Commit Graph

9863 Commits

Author SHA1 Message Date
Yon Uriarte 28e433cc54 Performance UpdateDanglingState
Avoid O(N^2) by spatial sorting, don't run checks if the bounding boxes
don't overlap.
A second copy is ordered by type to help classes that only want to check
a few types having to walk the whole list.

(cherry picked from commit b7b64d959f)
2024-02-23 14:56:17 -05:00
Yon Uriarte 3fd353d837 Performance SCH_EDIT_FRAME::SchematicCleanUp
Avoid O(N^2) comparisonis by spatial presorting. If bounding boxes don't
overlap there's no need to run expensive checks.

(cherry picked from commit f3c2083018)
2024-02-23 14:48:35 -05:00
Roberto Fernandez Bautista f238e09990 Legacy libraries: De-duplicate field names on load
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16902
2024-02-22 21:36:03 +01:00
Roberto Fernandez Bautista b0b523bfdb Revert "Duplicate field names not allowed - throw exception on load"
This reverts commit 9f20816b24.
2024-02-22 21:19:07 +01:00
Wayne Stambaugh 3329affc12 Fix crash when changing sheet file name that contains a highlighted net.
Performing a full connectivity rebuild after changing a sheet file name
ensures that there are no stale connectivity object pointers laying around.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17011
2024-02-17 09:42:13 -05:00
Roberto Fernandez Bautista 9f20816b24 Duplicate field names not allowed - throw exception on load
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16902
2024-02-13 22:37:32 +00:00
Mark Roszko 479b3e6c72 Add some missing newlines to cli output 2024-02-12 02:16:48 +00:00
Marek Roszko 27c573ca42 Fix crash if we exit lib table setup
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16917


(cherry picked from commit 6a37f99e94)
2024-02-12 02:06:33 +00:00
Jon Evans 37ac2ee0a3 Guard actions that change project against running in non-standalone mode
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16942

(cherry picked from commit ec2cd99405)
2024-02-11 09:44:46 -05:00
Jeff Young a3eca13ad3 By-hand cherry-pick of 3c45145401 2024-02-09 10:31:10 +00:00
Seth Hillbrand 5992d7331a Protect schematic undo list actions
The undo/redo lists can have non-SCH_ITEM elements such as worksheet
items.  When re-doing connectivity, we only need the schematic items, so
we pass on these

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16752
2024-02-08 08:31:45 +01:00
Alex Shvartzkop 127874a7b9 Fix bezier curves drawing in schematic/libedit.
(cherry picked from commit ead44d58a0)
2024-02-01 20:42:01 +03:00
Alex ecce28a472 Altium schematic import: fix power ports.
Use different symbol names for different port port styles.
Also fixes curved shapes construction.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16823

(cherry picked from commit 6225ef69b6)
2024-02-01 20:37:22 +03:00
Alex Shvartzkop e93dacb788 Fix HPGL color mode being set.
(cherry picked from commit 57bc443f0b)
2024-02-01 20:02:00 +03:00
Alex Shvartzkop 6c4734c370 Altium schematic: case-insensitive search for subsheet files.
Also fixes open polylines on sheet.
Also prevents adding polylines with less than 2 points.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16829

(cherry picked from commit 7f29ac39d8)
2024-02-01 20:00:58 +03:00
Mark Roszko 585693f0b3 Explicitly add 48, 128, 256 to icon bundles for each app 2024-01-30 20:58:05 +00:00
jean-pierre charras 13fcb571f7 Eeschema, hierarchy navigator: right click on an item must select the corresponding
sheet, not the currently opened sheet.
From master branch
Fixes #16670
https://gitlab.com/kicad/code/kicad/-/issues/16670
2024-01-27 10:06:21 +01:00
Wayne Stambaugh 9738a71922 Fix symbol annotation when pasting nested hierarchical sheets.
(cherry picked from commit 4d6bbc8caa)
2024-01-26 07:32:57 -05:00
Marek Roszko f45e3ca339 Fix assert in SYMBOL_VIEWER_FRAME::onSelectNextSymbol due to bad current selection check
Fixes sentry KICAD-6KE


(cherry picked from commit b8bbbcf410)
2024-01-25 01:18:05 +00:00
Jon Evans c579e11db4 Allow for empty LIB_PART in certain symbol functions
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16731


(cherry picked from commit 5d7eac7677)
2024-01-24 20:54:13 +00:00
Wayne Stambaugh 819f75e17c Remove paste sheet instance path debugging output. 2024-01-23 16:06:07 -05:00
Wayne Stambaugh 0828ee3b10 Fix overly aggressive sheet instance pruning.
(cherry picked from commit b3a36bd783)
2024-01-23 08:03:01 -05:00
Wayne Stambaugh add2215e5a Fix broken pasted sheet page numbering.
This change no longer sorts pasted sheets by page number.  This was done
because pasted sheets may not be numbered.  When sheets are not numbered
they are sorted by UUID path which results in some unexpected results.
Since the pasted sheet code uses recursion, pages will be numbered in the
order they are added.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16580

(cherry picked from commit 4cf22e428c)
2024-01-22 19:26:42 -05:00
Wayne Stambaugh 1d880cdcf6 Incremental schematic connectivity fixes.
(cherry picked from commit 2cfb7a5310)
2024-01-21 12:46:39 -05:00
Wayne Stambaugh 3744cfd987 Fix assertion when pasting schematic sheets.
Pasted sheets do not have assigned SCH_SCREEN objects until after they
are loaded.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16579
2024-01-15 13:56:20 -05:00
Wayne Stambaugh 5e2f979f36 Do not assert when pruning orphaned sheet and/or symbol instances.
Running the schematic editor in the stand alone mode can result in an
empty project name.  Rather than assert when the project name is empty,
just don't run the pruning algorithm.  The pruning will just have to
happen on the next load of the schematic when it has a proper project
name.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16577

(cherry picked from commit 0df8d5c2d6)
2024-01-11 15:52:27 -05:00
Wayne Stambaugh 7db48b81b6 Second attempt at fixing ERC dialog reference update issue.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16519

(cherry picked from commit 4f3fb5c23f)
2024-01-09 13:15:46 -05:00
Wayne Stambaugh f0ce3167c0 Fix sheet path dependent ERC dialog selection issues.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16519

(cherry picked from commit 92c58f2564)
2024-01-08 12:25:19 -05:00
jean-pierre charras ace6439758 LIB_TEXTBOX: fix incorrect line style in plot function for LINE_STYLE::DEFAULT.
LINE_STYLE::DEFAULT is fixed as SOLID in all plot functions, but not for this item.
From master branch
Fixes #16543
https://gitlab.com/kicad/code/kicad/-/issues/16543
2024-01-07 16:19:33 +01:00
Wayne Stambaugh e38b948f0b Do not update tree to selected sheet in schematic hierarchy navigator.
This was causing unwanted tree expansions when descending a sheet hierarchy
in editor.

Also fixed an issue with the tree highlighting when changing sheets in the
schematic editor.

(cherry picked from commit 50cad558cf)
2024-01-06 12:27:28 -05:00
Wayne Stambaugh 193e7f894d Do not expand the entire schematic hierarchy navigator tree by default.
The new behavior is to only expand to the first child of the root sheet
level.  On very complex hierarchies, this makes the navigator far more
useful.

Do not update schematic hierarchy navigator on every edit.  Now only
sheet changes will trigger a rebuild of the tree.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16371
2024-01-05 16:46:01 -05:00
Wayne Stambaugh 0aec789659 Don't show ERCs for every sheet path when using shared schematics.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16434

(cherry picked from commit f07d797ab3)
2024-01-04 14:01:22 -05:00
Alex Shvartzkop 2dc81999ef Default graphical line style in v6 and older was Dashed.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16479

(cherry picked from commit aa6fd88082)
2024-01-01 13:51:03 +05:00
Wayne Stambaugh 98a8781d70 Fix shadowed variable caused by cherry pick. 2023-12-29 11:52:08 -05:00
Jeff Young 76d463dcc8 Honour alternates when getting SCH_PIN description.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16407

(cherry picked from commit af158715e5)
2023-12-29 14:05:44 +00:00
Jeff Young 2daa432261 Ignore reference and value when computing "allChecked".
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16408

(cherry picked from commit 9910c670d2)
2023-12-29 14:04:30 +00:00
Jeff Young d7b2c81db5 Check added fields only if all fields were checked before.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16408

(cherry picked from commit 7e72a53876)
2023-12-29 14:04:15 +00:00
Jeff Young b597a4559f Update SCH_SHAPE::Plot() to handle all fill styles.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16429

(cherry picked from commit 1ca82035ae)
2023-12-29 14:00:53 +00:00
Jon Evans 18e3227c9a Allow no-connects on standalone hierarchical pins/ports
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16397


(cherry picked from commit dad842d3f0)
2023-12-29 13:34:55 +00:00
Wayne Stambaugh 41b847b3c9 Prune orphaned schematic sheet instances.
Pasting from the clipboard when copying from another project can leave
sheet instance information that is not valid for the current project.
This change prunes all sheet instance information that is not relevant
to the current project.  It also prunes invalid paths created by pasting
sheets from different paths in the same project.

(cherry picked from commit 482aff3f0b)
2023-12-29 08:06:53 -05:00
Wayne Stambaugh 567c5bc8db Tag release version 7.0.10. 2023-12-27 16:21:44 -05:00
Jeff Young 09bae9bb14 Fallback to normal undo when wire-drawing not in progress.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16216

(cherry picked from commit 035725cd5d)
2023-12-12 17:15:05 +00:00
Wayne Stambaugh 6d17d7d7a1 Fix crash when duplicating and editing a hierarchical label.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16264
2023-12-11 10:57:19 -05:00
Wayne Stambaugh 98dc21360a Fix crash on save after pasting symbols in schematic editor.
This was caused by pasting zero length instance paths which are not valid.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16300

(cherry picked from commit 484491aaea)
2023-12-11 08:30:38 -05:00
jean-pierre charras 5ae1b271e7 Fix crash: Under some circumstances the command "Export symbols to (new) library"
produces a crash when the library links are updated, and a power symbol is not found
in any loaded library.
Add also an option to export all symbols or all not pwer symbols
From master branch
Fixes #16229
https://gitlab.com/kicad/code/kicad/-/issues/
2023-12-04 18:28:06 +01:00
Wayne Stambaugh 62297e63a2 Fix crash when saving pasted root sheet symbols.
The paste code creates invalid KIID_PATH objects with a zero length.  All
paths must include the root KIID at a minimum.  Code was added to prune
the invalid paths and some defensive code was adding to the formatter to
prevent the crash in case there are other paths where someone generates
a zero length path.

Pruning orphaned instance data does not work when loading schematics prior
to version 7 because the paths did not include the root sheet UUID.  Once
the file is saved to V7 or later, the next load will prune any orphaned or
invalid instance data for the current project.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16245

(cherry picked from commit 764df1d107)
2023-12-03 13:27:34 -05:00
Jeff Young a46501b279 Attempt to fix build. 2023-12-02 19:19:02 +00:00
Jeff Young bc1953dded Collapse drawing tools to a single re-entrancy guard.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16112

(cherry picked from commit c518041f9b)
2023-12-02 16:23:46 +00:00
Jeff Young 789a695737 Remove children from view_group when de-selecting.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16139

(cherry picked from commit 4a25ef164d)
2023-12-02 16:21:50 +00:00
Wayne Stambaugh 9fdda223f5 Fix broken symbol reference designators on paste special.
It appears that in our zeal to prevent file changes when saving shared
schematics, we (I) clobbered saving relative symbol instance data paths
to the clipboard.  This has be restored along with setting the correct
symbol unit for relative clipboard paths.

Fixed a serious issue with KIID_PATH::MakeRelativeTo() where the original
path was not restored when the incremental KIID object test fails.  This
also included a minor optimization using the actual KIID object for
comparison instead of converting it to a string and then comparing the
string.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15981

(cherry picked from commit 6dc25f4775)
2023-12-01 15:30:51 -05:00