GRID HELPER: Consider all snappable items

When snapping, we should allow any point identified as a snappable
point.  The additional consideration for corners might be used for
alignment in the future.

Fixes: lp:1802741
* https://bugs.launchpad.net/kicad/+bug/1802741
This commit is contained in:
Seth Hillbrand 2018-11-11 11:03:31 -08:00
parent fcafe5362f
commit cf20b39ddc
1 changed files with 1 additions and 1 deletions

View File

@ -281,7 +281,7 @@ VECTOR2I GRID_HELPER::BestSnapAnchor( const VECTOR2I& aOrigin, const LSET& aLaye
computeAnchors( item, aOrigin ); computeAnchors( item, aOrigin );
} }
ANCHOR* nearest = nearestAnchor( aOrigin, CORNER | SNAPPABLE, aLayers ); ANCHOR* nearest = nearestAnchor( aOrigin, SNAPPABLE, aLayers );
VECTOR2I nearestGrid = Align( aOrigin ); VECTOR2I nearestGrid = Align( aOrigin );
double gridDist = ( nearestGrid - aOrigin ).EuclideanNorm(); double gridDist = ( nearestGrid - aOrigin ).EuclideanNorm();