Fixes:
* Various special cases around junctions on pins and dragging.
* Some rotations of endpoints resulting in a 45 degree rotate.
* Some cases where it was possible to get a line with neither
endpoint selected, and also substractive unselecting only one of two
selected endpoints unselecting both.
* Use line midpoint for sorting. Start and endpoints aren't
consistent in the order they appear on the X or Y axis. So,
we need to use the midpoint for our position for consistent
sorting when dragging groups of parallel lines where some
have the start and end reversed.
Other:
* Rename TEMP_SELECTED TO SELECTED_BY_DRAG. This is the actual meaning
of the flag, and should reduce confusion as
to when it should be used.
* Move usage of TEMP_SELECTED as an algorithmic mark to CANDIDATE
instead.
* Fix mistaken clearing of START_POINT and ENDPOINT.
* Move endpoint setting and clearing out of narrowSelection, and into
selectPoint and selectMultiple.
* Don't show dangling end warnings on new lines
Keeps the lines connected but doesn't solve the crossed-wire mixups.
This allows common usage (mirroring labels/rotating segments) and leaves
prevention of the crossed wires to the user.
We can't really prevent crossed wires when rotating e.g. a part with
wires connected to 4 sides and users will not expect that. But we
should not disable useful features like mirroring multiple parallel
items to avoid a known impossible situation
Also provides an alternative solution to 345f506f0c that allows us to
rotate groups without destroying connections on hover
Fixes https://gitlab.com/kicad/code/kicad/issues/8403
Fixes https://gitlab.com/kicad/code/kicad/issues/8523
1) Expand the accuracy to at least the grid spacing
2) Move pin-selects-symbol logic to Selectable()
3) Recode pick-closest algorithm to handle exactHits and inexactHits
separately
4) Remove pin target from bounding box in favour of expanding it to
at least as wide as the pin decoration (this prevents the accuracy
off the end of the pin from growing too large)
This standardizes selection tools in SELECTION_TOOL class to be able to
handle a long-click as asking for a non-heuristic disambiguation menu.
Fixes https://gitlab.com/kicad/code/kicad/issues/8490
The native cursor must be set on the GAL canvas wx object,
not its frame (otherwise on GTK the cursor is only set
when we get a request for it from the WM and not immediately).
Fixes https://gitlab.com/kicad/code/kicad/issues/6421
SHIFT, CTRL, ALT modifier keys were handled in 2 different codes, one for
the selection tool and another to modify the mouse cursor shape, with 2
different configs.
Now the modifiers are managed from only one function.
Pcbnew: group also SHIFT, CTRL, ALT modifier keys management to a specific function.
Fixes#8021https://gitlab.com/kicad/code/kicad/issues/8021
We kept having various issues of the pointer list going stale. This
will prevent all permutations of that.
Also while I was in there I fixed the double-move thing (see bug
number).
Fixes https://gitlab.com/kicad/code/kicad/issues/7910
* Frames moved: cvpcb, cvpcb footprints frame, gerbview, pagelayout editor
This also introduces new EDITOR_CONDITIONS that are used to set the
conditions of very common editor settings.
Also, some IDs were converted to tools in the pagelayout editor.
Rather than displaying dialog that has every update option possible like
updating footprints in the board editor, this change updates the library
symbol immediately using the symbol library identifier and requires no
additional input from the user.
ADDED: Context menu entry for schematic symbols to update the symbol from
the symbol library using the existing library identifier.
We were running into various corner conditions where a tool's event
loop would exit while the tool was still active, or the tool would
get popped while we were still in the event loop. (A lot of these
had to do with the POINT_EDITOR's, but not all of them.)
The new architecture:
1) tools always do a Push()/Pop()
2) everyone is responsible for their own pops; no more stack-clearing
on a cancel
3) CancelInteractive events go to all tools to facilitate (2)