Commit Graph

138 Commits

Author SHA1 Message Date
Jeff Young dc0cf3b802 Clean up a confusing API.
AllowDRCViolations is kept in any mode as a *setting*, but only
controls router behaviour when the mode is mark obstacles.

Fixes https://gitlab.com/kicad/code/kicad/issues/7795
2021-04-10 11:08:02 +01:00
Jeff Young 8cb6f15687 Warn when diff pair router can't start due to too-small-gap.
Fixes https://gitlab.com/kicad/code/kicad/issues/7795
2021-03-30 19:49:23 +01:00
Wayne Stambaugh 79a9d69ff5 Coverity fixes for issues 314755, 316287, 324536, 324539, and 324539. 2021-03-02 08:10:37 -05:00
Jeff Young b36e1c741d Fix insidious bug which resets layer of SOLID when marking collision.
It's supposed to be setting the layer of the collsion display object,
not the host object, but there's a typo.

Fixes https://gitlab.com/kicad/code/kicad/issues/7712
2021-02-25 23:39:48 +00:00
Tomasz Wlostowski 87ea540953 Fix whitespace errors 2021-02-25 17:18:23 +01:00
Tomasz Wlostowski 12dfb541fc router: expose current view area to the router algorithms so that the optimizer could know not to mess with traces/vias not currently visible to the user (wip) 2021-02-25 17:18:23 +01:00
Tomasz Wlostowski af95235f47 router: report debug log events from DRAGGER 2021-02-25 17:18:23 +01:00
Seth Hillbrand 792904557e Remember Parent data when routing
Keeps parent information such as UUID and pad removal options for
elements that are just updated in routing rather than created fresh or
fully destroyed.

Fixes https://gitlab.com/kicad/code/kicad/issues/7460
2021-02-07 17:08:43 -08:00
Jeff Young 02cd8c99cd Better error messages when routing can't be started.
Fixes https://gitlab.com/kicad/code/kicad/issues/6541
2021-01-05 18:47:58 +00:00
Jeff Young 2ea6bc5529 Formatting. 2021-01-04 19:19:55 +00:00
Jeff Young 648c42f643 Show collisions preventing routing from starting.
Also introduces a callback to the infobar so that the view can be
cleaned up when the timer expires.

Fixes https://gitlab.com/kicad/code/kicad/issues/6930
2021-01-04 19:19:55 +00:00
Jeff Young 71215bcab3 Make sure TH pads get collision layer highlighted.
Also cleans it up to centralise all the decision-making.

Fixes https://gitlab.com/kicad/code/kicad/issues/6925
2021-01-03 21:16:09 +00:00
Jeff Young 6b6694f55f Fix typo.
Fixes https://gitlab.com/kicad/code/kicad/issues/6913
2021-01-02 15:04:30 +00:00
Jeff Young fc1b0ec11f Improve feedback when routing in highlight collisions mode.
In particular, when Allow DRC violations is NOT turned on and we
bump in to an obstacle.
2021-01-01 17:25:37 +00:00
Jeff Young ecc0e861d3 Implement hole clearance and hole-to-hole clearance in router.
Fixes https://gitlab.com/kicad/code/kicad/issues/6882
2021-01-01 00:31:36 +00:00
Jon Evans 79502a0d88 PNS: A new approach to arc placement
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6334
2020-12-30 18:23:24 -05:00
Jeff Young d304f12284 Formatting. 2020-12-11 12:48:04 +00:00
Jeff Young 00edc85f4f Allow layer switching when routing from pad.
Additionally, don't process layer events from both main loop and
transitions -- it makes for a mess.

Fixes https://gitlab.com/kicad/code/kicad/issues/4832
2020-12-02 21:17:56 +00:00
Jeff Young d06d35a74d Formatting. 2020-12-02 20:05:47 +00:00
Jeff Young 64876a2761 PNS_DRAGGER should report its layers.
Also, don't use ViewGetLayers() for visibility checking.  For some
things (like vias) it deals with synthetic layers, not board layers.

Fixes https://gitlab.com/kicad/code/kicad/issues/6328
2020-11-08 17:19:37 +00:00
Jeff Young 76ac8b5acf Preflight routing so we can give a warning if it's not going to work.
Fixes https://gitlab.com/kicad/code/kicad/issues/4975
2020-11-02 00:10:21 +00:00
Jeff Young 8bfb255c96 Put a warning when routing can't start due to DRC violation.
Fixes https://gitlab.com/kicad/code/kicad/issues/4975
2020-11-01 23:46:42 +00:00
Jeff Young 409cd9d4ee Formatting. 2020-11-01 20:25:36 +00:00
Jeff Young f6c92ab1ea DRAGGER needs to report it's nets.
Otherwise things like snapping don't work.

Fixes https://gitlab.com/kicad/code/kicad/issues/4147
2020-11-01 19:57:42 +00:00
Jeff Young a95e2184da A more generic error message when route start pt violates DRC.
Fixes https://gitlab.com/kicad/code/kicad/issues/1812
2020-11-01 18:23:07 +00:00
Jeff Young c17ceb5875 Make sure proxy items at least get the right net for clearance lines.
Fixes https://gitlab.com/kicad/code/kicad/issues/5980
2020-10-30 23:37:35 +00:00
Tomasz Wlostowski 5e4fb46aef MINOPTMAX: added OptThenMin() method as syntax sugar 2020-10-09 00:01:26 +02:00
Jeff Young d23d5510e7 Restore a side-effect that the router appears to depend on. 2020-10-06 00:07:34 +01:00
Jeff Young 18a3c4c1db Fix some fairly catastrophic bugs in shape collision optimization.
I did a little too much copy & paste last time around....
2020-10-05 22:32:07 +01:00
Tomasz Wlostowski 379aa8f3b5 router: clearer distinction between LOGGER and DEBUG_DECORATOR classes.
The first one keeps a log of events (start routing, mouse motion, etc).
The second allows for adding temporary debug drawings and messages which are stored synchronously with the events in LOGGER.

The event stream together with the PCB design (now with UUIDs) can be used to deterministically replay routing bugs as the user sees them.
2020-07-22 18:05:54 +02:00
Tomasz Wlostowski 44905e1b0a router: initial support for dragging components with traces attached 2020-02-28 23:17:15 +01:00
Tomasz Wlostowski 4525a17076 router: backspace key to undo last fixed segment(s) 2020-02-27 22:02:56 +01:00
Tomasz Wlostowski dbe90e163e router: use one global logger object 2020-02-27 22:02:56 +01:00
Seth Hillbrand 8c19b4b6ae pcbnew: Adding arcs to PNS
This is allows ARCs in tracks to be synchronized with
the PNS router.  Note this does not yet include the UI components
to route curved traces
2020-02-21 16:11:41 -08:00
Jon Evans e59a3d981e Implement a new settings framework across all of KiCad
CHANGED: Settings are now stored in versioned sub-directories
ADDED: First-run dialog for migrating settings from a previous version
CHANGED: Settings are now stored as JSON files instead of wxConfig-style INI files
CHANGED: Color settings are now all stored in a separate settings file
CHANGED: The symbol editor and footprint editor now have their own settings files
CHANGED: Color settings are no longer exposed through BOARD object
CHANGED: Page layout editor now uses Eeschema's color scheme

Settings are now managed through a central SETTINGS_MANAGER held by PGM_BASE.
Existing settings will be migrated from the wxConfig format on first run of each application.
Per-application settings are now stored in one class for each application.
2020-02-19 23:44:56 -05:00
Seth Hillbrand a2edf9c442 Unified update to C++14 std::make_unique
This update replaces the existing uses of unique pointer creation with
the C++14 std::make_unique call that provides proper memory release in
event of an exception.
2019-12-05 10:43:55 -08:00
Tomasz Włostowski 45e4387ed1 router: remove unnecessary include 2019-08-07 23:46:32 +02:00
Seth Hillbrand cf63ae7ae2 pcbnew: Show clearance when editing tracks
When requested by display options, we should show the track clearance
when dragging tracks.

Fixes: lp:1818343
* https://bugs.launchpad.net/kicad/+bug/1818343
2019-04-07 21:25:28 -07:00
Seth Hillbrand f47089a804 pcbnew: Enforce router settings
When the user selects "Ignore DRC" in the Highlight collisions mode,
they should be allowed to start drc violating tracks as well as end
them.
2019-02-23 08:19:50 -08:00
Seth Hillbrand 9523b26472 pcbnew: Fix dragging snap to items
Snapping while dragging depends on the current net being assigned during
dragging.  This initializes the placer to hold the current net while
performing inline dragging.  The placer is reset along with the dragger
in StopRouting().  This fixes the difference in snap between drag and
create new route.

( cherry-picked from 219695953 )
2018-09-15 20:22:34 -07:00
Tomasz Wlostowski f6f726acab router: allow placing tracks/diff pairs without continuing routing by Shift+L-Click
Fixes: lp:1777688
* https://bugs.launchpad.net/kicad/+bug/1777688
2018-06-19 19:30:03 +02:00
Tomasz Włostowski 271363f822 router: support for board outline 2018-02-06 09:43:56 +01:00
Tomasz Włostowski 2faf1a1ed3 Initial support for keepout zones in the P&S router. 2018-02-06 09:43:56 +01:00
Tomasz Włostowski 44d4559f84 pcbnew: avoid segfault reported on certain OSX builds
Fixes: lp:1732274
* https://bugs.launchpad.net/kicad/+bug/1732274
2018-01-02 00:49:59 +01:00
Tomasz Włostowski 2d9ab80b4e Few improvements to the GAL router:
- missing 'break track' functionality
- 'drag 45 degree' and 'drag free angle' context menu shorcuts, both in the router tool and in the default context menu
- bugfix: length tuner tool can now be used again

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

Fixes: lp:1708402
* https://bugs.launchpad.net/kicad/+bug/1708402
2017-08-07 14:28:46 +02:00
Tomasz Włostowski 3cba1007eb Removed legacy connectivity/ratsnest algorithm, replaced with the new one. No legacy autorouting for the moment 2017-06-23 11:12:37 +02:00
Maciej Suminski 39317eac83 Display clearance for routed tracks (GAL) 2017-01-27 19:11:12 +01:00
Maciej Suminski fc122834c2 Code formatting 2017-01-27 19:08:32 +01:00
jean-pierre charras dec2d6e8cc Fix a few Coverity warnings. A bit of clean code in export_vrml.cpp. 2016-12-30 12:40:05 +01:00
Tomasz Włostowski 3257f1a863 pns: fixed inline drag grid snapping & undo-related assertion failure
Fixes: lp:1628697
* https://bugs.launchpad.net/kicad/+bug/1628697
2016-09-30 09:29:49 +02:00