xtd - Reference Guide  0.1.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
xtd::forms::about_dialog Class Referencefinal

#include <about_dialog.h>

Definition

Represents a dialog box that displays about dialog.

Namespace
xtd::forms
Library
xtd.forms
Appearance
Windows macOS Gnome
Light
td
td
td
Dark
td
td
td
Examples
The following code example demonstrate the use of about_dialog dialog.
#include <xtd/xtd>
#include "../resources/gammasoft_64x64.xpm"
using namespace xtd;
using namespace xtd::forms;
class form1 : public form {
public:
form1() {
text("About dialog example");
controls().push_back(button1);
button1.location({10, 10});
button1.text("About...");
button1.click += [&] {
about_dialog.icon(xtd::drawing::bitmap(gammasoft_64x64_xpm));
about_dialog.name("About dialog");
about_dialog.description("About dialog description.");
about_dialog.copyright("Copyright (c) 2021 Gammasoft.\nAll rights reserved.");
about_dialog.website("https://gammasoft71.wixsite.com/gammasoft");
about_dialog.website_label("gammasoft website");
about_dialog.authors({"Gammasoft", "Contributors"});
about_dialog.documenters({"Gammasoft"});
about_dialog.translators({"Gammasoft", "Contributors"});
about_dialog.artists({"Gammasoft"});
about_dialog.license("MIT License\n"
"\n"
"Copyright (c) 2021 Gammasoft.\n"
"\n"
"Permission is hereby granted, free of charge, to any person obtaining\n"
"a copy of this software and associated documentation files (the\n"
"\"Software\"), to deal in the Software without restriction, including\n"
"without limitation the rights to use, copy, modify, merge, publish,\n"
"distribute, sublicense, and/or sell copies of the Software, and to\n"
"permit persons to whom the Software is furnished to do so, subject\n"
"to the following conditions:\n"
"\n"
"The above copyright notice and this permission notice shall be\n"
"included in all copies or substantial portions of the Software.\n"
"\n"
"THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF\n"
"ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO\n"
"THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A\n"
"PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT\n"
"SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR\n"
"ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\n"
"ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n"
"OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE\n"
"OR OTHER DEALINGS IN THE SOFTWARE.\n");
};
}
private:
};
int main() {
application::run(form1());
}
Encapsulates a GDI+ bitmap, which consists of the pixel data for a graphics image and its attributes....
Definition: bitmap.h:19
Represents a dialog box that displays about dialog.
Definition: about_dialog.h:50
const artist_collection & artists() const
Gets the artists array.
Definition: about_dialog.h:66
const translator_collection & translators() const
Gets the translators array.
Definition: about_dialog.h:199
xtd::drawing::icon icon() const
Gets the product icon.
Definition: about_dialog.h:141
xtd::ustring long_version() const
Gets the product long version.
Definition: about_dialog.h:177
xtd::ustring copyright() const
Gets the product copyright.
Definition: about_dialog.h:94
xtd::ustring name() const
Gets the product name.
Definition: about_dialog.h:188
xtd::ustring description() const
Gets the product description.
Definition: about_dialog.h:105
xtd::ustring license() const
Gets the product license.
Definition: about_dialog.h:166
void show()
Runs about dialog box.
const author_collection & authors() const
Gets the authors array.
Definition: about_dialog.h:80
const documenter_collection & documenters() const
Gets the documentation writers array.
Definition: about_dialog.h:116
xtd::ustring website_label() const
Gets the product website label.
Definition: about_dialog.h:235
xtd::ustring website() const
Gets the product website.
Definition: about_dialog.h:224
xtd::ustring version() const
Gets the product version.
Definition: about_dialog.h:213
static void run()
Begins running a standard application message loop on the current thread, without a form.
Represents a Windows button control.
Definition: button.h:54
Represents a window or dialog box that makes up an application's user interface.
Definition: form.h:40
@ button1
The first button on the message box is the default button.
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition: about_box.h:13
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition: system_report.h:17
Examples
The following code example demonstrates the use of about_dialog dialog with dialog_styledialog_style to system.
#include <xtd/xtd>
#include "../resources/gammasoft_64x64.xpm"
using namespace xtd;
using namespace xtd::forms;
class form1 : public form {
public:
form1() {
text("About dialog system example");
controls().push_back(button1);
button1.location({10, 10});
button1.text("About...");
button1.click += [&] {
about_dialog.icon(xtd::drawing::bitmap(gammasoft_64x64_xpm));
about_dialog.name("About dialog system");
about_dialog.description("About dialog description.");
about_dialog.copyright("Copyright (c) 2021 Gammasoft.\nAll rights reserved.");
about_dialog.website("https://gammasoft71.wixsite.com/gammasoft");
about_dialog.website_label("gammasoft website");
about_dialog.authors({"Gammasoft", "Contributors"});
about_dialog.documenters({"Gammasoft"});
about_dialog.translators({"Gammasoft", "Contributors"});
about_dialog.artists({"Gammasoft"});
about_dialog.license("MIT License\n"
"\n"
"Copyright (c) 2021 Gammasoft.\n"
"\n"
"Permission is hereby granted, free of charge, to any person obtaining\n"
"a copy of this software and associated documentation files (the\n"
"\"Software\"), to deal in the Software without restriction, including\n"
"without limitation the rights to use, copy, modify, merge, publish,\n"
"distribute, sublicense, and/or sell copies of the Software, and to\n"
"permit persons to whom the Software is furnished to do so, subject\n"
"to the following conditions:\n"
"\n"
"The above copyright notice and this permission notice shall be\n"
"included in all copies or substantial portions of the Software.\n"
"\n"
"THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF\n"
"ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO\n"
"THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A\n"
"PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT\n"
"SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR\n"
"ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\n"
"ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n"
"OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE\n"
"OR OTHER DEALINGS IN THE SOFTWARE.\n");
};
}
private:
};
int main() {
application::run(form1());
}
xtd::forms::dialog_style dialog_style() const
Gets the dialog style.
Definition: about_dialog.h:130
@ system
System style dialog.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

Inherits xtd::forms::component.

Public Types

using artist_collection = xtd::forms::layout::arranged_element_collection< xtd::ustring >
 Represents a artist collection.
 
using author_collection = xtd::forms::layout::arranged_element_collection< xtd::ustring >
 Represents a author collection.
 
using documenter_collection = xtd::forms::layout::arranged_element_collection< xtd::ustring >
 Represents a documenter collection.
 
using translator_collection = xtd::forms::layout::arranged_element_collection< xtd::ustring >
 Represents a translator collection.
 

Public Member Functions

 about_dialog ()=default
 Initializes a new instance of the about_dialog class.
 
artist_collectionartists ()
 Gets the artists array.
 
const artist_collectionartists () const
 Gets the artists array.
 
about_dialogartists (const artist_collection &artists)
 Sets the artists array.
 
author_collectionauthors ()
 Gets the authors array.
 
const author_collectionauthors () const
 Gets the authors array.
 
about_dialogauthors (const author_collection &authors)
 Sets the authors array.
 
xtd::ustring copyright () const
 Gets the product copyright.
 
about_dialogcopyright (const xtd::ustring &copyright)
 Sets the product description.
 
xtd::ustring description () const
 Gets the product description.
 
about_dialogdescription (const xtd::ustring &description)
 Sets the product description.
 
xtd::forms::dialog_style dialog_style () const
 Gets the dialog style.
 
about_dialogdialog_style (xtd::forms::dialog_style dialog_style)
 Sets the dialog style.
 
documenter_collectiondocumenters ()
 Gets the artists array.
 
const documenter_collectiondocumenters () const
 Gets the documentation writers array.
 
about_dialogdocumenters (const documenter_collection &documenters)
 Sets the documenters array.
 
xtd::drawing::icon icon () const
 Gets the product icon.
 
about_dialogicon (const xtd::drawing::bitmap &bitmap)
 Sets the product icon.
 
about_dialogicon (const xtd::drawing::icon &icon)
 Sets the product icon.
 
about_dialogicon (const xtd::drawing::image &image)
 Sets the product icon.
 
xtd::ustring license () const
 Gets the product license.
 
about_dialoglicense (const xtd::ustring &license)
 Sets the product license.
 
xtd::ustring long_version () const
 Gets the product long version.
 
about_dialoglong_version (const xtd::ustring &long_version)
 Sets the product long version.
 
xtd::ustring name () const
 Gets the product name.
 
about_dialogname (const xtd::ustring &name)
 Sets the product name.
 
void reset ()
 Resets all properties to empty string.
 
void show ()
 Runs about dialog box.
 
void show (const iwin32_window &owner)
 Runs about dialog box.
 
translator_collectiontranslators ()
 Gets the translators array.
 
const translator_collectiontranslators () const
 Gets the translators array.
 
about_dialogtranslators (const translator_collection &translators)
 Sets the translators array.
 
xtd::ustring version () const
 Gets the product version.
 
about_dialogversion (const xtd::ustring &version)
 Sets the product version.
 
xtd::ustring website () const
 Gets the product website.
 
about_dialogwebsite (const xtd::ustring &website)
 Sets the product website.
 
xtd::ustring website_label () const
 Gets the product website label.
 
about_dialogwebsite_label (const xtd::ustring &website_label)
 Sets the product website label.
 
- Public Member Functions inherited from xtd::object
 object ()=default
 Create a new instance of the ultimate base class object.
 
virtual bool equals (const object &obj) const noexcept
 Determines whether the specified object is equal to the current object.
 
virtual size_t get_hash_code () const noexcept
 Serves as a hash function for a particular type.
 
template<typename object_t >
std::unique_ptr< object_t > memberwise_clone () const
 Gets the type of the current instance.
 
virtual xtd::ustring to_string () const noexcept
 Returns a std::string that represents the current object.
 

Additional Inherited Members

- Static Public Member Functions inherited from xtd::object
static bool equals (const object &object_a, const object &object_b) noexcept
 Determines whether the specified object instances are considered equal.
 
static bool reference_equals (const object &object_a, const object &object_b) noexcept
 Determines whether the specified object instances are the same instance.
 
- Protected Member Functions inherited from xtd::forms::component
 component ()=default
 Initialises a new instance of the component class.
 
virtual bool can_raise_events () const
 Gets a value indicating whether the component can raise an event.
 
bool design_mode () const
 Gets a value that indicates whether the component is currently in design mode.
 

Member Typedef Documentation

◆ artist_collection

Represents a artist collection.

◆ author_collection

Represents a author collection.

◆ documenter_collection

Represents a documenter collection.

◆ translator_collection

Represents a translator collection.

Constructor & Destructor Documentation

◆ about_dialog()

xtd::forms::about_dialog::about_dialog ( )
default

Initializes a new instance of the about_dialog class.

Member Function Documentation

◆ artists() [1/3]

artist_collection & xtd::forms::about_dialog::artists ( )
inline

Gets the artists array.

Returns
The artists array.

◆ artists() [2/3]

const artist_collection & xtd::forms::about_dialog::artists ( ) const
inline

Gets the artists array.

Returns
The artists array.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ artists() [3/3]

about_dialog & xtd::forms::about_dialog::artists ( const artist_collection artists)
inline

Sets the artists array.

Parameters
artistsThe artists array.
Returns
Current about_dialog instance.

◆ authors() [1/3]

author_collection & xtd::forms::about_dialog::authors ( )
inline

Gets the authors array.

Returns
The authors array.

◆ authors() [2/3]

const author_collection & xtd::forms::about_dialog::authors ( ) const
inline

Gets the authors array.

Returns
The author array.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ authors() [3/3]

about_dialog & xtd::forms::about_dialog::authors ( const author_collection authors)
inline

Sets the authors array.

Parameters
authorsThe authors array.
Returns
Current about_dialog instance.

◆ copyright() [1/2]

xtd::ustring xtd::forms::about_dialog::copyright ( ) const
inline

Gets the product copyright.

Returns
The product copyright.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ copyright() [2/2]

about_dialog & xtd::forms::about_dialog::copyright ( const xtd::ustring copyright)
inline

Sets the product description.

Parameters
copyrightThe description copyright.
Returns
Current about_dialog instance.

◆ description() [1/2]

xtd::ustring xtd::forms::about_dialog::description ( ) const
inline

Gets the product description.

Returns
The product description.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ description() [2/2]

about_dialog & xtd::forms::about_dialog::description ( const xtd::ustring description)
inline

Sets the product description.

Parameters
descriptionThe product description.
Returns
Current about_dialog instance.

◆ dialog_style() [1/2]

xtd::forms::dialog_style xtd::forms::about_dialog::dialog_style ( ) const
inline

Gets the dialog style.

Returns
One of the xtd::forms::dialog_style values. The default value is xtd::forms::dialog_style::standard.
Examples
about_dialog_system.cpp.

◆ dialog_style() [2/2]

about_dialog & xtd::forms::about_dialog::dialog_style ( xtd::forms::dialog_style  dialog_style)
inline

Sets the dialog style.

Parameters
dialog_styleOne of the xtd::forms::dialog_style values. The default value is xtd::forms::dialog_style::standard.
Returns
Current about_dialog instance.

◆ documenters() [1/3]

documenter_collection & xtd::forms::about_dialog::documenters ( )
inline

Gets the artists array.

Returns
The artists array.

◆ documenters() [2/3]

const documenter_collection & xtd::forms::about_dialog::documenters ( ) const
inline

Gets the documentation writers array.

Returns
The documentation writers array.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ documenters() [3/3]

about_dialog & xtd::forms::about_dialog::documenters ( const documenter_collection documenters)
inline

Sets the documenters array.

Parameters
documentersThe documenters array.
Returns
Current about_dialog instance.

◆ icon() [1/4]

xtd::drawing::icon xtd::forms::about_dialog::icon ( ) const
inline

Gets the product icon.

Returns
The product icon.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ icon() [2/4]

about_dialog & xtd::forms::about_dialog::icon ( const xtd::drawing::bitmap bitmap)
inline

Sets the product icon.

Parameters
bitmapThe product icon.
Returns
Current about_dialog instance.

◆ icon() [3/4]

about_dialog & xtd::forms::about_dialog::icon ( const xtd::drawing::icon icon)
inline

Sets the product icon.

Parameters
iconThe product icon.
Returns
Current about_dialog instance.

◆ icon() [4/4]

about_dialog & xtd::forms::about_dialog::icon ( const xtd::drawing::image image)
inline

Sets the product icon.

Parameters
imageThe product icon.
Returns
Current about_dialog instance.

◆ license() [1/2]

xtd::ustring xtd::forms::about_dialog::license ( ) const
inline

Gets the product license.

Returns
The product license.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ license() [2/2]

about_dialog & xtd::forms::about_dialog::license ( const xtd::ustring license)
inline

Sets the product license.

Parameters
nameThe product license.
Returns
Current about_dialog instance.

◆ long_version() [1/2]

xtd::ustring xtd::forms::about_dialog::long_version ( ) const
inline

Gets the product long version.

Returns
The product long version.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ long_version() [2/2]

about_dialog & xtd::forms::about_dialog::long_version ( const xtd::ustring long_version)
inline

Sets the product long version.

Parameters
versionThe version version.
Returns
Current about_dialog instance.

◆ name() [1/2]

xtd::ustring xtd::forms::about_dialog::name ( ) const
inline

Gets the product name.

Returns
The product name.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ name() [2/2]

about_dialog & xtd::forms::about_dialog::name ( const xtd::ustring name)
inline

Sets the product name.

Parameters
nameThe product name.
Returns
Current about_dialog instance.

◆ reset()

void xtd::forms::about_dialog::reset ( )

Resets all properties to empty string.

◆ show() [1/2]

void xtd::forms::about_dialog::show ( )

Runs about dialog box.

Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ show() [2/2]

void xtd::forms::about_dialog::show ( const iwin32_window owner)

Runs about dialog box.

◆ translators() [1/3]

translator_collection & xtd::forms::about_dialog::translators ( )
inline

Gets the translators array.

Returns
The translators array.

◆ translators() [2/3]

const translator_collection & xtd::forms::about_dialog::translators ( ) const
inline

Gets the translators array.

Returns
The translators array.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ translators() [3/3]

about_dialog & xtd::forms::about_dialog::translators ( const translator_collection translators)
inline

Sets the translators array.

Parameters
translatorsThe translators array.
Returns
Current about_dialog instance.

◆ version() [1/2]

xtd::ustring xtd::forms::about_dialog::version ( ) const
inline

Gets the product version.

Returns
The product version.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ version() [2/2]

about_dialog & xtd::forms::about_dialog::version ( const xtd::ustring version)
inline

Sets the product version.

Parameters
versionThe version version.
Returns
Current about_dialog instance.

◆ website() [1/2]

xtd::ustring xtd::forms::about_dialog::website ( ) const
inline

Gets the product website.

Returns
The website.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ website() [2/2]

about_dialog & xtd::forms::about_dialog::website ( const xtd::ustring website)
inline

Sets the product website.

Parameters
websiteThe product website.
Returns
Current about_dialog instance.

◆ website_label() [1/2]

xtd::ustring xtd::forms::about_dialog::website_label ( ) const
inline

Gets the product website label.

Returns
The product website label.
Examples
about_dialog.cpp, and about_dialog_system.cpp.

◆ website_label() [2/2]

about_dialog & xtd::forms::about_dialog::website_label ( const xtd::ustring website_label)
inline

Sets the product website label.

Parameters
website_labelThe product website label.
Returns
Current about_dialog instance.

The documentation for this class was generated from the following file: