]> git.saurik.com Git - wxWidgets.git/blob - include/wx/richtext/richtexttabspage.h
Applied #15226 wxRichTextCtrl: Implement setting properties with undo for objects...
[wxWidgets.git] / include / wx / richtext / richtexttabspage.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/richtext/richtexttabspage.h
3 // Purpose:
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 10/4/2006 8:03:20 AM
7 // Copyright: (c) Julian Smart
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _RICHTEXTTABSPAGE_H_
12 #define _RICHTEXTTABSPAGE_H_
13
14 /*!
15 * Includes
16 */
17
18 #include "wx/richtext/richtextdialogpage.h"
19
20 ////@begin includes
21 ////@end includes
22
23 /*!
24 * Forward declarations
25 */
26
27 ////@begin forward declarations
28 ////@end forward declarations
29
30 /*!
31 * Control identifiers
32 */
33
34 ////@begin control identifiers
35 #define SYMBOL_WXRICHTEXTTABSPAGE_STYLE wxRESIZE_BORDER|wxTAB_TRAVERSAL
36 #define SYMBOL_WXRICHTEXTTABSPAGE_TITLE wxEmptyString
37 #define SYMBOL_WXRICHTEXTTABSPAGE_IDNAME ID_RICHTEXTTABSPAGE
38 #define SYMBOL_WXRICHTEXTTABSPAGE_SIZE wxSize(400, 300)
39 #define SYMBOL_WXRICHTEXTTABSPAGE_POSITION wxDefaultPosition
40 ////@end control identifiers
41
42 /*!
43 * wxRichTextTabsPage class declaration
44 */
45
46 class WXDLLIMPEXP_RICHTEXT wxRichTextTabsPage: public wxRichTextDialogPage
47 {
48 DECLARE_DYNAMIC_CLASS( wxRichTextTabsPage )
49 DECLARE_EVENT_TABLE()
50 DECLARE_HELP_PROVISION()
51
52 public:
53 /// Constructors
54 wxRichTextTabsPage( );
55 wxRichTextTabsPage( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = SYMBOL_WXRICHTEXTTABSPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTTABSPAGE_SIZE, long style = SYMBOL_WXRICHTEXTTABSPAGE_STYLE );
56
57 /// Creation
58 bool Create( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = SYMBOL_WXRICHTEXTTABSPAGE_POSITION, const wxSize& size = SYMBOL_WXRICHTEXTTABSPAGE_SIZE, long style = SYMBOL_WXRICHTEXTTABSPAGE_STYLE );
59
60 /// Creates the controls and sizers
61 void CreateControls();
62
63 /// Initialise members
64 void Init();
65
66 /// Transfer data from/to window
67 virtual bool TransferDataFromWindow();
68 virtual bool TransferDataToWindow();
69
70 /// Sorts the tab array
71 virtual void SortTabs();
72
73 /// Gets the attributes associated with the main formatting dialog
74 wxRichTextAttr* GetAttributes();
75
76 ////@begin wxRichTextTabsPage event handler declarations
77
78 /// wxEVT_LISTBOX event handler for ID_RICHTEXTTABSPAGE_TABLIST
79 void OnTablistSelected( wxCommandEvent& event );
80
81 /// wxEVT_BUTTON event handler for ID_RICHTEXTTABSPAGE_NEW_TAB
82 void OnNewTabClick( wxCommandEvent& event );
83
84 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXTTABSPAGE_NEW_TAB
85 void OnNewTabUpdate( wxUpdateUIEvent& event );
86
87 /// wxEVT_BUTTON event handler for ID_RICHTEXTTABSPAGE_DELETE_TAB
88 void OnDeleteTabClick( wxCommandEvent& event );
89
90 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXTTABSPAGE_DELETE_TAB
91 void OnDeleteTabUpdate( wxUpdateUIEvent& event );
92
93 /// wxEVT_BUTTON event handler for ID_RICHTEXTTABSPAGE_DELETE_ALL_TABS
94 void OnDeleteAllTabsClick( wxCommandEvent& event );
95
96 /// wxEVT_UPDATE_UI event handler for ID_RICHTEXTTABSPAGE_DELETE_ALL_TABS
97 void OnDeleteAllTabsUpdate( wxUpdateUIEvent& event );
98
99 ////@end wxRichTextTabsPage event handler declarations
100
101 ////@begin wxRichTextTabsPage member function declarations
102
103 /// Retrieves bitmap resources
104 wxBitmap GetBitmapResource( const wxString& name );
105
106 /// Retrieves icon resources
107 wxIcon GetIconResource( const wxString& name );
108 ////@end wxRichTextTabsPage member function declarations
109
110 /// Should we show tooltips?
111 static bool ShowToolTips();
112
113 ////@begin wxRichTextTabsPage member variables
114 wxTextCtrl* m_tabEditCtrl;
115 wxListBox* m_tabListCtrl;
116 /// Control identifiers
117 enum {
118 ID_RICHTEXTTABSPAGE = 10200,
119 ID_RICHTEXTTABSPAGE_TABEDIT = 10213,
120 ID_RICHTEXTTABSPAGE_TABLIST = 10214,
121 ID_RICHTEXTTABSPAGE_NEW_TAB = 10201,
122 ID_RICHTEXTTABSPAGE_DELETE_TAB = 10202,
123 ID_RICHTEXTTABSPAGE_DELETE_ALL_TABS = 10203
124 };
125 ////@end wxRichTextTabsPage member variables
126
127 bool m_tabsPresent;
128 };
129
130 #endif
131 // _RICHTEXTTABSPAGE_H_