Hittesting for background-body-filled shapes (and other fills).
Fixes https://gitlab.com/kicad/code/kicad/issues/7286
This commit is contained in:
parent
0dd65d9cd1
commit
de1c3a83fd
|
@ -54,7 +54,10 @@ bool LIB_CIRCLE::HitTest( const wxPoint& aPosRef, int aAccuracy ) const
|
|||
if( abs( dist - GetRadius() ) <= mindist )
|
||||
return true;
|
||||
|
||||
return false;
|
||||
if( m_fill == FILL_TYPE::NO_FILL )
|
||||
return false;
|
||||
|
||||
return dist <= GetRadius();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -250,7 +250,10 @@ bool LIB_RECTANGLE::HitTest( const wxPoint& aPosition, int aAccuracy ) const
|
|||
if( TestSegmentHit( aPosition, start, end, mindist ) )
|
||||
return true;
|
||||
|
||||
return false;
|
||||
if( m_fill == FILL_TYPE::NO_FILL )
|
||||
return false;
|
||||
|
||||
return GetBoundingBox().Contains( aPosition );
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue