1998-05-20 14:01:55 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
2001-06-26 20:59:19 +00:00
|
|
|
// Name: wx/gtk/statbmp.h
|
1998-05-20 14:01:55 +00:00
|
|
|
// Purpose:
|
|
|
|
// Author: Robert Roebling
|
1998-10-29 18:03:18 +00:00
|
|
|
// Copyright: (c) 1998 Robert Roebling
|
2004-05-23 20:53:33 +00:00
|
|
|
// Licence: wxWindows licence
|
1998-05-20 14:01:55 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef __GTKSTATICBITMAPH__
|
|
|
|
#define __GTKSTATICBITMAPH__
|
|
|
|
|
1999-06-22 08:36:29 +00:00
|
|
|
#include "wx/icon.h"
|
1998-05-20 14:01:55 +00:00
|
|
|
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
// wxStaticBitmap
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
|
2005-08-02 22:58:06 +00:00
|
|
|
class WXDLLIMPEXP_CORE wxStaticBitmap : public wxStaticBitmapBase
|
1998-05-28 22:05:55 +00:00
|
|
|
{
|
1999-06-21 21:29:40 +00:00
|
|
|
public:
|
|
|
|
wxStaticBitmap();
|
|
|
|
wxStaticBitmap( wxWindow *parent,
|
|
|
|
wxWindowID id,
|
|
|
|
const wxBitmap& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize,
|
|
|
|
long style = 0,
|
|
|
|
const wxString& name = wxStaticBitmapNameStr );
|
|
|
|
bool Create( wxWindow *parent,
|
|
|
|
wxWindowID id,
|
|
|
|
const wxBitmap& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize,
|
|
|
|
long style = 0,
|
|
|
|
const wxString& name = wxStaticBitmapNameStr);
|
|
|
|
|
2014-03-30 00:02:23 +00:00
|
|
|
virtual void SetIcon(const wxIcon& icon) wxOVERRIDE { SetBitmap( icon ); }
|
|
|
|
virtual void SetBitmap( const wxBitmap& bitmap ) wxOVERRIDE;
|
|
|
|
virtual wxBitmap GetBitmap() const wxOVERRIDE { return m_bitmap; }
|
1999-06-21 21:29:40 +00:00
|
|
|
|
|
|
|
// for compatibility with wxMSW
|
2014-03-30 00:02:23 +00:00
|
|
|
wxIcon GetIcon() const wxOVERRIDE
|
1999-06-28 22:06:24 +00:00
|
|
|
{
|
|
|
|
// don't use wxDynamicCast, icons and bitmaps are really the same thing
|
|
|
|
// in wxGTK
|
|
|
|
return (const wxIcon &)m_bitmap;
|
|
|
|
}
|
1999-06-21 21:29:40 +00:00
|
|
|
|
2004-05-06 17:26:25 +00:00
|
|
|
static wxVisualAttributes
|
|
|
|
GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
|
2009-08-21 10:41:26 +00:00
|
|
|
|
1999-06-21 21:29:40 +00:00
|
|
|
private:
|
|
|
|
wxBitmap m_bitmap;
|
1998-05-28 22:05:55 +00:00
|
|
|
|
2015-04-23 11:49:01 +00:00
|
|
|
wxDECLARE_DYNAMIC_CLASS(wxStaticBitmap);
|
2001-06-26 20:59:19 +00:00
|
|
|
};
|
1999-06-14 23:04:05 +00:00
|
|
|
|
1998-05-20 14:01:55 +00:00
|
|
|
#endif // __GTKSTATICBITMAPH__
|