KiCad PCB EDA Suite
Loading...
Searching...
No Matches
dialog_gen_footprint_position_file_base.cpp
Go to the documentation of this file.
1
2// C++ code generated with wxFormBuilder (version 4.2.1-0-g80c4cb6)
3// http://www.wxformbuilder.org/
4//
5// PLEASE DO *NOT* EDIT THIS FILE!
7
10
12
14
15DIALOG_GEN_FOOTPRINT_POSITION_BASE::DIALOG_GEN_FOOTPRINT_POSITION_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
16{
17 this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
18
19 m_MainSizer = new wxBoxSizer( wxVERTICAL );
20
21 wxBoxSizer* bUpperSizer;
22 bUpperSizer = new wxBoxSizer( wxHORIZONTAL );
23
24 wxBoxSizer* bSizerdirBrowse;
25 bSizerdirBrowse = new wxBoxSizer( wxHORIZONTAL );
26
27 m_staticTextDir = new wxStaticText( this, wxID_ANY, _("Output directory:"), wxDefaultPosition, wxDefaultSize, 0 );
28 m_staticTextDir->Wrap( -1 );
29 bSizerdirBrowse->Add( m_staticTextDir, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
30
31 m_outputDirectoryName = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
32 m_outputDirectoryName->SetToolTip( _("Target directory for plot files. Can be absolute or relative to the board file location.") );
33 m_outputDirectoryName->SetMinSize( wxSize( 350,-1 ) );
34
35 bSizerdirBrowse->Add( m_outputDirectoryName, 1, wxALIGN_CENTER_VERTICAL, 5 );
36
37 m_browseButton = new STD_BITMAP_BUTTON( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
38 bSizerdirBrowse->Add( m_browseButton, 0, wxALIGN_CENTER_VERTICAL, 5 );
39
40
41 bUpperSizer->Add( bSizerdirBrowse, 1, wxEXPAND|wxALL, 10 );
42
43
44 m_MainSizer->Add( bUpperSizer, 0, wxEXPAND, 2 );
45
46 wxBoxSizer* bSizerMiddle;
47 bSizerMiddle = new wxBoxSizer( wxHORIZONTAL );
48
49 wxFlexGridSizer* fgSizer1;
50 fgSizer1 = new wxFlexGridSizer( 0, 2, 5, 5 );
51 fgSizer1->AddGrowableCol( 1 );
52 fgSizer1->SetFlexibleDirection( wxBOTH );
53 fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
54
55 m_formatLabel = new wxStaticText( this, wxID_ANY, _("Format:"), wxDefaultPosition, wxDefaultSize, 0 );
56 m_formatLabel->Wrap( -1 );
57 fgSizer1->Add( m_formatLabel, 0, wxRIGHT, 5 );
58
59 wxString m_formatCtrlChoices[] = { _("ASCII"), _("CSV"), _("Gerber X3") };
60 int m_formatCtrlNChoices = sizeof( m_formatCtrlChoices ) / sizeof( wxString );
61 m_formatCtrl = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_formatCtrlNChoices, m_formatCtrlChoices, 0 );
62 m_formatCtrl->SetSelection( 0 );
63 fgSizer1->Add( m_formatCtrl, 0, wxRIGHT|wxLEFT|wxEXPAND, 5 );
64
65 m_unitsLabel = new wxStaticText( this, wxID_ANY, _("Units:"), wxDefaultPosition, wxDefaultSize, 0 );
66 m_unitsLabel->Wrap( -1 );
67 fgSizer1->Add( m_unitsLabel, 0, wxRIGHT, 5 );
68
69 wxString m_unitsCtrlChoices[] = { _("Inches"), _("Millimeters") };
70 int m_unitsCtrlNChoices = sizeof( m_unitsCtrlChoices ) / sizeof( wxString );
71 m_unitsCtrl = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_unitsCtrlNChoices, m_unitsCtrlChoices, 0 );
72 m_unitsCtrl->SetSelection( 0 );
73 fgSizer1->Add( m_unitsCtrl, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
74
75
76 bSizerMiddle->Add( fgSizer1, 1, wxEXPAND|wxBOTTOM|wxLEFT, 5 );
77
78 wxBoxSizer* bSizer6;
79 bSizer6 = new wxBoxSizer( wxVERTICAL );
80
81
82 bSizer6->Add( 0, 0, 1, wxEXPAND, 5 );
83
84
85 bSizerMiddle->Add( bSizer6, 1, wxEXPAND, 5 );
86
87
88 m_MainSizer->Add( bSizerMiddle, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
89
90 wxBoxSizer* bSizerLower;
91 bSizerLower = new wxBoxSizer( wxVERTICAL );
92
93 m_onlySMD = new wxCheckBox( this, wxID_ANY, _("Include only SMD footprints"), wxDefaultPosition, wxDefaultSize, 0 );
94 bSizerLower->Add( m_onlySMD, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
95
96 m_excludeTH = new wxCheckBox( this, wxID_ANY, _("Exclude all footprints with through hole pads"), wxDefaultPosition, wxDefaultSize, 0 );
97 bSizerLower->Add( m_excludeTH, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
98
99 m_excludeDNP = new wxCheckBox( this, wxID_ANY, _("Exclude all footprints with the Do Not Populate flag set"), wxDefaultPosition, wxDefaultSize, 0 );
100 bSizerLower->Add( m_excludeDNP, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
101
102 m_cbIncludeBoardEdge = new wxCheckBox( this, wxID_ANY, _("Include board edge layer"), wxDefaultPosition, wxDefaultSize, 0 );
103 bSizerLower->Add( m_cbIncludeBoardEdge, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
104
105 m_useDrillPlaceOrigin = new wxCheckBox( this, wxID_ANY, _("Use drill/place file origin"), wxDefaultPosition, wxDefaultSize, 0 );
106 bSizerLower->Add( m_useDrillPlaceOrigin, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
107
108 m_negateXcb = new wxCheckBox( this, wxID_ANY, _("Use negative X coordinates for footprints on bottom layer"), wxDefaultPosition, wxDefaultSize, 0 );
109 bSizerLower->Add( m_negateXcb, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
110
111 m_singleFile = new wxCheckBox( this, wxID_ANY, _("Generate single file with both front and back positions"), wxDefaultPosition, wxDefaultSize, 0 );
112 bSizerLower->Add( m_singleFile, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
113
114
115 bSizerLower->Add( 0, 5, 0, wxEXPAND, 5 );
116
117 m_messagesPanel = new WX_HTML_REPORT_PANEL( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
118 m_messagesPanel->SetMinSize( wxSize( 350,120 ) );
119
120 bSizerLower->Add( m_messagesPanel, 1, wxEXPAND|wxTOP, 10 );
121
122
123 m_MainSizer->Add( bSizerLower, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
124
125 m_sdbSizer = new wxStdDialogButtonSizer();
126 m_sdbSizerOK = new wxButton( this, wxID_OK );
127 m_sdbSizer->AddButton( m_sdbSizerOK );
128 m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
129 m_sdbSizer->AddButton( m_sdbSizerCancel );
130 m_sdbSizer->Realize();
131
132 m_MainSizer->Add( m_sdbSizer, 0, wxALL|wxEXPAND, 5 );
133
134
135 this->SetSizer( m_MainSizer );
136 this->Layout();
137 m_MainSizer->Fit( this );
138
139 this->Centre( wxBOTH );
140
141 // Connect Events
142 m_browseButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onOutputDirectoryBrowseClicked ), NULL, this );
143 m_formatCtrl->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIFileOpt ), NULL, this );
144 m_unitsCtrl->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIUnits ), NULL, this );
145 m_onlySMD->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIOnlySMD ), NULL, this );
146 m_excludeTH->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIExcludeTH ), NULL, this );
147 m_excludeDNP->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIExcludeTH ), NULL, this );
148 m_cbIncludeBoardEdge->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIincludeBoardEdge ), NULL, this );
149 m_negateXcb->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUInegXcoord ), NULL, this );
150 m_sdbSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onGenerate ), NULL, this );
151}
152
154{
155 // Disconnect Events
156 m_browseButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onOutputDirectoryBrowseClicked ), NULL, this );
157 m_formatCtrl->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIFileOpt ), NULL, this );
158 m_unitsCtrl->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIUnits ), NULL, this );
159 m_onlySMD->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIOnlySMD ), NULL, this );
160 m_excludeTH->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIExcludeTH ), NULL, this );
161 m_excludeDNP->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIExcludeTH ), NULL, this );
162 m_cbIncludeBoardEdge->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUIincludeBoardEdge ), NULL, this );
163 m_negateXcb->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onUpdateUInegXcoord ), NULL, this );
164 m_sdbSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_FOOTPRINT_POSITION_BASE::onGenerate ), NULL, this );
165
166}
virtual void onUpdateUIExcludeTH(wxUpdateUIEvent &event)
virtual void onUpdateUIincludeBoardEdge(wxUpdateUIEvent &event)
DIALOG_GEN_FOOTPRINT_POSITION_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Generate Placement Files"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
virtual void onUpdateUInegXcoord(wxUpdateUIEvent &event)
virtual void onOutputDirectoryBrowseClicked(wxCommandEvent &event)
virtual void onUpdateUIUnits(wxUpdateUIEvent &event)
virtual void onUpdateUIFileOpt(wxUpdateUIEvent &event)
virtual void onUpdateUIOnlySMD(wxUpdateUIEvent &event)
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...
Definition: dialog_shim.h:88
A bitmap button widget that behaves like a standard dialog button except with an icon.
A widget for browsing a rich text error/status report.
#define _(s)