From 807b8d4cf13db5299c61c889210c57bd78398f9f Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Thu, 11 Jul 2019 17:01:30 +0100 Subject: [PATCH] Lower x (or y) value always defines "Start Point". "End Point" is the other. (The user doesn't care what the variable names in the code are.) Also re-lays-out the dialog for better comprehension. Fixes: lp:1694964 * https://bugs.launchpad.net/kicad/+bug/1694964 --- .../dialog_graphic_item_properties.cpp | 57 +- .../dialog_graphic_item_properties_base.cpp | 126 +- .../dialog_graphic_item_properties_base.fbp | 4005 +++++++++-------- .../dialog_graphic_item_properties_base.h | 9 +- 4 files changed, 2333 insertions(+), 1864 deletions(-) diff --git a/pcbnew/dialogs/dialog_graphic_item_properties.cpp b/pcbnew/dialogs/dialog_graphic_item_properties.cpp index d656d5b06c..3f1d82411e 100644 --- a/pcbnew/dialogs/dialog_graphic_item_properties.cpp +++ b/pcbnew/dialogs/dialog_graphic_item_properties.cpp @@ -55,6 +55,8 @@ private: UNIT_BINDER m_bezierCtrl1X, m_bezierCtrl1Y; UNIT_BINDER m_bezierCtrl2X, m_bezierCtrl2Y; + bool m_flipStartEnd; + wxFloatingPointValidator m_AngleValidator; double m_AngleValue; @@ -91,6 +93,7 @@ DIALOG_GRAPHIC_ITEM_PROPERTIES::DIALOG_GRAPHIC_ITEM_PROPERTIES( PCB_BASE_EDIT_FR m_bezierCtrl1Y( aParent, m_BezierPointC1YLabel, m_BezierC1Y_Ctrl, m_BezierPointC1YUnit ), m_bezierCtrl2X( aParent, m_BezierPointC2XLabel, m_BezierC2X_Ctrl, m_BezierPointC2XUnit ), m_bezierCtrl2Y( aParent, m_BezierPointC2YLabel, m_BezierC2Y_Ctrl, m_BezierPointC2YUnit ), + m_flipStartEnd( false ), m_AngleValidator( 1, &m_AngleValue ), m_AngleValue( 0.0 ) { @@ -146,8 +149,10 @@ bool DIALOG_GRAPHIC_ITEM_PROPERTIES::TransferDataToWindow() // Only a Bezeier curve has control points. So do not show these parameters for other shapes if( m_item->GetShape() != S_CURVE ) { + m_bezierCtrlPt1Label->Show( false ); m_bezierCtrl1X.Show( false ); m_bezierCtrl1Y.Show( false ); + m_bezierCtrlPt2Label->Show( false ); m_bezierCtrl2X.Show( false ); m_bezierCtrl2Y.Show( false ); } @@ -157,28 +162,30 @@ bool DIALOG_GRAPHIC_ITEM_PROPERTIES::TransferDataToWindow() { case S_CIRCLE: SetTitle( _( "Circle Properties" ) ); - m_startXLabel->SetLabel( _( "Center X:" ) ); - m_startYLabel->SetLabel( _( "Center Y:" ) ); - m_endXLabel->SetLabel( _( "Radius:" ) ); + m_startPointLabel->SetLabel( _( "Center" ) ); + m_endPointLabel->SetLabel( _( "Radius" ) ); m_endY.Show( false ); break; case S_ARC: SetTitle( _( "Arc Properties" ) ); - m_startXLabel->SetLabel( _( "Center X:" ) ); - m_startYLabel->SetLabel( _( "Center Y:" ) ); - m_endXLabel->SetLabel( _( "Start Point X:" ) ); - m_endYLabel->SetLabel( _( "Start Point Y:" ) ); + m_startPointLabel->SetLabel( _( "Center" ) ); + m_endPointLabel->SetLabel( _( "Start Point" ) ); m_AngleValue = m_item->GetAngle() / 10.0; break; case S_POLYGON: SetTitle( _( "Polygon Properties" ) ); - m_fgUpperLeftGridSizer->Show( false ); + m_sizerLeft->Show( false ); break; case S_SEGMENT: + if( m_item->GetStart().x == m_item->GetEnd().x ) + m_flipStartEnd = m_item->GetStart().y > m_item->GetEnd().y; + else + m_flipStartEnd = m_item->GetStart().x > m_item->GetEnd().x; + SetTitle( _( "Line Segment Properties" ) ); break; @@ -186,13 +193,26 @@ bool DIALOG_GRAPHIC_ITEM_PROPERTIES::TransferDataToWindow() break; } - m_startX.SetValue( m_item->GetStart().x ); - m_startY.SetValue( m_item->GetStart().y ); + if( m_flipStartEnd ) + { + m_startX.SetValue( m_item->GetEnd().x ); + m_startY.SetValue( m_item->GetEnd().y ); + } + else + { + m_startX.SetValue( m_item->GetStart().x ); + m_startY.SetValue( m_item->GetStart().y ); + } if( m_item->GetShape() == S_CIRCLE ) { m_endX.SetValue( m_item->GetRadius() ); } + else if( m_flipStartEnd ) + { + m_endX.SetValue( m_item->GetStart().x ); + m_endY.SetValue( m_item->GetStart().y ); + } else { m_endX.SetValue( m_item->GetEnd().x ); @@ -228,13 +248,26 @@ bool DIALOG_GRAPHIC_ITEM_PROPERTIES::TransferDataFromWindow() BOARD_COMMIT commit( m_parent ); commit.Modify( m_item ); - m_item->SetStartX( m_startX.GetValue() ); - m_item->SetStartY( m_startY.GetValue() ); + if( m_flipStartEnd ) + { + m_item->SetEndX( m_startX.GetValue() ); + m_item->SetEndY( m_startY.GetValue() ); + } + else + { + m_item->SetStartX( m_startX.GetValue() ); + m_item->SetStartY( m_startY.GetValue() ); + } if( m_item->GetShape() == S_CIRCLE ) { m_item->SetEnd( m_item->GetStart() + wxPoint( m_endX.GetValue(), 0 ) ); } + else if( m_flipStartEnd ) + { + m_item->SetStartX( m_endX.GetValue() ); + m_item->SetStartY( m_endY.GetValue() ); + } else { m_item->SetEndX( m_endX.GetValue() ); diff --git a/pcbnew/dialogs/dialog_graphic_item_properties_base.cpp b/pcbnew/dialogs/dialog_graphic_item_properties_base.cpp index 7ac544226b..e941b0ccb6 100644 --- a/pcbnew/dialogs/dialog_graphic_item_properties_base.cpp +++ b/pcbnew/dialogs/dialog_graphic_item_properties_base.cpp @@ -19,134 +19,150 @@ DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE::DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE( wxWind bMainSizer = new wxBoxSizer( wxVERTICAL ); wxBoxSizer* bUpperSizer; - bUpperSizer = new wxBoxSizer( wxHORIZONTAL ); + bUpperSizer = new wxBoxSizer( wxVERTICAL ); - m_fgUpperLeftGridSizer = new wxFlexGridSizer( 8, 3, 0, 0 ); - m_fgUpperLeftGridSizer->AddGrowableCol( 1 ); - m_fgUpperLeftGridSizer->SetFlexibleDirection( wxBOTH ); - m_fgUpperLeftGridSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); + m_sizerLeft = new wxGridBagSizer( 5, 5 ); + m_sizerLeft->SetFlexibleDirection( wxBOTH ); + m_sizerLeft->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); + m_sizerLeft->SetEmptyCellSize( wxSize( 5,5 ) ); - m_startXLabel = new wxStaticText( this, wxID_ANY, _("Start point X:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_startPointLabel = new wxStaticText( this, wxID_ANY, _("Start Point"), wxDefaultPosition, wxDefaultSize, 0 ); + m_startPointLabel->Wrap( -1 ); + m_sizerLeft->Add( m_startPointLabel, wxGBPosition( 0, 0 ), wxGBSpan( 1, 3 ), wxALIGN_CENTER_HORIZONTAL|wxALL, 5 ); + + m_startXLabel = new wxStaticText( this, wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_startXLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_startXLabel, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_startXLabel, wxGBPosition( 1, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_startXCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_startXCtrl, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_startXCtrl, wxGBPosition( 1, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_startXUnits = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_startXUnits = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_startXUnits->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_startXUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); + m_sizerLeft->Add( m_startXUnits, wxGBPosition( 1, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 15 ); - m_startYLabel = new wxStaticText( this, wxID_ANY, _("Start point Y:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_startYLabel = new wxStaticText( this, wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_startYLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_startYLabel, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_startYLabel, wxGBPosition( 2, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_startYCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_startYCtrl, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_startYCtrl, wxGBPosition( 2, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_startYUnits = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_startYUnits = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_startYUnits->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_startYUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); + m_sizerLeft->Add( m_startYUnits, wxGBPosition( 2, 2 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 15 ); - m_endXLabel = new wxStaticText( this, wxID_ANY, _("End point X:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_endPointLabel = new wxStaticText( this, wxID_ANY, _("End Point"), wxDefaultPosition, wxDefaultSize, 0 ); + m_endPointLabel->Wrap( -1 ); + m_sizerLeft->Add( m_endPointLabel, wxGBPosition( 0, 3 ), wxGBSpan( 1, 3 ), wxALIGN_CENTER_HORIZONTAL|wxALL, 5 ); + + m_endXLabel = new wxStaticText( this, wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_endXLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_endXLabel, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_endXLabel, wxGBPosition( 1, 3 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_endXCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_endXCtrl, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_endXCtrl, wxGBPosition( 1, 4 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_endXUnits = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_endXUnits = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_endXUnits->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_endXUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); + m_sizerLeft->Add( m_endXUnits, wxGBPosition( 1, 5 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 ); - m_endYLabel = new wxStaticText( this, wxID_ANY, _("End point Y:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_endYLabel = new wxStaticText( this, wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_endYLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_endYLabel, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_endYLabel, wxGBPosition( 2, 3 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_endYCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_endYCtrl, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 ); + m_sizerLeft->Add( m_endYCtrl, wxGBPosition( 2, 4 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_endYUnits = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_endYUnits = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_endYUnits->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_endYUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); + m_sizerLeft->Add( m_endYUnits, wxGBPosition( 2, 5 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 ); - m_BezierPointC1XLabel = new wxStaticText( this, wxID_ANY, _("Bezier point C1 X:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_bezierCtrlPt1Label = new wxStaticText( this, wxID_ANY, _("Bezier Control Pt"), wxDefaultPosition, wxDefaultSize, 0 ); + m_bezierCtrlPt1Label->Wrap( -1 ); + m_sizerLeft->Add( m_bezierCtrlPt1Label, wxGBPosition( 4, 0 ), wxGBSpan( 1, 3 ), wxALIGN_CENTER_HORIZONTAL|wxALL, 5 ); + + m_BezierPointC1XLabel = new wxStaticText( this, wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC1XLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC1XLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 ); + m_sizerLeft->Add( m_BezierPointC1XLabel, wxGBPosition( 5, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_BezierC1X_Ctrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_BezierC1X_Ctrl, 0, wxTOP|wxBOTTOM|wxLEFT|wxEXPAND, 5 ); + m_sizerLeft->Add( m_BezierC1X_Ctrl, wxGBPosition( 5, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC1XUnit = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC1XUnit = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC1XUnit->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC1XUnit, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); + m_sizerLeft->Add( m_BezierPointC1XUnit, wxGBPosition( 5, 2 ), wxGBSpan( 1, 1 ), wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC1YLabel = new wxStaticText( this, wxID_ANY, _("Bezier point C1 Y:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC1YLabel = new wxStaticText( this, wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC1YLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC1YLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 ); + m_sizerLeft->Add( m_BezierPointC1YLabel, wxGBPosition( 6, 0 ), wxGBSpan( 1, 1 ), wxLEFT|wxALIGN_CENTER_VERTICAL, 5 ); m_BezierC1Y_Ctrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_BezierC1Y_Ctrl, 0, wxTOP|wxBOTTOM|wxLEFT|wxEXPAND, 5 ); + m_sizerLeft->Add( m_BezierC1Y_Ctrl, wxGBPosition( 6, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC1YUnit = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC1YUnit = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC1YUnit->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC1YUnit, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); + m_sizerLeft->Add( m_BezierPointC1YUnit, wxGBPosition( 6, 2 ), wxGBSpan( 1, 1 ), wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC2XLabel = new wxStaticText( this, wxID_ANY, _("Bezier point C2 X:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_bezierCtrlPt2Label = new wxStaticText( this, wxID_ANY, _("Bezier Control Pt"), wxDefaultPosition, wxDefaultSize, 0 ); + m_bezierCtrlPt2Label->Wrap( -1 ); + m_sizerLeft->Add( m_bezierCtrlPt2Label, wxGBPosition( 4, 3 ), wxGBSpan( 1, 3 ), wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); + + m_BezierPointC2XLabel = new wxStaticText( this, wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC2XLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC2XLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 ); + m_sizerLeft->Add( m_BezierPointC2XLabel, wxGBPosition( 5, 3 ), wxGBSpan( 1, 1 ), wxLEFT|wxALIGN_CENTER_VERTICAL, 5 ); m_BezierC2X_Ctrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_BezierC2X_Ctrl, 0, wxTOP|wxBOTTOM|wxLEFT|wxEXPAND, 5 ); + m_sizerLeft->Add( m_BezierC2X_Ctrl, wxGBPosition( 5, 4 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC2XUnit = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC2XUnit = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC2XUnit->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC2XUnit, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); + m_sizerLeft->Add( m_BezierPointC2XUnit, wxGBPosition( 5, 5 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 ); - m_BezierPointC2YLabel = new wxStaticText( this, wxID_ANY, _("Bezier point C2 Y:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC2YLabel = new wxStaticText( this, wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC2YLabel->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC2YLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 ); + m_sizerLeft->Add( m_BezierPointC2YLabel, wxGBPosition( 6, 3 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); m_BezierC2Y_Ctrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_fgUpperLeftGridSizer->Add( m_BezierC2Y_Ctrl, 0, wxTOP|wxBOTTOM|wxLEFT|wxEXPAND, 5 ); + m_sizerLeft->Add( m_BezierC2Y_Ctrl, wxGBPosition( 6, 4 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 ); - m_BezierPointC2YUnit = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_BezierPointC2YUnit = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_BezierPointC2YUnit->Wrap( -1 ); - m_fgUpperLeftGridSizer->Add( m_BezierPointC2YUnit, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); + m_sizerLeft->Add( m_BezierPointC2YUnit, wxGBPosition( 6, 5 ), wxGBSpan( 1, 1 ), wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 ); - bUpperSizer->Add( m_fgUpperLeftGridSizer, 1, wxEXPAND|wxRIGHT, 30 ); + bUpperSizer->Add( m_sizerLeft, 1, wxEXPAND|wxBOTTOM, 20 ); wxBoxSizer* bUpperRightSizer; bUpperRightSizer = new wxBoxSizer( wxVERTICAL ); wxFlexGridSizer* fgUpperRightGridSizer; - fgUpperRightGridSizer = new wxFlexGridSizer( 0, 3, 0, 0 ); + fgUpperRightGridSizer = new wxFlexGridSizer( 0, 3, 5, 0 ); fgUpperRightGridSizer->AddGrowableCol( 1 ); fgUpperRightGridSizer->SetFlexibleDirection( wxBOTH ); fgUpperRightGridSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); m_angleLabel = new wxStaticText( this, wxID_ANY, _("Arc angle:"), wxDefaultPosition, wxDefaultSize, 0 ); m_angleLabel->Wrap( -1 ); - fgUpperRightGridSizer->Add( m_angleLabel, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP, 5 ); + fgUpperRightGridSizer->Add( m_angleLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxLEFT, 5 ); m_angleCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - fgUpperRightGridSizer->Add( m_angleCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxALL, 5 ); + fgUpperRightGridSizer->Add( m_angleCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); m_angleUnits = new wxStaticText( this, wxID_ANY, _("deg"), wxDefaultPosition, wxDefaultSize, 0 ); m_angleUnits->Wrap( -1 ); - fgUpperRightGridSizer->Add( m_angleUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxRIGHT, 5 ); + fgUpperRightGridSizer->Add( m_angleUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT, 5 ); m_thicknessLabel = new wxStaticText( this, wxID_ANY, _("Line thickness:"), wxDefaultPosition, wxDefaultSize, 0 ); m_thicknessLabel->Wrap( -1 ); - fgUpperRightGridSizer->Add( m_thicknessLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 ); + fgUpperRightGridSizer->Add( m_thicknessLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxLEFT, 5 ); m_thicknessCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - fgUpperRightGridSizer->Add( m_thicknessCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxALL, 5 ); + fgUpperRightGridSizer->Add( m_thicknessCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); - m_thicknessUnits = new wxStaticText( this, wxID_ANY, _("Unit"), wxDefaultPosition, wxDefaultSize, 0 ); + m_thicknessUnits = new wxStaticText( this, wxID_ANY, _("unit"), wxDefaultPosition, wxDefaultSize, 0 ); m_thicknessUnits->Wrap( -1 ); - fgUpperRightGridSizer->Add( m_thicknessUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxRIGHT, 5 ); + fgUpperRightGridSizer->Add( m_thicknessUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT, 5 ); m_LayerLabel = new wxStaticText( this, wxID_ANY, _("Layer:"), wxDefaultPosition, wxDefaultSize, 0 ); m_LayerLabel->Wrap( -1 ); @@ -165,7 +181,7 @@ DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE::DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE( wxWind bUpperSizer->Add( bUpperRightSizer, 0, wxEXPAND, 5 ); - bMainSizer->Add( bUpperSizer, 1, wxEXPAND|wxALL, 10 ); + bMainSizer->Add( bUpperSizer, 1, wxEXPAND|wxALL, 5 ); m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); bMainSizer->Add( m_staticline1, 0, wxEXPAND|wxRIGHT|wxLEFT, 10 ); diff --git a/pcbnew/dialogs/dialog_graphic_item_properties_base.fbp b/pcbnew/dialogs/dialog_graphic_item_properties_base.fbp index 5bee84fe2a..0318ee5cd2 100644 --- a/pcbnew/dialogs/dialog_graphic_item_properties_base.fbp +++ b/pcbnew/dialogs/dialog_graphic_item_properties_base.fbp @@ -1,8 +1,8 @@ - + - + C++ 1 source_name @@ -16,9 +16,9 @@ none 1 DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE - + . - + 1 1 1 @@ -29,2149 +29,2564 @@ 0 wxAUI_MGR_DEFAULT - + wxBOTH - + 1 1 impl_virtual - - - + + + 0 wxID_ANY - + -1,-1 DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE - + -1,-1 wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxSYSTEM_MENU DIALOG_SHIM; dialog_shim.h Graphic Item Properties - - - - - - - - - - - - - + + + + + + + + + + + + + OnClose - - - - - + + + + + OnInitDlg - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - + bMainSizer wxVERTICAL none - 10 + 5 wxEXPAND|wxALL 1 - + bUpperSizer - wxHORIZONTAL + wxVERTICAL none - 30 - wxEXPAND|wxRIGHT + 20 + wxEXPAND|wxBOTTOM 1 - - 3 + + 5,5 wxBOTH - 1 - - 0 - - m_fgUpperLeftGridSizer + + + 5 + + m_sizerLeft wxFLEX_GROWMODE_SPECIFIED protected - 8 - 0 - + 5 + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP - 0 + 3 + 0 + wxALIGN_CENTER_HORIZONTAL|wxALL + 0 + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + Start Point + + 0 + + + 0 + + 1 + m_startPointLabel + 1 + + + protected + 1 + + Resizable + 1 + + + ; forward_declare + 0 + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + 1 + 0 + wxALIGN_CENTER_VERTICAL|wxLEFT + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Start point X: - + X: + 0 - - + + 0 - + 1 m_startXLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP - 0 + 1 + 1 + wxALIGN_CENTER_VERTICAL + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_startXCtrl 1 - - + + protected 1 - + Resizable 1 - - + + ; ; forward_declare 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - 5 - wxALIGN_CENTER_VERTICAL|wxALL - 0 + + 15 + 1 + 2 + wxALIGN_CENTER_VERTICAL|wxRIGHT + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_startXUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP - 0 + 1 + 0 + wxALIGN_CENTER_VERTICAL|wxLEFT + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Start point Y: - + Y: + 0 - - + + 0 - + 1 m_startYLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP - 0 + 1 + 1 + wxALIGN_CENTER_VERTICAL + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_startYCtrl 1 - - + + protected 1 - + Resizable 1 - - + + ; ; forward_declare 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - 5 - wxALIGN_CENTER_VERTICAL|wxALL - 0 + + 15 + 1 + 2 + wxALIGN_CENTER_VERTICAL|wxRIGHT + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_startYUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP - 0 + 3 + 3 + wxALIGN_CENTER_HORIZONTAL|wxALL + 0 + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + End Point + + 0 + + + 0 + + 1 + m_endPointLabel + 1 + + + protected + 1 + + Resizable + 1 + + + ; forward_declare + 0 + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + 1 + 3 + wxALIGN_CENTER_VERTICAL|wxLEFT + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - End point X: - + X: + 0 - - + + 0 - + 1 m_endXLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP - 0 + 1 + 4 + wxALIGN_CENTER_VERTICAL + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_endXCtrl 1 - - + + protected 1 - + Resizable 1 - - + + ; ; forward_declare 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxALL - 0 + 1 + 5 + wxALIGN_CENTER_VERTICAL|wxRIGHT + 1 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_endXUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP - 0 + 1 + 3 + wxALIGN_CENTER_VERTICAL|wxLEFT + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - End point Y: - + Y: + 0 - - + + 0 - + 1 m_endYLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxEXPAND|wxLEFT|wxTOP - 0 + 1 + 4 + wxALIGN_CENTER_VERTICAL + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_endYCtrl 1 - - + + protected 1 - + Resizable 1 - - + + ; ; forward_declare 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxALL - 0 + 1 + 5 + wxALIGN_CENTER_VERTICAL|wxRIGHT + 2 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_endYUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT - 0 + 3 + 0 + wxALIGN_CENTER_HORIZONTAL|wxALL + 4 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Bezier point C1 X: - + Bezier Control Pt + 0 - - + + 0 - + + 1 + m_bezierCtrlPt1Label + 1 + + + protected + 1 + + Resizable + 1 + + + ; forward_declare + 0 + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + 1 + 0 + wxALIGN_CENTER_VERTICAL|wxLEFT + 5 + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + X: + + 0 + + + 0 + 1 m_BezierPointC1XLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxTOP|wxBOTTOM|wxLEFT|wxEXPAND - 0 + 1 + 1 + wxALIGN_CENTER_VERTICAL + 5 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_BezierC1X_Ctrl 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 + 1 + 2 + wxRIGHT|wxALIGN_CENTER_VERTICAL + 5 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_BezierPointC1XUnit 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT - 0 + 1 + 0 + wxLEFT|wxALIGN_CENTER_VERTICAL + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Bezier point C1 Y: - + Y: + 0 - - + + 0 - + 1 m_BezierPointC1YLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxTOP|wxBOTTOM|wxLEFT|wxEXPAND - 0 + 1 + 1 + wxALIGN_CENTER_VERTICAL + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_BezierC1Y_Ctrl 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 + 1 + 2 + wxRIGHT|wxALIGN_CENTER_VERTICAL + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_BezierPointC1YUnit 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT - 0 + 3 + 3 + wxALL|wxALIGN_CENTER_HORIZONTAL + 4 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Bezier point C2 X: - + Bezier Control Pt + 0 - - + + 0 - + + 1 + m_bezierCtrlPt2Label + 1 + + + protected + 1 + + Resizable + 1 + + + ; forward_declare + 0 + + + + + -1 + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 + 1 + 3 + wxLEFT|wxALIGN_CENTER_VERTICAL + 5 + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 1 + + 1 + + 0 + 0 + wxID_ANY + X: + + 0 + + + 0 + 1 m_BezierPointC2XLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxTOP|wxBOTTOM|wxLEFT|wxEXPAND - 0 + 1 + 4 + wxALIGN_CENTER_VERTICAL + 5 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_BezierC2X_Ctrl 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 + 1 + 5 + wxALIGN_CENTER_VERTICAL|wxRIGHT + 5 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_BezierPointC2XUnit 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT - 0 + 1 + 3 + wxALIGN_CENTER_VERTICAL|wxLEFT + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Bezier point C2 Y: - + Y: + 0 - - + + 0 - + 1 m_BezierPointC2YLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxTOP|wxBOTTOM|wxLEFT|wxEXPAND - 0 + 1 + 4 + wxALIGN_CENTER_VERTICAL + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_BezierC2Y_Ctrl 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 + 1 + 5 + wxRIGHT|wxALIGN_CENTER_VERTICAL + 6 + 1 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_BezierPointC2YUnit 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + @@ -2181,7 +2596,7 @@ wxEXPAND 0 - + bUpperRightSizer wxVERTICAL none @@ -2193,526 +2608,526 @@ 3 wxBOTH 1 - + 0 - + fgUpperRightGridSizer wxFLEX_GROWMODE_SPECIFIED none 0 - 0 + 5 5 - wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxTOP + wxALIGN_CENTER_VERTICAL|wxTOP|wxLEFT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY Arc angle: - + 0 - - + + 0 - + 1 m_angleLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + 5 - wxALIGN_CENTER_VERTICAL|wxEXPAND|wxALL + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_angleCtrl 1 - - + + protected 1 - + Resizable 1 - - + + ; ; forward_declare 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxRIGHT + wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY deg - + 0 - - + + 0 - + 1 m_angleUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT + wxALIGN_CENTER_VERTICAL|wxTOP|wxLEFT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY Line thickness: - + 0 - - + + 0 - + 1 m_thicknessLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + 5 - wxALIGN_CENTER_VERTICAL|wxEXPAND|wxALL + wxALIGN_CENTER_VERTICAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - + 0 - + 0 - + 1 m_thicknessCtrl 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxRIGHT + wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT 0 1 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - Unit - + unit + 0 - - + + 0 - + 1 m_thicknessUnits 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + @@ -2724,78 +3139,78 @@ 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 0 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY Layer: - + 0 - - + + 0 - + 1 m_LayerLabel 1 - - + + protected 1 - + Resizable 1 - - - + + + 0 - - - - + + + + -1 - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + @@ -2807,86 +3222,86 @@ 1 1 1 - - - - - - - + + + + + + + 1 0 - + 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - - + + 0 - + 1 m_LayerSelectionCtrl 1 - - + + protected 1 - + Resizable -1 1 - - + + PCB_LAYER_BOX_SELECTOR; pcb_layer_box_selector.h 0 - - + + wxFILTER_NONE wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -2914,76 +3329,76 @@ 1 1 1 - - - - - - - + + + + + + + 1 0 1 - + 1 0 Dock 0 Left 1 - + 1 - + 0 0 wxID_ANY - + 0 - - + + 0 - + 1 m_staticline1 1 - - + + protected 1 - + Resizable 1 - + wxLI_HORIZONTAL - + 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -2999,17 +3414,17 @@ 1 0 0 - + m_StandardButtonsSizer protected - - - - - - - - + + + + + + + + diff --git a/pcbnew/dialogs/dialog_graphic_item_properties_base.h b/pcbnew/dialogs/dialog_graphic_item_properties_base.h index dc81e63971..1ab91dede3 100644 --- a/pcbnew/dialogs/dialog_graphic_item_properties_base.h +++ b/pcbnew/dialogs/dialog_graphic_item_properties_base.h @@ -21,8 +21,9 @@ class PCB_LAYER_BOX_SELECTOR; #include #include #include -#include +#include #include +#include #include #include #include @@ -38,25 +39,29 @@ class DIALOG_GRAPHIC_ITEM_PROPERTIES_BASE : public DIALOG_SHIM private: protected: - wxFlexGridSizer* m_fgUpperLeftGridSizer; + wxGridBagSizer* m_sizerLeft; + wxStaticText* m_startPointLabel; wxStaticText* m_startXLabel; wxTextCtrl* m_startXCtrl; wxStaticText* m_startXUnits; wxStaticText* m_startYLabel; wxTextCtrl* m_startYCtrl; wxStaticText* m_startYUnits; + wxStaticText* m_endPointLabel; wxStaticText* m_endXLabel; wxTextCtrl* m_endXCtrl; wxStaticText* m_endXUnits; wxStaticText* m_endYLabel; wxTextCtrl* m_endYCtrl; wxStaticText* m_endYUnits; + wxStaticText* m_bezierCtrlPt1Label; wxStaticText* m_BezierPointC1XLabel; wxTextCtrl* m_BezierC1X_Ctrl; wxStaticText* m_BezierPointC1XUnit; wxStaticText* m_BezierPointC1YLabel; wxTextCtrl* m_BezierC1Y_Ctrl; wxStaticText* m_BezierPointC1YUnit; + wxStaticText* m_bezierCtrlPt2Label; wxStaticText* m_BezierPointC2XLabel; wxTextCtrl* m_BezierC2X_Ctrl; wxStaticText* m_BezierPointC2XUnit;