KiCad PCB EDA Suite
dialog_annotate_base.cpp
Go to the documentation of this file.
1 // C++ code generated with wxFormBuilder (version May 6 2016)
3 // http://www.wxformbuilder.org/
4 //
5 // PLEASE DO "NOT" EDIT THIS FILE!
7 
8 #include "dialog_annotate_base.h"
9 
11 
12 DIALOG_ANNOTATE_BASE::DIALOG_ANNOTATE_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
13 {
14  this->SetSizeHints( wxDefaultSize, wxDefaultSize );
15 
16  wxBoxSizer* bmainSizer;
17  bmainSizer = new wxBoxSizer( wxVERTICAL );
18 
19  wxBoxSizer* bupperSizer;
20  bupperSizer = new wxBoxSizer( wxVERTICAL );
21 
22  m_userMessage = new wxStaticText( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
23  m_userMessage->Wrap( 1 );
24  m_userMessage->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD, false, wxEmptyString ) );
25 
26  bupperSizer->Add( m_userMessage, 0, wxALL, 5 );
27 
28  m_staticTextScope = new wxStaticText( this, wxID_ANY, _("Scope"), wxDefaultPosition, wxDefaultSize, 0 );
29  m_staticTextScope->Wrap( -1 );
30  m_staticTextScope->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD, false, wxEmptyString ) );
31 
32  bupperSizer->Add( m_staticTextScope, 0, wxALL, 6 );
33 
34  wxBoxSizer* bscopeOptSizer;
35  bscopeOptSizer = new wxBoxSizer( wxVERTICAL );
36 
37  m_rbEntireSchematic = new wxRadioButton( this, ID_ENTIRE_SCHEMATIC, _("Use the &entire schematic"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
38  bscopeOptSizer->Add( m_rbEntireSchematic, 0, wxALL, 3 );
39 
40  m_rbCurrPage = new wxRadioButton( this, ID_CURRENT_PAGE, _("Use the current &page only"), wxDefaultPosition, wxDefaultSize, 0 );
41  bscopeOptSizer->Add( m_rbCurrPage, 0, wxALL, 3 );
42 
43  m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
44  bscopeOptSizer->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
45 
46  m_rbKeepAnnotation = new wxRadioButton( this, ID_KEEP_ANNOTATION, _("&Keep existing annotation"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
47  bscopeOptSizer->Add( m_rbKeepAnnotation, 0, wxALL, 3 );
48 
49  m_rbResetAnnotation = new wxRadioButton( this, ID_RESET_ANNOTATION, _("&Reset existing annotation"), wxDefaultPosition, wxDefaultSize, 0 );
50  bscopeOptSizer->Add( m_rbResetAnnotation, 0, wxALL, 3 );
51 
52  m_rbResetButLock = new wxRadioButton( this, ID_RESET_BUT_LOCK, _("R&eset, but do not swap any annotated multi-unit parts"), wxDefaultPosition, wxDefaultSize, 0 );
53  bscopeOptSizer->Add( m_rbResetButLock, 0, wxALL, 3 );
54 
55 
56  bupperSizer->Add( bscopeOptSizer, 0, wxEXPAND|wxLEFT, 25 );
57 
58  m_staticline2 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
59  bupperSizer->Add( m_staticline2, 0, wxEXPAND | wxALL, 5 );
60 
61  m_staticTextOrder = new wxStaticText( this, wxID_ANY, _("Annotation Order"), wxDefaultPosition, wxDefaultSize, 0 );
62  m_staticTextOrder->Wrap( -1 );
63  m_staticTextOrder->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD, false, wxEmptyString ) );
64 
65  bupperSizer->Add( m_staticTextOrder, 0, wxALL, 6 );
66 
67  wxBoxSizer* b_orderOptSizer;
68  b_orderOptSizer = new wxBoxSizer( wxVERTICAL );
69 
70  wxBoxSizer* bSizerXpos;
71  bSizerXpos = new wxBoxSizer( wxHORIZONTAL );
72 
73  m_rbSortBy_X_Position = new wxRadioButton( this, ID_SORT_BY_X_POSITION, _("Sort components by &X position"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
74  bSizerXpos->Add( m_rbSortBy_X_Position, 0, wxALL, 3 );
75 
76 
77  bSizerXpos->Add( 0, 0, 1, wxEXPAND, 5 );
78 
79  annotate_down_right_bitmap = new wxStaticBitmap( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, 0 );
80  bSizerXpos->Add( annotate_down_right_bitmap, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 12 );
81 
82 
83  b_orderOptSizer->Add( bSizerXpos, 0, wxEXPAND|wxRIGHT, 5 );
84 
85  wxBoxSizer* bSizerYpos;
86  bSizerYpos = new wxBoxSizer( wxHORIZONTAL );
87 
88  m_rbSortBy_Y_Position = new wxRadioButton( this, ID_SORT_BY_Y_POSITION, _("Sort components by &Y position"), wxDefaultPosition, wxDefaultSize, 0 );
89  bSizerYpos->Add( m_rbSortBy_Y_Position, 0, wxALL, 3 );
90 
91 
92  bSizerYpos->Add( 0, 0, 1, wxEXPAND, 5 );
93 
94  annotate_right_down_bitmap = new wxStaticBitmap( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, 0 );
95  bSizerYpos->Add( annotate_right_down_bitmap, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 12 );
96 
97 
98  b_orderOptSizer->Add( bSizerYpos, 0, wxEXPAND|wxRIGHT, 5 );
99 
100 
101  bupperSizer->Add( b_orderOptSizer, 0, wxEXPAND|wxLEFT, 25 );
102 
103  m_staticline5 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
104  bupperSizer->Add( m_staticline5, 0, wxEXPAND | wxALL, 5 );
105 
106  wxBoxSizer* bSizerAnnotAlgo;
107  bSizerAnnotAlgo = new wxBoxSizer( wxVERTICAL );
108 
109  m_staticTextAnnotateAlgo = new wxStaticText( this, wxID_ANY, _("Annotation Choice"), wxDefaultPosition, wxDefaultSize, 0 );
110  m_staticTextAnnotateAlgo->Wrap( -1 );
111  m_staticTextAnnotateAlgo->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD, false, wxEmptyString ) );
112 
113  bSizerAnnotAlgo->Add( m_staticTextAnnotateAlgo, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
114 
115  wxBoxSizer* bSizer1AlgoChoice;
116  bSizer1AlgoChoice = new wxBoxSizer( wxVERTICAL );
117 
118  wxBoxSizer* bSizerChoiceInc;
119  bSizerChoiceInc = new wxBoxSizer( wxHORIZONTAL );
120 
121  m_rbUseIncremental = new wxRadioButton( this, ID_SORT_BY_X_POSITION, _("Use first free number in schematic"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
122  bSizerChoiceInc->Add( m_rbUseIncremental, 0, wxALL, 3 );
123 
124 
125  bSizerChoiceInc->Add( 0, 0, 1, wxEXPAND, 5 );
126 
127 
128  bSizer1AlgoChoice->Add( bSizerChoiceInc, 0, wxEXPAND|wxRIGHT, 5 );
129 
130  wxBoxSizer* bSizerChoiceIncBySheet;
131  bSizerChoiceIncBySheet = new wxBoxSizer( wxHORIZONTAL );
132 
133  m_rbUseSheetNum = new wxRadioButton( this, wxID_ANY, _("Start to sheet number*100 and use first free number"), wxDefaultPosition, wxDefaultSize, 0 );
134  bSizerChoiceIncBySheet->Add( m_rbUseSheetNum, 0, wxALL, 3 );
135 
136 
137  bSizerChoiceIncBySheet->Add( 0, 0, 1, wxEXPAND, 5 );
138 
139 
140  bSizer1AlgoChoice->Add( bSizerChoiceIncBySheet, 1, wxEXPAND, 5 );
141 
142  wxBoxSizer* bSizerChoiceIncBySheetLarge;
143  bSizerChoiceIncBySheetLarge = new wxBoxSizer( wxHORIZONTAL );
144 
145  m_rbStartSheetNumLarge = new wxRadioButton( this, wxID_ANY, _("Start to sheet number*1000 and use first free number"), wxDefaultPosition, wxDefaultSize, 0 );
146  bSizerChoiceIncBySheetLarge->Add( m_rbStartSheetNumLarge, 0, wxALL, 3 );
147 
148 
149  bSizerChoiceIncBySheetLarge->Add( 0, 0, 1, wxEXPAND, 5 );
150 
151 
152  bSizer1AlgoChoice->Add( bSizerChoiceIncBySheetLarge, 1, wxEXPAND, 5 );
153 
154 
155  bSizerAnnotAlgo->Add( bSizer1AlgoChoice, 1, wxEXPAND|wxLEFT, 25 );
156 
157 
158  bupperSizer->Add( bSizerAnnotAlgo, 0, wxEXPAND|wxRIGHT, 5 );
159 
160  m_staticline4 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
161  bupperSizer->Add( m_staticline4, 0, wxEXPAND | wxALL, 5 );
162 
163  wxBoxSizer* bSizerDldOptions;
164  bSizerDldOptions = new wxBoxSizer( wxVERTICAL );
165 
166  m_staticTextDlgOpts = new wxStaticText( this, wxID_ANY, _("Dialog"), wxDefaultPosition, wxDefaultSize, 0 );
167  m_staticTextDlgOpts->Wrap( -1 );
168  m_staticTextDlgOpts->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD, false, wxEmptyString ) );
169 
170  bSizerDldOptions->Add( m_staticTextDlgOpts, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
171 
172  wxBoxSizer* bSizerDlgChoices;
173  bSizerDlgChoices = new wxBoxSizer( wxVERTICAL );
174 
175  wxBoxSizer* bSizerChoiceClose;
176  bSizerChoiceClose = new wxBoxSizer( wxHORIZONTAL );
177 
178  m_cbKeepDlgOpen = new wxCheckBox( this, wxID_ANY, _("Keep this dialog open"), wxDefaultPosition, wxDefaultSize, 0 );
179  bSizerChoiceClose->Add( m_cbKeepDlgOpen, 0, wxALL, 5 );
180 
181 
182  bSizerChoiceClose->Add( 0, 0, 1, wxEXPAND, 5 );
183 
184 
185  bSizerDlgChoices->Add( bSizerChoiceClose, 0, wxEXPAND|wxRIGHT, 5 );
186 
187  wxBoxSizer* bSizerChoiceSilentMode;
188  bSizerChoiceSilentMode = new wxBoxSizer( wxHORIZONTAL );
189 
190  m_cbAskForConfirmation = new wxCheckBox( this, wxID_ANY, _("Always ask for confirmation"), wxDefaultPosition, wxDefaultSize, 0 );
191  m_cbAskForConfirmation->SetValue(true);
192  bSizerChoiceSilentMode->Add( m_cbAskForConfirmation, 0, wxALL, 5 );
193 
194 
195  bSizerChoiceSilentMode->Add( 0, 0, 1, wxEXPAND, 5 );
196 
197 
198  bSizerDlgChoices->Add( bSizerChoiceSilentMode, 1, wxEXPAND, 5 );
199 
200 
201  bSizerDldOptions->Add( bSizerDlgChoices, 1, wxEXPAND|wxLEFT, 25 );
202 
203  m_staticline41 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
204  bSizerDldOptions->Add( m_staticline41, 0, wxEXPAND | wxALL, 5 );
205 
206 
207  bupperSizer->Add( bSizerDldOptions, 0, wxEXPAND|wxRIGHT, 5 );
208 
209  wxBoxSizer* bButtonsSizer;
210  bButtonsSizer = new wxBoxSizer( wxHORIZONTAL );
211 
212  m_btnClose = new wxButton( this, wxID_CANCEL, _("Close"), wxDefaultPosition, wxDefaultSize, 0 );
213  bButtonsSizer->Add( m_btnClose, 0, wxALL|wxEXPAND, 5 );
214 
215  m_btnClear = new wxButton( this, ID_CLEAR_ANNOTATION_CMP, _("Clear Annotation"), wxDefaultPosition, wxDefaultSize, 0 );
216  bButtonsSizer->Add( m_btnClear, 0, wxALL|wxEXPAND, 5 );
217 
218  m_btnApply = new wxButton( this, wxID_APPLY, _("Annotate"), wxDefaultPosition, wxDefaultSize, 0 );
219  bButtonsSizer->Add( m_btnApply, 0, wxALL|wxEXPAND, 5 );
220 
221 
222  bupperSizer->Add( bButtonsSizer, 0, wxALIGN_CENTER_HORIZONTAL, 6 );
223 
224 
225  bmainSizer->Add( bupperSizer, 1, wxALL|wxEXPAND, 6 );
226 
227 
228  this->SetSizer( bmainSizer );
229  this->Layout();
230  bmainSizer->Fit( this );
231 
232  // Connect Events
233  m_btnClose->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnCancelClick ), NULL, this );
234  m_btnClear->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnClearAnnotationCmpClick ), NULL, this );
235  m_btnApply->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnApplyClick ), NULL, this );
236 }
237 
239 {
240  // Disconnect Events
241  m_btnClose->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnCancelClick ), NULL, this );
242  m_btnClear->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnClearAnnotationCmpClick ), NULL, this );
243  m_btnApply->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_ANNOTATE_BASE::OnApplyClick ), NULL, this );
244 
245 }
wxStaticLine * m_staticline1
wxRadioButton * m_rbUseIncremental
#define ID_CLEAR_ANNOTATION_CMP
#define ID_ENTIRE_SCHEMATIC
#define ID_CURRENT_PAGE
wxRadioButton * m_rbSortBy_X_Position
#define ID_RESET_ANNOTATION
wxRadioButton * m_rbUseSheetNum
#define ID_RESET_BUT_LOCK
wxStaticLine * m_staticline5
Class DIALOG_SHIM may sit in the inheritance tree between wxDialog and any class written by wxFormBui...
Definition: dialog_shim.h:60
wxStaticText * m_staticTextDlgOpts
wxStaticLine * m_staticline41
wxStaticBitmap * annotate_right_down_bitmap
wxRadioButton * m_rbKeepAnnotation
virtual void OnApplyClick(wxCommandEvent &event)
wxRadioButton * m_rbSortBy_Y_Position
wxRadioButton * m_rbResetAnnotation
wxStaticLine * m_staticline4
wxRadioButton * m_rbEntireSchematic
wxCheckBox * m_cbAskForConfirmation
#define ID_SORT_BY_X_POSITION
wxStaticText * m_userMessage
wxStaticText * m_staticTextOrder
wxStaticLine * m_staticline2
wxStaticBitmap * annotate_down_right_bitmap
DIALOG_ANNOTATE_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Annotate Schematic"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
wxRadioButton * m_rbStartSheetNumLarge
wxRadioButton * m_rbCurrPage
#define ID_SORT_BY_Y_POSITION
wxStaticText * m_staticTextScope
virtual void OnCancelClick(wxCommandEvent &event)
#define ID_KEEP_ANNOTATION
wxStaticText * m_staticTextAnnotateAlgo
wxRadioButton * m_rbResetButLock
virtual void OnClearAnnotationCmpClick(wxCommandEvent &event)