From a06b95bb1f9eb9509520ea35c9b42ca7a2aad243 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Fri, 9 Jul 2021 23:37:50 +0100 Subject: [PATCH] Even out spacing around various panels. --- common/dialogs/panel_setup_severities.cpp | 10 +++++-- common/dialogs/panel_text_variables_base.cpp | 6 ++--- common/dialogs/panel_text_variables_base.fbp | 6 ++--- common/dialogs/panel_text_variables_base.h | 2 +- .../panel_eeschema_template_fieldnames.cpp | 8 ------ .../dialogs/panel_setup_formatting_base.cpp | 6 ++--- .../dialogs/panel_setup_formatting_base.fbp | 6 ++--- .../dialogs/panel_setup_formatting_base.h | 2 +- eeschema/dialogs/panel_setup_pinmap_base.cpp | 7 +++-- eeschema/dialogs/panel_setup_pinmap_base.fbp | 14 ++++++++-- .../dialogs/panel_setup_constraints_base.fbp | 26 +++++++++---------- 11 files changed, 51 insertions(+), 42 deletions(-) diff --git a/common/dialogs/panel_setup_severities.cpp b/common/dialogs/panel_setup_severities.cpp index 794fa06c25..5737f86470 100644 --- a/common/dialogs/panel_setup_severities.cpp +++ b/common/dialogs/panel_setup_severities.cpp @@ -47,6 +47,7 @@ PANEL_SETUP_SEVERITIES::PANEL_SETUP_SEVERITIES( PAGED_DIALOG* aParent, wxScrolledWindow* scrollWin = new wxScrolledWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL | wxVSCROLL ); + bool firstLine = true; scrollWin->SetScrollRate( 0, 5 ); @@ -69,8 +70,11 @@ PANEL_SETUP_SEVERITIES::PANEL_SETUP_SEVERITIES( PAGED_DIALOG* aParent, heading->SetFont( headingFont.Bold() ); - gridSizer->AddSpacer( 5 ); // col 1 - gridSizer->AddSpacer( 5 ); // col 2 + if( !firstLine ) + { + gridSizer->AddSpacer( 5 ); // col 1 + gridSizer->AddSpacer( 5 ); // col 2 + } gridSizer->Add( heading, 0, wxALIGN_BOTTOM | wxALL | wxEXPAND, 4 ); gridSizer->AddSpacer( 0 ); // col 2 @@ -100,6 +104,8 @@ PANEL_SETUP_SEVERITIES::PANEL_SETUP_SEVERITIES( PAGED_DIALOG* aParent, radioPanel->Layout(); gridSizer->Add( radioPanel, 0, wxALIGN_CENTER_VERTICAL ); } + + firstLine = false; } diff --git a/common/dialogs/panel_text_variables_base.cpp b/common/dialogs/panel_text_variables_base.cpp index b3e79bc1f1..59e89b32a6 100644 --- a/common/dialogs/panel_text_variables_base.cpp +++ b/common/dialogs/panel_text_variables_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 6 2019) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -49,7 +49,7 @@ PANEL_TEXT_VARIABLES_BASE::PANEL_TEXT_VARIABLES_BASE( wxWindow* parent, wxWindow m_TextVars->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP ); m_TextVars->SetMinSize( wxSize( 604,170 ) ); - bSizer3->Add( m_TextVars, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + bSizer3->Add( m_TextVars, 1, wxEXPAND|wxALL, 5 ); wxBoxSizer* bSizerEnvVarBtns; bSizerEnvVarBtns = new wxBoxSizer( wxHORIZONTAL ); @@ -67,7 +67,7 @@ PANEL_TEXT_VARIABLES_BASE::PANEL_TEXT_VARIABLES_BASE( wxWindow* parent, wxWindow bSizer3->Add( bSizerEnvVarBtns, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 ); - bPanelSizer->Add( bSizer3, 1, wxEXPAND|wxTOP|wxLEFT, 10 ); + bPanelSizer->Add( bSizer3, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 ); this->SetSizer( bPanelSizer ); diff --git a/common/dialogs/panel_text_variables_base.fbp b/common/dialogs/panel_text_variables_base.fbp index 6dc5b37758..161511f2fc 100644 --- a/common/dialogs/panel_text_variables_base.fbp +++ b/common/dialogs/panel_text_variables_base.fbp @@ -56,8 +56,8 @@ wxVERTICAL none - 10 - wxEXPAND|wxTOP|wxLEFT + 5 + wxEXPAND|wxRIGHT|wxLEFT 1 @@ -66,7 +66,7 @@ none 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + wxEXPAND|wxALL 1 1 diff --git a/common/dialogs/panel_text_variables_base.h b/common/dialogs/panel_text_variables_base.h index 265b3cdd99..0a8b881069 100644 --- a/common/dialogs/panel_text_variables_base.h +++ b/common/dialogs/panel_text_variables_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 6 2019) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! diff --git a/eeschema/dialogs/panel_eeschema_template_fieldnames.cpp b/eeschema/dialogs/panel_eeschema_template_fieldnames.cpp index ecccbb8661..d073b51063 100644 --- a/eeschema/dialogs/panel_eeschema_template_fieldnames.cpp +++ b/eeschema/dialogs/panel_eeschema_template_fieldnames.cpp @@ -41,14 +41,6 @@ PANEL_EESCHEMA_TEMPLATE_FIELDNAMES::PANEL_EESCHEMA_TEMPLATE_FIELDNAMES( SCH_EDIT m_title->SetLabel( aGlobal ? _( "Global field name templates:" ) : _( "Project field name templates:" ) ); - // Yep, it's a hack. I haven't a clue why the global and project versions don't lay - // out the same. - if( !aGlobal ) - { - m_leftMargin->PrependSpacer( 10 ); - m_topMargin->PrependSpacer( 10 ); - } - m_addFieldButton->SetBitmap( KiBitmap( BITMAPS::small_plus ) ); m_deleteFieldButton->SetBitmap( KiBitmap( BITMAPS::small_trash ) ); diff --git a/eeschema/dialogs/panel_setup_formatting_base.cpp b/eeschema/dialogs/panel_setup_formatting_base.cpp index 3c320562ce..f7bfd8c2c9 100644 --- a/eeschema/dialogs/panel_setup_formatting_base.cpp +++ b/eeschema/dialogs/panel_setup_formatting_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version 3.9.0 Jun 3 2020) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -142,7 +142,7 @@ PANEL_SETUP_FORMATTING_BASE::PANEL_SETUP_FORMATTING_BASE( wxWindow* parent, wxWi bLeftColumn->Add( sbSizer2, 0, wxEXPAND|wxALL, 5 ); - bPanelSizer->Add( bLeftColumn, 1, wxLEFT|wxTOP, 10 ); + bPanelSizer->Add( bLeftColumn, 1, 0, 10 ); wxBoxSizer* bRightColumn; bRightColumn = new wxBoxSizer( wxVERTICAL ); @@ -200,7 +200,7 @@ PANEL_SETUP_FORMATTING_BASE::PANEL_SETUP_FORMATTING_BASE( wxWindow* parent, wxWi bRightColumn->Add( 0, 0, 0, wxEXPAND, 5 ); - bPanelSizer->Add( bRightColumn, 1, wxLEFT|wxTOP, 10 ); + bPanelSizer->Add( bRightColumn, 1, wxRIGHT|wxLEFT, 10 ); this->SetSizer( bPanelSizer ); diff --git a/eeschema/dialogs/panel_setup_formatting_base.fbp b/eeschema/dialogs/panel_setup_formatting_base.fbp index 9cba32ce67..da666319f0 100644 --- a/eeschema/dialogs/panel_setup_formatting_base.fbp +++ b/eeschema/dialogs/panel_setup_formatting_base.fbp @@ -14,7 +14,6 @@ panel_setup_formatting_base 1000 none - 1 PanelSetupFormatting @@ -26,7 +25,6 @@ 1 1 UI - 0 1 0 @@ -58,7 +56,7 @@ none 10 - wxLEFT|wxTOP + 1 @@ -1177,7 +1175,7 @@ 10 - wxLEFT|wxTOP + wxRIGHT|wxLEFT 1 diff --git a/eeschema/dialogs/panel_setup_formatting_base.h b/eeschema/dialogs/panel_setup_formatting_base.h index 35054e4799..bb2cb1b999 100644 --- a/eeschema/dialogs/panel_setup_formatting_base.h +++ b/eeschema/dialogs/panel_setup_formatting_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version 3.9.0 Jun 3 2020) +// C++ code generated with wxFormBuilder (version Oct 26 2018) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! diff --git a/eeschema/dialogs/panel_setup_pinmap_base.cpp b/eeschema/dialogs/panel_setup_pinmap_base.cpp index c3382d60a9..809f56e207 100644 --- a/eeschema/dialogs/panel_setup_pinmap_base.cpp +++ b/eeschema/dialogs/panel_setup_pinmap_base.cpp @@ -17,6 +17,9 @@ PANEL_SETUP_PINMAP_BASE::PANEL_SETUP_PINMAP_BASE( wxWindow* parent, wxWindowID i wxBoxSizer* m_panelMatrixSizer; m_panelMatrixSizer = new wxBoxSizer( wxVERTICAL ); + + m_panelMatrixSizer->Add( 0, 5, 0, 0, 5 ); + wxStaticBoxSizer* sbSizer3; sbSizer3 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Pin to Pin Connections") ), wxVERTICAL ); @@ -26,10 +29,10 @@ PANEL_SETUP_PINMAP_BASE::PANEL_SETUP_PINMAP_BASE( wxWindow* parent, wxWindowID i sbSizer3->Add( m_matrixPanel, 1, wxEXPAND | wxALL, 5 ); - m_panelMatrixSizer->Add( sbSizer3, 1, wxALL|wxEXPAND, 10 ); + m_panelMatrixSizer->Add( sbSizer3, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 10 ); - bSizer2->Add( m_panelMatrixSizer, 1, wxEXPAND|wxLEFT, 10 ); + bSizer2->Add( m_panelMatrixSizer, 1, wxEXPAND, 10 ); this->SetSizer( bSizer2 ); diff --git a/eeschema/dialogs/panel_setup_pinmap_base.fbp b/eeschema/dialogs/panel_setup_pinmap_base.fbp index 58fa670966..88a35c52a8 100644 --- a/eeschema/dialogs/panel_setup_pinmap_base.fbp +++ b/eeschema/dialogs/panel_setup_pinmap_base.fbp @@ -56,16 +56,26 @@ none 10 - wxEXPAND|wxLEFT + wxEXPAND 1 m_panelMatrixSizer wxVERTICAL none + + 5 + + 0 + + 5 + protected + 0 + + 10 - wxALL|wxEXPAND + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT 1 wxID_ANY diff --git a/pcbnew/dialogs/panel_setup_constraints_base.fbp b/pcbnew/dialogs/panel_setup_constraints_base.fbp index 2e8aa1d95a..381ac585a7 100644 --- a/pcbnew/dialogs/panel_setup_constraints_base.fbp +++ b/pcbnew/dialogs/panel_setup_constraints_base.fbp @@ -716,7 +716,7 @@ ; ; forward_declare 0 - + The maximum allowed deviation between a true arc or circle and segments used to approximate it. Smaller values produce smoother graphics at the expense of performance. wxString wxFILTER_NUMERIC wxTextValidator @@ -1536,7 +1536,7 @@ 5 wxEXPAND|wxRIGHT 0 - + sbFeatureConstraints wxVERTICAL @@ -1820,7 +1820,7 @@ ; ; forward_declare 0 - + The minimum clearance between copper items which do not belong to the same net. If set, this is an absolute minimum which cannot be reduced by netclasses, custom rules, or other settings. wxFILTER_NONE wxDefaultValidator @@ -2064,7 +2064,7 @@ 0 - + The minimum track width. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules, or other settings. wxString wxFILTER_NUMERIC wxTextValidator @@ -2308,7 +2308,7 @@ ; ; forward_declare 0 - + The minimum annular ring width. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules, or other settings. wxFILTER_NONE wxDefaultValidator @@ -2552,7 +2552,7 @@ ; 0 - + The minimum via diameter. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules, or other settings. wxString wxFILTER_NUMERIC wxTextValidator @@ -2796,7 +2796,7 @@ ; ; forward_declare 0 - + The minimum clearance between a hole and an unassociated copper item. If set, this is an absolute minimum and cannot be reduced by custom rules or other settings. wxFILTER_NONE wxDefaultValidator @@ -3040,7 +3040,7 @@ ; forward_declare 0 - + The minimum clearance between the board edge and any copper item. If set, this is an absolute minimum and cannot be reduced by custom rules or other settings. wxFILTER_NONE wxDefaultValidator @@ -3607,7 +3607,7 @@ 0 - + The minimum through-hole size. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules or other settings. wxFILTER_NUMERIC wxTextValidator @@ -3851,7 +3851,7 @@ ; forward_declare 0 - + The minimum clearance between two drilled holes. If set, this is an absolute minimum and cannot be reduced by custom rules or other settings. (Note: does not apply to milled holes.) wxFILTER_NONE wxDefaultValidator @@ -4418,7 +4418,7 @@ 0 - + The minimum diameter for micro-vias. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules, or other settings. wxFILTER_NUMERIC wxTextValidator @@ -4662,7 +4662,7 @@ 0 - + The minimum micro-via hole size. If set, this is an absolute minimum and cannot be reduced by netclasses, custom rules, or other settings. wxFILTER_NUMERIC wxTextValidator @@ -5181,7 +5181,7 @@ ; ; forward_declare 0 - + Minimum clearance between two items on the same silkscreen layer. If set this can improve legibility. (Note: does not apply to multiple shapes within a single footprint.) wxFILTER_NONE wxDefaultValidator