Commit Graph

19339 Commits

Author SHA1 Message Date
Jon Evans 79e40cf765 Fix a few issues with Close Projects MR
Store list of previously open projects only in kicad.json
Keep all management of open projects in SETTINGS_MANAGER

Also add kicadSettings() for convenience
2020-08-08 16:00:49 -04:00
Fabien Corona bc357dff8a Add "Close project"
Allow the user to close a project from the project manager.
Distinguish the open project from the file history.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/4964
2020-08-08 18:52:14 +00:00
Jeff Young ae404e6339 Update board markers from DRC changes before dialog is closed.
Fixes https://gitlab.com/kicad/code/kicad/issues/5110
2020-08-08 19:09:22 +01:00
Jeff Young 484643c5ed Fix really bad bug where KIIDs always get reset when reading files.
Mea culpa.

Fixes https://gitlab.com/kicad/code/kicad/issues/5106
2020-08-08 16:25:30 +01:00
Jeff Young 02bf5d27df Fix crash when a DRC rule specifies an empty zone as a keepout. 2020-08-08 16:25:30 +01:00
Jeff Young 98237e96a4 Fix doubly-inited list.
Fixes https://gitlab.com/kicad/code/kicad/issues/4921
2020-08-08 16:25:30 +01:00
Jeff Young 7cd8f710b6 Clean up unused includes. 2020-08-08 16:25:30 +01:00
jean-pierre charras 111ed6c4ac Fix simulator: op results are not printed correctly when numbers are very small
Was due to an overflow in units calculation.

Fixes #5074
https://gitlab.com/kicad/code/kicad/issues/5074
2020-08-08 15:18:50 +02:00
jean-pierre charras 61ada3a602 Remove translation markers from strings that cannot be translated. 2020-08-08 07:47:58 +02:00
PJM 829316fad4 Pcbnew #4904 : Import settings from another board deleted internal layers
When importing settings from a board with more copper layers and applying it
to a board with less copper layers, if the user has ticked the checkbox
"Layer settings", then KiCad will delete the inner copper layers.  Only
when the user clicks OK does it then warn that it found deleted items on inner
layers.  The message is too generic and comes after the layers have already
been deleted.

This Merge Request tries to address this by warning them early.  The changes are:

1 - Added code to check if user is trying to import settings from a
board with less copper layers than the current loaded board.  This
results in KiCad deleting inner copper layers.  Now it presents a
warning dialog that explains the current settings will result in deleted
inner layers, and lets the user stop the import process before making any changes.

2 - Made "Import Settings" dialog disable "Import Settings" button
until at least one import option checkbox is checked.

3 - Made "Select All" button on "Import Settings" dialog toggle
between "Select All" and "Deselect All" on each click.

Items 2&3 were added to improve the overall import settings usability
experience.

Fixes issue https://gitlab.com/kicad/code/kicad/-/issues/4904
2020-08-08 00:51:23 +00:00
Seth Hillbrand f615b026d9 pcbnew: Account for zone expansion in conn
Connecting zone-to-zone, we need to allow for the stroke-width in
old-style polygons.

Also, speed up the calculation by skipping zone points that do not fall
inside the matching BBox

Fixes https://gitlab.com/kicad/code/kicad/issues/5043
2020-08-07 15:59:39 -07:00
Jon Evans dcc484e114 CHANGED: Library editors are now usable with no project loaded
Fixes https://gitlab.com/kicad/code/kicad/-/issues/3688
2020-08-07 18:02:34 -04:00
Jeff Young db501c2002 Fix issue with doing DRC on a multi-layer zone.
Testing for an intersection of layers between the zone and the
item (track in this case) isn't enough: we need to test for the
presence of the item on each layer of the zone.

Fixes https://gitlab.com/kicad/code/kicad/issues/5102
2020-08-07 22:40:18 +01:00
Jeff Young 1671c3356d Fix typo where "continue" got put on wrong side of closing brace.
Fixes https://gitlab.com/kicad/code/kicad/issues/5100
2020-08-07 22:40:18 +01:00
Jon Evans 413c2cc2c6 Don't use the schematic grid for page border in pcbnew
Fixes https://gitlab.com/kicad/code/kicad/-/issues/5105
2020-08-07 17:12:21 -04:00
Jeff Young e5b50d90a7 Update DRC rules to new layer and disallow grammars.
Also adds support for hooking rules up to named zones.

Fixes https://gitlab.com/kicad/code/kicad/issues/2041
2020-08-07 21:49:36 +01:00
Seth Hillbrand 406de56964 pcbnew: Prevent use of non-connected item in ratsnest
We need to be careful in the connectivity system to always use
dyn_cast/dynamic_cast and check the return when dealing with board
items.  Getting non-connected items will result in null nets when
propagated.

Fixes https://gitlab.com/kicad/code/kicad/issues/5082
2020-08-07 13:38:51 -07:00
jean-pierre charras f46c1ccb32 Fix another incorrect (and useless) conversion of a wxString to and from std::string.
This useless conversion breaks non ASCII8 strings.
2020-08-07 19:44:34 +02:00
Jeff Young e14bbc7d83 Fix auto-added include. 2020-08-07 17:10:12 +01:00
Jeff Young 00e77d1ba4 Implement pad & via aprons for hatched zones.
Fixes https://gitlab.com/kicad/code/kicad/issues/2519
2020-08-07 15:15:43 +01:00
mntmn bf60482b5c OpenGL GAL: support fallback without overlay buffer
On platforms with limited framebuffer attachments, like GC7000L
driven by the open source etnaviv driver, we can still use
GPU acceleration by drawing directly to the main buffer.

EDA_DRAW_PANEL_GAL::onPaint checks if an overlay target is
available in the GAL, and if not, redraws the whole view if the
overlay target should be dirty.

Clearing of the overlay target is a no-op if there is no overlay
buffer.

Signed-off-by: Lukas F. Hartmann <lukas@mntre.com>
2020-08-07 13:27:47 +00:00
jean-pierre charras 8005de27c0 Fix a compil warning and 2 Coverity warnings. 2020-08-07 13:13:25 +02:00
jean-pierre charras 9b6ade6b1c Fix a link issue (symbol not found). 2020-08-07 08:02:45 +02:00
Ben Ellis c3e9007e20 Added a check that canvas exists before trying to dereference it 2020-08-06 20:23:57 -04:00
Fabien Corona 8de6aa161f pcb_calculator : do not overwrite input parameters
Split the computing / displaying code into different functions
Add coloured warnings when a value is not finite / illogical .

Fixes https://gitlab.com/kicad/code/kicad/-/issues/1849
2020-08-07 00:09:33 +00:00
Jeff Young 0ff5dcee69 Kick the lexer generator one more time... 2020-08-06 23:32:49 +01:00
Jeff Young f244f3b24c Last issue wasn't gcc/CLang after all, but the lexer not getting built. 2020-08-06 23:16:58 +01:00
Jon Evans 1a3b7828f8 Fix layer exclusions and worksheet in board color theme editor 2020-08-06 17:44:16 -04:00
Jeff Young af6bd76dce Fix for gcc. 2020-08-06 22:42:26 +01:00
Jeff Young ea1be41ff0 Only clean up tracks completely inside pads.
Fixes https://gitlab.com/kicad/code/kicad/issues/5093
2020-08-06 21:53:28 +01:00
Jeff Young 76bd344730 Preview for PCBNew colour settings editor. 2020-08-06 19:38:06 +01:00
Jeff Young f27661fa39 Be more flexible with user input; more multibyte safety. 2020-08-06 19:38:06 +01:00
Jeff Young dd7d8218f0 Handle multiple-selections for kicad manager context menu.
Fixes https://gitlab.com/kicad/code/kicad/issues/5080
2020-08-06 19:38:06 +01:00
jean-pierre charras 5a33772f41 Pcbnew: avoid crash when saving a board having "orphan" nets.
Sometimes tracks or zones can have "orphan" nets no longer existing
in schematic after updating the board from the schematic (no pad belonging this net).

The fix does not save these broken nets having no info (no netname, no valid netcode)

Fixes #5087
https://gitlab.com/kicad/code/kicad/issues/5087
2020-08-06 16:11:55 +02:00
SUENAGA Hiroki 27d319b2df correct library path in fixup_bandle().
* Fix build failure on MacOS X 10.15.6.
2020-08-06 02:57:46 +00:00
Seth Hillbrand c57c168753 PNS: Remove items from all layers
subIndices control which layers the items are inserted onto and removed
from.  The iterator to remove items needs to be inclusive of the
first/last layers

Fixes https://gitlab.com/kicad/code/kicad/issues/5090

Fixes https://gitlab.com/kicad/code/kicad/issues/5075

Fixes https://gitlab.com/kicad/code/kicad/issues/5034
2020-08-05 19:39:55 -07:00
Jeff Young 4b51184678 Don't try and select if we don't have a location.
Fixes https://gitlab.com/kicad/code/kicad/issues/5088
2020-08-06 01:22:59 +01:00
Jeff Young 6a4f611e61 Special handling for connecting vias in hatched zones.
Fixes https://gitlab.com/kicad/code/kicad/issues/2568
2020-08-06 00:03:00 +01:00
Jeff Young c3f8f57cd5 Remove folder menu items from sub-projects in Kicad manager frame.
Fixes https://gitlab.com/kicad/code/kicad/issues/5080
2020-08-05 23:06:42 +01:00
Jeff Young 3522fd0535 Refresh for colour changes.
Fixes https://gitlab.com/kicad/code/kicad/issues/4983
2020-08-05 22:56:07 +01:00
Jeff Young dd0f33bcbb Get rid of extraneous char conversion. 2020-08-05 22:23:53 +01:00
Seth Hillbrand 4a79d1be56 Track cleaner should not remove vias from pads
Vias are stored in the board tracks list, so we need to skip them when
testing if the start/end points are both in pads

Fixes https://gitlab.com/kicad/code/kicad/issues/5086
2020-08-05 13:24:14 -07:00
Seth Hillbrand 8a0be64ad4 Ensure dangling test takes track width into account
When running a hit test to check if the anchors are connected, we should
loosen the check for tracks to account for the width.  Otherwise
connected anchors can be connected in the system but test positive for
IsDangling()

Fixes https://gitlab.com/kicad/code/kicad/issues/5027
2020-08-05 13:17:29 -07:00
Jeff Young b26ced820c Make sure plugins table has columns wide enough for headers.
Don't expect wxWidgets to return appropriate values for this.  At
least not in the version we're using.

Fixes https://gitlab.com/kicad/code/kicad/issues/1916
2020-08-05 19:37:52 +01:00
Jeff Young 73832a9708 Work around an event processing failure.
Fixes https://gitlab.com/kicad/code/kicad/issues/4273
2020-08-05 19:36:58 +01:00
Jeff Young 04e57a31eb Reset KIIDs when appending a board.
Fixes https://gitlab.com/kicad/code/kicad/issues/5081
2020-08-05 19:02:19 +01:00
jean-pierre charras ea71d9db81 Fix incorrect (and useless) conversion of a wxString to and from std::string.
This useless conversion breaks non ASCII8 strings.
2020-08-05 18:34:49 +02:00
Jeff Young c30739dff3 Implement a more aggressive zone-fill-cancel.
We now unfill all zones so that the user can clearly see that
things are not in a "finished" state.

Fixes https://gitlab.com/kicad/code/kicad/issues/5035
2020-08-05 16:51:58 +01:00
Jeff Young e2ec9d9f00 A more fail-safe way to disallow editing while routing.
Fixes https://gitlab.com/kicad/code/kicad/issues/4413

Fixes https://gitlab.com/kicad/code/kicad/issues/5067
2020-08-05 16:51:58 +01:00
Jeff Young a6cdb6440a Give the user a bit of help with board thickness.
Fixes https://gitlab.com/kicad/code/kicad/issues/3807
2020-08-05 16:51:58 +01:00