]> git.saurik.com Git - wxWidgets.git/blob - interface/statbmp.h
c5cb6b3bbae928548dc4265b0f24cd132e5f03bc
[wxWidgets.git] / interface / statbmp.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: statbmp.h
3 // Purpose: documentation for wxStaticBitmap class
4 // Author: wxWidgets team
5 // RCS-ID: $Id$
6 // Licence: wxWindows license
7 /////////////////////////////////////////////////////////////////////////////
8
9 /**
10 @class wxStaticBitmap
11 @wxheader{statbmp.h}
12
13 A static bitmap control displays a bitmap. It is meant for display of the
14 small icons in the dialog boxes and is not meant to be a general purpose image
15 display control. In particular, under Windows 9x the size of bitmap is limited
16 to 64*64 pixels and thus you should use your own control if you want to
17 display larger images portably.
18
19 @library{wxcore}
20 @category{ctrl}
21 @appearance{staticbitmap.png}
22
23 @seealso
24 wxStaticBitmap, wxStaticBox
25 */
26 class wxStaticBitmap : public wxControl
27 {
28 public:
29 //@{
30 /**
31 Constructor, creating and showing a static bitmap control.
32
33 @param parent
34 Parent window. Should not be @NULL.
35
36 @param id
37 Control identifier. A value of -1 denotes a default value.
38
39 @param label
40 Bitmap label.
41
42 @param pos
43 Window position.
44
45 @param size
46 Window size.
47
48 @param style
49 Window style. See wxStaticBitmap.
50
51 @param name
52 Window name.
53
54 @sa Create()
55 */
56 wxStaticBitmap();
57 wxStaticBitmap(wxWindow* parent, wxWindowID id,
58 const wxBitmap& label,
59 const wxPoint& pos = wxDefaultPosition,
60 const wxSize& size = wxDefaultSize,
61 long style = 0,
62 const wxString& name = "staticBitmap");
63 //@}
64
65 /**
66 Creation function, for two-step construction. For details see wxStaticBitmap().
67 */
68 bool Create(wxWindow* parent, wxWindowID id,
69 const wxBitmap& label,
70 const wxPoint& pos = wxDefaultPosition,
71 const wxSize& size = wxDefaultSize,
72 long style = 0,
73 const wxString& name = "staticBitmap");
74
75 /**
76 Returns the bitmap currently used in the control. Notice that this method can
77 be called even if SetIcon() had been used.
78
79 @sa SetBitmap()
80 */
81 wxBitmap GetBitmap();
82
83 /**
84 Returns the icon currently used in the control. Notice that this method can
85 only be called if SetIcon() had been used: an icon
86 can't be retrieved from the control if a bitmap had been set (using
87 wxStaticBitmap::SetBitmap).
88
89 @sa SetIcon()
90 */
91 wxIcon GetIcon();
92
93 /**
94 Sets the bitmap label.
95
96 @param label
97 The new bitmap.
98
99 @sa GetBitmap()
100 */
101 virtual void SetBitmap(const wxBitmap& label);
102
103 /**
104 Sets the label to the given icon.
105
106 @param label
107 The new icon.
108 */
109 virtual void SetIcon(const wxIcon& label);
110 };