/////////////////////////////////////////////////////////////////////////////
// Name: button.h
-// Purpose:
-// Author: Robert Roebling
-// Created: 01/02/97
-// Id:
-// Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
+// Purpose: wxButton class
+// Author: AUTHOR
+// Modified by:
+// Created: ??/??/98
+// RCS-ID: $Id$
+// Copyright: (c) AUTHOR
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-
-#ifndef __GTKBUTTONH__
-#define __GTKBUTTONH__
+#ifndef _WX_BUTTON_H_
+#define _WX_BUTTON_H_
#ifdef __GNUG__
-#pragma interface
+#pragma interface "button.h"
#endif
-#include "wx/defs.h"
-#include "wx/object.h"
-#include "wx/list.h"
#include "wx/control.h"
+#include "wx/gdicmn.h"
-//-----------------------------------------------------------------------------
-// classes
-//-----------------------------------------------------------------------------
-
-class wxButton;
-
-//-----------------------------------------------------------------------------
-// global data
-//-----------------------------------------------------------------------------
-
-extern const char *wxButtonNameStr;
+WXDLLEXPORT_DATA(extern const char*) wxButtonNameStr;
-//-----------------------------------------------------------------------------
-// wxButton
-//-----------------------------------------------------------------------------
-
-class wxButton: public wxControl
+// Pushbutton
+class WXDLLEXPORT wxButton: public wxControl
{
DECLARE_DYNAMIC_CLASS(wxButton)
-
- public:
-
- wxButton(void);
- wxButton( wxWindow *parent, wxWindowID id, const wxString &label,
- const wxPoint &pos = wxDefaultPosition, const wxSize &size = wxDefaultSize,
- long style = 0, const wxString &name = wxButtonNameStr );
- bool Create( wxWindow *parent, wxWindowID id, const wxString &label,
- const wxPoint &pos = wxDefaultPosition, const wxSize &size = wxDefaultSize,
- long style = 0, const wxString &name = wxButtonNameStr );
- void SetDefault(void);
- void SetLabel( const wxString &label );
- wxString GetLabel(void) const;
+ public:
+ inline wxButton() {}
+ inline wxButton(wxWindow *parent, wxWindowID id, const wxString& label,
+ const wxPoint& pos = wxDefaultPosition,
+ const wxSize& size = wxDefaultSize, long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxButtonNameStr)
+ {
+ Create(parent, id, label, pos, size, style, validator, name);
+ }
+
+ bool Create(wxWindow *parent, wxWindowID id, const wxString& label,
+ const wxPoint& pos = wxDefaultPosition,
+ const wxSize& size = wxDefaultSize, long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxButtonNameStr);
+
+ virtual void SetSize(int x, int y, int width, int height, int sizeFlags = wxSIZE_AUTO);
+ virtual void SetDefault();
+ virtual void SetLabel(const wxString& label);
+ virtual wxString GetLabel() const ;
+ virtual void Command(wxCommandEvent& event);
};
-#endif // __GTKBUTTONH__
+#endif
+ // _WX_BUTTON_H_