]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/iconbndl.h
Removed wxPG_EX_LEGACY_VALIDATORS
[wxWidgets.git] / interface / wx / iconbndl.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: iconbndl.h
e54c96f1 3// Purpose: interface of wxIconBundle
23324ae1
FM
4// Author: wxWidgets team
5// RCS-ID: $Id$
6// Licence: wxWindows license
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxIconBundle
7c913512 11
23324ae1
FM
12 This class contains multiple copies of an icon in different sizes,
13 see also wxDialog::SetIcons and
14 wxTopLevelWindow::SetIcons.
7c913512 15
23324ae1
FM
16 @library{wxcore}
17 @category{FIXME}
7c913512 18
23324ae1 19 @stdobjects
65874118 20 ::wxNullIconBundle
23324ae1
FM
21*/
22class wxIconBundle : public wxGDIObject
23{
24public:
25 //@{
26 /**
27 Copy constructor.
28 */
29 wxIconBundle();
e98e625c 30 wxIconBundle(const wxString& file, wxBitmapType type);
7c913512
FM
31 wxIconBundle(const wxIcon& icon);
32 wxIconBundle(const wxIconBundle& ic);
23324ae1
FM
33 //@}
34
35 /**
36 Destructor.
37 */
adaaa686 38 virtual ~wxIconBundle();
23324ae1
FM
39
40 //@{
41 /**
42 Adds the icon to the collection; if the collection already
43 contains an icon with the same width and height, it is
44 replaced by the new one.
45 */
e98e625c 46 void AddIcon(const wxString& file, wxBitmapType type);
7c913512 47 void AddIcon(const wxIcon& icon);
23324ae1
FM
48 //@}
49
50 //@{
51 /**
52 Same as GetIcon( wxSize( size, size ) ).
53 */
328f5751
FM
54 wxIcon GetIcon(const wxSize& size) const;
55 const wxIcon GetIcon(wxCoord size = -1) const;
23324ae1
FM
56 //@}
57
58 /**
59 Returns the icon with exactly the given size or @c wxNullIcon if this
60 size is not available.
61 */
328f5751 62 wxIcon GetIconOfExactSize(const wxSize& size) const;
23324ae1
FM
63
64 /**
65 Returns @true if the bundle doesn't contain any icons, @false otherwise (in
66 which case a call to GetIcon() with default
67 parameter should return a valid icon).
68 */
328f5751 69 bool IsEmpty() const;
23324ae1
FM
70
71 /**
72 Assignment operator, using @ref overview_trefcount "reference counting".
73 */
74 wxIconBundle operator =(const wxIconBundle& ic);
75
76 /**
77 Equality operator. This returns @true if two icon bundles are equal.
78 */
79 bool operator ==(const wxIconBundle& ic);
80};
e54c96f1
FM
81
82
83/**
65874118 84 An empty wxIconBundle.
e54c96f1
FM
85*/
86wxIconBundle wxNullIconBundle;
87
88