Commit Graph

98 Commits

Author SHA1 Message Date
Jeff Young fd6dffe170 Only save changed severities etc. if the modify bit is set.
(Also means we need to set said bit when changing them.)

Fixes https://gitlab.com/kicad/code/kicad/issues/4164
2020-04-24 23:09:10 +01:00
Jeff Young 32db9eb0f1 Add some distances to a few DRC errors. 2020-04-24 22:17:45 +01:00
Jeff Young 1535c83b88 Lay some groundwork for adding distances to DRC errors.
modified:   eeschema/lib_rectangle.cpp
2020-04-24 14:46:22 +01:00
Jeff Young 840cab4eec Allow user to show layer if DRC object is hidden.
Fixes https://gitlab.com/kicad/code/kicad/issues/3686
2020-04-07 17:29:58 +01:00
Jeff Young cee973dc04 Move ERC error reporting over to the new framework.
Fixes https://gitlab.com/kicad/code/kicad/issues/1989
2020-03-16 11:06:15 +00:00
Jeff Young 2359d19cf4 Add menu item to DRC dialog to go to Board Setup / Violation Severities. 2020-03-04 21:52:30 +00:00
Jeff Young d20f36511f Fix issue with severities not get initialised in DRC_TREE_MODELs. 2020-03-04 21:52:30 +00:00
Jeff Young 0894674869 Save severities settings in the DRC dialog.
Fixes https://gitlab.com/kicad/code/kicad/issues/3978
2020-03-04 21:52:30 +00:00
jean-pierre charras b7cd0c54c2 Fix compil issues, especially on Windows:
Replace SEVERITY_ERROR by RPT_SEVERITY_ERROR to avoid collision with a system definition.
Replace other SEVERITY_XXX by RPT_SEVERITY_XX for consistency.
Fix compil warnings and some other compil issues.
2020-03-04 10:48:18 +01:00
Jeff Young 85c2e0d23a Add user-defined severities, exclusions and colors to DRC markers.
Exclusions are currently persisted in the project file.

Fixes https://gitlab.com/kicad/code/kicad/issues/1989
2020-03-04 00:39:28 +00:00
Ian McInerney d5ceb8252e Clean up some warnings 2020-02-28 00:06:52 +00:00
Jeff Young 3860ab9f0c Fix issue returning pointers to items inside std::vector.
(When the vector is re-allocated your pointers become bogus.)
2020-02-27 22:00:51 +00:00
Jeff Young 82ae9db262 Another variation on the wxDataViewCtrl issue.... 2020-02-26 17:56:47 +00:00
Jeff Young cdad62022b Bug fix for double-click in DRC dialog.
Also better clean-up of highlighting in board editor window.
2020-02-25 12:18:24 +00:00
Jeff Young a4837f7d32 Move DRC dialogs to wxDataView.
This allows for hierarchy and better selection handling.
2020-02-24 23:19:17 +00:00
Jeff Young c5077aeb97 Move weak-reference stuff to UUIDs. 2020-02-24 23:19:17 +00: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
brian piccioni 8341398082 Save footprint errors in the DRC log
Fixes https://gitlab.com/kicad/code/kicad/issues/3754
2020-01-18 01:40:43 +00:00
Mark Roszko 11ff16be4e Switch to scoped enums 2019-12-20 14:11:39 +00:00
jean-pierre charras 5cd7f3fdee DIALOG_DRC_CONTROL: fix a crash on wxWidgets 3.1.3, Windows,
Happens when right clicking on an item in displayed lists.
The crash was due to a bug in wxWidgets, and the fix is only a workaround

Also remove duplicate code.
2019-12-02 11:27:40 +01:00
jean-pierre charras 16f4958430 Pcbnew: avoid crash when closing pcbnew if the DRC dialog is open.
Cvpcb: change from commit 9ceca583:
the root class close event that save settings is now seeing the close event.
2019-09-19 09:16:12 +02:00
Jeff Young a25368cc6b Improve spelling.
The groundwork here is thanks to kunda1.

Fixes: lp:1831510
* https://bugs.launchpad.net/kicad/+bug/1831510
2019-08-20 19:14:05 +01:00
Jeff Young da71a51029 Cleanup. 2019-07-02 00:48:05 +01:00
Jeff Young 8f84c3ec4f Grid rid of GetCanvas/GetGalCanvas distinction now that there's only gal. 2019-06-13 19:58:37 +01:00
Jeff Young 4e11dcfa31 Better error reporting for board edge collisions. 2019-06-04 13:56:54 +01:00
Jeff Young fbfbb64387 A bit of cleanup of stale DRC code. 2019-06-04 13:56:54 +01:00
Jeff Young d7574db805 Fix regression in dialog-avoidance when focusing on a location. 2019-06-03 21:08:30 +01:00
Jeff Young 7553cc2651 Clean up some dangling legacy odds and ends. 2019-06-01 01:17:46 +01:00
Jeff Young d6e9bdf07b Convert remaining legacy drawing code to print code. 2019-05-31 21:54:22 +01:00
Jeff Young 03bab2f4a9 Remove some more legacy drawing stuff. 2019-05-31 21:54:22 +01:00
Jeff Young 1e9da7f57b Remove CurItem() architecture and legacy routers and drawing code. 2019-05-29 00:26:30 +01:00
Seth Hillbrand b3b5ffe799 pcbnew: fixup small type issue 2019-05-15 09:53:42 -07:00
Wayne Stambaugh a32bb4e9a5 Pcbnew: fix crash when deleting DRC errors from DRC dialog.
Fixes lp:1828726

https://bugs.launchpad.net/kicad/+bug/1828726
2019-05-14 18:07:34 -04:00
Jon Evans dec5d80180 Veto mouse warping from DRC dialog
Fixes: lp:1824630
* https://bugs.launchpad.net/kicad/+bug/1824630
2019-04-13 11:23:57 -04:00
Jon Evans 3d9b5daf9c Improve selection behavior of DRC markers in DRC dialog list
Fixes: lp:1813373
* https://bugs.launchpad.net/kicad/+bug/1813373
2019-04-12 11:01:38 -04:00
Jeff Young d361e68d0e Condense the DRC dialog a bit.
The messages title doesn't really provide useful info anyway.
2019-04-08 13:26:26 +01:00
Jeff Young a1c162e59f Reimplement footprint checking on top of DRC architecture.
This allows Import Netlist and Update PCB from Schematic to
share the same checking code, and expose it through the DRC
dialog.

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

Fixes: lp:1809293
* https://bugs.launchpad.net/kicad/+bug/1809293
2019-04-08 13:26:17 +01:00
jean-pierre charras 7c04b3dbeb Drc dialog: make track to copper zones test optional, because it can be really very time consuming 2019-03-19 18:18:20 +01:00
Jeff Young 4050991d28 Move ERC marker focusing to GAL architecture.
Fixes: lp:1802537
* https://bugs.launchpad.net/kicad/+bug/1802537
2018-11-16 10:38:44 +00:00
Jeff Young aab97c8385 Consolidate design rules UI.
Implement new Board Setup paged dialog which includes:
  Layers Setup
  Design Rules
  Solder Mask & Paste
  Text & Drawings

Moves line width and text properties to a layer-class-based
system.  Renames unlocked to upright (which also reverses the
logic).

New Edit Text and Graphic Properties dialog which replaces
Edit Footprint Text and adds layer-class-based editing and the
italic, upright and visibility properties.

Adds Import Settings functionality which allows settings to
be imported from another project at page granularity.

Also UNIT_BINDERizes the dialog and adds editing of pcb text.

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

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

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

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

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

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

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

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

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

(cherry picked from commit 3944a5e)
2018-07-17 15:12:34 +01:00
Jeff Young ef3e045a9b Eradicate g_UserUnit from ERC/DRC.
(cherry picked from commit 98b8cd4)
2018-07-17 15:12:16 +01:00
Jeff Young bbc25cd694 Add hole-to-hole clearance testing to DRC.
Also move courtyard testing flags to BoardSettings API.  Both are
still stored in the config until we decide where they go in order
to prevent prematurely disturbing the board file format.

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

(cherry picked from commit 5399f60)
2018-07-17 15:11:11 +01:00
Jeff Young 74acb76e7f Switch UNIT_BINDER and DIALOG_SHIM to local units.
The general idea is to support user-units inheritance.  The
UNIT_BINDER allows wrapped controls to inherit units from their
parent dialog, while KEYWAY_HOLDER and DIALOG_SHIM allow child
KEYWAY_HOLDERs or DIALOG_SHIMs to inherit units from their
parent.

The GetUserUnits() method signature has to move to KEYWAY_HOLDER
rather than KEYWAY_PLAYER (where it makes more sense) as it’s the
only common ancestor of KEYWAY_PLAYER and DIALOG_SHIM.

As long as we'll be using the UNIT_BINDER more widely, it also
makes sense to move evaluation and validation into it.

This commit also provides eeschema’s DIALOG_LABEL_EDITOR and
pcbnew’s DIALOG_TRACK_VIA_PROPERTIES and DIALOG_SET_GRID as
models of how to use the new user-units inheritance, eval, and
validation.

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

(cherry picked from commit c8bc53e)
2018-07-17 15:09:53 +01:00
Jeff Young a1ef5401f4 More platform-standard presentation of DRC dialog.
Also makes better use of space to significantly increase number
of markers shown.

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

(cherry picked from commit a1d8097)
2018-07-17 15:09:46 +01:00
Jeff Young 3e190cee4b Implement selection brightening for DRC.
The old item pointers (which aren't safe to keep around) were
removed in favour of opaque references (void*) which are then
compared against existing items when needed.

Also improves brightening by brightening the whole footprint
(ie: its pads, drawings, reference and value) rather than just
its target cross.

(cherry picked from commit 30e90b0)
2018-07-17 15:09:40 +01:00
Jeff Young e9d877914d Dialog consistency and beautification.
Small icons for dialog browse, refresh, and row operations.
Icons in B&W so they don't over-emphasize with respect to other
controls in the dialog.

Layout cleanup for consistency.  Removal of the blank space to
left of the fields list in the Global Fields Editor, and addition
of column-sizing-to-list-width.

More even spacing for buttons in html report panel.

Honor platform conventions for action button order and layout.

Move netlist importer to update-pcb-from-schematic algorithm
(display messages and then update instead of "dry run" checkbox)

(cherry picked from commit b21e19d)
2018-07-17 15:09:01 +01:00
Maciej Suminski 80fa480388 Disable the DRC dialog while the checks are running
Closing the DRC dialog while zones are refilled leads to a crash.
Disabling the dialog prevents the crash.
2018-06-27 19:05:06 +02:00
Maciej Suminski 7c49bcd3a6 Clear selection before deleting DRC markers
Pcbnew crashes when a selected DRC marker is deleted. This a possible
fix to lp:#1773863.
2018-05-31 09:32:43 +02:00
Jon Evans c78171d01f DRC: Add an optional mode to report all track errors
Fixes: lp:1754442
* https://bugs.launchpad.net/kicad/+bug/1754442
2018-03-20 19:54:06 -04:00
Jon Evans 3103e3dc4c DRC: Center zoom on marker location, not DRC item start location
For some DRC checks, the location of the marker is not the location
of the first item in the resulting DRC_ITEM, so centering the screen
on PointA of the DRC_ITEM can be confusing.
2018-03-19 22:25:55 -04:00