2018-04-28 15:22:25 +00:00
///////////////////////////////////////////////////////////////////////////
2022-08-14 11:03:18 +00:00
// C++ code generated with wxFormBuilder (version 3.10.1-0-g8feb16b)
2018-04-28 15:22:25 +00:00
// http://www.wxformbuilder.org/
//
// PLEASE DO *NOT* EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
2022-12-13 20:47:28 +00:00
# include "widgets/std_bitmap_button.h"
2018-04-28 15:22:25 +00:00
# include "widgets/wx_grid.h"
2022-09-03 18:29:02 +00:00
# include "widgets/wx_html_report_box.h"
2023-01-11 01:00:47 +00:00
# include "widgets/wx_panel.h"
2018-04-28 15:22:25 +00:00
# include "panel_setup_netclasses_base.h"
///////////////////////////////////////////////////////////////////////////
2019-02-10 08:49:42 +00:00
PANEL_SETUP_NETCLASSES_BASE : : PANEL_SETUP_NETCLASSES_BASE ( wxWindow * parent , wxWindowID id , const wxPoint & pos , const wxSize & size , long style , const wxString & name ) : wxPanel ( parent , id , pos , size , style , name )
2018-04-28 15:22:25 +00:00
{
wxBoxSizer * bpanelNetClassesSizer ;
bpanelNetClassesSizer = new wxBoxSizer ( wxVERTICAL ) ;
2019-02-10 08:49:42 +00:00
2018-07-17 06:52:33 +00:00
wxBoxSizer * bMargins ;
bMargins = new wxBoxSizer ( wxVERTICAL ) ;
2019-02-10 08:49:42 +00:00
2021-02-23 14:34:18 +00:00
m_splitter = new wxSplitterWindow ( this , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxSP_3DSASH | wxSP_LIVE_UPDATE | wxSP_NO_XP_THEME ) ;
2023-08-28 14:55:14 +00:00
m_splitter - > SetMinimumPaneSize ( 160 ) ;
2021-02-23 14:34:18 +00:00
2023-01-11 01:00:47 +00:00
m_netclassesPane = new WX_PANEL ( m_splitter , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxTAB_TRAVERSAL ) ;
2021-02-23 14:34:18 +00:00
wxBoxSizer * bUpperSizer ;
bUpperSizer = new wxBoxSizer ( wxVERTICAL ) ;
2019-02-10 08:49:42 +00:00
2023-01-11 01:00:47 +00:00
m_staticText3 = new wxStaticText ( m_netclassesPane , wxID_ANY , _ ( " Netclasses: " ) , wxDefaultPosition , wxDefaultSize , 0 ) ;
m_staticText3 - > Wrap ( - 1 ) ;
bUpperSizer - > Add ( m_staticText3 , 0 , wxTOP | wxLEFT | wxEXPAND , 8 ) ;
bUpperSizer - > Add ( 0 , 3 , 0 , wxEXPAND , 5 ) ;
m_netclassGrid = new WX_GRID ( m_netclassesPane , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxHSCROLL | wxTAB_TRAVERSAL | wxVSCROLL ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
// Grid
2022-08-14 11:03:18 +00:00
m_netclassGrid - > CreateGrid ( 3 , 13 ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > EnableEditing ( true ) ;
m_netclassGrid - > EnableGridLines ( true ) ;
m_netclassGrid - > EnableDragGridSize ( false ) ;
m_netclassGrid - > SetMargins ( 0 , 0 ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
// Columns
m_netclassGrid - > EnableDragColMove ( false ) ;
m_netclassGrid - > EnableDragColSize ( true ) ;
2023-01-11 01:00:47 +00:00
m_netclassGrid - > SetColLabelValue ( 0 , _ ( " Name " ) ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > SetColLabelValue ( 1 , _ ( " Clearance " ) ) ;
m_netclassGrid - > SetColLabelValue ( 2 , _ ( " Track Width " ) ) ;
m_netclassGrid - > SetColLabelValue ( 3 , _ ( " Via Size " ) ) ;
2021-01-11 13:46:00 +00:00
m_netclassGrid - > SetColLabelValue ( 4 , _ ( " Via Hole " ) ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > SetColLabelValue ( 5 , _ ( " uVia Size " ) ) ;
2021-01-11 13:46:00 +00:00
m_netclassGrid - > SetColLabelValue ( 6 , _ ( " uVia Hole " ) ) ;
2020-05-23 21:48:24 +00:00
m_netclassGrid - > SetColLabelValue ( 7 , _ ( " DP Width " ) ) ;
m_netclassGrid - > SetColLabelValue ( 8 , _ ( " DP Gap " ) ) ;
2020-07-08 18:29:16 +00:00
m_netclassGrid - > SetColLabelValue ( 9 , _ ( " Wire Thickness " ) ) ;
m_netclassGrid - > SetColLabelValue ( 10 , _ ( " Bus Thickness " ) ) ;
m_netclassGrid - > SetColLabelValue ( 11 , _ ( " Color " ) ) ;
m_netclassGrid - > SetColLabelValue ( 12 , _ ( " Line Style " ) ) ;
2023-01-11 01:00:47 +00:00
m_netclassGrid - > SetColLabelSize ( wxGRID_AUTOSIZE ) ;
2019-02-10 08:49:42 +00:00
m_netclassGrid - > SetColLabelAlignment ( wxALIGN_CENTER , wxALIGN_CENTER ) ;
2018-04-28 15:22:25 +00:00
// Rows
2019-02-18 09:09:22 +00:00
m_netclassGrid - > EnableDragRowSize ( true ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > SetRowLabelValue ( 0 , _ ( " Default " ) ) ;
2021-09-07 12:06:02 +00:00
m_netclassGrid - > SetRowLabelSize ( 0 ) ;
2019-02-10 08:49:42 +00:00
m_netclassGrid - > SetRowLabelAlignment ( wxALIGN_LEFT , wxALIGN_CENTER ) ;
2018-04-28 15:22:25 +00:00
// Label Appearance
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
// Cell Defaults
2023-09-18 14:15:22 +00:00
m_netclassGrid - > SetDefaultCellAlignment ( wxALIGN_LEFT , wxALIGN_CENTER ) ;
2023-10-19 15:59:35 +00:00
bUpperSizer - > Add ( m_netclassGrid , 1 , wxEXPAND | wxFIXED_MINSIZE | wxLEFT | wxRIGHT | wxTOP , 5 ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
wxBoxSizer * buttonBoxSizer ;
buttonBoxSizer = new wxBoxSizer ( wxHORIZONTAL ) ;
2019-02-10 08:49:42 +00:00
2022-12-13 20:47:28 +00:00
m_addButton = new STD_BITMAP_BUTTON ( m_netclassesPane , wxID_ANY , wxNullBitmap , wxDefaultPosition , wxSize ( - 1 , - 1 ) , wxBU_AUTODRAW | 0 ) ;
2023-01-11 01:00:47 +00:00
buttonBoxSizer - > Add ( m_addButton , 0 , wxLEFT , 2 ) ;
2019-02-10 08:49:42 +00:00
2023-01-11 01:00:47 +00:00
buttonBoxSizer - > Add ( 20 , 0 , 0 , wxEXPAND , 5 ) ;
2019-02-10 08:49:42 +00:00
2022-12-13 20:47:28 +00:00
m_removeButton = new STD_BITMAP_BUTTON ( m_netclassesPane , wxID_ANY , wxNullBitmap , wxDefaultPosition , wxSize ( - 1 , - 1 ) , wxBU_AUTODRAW | 0 ) ;
2022-08-14 11:03:18 +00:00
buttonBoxSizer - > Add ( m_removeButton , 0 , wxBOTTOM | wxRIGHT | wxLEFT , 5 ) ;
2019-02-10 08:49:42 +00:00
2023-08-28 14:55:14 +00:00
buttonBoxSizer - > Add ( 60 , 0 , 1 , wxEXPAND , 5 ) ;
2021-06-28 12:23:19 +00:00
2021-09-07 12:06:02 +00:00
m_colorDefaultHelpText = new wxStaticText ( m_netclassesPane , wxID_ANY , _ ( " Set color to transparent to use KiCad default color. " ) , wxDefaultPosition , wxDefaultSize , 0 ) ;
2021-06-28 12:23:19 +00:00
m_colorDefaultHelpText - > Wrap ( - 1 ) ;
2023-02-02 21:54:52 +00:00
buttonBoxSizer - > Add ( m_colorDefaultHelpText , 0 , wxALIGN_CENTER_VERTICAL | wxRIGHT , 10 ) ;
2021-06-28 12:23:19 +00:00
2023-02-02 21:54:52 +00:00
bUpperSizer - > Add ( buttonBoxSizer , 0 , wxEXPAND | wxLEFT | wxTOP , 5 ) ;
2019-02-10 08:49:42 +00:00
2021-02-23 14:34:18 +00:00
m_netclassesPane - > SetSizer ( bUpperSizer ) ;
2019-07-09 20:25:58 +00:00
m_netclassesPane - > Layout ( ) ;
2021-02-23 14:34:18 +00:00
bUpperSizer - > Fit ( m_netclassesPane ) ;
2023-01-11 01:00:47 +00:00
m_membershipPane = new WX_PANEL ( m_splitter , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxTAB_TRAVERSAL ) ;
2021-02-23 14:34:18 +00:00
wxBoxSizer * bLowerSizer ;
2022-08-14 11:03:18 +00:00
bLowerSizer = new wxBoxSizer ( wxVERTICAL ) ;
2019-02-10 08:49:42 +00:00
2023-01-11 01:00:47 +00:00
bLowerSizer - > Add ( 0 , 5 , 0 , wxEXPAND , 5 ) ;
2022-08-14 11:03:18 +00:00
m_staticText5 = new wxStaticText ( m_membershipPane , wxID_ANY , _ ( " Netclass assignments: " ) , wxDefaultPosition , wxDefaultSize , 0 ) ;
m_staticText5 - > Wrap ( - 1 ) ;
2023-01-11 01:00:47 +00:00
bLowerSizer - > Add ( m_staticText5 , 0 , wxEXPAND | wxTOP | wxLEFT , 8 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
wxBoxSizer * bColumns ;
bColumns = new wxBoxSizer ( wxHORIZONTAL ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
wxBoxSizer * bSizer14 ;
bSizer14 = new wxBoxSizer ( wxVERTICAL ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
m_assignmentGrid = new WX_GRID ( m_membershipPane , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxBORDER_DEFAULT ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
// Grid
m_assignmentGrid - > CreateGrid ( 5 , 2 ) ;
m_assignmentGrid - > EnableEditing ( true ) ;
m_assignmentGrid - > EnableGridLines ( true ) ;
m_assignmentGrid - > EnableDragGridSize ( false ) ;
m_assignmentGrid - > SetMargins ( 0 , 0 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
// Columns
2023-06-16 15:47:42 +00:00
m_assignmentGrid - > SetColSize ( 0 , 270 ) ;
2022-08-14 11:03:18 +00:00
m_assignmentGrid - > SetColSize ( 1 , 160 ) ;
m_assignmentGrid - > EnableDragColMove ( false ) ;
m_assignmentGrid - > EnableDragColSize ( true ) ;
m_assignmentGrid - > SetColLabelValue ( 0 , _ ( " Pattern " ) ) ;
m_assignmentGrid - > SetColLabelValue ( 1 , _ ( " Net Class " ) ) ;
2023-01-11 01:00:47 +00:00
m_assignmentGrid - > SetColLabelSize ( wxGRID_AUTOSIZE ) ;
2022-08-14 11:03:18 +00:00
m_assignmentGrid - > SetColLabelAlignment ( wxALIGN_CENTER , wxALIGN_CENTER ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
// Rows
m_assignmentGrid - > EnableDragRowSize ( true ) ;
m_assignmentGrid - > SetRowLabelSize ( 0 ) ;
m_assignmentGrid - > SetRowLabelAlignment ( wxALIGN_CENTER , wxALIGN_CENTER ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
// Label Appearance
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
// Cell Defaults
2023-09-18 14:15:22 +00:00
m_assignmentGrid - > SetDefaultCellAlignment ( wxALIGN_LEFT , wxALIGN_CENTER ) ;
2023-06-16 15:47:42 +00:00
bSizer14 - > Add ( m_assignmentGrid , 2 , wxEXPAND | wxFIXED_MINSIZE | wxLEFT , 5 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
bColumns - > Add ( bSizer14 , 3 , wxEXPAND , 5 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
m_matchingNets = new WX_HTML_REPORT_BOX ( m_membershipPane , wxID_ANY , wxDefaultPosition , wxDefaultSize , wxHW_SCROLLBAR_AUTO ) ;
2023-02-02 21:54:52 +00:00
bColumns - > Add ( m_matchingNets , 2 , wxEXPAND | wxLEFT | wxRIGHT , 5 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
bLowerSizer - > Add ( bColumns , 1 , wxEXPAND | wxTOP , 3 ) ;
2019-02-10 08:49:42 +00:00
2022-08-14 11:03:18 +00:00
wxBoxSizer * buttonBoxSizer1 ;
buttonBoxSizer1 = new wxBoxSizer ( wxHORIZONTAL ) ;
2019-02-10 08:49:42 +00:00
2022-12-13 20:47:28 +00:00
m_addAssignmentButton = new STD_BITMAP_BUTTON ( m_membershipPane , wxID_ANY , wxNullBitmap , wxDefaultPosition , wxSize ( - 1 , - 1 ) , wxBU_AUTODRAW | 0 ) ;
2023-01-11 01:00:47 +00:00
buttonBoxSizer1 - > Add ( m_addAssignmentButton , 0 , wxLEFT , 2 ) ;
2019-02-10 08:49:42 +00:00
2023-01-11 01:00:47 +00:00
buttonBoxSizer1 - > Add ( 20 , 0 , 0 , wxEXPAND , 5 ) ;
2019-02-10 08:49:42 +00:00
2022-12-13 20:47:28 +00:00
m_removeAssignmentButton = new STD_BITMAP_BUTTON ( m_membershipPane , wxID_ANY , wxNullBitmap , wxDefaultPosition , wxSize ( - 1 , - 1 ) , wxBU_AUTODRAW | 0 ) ;
2022-08-14 11:03:18 +00:00
buttonBoxSizer1 - > Add ( m_removeAssignmentButton , 0 , wxRIGHT | wxLEFT , 5 ) ;
2019-02-10 08:49:42 +00:00
2023-01-11 01:00:47 +00:00
bLowerSizer - > Add ( buttonBoxSizer1 , 0 , wxEXPAND | wxTOP | wxBOTTOM | wxLEFT , 5 ) ;
2019-02-10 08:49:42 +00:00
2021-02-23 14:34:18 +00:00
m_membershipPane - > SetSizer ( bLowerSizer ) ;
2019-07-09 20:25:58 +00:00
m_membershipPane - > Layout ( ) ;
2021-02-23 14:34:18 +00:00
bLowerSizer - > Fit ( m_membershipPane ) ;
m_splitter - > SplitHorizontally ( m_netclassesPane , m_membershipPane , - 1 ) ;
2023-01-11 01:00:47 +00:00
bMargins - > Add ( m_splitter , 1 , wxEXPAND , 10 ) ;
2019-02-10 08:49:42 +00:00
2021-02-23 14:34:18 +00:00
bpanelNetClassesSizer - > Add ( bMargins , 1 , wxEXPAND | wxTOP , 2 ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
this - > SetSizer ( bpanelNetClassesSizer ) ;
this - > Layout ( ) ;
2023-08-28 14:55:14 +00:00
bpanelNetClassesSizer - > Fit ( this ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
// Connect Events
2018-08-25 16:49:51 +00:00
this - > Connect ( wxEVT_UPDATE_UI , wxUpdateUIEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnUpdateUI ) ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > Connect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnSizeNetclassGrid ) , NULL , this ) ;
m_addButton - > Connect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnAddNetclassClick ) , NULL , this ) ;
m_removeButton - > Connect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnRemoveNetclassClick ) , NULL , this ) ;
2020-11-24 16:03:48 +00:00
m_membershipPane - > Connect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : onmembershipPanelSize ) , NULL , this ) ;
2022-08-14 11:03:18 +00:00
m_assignmentGrid - > Connect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnSizeAssignmentGrid ) , NULL , this ) ;
m_assignmentGrid - > Connect ( wxEVT_UPDATE_UI , wxUpdateUIEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnUpdateUI ) , NULL , this ) ;
m_addAssignmentButton - > Connect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnAddAssignmentClick ) , NULL , this ) ;
m_removeAssignmentButton - > Connect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnRemoveAssignmentClick ) , NULL , this ) ;
2018-04-28 15:22:25 +00:00
}
PANEL_SETUP_NETCLASSES_BASE : : ~ PANEL_SETUP_NETCLASSES_BASE ( )
{
// Disconnect Events
2018-08-25 16:49:51 +00:00
this - > Disconnect ( wxEVT_UPDATE_UI , wxUpdateUIEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnUpdateUI ) ) ;
2018-04-28 15:22:25 +00:00
m_netclassGrid - > Disconnect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnSizeNetclassGrid ) , NULL , this ) ;
m_addButton - > Disconnect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnAddNetclassClick ) , NULL , this ) ;
m_removeButton - > Disconnect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnRemoveNetclassClick ) , NULL , this ) ;
2020-11-24 16:03:48 +00:00
m_membershipPane - > Disconnect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : onmembershipPanelSize ) , NULL , this ) ;
2022-08-14 11:03:18 +00:00
m_assignmentGrid - > Disconnect ( wxEVT_SIZE , wxSizeEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnSizeAssignmentGrid ) , NULL , this ) ;
m_assignmentGrid - > Disconnect ( wxEVT_UPDATE_UI , wxUpdateUIEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnUpdateUI ) , NULL , this ) ;
m_addAssignmentButton - > Disconnect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnAddAssignmentClick ) , NULL , this ) ;
m_removeAssignmentButton - > Disconnect ( wxEVT_COMMAND_BUTTON_CLICKED , wxCommandEventHandler ( PANEL_SETUP_NETCLASSES_BASE : : OnRemoveAssignmentClick ) , NULL , this ) ;
2019-02-10 08:49:42 +00:00
2018-04-28 15:22:25 +00:00
}