KiCad PCB EDA Suite
dialog_track_via_properties_base.cpp
Go to the documentation of this file.
1 // C++ code generated with wxFormBuilder (version Jun 17 2015)
3 // http://www.wxformbuilder.org/
4 //
5 // PLEASE DO "NOT" EDIT THIS FILE!
7 
9 
11 
13 
14 DIALOG_TRACK_VIA_PROPERTIES_BASE::DIALOG_TRACK_VIA_PROPERTIES_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
15 {
16  this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
17 
18  m_MainSizer = new wxBoxSizer( wxVERTICAL );
19 
20  m_sbCommonSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Common") ), wxHORIZONTAL );
21 
22  m_lockedCbox = new wxCheckBox( m_sbCommonSizer->GetStaticBox(), wxID_ANY, _("Locked"), wxDefaultPosition, wxDefaultSize, wxCHK_3STATE );
23  m_sbCommonSizer->Add( m_lockedCbox, 0, wxALL, 5 );
24 
25 
26  m_MainSizer->Add( m_sbCommonSizer, 1, wxEXPAND|wxALL, 5 );
27 
28  m_sbTrackSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Tracks") ), wxHORIZONTAL );
29 
30  wxFlexGridSizer* fgTrackLeftGridSizer;
31  fgTrackLeftGridSizer = new wxFlexGridSizer( 4, 3, 5, 5 );
32  fgTrackLeftGridSizer->SetFlexibleDirection( wxBOTH );
33  fgTrackLeftGridSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
34 
35  m_TrackStartXLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Start point X:"), wxDefaultPosition, wxDefaultSize, 0 );
36  m_TrackStartXLabel->Wrap( -1 );
37  fgTrackLeftGridSizer->Add( m_TrackStartXLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
38 
39  m_TrackStartXCtrl = new wxTextCtrl( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
40  m_TrackStartXCtrl->SetMaxLength( 0 );
41  fgTrackLeftGridSizer->Add( m_TrackStartXCtrl, 0, wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 );
42 
43  m_TrackStartXUnit = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
44  m_TrackStartXUnit->Wrap( -1 );
45  fgTrackLeftGridSizer->Add( m_TrackStartXUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
46 
47  m_TrackStartYLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Start point Y:"), wxDefaultPosition, wxDefaultSize, 0 );
48  m_TrackStartYLabel->Wrap( -1 );
49  fgTrackLeftGridSizer->Add( m_TrackStartYLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
50 
51  m_TrackStartYCtrl = new wxTextCtrl( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
52  m_TrackStartYCtrl->SetMaxLength( 0 );
53  fgTrackLeftGridSizer->Add( m_TrackStartYCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
54 
55  m_TrackStartYUnit = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
56  m_TrackStartYUnit->Wrap( -1 );
57  fgTrackLeftGridSizer->Add( m_TrackStartYUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
58 
59  m_TrackEndXLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("End point X:"), wxDefaultPosition, wxDefaultSize, 0 );
60  m_TrackEndXLabel->Wrap( -1 );
61  fgTrackLeftGridSizer->Add( m_TrackEndXLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
62 
63  m_TrackEndXCtrl = new wxTextCtrl( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
64  m_TrackEndXCtrl->SetMaxLength( 0 );
65  fgTrackLeftGridSizer->Add( m_TrackEndXCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
66 
67  m_TrackEndXUnit = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
68  m_TrackEndXUnit->Wrap( -1 );
69  fgTrackLeftGridSizer->Add( m_TrackEndXUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
70 
71  m_TrackEndYLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("End point Y:"), wxDefaultPosition, wxDefaultSize, 0 );
72  m_TrackEndYLabel->Wrap( -1 );
73  fgTrackLeftGridSizer->Add( m_TrackEndYLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
74 
75  m_TrackEndYCtrl = new wxTextCtrl( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
76  m_TrackEndYCtrl->SetMaxLength( 0 );
77  fgTrackLeftGridSizer->Add( m_TrackEndYCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
78 
79  m_TrackEndYUnit = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
80  m_TrackEndYUnit->Wrap( -1 );
81  fgTrackLeftGridSizer->Add( m_TrackEndYUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
82 
83 
84  m_sbTrackSizer->Add( fgTrackLeftGridSizer, 1, wxEXPAND, 5 );
85 
86  m_trackStaticLine = new wxStaticLine( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_VERTICAL );
87  m_sbTrackSizer->Add( m_trackStaticLine, 0, wxEXPAND | wxALL, 5 );
88 
89  wxFlexGridSizer* fgTrackRightSizer;
90  fgTrackRightSizer = new wxFlexGridSizer( 0, 3, 5, 5 );
91  fgTrackRightSizer->SetFlexibleDirection( wxBOTH );
92  fgTrackRightSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
93 
94  m_TrackWidthLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Width:"), wxDefaultPosition, wxDefaultSize, 0 );
95  m_TrackWidthLabel->Wrap( -1 );
96  fgTrackRightSizer->Add( m_TrackWidthLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxLEFT, 5 );
97 
98  m_TrackWidthCtrl = new wxTextCtrl( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
99  m_TrackWidthCtrl->SetMaxLength( 0 );
100  fgTrackRightSizer->Add( m_TrackWidthCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
101 
102  m_TrackWidthUnit = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
103  m_TrackWidthUnit->Wrap( -1 );
104  fgTrackRightSizer->Add( m_TrackWidthUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
105 
106 
107  fgTrackRightSizer->Add( 0, 0, 1, wxEXPAND, 5 );
108 
109  m_trackNetclass = new wxCheckBox( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Use net class width"), wxDefaultPosition, wxDefaultSize, 0 );
110  fgTrackRightSizer->Add( m_trackNetclass, 0, wxBOTTOM|wxTOP, 5 );
111 
112 
113  fgTrackRightSizer->Add( 0, 0, 1, wxEXPAND, 5 );
114 
115  m_TrackLayerLabel = new wxStaticText( m_sbTrackSizer->GetStaticBox(), wxID_ANY, _("Layer:"), wxDefaultPosition, wxDefaultSize, 0 );
116  m_TrackLayerLabel->Wrap( -1 );
117  fgTrackRightSizer->Add( m_TrackLayerLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
118 
119  m_TrackLayerCtrl = new PCB_LAYER_BOX_SELECTOR( m_sbTrackSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
120  fgTrackRightSizer->Add( m_TrackLayerCtrl, 0, wxALIGN_CENTER_VERTICAL, 5 );
121 
122 
123  fgTrackRightSizer->Add( 0, 0, 1, wxEXPAND, 5 );
124 
125 
126  m_sbTrackSizer->Add( fgTrackRightSizer, 0, wxEXPAND, 5 );
127 
128 
129  m_MainSizer->Add( m_sbTrackSizer, 0, wxALL|wxEXPAND, 5 );
130 
131  m_sbViaSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Vias") ), wxHORIZONTAL );
132 
133  wxFlexGridSizer* fgViaLeftSizer;
134  fgViaLeftSizer = new wxFlexGridSizer( 2, 3, 5, 5 );
135  fgViaLeftSizer->SetFlexibleDirection( wxBOTH );
136  fgViaLeftSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
137 
138  m_ViaXLabel = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Position X:"), wxDefaultPosition, wxDefaultSize, 0 );
139  m_ViaXLabel->Wrap( -1 );
140  fgViaLeftSizer->Add( m_ViaXLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
141 
142  m_ViaXCtrl = new wxTextCtrl( m_sbViaSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
143  m_ViaXCtrl->SetMaxLength( 0 );
144  fgViaLeftSizer->Add( m_ViaXCtrl, 0, wxEXPAND, 5 );
145 
146  m_ViaXUnit = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
147  m_ViaXUnit->Wrap( -1 );
148  fgViaLeftSizer->Add( m_ViaXUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
149 
150  m_ViaYLabel = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Position Y:"), wxDefaultPosition, wxDefaultSize, 0 );
151  m_ViaYLabel->Wrap( -1 );
152  fgViaLeftSizer->Add( m_ViaYLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
153 
154  m_ViaYCtrl = new wxTextCtrl( m_sbViaSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
155  m_ViaYCtrl->SetMaxLength( 0 );
156  fgViaLeftSizer->Add( m_ViaYCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
157 
158  m_ViaYUnit = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
159  m_ViaYUnit->Wrap( -1 );
160  fgViaLeftSizer->Add( m_ViaYUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
161 
162 
163  m_sbViaSizer->Add( fgViaLeftSizer, 1, wxEXPAND|wxALL, 5 );
164 
165  m_viaStaticLine = new wxStaticLine( m_sbViaSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_VERTICAL );
166  m_sbViaSizer->Add( m_viaStaticLine, 0, wxEXPAND | wxALL, 5 );
167 
168  wxFlexGridSizer* fgViaRightSizer;
169  fgViaRightSizer = new wxFlexGridSizer( 0, 3, 5, 5 );
170  fgViaRightSizer->SetFlexibleDirection( wxBOTH );
171  fgViaRightSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
172 
173  m_ViaDiameterLabel = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Diameter:"), wxDefaultPosition, wxDefaultSize, 0 );
174  m_ViaDiameterLabel->Wrap( -1 );
175  fgViaRightSizer->Add( m_ViaDiameterLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
176 
177  m_ViaDiameterCtrl = new wxTextCtrl( m_sbViaSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
178  m_ViaDiameterCtrl->SetMaxLength( 0 );
179  fgViaRightSizer->Add( m_ViaDiameterCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
180 
181  m_ViaDiameterUnit = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
182  m_ViaDiameterUnit->Wrap( -1 );
183  fgViaRightSizer->Add( m_ViaDiameterUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
184 
185  m_ViaDrillLabel = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Drill:"), wxDefaultPosition, wxDefaultSize, 0 );
186  m_ViaDrillLabel->Wrap( -1 );
187  fgViaRightSizer->Add( m_ViaDrillLabel, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
188 
189  m_ViaDrillCtrl = new wxTextCtrl( m_sbViaSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
190  m_ViaDrillCtrl->SetMaxLength( 0 );
191  fgViaRightSizer->Add( m_ViaDrillCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
192 
193  m_ViaDrillUnit = new wxStaticText( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 );
194  m_ViaDrillUnit->Wrap( -1 );
195  fgViaRightSizer->Add( m_ViaDrillUnit, 0, wxALIGN_CENTER_VERTICAL, 5 );
196 
197 
198  fgViaRightSizer->Add( 0, 0, 1, wxEXPAND, 5 );
199 
200  m_viaNetclass = new wxCheckBox( m_sbViaSizer->GetStaticBox(), wxID_ANY, _("Use net class size"), wxDefaultPosition, wxDefaultSize, 0 );
201  fgViaRightSizer->Add( m_viaNetclass, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxTOP, 5 );
202 
203 
204  fgViaRightSizer->Add( 0, 0, 1, wxEXPAND, 5 );
205 
206 
207  m_sbViaSizer->Add( fgViaRightSizer, 1, wxEXPAND|wxALL, 5 );
208 
209 
210  m_MainSizer->Add( m_sbViaSizer, 0, wxALL|wxEXPAND, 5 );
211 
212 
213  m_MainSizer->Add( 0, 0, 1, wxEXPAND, 5 );
214 
215  m_StdButtons = new wxStdDialogButtonSizer();
216  m_StdButtonsOK = new wxButton( this, wxID_OK );
217  m_StdButtons->AddButton( m_StdButtonsOK );
218  m_StdButtonsCancel = new wxButton( this, wxID_CANCEL );
219  m_StdButtons->AddButton( m_StdButtonsCancel );
220  m_StdButtons->Realize();
221 
222  m_MainSizer->Add( m_StdButtons, 0, wxALL|wxEXPAND, 5 );
223 
224 
225  this->SetSizer( m_MainSizer );
226  this->Layout();
227 
228  this->Centre( wxBOTH );
229 
230  // Connect Events
231  this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onClose ) );
232  this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::OnInitDlg ) );
233  m_trackNetclass->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onTrackNetclassCheck ), NULL, this );
234  m_viaNetclass->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onViaNetclassCheck ), NULL, this );
235  m_StdButtonsCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onCancelClick ), NULL, this );
236  m_StdButtonsOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onOkClick ), NULL, this );
237 }
238 
240 {
241  // Disconnect Events
242  this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onClose ) );
243  this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::OnInitDlg ) );
244  m_trackNetclass->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onTrackNetclassCheck ), NULL, this );
245  m_viaNetclass->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onViaNetclassCheck ), NULL, this );
246  m_StdButtonsCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onCancelClick ), NULL, this );
247  m_StdButtonsOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TRACK_VIA_PROPERTIES_BASE::onOkClick ), NULL, this );
248 
249 }
virtual void onOkClick(wxCommandEvent &event)
Class to display a pcb layer list in a wxBitmapComboBox.
Class DIALOG_SHIM may sit in the inheritance tree between wxDialog and any class written by wxFormBui...
Definition: dialog_shim.h:60
virtual void onTrackNetclassCheck(wxCommandEvent &event)
virtual void onCancelClick(wxCommandEvent &event)
DIALOG_TRACK_VIA_PROPERTIES_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Track & Via Properties"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(573, 437), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxSYSTEM_MENU)
virtual void onClose(wxCloseEvent &event)
virtual void OnInitDlg(wxInitDialogEvent &event)
virtual void onViaNetclassCheck(wxCommandEvent &event)