KiCad PCB EDA Suite
Loading...
Searching...
No Matches
panel_plugin_settings_base.cpp
Go to the documentation of this file.
1
2// C++ code generated with wxFormBuilder (version 4.0.0-0-g0efcecf-dirty)
3// http://www.wxformbuilder.org/
4//
5// PLEASE DO *NOT* EDIT THIS FILE!
7
9
11
12PANEL_PLUGIN_SETTINGS_BASE::PANEL_PLUGIN_SETTINGS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : RESETTABLE_PANEL( parent, id, pos, size, style, name )
13{
14 wxBoxSizer* bPanelSizer;
15 bPanelSizer = new wxBoxSizer( wxHORIZONTAL );
16
17 wxBoxSizer* bSizer8;
18 bSizer8 = new wxBoxSizer( wxVERTICAL );
19
20 wxStaticBoxSizer* sbSizerServer;
21 sbSizerServer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("KiCad API") ), wxVERTICAL );
22
23 m_staticText3 = new wxStaticText( sbSizerServer->GetStaticBox(), wxID_ANY, _("When the KiCad API is enabled, plugins and other software running on this computer can connect to KiCad."), wxDefaultPosition, wxDefaultSize, 0 );
24 m_staticText3->Wrap( -1 );
25 sbSizerServer->Add( m_staticText3, 0, wxALL, 5 );
26
27 m_cbEnableApi = new wxCheckBox( sbSizerServer->GetStaticBox(), wxID_ANY, _("Enable KiCad API"), wxDefaultPosition, wxDefaultSize, 0 );
28 m_cbEnableApi->SetToolTip( _("Enable the KiCad API. Doing so will allow third-party software running on your computer to access KiCad.") );
29
30 sbSizerServer->Add( m_cbEnableApi, 0, wxALL, 5 );
31
32 m_stApiStatus = new wxStaticText( sbSizerServer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
33 m_stApiStatus->Wrap( -1 );
34 sbSizerServer->Add( m_stApiStatus, 0, wxALL, 5 );
35
36
37 bSizer8->Add( sbSizerServer, 0, wxALL|wxEXPAND, 5 );
38
39 wxStaticBoxSizer* sbSizerPython;
40 sbSizerPython = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Python Interpreter") ), wxVERTICAL );
41
42 wxBoxSizer* bSizer4;
43 bSizer4 = new wxBoxSizer( wxHORIZONTAL );
44
45 m_staticText2 = new wxStaticText( sbSizerPython->GetStaticBox(), wxID_ANY, _("Path to Python interpreter:"), wxDefaultPosition, wxDefaultSize, 0 );
46 m_staticText2->Wrap( -1 );
47 bSizer4->Add( m_staticText2, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
48
49 m_pickerPythonInterpreter = new wxFilePickerCtrl( sbSizerPython->GetStaticBox(), wxID_ANY, wxEmptyString, _("Select the path to a Python interpreter"), _("*.*"), wxDefaultPosition, wxDefaultSize, wxFLP_DEFAULT_STYLE|wxFLP_USE_TEXTCTRL );
50 bSizer4->Add( m_pickerPythonInterpreter, 1, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
51
52 m_btnDetectAutomatically = new wxButton( sbSizerPython->GetStaticBox(), wxID_ANY, _("Detect Automatically"), wxDefaultPosition, wxDefaultSize, 0 );
53 bSizer4->Add( m_btnDetectAutomatically, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
54
55
56 sbSizerPython->Add( bSizer4, 0, wxEXPAND, 5 );
57
58 m_stPythonStatus = new wxStaticText( sbSizerPython->GetStaticBox(), wxID_ANY, _("No Python interpreter chosen; external Python plugins will not be available"), wxDefaultPosition, wxDefaultSize, 0 );
59 m_stPythonStatus->Wrap( -1 );
60 m_stPythonStatus->SetToolTip( _("Python interpreter status") );
61
62 sbSizerPython->Add( m_stPythonStatus, 0, wxALL, 5 );
63
64
65 bSizer8->Add( sbSizerPython, 0, wxALL|wxEXPAND, 5 );
66
67
68 bSizer8->Add( 0, 0, 1, wxEXPAND, 5 );
69
70
71 bPanelSizer->Add( bSizer8, 1, wxEXPAND, 5 );
72
73
74 this->SetSizer( bPanelSizer );
75 this->Layout();
76 bPanelSizer->Fit( this );
77
78 // Connect Events
79 m_cbEnableApi->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnEnableApiChecked ), NULL, this );
80 m_pickerPythonInterpreter->Connect( wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnPythonInterpreterChanged ), NULL, this );
81 m_btnDetectAutomatically->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnBtnDetectAutomaticallyClicked ), NULL, this );
82}
83
85{
86 // Disconnect Events
87 m_cbEnableApi->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnEnableApiChecked ), NULL, this );
88 m_pickerPythonInterpreter->Disconnect( wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnPythonInterpreterChanged ), NULL, this );
89 m_btnDetectAutomatically->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PLUGIN_SETTINGS_BASE::OnBtnDetectAutomaticallyClicked ), NULL, this );
90
91}
const char * name
Definition: DXF_plotter.cpp:57
wxFilePickerCtrl * m_pickerPythonInterpreter
virtual void OnBtnDetectAutomaticallyClicked(wxCommandEvent &event)
PANEL_PLUGIN_SETTINGS_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
virtual void OnEnableApiChecked(wxCommandEvent &event)
virtual void OnPythonInterpreterChanged(wxFileDirPickerEvent &event)
A wxPanel that is designed to be reset in a standard manner.
#define _(s)