KiCad PCB EDA Suite
dialog_rule_area_properties_base.cpp
Go to the documentation of this file.
1
2// C++ code generated with wxFormBuilder (version Oct 26 2018)
3// http://www.wxformbuilder.org/
4//
5// PLEASE DO *NOT* EDIT THIS FILE!
7
9
11
12DIALOG_RULE_AREA_PROPERTIES_BASE::DIALOG_RULE_AREA_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 )
13{
14 this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
15
16 wxBoxSizer* bMainSizer;
17 bMainSizer = new wxBoxSizer( wxVERTICAL );
18
19 wxBoxSizer* bUpperSizer;
20 bUpperSizer = new wxBoxSizer( wxHORIZONTAL );
21
22 wxBoxSizer* bLayersListSizer;
23 bLayersListSizer = new wxBoxSizer( wxVERTICAL );
24
25 m_staticTextLayerSelection = new wxStaticText( this, wxID_ANY, _("Layers:"), wxDefaultPosition, wxDefaultSize, 0 );
27 bLayersListSizer->Add( m_staticTextLayerSelection, 0, wxALL, 4 );
28
29 m_layers = new wxDataViewListCtrl( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxDV_NO_HEADER|wxBORDER_SIMPLE );
30 bLayersListSizer->Add( m_layers, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
31
32
33 bUpperSizer->Add( bLayersListSizer, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
34
35
36 bUpperSizer->Add( 0, 0, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
37
38 wxBoxSizer* bSizerRight;
39 bSizerRight = new wxBoxSizer( wxVERTICAL );
40
41 wxBoxSizer* bSizer6;
42 bSizer6 = new wxBoxSizer( wxVERTICAL );
43
44 m_staticText3 = new wxStaticText( this, wxID_ANY, _("Area name:"), wxDefaultPosition, wxDefaultSize, 0 );
45 m_staticText3->Wrap( -1 );
46 m_staticText3->SetToolTip( _("A unique name for this rule area for use in DRC rules") );
47
48 bSizer6->Add( m_staticText3, 0, wxRIGHT|wxLEFT, 5 );
49
50
51 bSizer6->Add( 0, 2, 0, 0, 5 );
52
53 m_tcName = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
54 m_tcName->SetToolTip( _("A unique name for this rule area for use in DRC rules") );
55
56 bSizer6->Add( m_tcName, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 );
57
58 m_cbLocked = new wxCheckBox( this, wxID_ANY, _("Locked"), wxDefaultPosition, wxDefaultSize, 0 );
59 bSizer6->Add( m_cbLocked, 0, wxALL, 5 );
60
61
62 bSizerRight->Add( bSizer6, 0, wxEXPAND|wxBOTTOM, 5 );
63
64 wxFlexGridSizer* fgSizer2;
65 fgSizer2 = new wxFlexGridSizer( 0, 1, 3, 0 );
66 fgSizer2->SetFlexibleDirection( wxBOTH );
67 fgSizer2->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
68
69 m_staticTextBasicRules = new wxStaticText( this, wxID_ANY, _("Basic rules:"), wxDefaultPosition, wxDefaultSize, 0 );
70 m_staticTextBasicRules->Wrap( -1 );
71 fgSizer2->Add( m_staticTextBasicRules, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
72
73 m_cbTracksCtrl = new wxCheckBox( this, wxID_ANY, _("Keep out tracks"), wxDefaultPosition, wxDefaultSize, 0 );
74 m_cbTracksCtrl->SetToolTip( _("Prevent tracks from routing into this area") );
75
76 fgSizer2->Add( m_cbTracksCtrl, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
77
78 m_cbViasCtrl = new wxCheckBox( this, wxID_ANY, _("Keep out vias"), wxDefaultPosition, wxDefaultSize, 0 );
79 m_cbViasCtrl->SetToolTip( _("Prevent vias from being placed in this area") );
80
81 fgSizer2->Add( m_cbViasCtrl, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
82
83 m_cbPadsCtrl = new wxCheckBox( this, wxID_ANY, _("Keep out pads"), wxDefaultPosition, wxDefaultSize, 0 );
84 m_cbPadsCtrl->SetToolTip( _("Raise a DRC error if a pad overlaps this area") );
85
86 fgSizer2->Add( m_cbPadsCtrl, 0, wxRIGHT|wxLEFT, 5 );
87
88 m_cbCopperPourCtrl = new wxCheckBox( this, wxID_ANY, _("Keep out copper fill"), wxDefaultPosition, wxDefaultSize, 0 );
89 m_cbCopperPourCtrl->SetToolTip( _("Zones will not fill copper into this area") );
90
91 fgSizer2->Add( m_cbCopperPourCtrl, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
92
93 m_cbFootprintsCtrl = new wxCheckBox( this, wxID_ANY, _("Keep out footprints"), wxDefaultPosition, wxDefaultSize, 0 );
94 m_cbFootprintsCtrl->SetToolTip( _("Raise a DRC error if a footprint courtyard overlaps this area") );
95
96 fgSizer2->Add( m_cbFootprintsCtrl, 0, wxRIGHT|wxLEFT, 5 );
97
98
99 bSizerRight->Add( fgSizer2, 0, wxEXPAND, 5 );
100
101
102 bSizerRight->Add( 0, 3, 0, wxEXPAND, 5 );
103
104
105 bSizerRight->Add( 0, 0, 0, wxEXPAND, 5 );
106
107
108 bSizerRight->Add( 0, 0, 0, wxEXPAND|wxBOTTOM, 5 );
109
110 wxGridBagSizer* gbSizer1;
111 gbSizer1 = new wxGridBagSizer( 3, 3 );
112 gbSizer1->SetFlexibleDirection( wxBOTH );
113 gbSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
114 gbSizer1->SetEmptyCellSize( wxSize( -1,2 ) );
115
116 m_staticTextStyle = new wxStaticText( this, wxID_ANY, _("Outline display:"), wxDefaultPosition, wxDefaultSize, 0 );
117 m_staticTextStyle->Wrap( -1 );
118 gbSizer1->Add( m_staticTextStyle, wxGBPosition( 2, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
119
120 wxString m_OutlineDisplayCtrlChoices[] = { _("Line"), _("Hatched"), _("Fully hatched") };
121 int m_OutlineDisplayCtrlNChoices = sizeof( m_OutlineDisplayCtrlChoices ) / sizeof( wxString );
122 m_OutlineDisplayCtrl = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_OutlineDisplayCtrlNChoices, m_OutlineDisplayCtrlChoices, 0 );
123 m_OutlineDisplayCtrl->SetSelection( 0 );
124 gbSizer1->Add( m_OutlineDisplayCtrl, wxGBPosition( 2, 1 ), wxGBSpan( 1, 2 ), wxEXPAND, 5 );
125
126 m_stBorderHatchPitchText = new wxStaticText( this, wxID_ANY, _("Outline hatch pitch:"), wxDefaultPosition, wxDefaultSize, 0 );
127 m_stBorderHatchPitchText->Wrap( -1 );
128 gbSizer1->Add( m_stBorderHatchPitchText, wxGBPosition( 3, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
129
130 m_outlineHatchPitchCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
131 m_outlineHatchPitchCtrl->SetToolTip( _("A unique name for this rule area for use in DRC rules") );
132
133 gbSizer1->Add( m_outlineHatchPitchCtrl, wxGBPosition( 3, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
134
135 m_outlineHatchUnits = new wxStaticText( this, wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 );
136 m_outlineHatchUnits->Wrap( -1 );
137 gbSizer1->Add( m_outlineHatchUnits, wxGBPosition( 3, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
138
139
140 bSizerRight->Add( gbSizer1, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
141
142
143 bUpperSizer->Add( bSizerRight, 0, wxEXPAND|wxALL, 5 );
144
145
146 bMainSizer->Add( bUpperSizer, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
147
148 m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
149 bMainSizer->Add( m_staticline1, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
150
151 m_sdbSizerButtons = new wxStdDialogButtonSizer();
152 m_sdbSizerButtonsOK = new wxButton( this, wxID_OK );
154 m_sdbSizerButtonsCancel = new wxButton( this, wxID_CANCEL );
156 m_sdbSizerButtons->Realize();
157
158 bMainSizer->Add( m_sdbSizerButtons, 0, wxEXPAND|wxALL, 5 );
159
160
161 this->SetSizer( bMainSizer );
162 this->Layout();
163 bMainSizer->Fit( this );
164
165 this->Centre( wxBOTH );
166
167 // Connect Events
168 m_layers->Connect( wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED, wxDataViewEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::OnLayerSelection ), NULL, this );
169 m_layers->Connect( wxEVT_RIGHT_DOWN, wxMouseEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::onLayerListRightDown ), NULL, this );
170 m_layers->Connect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::OnSizeLayersList ), NULL, this );
171}
172
174{
175 // Disconnect Events
176 m_layers->Disconnect( wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED, wxDataViewEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::OnLayerSelection ), NULL, this );
177 m_layers->Disconnect( wxEVT_RIGHT_DOWN, wxMouseEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::onLayerListRightDown ), NULL, this );
178 m_layers->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_RULE_AREA_PROPERTIES_BASE::OnSizeLayersList ), NULL, this );
179
180}
virtual void onLayerListRightDown(wxMouseEvent &event)
virtual void OnSizeLayersList(wxSizeEvent &event)
DIALOG_RULE_AREA_PROPERTIES_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Rule Area Properties"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxFULL_REPAINT_ON_RESIZE|wxBORDER_SUNKEN)
virtual void OnLayerSelection(wxDataViewEvent &event)
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...
Definition: dialog_shim.h:83
#define _(s)