]> git.saurik.com Git - wxWidgets.git/blame - include/wx/mac/carbon/bmpbuttn.h
Simplify use of MacIsWindowScrollbar
[wxWidgets.git] / include / wx / mac / carbon / bmpbuttn.h
CommitLineData
8cf73271
SC
1/////////////////////////////////////////////////////////////////////////////
2// Name: bmpbuttn.h
3// Purpose: wxBitmapButton class
4// Author: Stefan Csomor
5// Modified by:
6// Created: 1998-01-01
7// RCS-ID: $Id$
8// Copyright: (c) Stefan Csomor
65571936 9// Licence: wxWindows licence
8cf73271
SC
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_BMPBUTTN_H_
13#define _WX_BMPBUTTN_H_
14
8cf73271
SC
15#include "wx/button.h"
16
63ec432b 17WXDLLEXPORT_DATA(extern const wxChar) wxButtonNameStr[];
8cf73271
SC
18
19#define wxDEFAULT_BUTTON_MARGIN 4
20
21class WXDLLEXPORT wxBitmapButton: public wxBitmapButtonBase
22{
23 DECLARE_DYNAMIC_CLASS(wxBitmapButton)
24
25public:
26 wxBitmapButton()
27 {
28 SetMargins(wxDEFAULT_BUTTON_MARGIN, wxDEFAULT_BUTTON_MARGIN);
29 }
30
31 wxBitmapButton(wxWindow *parent, wxWindowID id, const wxBitmap& bitmap,
32 const wxPoint& pos = wxDefaultPosition,
33 const wxSize& size = wxDefaultSize, long style = wxBU_AUTODRAW,
34 const wxValidator& validator = wxDefaultValidator,
35 const wxString& name = wxButtonNameStr)
36 {
37 Create(parent, id, bitmap, pos, size, style, validator, name);
38 }
39
40 bool Create(wxWindow *parent, wxWindowID id, const wxBitmap& bitmap,
41 const wxPoint& pos = wxDefaultPosition,
42 const wxSize& size = wxDefaultSize, long style = wxBU_AUTODRAW,
43 const wxValidator& validator = wxDefaultValidator,
44 const wxString& name = wxButtonNameStr);
45
46 virtual void SetBitmapLabel(const wxBitmap& bitmap);
47
8cf73271
SC
48protected:
49 virtual wxSize DoGetBestSize() const;
50};
51
52#endif
53 // _WX_BMPBUTTN_H_