Make sure polygonization error is on correct side.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16869
This commit is contained in:
Jeff Young 2024-02-03 19:45:54 +00:00
parent 2fc96c1d11
commit 36275bcbc5
1 changed files with 8 additions and 1 deletions

View File

@ -1737,7 +1737,14 @@ void EDA_SHAPE::TransformShapeToPolygon( SHAPE_POLY_SET& aBuffer, int aClearance
tmp.Append( poly.GetPoint( jj ) );
if( width > 0 )
tmp.Inflate( width/2, CORNER_STRATEGY::ROUND_ALL_CORNERS, aError, false);
{
int inflate = width / 2;
if( aErrorLoc == ERROR_OUTSIDE )
inflate += aError;
tmp.Inflate( inflate, CORNER_STRATEGY::ROUND_ALL_CORNERS, aError );
}
aBuffer.Append( tmp );
}