]> git.saurik.com Git - wxWidgets.git/blob - src/common/radiobtncmn.cpp
Always link with expat in monolithic build.
[wxWidgets.git] / src / common / radiobtncmn.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/common/radiobtncmn.cpp
3 // Purpose: wxRadioButton common code
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 04/01/98
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 // ============================================================================
13 // declarations
14 // ============================================================================
15
16 // ----------------------------------------------------------------------------
17 // headers
18 // ----------------------------------------------------------------------------
19
20 // For compilers that support precompilation, includes "wx.h".
21 #include "wx/wxprec.h"
22
23 #ifdef __BORLANDC__
24 #pragma hdrstop
25 #endif
26
27 #if wxUSE_RADIOBTN
28
29 #include "wx/radiobut.h"
30
31 #ifndef WX_PRECOMP
32 #include "wx/settings.h"
33 #include "wx/dcscreen.h"
34 #endif
35
36 extern WXDLLEXPORT_DATA(const char) wxRadioButtonNameStr[] = "radioButton";
37 extern WXDLLEXPORT_DATA(const char) wxBitmapRadioButtonNameStr[] = "radioButton";
38
39 // ----------------------------------------------------------------------------
40 // XTI
41 // ----------------------------------------------------------------------------
42
43 wxDEFINE_FLAGS( wxRadioButtonStyle )
44 wxBEGIN_FLAGS( wxRadioButtonStyle )
45 // new style border flags, we put them first to
46 // use them for streaming out
47 wxFLAGS_MEMBER(wxBORDER_SIMPLE)
48 wxFLAGS_MEMBER(wxBORDER_SUNKEN)
49 wxFLAGS_MEMBER(wxBORDER_DOUBLE)
50 wxFLAGS_MEMBER(wxBORDER_RAISED)
51 wxFLAGS_MEMBER(wxBORDER_STATIC)
52 wxFLAGS_MEMBER(wxBORDER_NONE)
53
54 // old style border flags
55 wxFLAGS_MEMBER(wxSIMPLE_BORDER)
56 wxFLAGS_MEMBER(wxSUNKEN_BORDER)
57 wxFLAGS_MEMBER(wxDOUBLE_BORDER)
58 wxFLAGS_MEMBER(wxRAISED_BORDER)
59 wxFLAGS_MEMBER(wxSTATIC_BORDER)
60 wxFLAGS_MEMBER(wxBORDER)
61
62 // standard window styles
63 wxFLAGS_MEMBER(wxTAB_TRAVERSAL)
64 wxFLAGS_MEMBER(wxCLIP_CHILDREN)
65 wxFLAGS_MEMBER(wxTRANSPARENT_WINDOW)
66 wxFLAGS_MEMBER(wxWANTS_CHARS)
67 wxFLAGS_MEMBER(wxFULL_REPAINT_ON_RESIZE)
68 wxFLAGS_MEMBER(wxALWAYS_SHOW_SB )
69 wxFLAGS_MEMBER(wxVSCROLL)
70 wxFLAGS_MEMBER(wxHSCROLL)
71
72 wxFLAGS_MEMBER(wxRB_GROUP)
73 wxEND_FLAGS( wxRadioButtonStyle )
74
75 wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxRadioButton, wxControl, "wx/radiobut.h")
76
77 wxBEGIN_PROPERTIES_TABLE(wxRadioButton)
78 wxEVENT_PROPERTY( Click, wxEVT_COMMAND_RADIOBUTTON_SELECTED, wxCommandEvent )
79 wxPROPERTY( Font, wxFont, SetFont, GetFont , wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, \
80 wxT("Helpstring"), wxT("group"))
81 wxPROPERTY( Label,wxString, SetLabel, GetLabel, wxString(), 0 /*flags*/, \
82 wxT("Helpstring"), wxT("group") )
83 wxPROPERTY( Value,bool, SetValue, GetValue, wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, \
84 wxT("Helpstring"), wxT("group") )
85 wxPROPERTY_FLAGS( WindowStyle, wxRadioButtonStyle, long, SetWindowStyleFlag, \
86 GetWindowStyleFlag, wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, \
87 wxT("Helpstring"), wxT("group")) // style
88 wxEND_PROPERTIES_TABLE()
89
90 wxEMPTY_HANDLERS_TABLE(wxRadioButton)
91
92 wxCONSTRUCTOR_6( wxRadioButton, wxWindow*, Parent, wxWindowID, Id, \
93 wxString, Label, wxPoint, Position, wxSize, Size, long, WindowStyle )
94
95
96 #endif // wxUSE_RADIOBTN