From 8445783216b04503515076d7fcce42fec1167c85 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Tue, 18 Jan 2022 13:45:00 +0000 Subject: [PATCH] Fix backwards arcs in legacy LIB_ARCs. Fixes https://gitlab.com/kicad/code/kicad/issues/10455 --- common/eda_shape.cpp | 3 +-- eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp | 11 ++++------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/common/eda_shape.cpp b/common/eda_shape.cpp index 0bd225897b..22879140e3 100644 --- a/common/eda_shape.cpp +++ b/common/eda_shape.cpp @@ -508,7 +508,6 @@ void EDA_SHAPE::SetArcGeometry( const VECTOR2I& aStart, const VECTOR2I& aMid, co std::swap( m_start, m_end ); m_endsSwapped = true; } - } @@ -600,8 +599,8 @@ void EDA_SHAPE::ShapeGetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vectorSetCenter( center ); /** * This accounts for an oddity in the old library format, where the symbol is overdefined. * The previous draw (based on wxwidgets) used start point and end point and always drew @@ -994,13 +995,9 @@ LIB_SHAPE* SCH_SEXPR_PARSER::parseArc() * these points were stored in the file, so we need to mimic the swapping of start/end * points rather than using the stored angles in order to properly map edge cases. */ - if( !TRANSFORM().MapAngles( &startAngle, &endAngle ) ) - { - VECTOR2I temp = arc->GetStart(); - arc->SetStart( arc->GetEnd() ); - arc->SetEnd( temp ); - } - arc->SetCenter( center ); + VECTOR2I temp = arc->GetStart(); + arc->SetStart( arc->GetEnd() ); + arc->SetEnd( temp ); } else {