1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxStaticBitmap class
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_STATBMP_H_
13 #define _WX_STATBMP_H_
16 #pragma interface "statbmp.h"
19 #include "wx/control.h"
22 WXDLLEXPORT_DATA(extern const char*) wxStaticBitmapNameStr
;
24 class WXDLLEXPORT wxStaticBitmap
: public wxControl
26 DECLARE_DYNAMIC_CLASS(wxStaticBitmap
)
32 wxStaticBitmap(wxWindow
*parent
, wxWindowID id
,
33 const wxBitmap
& label
,
34 const wxPoint
& pos
= wxDefaultPosition
,
35 const wxSize
& size
= wxDefaultSize
,
37 const wxString
& name
= wxStaticBitmapNameStr
)
39 Create(parent
, id
, label
, pos
, size
, style
, name
);
42 bool Create(wxWindow
*parent
, wxWindowID id
,
43 const wxBitmap
& label
,
44 const wxPoint
& pos
= wxDefaultPosition
,
45 const wxSize
& size
= wxDefaultSize
,
47 const wxString
& name
= wxStaticBitmapNameStr
);
49 virtual void SetBitmap(const wxBitmap
& bitmap
);
51 virtual bool ProcessCommand(wxCommandEvent
& WXUNUSED(event
))
56 wxBitmap
& GetBitmap() const { return (wxBitmap
&) m_messageBitmap
; }
58 // for compatibility with wxMSW
59 const wxIcon
& GetIcon() const
61 // don't use wxDynamicCast, icons and bitmaps are really the same thing
62 return (const wxIcon
&)m_messageBitmap
;
65 // for compatibility with wxMSW
66 void SetIcon(const wxIcon
& icon
)
71 // overriden base class virtuals
72 virtual bool AcceptsFocus() const { return FALSE
; }
75 virtual void ChangeFont(bool keepOriginalSize
= TRUE
);
76 virtual void ChangeBackgroundColour();
77 virtual void ChangeForegroundColour();
83 wxBitmap m_messageBitmap
;
84 wxBitmap m_messageBitmapOriginal
;