Commit Graph

101 Commits

Author SHA1 Message Date
Marek Roszko 0ff32d20cd wxS more things 2023-01-22 09:41:42 -05:00
Wayne Stambaugh d99e09014b Rename SYMBOL_INSTANCE_REFERENCE to SCH_SYMBOL_INSTANCE. 2023-01-04 15:39:50 -05:00
Jon Evans ac3ed02283 Rework bitmap cache and enable it
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12405
2023-01-04 00:26:45 +00:00
Wayne Stambaugh 0a62c17040 Remove schematic symbol value and footprint field instance data.
https://gitlab.com/kicad/code/kicad/-/issues/12933
2022-11-30 11:47:13 -05:00
Wayne Stambaugh 6f90a63381 Fix legacy schematic symbol instance data bug. 2022-11-20 14:57:37 -05:00
Jon Evans dd94b2d3a7 Rename PROPERTIES to STRING_UTF8_MAP for clarity
This class has nothing to do with the properties system
2022-11-06 11:51:52 -05:00
Wayne Stambaugh 85805bdad7 Fix broken legacy file format symbol instance data import. 2022-10-19 12:23:28 -04:00
Wayne Stambaugh 598b09821a Coverity fixes. 2022-10-17 15:30:20 -04:00
Wayne Stambaugh b109136c5c Fix complex hierarchy instance data when loading legacy schematic. 2022-10-15 14:50:06 -04:00
Wayne Stambaugh f782323960 Fix yet another symbol instance issue when loading legacy schematics. 2022-10-15 14:16:03 -04:00
Wayne Stambaugh 2b387ae9c3 Move schematic symbol instance data back into symbol definition.
This change reverts the storage of all symbol instance data in the root
schematic.  This was done because it's not possible to reuse instance
data when importing from sub-sheets.

There has been a fundamental change in how sheet paths are store in the
instance data.  The root schematic UUID is always used when saving the
instance data.  To prevent file churn, the virtual root sheet UUID is set
to the root schematic UUID when loading the project.  This provides a way
to determine the project that stored the instance data.  All uses of paths
without root sheet have been expunged from the code.

The sheet instance data is still saved only in the root sheet for the
time being.  New sheet instances will be automatically assigned an page
number based on the incremental virtual sheet page number.  Sheet page
numbers will not be imported.

Added project name to instance data to improve the readability of the
schematic file format.  It also creates an opportunity to remove orphaned
instance data by project name rather than cryptic UUIDs.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12472
2022-10-02 15:06:42 -04:00
Jeff Young c0a666507c Work around more instances of the wxWidgets color string locale bug.
Fixes https://gitlab.com/kicad/code/kicad/issues/12552
2022-09-30 20:56:25 +01:00
Wayne Stambaugh 979b4a4eb7 Revert "Move schematic symbol instance data back into symbol definition."
This reverts commit 7984e114db.
2022-09-29 15:33:23 -04:00
Wayne Stambaugh 7984e114db Move schematic symbol instance data back into symbol definition.
This change reverts the storage of all symbol instance data in the root
schematic.  This was done because it's not possible to reuse instance
data when importing from sub-sheets.

There has been a fundamental change in how sheet paths are store in the
instance data.  The root schematic UUID is always used when saving the
instance data.  To prevent file churn, the virtual root sheet UUID is set
to the root schematic UUID when loading the project.  This provides a way
to determine the project that stored the instance data.  All uses of paths
without root sheet have been expunged from the code.

The sheet instance data is still saved only in the root sheet for the
time being.  New sheet instances will be automatically assigned an page
number based on the incremental virtual sheet page number.  Sheet page
numbers will not be imported.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12472
2022-09-29 17:47:57 +00:00
Jeff Young 10d8db482e Init intersheet refs field pos to local {0,0}, not global {0,0}
Fixes https://gitlab.com/kicad/code/kicad/issues/12517
2022-09-26 21:00:46 +01:00
Marek Roszko 7a5829f8d6 Move IU2Mils 2022-09-16 21:09:27 -04:00
Marek Roszko 61e11d6896 Strip out Mils2Iu 2022-09-16 21:09:27 -04:00
Jeff Young 536561f7b3 Move bus aliases to std::set.
This is mostly to output the aliases sorted (for ease of VCS integration),
but also because a btree will be faster than hashing on a small dataset.

Fixes https://gitlab.com/kicad/code/kicad/issues/11890
2022-09-11 19:48:08 +01:00
Jeff Young 638198251a Coverity fixes. 2022-08-22 17:52:58 +01:00
Jeff Young 88c9177ff6 Move bus members from wxArray to std::vector and fix some bugs in dialog. 2022-08-21 20:54:41 +01:00
Wayne Stambaugh 797827b833 Fix missing legacy value and footprint field instance data.
The legacy and s-expression (prior to version 20200828) file formats only
supported symbol unit and reference fields so the newly added value and
footprint fields must be updated from the original symbol fields.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12226
2022-08-17 11:32:04 -04:00
Seth Hillbrand 35ac39844f Clean up some auto usage
Don't make new copies of shared_ptr if we can use references.  Keep auto
usage down to hard-to-type-out sequences
2022-08-15 11:29:45 -07:00
Jeff Young d5a6452934 Get rid of special default line style for Eeschema.
Fixes https://gitlab.com/kicad/code/kicad/issues/11882
2022-06-27 19:12:45 -06:00
Jeff Young 4f62960334 Update message panel from PCB point editor and SCH drawing tools.
Fixes https://gitlab.com/kicad/code/kicad/issues/11186
2022-03-21 10:32:36 +00:00
Wayne Stambaugh fc3cad0b54 Hash symbol libraries per library rather than statically per cache type. 2022-02-07 15:40:21 -05:00
Wayne Stambaugh 9260431fe4 Abstract out symbol library parser object. 2022-02-02 07:07:39 -05:00
Wayne Stambaugh 6fcc6f7c9d Factor out common legacy schematic and symbol library parser code. 2022-02-01 16:30:15 -05:00
Wayne Stambaugh b36e31c49f Factor out common and remove dead legacy symbol library code. 2022-01-29 14:13:00 -05:00
Jeff Young 3409783d9f Break sch_text.h/.cpp into sch_text and sch_label.
Also moves SCH_NETCLASS_FLAG to SCH_DIRECTIVE_LABEL, and remaps Altium
harnesses from SCH_TEXT to SCH_DIRECTIVE_LABEL.
2022-01-28 21:38:15 +00:00
Jeff Young 9b661aea10 EDA_ANGLE for plotters.
Also fixes a compile error in the PNS Playground.
2022-01-16 01:19:45 +00:00
Jeff Young 1b19ff5f42 More EDA_ANGLE changes. 2022-01-14 16:08:19 +00:00
Jeff Young e048e51f5d Improve SNR of EDA_ANGLE stuff. 2022-01-14 16:08:18 +00:00
Seth Hillbrand 3ace4446e7 Use 'special' escaping for certain fields
Most fields are escaped using the `\` notation.  But the VALUE field and
the symbol name need to be escaped using braces notation.

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

(cherry picked from commit 71e7b4b77b)
2022-01-05 17:19:36 -08:00
Marek Roszko ea613cf448 Another batch of point changes 2022-01-01 13:17:12 -05:00
Marek Roszko c4c56de708 Neurotically update position wxPoint usages 2022-01-01 11:55:51 -05:00
Jeff Young 86cb57f4a7 Cherry-pick TEXT_ATTRIBUTES and EDA_ANGLE from rockola/kicad-strokefont 2021-12-28 22:15:20 +00:00
Jeff Young 889970a449 SCH_NETCLASS_FLAGs and SCH_FIELDs for labels.
ADDED: a new label type for netclass flags.
ADDED: the ability to define fields on labels.
2021-12-24 16:13:27 +00:00
Jeff Young 2bc86fa0a8 Shapes for schematic.
ADDED arc, circle and rectangle shapes for schematic.  Shapes support
line styles and fill colors.

CHANGED sheet background color in Edit Text & Graphics Properties to
fill color (and it now affects shapes).

Pushed STROKE_PARAMS down into common and moved all shapes to using it
for stroke descriptions.
2021-12-23 20:36:07 +00:00
jean-pierre charras 3a00d76207 Fix a compil warning (shadowed var) and add a comment. 2021-12-01 11:05:16 +01:00
dsa-t bfe595819a Prevent error when loading bitmaps from some old schematics 2021-12-01 09:54:48 +00:00
Mikolaj Wielgus 9bb370e6b4 SCH_SHEET_PIN: Rename GetEdge, SetEdge to GetSide, SetSide 2021-11-28 20:07:06 +01:00
Jeff Young 0cdffa16d4 Fix off-by-one error in fill mode writing.
Fixes https://gitlab.com/kicad/code/kicad/issues/9111
2021-10-28 19:29:47 +01:00
Jeff Young 8fdfc0e63d Replace legacy sch writing code for rescue functionality. 2021-10-28 15:11:15 +01:00
Jeff Young b52529521e Replace individual LIB_* shapes with LIB_SHAPE (based on EDA_SHAPE).
Also moves to more capable FILL_T model that can be shared.
2021-10-15 12:45:43 +01:00
Jeff Young 9b9e379aa0 Overhaul arc internal model to not over-specify information. 2021-10-15 12:45:43 +01:00
Wayne Stambaugh c61af21da8 Eeschema: don't stat files when updating title bar text.
The tests for file existence and write status perform two file stats
which cause performance issues on slow network shares.  Now the file
state is determined at load time and stored in the SCH_SCREEN object
so file access is no longer required.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/9343
2021-10-14 10:52:58 -04:00
Wayne Stambaugh 4663da4709 Eeschema: don't escape document file alias names in legacy plugin.
Escaping the document file (.dcm) alias names breaks the link between the
document file and the library (.lib) file.  This causes the information in
the document file to be lost.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/9130
2021-09-16 09:09:44 -04:00
Wayne Stambaugh 451f8eefc0 Eeschema: fix broken project symbol rescue bug.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9111
2021-09-09 10:21:09 -04:00
Jeff Young 8879b887df Fix missing overbar notation conversions in legacy library parsing.
Fixes https://gitlab.com/kicad/code/kicad/issues/8981
2021-08-18 22:48:29 +01:00
Jeff Young 41619ebbe2 Decouple PROGRESS_REPORTER interface from implementations. 2021-08-14 21:05:49 +01:00