]> git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/statbmp.h
wxSystemSettings mods in wxGTK
[wxWidgets.git] / include / wx / gtk / statbmp.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk/statbmp.h
3 // Purpose:
4 // Author: Robert Roebling
5 // Id: $Id$
6 // Copyright: (c) 1998 Robert Roebling
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
9
10
11 #ifndef __GTKSTATICBITMAPH__
12 #define __GTKSTATICBITMAPH__
13
14 #ifdef __GNUG__
15 #pragma interface
16 #endif
17
18 #include "wx/icon.h"
19
20 //-----------------------------------------------------------------------------
21 // wxStaticBitmap
22 //-----------------------------------------------------------------------------
23
24 class wxStaticBitmap : public wxStaticBitmapBase
25 {
26 public:
27 wxStaticBitmap();
28 wxStaticBitmap( wxWindow *parent,
29 wxWindowID id,
30 const wxBitmap& label,
31 const wxPoint& pos = wxDefaultPosition,
32 const wxSize& size = wxDefaultSize,
33 long style = 0,
34 const wxString& name = wxStaticBitmapNameStr );
35 bool Create( wxWindow *parent,
36 wxWindowID id,
37 const wxBitmap& label,
38 const wxPoint& pos = wxDefaultPosition,
39 const wxSize& size = wxDefaultSize,
40 long style = 0,
41 const wxString& name = wxStaticBitmapNameStr);
42
43 virtual void SetIcon(const wxIcon& icon) { SetBitmap( icon ); }
44 virtual void SetBitmap( const wxBitmap& bitmap );
45 virtual wxBitmap GetBitmap() const { return m_bitmap; }
46
47 // for compatibility with wxMSW
48 wxIcon GetIcon() const
49 {
50 // don't use wxDynamicCast, icons and bitmaps are really the same thing
51 // in wxGTK
52 return (const wxIcon &)m_bitmap;
53 }
54
55 private:
56 // creates the new pixmap widget
57 void CreatePixmapWidget();
58
59 wxBitmap m_bitmap;
60
61 DECLARE_DYNAMIC_CLASS(wxStaticBitmap)
62 };
63
64 #endif // __GTKSTATICBITMAPH__