1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Miscellaneous dialogs
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _STUDIO_DIALOGS_H_
13 #define _STUDIO_DIALOGS_H_
15 #if defined(__GNUG__) && !defined(__APPLE__)
20 #include <wx/notebook.h>
22 #include <wx/ogl/ogl.h> // base header of OGL, includes and adjusts wx/deprecated/setup.h
24 #if wxUSE_WX_RESOURCES
27 * Label editing dialog (about to become obsolete)
30 class csLabelEditingDialog
: public wxDialog
32 DECLARE_CLASS(csLabelEditingDialog
)
34 csLabelEditingDialog(wxWindow
* parent
);
36 void SetShapeLabel(const wxString
& label
);
37 inline wxString
GetShapeLabel() const { return m_label
; }
39 void OnOK(wxCommandEvent
& event
);
48 * Settings dialog (tabbed)
51 class csSettingsDialog
: public wxDialog
53 DECLARE_CLASS(csSettingsDialog
)
55 csSettingsDialog(wxWindow
* parent
);
57 void OnOK(wxCommandEvent
& event
);
59 virtual bool TransferDataToWindow();
60 virtual bool TransferDataFromWindow();
64 wxPanel
* m_generalSettings
;
65 wxPanel
* m_diagramSettings
;
66 wxNotebook
* m_notebook
;
71 #define ID_PROPERTY_NOTEBOOK 1000
72 #define ID_GENERAL_SETTINGS 1002
73 #define ID_DIAGRAM_SETTINGS 1003
76 * csGeneralShapePropertiesDialog
77 * Name, description etc.
80 class csGeneralShapePropertiesDialog
: public wxPanel
82 DECLARE_CLASS(csGeneralShapePropertiesDialog
)
84 csGeneralShapePropertiesDialog();
86 void SetShapeLabel(const wxString
& label
);
87 inline wxString
GetShapeLabel() const { return m_label
; }
96 * Shape properties dialog (tabbed)
99 class csShapePropertiesDialog
: public wxDialog
101 DECLARE_CLASS(csShapePropertiesDialog
)
103 csShapePropertiesDialog(wxWindow
* parent
, const wxString
& title
, wxPanel
* attributeDialog
, const wxString
& attributeDialogName
);
105 void OnOK(wxCommandEvent
& event
);
107 // Set some suitable defaults in the attribute dialogs (in the first instance,
108 // just set all wxChoices to the first element)
112 csGeneralShapePropertiesDialog
* GetGeneralPropertiesDialog() const { return m_generalPropertiesDialog
; }
117 // Attributes, specific to each shape
118 wxPanel
* m_attributeDialog
;
119 wxPanel
* m_alternativeAttributeDialog
;
121 // General properties, same for each shape, e.g. name/description
122 csGeneralShapePropertiesDialog
* m_generalPropertiesDialog
;
124 wxNotebook
* m_notebook
;
126 DECLARE_EVENT_TABLE()
129 #endif // wxUSE_WX_RESOURCES
131 #define ID_SHAPE_PROPERTY_NOTEBOOK 1000
133 //// Specific attribute-editing panel classes below here
136 * csThinRectangleDialog
139 class csThinRectangleDialog
: public wxPanel
141 DECLARE_CLASS(csThinRectangleDialog
)
143 csThinRectangleDialog();
145 DECLARE_EVENT_TABLE()
149 * csWideRectangleDialog
152 class csWideRectangleDialog
: public wxPanel
154 DECLARE_CLASS(csWideRectangleDialog
)
156 csWideRectangleDialog();
158 DECLARE_EVENT_TABLE()
165 class csTriangleDialog
: public wxPanel
167 DECLARE_CLASS(csTriangleDialog
)
171 DECLARE_EVENT_TABLE()
178 class csSemiCircleDialog
: public wxPanel
180 DECLARE_CLASS(csSemiCircleDialog
)
182 csSemiCircleDialog();
184 DECLARE_EVENT_TABLE()
191 class csCircleDialog
: public wxPanel
193 DECLARE_CLASS(csCircleDialog
)
197 DECLARE_EVENT_TABLE()
201 * csCircleShadowDialog
204 class csCircleShadowDialog
: public wxPanel
206 DECLARE_CLASS(csCircleShadowDialog
)
208 csCircleShadowDialog();
210 DECLARE_EVENT_TABLE()
217 class csOctagonDialog
: public wxPanel
219 DECLARE_CLASS(csOctagonDialog
)
223 DECLARE_EVENT_TABLE()
230 class csGroupDialog
: public wxPanel
232 DECLARE_CLASS(csGroupDialog
)
236 DECLARE_EVENT_TABLE()
243 class csTextBoxDialog
: public wxPanel
245 DECLARE_CLASS(csTextBoxDialog
)
249 DECLARE_EVENT_TABLE()
253 // _STUDIO_DIALOGS_H_