Commit Graph

150 Commits

Author SHA1 Message Date
Alex Shvartzkop a16bdb7288 ADDED: Support EAGLE libraries directly in Symbol Library Table.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/2214
2023-10-15 01:45:39 +03:00
Thomas Pointhuber 7005dd7c48 altium: make special string parsing on pcb a bit more generic
Only special strings starting with a dot are supported. Parsing of concatenated special strings using quotes needs to be implemented, but at least a few test-cases are already there now.
2023-10-01 15:10:50 +02:00
Thomas Pointhuber 3b3e4fd34a Move duplicated code of plugin.cpp and sch_plugin.cpp into a new plugin_utils located in commons 2023-10-01 13:58:38 +02:00
Alex Shvartzkop 3b28ba83c6 EasyEDA Pro: don't fail on attributes for dimensions. 2023-09-29 12:17:30 +03:00
Marek Roszko 3cd60007c5 Dont leak richio into everything 2023-09-07 22:29:40 -04:00
jean-pierre charras 3e6f7ab3e5 Fix compil issues (especially easyeda_parser_base.xx) and compil warnings
Compil issues can be gcc13/msys2 specific.
2023-09-07 13:41:25 +02:00
Alex Shvartzkop 21ee65aa9c ADDED: Importers for EasyEDA (JLCEDA) Standard / Professional. 2023-09-07 11:02:40 +03:00
Marek Roszko a4d8c021aa Remove rouge gdicmn include 2023-09-06 18:33:22 -04:00
Seth Hillbrand c7868f0832 Altium Plugin updates
Handle Altium multiple display modes (e.g. DeMorgan)
Handle Altium overbar format (o\v\e\r\b\a\r\)
Transform ellipses and elliptical arcs into approximate arcs
Add remaining unknown RECORD ids
2023-09-06 19:15:35 +00:00
Seth Hillbrand 1b63d11adf Speed up Altium compound file reader
Just read the footprint list once and store the cache for later use.
2023-09-06 19:15:35 +00:00
Seth Hillbrand 24d3df5416 ADDED: Altium SchLib Support 2023-09-06 19:15:35 +00:00
Alex Shvartzkop 8a4f203963 Altium: remove illegal chars from library name. 2023-09-02 10:36:03 +03:00
Seth Hillbrand 57ba38560c Optimize library load time for Altium plugin
Load times were >20min for moderate sized libraries as EnumFiles
iterated over the entire list for each operation.  The update modifies
our third-party lib to allow a return value, stopping the iteration when
we find our desired entry.  This also provides a short-circuit for
ASCII-based names, allowing single-level parsing if available
2023-08-18 13:50:15 -07:00
Alex Shvartzkop 24452f41ad Improvements to Altium PCB/footprint importer:
- Support unicode footprint names
- Set default footprint text size and thickness to match KLC
- Position Reference at the top, Value at the bottom of fp bounding box
2023-07-22 08:55:53 +05:00
Alex Shvartzkop e892405738 Altium PCB import: read and apply TrueType font names to text. 2023-07-04 13:29:42 +03:00
Jeff Young 8bd21edd8a Fix capitalization of text vars for Eagle importer.
Also fixes the test gold files to expect the correct variable
references.
2023-05-06 23:49:10 +01:00
Jeff Young 8fe02ee83c Handle Eagle user-defined attributes.
(We map these to text variables.)

Fixes https://gitlab.com/kicad/code/kicad/issues/13798
2023-05-06 21:10:34 +01:00
qu1ck 0c049eccc7 Fix a bunch of compiler warnings 2023-04-11 17:01:30 +00:00
Jeff Young 13e79af8a0 Eagle template footprints don't actually belong to board.
Set their parent to nullptr before deleting (as the board may have
already been deleted).

Likely fix for Sentry KICAD-79.
2023-04-04 14:18:49 +01:00
Roberto Fernandez Bautista c5362c9b0a CADSTAR: Parse PINNOOFFSET and PINNOANGLE 2023-03-16 21:07:08 +01:00
Roberto Fernandez Bautista a5dc528c88 CADSTAR: Fix edge case in parts grammar (symbol name can be quoted) 2023-03-16 21:07:08 +01:00
Roberto Fernandez Bautista 59d88e1871 CADSTAR Parts: Add parsing of hierarchy tree 2023-03-16 21:07:07 +01:00
Roberto Fernandez Bautista b70fe88145 CADSTAR Parts: Fix parsing of hidden pins (possible for several pins per net!) 2023-03-16 21:07:07 +01:00
Roberto Fernandez Bautista 6ab2112135 ADDED: CADSTAR Parts Libraries (.lib) 2023-03-16 21:07:07 +01:00
Roberto Fernandez Bautista 8f83f27336 CADSTAR SCH: Refactor loading of symbols out of loading part info 2023-03-16 21:07:06 +01:00
Roberto Fernandez Bautista c34207b726 CADSTAR: Remove wxPoint + improve formatting 2023-03-16 21:07:06 +01:00
Roberto Fernandez Bautista f45ab30fa6 Add parsing for symbols and pins (Parser now complete) 2023-03-16 21:07:05 +01:00
Roberto Fernandez Bautista e2a4d58e8f Extract CADSTAR PIN_TYPE and PIN::POSITION into a separate header 2023-03-16 21:07:04 +01:00
Roberto Fernandez Bautista 379e3b2fbb Add CADSTAR Parts Library (.lib) parser and qa tests 2023-03-16 21:07:04 +01:00
Roberto Fernandez Bautista b03366c9e8 Fix CADSTAR importer memory leaks
We were leaking the xml tree when throwing exceptions
2023-02-27 23:57:39 +01:00
Roberto Fernandez Bautista 698d0b7e92 CADSTAR Sch: Fix loading of graphical arc shapes
Correctly load arc shapes as real arcs instead of approximating now that
v7 supports graphical arcs in the schematic.

Also fix calculation of arc geometry for ccw arcs.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14101
2023-02-26 19:46:34 +01:00
Marek Roszko 30a49462fe Fix crash parsing cadstar
Fixes sentry KICAD-B2
2023-02-19 08:06:35 -05:00
Marek Roszko aacc9746e3 Yeet the last of wxSize/wxPoint to stop leaking gdicmn everywhere 2023-02-18 22:57:18 -05:00
Marek Roszko 4665823089 Turn on and fix MSVC compliance mode issues
We want /permissive- to enable debug performance improvements in MSVC 17.5+.
This flag is also default under C++20 so we'll have to deal with these compile issues anyway at some point in the future.

In particular, MSVC becomes pedantic about ternary types.
See https://learn.microsoft.com/en-us/cpp/build/reference/permissive-standards-conformance?view=msvc-170#ambiguous-conditional-operator-arguments

MSFT cites https://cplusplus.github.io/CWG/issues/1805.html
2023-02-12 16:30:37 -05:00
Dag Lem cff0560088 Eagle schematic import: Handling of escaped text 2023-01-18 12:33:36 +00:00
Jeff Young ea1d7c5d97 Update Eagle imported variable mapping to better match Eagle output.
Fixes https://gitlab.com/kicad/code/kicad/issues/13541
2023-01-17 13:43:47 +00:00
Jeff Young 9315e885ee Substitute variables in imported symbol text.
Also allows mulit-line text items to be imported.

Fixes https://gitlab.com/kicad/code/kicad/issues/13541
2023-01-16 16:01:45 +00:00
Jeff Young ca1fb732c8 Share Eagle var substitution between board and schematic importers.
Fixes https://gitlab.com/kicad/code/kicad/issues/13541
2023-01-15 22:27:19 +00:00
Roberto Fernandez Bautista 99d02ac7c0 CADSTAR SCH: Load symbol shapes with correct fill state
Changes architecture of importer to use SHAPE_LINE_CHAIN.

For now lets just load symbol shapes like this, but we could update code
for all other loading operations (also in PCB).

FIxes https://gitlab.com/kicad/code/kicad/-/issues/8060
2023-01-10 22:28:01 +01:00
Roberto Fernandez Bautista ee6e86d1db Add conversion from CADSTAR SHAPE to SHAPE_POLY_SET 2023-01-10 22:28:01 +01:00
Jeff Young f17ddf5c88 Terminate overbar notation correctly.
Fixes https://gitlab.com/kicad/code/kicad/issues/13438
2023-01-08 20:08:53 +00:00
Seth Hillbrand f1261e71d4 Replace boost::optional with std::optional 2022-08-25 15:50:47 -07:00
Marek Roszko f695ae5522 Generate const keyword_hash maps at compile time
Or else the map gets pointlessly recreated during footprint loading thousands of times
2022-08-09 00:56:49 -04:00
luz paz 79fa911e0e Fix various typos
Found via `codespell -q 3 -S *.po,./thirdparty,./Documentation/changelogs -L aactual,acount,aline,alocation,alog,anormal,anumber,aother,apoints,aparent,aray,ba,busses,dout,einstance,leaded,modul,ontext,ot,overide,serie,te,,tesselate,tesselator,tht`
2022-07-21 16:31:41 +00:00
Roberto Fernandez Bautista 41bf397d24 CADSTAR Schematic: Fix parsing of ATTRCOLORS.
Apparently there can be a `INVISIBLE` token. Unclear what it means,
but lets read it anyway
2022-06-03 23:07:12 +02:00
Jeff Young 739f4d0a1e Improvements to Eagle dimension importing.
1) Import leaders
2) Drop radius and angle dimensions
3) Import dimension text sizes
4) Correctly interpret which side dimension offset is on
5) Correclty handle offsets for non-cardinal dimensions

Fixes https://gitlab.com/kicad/code/kicad/issues/10763
2022-04-12 15:47:39 +01:00
Jeff Young cf33cfcad1 Round Altium unit conversions to nearest 10nm.
Fixes https://gitlab.com/kicad/code/kicad/issues/6462
2022-03-22 23:22:44 +00:00
Thomas Pointhuber 8ef7252330 altium: Don't use string concatenation for paths pointing in the compound file
* std::vector do not need to be split apart again
* supports backslash in footprint names
2022-02-19 16:46:20 +01:00
Marek Roszko ca7840334c Mark some limits as constexpr
gcc doesn't need it and computes during compile regardless, but experimenting in godbolt, both clang and MSVC actually do need it or else it's partially computed at runtime
2022-02-04 07:50:13 -05:00
Thomas Pointhuber 5aff3ef949 altium: First prototype to parse tracks of a footprint 2022-01-17 19:54:28 +01:00