Handle DXF arcs with a flipped coord system.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14905
This commit is contained in:
Jeff Young 2023-08-27 13:16:34 +01:00
parent 3f26b29aa2
commit 75b160e83a
1 changed files with 7 additions and 0 deletions

View File

@ -587,6 +587,13 @@ void DXF_IMPORT_PLUGIN::addArc( const DL_ArcData& aData )
EDA_ANGLE startangle( aData.angle1, DEGREES_T );
EDA_ANGLE endangle( aData.angle2, DEGREES_T );
if( ( arbAxis.GetScale().x < 0 ) != ( arbAxis.GetScale().y < 0 ) )
{
startangle = ANGLE_180 - startangle;
endangle = ANGLE_180 - endangle;
std::swap( startangle, endangle );
}
// Init arc start point
VECTOR2D startPoint( aData.radius, 0.0 );
RotatePoint( startPoint, -startangle );