From 30a428677f7a227fa540a3af10c99f2a9ce2f06a Mon Sep 17 00:00:00 2001 From: Jon Evans Date: Fri, 11 Sep 2020 20:45:36 -0400 Subject: [PATCH] Change rotation command to only impact dimension text --- pcbnew/class_dimension.cpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/pcbnew/class_dimension.cpp b/pcbnew/class_dimension.cpp index 67ed2184fc..950cb5b9f8 100644 --- a/pcbnew/class_dimension.cpp +++ b/pcbnew/class_dimension.cpp @@ -217,23 +217,16 @@ void DIMENSION::Move( const wxPoint& offset ) void DIMENSION::Rotate( const wxPoint& aRotCentre, double aAngle ) { - wxPoint tmp = m_text.GetTextPos(); - RotatePoint( &tmp, aRotCentre, aAngle ); - m_text.SetTextPos( tmp ); + if( m_keepTextAligned ) + m_keepTextAligned = false; double newAngle = m_text.GetTextAngle() + aAngle; if( newAngle >= 3600 ) newAngle -= 3600; - if( newAngle > 900 && newAngle < 2700 ) - newAngle -= 1800; - m_text.SetTextAngle( newAngle ); - RotatePoint( &m_start, aRotCentre, aAngle ); - RotatePoint( &m_end, aRotCentre, aAngle ); - Update(); }