1998-05-20 10:01:55 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
2006-01-22 21:28:01 -05:00
|
|
|
// Name: wx/gtk1/statbmp.h
|
1998-05-20 10:01:55 -04:00
|
|
|
// Purpose:
|
|
|
|
// Author: Robert Roebling
|
1998-10-29 13:03:18 -05:00
|
|
|
// Copyright: (c) 1998 Robert Roebling
|
2004-05-23 16:53:33 -04:00
|
|
|
// Licence: wxWindows licence
|
1998-05-20 10:01:55 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef __GTKSTATICBITMAPH__
|
|
|
|
#define __GTKSTATICBITMAPH__
|
|
|
|
|
1999-06-22 04:36:29 -04:00
|
|
|
#include "wx/icon.h"
|
1998-05-20 10:01:55 -04:00
|
|
|
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
// wxStaticBitmap
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
|
2005-08-02 18:58:06 -04:00
|
|
|
class WXDLLIMPEXP_CORE wxStaticBitmap : public wxStaticBitmapBase
|
1998-05-28 18:05:55 -04:00
|
|
|
{
|
1999-06-21 17:29:40 -04: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);
|
|
|
|
|
2001-06-26 16:59:19 -04:00
|
|
|
virtual void SetIcon(const wxIcon& icon) { SetBitmap( icon ); }
|
1998-05-28 18:05:55 -04:00
|
|
|
virtual void SetBitmap( const wxBitmap& bitmap );
|
2001-06-26 16:59:19 -04:00
|
|
|
virtual wxBitmap GetBitmap() const { return m_bitmap; }
|
1999-06-21 17:29:40 -04:00
|
|
|
|
|
|
|
// for compatibility with wxMSW
|
2001-06-26 16:59:19 -04:00
|
|
|
wxIcon GetIcon() const
|
1999-06-28 18:06:24 -04:00
|
|
|
{
|
|
|
|
// don't use wxDynamicCast, icons and bitmaps are really the same thing
|
|
|
|
// in wxGTK
|
|
|
|
return (const wxIcon &)m_bitmap;
|
|
|
|
}
|
1999-06-21 17:29:40 -04:00
|
|
|
|
2004-05-06 13:26:25 -04:00
|
|
|
static wxVisualAttributes
|
|
|
|
GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
|
2006-01-22 21:28:01 -05:00
|
|
|
|
1999-06-21 17:29:40 -04:00
|
|
|
private:
|
|
|
|
wxBitmap m_bitmap;
|
1998-05-28 18:05:55 -04:00
|
|
|
|
2015-04-23 07:49:01 -04:00
|
|
|
wxDECLARE_DYNAMIC_CLASS(wxStaticBitmap);
|
2001-06-26 16:59:19 -04:00
|
|
|
};
|
1999-06-14 19:04:05 -04:00
|
|
|
|
1998-05-20 10:01:55 -04:00
|
|
|
#endif // __GTKSTATICBITMAPH__
|