document the wxArtID and wxArtClient types; they help to understand how wxArtProvider::GetBitmap can be used to retrieve GTK native icons
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57092 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -6,6 +6,17 @@
|
||||
// Licence: wxWindows license
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/**
|
||||
This type identifies the client of the art objects requested to wxArtProvider.
|
||||
*/
|
||||
typedef wxString wxArtClient;
|
||||
|
||||
/**
|
||||
This type identifies a specific art object which can be requested to wxArtProvider.
|
||||
*/
|
||||
typedef wxString wxArtID;
|
||||
|
||||
|
||||
/**
|
||||
@class wxArtProvider
|
||||
|
||||
@@ -45,10 +56,6 @@
|
||||
code and use platform native icons as provided by wxArtProvider::GetBitmap or
|
||||
wxArtProvider::GetIcon.
|
||||
|
||||
@todo IS THIS NB TRUE?
|
||||
(@note this is not yet really possible as of wxWidgets 2.3.3, the set of wxArtProvider
|
||||
bitmaps is too small).
|
||||
|
||||
@section artprovider_identify Identifying art resources
|
||||
|
||||
Every bitmap and icon bundle are known to wxArtProvider under an unique ID that
|
||||
@@ -116,7 +123,13 @@
|
||||
|
||||
@note
|
||||
When running under GTK+ 2, GTK+ stock item IDs (e.g. @c "gtk-cdrom") may be used
|
||||
as well. Additionally, if wxGTK was compiled against GTK+ >= 2.4, then it is also
|
||||
as well:
|
||||
@code
|
||||
#ifdef __WXGTK__
|
||||
wxBitmap bmp = wxArtProvider::GetBitmap("gtk-cdrom", wxART_MENU);
|
||||
#endif
|
||||
@endcode
|
||||
Additionally, if wxGTK was compiled against GTK+ >= 2.4, then it is also
|
||||
possible to load icons from current icon theme by specifying their name (without
|
||||
extension and directory components).
|
||||
Icon themes recognized by GTK+ follow the freedesktop.org Icon Themes specification
|
||||
@@ -128,7 +141,7 @@
|
||||
|
||||
@section artprovider_clients Clients
|
||||
|
||||
Client is the entity that calls wxArtProvider's GetBitmap or GetIcon function.
|
||||
The @e client is the entity that calls wxArtProvider's GetBitmap() or GetIcon() function.
|
||||
It is represented by wxClientID type and can have one of these values:
|
||||
|
||||
@li wxART_TOOLBAR
|
||||
@@ -141,7 +154,7 @@
|
||||
@li wxART_OTHER (used for all requests that don't fit into any of the
|
||||
categories above)
|
||||
|
||||
Client ID servers as a hint to wxArtProvider that is supposed to help it to
|
||||
Client ID serve as a hint to wxArtProvider that is supposed to help it to
|
||||
choose the best looking bitmap. For example it is often desirable to use
|
||||
slightly different icons in menus and toolbars even though they represent
|
||||
the same action (e.g. wxART_FILE_OPEN). Remember that this is really only a
|
||||
|
Reference in New Issue
Block a user