From 883c9e14f3cbd5b9b59cad19592ae916d3e6a5eb Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Thu, 22 Oct 2020 11:56:30 +0100 Subject: [PATCH] Don't draw 0-clearance clearance lines. Fixes https://gitlab.com/kicad/code/kicad/issues/6108 --- pcbnew/pcb_painter.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pcbnew/pcb_painter.cpp b/pcbnew/pcb_painter.cpp index e7bad9fd89..1dc72cf8d1 100644 --- a/pcbnew/pcb_painter.cpp +++ b/pcbnew/pcb_painter.cpp @@ -1083,7 +1083,7 @@ void PCB_PAINTER::draw( const D_PAD* aPad, int aLayer ) int clearance = aPad->GetOwnClearance( m_pcbSettings.GetActiveLayer() ); - if( flashActiveLayer ) + if( flashActiveLayer && clearance > 0 ) { auto shape = std::dynamic_pointer_cast( aPad->GetEffectiveShape() ); @@ -1107,7 +1107,7 @@ void PCB_PAINTER::draw( const D_PAD* aPad, int aLayer ) m_gal->DrawPolygon( polySet ); } } - else if( aPad->GetEffectiveHoleShape() ) + else if( aPad->GetEffectiveHoleShape() && clearance > 0 ) { clearance += bds.GetHolePlatingThickness(); @@ -1115,7 +1115,6 @@ void PCB_PAINTER::draw( const D_PAD* aPad, int aLayer ) m_gal->DrawSegment( seg->GetSeg().A, seg->GetSeg().B, seg->GetWidth() + 2 * clearance ); } - } } }