Commit Graph

48 Commits

Author SHA1 Message Date
jean-pierre charras e218471d24 DIALOG_CHANGE_SYMBOLS: fix a bug introduced by my commit 686b32db
the filtering for mandatory fields was disabled.
2021-11-13 13:47:09 +01:00
jean-pierre charras 686b32dbd3 fix issue in DIALOG_CHANGE_SYMBOLS, in non English locale.
Mandatory field names where compared in list, using translated and not translated names.
Fixes #9596
https://gitlab.com/kicad/code/kicad/issues/9596
2021-11-11 10:56:09 +01:00
jean-pierre charras c3a4c40d4c DIALOG_CHANGE_SYMBOLS: add missing skip event in wxFocusEvents.
Fixes #9467
https://gitlab.com/kicad/code/kicad/issues/9467
2021-10-27 17:17:44 +02:00
Jeff Young 6aaf4413b3 Fix kicad_string.h / string.cpp mismatch.
They don't define a KiCad string class, so the header file name was
somewhat misleading. But the fact that they didn't match definitely
made coding more difficult.
2021-07-29 16:03:25 +01:00
Jeff Young 726f4d8016 Fix up some more cases of missing escaping for symbol names.
Fixes https://gitlab.com/kicad/code/kicad/issues/8694
2021-07-28 16:40:38 +01:00
Jeff Young b1b4caee6a Escape "naughty" characters in symbol names.
It's tempting to say that we don't need to exclude filename chars
from symbols, but we might regret that decision down the road.  Better
to just escape them.

Fixes https://gitlab.com/kicad/code/kicad/issues/8694
2021-06-30 13:12:57 +01:00
Jeff Young e2a2c3282a Update fields list when source or target lib IDs change.
Fixes https://gitlab.com/kicad/code/kicad/issues/8263
2021-06-28 20:38:19 +01:00
Jeff Young e540752640 Allow all selected footprints/symbols to be changed.
Fixes https://gitlab.com/kicad/code/kicad/issues/7389
2021-06-17 23:34:56 +01:00
Jeff Young 389287e942 A bit more Part -> Symbol. 2021-06-17 22:24:41 +01:00
Wayne Stambaugh 71c183d7bb Rename LIB_PART to LIB_SYMBOL. 2021-06-14 07:11:17 -04:00
Wayne Stambaugh fbc135e69f Rename SCH_COMPONENT to SCH_SYMBOL. 2021-06-10 10:34:49 -04:00
Jeff Young 2e3860de6f Naming conventions. 2021-05-05 22:58:40 +01:00
Jeff Young f30c67a478 Symbols need to be unannotated when updating their references.
Fixes https://gitlab.com/kicad/code/kicad/issues/8223
2021-04-18 16:26:36 +01:00
Jon Evans 18037e2f65 Rework bitmap system to load from archived PNGs
Bitmaps are now identified by an enum class instead of by pointers.
Bitmap loading and caching is now handled by a class in common, and
we no longer compile most bitmaps into the binary, so there is no
longer a bitmaps static library.

Instead, bitmaps are archived to a .tar.gz file which is installed
in ${KICAD_DATA}/resources/images.tar.gz

The source PNGs are checked in to Git as the original CPP files were,
so that people can build without the required dependencies to convert
SVGs to PNGs.

Initial support is also added for dark theme icons, although this
is not yet exposed in the GUI.

Stubs are present for multi-resolution image resources, but this is
not fully-baked yet and could use some refinement.
2021-03-11 08:37:35 -05:00
Wayne Stambaugh 7a00e01b3e Eeschema: fix false positive library symbol changed ERC errors.
This fix required sorting all of the LIB_PART draw items to ensure
accurate comparison between the symbols stored in the schematic and the
original library symbols.  This has a noticeable impact on symbol library
load performance.  It may also cause significant changes the next time
the library is saved due to changes in the draw item sorting.  Hashing
may be a better solution here but this addressed the immediate problem.

A skeleton method SCH_SCREEN::SwapSymbolLinks() was added because there
is most likely an issue with orphaned symbols in the schematic library
symbol cache during undo/redo operations.  More testing is required to
verify this.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/7263
2021-03-04 17:59:24 -05:00
Jeff Young 8a33542bcd SCH_COMPONENT::GetField() expects a vector index, not a field id.
Check this at compile time.  Callers wanting to use an index now must
use SCH_COMPONENT::GetFields()[i] instead.

Fixes https://gitlab.com/kicad/code/kicad/issues/7757
2021-02-28 15:10:37 +00:00
Jeff Young b8c95345d0 Make sure reporters have a better default path than /bin. 2021-02-25 15:05:26 +00:00
Wayne Stambaugh 1786ae8773 Eeschema: use symbol nomenclature for object file naming. 2021-02-24 08:48:02 -05:00
Jeff Young 781d293b60 Add option for text updating to Update Symbol.
Fixes https://gitlab.com/kicad/code/kicad/issues/6420
2021-02-22 00:36:40 +00:00
Jeff Young ec20121114 Make sure schematic symbol fields get transferred to symbol editor.
Fixes https://gitlab.com/kicad/code/kicad/issues/7501
2021-02-14 18:30:14 +00:00
Jeff Young c016ed7940 Engage brain before coding.
Fixes https://gitlab.com/kicad/code/kicad/issues/7123
2021-01-18 15:20:15 +00:00
Jeff Young e27bd5cf15 Add control over updating of symbol attributes.
ADDED Update Symbol from Library and Change Symbol can now specify
whether or not to update attributes (include in BOM and include on
board).

Fixes https://gitlab.com/kicad/code/kicad/issues/7123
2021-01-15 22:19:49 +00:00
Jeff Young 6542960ba5 Fix failure to clear list before reusing it.
Fixes https://gitlab.com/kicad/code/kicad/issues/6927
2021-01-04 00:33:42 +00:00
Jeff Young c0d2ad42ce Remember state of RefDes and Value checkboxes.
Fixes https://gitlab.com/kicad/code/kicad/issues/6755
2020-12-18 15:09:54 +00:00
Jeff Young bb232e6ac6 Unify LIB_IDs now that both are stored in sexpr files.
Fixes https://gitlab.com/kicad/code/kicad/issues/6764
2020-12-18 00:30:26 +00:00
Ian McInerney fc20eaa083 Fix some compiler and Coverity warnings 2020-12-17 00:30:22 +00:00
Jeff Young 5761666ad6 Don't let the flattened symbol go out of scope before we're done with it.
Fixes https://gitlab.com/kicad/code/kicad/issues/6760
2020-12-16 17:59:20 +00:00
Jeff Young 10e68daa37 Fix some bugs in Change Symbol and Update Symbols.
In particular, there was a typo that kept library values from being
updated, and there was missing logic to fetch the various field names
from the library parts (and the change-to part).

Also implements some performance gains by desisting from copying
LIB_FIELDs around every time we want to look at them.

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

Fixes https://gitlab.com/kicad/code/kicad/issues/6749
2020-12-15 16:12:17 +00:00
Jon Evans b7564f6f05 Don't modify RTree while iterating over it
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6582
2020-12-02 12:33:08 -05:00
Jeff Young 8d3d648975 Update Change Symbols dialog to Update/reset terminology...
... as used in the Change Footprints dialog.
2020-12-02 14:27:43 +00:00
Jeff Young 3d7c26b6bd Get fields out of SYMBOL, not LIB_PART.
Also make sure the match-mode is initialised before we try and fetch
all the field names.

Fixes https://gitlab.com/kicad/code/kicad/issues/6589
2020-12-02 14:27:43 +00:00
Jeff Young bf04fc3b72 Process all symbol instances as the ref, value, etc. may be different.
Also makes sure that the instance fields get set for reference, value
and footprint, and not just the base SCH_FIELD.

Also makes the translations easier.

Fixes https://gitlab.com/kicad/code/kicad/issues/6459
2020-11-23 22:09:15 +00:00
Jeff Young c89676e39d Require client to specify whether they want resolved values or not.
Fixes https://gitlab.com/kicad/code/kicad/issues/6408
2020-11-17 21:36:48 +00:00
Jeff Young a207bd97bb Naming conventions. 2020-11-17 16:05:49 +00:00
Jeff Young b227d2b910 More component -> symbol. 2020-11-15 20:23:15 +00:00
Jeff Young f0d0e17aab Prepare for MODULE -> FOOTPRINT. 2020-11-13 15:16:24 +00:00
Marek Roszko 81a7afc76e Use kicad_algo directly rather than common.h 2020-10-24 08:53:11 -04:00
Ian McInerney 06bf7943b7 Minor warning fixes 2020-10-21 00:30:50 +01:00
Jeff Young 688a031793 Fix broken logic when updating fields.
Fixes https://gitlab.com/kicad/code/kicad/issues/6024
2020-10-18 00:51:58 +01:00
Seth Hillbrand 971eb529f4 Separate strings into full strings 2020-10-16 23:10:47 -07:00
jean-pierre charras bda275de46 more cleanup about removing useless include 2020-10-03 11:48:16 +02:00
Jeff Young e4bc1eb3bf Fold Update Fields from Library into Update Symbol.
Also gives Change Symbol control over which fields to update.

Fixes https://gitlab.com/kicad/code/kicad/issues/5217
2020-09-27 14:09:11 +01:00
Jeff Young cdbe2fd2d2 User terminology specific to Change Footprint/Symbol.
Also implements separate session settings for the reset checkboxes
for Change Footprint and Update Footprint.

Fixes https://gitlab.com/kicad/code/kicad/issues/5614
2020-09-16 00:15:26 +01:00
Jeff Young 7b05e456cc Bug fixes for multiple symbol instances in complex hierarchies
1) use SCH_COMPONENT::GetRef(), GetValue() and GetFootprint() when
instance-specific info is needed
2) update UpdateAllScreenReferences() to handle value and footprint.
3) BACKANNO is CvPcb's handler, not back annotation's handler.  Which
means it needs GUI behaviour, not back annotation behaviour.

Fixes https://gitlab.com/kicad/code/kicad/issues/5520
2020-09-06 13:57:14 +01:00
Jeff Young b596d3c3d5 Implement update options for Update Symbol from Library. 2020-09-02 15:21:51 +01:00
Mark Roszko 1082402b33 Convert UNDO_REDO_T to an enum class 2020-08-26 18:04:32 +00:00
jean-pierre charras b60a7e2aca Eeschema: fix crash in DIALOG_CHANGE_SYMBOLS when run Update Library Symbols.
Probably due to a typo.
Fix also a minor wxWidgets alert in this dialog
2020-08-18 20:53:10 +02:00
Wayne Stambaugh 0bb175a028 Eeschema: Add change and update symbol from library support.
ADDED: Add support to to Eeschema to change and update symbols from a
symbol library.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/4565
2020-08-13 13:53:49 -04:00