]> git.saurik.com Git - wxWidgets.git/blob - include/wx/richtext/richtextmarginspage.h
Add wxActivateEvent::GetActivationReason().
[wxWidgets.git] / include / wx / richtext / richtextmarginspage.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/richtext/richtextmarginspage.h
3 // Purpose:
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 20/10/2010 10:27:34
7 // RCS-ID:
8 // Copyright: (c) Julian Smart
9 // Licence:
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _RICHTEXTMARGINSPAGE_H_
13 #define _RICHTEXTMARGINSPAGE_H_
14
15
16 /*!
17 * Includes
18 */
19
20 #include "wx/richtext/richtextdialogpage.h"
21
22 ////@begin includes
23 #include "wx/statline.h"
24 ////@end includes
25
26 /*!
27 * Forward declarations
28 */
29
30 ////@begin forward declarations
31 ////@end forward declarations
32
33 /*!
34 * Control identifiers
35 */
36
37 ////@begin control identifiers
38 #define SYMBOL_WXRICHTEXTMARGINSPAGE_STYLE wxTAB_TRAVERSAL
39 #define SYMBOL_WXRICHTEXTMARGINSPAGE_TITLE wxEmptyString
40 #define SYMBOL_WXRICHTEXTMARGINSPAGE_IDNAME ID_WXRICHTEXTMARGINSPAGE
41 #define SYMBOL_WXRICHTEXTMARGINSPAGE_SIZE wxSize(400, 300)
42 #define SYMBOL_WXRICHTEXTMARGINSPAGE_POSITION wxDefaultPosition
43 ////@end control identifiers
44
45
46 /*!
47 * wxRichTextMarginsPage class declaration
48 */
49
50 class WXDLLIMPEXP_RICHTEXT wxRichTextMarginsPage: public wxRichTextDialogPage
51 {
52 DECLARE_DYNAMIC_CLASS( wxRichTextMarginsPage )
53 DECLARE_EVENT_TABLE()
54 DECLARE_HELP_PROVISION()
55
56 public:
57 /// Constructors
58 wxRichTextMarginsPage();
59 wxRichTextMarginsPage( wxWindow* parent, wxWindowID id = SYMBOL_WXRICHTEXTMARGINSPAGE_IDNAME, const wxPoint& pos = SYMBOL_WXRICHTEXTMARGINSPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTMARGINSPAGE_SIZE, long style = SYMBOL_WXRICHTEXTMARGINSPAGE_STYLE );
60
61 /// Creation
62 bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WXRICHTEXTMARGINSPAGE_IDNAME, const wxPoint& pos = SYMBOL_WXRICHTEXTMARGINSPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTMARGINSPAGE_SIZE, long style = SYMBOL_WXRICHTEXTMARGINSPAGE_STYLE );
63
64 /// Destructor
65 ~wxRichTextMarginsPage();
66
67 /// Initialises member variables
68 void Init();
69
70 /// Creates the controls and sizers
71 void CreateControls();
72
73 /// Gets the attributes from the formatting dialog
74 wxRichTextAttr* GetAttributes();
75
76 /// Data transfer
77 virtual bool TransferDataToWindow();
78 virtual bool TransferDataFromWindow();
79
80 ////@begin wxRichTextMarginsPage event handler declarations
81
82 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_LEFT_MARGIN
83 void OnRichtextLeftMarginUpdate( wxUpdateUIEvent& event );
84
85 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_RIGHT_MARGIN
86 void OnRichtextRightMarginUpdate( wxUpdateUIEvent& event );
87
88 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_TOP_MARGIN
89 void OnRichtextTopMarginUpdate( wxUpdateUIEvent& event );
90
91 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_BOTTOM_MARGIN
92 void OnRichtextBottomMarginUpdate( wxUpdateUIEvent& event );
93
94 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_LEFT_PADDING
95 void OnRichtextLeftPaddingUpdate( wxUpdateUIEvent& event );
96
97 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_RIGHT_PADDING
98 void OnRichtextRightPaddingUpdate( wxUpdateUIEvent& event );
99
100 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_TOP_PADDING
101 void OnRichtextTopPaddingUpdate( wxUpdateUIEvent& event );
102
103 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_BOTTOM_PADDING
104 void OnRichtextBottomPaddingUpdate( wxUpdateUIEvent& event );
105
106 ////@end wxRichTextMarginsPage event handler declarations
107
108 ////@begin wxRichTextMarginsPage member function declarations
109
110 /// Retrieves bitmap resources
111 wxBitmap GetBitmapResource( const wxString& name );
112
113 /// Retrieves icon resources
114 wxIcon GetIconResource( const wxString& name );
115 ////@end wxRichTextMarginsPage member function declarations
116
117 /// Should we show tooltips?
118 static bool ShowToolTips();
119
120 ////@begin wxRichTextMarginsPage member variables
121 wxCheckBox* m_leftMarginCheckbox;
122 wxTextCtrl* m_marginLeft;
123 wxComboBox* m_unitsMarginLeft;
124 wxCheckBox* m_rightMarginCheckbox;
125 wxTextCtrl* m_marginRight;
126 wxComboBox* m_unitsMarginRight;
127 wxCheckBox* m_topMarginCheckbox;
128 wxTextCtrl* m_marginTop;
129 wxComboBox* m_unitsMarginTop;
130 wxCheckBox* m_bottomMarginCheckbox;
131 wxTextCtrl* m_marginBottom;
132 wxComboBox* m_unitsMarginBottom;
133 wxCheckBox* m_leftPaddingCheckbox;
134 wxTextCtrl* m_paddingLeft;
135 wxComboBox* m_unitsPaddingLeft;
136 wxCheckBox* m_rightPaddingCheckbox;
137 wxTextCtrl* m_paddingRight;
138 wxComboBox* m_unitsPaddingRight;
139 wxCheckBox* m_topPaddingCheckbox;
140 wxTextCtrl* m_paddingTop;
141 wxComboBox* m_unitsPaddingTop;
142 wxCheckBox* m_bottomPaddingCheckbox;
143 wxTextCtrl* m_paddingBottom;
144 wxComboBox* m_unitsPaddingBottom;
145 /// Control identifiers
146 enum {
147 ID_WXRICHTEXTMARGINSPAGE = 10750,
148 ID_RICHTEXT_LEFT_MARGIN_CHECKBOX = 10751,
149 ID_RICHTEXT_LEFT_MARGIN = 10752,
150 ID_RICHTEXT_LEFT_MARGIN_UNITS = 10753,
151 ID_RICHTEXT_RIGHT_MARGIN_CHECKBOX = 10754,
152 ID_RICHTEXT_RIGHT_MARGIN = 10755,
153 ID_RICHTEXT_RIGHT_MARGIN_UNITS = 10756,
154 ID_RICHTEXT_TOP_MARGIN_CHECKBOX = 10757,
155 ID_RICHTEXT_TOP_MARGIN = 10758,
156 ID_RICHTEXT_TOP_MARGIN_UNITS = 10759,
157 ID_RICHTEXT_BOTTOM_MARGIN_CHECKBOX = 10760,
158 ID_RICHTEXT_BOTTOM_MARGIN = 10761,
159 ID_RICHTEXT_BOTTOM_MARGIN_UNITS = 10762,
160 ID_RICHTEXT_LEFT_PADDING_CHECKBOX = 10763,
161 ID_RICHTEXT_LEFT_PADDING = 10764,
162 ID_RICHTEXT_LEFT_PADDING_UNITS = 10765,
163 ID_RICHTEXT_RIGHT_PADDING_CHECKBOX = 10766,
164 ID_RICHTEXT_RIGHT_PADDING = 10767,
165 ID_RICHTEXT_RIGHT_PADDING_UNITS = 10768,
166 ID_RICHTEXT_TOP_PADDING_CHECKBOX = 10769,
167 ID_RICHTEXT_TOP_PADDING = 10770,
168 ID_RICHTEXT_TOP_PADDING_UNITS = 10771,
169 ID_RICHTEXT_BOTTOM_PADDING_CHECKBOX = 10772,
170 ID_RICHTEXT_BOTTOM_PADDING = 10773,
171 ID_RICHTEXT_BOTTOM_PADDING_UNITS = 10774
172 };
173 ////@end wxRichTextMarginsPage member variables
174
175 bool m_ignoreUpdates;
176 };
177
178 #endif
179 // _RICHTEXTMARGINSPAGE_H_