Commit Graph

1319 Commits

Author SHA1 Message Date
Jeff Young ba7ad7ddf4 Fix bug with PCBNEW_PICKER_TOOL not doing a push/pop.
PICKER_TOOL got updated but PCBNEW_PICKER_TOOL didn't.
2019-07-16 20:25:25 +01:00
Jeff Young e816a0c29d Push Eeschema & PLEditor PICKER_TOOLs down into common.
Also implements a more robust push/pop tool strategy for pickers.
2019-07-16 00:44:01 +01:00
Jeff Young 58ca5b71a9 A more robust fix for 36f1d023f0.
This one also handles when the events get out-of-order due to them
starting out in the Simulation window and not getting dispatched until
the mouse goes over the Schematic window.

Fixes: lp:1835907
* https://bugs.launchpad.net/kicad/+bug/1835907

Fixes: lp:1836544
* https://bugs.launchpad.net/kicad/+bug/1836544
2019-07-15 14:15:24 +01:00
Jeff Young a3c74051c2 Allow edits to self-intersecting polygons.
1) Intermediate states might be self-intersecting, and we shouldn't
be policing our users on what order to do things in
2) The polygon might already be self-intersecting, at which point we're
preventing the user from fixing it.

Also includes better const management for SHAPE_POLY_SET API.

Fixes: lp:1833831
* https://bugs.launchpad.net/kicad/+bug/1833831
2019-07-14 18:18:48 +01:00
Jeff Young fe188489c7 A better hack for the post-ProgressReporter-loss-of-focus issue. 2019-07-14 18:18:48 +01:00
Jeff Young 928d6c5dff Implement preserved-corners to prevent divots when filling adjacent zones.
Fixes: lp:1460787
* https://bugs.launchpad.net/kicad/+bug/1460787
2019-07-14 18:18:48 +01:00
Jeff Young 560fda70a2 Update position before first mouse-move-event.
Fixes: lp:1780426
* https://bugs.launchpad.net/kicad/+bug/1780426
2019-07-14 10:39:38 +01:00
Jeff Young 1dbaa89f95 Fix a bug in tool activation/deactivation and another illegal static_cast.
Fixes: lp:1836419
* https://bugs.launchpad.net/kicad/+bug/1836419
2019-07-14 10:39:38 +01:00
Jeff Young 37af3adffb Add preference for flip axis.
Fixes: lp:1836267
* https://bugs.launchpad.net/kicad/+bug/1836267
2019-07-14 10:36:48 +01:00
Jeff Young 2d17d2b91f Cleanup and commenting. 2019-07-14 10:36:48 +01:00
Seth Hillbrand f2f2b4bcf9 Explode/Combine in terms of visible elements
When generating a complex pad, this allows the user to combine with a
rotated pad and explode rotated pads without needing to rotate elements
to 0 orientation first.

Fixes: lp:1808137
* https://bugs.launchpad.net/kicad/+bug/1808137
2019-07-12 16:55:41 -07:00
Seth Hillbrand c86b4928a7 Fix assert in footprint editor
PCB_EDIT_FRAME does not return for footprint editor.  The
PCB_EDIT_BASE_FRAME is needed for common fns between pcbnew and modedit
2019-07-12 13:34:30 -07:00
Jeff Young ecc5fc9894 Cleanup. 2019-07-10 01:38:02 +01:00
Jeff Young 13d61e4b2b Cleanup. 2019-07-10 01:14:21 +01:00
Jeff Young 483dc24e87 Homogenize selection tools around our HIG.
In particular make addative and exclusive-or selections work the
same way.

Also give Highlight Net a hotkey now that it can't use ctrl-click
anymore.
2019-07-09 21:59:46 +01:00
Jeff Young b0b9c5ab63 Fix copy/paste error. 2019-07-09 16:54:02 +01:00
Jeff Young 36f1d023f0 Make sure Push/PopTool() go in the right order.
Because the pickers are called with an Activate()/Wait() pair, any
usurping tool gets in between the picker handling the cancel (due
to activation) and the picker client doing a PopTool().  The new
tool is therefore pushed before the old tool is popped.

Fixes: lp:1835907
* https://bugs.launchpad.net/kicad/+bug/1835907
2019-07-09 15:03:23 +01:00
Jeff Young 3a8f32c380 Convert ShowEEschema to an ACTION so it can get a hotkey assignment.
Fixes: lp:1686010
* https://bugs.launchpad.net/kicad/+bug/1686010
2019-07-09 00:43:41 +01:00
Jeff Young b8013648d2 Change behaviour of increase/decrease track width & via size when there's a selection.
They now modifiy the selection if it contains only tracks and/or vias,
and modify the current widths/sizes otherwise.

Fixes: lp:1814908
* https://bugs.launchpad.net/kicad/+bug/1814908
2019-07-08 22:18:25 +01:00
Jeff Young 183687c69e Cleanup and a big hack to prevent keyboard focus loss.
Fixes: lp:1810993
* https://bugs.launchpad.net/kicad/+bug/1810993
2019-07-08 20:45:42 +01:00
Jeff Young 772dff7a01 Removed post-page-settings ZoomFitToScreen() calls.
Fixes: lp:1834608
* https://bugs.launchpad.net/kicad/+bug/1834608
2019-07-08 00:06:28 +01:00
Jeff Young a11f3a0b80 Make <esc> unhighlight nets, but only after all tools have been cleared.
Also moves the Highlight Net hotkey from activating the tool to just doing
a one-shot highlight.

Fixes: lp:1835658
* https://bugs.launchpad.net/kicad/+bug/1835658
2019-07-08 00:02:25 +01:00
Jeff Young 986392d88e Update item at start of drag to erase original location.
Fixes: lp:1813038
* https://bugs.launchpad.net/kicad/+bug/1813038
2019-07-07 22:30:18 +01:00
jean-pierre charras a833aeeacb Pcbnew: cosmetic enhancement: add missing icons to 2 menuitems in "Route" menu 2019-07-07 18:12:04 +02:00
Jeff Young 70ca02537d Don't split track when via is placed at one of its ends.
Zero-length tracks are just a pain.

Fixes: lp:1813077
* https://bugs.launchpad.net/kicad/+bug/1813077
2019-07-06 22:54:31 +01:00
Jeff Young a991625f56 Don't refill zone from external change.
We may later add an Automatic Zone Fill option which would restore
this, but for now I'm turning it off to see if it fixes the crash
bug.

Fixes: lp:1834718
* https://bugs.launchpad.net/kicad/+bug/1834718
2019-07-06 22:38:25 +01:00
Jeff Young 174c276883 Expose TrackWidthNext/Prev and ViaSizeNext/Prev in hotkey list.
Fixes: lp:1835616
* https://bugs.launchpad.net/kicad/+bug/1835616
2019-07-06 20:47:39 +01:00
Jeff Young 50f6844e71 Move Zone Display hotkey because Z is already in use (reset grid origin).
Fixes: lp:1835471
* https://bugs.launchpad.net/kicad/+bug/1835471
2019-07-06 00:04:54 +01:00
Jeff Young f20335cefe Apply fix from 5.1 branch.
Fixes: lp:1834111
* https://bugs.launchpad.net/kicad/+bug/1834111
2019-07-05 14:45:15 +01:00
Jeff Young a9c66e15ea Common-ize EE_ACTIONS::refreshPreview and use it after cursor actions.
Fixes: lp:1818667
* https://bugs.launchpad.net/kicad/+bug/1818667
2019-07-05 14:45:15 +01:00
Jeff Young bcd48d4bc2 Use common actions where possible. 2019-07-05 14:45:15 +01:00
jean-pierre charras becd6a6f9d Microwave tools: better tooltips 2019-07-04 11:28:41 +02:00
Jeff Young 1548dcfe8d Fix typo in Pad Enumeration tool.
Fixes: lp:1831950
* https://bugs.launchpad.net/kicad/+bug/1831950
2019-07-03 18:53:13 +01:00
Jeff Young 0eed5175cc Fix crash in Pcbnew drawing tools.
Couple of typos: return !cancelled instead of cancel, and some breaks
on the wrong side of the braces.

Fixes: lp:1835172
* https://bugs.launchpad.net/kicad/+bug/1835172
2019-07-03 11:44:30 +01:00
Jeff Young d03041b565 Cleanup. 2019-07-02 21:36:42 +01:00
Seth Hillbrand 9460f207f5 Fix misc build warnings
This removes unused static function in page layout editor, unused
variable in pcb_painter and restors the gcc unitialized fix for
pcbnew's drawing_tool.
2019-07-02 10:32:49 -07:00
Jeff Young da71a51029 Cleanup. 2019-07-02 00:48:05 +01:00
Jeff Young faa730dfb1 Fix highlight bug.
Fixes: lp:1834960
* https://bugs.launchpad.net/kicad/+bug/1834960
2019-07-01 22:15:25 +01:00
Jeff Young 9effd24f3a Allow move tool to run on top of other tools.
Fixes: lp:1784480
* https://bugs.launchpad.net/kicad/+bug/1784480
2019-07-01 22:15:25 +01:00
Jeff Young ad26ece8d4 Add Global Edit Text and Graphics Properties to Eeschema.
Fixes: lp:1801150
* https://bugs.launchpad.net/kicad/+bug/1801150
2019-07-01 22:15:25 +01:00
Seth Hillbrand 743c650129 Move zone refill to action
This unifies the zone refill across architecture into the tool-based
architecture.  Also provides ZONE_FILLER-based progress managment for
tools.

(cherry picked from commit be9cd98cb1)
2019-07-01 09:27:04 -07:00
Jeff Young a498d7e9c5 Try out a new arc-editing paradigm for LibEdit.
This is based on the notion that in Kicad the start and end-points
are far more important (as they usually connect to other segments)
than the center is.
2019-06-29 16:10:58 +01:00
Jeff Young 981072598b Overhaul cursor code for new tool/action framework.
Includes the addition of an onSetCursor() handler which must be called
from both the GAL canvas AND the GAL backend (at least on OSX) to prevent
cursor flickering between (for instance) pencil and arrow.

Also includes new architecture for point editors which allows them to
coordiate cursors with the editing tools (so we can switch to an arrow
when over a point).
2019-06-27 22:37:11 +01:00
Jeff Young 2f23aa9556 Implement a more robust tool stacking architecture.
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)
2019-06-27 17:01:31 +01:00
Jeff Young e175eb25b8 Fix bug with accidental modification of legacy hotkey name. 2019-06-27 11:29:05 +01:00
Jeff Young fa84babefe Re-implement sch->pcb cross-probing using net highlighting architecture.
Fixes: lp:1827853
* https://bugs.launchpad.net/kicad/+bug/1827853
2019-06-26 21:54:03 +01:00
Jeff Young e785c140b9 Eradicate globals for PCB_GENERAL_SETTINGS.
Fixes: lp:1832896
* https://bugs.launchpad.net/kicad/+bug/1832896
2019-06-26 21:54:03 +01:00
Jeff Young 4eaba20cd3 Real-time highlighting for Pcbnew and ModEdit delete tools. 2019-06-25 21:10:21 +01:00
Jeff Young 7ce38ee6f8 Performance enhancements to zone filling & track DRC.
Significant improvement in fetch time for item clearances.  On large
boards with lots of nets, maybe 10% faster zone fills and about
2x speedup on track-to-track DRC.
2019-06-25 11:34:28 +01:00
Jeff Young f9702aab87 Immediate actions for PlEditor, PcbNew, etc. 2019-06-25 11:34:28 +01:00