2008-03-08 08:52:38 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: statbmp.h
|
2008-03-10 11:24:38 -04:00
|
|
|
// Purpose: interface of wxStaticBitmap
|
2008-03-08 08:52:38 -05:00
|
|
|
// Author: wxWidgets team
|
|
|
|
// RCS-ID: $Id$
|
|
|
|
// Licence: wxWindows license
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
/**
|
|
|
|
@class wxStaticBitmap
|
|
|
|
@wxheader{statbmp.h}
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-06-21 11:32:33 -04:00
|
|
|
A static bitmap control displays a bitmap. Native implementations on some
|
|
|
|
platforms are only meant for display of the small icons in the dialog
|
|
|
|
boxes. In particular, under Windows 9x the size of bitmap is limited
|
|
|
|
to 64*64 pixels.
|
|
|
|
If you want to display larger images portably, you may use generic
|
|
|
|
implementation wxGenericStaticBitmap declared in <wx/generic/statbmpg.h>.
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
@library{wxcore}
|
|
|
|
@category{ctrl}
|
2008-05-02 00:52:42 -04:00
|
|
|
<!-- @appearance{staticbitmap.png} -->
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-03-10 11:24:38 -04:00
|
|
|
@see wxStaticBitmap, wxStaticBox
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
class wxStaticBitmap : public wxControl
|
|
|
|
{
|
|
|
|
public:
|
2008-05-29 10:10:52 -04:00
|
|
|
/**
|
|
|
|
Default constructor
|
|
|
|
*/
|
|
|
|
wxStaticBitmap();
|
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
/**
|
|
|
|
Constructor, creating and showing a static bitmap control.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param parent
|
2008-03-09 08:33:59 -04:00
|
|
|
Parent window. Should not be @NULL.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param id
|
2008-03-09 08:33:59 -04:00
|
|
|
Control identifier. A value of -1 denotes a default value.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param label
|
2008-03-09 08:33:59 -04:00
|
|
|
Bitmap label.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param pos
|
2008-03-09 08:33:59 -04:00
|
|
|
Window position.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param size
|
2008-03-09 08:33:59 -04:00
|
|
|
Window size.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param style
|
2008-03-09 08:33:59 -04:00
|
|
|
Window style. See wxStaticBitmap.
|
2008-03-08 09:43:31 -05:00
|
|
|
@param name
|
2008-03-09 08:33:59 -04:00
|
|
|
Window name.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see Create()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-03-08 09:43:31 -05:00
|
|
|
wxStaticBitmap(wxWindow* parent, wxWindowID id,
|
|
|
|
const wxBitmap& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize,
|
|
|
|
long style = 0,
|
|
|
|
const wxString& name = "staticBitmap");
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Creation function, for two-step construction. For details see wxStaticBitmap().
|
|
|
|
*/
|
|
|
|
bool Create(wxWindow* parent, wxWindowID id,
|
|
|
|
const wxBitmap& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize,
|
|
|
|
long style = 0,
|
|
|
|
const wxString& name = "staticBitmap");
|
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the bitmap currently used in the control. Notice that this method can
|
|
|
|
be called even if SetIcon() had been used.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetBitmap()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-03-09 12:24:26 -04:00
|
|
|
wxBitmap GetBitmap() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Returns the icon currently used in the control. Notice that this method can
|
|
|
|
only be called if SetIcon() had been used: an icon
|
2008-03-08 09:43:31 -05:00
|
|
|
can't be retrieved from the control if a bitmap had been set (using
|
2008-03-08 08:52:38 -05:00
|
|
|
wxStaticBitmap::SetBitmap).
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see SetIcon()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
2008-03-09 12:24:26 -04:00
|
|
|
wxIcon GetIcon() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the bitmap label.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param label
|
2008-03-09 08:33:59 -04:00
|
|
|
The new bitmap.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-09 08:33:59 -04:00
|
|
|
@see GetBitmap()
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
virtual void SetBitmap(const wxBitmap& label);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Sets the label to the given icon.
|
2008-03-20 09:45:17 -04:00
|
|
|
|
2008-03-08 09:43:31 -05:00
|
|
|
@param label
|
2008-03-09 08:33:59 -04:00
|
|
|
The new icon.
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
virtual void SetIcon(const wxIcon& label);
|
|
|
|
};
|
2008-03-10 11:24:38 -04:00
|
|
|
|