From e38c3666952754a370ea8eb951cf07dcc9f4fe47 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sun, 8 Aug 2021 17:24:05 +0100 Subject: [PATCH] Narrow zone dialog a bit. --- pcbnew/dialogs/dialog_copper_zones_base.cpp | 18 +- pcbnew/dialogs/dialog_copper_zones_base.fbp | 199 +++++++------------- pcbnew/dialogs/dialog_copper_zones_base.h | 3 +- 3 files changed, 78 insertions(+), 142 deletions(-) diff --git a/pcbnew/dialogs/dialog_copper_zones_base.cpp b/pcbnew/dialogs/dialog_copper_zones_base.cpp index a96afd888d..de5cd36e85 100644 --- a/pcbnew/dialogs/dialog_copper_zones_base.cpp +++ b/pcbnew/dialogs/dialog_copper_zones_base.cpp @@ -26,6 +26,7 @@ DIALOG_COPPER_ZONE_BASE::DIALOG_COPPER_ZONE_BASE( wxWindow* parent, wxWindowID i wxStaticBoxSizer* sbSizer2; sbSizer2 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Layer") ), wxVERTICAL ); + sbSizer2->SetMinSize( wxSize( 180,-1 ) ); m_layers = new wxDataViewListCtrl( sbSizer2->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxDV_NO_HEADER|wxBORDER_SIMPLE ); m_layers->SetMinSize( wxSize( 120,-1 ) ); @@ -209,13 +210,7 @@ DIALOG_COPPER_ZONE_BASE::DIALOG_COPPER_ZONE_BASE( wxWindow* parent, wxWindowID i gbSizerSettings->Add( m_minWidthUnits, wxGBPosition( 1, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT, 5 ); m_staticline2 = new wxStaticLine( sbSizer5->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); - gbSizerSettings->Add( m_staticline2, wxGBPosition( 2, 0 ), wxGBSpan( 1, 1 ), wxEXPAND|wxTOP|wxBOTTOM, 5 ); - - m_staticline3 = new wxStaticLine( sbSizer5->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); - gbSizerSettings->Add( m_staticline3, wxGBPosition( 2, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxTOP|wxBOTTOM, 5 ); - - m_staticline4 = new wxStaticLine( sbSizer5->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); - gbSizerSettings->Add( m_staticline4, wxGBPosition( 2, 2 ), wxGBSpan( 1, 1 ), wxEXPAND|wxTOP|wxBOTTOM, 5 ); + gbSizerSettings->Add( m_staticline2, wxGBPosition( 2, 0 ), wxGBSpan( 1, 3 ), wxEXPAND|wxTOP|wxBOTTOM, 5 ); m_connectionLabel = new wxStaticText( sbSizer5->GetStaticBox(), wxID_ANY, _("Pad connections:"), wxDefaultPosition, wxDefaultSize, 0 ); m_connectionLabel->Wrap( -1 ); @@ -244,7 +239,7 @@ DIALOG_COPPER_ZONE_BASE::DIALOG_COPPER_ZONE_BASE( wxWindow* parent, wxWindowID i m_antipadUnits->Wrap( -1 ); gbSizerSettings->Add( m_antipadUnits, wxGBPosition( 4, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT, 5 ); - m_spokeWidthLabel = new wxStaticText( sbSizer5->GetStaticBox(), wxID_ANY, _("Thermal relief spoke width:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_spokeWidthLabel = new wxStaticText( sbSizer5->GetStaticBox(), wxID_ANY, _("Thermal spoke width:"), wxDefaultPosition, wxDefaultSize, 0 ); m_spokeWidthLabel->Wrap( -1 ); gbSizerSettings->Add( m_spokeWidthLabel, wxGBPosition( 5, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5 ); @@ -276,13 +271,13 @@ DIALOG_COPPER_ZONE_BASE::DIALOG_COPPER_ZONE_BASE( wxWindow* parent, wxWindowID i m_staticTextGridFillType = new wxStaticText( sbSizerZoneStyle->GetStaticBox(), wxID_ANY, _("Fill type:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGridFillType->Wrap( -1 ); - gbSizer3->Add( m_staticTextGridFillType, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM, 5 ); + gbSizer3->Add( m_staticTextGridFillType, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); wxString m_GridStyleCtrlChoices[] = { _("Solid fill"), _("Hatch pattern") }; int m_GridStyleCtrlNChoices = sizeof( m_GridStyleCtrlChoices ) / sizeof( wxString ); m_GridStyleCtrl = new wxChoice( sbSizerZoneStyle->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_GridStyleCtrlNChoices, m_GridStyleCtrlChoices, 0 ); m_GridStyleCtrl->SetSelection( 0 ); - gbSizer3->Add( m_GridStyleCtrl, wxGBPosition( 0, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 ); + gbSizer3->Add( m_GridStyleCtrl, wxGBPosition( 0, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 ); m_staticTextGrindOrient = new wxStaticText( sbSizerZoneStyle->GetStaticBox(), wxID_ANY, _("Orientation:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGrindOrient->Wrap( -1 ); @@ -336,6 +331,9 @@ DIALOG_COPPER_ZONE_BASE::DIALOG_COPPER_ZONE_BASE( wxWindow* parent, wxWindowID i m_spinCtrlSmoothValue->SetDigits( 0 ); gbSizer3->Add( m_spinCtrlSmoothValue, wxGBPosition( 5, 1 ), wxGBSpan( 1, 1 ), wxBOTTOM|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 ); + m_staticline5 = new wxStaticLine( sbSizerZoneStyle->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); + gbSizer3->Add( m_staticline5, wxGBPosition( 6, 0 ), wxGBSpan( 1, 3 ), wxEXPAND|wxTOP|wxBOTTOM, 5 ); + m_staticText40 = new wxStaticText( sbSizerZoneStyle->GetStaticBox(), wxID_ANY, _("Remove islands:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText40->Wrap( -1 ); m_staticText40->SetToolTip( _("Choose what to do with unconnected copper islands") ); diff --git a/pcbnew/dialogs/dialog_copper_zones_base.fbp b/pcbnew/dialogs/dialog_copper_zones_base.fbp index 56160903bc..02ef1dd870 100644 --- a/pcbnew/dialogs/dialog_copper_zones_base.fbp +++ b/pcbnew/dialogs/dialog_copper_zones_base.fbp @@ -136,7 +136,7 @@ wxID_ANY Layer - + 180,-1 sbSizer2 wxVERTICAL 1 @@ -1476,7 +1476,7 @@ 10 wxEXPAND|wxTOP|wxRIGHT 0 - + wxID_ANY Electrical Properties @@ -1484,11 +1484,11 @@ wxVERTICAL 1 none - + 5 wxEXPAND 0 - + wxBOTH 1 @@ -1891,7 +1891,7 @@ 5 - 1 + 3 0 wxEXPAND|wxTOP|wxBOTTOM 2 @@ -1950,128 +1950,6 @@ - - 5 - 1 - 1 - wxEXPAND|wxTOP|wxBOTTOM - 2 - 1 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_staticline3 - 1 - - - protected - 1 - - Resizable - 1 - - wxLI_HORIZONTAL - ; ; forward_declare - 0 - - - - - - - - 5 - 1 - 2 - wxEXPAND|wxTOP|wxBOTTOM - 2 - 1 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_staticline4 - 1 - - - protected - 1 - - Resizable - 1 - - wxLI_HORIZONTAL - ; ; forward_declare - 0 - - - - - - 5 1 @@ -2433,7 +2311,7 @@ 0 0 wxID_ANY - Thermal relief spoke width: + Thermal spoke width: 0 0 @@ -2628,7 +2506,7 @@ 5 1 0 - wxALIGN_CENTER_VERTICAL|wxBOTTOM + wxALIGN_CENTER_VERTICAL 0 1 @@ -2692,7 +2570,7 @@ 5 1 1 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT 0 1 @@ -3601,6 +3479,67 @@ + + 5 + 3 + 0 + wxEXPAND|wxTOP|wxBOTTOM + 6 + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_staticline5 + 1 + + + protected + 1 + + Resizable + 1 + + wxLI_HORIZONTAL + ; ; forward_declare + 0 + + + + + + 5 1 diff --git a/pcbnew/dialogs/dialog_copper_zones_base.h b/pcbnew/dialogs/dialog_copper_zones_base.h index 844fae32c9..0848d6ce80 100644 --- a/pcbnew/dialogs/dialog_copper_zones_base.h +++ b/pcbnew/dialogs/dialog_copper_zones_base.h @@ -87,8 +87,6 @@ class DIALOG_COPPER_ZONE_BASE : public DIALOG_SHIM wxTextCtrl* m_minWidthCtrl; wxStaticText* m_minWidthUnits; wxStaticLine* m_staticline2; - wxStaticLine* m_staticline3; - wxStaticLine* m_staticline4; wxStaticText* m_connectionLabel; wxChoice* m_PadInZoneOpt; wxStaticText* m_antipadLabel; @@ -112,6 +110,7 @@ class DIALOG_COPPER_ZONE_BASE : public DIALOG_SHIM wxSpinCtrl* m_spinCtrlSmoothLevel; wxStaticText* m_staticTextGridSmootingVal; wxSpinCtrlDouble* m_spinCtrlSmoothValue; + wxStaticLine* m_staticline5; wxStaticText* m_staticText40; wxChoice* m_cbRemoveIslands; wxStaticText* m_islandThresholdLabel;