1 /* 2 Copyright (C) 2020-2021, Dirk Krause 3 SPDX-License-Identifier: BSD-3-Clause 4 */ 5 6 /* 7 WARNING: This file was generated by the dkct program (see 8 http://dktools.sourceforge.net/ for details). 9 Changes you make here will be lost if dkct is run again! 10 You should modify the original source and run dkct on it. 11 Original source: WxdkdrawDlgOptionsScreen.wxc 12 */ 13 14 /** @file WxdkdrawDlgOptionsScreen.h Header file for the WxdkdrawDlgOptionsScreen module. 15 */ 16 17 #ifndef WXDKDRAWDLGOPTIONSSCREEN_H_INCLUDED 18 /** Avoid multiple inclusions. */ 19 #define WXDKDRAWDLGOPTIONSSCREEN_H_INCLUDED 1 20 21 22 #ifndef WXDKDRAW_H_INCLUDED 23 #include <wxdkdraw/wxdkdraw.h> 24 #endif 25 26 #ifndef WXDKDRAWFRAME_H_INCLUDED 27 #include <wxdkdraw/WxdkdrawFrame.h> 28 #endif 29 30 31 /** Dialog to change dot details. 32 */ 33 class WxdkdrawDlgOptionsScreen : public wxDialog 34 { 35 private: 36 37 /** Events to process. 38 */ 39 #if wxCHECK_VERSION(3,0,0) 40 wxDECLARE_EVENT_TABLE(); 41 #else 42 DECLARE_EVENT_TABLE() 43 #endif 44 45 /** Flag: GUI ok. 46 */ 47 bool dkctGUILayoutOK; 48 49 /** GUI element sizerHorizontal. 50 */ 51 wxBoxSizer *sizerHorizontal; 52 53 /** GUI element sizerVertical. 54 */ 55 wxBoxSizer *sizerVertical; 56 57 /** GUI element sizerContents. 58 */ 59 wxGridBagSizer *sizerContents; 60 61 /** GUI element sizerButtons. 62 */ 63 wxStdDialogButtonSizer *sizerButtons; 64 65 /** GUI element lTexts. 66 */ 67 wxStaticText *lTexts; 68 69 /** GUI element cbTexts. 70 */ 71 wxCheckBox *cbTexts; 72 73 /** GUI element lSplines. 74 */ 75 wxStaticText *lSplines; 76 77 /** GUI element lSubsegs. 78 */ 79 wxStaticText *lSubsegs; 80 81 /** GUI element spSubsegs. 82 */ 83 wxSpinCtrl *spSubsegs; 84 85 /** GUI element lPointMoveOps. 86 */ 87 wxStaticText *lPointMoveOps; 88 89 /** GUI element cbPointMoveOps. 90 */ 91 wxCheckBox *cbPointMoveOps; 92 93 /** GUI element buttonOK. 94 */ 95 wxButton *buttonOK; 96 97 /** GUI element buttonCancel. 98 */ 99 wxButton *buttonCancel; 100 101 102 protected: 103 104 /** Red colour for group titles. 105 */ 106 wxColour m_oColourRed; 107 108 /** Parent frame. 109 */ 110 WxdkdrawFrame *m_pParent; 111 112 /** Drawing control to refresh on changes. 113 */ 114 wxControl *m_pControl; 115 116 /** Entire drawing. 117 */ 118 Wxd_drawing_t *m_pDrw; 119 120 /** Localized text fragments. 121 */ 122 wxChar const * const *m_sTexts; 123 124 /** Address of subsegments variable. 125 */ 126 int *m_pSubsegs; 127 128 /** Address of exact fonts variable. 129 */ 130 int *m_pExact; 131 132 /** Address of variable for markup reduction. 133 */ 134 int *m_pReduceMarkup; 135 136 /** Initial value for number of subsegments. 137 */ 138 int m_iSubsegments; 139 140 /** Initial value for exact font flag. 141 */ 142 int m_iExact; 143 144 /** Initial value for markup reduction. 145 */ 146 int m_iReduceMarkup; 147 148 public: 149 150 /** Control events. 151 */ 152 enum { 153 WXD_ID_SUBSEGS = (wxID_HIGHEST + 1), /**< Subsegs changed. */ 154 WXD_ID_EXACT , /**< Use exact fonts. */ 155 WXD_ID_POINT_OPS , /**< Reduce markup. */ 156 }; 157 158 /** Constructor. 159 @param pParent Parent frame (programs main window). 160 @param pControl Drawing control. 161 @param pDrw Drawing. 162 @param pSubsegs Address of sub-segments variable. 163 @param pExact Address of exact font variables. 164 @param pReduce Address of variable to reduce markup. 165 @param pTexts Localized text fragments. 166 */ 167 WxdkdrawDlgOptionsScreen( 168 WxdkdrawFrame *pParent, 169 wxControl *pControl, 170 Wxd_drawing_t *pDrw, 171 int *pSubsegs, 172 int *pExact, 173 int *pReduce, 174 wxChar const * const *pTexts 175 ); 176 177 /** OK button handler. 178 @param event Event to process. 179 */ 180 void 181 OnOK(wxCommandEvent & event); 182 183 /** Cancel button handler. 184 @param event Event to process. 185 */ 186 void 187 OnCancel(wxCommandEvent & event); 188 189 /** Subsegs spin control handler. 190 @param event Event to process. 191 */ 192 void 193 OnSubsegs(wxSpinEvent & event); 194 195 /** Handler for checkbox change. 196 @param event Event to process. 197 */ 198 void 199 OnFontExact(wxCommandEvent & event); 200 201 /** Handler for reduce markup checkbox change. 202 @param event Event to process. 203 */ 204 void 205 OnMarkupReduce(wxCommandEvent & event); 206 207 }; 208 209 210 211 212 213 #endif 214