diff --git a/common/dialogs/panel_display_options.cpp b/common/dialogs/panel_gal_display_options.cpp similarity index 87% rename from common/dialogs/panel_display_options.cpp rename to common/dialogs/panel_gal_display_options.cpp index 2a7a06e906..d714f68c00 100644 --- a/common/dialogs/panel_display_options.cpp +++ b/common/dialogs/panel_gal_display_options.cpp @@ -22,10 +22,10 @@ #include #include -#include +#include -PANEL_DISPLAY_OPTIONS::PANEL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aFrame, PAGED_DIALOG* aParent ) : +PANEL_GAL_DISPLAY_OPTIONS::PANEL_GAL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aFrame, PAGED_DIALOG* aParent ) : wxPanel( aParent->GetTreebook(), wxID_ANY ), m_frame( aFrame ) { @@ -44,14 +44,14 @@ PANEL_DISPLAY_OPTIONS::PANEL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aFrame, PAGED_DIAL } -bool PANEL_DISPLAY_OPTIONS::TransferDataToWindow() +bool PANEL_GAL_DISPLAY_OPTIONS::TransferDataToWindow() { m_galOptsPanel->TransferDataToWindow(); return true; } -bool PANEL_DISPLAY_OPTIONS::TransferDataFromWindow() +bool PANEL_GAL_DISPLAY_OPTIONS::TransferDataFromWindow() { m_galOptsPanel->TransferDataFromWindow(); diff --git a/common/dialogs/panel_display_options.h b/common/dialogs/panel_gal_display_options.h similarity index 90% rename from common/dialogs/panel_display_options.h rename to common/dialogs/panel_gal_display_options.h index d233ef21e5..06f519ce62 100644 --- a/common/dialogs/panel_display_options.h +++ b/common/dialogs/panel_gal_display_options.h @@ -27,10 +27,10 @@ class GAL_OPTIONS_PANEL; class EDA_DRAW_FRAME; class PAGED_DIALOG; -class PANEL_DISPLAY_OPTIONS : public wxPanel +class PANEL_GAL_DISPLAY_OPTIONS : public wxPanel { public: - PANEL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aParent, PAGED_DIALOG* aWindow ); + PANEL_GAL_DISPLAY_OPTIONS( EDA_DRAW_FRAME* aParent, PAGED_DIALOG* aWindow ); private: bool TransferDataToWindow() override; diff --git a/eeschema/CMakeLists.txt b/eeschema/CMakeLists.txt index 953f859203..113b0a9efa 100644 --- a/eeschema/CMakeLists.txt +++ b/eeschema/CMakeLists.txt @@ -253,7 +253,7 @@ set( EESCHEMA_SRCS set( EESCHEMA_COMMON_SRCS ${CMAKE_SOURCE_DIR}/common/dialogs/dialog_page_settings.cpp - ${CMAKE_SOURCE_DIR}/common/dialogs/panel_display_options.cpp + ${CMAKE_SOURCE_DIR}/common/dialogs/panel_gal_display_options.cpp ${CMAKE_SOURCE_DIR}/common/dialogs/panel_setup_severities.cpp ${CMAKE_SOURCE_DIR}/common/common.cpp ${CMAKE_SOURCE_DIR}/common/base_screen.cpp diff --git a/eeschema/eeschema_config.cpp b/eeschema/eeschema_config.cpp index e4461d8235..a4ecf27766 100644 --- a/eeschema/eeschema_config.cpp +++ b/eeschema/eeschema_config.cpp @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include @@ -511,7 +511,7 @@ void LIB_EDIT_FRAME::InstallPreferences( PAGED_DIALOG* aParent, wxTreebook* book = aParent->GetTreebook(); book->AddPage( new wxPanel( book ), _( "Symbol Editor" ) ); - book->AddSubPage( new PANEL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); + book->AddSubPage( new PANEL_GAL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); book->AddSubPage( new PANEL_LIBEDIT_SETTINGS( this, book ), _( "Editing Options" ) ); book->AddSubPage( new PANEL_LIBEDIT_COLOR_SETTINGS( this, book ), _( "Colors" ) ); diff --git a/include/eda_draw_frame.h b/include/eda_draw_frame.h index 464a38365b..ad4a326385 100644 --- a/include/eda_draw_frame.h +++ b/include/eda_draw_frame.h @@ -60,6 +60,7 @@ using KIGFX::RENDER_SETTINGS; #define FOOTPRINT_VIEWER_FRAME_NAME wxT( "ModViewFrame" ) #define FOOTPRINT_VIEWER_FRAME_NAME_MODAL wxT( "ModViewFrameModal" ) #define PCB_EDIT_FRAME_NAME wxT( "PcbFrame" ) +#define SHAPE_EDIT_FRAME_NAME wxT( "ShapeEditFrame" ) /** diff --git a/include/frame_type.h b/include/frame_type.h index d122b0f769..4d508c750a 100644 --- a/include/frame_type.h +++ b/include/frame_type.h @@ -46,6 +46,7 @@ enum FRAME_T FRAME_FOOTPRINT_WIZARD, FRAME_PCB_DISPLAY3D, FRAME_FOOTPRINT_PREVIEW, + FRAME_SHAPE_EDITOR, FRAME_CVPCB, FRAME_CVPCB_DISPLAY, diff --git a/pagelayout_editor/CMakeLists.txt b/pagelayout_editor/CMakeLists.txt index ee0219f64b..43bca0376f 100644 --- a/pagelayout_editor/CMakeLists.txt +++ b/pagelayout_editor/CMakeLists.txt @@ -47,7 +47,7 @@ set( PL_EDITOR_EXTRA_SRCS ${CMAKE_SOURCE_DIR}/common/base_units.cpp ${CMAKE_SOURCE_DIR}/common/eda_text.cpp ${CMAKE_SOURCE_DIR}/common/dialogs/dialog_page_settings.cpp - ${CMAKE_SOURCE_DIR}/common/dialogs/panel_display_options.cpp + ${CMAKE_SOURCE_DIR}/common/dialogs/panel_gal_display_options.cpp ${CMAKE_SOURCE_DIR}/common/page_info.cpp ) diff --git a/pagelayout_editor/pl_editor_frame.cpp b/pagelayout_editor/pl_editor_frame.cpp index 877f7cb4ea..166ba1391c 100644 --- a/pagelayout_editor/pl_editor_frame.cpp +++ b/pagelayout_editor/pl_editor_frame.cpp @@ -38,7 +38,7 @@ #include #include #include -#include +#include #include #include #include @@ -407,7 +407,7 @@ void PL_EDITOR_FRAME::InstallPreferences( PAGED_DIALOG* aParent, { wxTreebook* book = aParent->GetTreebook(); - book->AddPage( new PANEL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); + book->AddPage( new PANEL_GAL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); book->AddPage( new PANEL_PL_EDITOR_COLOR_SETTINGS( this, aParent ), _( "Colors" ) ); aHotkeysPanel->AddHotKeys( GetToolManager() ); diff --git a/pcbnew/CMakeLists.txt b/pcbnew/CMakeLists.txt index c3faa6a7f1..bba3b69980 100644 --- a/pcbnew/CMakeLists.txt +++ b/pcbnew/CMakeLists.txt @@ -142,19 +142,16 @@ set( PCBNEW_DIALOGS dialogs/dialog_track_via_size_base.cpp dialogs/dialog_update_pcb.cpp dialogs/dialog_update_pcb_base.cpp + dialogs/panel_display_options.cpp + dialogs/panel_display_options_base.cpp + dialogs/panel_edit_options.cpp + dialogs/panel_edit_options_base.cpp dialogs/panel_fp_lib_table.cpp dialogs/panel_fp_lib_table_base.cpp dialogs/panel_modedit_color_settings.cpp dialogs/panel_modedit_defaults.cpp dialogs/panel_modedit_defaults_base.cpp - dialogs/panel_modedit_display_options.cpp - dialogs/panel_modedit_settings.cpp - dialogs/panel_modedit_settings_base.cpp dialogs/panel_pcbnew_color_settings.cpp - dialogs/panel_pcbnew_display_options.cpp - dialogs/panel_pcbnew_display_options_base.cpp - dialogs/panel_pcbnew_settings.cpp - dialogs/panel_pcbnew_settings_base.cpp dialogs/panel_setup_mask_and_paste.cpp dialogs/panel_setup_mask_and_paste_base.cpp dialogs/panel_setup_feature_constraints.cpp diff --git a/pcbnew/dialogs/panel_pcbnew_display_options.cpp b/pcbnew/dialogs/panel_display_options.cpp similarity index 54% rename from pcbnew/dialogs/panel_pcbnew_display_options.cpp rename to pcbnew/dialogs/panel_display_options.cpp index dfa8ee1a52..a9fcfc6a0d 100644 --- a/pcbnew/dialogs/panel_pcbnew_display_options.cpp +++ b/pcbnew/dialogs/panel_display_options.cpp @@ -2,7 +2,7 @@ * This program source code file is part of KiCad, a free EDA CAD application. * * Copyright (C) 2015 Jean-Pierre Charras, jean-pierre.charras at wanadoo.fr - * Copyright (C) 1992-2018 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors. * * This program is free software: you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the @@ -23,8 +23,7 @@ #include #include #include -#include -#include +#include #include #include #include @@ -41,29 +40,36 @@ static const UTIL::CFG_MAP }; -PANEL_PCBNEW_DISPLAY_OPTIONS::PANEL_PCBNEW_DISPLAY_OPTIONS( PCB_EDIT_FRAME* aFrame, - PAGED_DIALOG* aParent ) : - PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( aParent->GetTreebook() ), +PANEL_DISPLAY_OPTIONS::PANEL_DISPLAY_OPTIONS( PCB_BASE_FRAME* aFrame, + PAGED_DIALOG* aParent ) : + PANEL_DISPLAY_OPTIONS_BASE( aParent->GetTreebook() ), m_frame( aFrame ) { KIGFX::GAL_DISPLAY_OPTIONS& galOptions = m_frame->GetGalDisplayOptions(); m_galOptsPanel = new GAL_OPTIONS_PANEL( this, galOptions ); m_galOptionsSizer->Add( m_galOptsPanel, 1, wxEXPAND, 0 ); + + m_optionsBook->SetSelection( dynamic_cast( m_frame ) ? 1 : 0 ); } -bool PANEL_PCBNEW_DISPLAY_OPTIONS::TransferDataToWindow() +bool PANEL_DISPLAY_OPTIONS::TransferDataToWindow() { - auto& displ_opts = m_frame->GetDisplayOptions(); + PCB_EDIT_FRAME* pcbEdit = dynamic_cast( m_frame ); - m_OptDisplayTracksClearance->SetSelection( UTIL::GetConfigForVal( - traceClearanceSelectMap, displ_opts.m_ShowTrackClearanceMode ) ); + if( pcbEdit ) + { + const PCB_DISPLAY_OPTIONS& displ_opts = pcbEdit->GetDisplayOptions(); - m_OptDisplayPadClearence->SetValue( displ_opts.m_DisplayPadIsol ); - m_OptDisplayPadNumber->SetValue( displ_opts.m_DisplayPadNum ); - m_OptDisplayPadNoConn->SetValue( m_frame->IsElementVisible( LAYER_NO_CONNECTS ) ); - m_ShowNetNamesOption->SetSelection( displ_opts.m_DisplayNetNamesMode ); + m_OptDisplayTracksClearance->SetSelection( UTIL::GetConfigForVal( + traceClearanceSelectMap, displ_opts.m_ShowTrackClearanceMode ) ); + + m_OptDisplayPadClearence->SetValue( displ_opts.m_DisplayPadIsol ); + m_OptDisplayPadNumber->SetValue( displ_opts.m_DisplayPadNum ); + m_OptDisplayPadNoConn->SetValue( pcbEdit->IsElementVisible( LAYER_NO_CONNECTS ) ); + m_ShowNetNamesOption->SetSelection( displ_opts.m_DisplayNetNamesMode ); + } m_galOptsPanel->TransferDataToWindow(); @@ -74,20 +80,8 @@ bool PANEL_PCBNEW_DISPLAY_OPTIONS::TransferDataToWindow() /* * Update variables with new options */ -bool PANEL_PCBNEW_DISPLAY_OPTIONS::TransferDataFromWindow() +bool PANEL_DISPLAY_OPTIONS::TransferDataFromWindow() { - PCB_DISPLAY_OPTIONS displ_opts = m_frame->GetDisplayOptions(); - - displ_opts.m_ShowTrackClearanceMode = UTIL::GetValFromConfig( - traceClearanceSelectMap, m_OptDisplayTracksClearance->GetSelection() ); - - displ_opts.m_DisplayPadIsol = m_OptDisplayPadClearence->GetValue(); - displ_opts.m_DisplayPadNum = m_OptDisplayPadNumber->GetValue(); - - m_frame->SetElementVisibility( LAYER_NO_CONNECTS, m_OptDisplayPadNoConn->GetValue() ); - - displ_opts.m_DisplayNetNamesMode = m_ShowNetNamesOption->GetSelection(); - m_galOptsPanel->TransferDataFromWindow(); // Apply changes to the GAL @@ -95,9 +89,26 @@ bool PANEL_PCBNEW_DISPLAY_OPTIONS::TransferDataFromWindow() KIGFX::PCB_PAINTER* painter = static_cast( view->GetPainter() ); KIGFX::PCB_RENDER_SETTINGS* settings = painter->GetSettings(); - m_frame->SetDisplayOptions( displ_opts ); - settings->LoadDisplayOptions( displ_opts, m_frame->ShowPageLimits() ); - m_frame->SetElementVisibility( LAYER_RATSNEST, displ_opts.m_ShowGlobalRatsnest ); + PCB_EDIT_FRAME* pcbEdit = dynamic_cast( m_frame ); + + if( pcbEdit ) + { + PCB_DISPLAY_OPTIONS displ_opts = pcbEdit->GetDisplayOptions(); + + displ_opts.m_ShowTrackClearanceMode = UTIL::GetValFromConfig( + traceClearanceSelectMap, m_OptDisplayTracksClearance->GetSelection() ); + + displ_opts.m_DisplayPadIsol = m_OptDisplayPadClearence->GetValue(); + displ_opts.m_DisplayPadNum = m_OptDisplayPadNumber->GetValue(); + + pcbEdit->SetElementVisibility( LAYER_NO_CONNECTS, m_OptDisplayPadNoConn->GetValue() ); + + displ_opts.m_DisplayNetNamesMode = m_ShowNetNamesOption->GetSelection(); + + pcbEdit->SetDisplayOptions( displ_opts ); + settings->LoadDisplayOptions( displ_opts, pcbEdit->ShowPageLimits() ); + pcbEdit->SetElementVisibility( LAYER_RATSNEST, displ_opts.m_ShowGlobalRatsnest ); + } view->RecacheAllItems(); view->MarkTargetDirty( KIGFX::TARGET_NONCACHED ); diff --git a/pcbnew/dialogs/panel_pcbnew_display_options.h b/pcbnew/dialogs/panel_display_options.h similarity index 76% rename from pcbnew/dialogs/panel_pcbnew_display_options.h rename to pcbnew/dialogs/panel_display_options.h index 64e7ee12e0..17023f4913 100644 --- a/pcbnew/dialogs/panel_pcbnew_display_options.h +++ b/pcbnew/dialogs/panel_display_options.h @@ -2,7 +2,7 @@ * This program source code file is part of KiCad, a free EDA CAD application. * * Copyright (C) 2010-2014 Jean-Pierre Charras, jean-pierre.charras at wanadoo.fr - * Copyright (C) 1992-2018 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors. * * This program is free software: you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the @@ -18,20 +18,20 @@ * with this program. If not, see . */ -#include "panel_pcbnew_display_options_base.h" +#include "panel_display_options_base.h" class GAL_OPTIONS_PANEL; -class PANEL_PCBNEW_DISPLAY_OPTIONS : public PANEL_PCBNEW_DISPLAY_OPTIONS_BASE +class PANEL_DISPLAY_OPTIONS : public PANEL_DISPLAY_OPTIONS_BASE { public: - PANEL_PCBNEW_DISPLAY_OPTIONS( PCB_EDIT_FRAME* aFrame, PAGED_DIALOG* aWindow ); + PANEL_DISPLAY_OPTIONS( PCB_BASE_FRAME* aFrame, PAGED_DIALOG* aWindow ); bool TransferDataFromWindow() override; bool TransferDataToWindow() override; private: - PCB_EDIT_FRAME* m_frame; + PCB_BASE_FRAME* m_frame; GAL_OPTIONS_PANEL* m_galOptsPanel; }; diff --git a/pcbnew/dialogs/panel_pcbnew_display_options_base.cpp b/pcbnew/dialogs/panel_display_options_base.cpp similarity index 68% rename from pcbnew/dialogs/panel_pcbnew_display_options_base.cpp rename to pcbnew/dialogs/panel_display_options_base.cpp index 4472c727dc..e982680b29 100644 --- a/pcbnew/dialogs/panel_pcbnew_display_options_base.cpp +++ b/pcbnew/dialogs/panel_display_options_base.cpp @@ -1,15 +1,15 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version v3.8.0) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! /////////////////////////////////////////////////////////////////////////// -#include "panel_pcbnew_display_options_base.h" +#include "panel_display_options_base.h" /////////////////////////////////////////////////////////////////////////// -PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name ) +PANEL_DISPLAY_OPTIONS_BASE::PANEL_DISPLAY_OPTIONS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name ) { wxBoxSizer* bMainSizer; bMainSizer = new wxBoxSizer( wxVERTICAL ); @@ -22,11 +22,17 @@ PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( wxWindow* bupperSizer->Add( m_galOptionsSizer, 1, wxEXPAND, 5 ); - wxBoxSizer* bRightSizer; - bRightSizer = new wxBoxSizer( wxVERTICAL ); + m_optionsBook = new wxSimplebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 ); + wxPanel* emptyPage; + emptyPage = new wxPanel( m_optionsBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); + m_optionsBook->AddPage( emptyPage, _("a page"), false ); + wxPanel* pcbPage; + pcbPage = new wxPanel( m_optionsBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); + wxBoxSizer* pcbOptionsSizer; + pcbOptionsSizer = new wxBoxSizer( wxVERTICAL ); wxStaticBoxSizer* sbAnnotations; - sbAnnotations = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Annotations") ), wxVERTICAL ); + sbAnnotations = new wxStaticBoxSizer( new wxStaticBox( pcbPage, wxID_ANY, _("Annotations") ), wxVERTICAL ); wxString m_ShowNetNamesOptionChoices[] = { _("Do not show"), _("Show on pads"), _("Show on tracks"), _("Show on pads and tracks") }; int m_ShowNetNamesOptionNChoices = sizeof( m_ShowNetNamesOptionChoices ) / sizeof( wxString ); @@ -45,10 +51,10 @@ PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( wxWindow* sbAnnotations->Add( m_OptDisplayPadNoConn, 0, wxBOTTOM|wxLEFT|wxRIGHT, 6 ); - bRightSizer->Add( sbAnnotations, 0, wxEXPAND|wxBOTTOM, 5 ); + pcbOptionsSizer->Add( sbAnnotations, 0, wxEXPAND|wxBOTTOM, 5 ); wxStaticBoxSizer* sbClearance; - sbClearance = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Clearance Outlines") ), wxVERTICAL ); + sbClearance = new wxStaticBoxSizer( new wxStaticBox( pcbPage, wxID_ANY, _("Clearance Outlines") ), wxVERTICAL ); wxString m_OptDisplayTracksClearanceChoices[] = { _("Do not show"), _("Show when creating tracks"), _("Show with via clearance at end"), _("Show when creating and editing tracks"), _("Show always") }; int m_OptDisplayTracksClearanceNChoices = sizeof( m_OptDisplayTracksClearanceChoices ) / sizeof( wxString ); @@ -62,10 +68,15 @@ PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( wxWindow* sbClearance->Add( m_OptDisplayPadClearence, 0, wxALL, 6 ); - bRightSizer->Add( sbClearance, 0, wxBOTTOM|wxEXPAND|wxTOP, 5 ); + pcbOptionsSizer->Add( sbClearance, 0, wxBOTTOM|wxEXPAND|wxTOP, 5 ); - bupperSizer->Add( bRightSizer, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); + pcbPage->SetSizer( pcbOptionsSizer ); + pcbPage->Layout(); + pcbOptionsSizer->Fit( pcbPage ); + m_optionsBook->AddPage( pcbPage, _("a page"), false ); + + bupperSizer->Add( m_optionsBook, 1, wxEXPAND | wxALL, 5 ); bMainSizer->Add( bupperSizer, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 ); @@ -76,6 +87,6 @@ PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::PANEL_PCBNEW_DISPLAY_OPTIONS_BASE( wxWindow* bMainSizer->Fit( this ); } -PANEL_PCBNEW_DISPLAY_OPTIONS_BASE::~PANEL_PCBNEW_DISPLAY_OPTIONS_BASE() +PANEL_DISPLAY_OPTIONS_BASE::~PANEL_DISPLAY_OPTIONS_BASE() { } diff --git a/pcbnew/dialogs/panel_display_options_base.fbp b/pcbnew/dialogs/panel_display_options_base.fbp new file mode 100644 index 0000000000..b45c30e4dd --- /dev/null +++ b/pcbnew/dialogs/panel_display_options_base.fbp @@ -0,0 +1,609 @@ + + + + + + C++ + 1 + source_name + 0 + 0 + res + UTF-8 + connect + panel_display_options_base + 1000 + none + + 1 + PanelDisplayOptions + + . + + 1 + 1 + 1 + 1 + UI + 1 + 0 + + 0 + wxAUI_MGR_DEFAULT + + + 1 + 1 + impl_virtual + + + 0 + wxID_ANY + + + PANEL_DISPLAY_OPTIONS_BASE + + -1,-1 + ; forward_declare + + + + wxTAB_TRAVERSAL + + + bMainSizer + wxVERTICAL + none + + 5 + wxEXPAND|wxRIGHT|wxLEFT + 0 + + + bupperSizer + wxHORIZONTAL + none + + 5 + wxEXPAND + 1 + + + m_galOptionsSizer + wxVERTICAL + protected + + + + 5 + wxEXPAND | wxALL + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_optionsBook + 1 + + + protected + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + + + a page + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + emptyPage + 1 + + + none + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + wxTAB_TRAVERSAL + + + + a page + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + pcbPage + 1 + + + none + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + wxTAB_TRAVERSAL + + + pcbOptionsSizer + wxVERTICAL + none + + 5 + wxEXPAND|wxBOTTOM + 0 + + wxID_ANY + Annotations + + sbAnnotations + wxVERTICAL + 1 + none + + 5 + wxEXPAND|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Do not show" "Show on pads" "Show on tracks" "Show on pads and tracks" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Net Names + 1 + + 0 + + + 0 + + 1 + m_ShowNetNamesOption + 1 + + + protected + 1 + + Resizable + 0 + 1 + + wxRA_SPECIFY_COLS + + 0 + Show or hide net names on pads and/or tracks. + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 6 + wxALL + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show pad numbers + + 0 + + + 0 + + 1 + m_OptDisplayPadNumber + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 6 + wxBOTTOM|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show pad <no net> indicator + + 0 + + + 0 + + 1 + m_OptDisplayPadNoConn + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + 5 + wxBOTTOM|wxEXPAND|wxTOP + 0 + + wxID_ANY + Clearance Outlines + + sbClearance + wxVERTICAL + 1 + none + + 5 + wxEXPAND|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Do not show" "Show when creating tracks" "Show with via clearance at end" "Show when creating and editing tracks" "Show always" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + ID_SHOW_CLEARANCE + Track Clearance + 1 + + 0 + + + 0 + + 1 + m_OptDisplayTracksClearance + 1 + + + protected + 1 + + Resizable + 2 + 1 + + wxRA_SPECIFY_COLS + + 0 + Show or hide the track and via clearance area. If "New track" is selected, track clearance area is shown only when creating the track. + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 6 + wxALL + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show pad clearance + + 0 + + + 0 + + 1 + m_OptDisplayPadClearence + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + diff --git a/pcbnew/dialogs/panel_pcbnew_display_options_base.h b/pcbnew/dialogs/panel_display_options_base.h similarity index 70% rename from pcbnew/dialogs/panel_pcbnew_display_options_base.h rename to pcbnew/dialogs/panel_display_options_base.h index dc690a5d9a..ebd0919933 100644 --- a/pcbnew/dialogs/panel_pcbnew_display_options_base.h +++ b/pcbnew/dialogs/panel_display_options_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version v3.8.0) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -12,21 +12,22 @@ #include #include #include -#include -#include +#include #include #include #include +#include +#include #include #include -#include +#include /////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////// -/// Class PANEL_PCBNEW_DISPLAY_OPTIONS_BASE +/// Class PANEL_DISPLAY_OPTIONS_BASE /////////////////////////////////////////////////////////////////////////////// -class PANEL_PCBNEW_DISPLAY_OPTIONS_BASE : public wxPanel +class PANEL_DISPLAY_OPTIONS_BASE : public wxPanel { private: @@ -37,6 +38,7 @@ class PANEL_PCBNEW_DISPLAY_OPTIONS_BASE : public wxPanel }; wxBoxSizer* m_galOptionsSizer; + wxSimplebook* m_optionsBook; wxRadioBox* m_ShowNetNamesOption; wxCheckBox* m_OptDisplayPadNumber; wxCheckBox* m_OptDisplayPadNoConn; @@ -45,8 +47,8 @@ class PANEL_PCBNEW_DISPLAY_OPTIONS_BASE : public wxPanel public: - PANEL_PCBNEW_DISPLAY_OPTIONS_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 ); - ~PANEL_PCBNEW_DISPLAY_OPTIONS_BASE(); + PANEL_DISPLAY_OPTIONS_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 ); + ~PANEL_DISPLAY_OPTIONS_BASE(); }; diff --git a/pcbnew/dialogs/panel_pcbnew_settings.cpp b/pcbnew/dialogs/panel_edit_options.cpp similarity index 66% rename from pcbnew/dialogs/panel_pcbnew_settings.cpp rename to pcbnew/dialogs/panel_edit_options.cpp index 663f9dadba..4e732e8d8c 100644 --- a/pcbnew/dialogs/panel_pcbnew_settings.cpp +++ b/pcbnew/dialogs/panel_edit_options.cpp @@ -25,50 +25,66 @@ #include #include #include -#include +#include #include #include #include #include #include #include +#include -PANEL_PCBNEW_SETTINGS::PANEL_PCBNEW_SETTINGS( PCB_EDIT_FRAME* aFrame, PAGED_DIALOG* aParent ) : - PANEL_PCBNEW_SETTINGS_BASE( aParent->GetTreebook() ), +PANEL_EDIT_OPTIONS::PANEL_EDIT_OPTIONS( PCB_BASE_EDIT_FRAME* aFrame, PAGED_DIALOG* aParent ) : + PANEL_EDIT_OPTIONS_BASE( aParent->GetTreebook() ), m_Frame( aFrame ) -{} - - -bool PANEL_PCBNEW_SETTINGS::TransferDataToWindow() { - const PCB_DISPLAY_OPTIONS& displ_opts = m_Frame->GetDisplayOptions(); - const PCBNEW_SETTINGS& general_opts = m_Frame->Settings(); + m_MagneticPads->Show( dynamic_cast( m_Frame ) != nullptr ); + m_FlipLeftRight->Show( dynamic_cast( m_Frame ) != nullptr );\ + + m_optionsBook->SetSelection( dynamic_cast( m_Frame ) ? 1 : 0 ); +} + + +bool PANEL_EDIT_OPTIONS::TransferDataToWindow() +{ + const PCB_DISPLAY_OPTIONS& displ_opts = m_Frame->GetDisplayOptions(); + const PCBNEW_SETTINGS& general_opts = m_Frame->Settings(); - /* Set display options */ m_PolarDisplay->SetSelection( m_Frame->GetShowPolarCoords() ? 1 : 0 ); m_UnitsSelection->SetSelection( m_Frame->GetUserUnits() == EDA_UNITS::INCHES ? 0 : 1 ); - m_OptDisplayCurvedRatsnestLines->SetValue( displ_opts.m_DisplayRatsnestLinesCurved ); - m_showGlobalRatsnest->SetValue( displ_opts.m_ShowGlobalRatsnest ); - m_showSelectedRatsnest->SetValue( displ_opts.m_ShowModuleRatsnest ); - m_OptDisplayCurvedRatsnestLines->SetValue( displ_opts.m_DisplayRatsnestLinesCurved ); + + m_Segments_45_Only_Ctrl->SetValue( general_opts.m_Use45DegreeGraphicSegments ); wxString rotationAngle; rotationAngle = AngleToStringDegrees( (double)m_Frame->GetRotationAngle() ); m_RotationAngle->SetValue( rotationAngle ); - m_Segments_45_Only_Ctrl->SetValue( general_opts.m_Use45DegreeGraphicSegments ); - m_magneticPadChoice->SetSelection( static_cast( general_opts.m_MagneticItems.pads ) ); - m_magneticTrackChoice->SetSelection( static_cast( general_opts.m_MagneticItems.tracks ) ); - m_magneticGraphicsChoice->SetSelection( !general_opts.m_MagneticItems.graphics ); - m_FlipLeftRight->SetValue( general_opts.m_FlipLeftRight ); + if( dynamic_cast( m_Frame ) ) + { + /* Set display options */ + m_OptDisplayCurvedRatsnestLines->SetValue( displ_opts.m_DisplayRatsnestLinesCurved ); + m_showGlobalRatsnest->SetValue( displ_opts.m_ShowGlobalRatsnest ); + m_showSelectedRatsnest->SetValue( displ_opts.m_ShowModuleRatsnest ); + m_OptDisplayCurvedRatsnestLines->SetValue( displ_opts.m_DisplayRatsnestLinesCurved ); - m_Show_Page_Limits->SetValue( m_Frame->ShowPageLimits() ); + m_magneticPadChoice->SetSelection( static_cast( general_opts.m_MagneticItems.pads ) ); + m_magneticTrackChoice->SetSelection( static_cast( general_opts.m_MagneticItems.tracks ) ); + m_magneticGraphicsChoice->SetSelection( !general_opts.m_MagneticItems.graphics ); + m_FlipLeftRight->SetValue( general_opts.m_FlipLeftRight ); + + m_Show_Page_Limits->SetValue( m_Frame->ShowPageLimits() ); + } + else if( dynamic_cast( m_Frame ) ) + { + m_MagneticPads->SetValue( + m_Frame->GetMagneticItemsSettings()->pads == MAGNETIC_OPTIONS::CAPTURE_ALWAYS ); + } return true; } -bool PANEL_PCBNEW_SETTINGS::TransferDataFromWindow() +bool PANEL_EDIT_OPTIONS::TransferDataFromWindow() { m_Frame->SetShowPolarCoords( m_PolarDisplay->GetSelection() != 0 ); m_Frame->SetUserUnits( diff --git a/pcbnew/dialogs/panel_pcbnew_settings.h b/pcbnew/dialogs/panel_edit_options.h similarity index 81% rename from pcbnew/dialogs/panel_pcbnew_settings.h rename to pcbnew/dialogs/panel_edit_options.h index ed4ba190f7..f8dc7320ae 100644 --- a/pcbnew/dialogs/panel_pcbnew_settings.h +++ b/pcbnew/dialogs/panel_edit_options.h @@ -2,7 +2,7 @@ * This program source code file is part of KiCad, a free EDA CAD application. * * Copyright (C) 2010-2014 Jean-Pierre Charras, jean-pierre.charras at wanadoo.fr - * Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 1992-2020 KiCad Developers, see AUTHORS.txt for contributors. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -25,18 +25,19 @@ #ifndef __dialog_general_options_h #define __dialog_general_options_h -#include "panel_pcbnew_settings_base.h" +#include "panel_edit_options_base.h" class PAGED_DIALOG; +class PCB_BASE_EDIT_FRAME; -class PANEL_PCBNEW_SETTINGS : public PANEL_PCBNEW_SETTINGS_BASE +class PANEL_EDIT_OPTIONS : public PANEL_EDIT_OPTIONS_BASE { private: - PCB_EDIT_FRAME* m_Frame; + PCB_BASE_EDIT_FRAME* m_Frame; public: - PANEL_PCBNEW_SETTINGS( PCB_EDIT_FRAME* aFrame, PAGED_DIALOG* aWindow ); + PANEL_EDIT_OPTIONS( PCB_BASE_EDIT_FRAME* aFrame, PAGED_DIALOG* aWindow ); protected: bool TransferDataToWindow() override; diff --git a/pcbnew/dialogs/panel_pcbnew_settings_base.cpp b/pcbnew/dialogs/panel_edit_options_base.cpp similarity index 82% rename from pcbnew/dialogs/panel_pcbnew_settings_base.cpp rename to pcbnew/dialogs/panel_edit_options_base.cpp index a437047d9c..b46c931e53 100644 --- a/pcbnew/dialogs/panel_pcbnew_settings_base.cpp +++ b/pcbnew/dialogs/panel_edit_options_base.cpp @@ -5,11 +5,11 @@ // PLEASE DO *NOT* EDIT THIS FILE! /////////////////////////////////////////////////////////////////////////// -#include "panel_pcbnew_settings_base.h" +#include "panel_edit_options_base.h" /////////////////////////////////////////////////////////////////////////// -PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name ) +PANEL_EDIT_OPTIONS_BASE::PANEL_EDIT_OPTIONS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name ) { wxBoxSizer* bPanelSizer; bPanelSizer = new wxBoxSizer( wxHORIZONTAL ); @@ -39,6 +39,9 @@ PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWind wxStaticBoxSizer* bOptionsSizer; bOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Editing Options") ), wxVERTICAL ); + m_MagneticPads = new wxCheckBox( bOptionsSizer->GetStaticBox(), wxID_ANY, _("Magnetic pads"), wxDefaultPosition, wxDefaultSize, 0 ); + bOptionsSizer->Add( m_MagneticPads, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + m_Segments_45_Only_Ctrl = new wxCheckBox( bOptionsSizer->GetStaticBox(), wxID_SEGMENTS45, _("L&imit graphic lines to H, V and 45 degrees"), wxDefaultPosition, wxDefaultSize, 0 ); m_Segments_45_Only_Ctrl->SetToolTip( _("Force line segment directions to H, V or 45 degrees when drawing on technical layers.") ); @@ -71,11 +74,17 @@ PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWind bMargins->Add( bMiddleLeftSizer, 1, wxEXPAND|wxRIGHT, 5 ); - wxBoxSizer* bRightSizer; - bRightSizer = new wxBoxSizer( wxVERTICAL ); + m_optionsBook = new wxSimplebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 ); + wxPanel* emptyPage; + emptyPage = new wxPanel( m_optionsBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); + m_optionsBook->AddPage( emptyPage, _("a page"), false ); + wxPanel* pcbPage; + pcbPage = new wxPanel( m_optionsBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); + wxBoxSizer* pcbOptionsSizer; + pcbOptionsSizer = new wxBoxSizer( wxVERTICAL ); wxStaticBoxSizer* sbMagnets; - sbMagnets = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Magnetic Points") ), wxVERTICAL ); + sbMagnets = new wxStaticBoxSizer( new wxStaticBox( pcbPage, wxID_ANY, _("Magnetic Points") ), wxVERTICAL ); wxFlexGridSizer* fgSizer2; fgSizer2 = new wxFlexGridSizer( 0, 2, 3, 0 ); @@ -128,10 +137,10 @@ PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWind sbMagnets->Add( fgSizer2, 1, wxEXPAND|wxBOTTOM, 5 ); - bRightSizer->Add( sbMagnets, 1, wxEXPAND, 5 ); + pcbOptionsSizer->Add( sbMagnets, 1, wxEXPAND, 5 ); wxStaticBoxSizer* sbSizer3; - sbSizer3 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Ratsnest") ), wxVERTICAL ); + sbSizer3 = new wxStaticBoxSizer( new wxStaticBox( pcbPage, wxID_ANY, _("Ratsnest") ), wxVERTICAL ); m_showGlobalRatsnest = new wxCheckBox( sbSizer3->GetStaticBox(), wxID_ANY, _("Show ratsnest"), wxDefaultPosition, wxDefaultSize, 0 ); sbSizer3->Add( m_showGlobalRatsnest, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); @@ -143,20 +152,25 @@ PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWind sbSizer3->Add( m_OptDisplayCurvedRatsnestLines, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - bRightSizer->Add( sbSizer3, 1, wxEXPAND, 5 ); + pcbOptionsSizer->Add( sbSizer3, 1, wxEXPAND|wxTOP, 5 ); wxStaticBoxSizer* sbSizer4; - sbSizer4 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Annotations") ), wxVERTICAL ); + sbSizer4 = new wxStaticBoxSizer( new wxStaticBox( pcbPage, wxID_ANY, _("Annotations") ), wxVERTICAL ); m_Show_Page_Limits = new wxCheckBox( sbSizer4->GetStaticBox(), wxID_ANY, _("Show page limits"), wxDefaultPosition, wxDefaultSize, 0 ); m_Show_Page_Limits->SetValue(true); sbSizer4->Add( m_Show_Page_Limits, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - bRightSizer->Add( sbSizer4, 1, wxEXPAND, 5 ); + pcbOptionsSizer->Add( sbSizer4, 0, wxEXPAND|wxTOP, 5 ); - bMargins->Add( bRightSizer, 1, wxEXPAND|wxTOP|wxRIGHT, 5 ); + pcbPage->SetSizer( pcbOptionsSizer ); + pcbPage->Layout(); + pcbOptionsSizer->Fit( pcbPage ); + m_optionsBook->AddPage( pcbPage, _("a page"), false ); + + bMargins->Add( m_optionsBook, 1, wxEXPAND | wxALL, 5 ); bPanelSizer->Add( bMargins, 1, wxRIGHT, 5 ); @@ -167,6 +181,6 @@ PANEL_PCBNEW_SETTINGS_BASE::PANEL_PCBNEW_SETTINGS_BASE( wxWindow* parent, wxWind bPanelSizer->Fit( this ); } -PANEL_PCBNEW_SETTINGS_BASE::~PANEL_PCBNEW_SETTINGS_BASE() +PANEL_EDIT_OPTIONS_BASE::~PANEL_EDIT_OPTIONS_BASE() { } diff --git a/pcbnew/dialogs/panel_edit_options_base.fbp b/pcbnew/dialogs/panel_edit_options_base.fbp new file mode 100644 index 0000000000..0b0636fa67 --- /dev/null +++ b/pcbnew/dialogs/panel_edit_options_base.fbp @@ -0,0 +1,1429 @@ + + + + + + C++ + 1 + source_name + 0 + 0 + res + UTF-8 + connect + panel_edit_options_base + 1000 + none + + 1 + PanelEditOptions + + . + + 1 + 1 + 1 + 1 + UI + 1 + 0 + + 0 + wxAUI_MGR_DEFAULT + + + 1 + 1 + impl_virtual + + + 0 + wxID_ANY + + + PANEL_EDIT_OPTIONS_BASE + + -1,-1 + ; forward_declare + + + + wxTAB_TRAVERSAL + + + bPanelSizer + wxHORIZONTAL + none + + 5 + wxRIGHT + 1 + + + bMargins + wxHORIZONTAL + none + + 5 + wxEXPAND|wxRIGHT + 1 + + + bMiddleLeftSizer + wxVERTICAL + none + + 5 + wxALL|wxEXPAND + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Cartesian coordinates" "Polar coordinates" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_POLAR_CTRL + Coordinates + 1 + + 0 + + + 0 + + 1 + m_PolarDisplay + 1 + + + protected + 1 + + Resizable + 0 + 1 + + wxRA_SPECIFY_COLS + + 0 + Set display of relative (dx/dy) coordinates to Cartesian (rectangular) or polar (angle/distance). + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxALL|wxEXPAND + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Inches" "Millimeters" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_UNITS + Units + 1 + + 0 + + + 0 + + 1 + m_UnitsSelection + 1 + + + protected + 1 + + Resizable + 0 + 1 + + wxRA_SPECIFY_COLS + + 0 + Set units used to display dimensions and positions. + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxEXPAND|wxTOP|wxRIGHT|wxLEFT + 1 + + wxID_ANY + Editing Options + + bOptionsSizer + wxVERTICAL + 1 + none + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Magnetic pads + + 0 + + + 0 + + 1 + m_MagneticPads + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxBOTTOM|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_SEGMENTS45 + L&imit graphic lines to H, V and 45 degrees + + 0 + + + 0 + + 1 + m_Segments_45_Only_Ctrl + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + Force line segment directions to H, V or 45 degrees when drawing on technical layers. + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Flip board items L/R (default is T/B) + + 0 + + + 0 + + 1 + m_FlipLeftRight + 1 + + + protected + 1 + + Resizable + 1 + + + ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxEXPAND + 1 + + 2 + wxBOTH + 1 + + 0 + + fgSizer12 + wxFLEX_GROWMODE_SPECIFIED + none + 0 + 0 + + 5 + wxALIGN_CENTER_VERTICAL|wxALL + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + &Rotation angle: + 0 + + 0 + + + 0 + + 1 + m_staticTextRotationAngle + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxALIGN_CENTER_VERTICAL|wxALL|wxEXPAND + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + + 0 + + 1 + m_RotationAngle + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + Set increment (in degrees) for context menu and hotkey rotation. + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + 5 + wxEXPAND | wxALL + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_optionsBook + 1 + + + protected + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + + + a page + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + emptyPage + 1 + + + none + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + wxTAB_TRAVERSAL + + + + a page + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + pcbPage + 1 + + + none + 1 + + Resizable + 1 + + ; ; forward_declare + 0 + + + + wxTAB_TRAVERSAL + + + pcbOptionsSizer + wxVERTICAL + none + + 5 + wxEXPAND + 1 + + wxID_ANY + Magnetic Points + + sbMagnets + wxVERTICAL + 1 + none + + 5 + wxEXPAND|wxBOTTOM + 1 + + 2 + wxBOTH + + + 0 + + fgSizer2 + wxFLEX_GROWMODE_SPECIFIED + none + 0 + 3 + + 5 + wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Snap to pads: + 0 + + 0 + + + 0 + + 1 + m_staticText2 + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse enters a pad area + + + + -1 + + + + 5 + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Never" "When creating tracks" "Always" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_magneticPadChoice + 1 + + + protected + 1 + + Resizable + 1 + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse enters a pad area + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Snap to tracks: + 0 + + 0 + + + 0 + + 1 + m_staticText21 + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse approaches a track + + + + -1 + + + + 5 + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Never" "When creating tracks" "Always" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_magneticTrackChoice + 1 + + + protected + 1 + + Resizable + 1 + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse approaches a track + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Snap to graphics: + 0 + + 0 + + + 0 + + 1 + m_staticText211 + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse approaches graphical control points + + + + -1 + + + + 5 + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + "Always" "Never" + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_magneticGraphicsChoice + 1 + + + protected + 1 + + Resizable + 0 + 1 + + + ; ; forward_declare + 0 + Capture cursor when the mouse approaches graphical control points + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + 5 + wxEXPAND|wxTOP + 1 + + wxID_ANY + Ratsnest + + sbSizer3 + wxVERTICAL + 1 + none + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show ratsnest + + 0 + + + 0 + + 1 + m_showGlobalRatsnest + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Always show selected ratsnest + + 0 + + + 0 + + 1 + m_showSelectedRatsnest + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show ratsnest with curved lines + + 0 + + + 0 + + 1 + m_OptDisplayCurvedRatsnestLines + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + 5 + wxEXPAND|wxTOP + 0 + + wxID_ANY + Annotations + + sbSizer4 + wxVERTICAL + 1 + none + + 5 + wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Show page limits + + 0 + + + 0 + + 1 + m_Show_Page_Limits + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + + + + + + + + + + + + + + diff --git a/pcbnew/dialogs/panel_pcbnew_settings_base.h b/pcbnew/dialogs/panel_edit_options_base.h similarity index 79% rename from pcbnew/dialogs/panel_pcbnew_settings_base.h rename to pcbnew/dialogs/panel_edit_options_base.h index 9489e85a7c..fac95c0466 100644 --- a/pcbnew/dialogs/panel_pcbnew_settings_base.h +++ b/pcbnew/dialogs/panel_edit_options_base.h @@ -21,15 +21,16 @@ #include #include #include -#include #include +#include +#include /////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////// -/// Class PANEL_PCBNEW_SETTINGS_BASE +/// Class PANEL_EDIT_OPTIONS_BASE /////////////////////////////////////////////////////////////////////////////// -class PANEL_PCBNEW_SETTINGS_BASE : public wxPanel +class PANEL_EDIT_OPTIONS_BASE : public wxPanel { private: @@ -43,10 +44,12 @@ class PANEL_PCBNEW_SETTINGS_BASE : public wxPanel wxRadioBox* m_PolarDisplay; wxRadioBox* m_UnitsSelection; + wxCheckBox* m_MagneticPads; wxCheckBox* m_Segments_45_Only_Ctrl; wxCheckBox* m_FlipLeftRight; wxStaticText* m_staticTextRotationAngle; wxTextCtrl* m_RotationAngle; + wxSimplebook* m_optionsBook; wxStaticText* m_staticText2; wxChoice* m_magneticPadChoice; wxStaticText* m_staticText21; @@ -60,8 +63,8 @@ class PANEL_PCBNEW_SETTINGS_BASE : public wxPanel public: - PANEL_PCBNEW_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 ); - ~PANEL_PCBNEW_SETTINGS_BASE(); + PANEL_EDIT_OPTIONS_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 ); + ~PANEL_EDIT_OPTIONS_BASE(); }; diff --git a/pcbnew/dialogs/panel_modedit_display_options.cpp b/pcbnew/dialogs/panel_modedit_display_options.cpp deleted file mode 100644 index 65a294659a..0000000000 --- a/pcbnew/dialogs/panel_modedit_display_options.cpp +++ /dev/null @@ -1,65 +0,0 @@ -/* - * This program source code file is part of KiCad, a free EDA CAD application. - * - * Copyright (C) 2017-2018 KiCad Developers, see AUTHORS.txt for contributors. - * - * This program is free software: you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation, either version 3 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - -#include -#include -#include -#include - -#include - - -PANEL_MODEDIT_DISPLAY_OPTIONS::PANEL_MODEDIT_DISPLAY_OPTIONS( FOOTPRINT_EDIT_FRAME* aFrame, - PAGED_DIALOG* aParent ) : - wxPanel( aParent->GetTreebook(), wxID_ANY ), - m_frame( aFrame ) -{ - auto mainSizer = new wxBoxSizer( wxHORIZONTAL ); - SetSizer( mainSizer ); - - // install GAL options pane - KIGFX::GAL_DISPLAY_OPTIONS& galOptions = m_frame->GetGalDisplayOptions(); - - m_galOptsPanel = new GAL_OPTIONS_PANEL( this, galOptions ); - mainSizer->Add( m_galOptsPanel, 1, wxEXPAND | wxLEFT, 5 ); - - // a spacer to take up the other half of the width - auto spacer = new wxPanel( this, wxID_ANY ); - mainSizer->Add( spacer, 1, wxEXPAND | wxLEFT, 5 ); -} - - -bool PANEL_MODEDIT_DISPLAY_OPTIONS::TransferDataToWindow() -{ - m_galOptsPanel->TransferDataToWindow(); - return true; -} - - -bool PANEL_MODEDIT_DISPLAY_OPTIONS::TransferDataFromWindow() -{ - m_galOptsPanel->TransferDataFromWindow(); - - // refresh view - m_frame->GetCanvas()->GetView()->RecacheAllItems(); - m_frame->GetCanvas()->GetView()->MarkTargetDirty( KIGFX::TARGET_NONCACHED ); - m_frame->GetCanvas()->Refresh(); - - return true; -} diff --git a/pcbnew/dialogs/panel_modedit_display_options.h b/pcbnew/dialogs/panel_modedit_display_options.h deleted file mode 100644 index 86b309a18a..0000000000 --- a/pcbnew/dialogs/panel_modedit_display_options.h +++ /dev/null @@ -1,43 +0,0 @@ -/* - * This program source code file is part of KiCad, a free EDA CAD application. - * - * Copyright (C) 2017-2018 KiCad Developers, see AUTHORS.txt for contributors. - * - * This program is free software: you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation, either version 3 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - - -#ifndef KICAD_PANEL_MODEDIT_DISPLAY_OPTIONS_H -#define KICAD_PANEL_MODEDIT_DISPLAY_OPTIONS_H - -#include - -class GAL_OPTIONS_PANEL; -class FOOTPRINT_EDIT_FRAME; -class PAGED_DIALOG; - -class PANEL_MODEDIT_DISPLAY_OPTIONS : public wxPanel -{ -public: - PANEL_MODEDIT_DISPLAY_OPTIONS( FOOTPRINT_EDIT_FRAME* aFrame, PAGED_DIALOG* aParent ); - -private: - bool TransferDataToWindow() override; - bool TransferDataFromWindow() override; - - FOOTPRINT_EDIT_FRAME* m_frame; - GAL_OPTIONS_PANEL* m_galOptsPanel; -}; - -#endif //KICAD_PANEL_MODEDIT_DISPLAY_OPTIONS_H diff --git a/pcbnew/dialogs/panel_modedit_settings.cpp b/pcbnew/dialogs/panel_modedit_settings.cpp deleted file mode 100644 index 00eba22cca..0000000000 --- a/pcbnew/dialogs/panel_modedit_settings.cpp +++ /dev/null @@ -1,70 +0,0 @@ -/* - * This program source code file is part of KiCad, a free EDA CAD application. - * - * Copyright (C) 1992-2016 KiCad Developers, see AUTHORS.txt for contributors. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, you may find one here: - * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html - * or you may search the http://www.gnu.org website for the version 2 license, - * or you may write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include -#include -#include -#include -#include -#include -#include - -#include - - -PANEL_MODEDIT_SETTINGS::PANEL_MODEDIT_SETTINGS( FOOTPRINT_EDIT_FRAME* aFrame, - PAGED_DIALOG* aParent) : - PANEL_MODEDIT_SETTINGS_BASE( aParent->GetTreebook() ), - m_frame( aFrame ) -{} - - -bool PANEL_MODEDIT_SETTINGS::TransferDataToWindow() -{ - // Display options - m_PolarDisplay->SetSelection( m_frame->GetShowPolarCoords() ? 1 : 0 ); - m_UnitsSelection->SetSelection( m_frame->GetUserUnits() == EDA_UNITS::INCHES ? 0 : 1 ); - - // Editing options - m_Segments_45_Only_Ctrl->SetValue( m_frame->Settings().m_Use45DegreeGraphicSegments ); - m_MagneticPads->SetValue( - m_frame->GetMagneticItemsSettings()->pads == MAGNETIC_OPTIONS::CAPTURE_ALWAYS ); - - return true; -} - - -bool PANEL_MODEDIT_SETTINGS::TransferDataFromWindow() -{ - // Display options - m_frame->SetShowPolarCoords( m_PolarDisplay->GetSelection() != 0 ); - m_frame->SetUserUnits( - m_UnitsSelection->GetSelection() == 0 ? EDA_UNITS::INCHES : EDA_UNITS::MILLIMETRES ); - - // Editing options - m_frame->Settings().m_Use45DegreeGraphicSegments = m_Segments_45_Only_Ctrl->GetValue(); - m_frame->GetMagneticItemsSettings()->pads = m_MagneticPads->GetValue() ? - MAGNETIC_OPTIONS::CAPTURE_ALWAYS : MAGNETIC_OPTIONS::NO_EFFECT; - - return true; -} diff --git a/pcbnew/dialogs/panel_modedit_settings.h b/pcbnew/dialogs/panel_modedit_settings.h deleted file mode 100644 index cfb9b37117..0000000000 --- a/pcbnew/dialogs/panel_modedit_settings.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * This program source code file is part of KiCad, a free EDA CAD application. - * - * Copyright (C) 2017-2018 KiCad Developers, see AUTHORS.txt for contributors. - * - * This program is free software: you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation, either version 3 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - -#ifndef KICAD_PANEL_MODEDIT_SETTINGS_H -#define KICAD_PANEL_MODEDIT_SETTINGS_H - -#include - -class FOOTPRINT_EDIT_FRAME; -class PAGED_DIALOG; - - -class PANEL_MODEDIT_SETTINGS : public PANEL_MODEDIT_SETTINGS_BASE -{ - FOOTPRINT_EDIT_FRAME* m_frame; - -public: - PANEL_MODEDIT_SETTINGS( FOOTPRINT_EDIT_FRAME* aFrame, PAGED_DIALOG* aWindow ); - -private: - bool TransferDataToWindow() override; - bool TransferDataFromWindow() override; -}; - - -#endif //KICAD_PANEL_MODEDIT_SETTINGS_H diff --git a/pcbnew/dialogs/panel_modedit_settings_base.cpp b/pcbnew/dialogs/panel_modedit_settings_base.cpp deleted file mode 100644 index fd8b09b437..0000000000 --- a/pcbnew/dialogs/panel_modedit_settings_base.cpp +++ /dev/null @@ -1,67 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Dec 30 2017) -// http://www.wxformbuilder.org/ -// -// PLEASE DO *NOT* EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#include "panel_modedit_settings_base.h" - -/////////////////////////////////////////////////////////////////////////// - -PANEL_MODEDIT_SETTINGS_BASE::PANEL_MODEDIT_SETTINGS_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style ) : wxPanel( parent, id, pos, size, style ) -{ - wxBoxSizer* bSizerMain; - bSizerMain = new wxBoxSizer( wxHORIZONTAL ); - - wxBoxSizer* bSizerColumns; - bSizerColumns = new wxBoxSizer( wxVERTICAL ); - - wxBoxSizer* bSizerDisplayOptions; - bSizerDisplayOptions = new wxBoxSizer( wxVERTICAL ); - - wxString m_PolarDisplayChoices[] = { _("Cartesian coordinates"), _("Polar coordinates") }; - int m_PolarDisplayNChoices = sizeof( m_PolarDisplayChoices ) / sizeof( wxString ); - m_PolarDisplay = new wxRadioBox( this, wxID_POLAR_CTRL, _("Coordinates"), wxDefaultPosition, wxDefaultSize, m_PolarDisplayNChoices, m_PolarDisplayChoices, 1, wxRA_SPECIFY_COLS ); - m_PolarDisplay->SetSelection( 0 ); - m_PolarDisplay->SetToolTip( _("Set display of relative (dx/dy) coordinates to Cartesian (rectangular) or polar (angle/distance).") ); - - bSizerDisplayOptions->Add( m_PolarDisplay, 0, wxEXPAND|wxBOTTOM, 5 ); - - wxString m_UnitsSelectionChoices[] = { _("Inches"), _("Millimeters") }; - int m_UnitsSelectionNChoices = sizeof( m_UnitsSelectionChoices ) / sizeof( wxString ); - m_UnitsSelection = new wxRadioBox( this, wxID_UNITS, _("Units"), wxDefaultPosition, wxDefaultSize, m_UnitsSelectionNChoices, m_UnitsSelectionChoices, 1, wxRA_SPECIFY_COLS ); - m_UnitsSelection->SetSelection( 0 ); - m_UnitsSelection->SetToolTip( _("Set units used to display dimensions and positions.") ); - - bSizerDisplayOptions->Add( m_UnitsSelection, 0, wxEXPAND|wxBOTTOM, 5 ); - - - bSizerColumns->Add( bSizerDisplayOptions, 0, wxEXPAND, 5 ); - - wxStaticBoxSizer* sbSizerEditOptions; - sbSizerEditOptions = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Editing Options") ), wxVERTICAL ); - - m_MagneticPads = new wxCheckBox( sbSizerEditOptions->GetStaticBox(), wxID_ANY, _("Magnetic pads"), wxDefaultPosition, wxDefaultSize, 0 ); - sbSizerEditOptions->Add( m_MagneticPads, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - - m_Segments_45_Only_Ctrl = new wxCheckBox( sbSizerEditOptions->GetStaticBox(), wxID_SEGMENTS45, _("L&imit graphic lines to H, V and 45 degrees"), wxDefaultPosition, wxDefaultSize, 0 ); - m_Segments_45_Only_Ctrl->SetToolTip( _("Force line segment directions to H, V or 45 degrees when drawing on technical layers.") ); - - sbSizerEditOptions->Add( m_Segments_45_Only_Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - - - bSizerColumns->Add( sbSizerEditOptions, 0, wxEXPAND|wxTOP|wxBOTTOM, 5 ); - - - bSizerMain->Add( bSizerColumns, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); - - - this->SetSizer( bSizerMain ); - this->Layout(); - bSizerMain->Fit( this ); -} - -PANEL_MODEDIT_SETTINGS_BASE::~PANEL_MODEDIT_SETTINGS_BASE() -{ -} diff --git a/pcbnew/dialogs/panel_modedit_settings_base.fbp b/pcbnew/dialogs/panel_modedit_settings_base.fbp deleted file mode 100644 index d18ad5c3a8..0000000000 --- a/pcbnew/dialogs/panel_modedit_settings_base.fbp +++ /dev/null @@ -1,482 +0,0 @@ - - - - - - C++ - 1 - source_name - 0 - 0 - res - UTF-8 - connect - panel_modedit_settings_base - 1000 - none - 1 - PanelModeditSettings - - . - - 1 - 1 - 1 - 1 - UI - 0 - 0 - - 0 - wxAUI_MGR_DEFAULT - - - 1 - 1 - impl_virtual - - - 0 - wxID_ANY - - - PANEL_MODEDIT_SETTINGS_BASE - - -1,-1 - ; forward_declare - - - - wxTAB_TRAVERSAL - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - bSizerMain - wxHORIZONTAL - none - - 5 - wxEXPAND|wxTOP|wxRIGHT|wxLEFT - 0 - - - bSizerColumns - wxVERTICAL - none - - 5 - wxEXPAND - 0 - - - bSizerDisplayOptions - wxVERTICAL - none - - 5 - wxEXPAND|wxBOTTOM - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Cartesian coordinates" "Polar coordinates" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_POLAR_CTRL - Coordinates - 1 - - 0 - - - 0 - - 1 - m_PolarDisplay - 1 - - - protected - 1 - - Resizable - 0 - 1 - - wxRA_SPECIFY_COLS - - 0 - Set display of relative (dx/dy) coordinates to Cartesian (rectangular) or polar (angle/distance). - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND|wxBOTTOM - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Inches" "Millimeters" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_UNITS - Units - 1 - - 0 - - - 0 - - 1 - m_UnitsSelection - 1 - - - protected - 1 - - Resizable - 0 - 1 - - wxRA_SPECIFY_COLS - - 0 - Set units used to display dimensions and positions. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND|wxTOP|wxBOTTOM - 0 - - wxID_ANY - Editing Options - - sbSizerEditOptions - wxVERTICAL - 1 - none - - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Magnetic pads - - 0 - - - 0 - - 1 - m_MagneticPads - 1 - - - protected - 1 - - Resizable - 1 - - - ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_SEGMENTS45 - L&imit graphic lines to H, V and 45 degrees - - 0 - - - 0 - - 1 - m_Segments_45_Only_Ctrl - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - Force line segment directions to H, V or 45 degrees when drawing on technical layers. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/pcbnew/dialogs/panel_modedit_settings_base.h b/pcbnew/dialogs/panel_modedit_settings_base.h deleted file mode 100644 index 6620f5ec0a..0000000000 --- a/pcbnew/dialogs/panel_modedit_settings_base.h +++ /dev/null @@ -1,51 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Dec 30 2017) -// http://www.wxformbuilder.org/ -// -// PLEASE DO *NOT* EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#ifndef __PANEL_MODEDIT_SETTINGS_BASE_H__ -#define __PANEL_MODEDIT_SETTINGS_BASE_H__ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/////////////////////////////////////////////////////////////////////////// - -#define wxID_POLAR_CTRL 1000 -#define wxID_UNITS 1001 -#define wxID_SEGMENTS45 1002 - -/////////////////////////////////////////////////////////////////////////////// -/// Class PANEL_MODEDIT_SETTINGS_BASE -/////////////////////////////////////////////////////////////////////////////// -class PANEL_MODEDIT_SETTINGS_BASE : public wxPanel -{ - private: - - protected: - wxRadioBox* m_PolarDisplay; - wxRadioBox* m_UnitsSelection; - wxCheckBox* m_MagneticPads; - wxCheckBox* m_Segments_45_Only_Ctrl; - - public: - - PANEL_MODEDIT_SETTINGS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxTAB_TRAVERSAL ); - ~PANEL_MODEDIT_SETTINGS_BASE(); - -}; - -#endif //__PANEL_MODEDIT_SETTINGS_BASE_H__ diff --git a/pcbnew/dialogs/panel_pcbnew_display_options_base.fbp b/pcbnew/dialogs/panel_pcbnew_display_options_base.fbp deleted file mode 100644 index dc3ca72418..0000000000 --- a/pcbnew/dialogs/panel_pcbnew_display_options_base.fbp +++ /dev/null @@ -1,445 +0,0 @@ - - - - - - C++ - 1 - source_name - 0 - 0 - res - UTF-8 - connect - panel_pcbnew_display_options_base - 1000 - none - - 1 - PanelPcbnewDisplayOptions - - . - - 1 - 1 - 1 - 1 - UI - 1 - 0 - - 0 - wxAUI_MGR_DEFAULT - - - 1 - 1 - impl_virtual - - - 0 - wxID_ANY - - - PANEL_PCBNEW_DISPLAY_OPTIONS_BASE - - -1,-1 - ; forward_declare - - - - wxTAB_TRAVERSAL - - - bMainSizer - wxVERTICAL - none - - 5 - wxEXPAND|wxRIGHT|wxLEFT - 0 - - - bupperSizer - wxHORIZONTAL - none - - 5 - wxEXPAND - 1 - - - m_galOptionsSizer - wxVERTICAL - protected - - - - 5 - wxEXPAND|wxTOP|wxRIGHT|wxLEFT - 1 - - - bRightSizer - wxVERTICAL - none - - 5 - wxEXPAND|wxBOTTOM - 0 - - wxID_ANY - Annotations - - sbAnnotations - wxVERTICAL - 1 - none - - 5 - wxEXPAND|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Do not show" "Show on pads" "Show on tracks" "Show on pads and tracks" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Net Names - 1 - - 0 - - - 0 - - 1 - m_ShowNetNamesOption - 1 - - - protected - 1 - - Resizable - 0 - 1 - - wxRA_SPECIFY_COLS - - 0 - Show or hide net names on pads and/or tracks. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 6 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show pad numbers - - 0 - - - 0 - - 1 - m_OptDisplayPadNumber - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 6 - wxBOTTOM|wxLEFT|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show pad <no net> indicator - - 0 - - - 0 - - 1 - m_OptDisplayPadNoConn - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - 5 - wxBOTTOM|wxEXPAND|wxTOP - 0 - - wxID_ANY - Clearance Outlines - - sbClearance - wxVERTICAL - 1 - none - - 5 - wxEXPAND|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Do not show" "Show when creating tracks" "Show with via clearance at end" "Show when creating and editing tracks" "Show always" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - ID_SHOW_CLEARANCE - Track Clearance - 1 - - 0 - - - 0 - - 1 - m_OptDisplayTracksClearance - 1 - - - protected - 1 - - Resizable - 2 - 1 - - wxRA_SPECIFY_COLS - - 0 - Show or hide the track and via clearance area. If "New track" is selected, track clearance area is shown only when creating the track. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 6 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show pad clearance - - 0 - - - 0 - - 1 - m_OptDisplayPadClearence - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - diff --git a/pcbnew/dialogs/panel_pcbnew_settings_base.fbp b/pcbnew/dialogs/panel_pcbnew_settings_base.fbp deleted file mode 100644 index b4371f264e..0000000000 --- a/pcbnew/dialogs/panel_pcbnew_settings_base.fbp +++ /dev/null @@ -1,1201 +0,0 @@ - - - - - - C++ - 1 - source_name - 0 - 0 - res - UTF-8 - connect - panel_pcbnew_settings_base - 1000 - none - - 1 - PanelPcbnewSettings - - . - - 1 - 1 - 1 - 1 - UI - 1 - 0 - - 0 - wxAUI_MGR_DEFAULT - - - 1 - 1 - impl_virtual - - - 0 - wxID_ANY - - - PANEL_PCBNEW_SETTINGS_BASE - - -1,-1 - ; forward_declare - - - - wxTAB_TRAVERSAL - - - bPanelSizer - wxHORIZONTAL - none - - 5 - wxRIGHT - 1 - - - bMargins - wxHORIZONTAL - none - - 5 - wxEXPAND|wxRIGHT - 1 - - - bMiddleLeftSizer - wxVERTICAL - none - - 5 - wxALL|wxEXPAND - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Cartesian coordinates" "Polar coordinates" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_POLAR_CTRL - Coordinates - 1 - - 0 - - - 0 - - 1 - m_PolarDisplay - 1 - - - protected - 1 - - Resizable - 0 - 1 - - wxRA_SPECIFY_COLS - - 0 - Set display of relative (dx/dy) coordinates to Cartesian (rectangular) or polar (angle/distance). - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxALL|wxEXPAND - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Inches" "Millimeters" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_UNITS - Units - 1 - - 0 - - - 0 - - 1 - m_UnitsSelection - 1 - - - protected - 1 - - Resizable - 0 - 1 - - wxRA_SPECIFY_COLS - - 0 - Set units used to display dimensions and positions. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxEXPAND|wxTOP|wxRIGHT|wxLEFT - 1 - - wxID_ANY - Editing Options - - bOptionsSizer - wxVERTICAL - 1 - none - - 5 - wxBOTTOM|wxLEFT|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_SEGMENTS45 - L&imit graphic lines to H, V and 45 degrees - - 0 - - - 0 - - 1 - m_Segments_45_Only_Ctrl - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - Force line segment directions to H, V or 45 degrees when drawing on technical layers. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Flip board items L/R (default is T/B) - - 0 - - - 0 - - 1 - m_FlipLeftRight - 1 - - - protected - 1 - - Resizable - 1 - - - ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxEXPAND - 1 - - 2 - wxBOTH - 1 - - 0 - - fgSizer12 - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 0 - - 5 - wxALIGN_CENTER_VERTICAL|wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - &Rotation angle: - 0 - - 0 - - - 0 - - 1 - m_staticTextRotationAngle - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxALIGN_CENTER_VERTICAL|wxALL|wxEXPAND - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - - 0 - - 1 - m_RotationAngle - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - Set increment (in degrees) for context menu and hotkey rotation. - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - 5 - wxEXPAND|wxTOP|wxRIGHT - 1 - - - bRightSizer - wxVERTICAL - none - - 5 - wxEXPAND - 1 - - wxID_ANY - Magnetic Points - - sbMagnets - wxVERTICAL - 1 - none - - 5 - wxEXPAND|wxBOTTOM - 1 - - 2 - wxBOTH - - - 0 - - fgSizer2 - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 3 - - 5 - wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Snap to pads: - 0 - - 0 - - - 0 - - 1 - m_staticText2 - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse enters a pad area - - - - -1 - - - - 5 - wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Never" "When creating tracks" "Always" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_magneticPadChoice - 1 - - - protected - 1 - - Resizable - 1 - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse enters a pad area - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Snap to tracks: - 0 - - 0 - - - 0 - - 1 - m_staticText21 - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse approaches a track - - - - -1 - - - - 5 - wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Never" "When creating tracks" "Always" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_magneticTrackChoice - 1 - - - protected - 1 - - Resizable - 1 - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse approaches a track - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Snap to graphics: - 0 - - 0 - - - 0 - - 1 - m_staticText211 - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse approaches graphical control points - - - - -1 - - - - 5 - wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - "Always" "Never" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_magneticGraphicsChoice - 1 - - - protected - 1 - - Resizable - 0 - 1 - - - ; ; forward_declare - 0 - Capture cursor when the mouse approaches graphical control points - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - 5 - wxEXPAND - 1 - - wxID_ANY - Ratsnest - - sbSizer3 - wxVERTICAL - 1 - none - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show ratsnest - - 0 - - - 0 - - 1 - m_showGlobalRatsnest - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Always show selected ratsnest - - 0 - - - 0 - - 1 - m_showSelectedRatsnest - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show ratsnest with curved lines - - 0 - - - 0 - - 1 - m_OptDisplayCurvedRatsnestLines - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - 5 - wxEXPAND - 1 - - wxID_ANY - Annotations - - sbSizer4 - wxVERTICAL - 1 - none - - 5 - wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Show page limits - - 0 - - - 0 - - 1 - m_Show_Page_Limits - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - diff --git a/pcbnew/footprint_edit_frame.cpp b/pcbnew/footprint_edit_frame.cpp index f3137061df..522522219b 100644 --- a/pcbnew/footprint_edit_frame.cpp +++ b/pcbnew/footprint_edit_frame.cpp @@ -37,8 +37,8 @@ #include #include #include -#include -#include +#include +#include #include #include #include @@ -839,9 +839,9 @@ void FOOTPRINT_EDIT_FRAME::InstallPreferences( PAGED_DIALOG* aParent, wxTreebook* book = aParent->GetTreebook(); book->AddPage( new wxPanel( book ), _( "Footprint Editor" ) ); - book->AddSubPage( new PANEL_MODEDIT_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); + book->AddSubPage( new PANEL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); book->AddSubPage( new PANEL_MODEDIT_COLOR_SETTINGS( this, book ), _( "Colors" ) ); - book->AddSubPage( new PANEL_MODEDIT_SETTINGS( this, aParent ), _( "Editing Options" ) ); + book->AddSubPage( new PANEL_EDIT_OPTIONS( this, aParent ), _( "Editing Options" ) ); book->AddSubPage( new PANEL_MODEDIT_DEFAULTS( this, aParent ), _( "Default Values" ) ); aHotkeysPanel->AddHotKeys( GetToolManager() ); diff --git a/pcbnew/pcbnew_config.cpp b/pcbnew/pcbnew_config.cpp index 137c0a496a..9d3d115353 100644 --- a/pcbnew/pcbnew_config.cpp +++ b/pcbnew/pcbnew_config.cpp @@ -26,18 +26,16 @@ #include #include -#include #include #include #include #include #include #include -#include #include -#include +#include #include -#include +#include #include #include #include @@ -64,9 +62,9 @@ void PCB_EDIT_FRAME::InstallPreferences( PAGED_DIALOG* aParent, wxTreebook* book = aParent->GetTreebook(); book->AddPage( new wxPanel( book ), _( "Pcbnew" ) ); - book->AddSubPage( new PANEL_PCBNEW_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); + book->AddSubPage( new PANEL_DISPLAY_OPTIONS( this, aParent ), _( "Display Options" ) ); book->AddSubPage( new PANEL_PCBNEW_COLOR_SETTINGS( this, book ), _( "Colors" ) ); - book->AddSubPage( new PANEL_PCBNEW_SETTINGS( this, aParent ), _( "Editing Options" ) ); + book->AddSubPage( new PANEL_EDIT_OPTIONS( this, aParent ), _( "Editing Options" ) ); #if defined(KICAD_SCRIPTING) && defined(KICAD_SCRIPTING_ACTION_MENU) book->AddSubPage( new PANEL_PCBNEW_ACTION_PLUGINS( this, aParent ), _( "Action Plugins" ) ); #endif