Commit Graph

13 Commits

Author SHA1 Message Date
Ian McInerney fc20eaa083 Fix some compiler and Coverity warnings 2020-12-17 00:30:22 +00:00
Wayne Stambaugh dd4298bb94 Coverity fixes: 280374, 313611, 313648, 313649, and 314720. 2020-12-11 13:29:52 -05:00
Jeff Young 4f90c03c7d Allow snapItem to be re-activated.
Don't clear until another snapPoint is chosen.  This allows line
snapping to re-appear when they move back in range.

Fixes https://gitlab.com/kicad/code/kicad/issues/5973
2020-12-05 23:57:33 +00:00
Jeff Young a3406e7514 Make snapping more predictable.
In particular, allow grid positions to override line snapping if
they're a better match (and do this independently on x and y axes).
We already allow a nearer anchor to override, but that should be
based on a cartesian distance rather than independent axes.

Fixes https://gitlab.com/kicad/code/kicad/issues/6626
2020-12-04 22:50:30 +00:00
Jeff Young a19028a396 Hook up EE_GRID_HELPER to some more tools.
Also implements EE_GRID_HELPER layers so that connectable things
snap to connectable things and graphics snap to graphics.

Fixes https://gitlab.com/kicad/code/kicad/issues/5641
2020-12-03 15:16:34 +00:00
Jeff Young 43fe228367 Hook up a bit more of the EE_GRID_HELPER.
Fixes https://gitlab.com/kicad/code/kicad/issues/5985
2020-12-02 23:18:33 +00:00
Werni 0e44f5128c Add const specifiers 2020-11-18 19:50:36 +00:00
Seth Hillbrand 471f81742f ADDED: Align to Grid function in Eeschema
Adds tool option to align selected elements to the current grid.

Fixes https://gitlab.com/kicad/code/kicad/issues/5481
2020-09-17 12:27:43 -07:00
Seth Hillbrand 67a7aa8ba4 Make snapping size grid-dependent
Fixes https://gitlab.com/kicad/code/kicad/issues/5638

Fixes https://gitlab.com/kicad/code/kicad/issues/5588
2020-09-15 12:07:34 -07:00
Seth Hillbrand 1703657fb5 Decrease default snap range
The snap range needs tuning to preference and monitor resolution.  This
shifts the default range down for users until the customization bits are
implemented.
2020-09-12 08:34:21 -07:00
Seth Hillbrand d14c6ba71f Keep snap line alignment before new snaps
Also fixes the alignment line that was supposed to be dashed and not
solid.
2020-09-11 14:22:41 -07:00
Seth Hillbrand f493e270ea ADDED: Menu option to enable/disable snap to grid
You can now enable and disable snap to grid when drawing/editing across
all apps.  You can also tie snap to grid to the visibility of the grid
to allow rapid enable/disable via grid display.
2020-09-10 20:09:30 -07:00
Seth Hillbrand 173b4ff588 Add snapping to eeschema
This generalizes both the SetPosition() function and ORIGIN_VIEWITEM
class away from the pcbnew-centric.
2020-09-09 10:18:15 -07:00