wx.adv.AboutDialogInfo contains information shown in the standard About dialog displayed by the wx.adv.AboutBox
function.
This class contains the general information about the program, such as its name, version, copyright and so on, as well as lists of the program developers, documentation writers, artists and translators. The simple properties from the former group are represented as a string with the exception of the program icon and the program web site, while the lists from the latter group are stored as list of strings and can be either set entirely at once using wx.adv.AboutDialogInfo.SetDevelopers
and similar functions or built one by one using wx.adv.AboutDialogInfo.AddDeveloper
etc.
Please also notice that while all the main platforms have the native implementation of the about dialog, they are often more limited than the generic version provided by wxWidgets and so the generic version is used if wx.adv.AboutDialogInfo has any fields not supported by the native version. Currently GTK+ version supports all the possible fields natively but MSW and Mac versions don’t support URLs, licence text nor custom icons in the about dialog and if either of those is used, wx.adv.AboutBox
will automatically use the generic version so you should avoid specifying these fields to achieve more native look and feel.
Example of usage:
def OnAbout(self, event):
aboutInfo = wx.adv.AboutDialogInfo()
aboutInfo.SetName("MyApp")
aboutInfo.SetVersion(MY_APP_VERSION_STRING)
aboutInfo.SetDescription(_("My wxPython-based application!"))
aboutInfo.SetCopyright("(C) 1992-2012")
aboutInfo.SetWebSite("http:#myapp.org")
aboutInfo.AddDeveloper("My Self")
wx.adv.AboutBox(aboutInfo)
See also
__init__ |
Default constructor leaves all fields are initially uninitialized, in general you should call at least SetVersion , SetCopyright and SetDescription . |
AddArtist |
Adds an artist name to be shown in the program credits. |
AddDeveloper |
Adds a developer name to be shown in the program credits. |
AddDocWriter |
Adds a documentation writer name to be shown in the program credits. |
AddTranslator |
Adds a translator name to be shown in the program credits. |
GetArtists |
Returns an array of the artist strings set in the dialog info. |
GetCopyright |
Get the copyright string. |
GetDescription |
Get the description string. |
GetDevelopers |
Returns an array of the developer strings set in the dialog info. |
GetDocWriters |
Returns an array of the writer strings set in the dialog info. |
GetIcon |
Returns the icon set by SetIcon . |
GetLicence |
Returns the licence string. |
GetLongVersion |
Return the long version string if set. |
GetName |
Get the name of the program. |
GetTranslators |
Returns an array of the translator strings set in the dialog info. |
GetVersion |
Return the short version string. |
GetWebSiteDescription |
Returns the description of the website URL set for the dialog. |
GetWebSiteURL |
Returns the website URL set for the dialog. |
HasArtists |
Returns True if artists have been set in the dialog info. |
HasCopyright |
Returns True if a copyright string has been specified. |
HasDescription |
Returns True if a description string has been specified. |
HasDevelopers |
Returns True if developers have been set in the dialog info. |
HasDocWriters |
Returns True if writers have been set in the dialog info. |
HasIcon |
Returns True if an icon has been set for the about dialog. |
HasLicence |
Returns True if the licence string has been set. |
HasTranslators |
Returns True if translators have been set in the dialog info. |
HasWebSite |
Returns True if the website info has been set. |
SetArtists |
Sets the list of artists to be shown in the program credits. |
SetCopyright |
Set the short string containing the program copyright information. |
SetDescription |
Set brief, but possibly multiline, description of the program. |
SetDevelopers |
Set the list of developers of the program. |
SetDocWriters |
Set the list of documentation writers. |
SetIcon |
Set the icon to be shown in the dialog. |
SetLicence |
Set the long, multiline string containing the text of the program licence. |
SetLicense |
This is the same as SetLicence . |
SetName |
Set the name of the program. |
SetTranslators |
Set the list of translators. |
SetVersion |
Set the version of the program. |
SetWebSite |
Set the web site for the program and its description (which defaults to url itself if empty). |
Artists |
See GetArtists and SetArtists |
Copyright |
See GetCopyright and SetCopyright |
Description |
See GetDescription and SetDescription |
Developers |
See GetDevelopers and SetDevelopers |
DocWriters |
See GetDocWriters and SetDocWriters |
Icon |
See GetIcon and SetIcon |
Licence |
See GetLicence and SetLicence |
LongVersion |
See GetLongVersion |
Name |
See GetName and SetName |
Translators |
See GetTranslators and SetTranslators |
Version |
See GetVersion and SetVersion |
WebSiteDescription |
See GetWebSiteDescription |
WebSiteURL |
See GetWebSiteURL |
wx.adv.
AboutDialogInfo
(object)¶Possible constructors:
AboutDialogInfo()
AboutDialogInfo contains information shown in the standard About dialog displayed by the AboutBox() function.
__init__
(self)¶Default constructor leaves all fields are initially uninitialized, in general you should call at least SetVersion
, SetCopyright
and SetDescription
.
AddArtist
(self, artist)¶Adds an artist name to be shown in the program credits.
Parameters: | artist (string) – |
---|
See also
AddDeveloper
(self, developer)¶Adds a developer name to be shown in the program credits.
Parameters: | developer (string) – |
---|
See also
AddDocWriter
(self, docwriter)¶Adds a documentation writer name to be shown in the program credits.
Parameters: | docwriter (string) – |
---|
See also
AddTranslator
(self, translator)¶Adds a translator name to be shown in the program credits.
Notice that if no translator names are specified explicitly, wx.adv.AboutBox
will try to use the translation of the string translator-credits
from the currently used message catalog
Parameters: | translator (string) – |
---|
See also
GetArtists
(self)¶Returns an array of the artist strings set in the dialog info.
Return type: | list of strings |
---|
GetCopyright
(self)¶Get the copyright string.
Return type: | string |
---|---|
Returns: | The copyright string |
GetDescription
(self)¶Get the description string.
Return type: | string |
---|---|
Returns: | The description string, free-form. |
GetDevelopers
(self)¶Returns an array of the developer strings set in the dialog info.
Return type: | list of strings |
---|
GetDocWriters
(self)¶Returns an array of the writer strings set in the dialog info.
Return type: | list of strings |
---|
GetLicence
(self)¶Returns the licence string.
Return type: | string |
---|
See also
GetLongVersion
(self)¶Return the long version string if set.
Return type: | string |
---|
See also
GetName
(self)¶Get the name of the program.
Return type: | string |
---|---|
Returns: | Name of the program |
See also
GetTranslators
(self)¶Returns an array of the translator strings set in the dialog info.
Return type: | list of strings |
---|
GetVersion
(self)¶Return the short version string.
Return type: | string |
---|
See also
GetWebSiteDescription
(self)¶Returns the description of the website URL set for the dialog.
Return type: | string |
---|
GetWebSiteURL
(self)¶Returns the website URL set for the dialog.
Return type: | string |
---|
HasArtists
(self)¶Returns True
if artists have been set in the dialog info.
Return type: | bool |
---|
HasCopyright
(self)¶Returns True
if a copyright string has been specified.
Return type: | bool |
---|
See also
HasDescription
(self)¶Returns True
if a description string has been specified.
Return type: | bool |
---|
See also
HasDevelopers
(self)¶Returns True
if developers have been set in the dialog info.
Return type: | bool |
---|
HasDocWriters
(self)¶Returns True
if writers have been set in the dialog info.
Return type: | bool |
---|
HasIcon
(self)¶Returns True
if an icon has been set for the about dialog.
Return type: | bool |
---|
HasLicence
(self)¶Returns True
if the licence string has been set.
Return type: | bool |
---|
HasTranslators
(self)¶Returns True
if translators have been set in the dialog info.
Return type: | bool |
---|
HasWebSite
(self)¶Returns True
if the website info has been set.
Return type: | bool |
---|
SetArtists
(self, artists)¶Sets the list of artists to be shown in the program credits.
Parameters: | artists (list of strings) – |
---|
See also
SetCopyright
(self, copyright)¶Set the short string containing the program copyright information.
Notice that any occurrences of "(C)"
in copyright will be replaced by the copyright symbol (circled C) automatically, which means that you can avoid using this symbol in the program source code which can be problematic,
Parameters: | copyright (string) – |
---|
SetDescription
(self, desc)¶Set brief, but possibly multiline, description of the program.
Parameters: | desc (string) – |
---|
SetDevelopers
(self, developers)¶Set the list of developers of the program.
Parameters: | developers (list of strings) – |
---|
See also
SetDocWriters
(self, docwriters)¶Set the list of documentation writers.
Parameters: | docwriters (list of strings) – |
---|
See also
SetIcon
(self, icon)¶Set the icon to be shown in the dialog.
By default the icon of the main frame will be shown if the native about dialog supports custom icons. If it doesn’t but a valid icon is specified using this method, the generic about dialog is used instead so you should avoid calling this function for maximally native look and feel.
Parameters: | icon (wx.Icon) – |
---|
SetLicence
(self, licence)¶Set the long, multiline string containing the text of the program licence.
Only GTK+ version supports showing the licence text in the native about dialog currently so the generic version will be used under all the other platforms if this method is called. To preserve the native look and feel it is advised that you do not call this method but provide a separate menu item in the "Help"
menu for displaying the text of your program licence.
Parameters: | licence (string) – |
---|
SetLicense
(self, licence)¶This is the same as SetLicence
.
Parameters: | licence (string) – |
---|
SetName
(self, name)¶Set the name of the program.
If this method is not called, the string returned by wx.App.GetAppName
will be shown in the dialog.
Parameters: | name (string) – |
---|
SetTranslators
(self, translators)¶Set the list of translators.
Please see AddTranslator
for additional discussion.
Parameters: | translators (list of strings) – |
---|
SetVersion
(self, version, longVersion="")¶Set the version of the program.
The word “version” shouldn’t be included in version. Example version values: “1.2” and “RC2
”. In about dialogs with more space set aside for version information, longVersion is used. Example longVersion values: “Version 1.2” and “Release Candidate 2”. If version is non-empty but longVersion is empty, a long version is constructed automatically, using version (by simply prepending “Version ” to version).
The generic about dialog and native GTK+ dialog use version only, as a suffix to the program name. The native MSW and OS X about dialogs use the long version.
Parameters: |
|
---|
SetWebSite
(self, url, desc="")¶Set the web site for the program and its description (which defaults to url itself if empty).
Please notice that only GTK+ version currently supports showing the link in the native about dialog so if this method is called, the generic version will be used under all the other platforms.
Parameters: |
|
---|
Artists
¶See GetArtists
and SetArtists
Copyright
¶See GetCopyright
and SetCopyright
Description
¶See GetDescription
and SetDescription
Developers
¶See GetDevelopers
and SetDevelopers
DocWriters
¶See GetDocWriters
and SetDocWriters
Licence
¶See GetLicence
and SetLicence
LongVersion
¶See GetLongVersion
Translators
¶See GetTranslators
and SetTranslators
Version
¶See GetVersion
and SetVersion
WebSiteDescription
¶WebSiteURL
¶See GetWebSiteURL