]> git.saurik.com Git - wxWidgets.git/blob - include/wx/richtext/richtextsizepage.h
Move msw configuration checking to chkconf.h
[wxWidgets.git] / include / wx / richtext / richtextsizepage.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/richtext/richtextsizepage.h
3 // Purpose:
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 20/10/2010 10:23:24
7 // RCS-ID:
8 // Copyright: (c) Julian Smart
9 // Licence:
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _RICHTEXTSIZEPAGE_H_
13 #define _RICHTEXTSIZEPAGE_H_
14
15 /*!
16 * Includes
17 */
18
19 #include "wx/richtext/richtextdialogpage.h"
20 #include "wx/sizer.h"
21
22 ////@begin includes
23 #include "wx/statline.h"
24 ////@end includes
25
26 /*!
27 * Forward declarations
28 */
29
30
31 /*!
32 * Control identifiers
33 */
34
35 ////@begin control identifiers
36 #define SYMBOL_WXRICHTEXTSIZEPAGE_STYLE wxTAB_TRAVERSAL
37 #define SYMBOL_WXRICHTEXTSIZEPAGE_TITLE wxEmptyString
38 #define SYMBOL_WXRICHTEXTSIZEPAGE_IDNAME ID_WXRICHTEXTSIZEPAGE
39 #define SYMBOL_WXRICHTEXTSIZEPAGE_SIZE wxSize(400, 300)
40 #define SYMBOL_WXRICHTEXTSIZEPAGE_POSITION wxDefaultPosition
41 ////@end control identifiers
42
43
44 /*!
45 * wxRichTextSizePage class declaration
46 */
47
48 class WXDLLIMPEXP_RICHTEXT wxRichTextSizePage: public wxRichTextDialogPage
49 {
50 DECLARE_DYNAMIC_CLASS( wxRichTextSizePage )
51 DECLARE_EVENT_TABLE()
52 DECLARE_HELP_PROVISION()
53
54 public:
55 /// Constructors
56 wxRichTextSizePage();
57 wxRichTextSizePage( wxWindow* parent, wxWindowID id = SYMBOL_WXRICHTEXTSIZEPAGE_IDNAME, const wxPoint& pos = SYMBOL_WXRICHTEXTSIZEPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTSIZEPAGE_SIZE, long style = SYMBOL_WXRICHTEXTSIZEPAGE_STYLE );
58
59 /// Creation
60 bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WXRICHTEXTSIZEPAGE_IDNAME, const wxPoint& pos = SYMBOL_WXRICHTEXTSIZEPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTSIZEPAGE_SIZE, long style = SYMBOL_WXRICHTEXTSIZEPAGE_STYLE );
61
62 /// Destructor
63 ~wxRichTextSizePage();
64
65 /// Initialises member variables
66 void Init();
67
68 /// Creates the controls and sizers
69 void CreateControls();
70
71 /// Gets the attributes from the formatting dialog
72 wxRichTextAttr* GetAttributes();
73
74 /// Data transfer
75 virtual bool TransferDataToWindow();
76 virtual bool TransferDataFromWindow();
77
78 /// Show/hide position controls
79 void ShowPositionControls(bool show);
80
81 /// Show/hide floating controls
82 void ShowFloatingControls(bool show);
83
84 ////@begin wxRichTextSizePage event handler declarations
85
86 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_WIDTH
87 void OnRichtextWidthUpdate( wxUpdateUIEvent& event );
88
89 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_HEIGHT
90 void OnRichtextHeightUpdate( wxUpdateUIEvent& event );
91
92 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_VERTICAL_ALIGNMENT_COMBOBOX
93 void OnRichtextVerticalAlignmentComboboxUpdate( wxUpdateUIEvent& event );
94
95 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXT_OFFSET
96 void OnRichtextOffsetUpdate( wxUpdateUIEvent& event );
97
98 /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RICHTEXT_PARA_UP
99 void OnRichtextParaUpClick( wxCommandEvent& event );
100
101 /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RICHTEXT_PARA_DOWN
102 void OnRichtextParaDownClick( wxCommandEvent& event );
103
104 ////@end wxRichTextSizePage event handler declarations
105
106 ////@begin wxRichTextSizePage member function declarations
107
108 /// Retrieves bitmap resources
109 wxBitmap GetBitmapResource( const wxString& name );
110
111 /// Retrieves icon resources
112 wxIcon GetIconResource( const wxString& name );
113 ////@end wxRichTextSizePage member function declarations
114
115 /// Should we show tooltips?
116 static bool ShowToolTips();
117
118 ////@begin wxRichTextSizePage member variables
119 wxBoxSizer* m_parentSizer;
120 wxBoxSizer* m_floatingControls;
121 wxComboBox* m_float;
122 wxCheckBox* m_widthCheckbox;
123 wxTextCtrl* m_width;
124 wxComboBox* m_unitsW;
125 wxCheckBox* m_heightCheckbox;
126 wxTextCtrl* m_height;
127 wxComboBox* m_unitsH;
128 wxBoxSizer* m_alignmentControls;
129 wxCheckBox* m_verticalAlignmentCheckbox;
130 wxComboBox* m_verticalAlignmentComboBox;
131 wxBoxSizer* m_positionControls;
132 wxBoxSizer* m_moveObjectParentSizer;
133 wxCheckBox* m_offsetYCheckbox;
134 wxTextCtrl* m_offset;
135 wxComboBox* m_unitsOffset;
136 wxBoxSizer* m_moveObjectSizer;
137 /// Control identifiers
138 enum {
139 ID_WXRICHTEXTSIZEPAGE = 10700,
140 ID_RICHTEXT_FLOATING_MODE = 10701,
141 ID_RICHTEXT_WIDTH_CHECKBOX = 10702,
142 ID_RICHTEXT_WIDTH = 10703,
143 ID_RICHTEXT_UNITS_W = 10704,
144 ID_RICHTEXT_HEIGHT_CHECKBOX = 10705,
145 ID_RICHTEXT_HEIGHT = 10706,
146 ID_RICHTEXT_UNITS_H = 10707,
147 ID_RICHTEXT_VERTICAL_ALIGNMENT_CHECKBOX = 10708,
148 ID_RICHTEXT_VERTICAL_ALIGNMENT_COMBOBOX = 10709,
149 ID_RICHTEXT_OFFSET_CHECKBOX = 10710,
150 ID_RICHTEXT_OFFSET = 10711,
151 ID_RICHTEXT_OFFSET_UNITS = 10712,
152 ID_RICHTEXT_PARA_UP = 10713,
153 ID_RICHTEXT_PARA_DOWN = 10714
154 };
155 ////@end wxRichTextSizePage member variables
156 };
157
158 #endif
159 // _RICHTEXTSIZEPAGE_H_