mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 02:03:12 +02:00
Avoid negative pad sizes in plot
Clearance can be negative but setting the pad size to negative leads to invalid output in plotting Fixes https://gitlab.com/kicad/code/kicad/-/issues/18996
This commit is contained in:
parent
7074c31374
commit
3f36d7f1dd
@ -563,7 +563,8 @@ void PlotStandardLayer( BOARD* aBoard, PLOTTER* aPlotter, LSET aLayerMask,
|
||||
// anchor will be added to the pad shape when plotting the pad. So now the
|
||||
// polygonal shape is built, we can clamp the anchor size
|
||||
if( mask_clearance < 0 ) // we expect margin.x = margin.y for custom pads
|
||||
dummy.SetSize( aLayer, padPlotsSize );
|
||||
dummy.SetSize( aLayer, VECTOR2I( std::max( 0, padPlotsSize.x ),
|
||||
std::max( 0, padPlotsSize.y ) ) );
|
||||
|
||||
itemplotter.PlotPad( &dummy, aLayer, color, padPlotMode );
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user