Allow selection of NPTH pads with zero copper size
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9249
This commit is contained in:
parent
422def1261
commit
e2368b733c
|
@ -1478,6 +1478,9 @@ bool SHAPE_POLY_SET::Collide( const SEG& aSeg, int aClearance, int* aActual,
|
||||||
bool SHAPE_POLY_SET::Collide( const VECTOR2I& aP, int aClearance, int* aActual,
|
bool SHAPE_POLY_SET::Collide( const VECTOR2I& aP, int aClearance, int* aActual,
|
||||||
VECTOR2I* aLocation ) const
|
VECTOR2I* aLocation ) const
|
||||||
{
|
{
|
||||||
|
if( IsEmpty() || VertexCount() == 0 )
|
||||||
|
return false;
|
||||||
|
|
||||||
VECTOR2I nearest;
|
VECTOR2I nearest;
|
||||||
ecoord dist_sq = SquaredDistance( aP, aLocation ? &nearest : nullptr );
|
ecoord dist_sq = SquaredDistance( aP, aLocation ? &nearest : nullptr );
|
||||||
|
|
||||||
|
|
|
@ -854,6 +854,8 @@ SHAPE_POLY_SET FOOTPRINT::GetBoundingHull() const
|
||||||
{
|
{
|
||||||
pad->TransformShapeWithClearanceToPolygon( rawPolys, UNDEFINED_LAYER, 0, ARC_LOW_DEF,
|
pad->TransformShapeWithClearanceToPolygon( rawPolys, UNDEFINED_LAYER, 0, ARC_LOW_DEF,
|
||||||
ERROR_OUTSIDE );
|
ERROR_OUTSIDE );
|
||||||
|
// In case hole is larger than pad
|
||||||
|
pad->TransformHoleWithClearanceToPolygon( rawPolys, 0, ARC_LOW_DEF, ERROR_OUTSIDE );
|
||||||
}
|
}
|
||||||
|
|
||||||
for( FP_ZONE* zone : m_fp_zones )
|
for( FP_ZONE* zone : m_fp_zones )
|
||||||
|
|
Loading…
Reference in New Issue