Commit Graph

114 Commits

Author SHA1 Message Date
Jeff Young bbd6c80507 Collapse FP_* down into their PCB_* equivalents. 2023-03-31 22:57:46 +01:00
Marek Roszko 604a7d69db Move up a layer validity check to prevent crash
Fixes sentry crash KICAD-RF
2023-03-25 17:12:22 -04:00
Jeff Young 461def2719 Move automatic dimension processing inside PCB_DIMENSION_BASE.
Also move dimension precision to an enum so it can get a proper dropdown
in the properties inspector.
2023-03-05 15:19:06 +00:00
Jeff Young 23accffc6d Add Property Inspector support for dimension objects.
Includes changing the class hierarchy so that dimension objects inherit
from PCB_TEXT rather than containing a PCB_TEXT member variable.
2023-03-04 23:16:46 +00:00
Marek Roszko aacc9746e3 Yeet the last of wxSize/wxPoint to stop leaking gdicmn everywhere 2023-02-18 22:57:18 -05:00
Jon Evans e066454c61 Zones: use metric defaults and limits instead of mixed units
Update testcases to reflect new defaults
2023-02-11 07:39:29 -05:00
vinsfortunato 5bdaf20af6 eagle: determine and use the minimum copper layer stackup count
Fixes: https://gitlab.com/kicad/code/kicad/issues/13484
2023-01-29 21:13:41 +00:00
Dag Lem cff0560088 Eagle schematic import: Handling of escaped text 2023-01-18 12:33:36 +00:00
Seth Hillbrand 60ba245474 Remove Eagle islands by default unless told otherwise
Fixes https://gitlab.com/kicad/code/kicad/issues/13503
2023-01-17 12:49:44 -08: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
Jeff Young f358749b28 Import copper pour cutouts from Eagle packages (footprints).
Fixes https://gitlab.com/kicad/code/kicad/issues/13503
2023-01-13 16:35:45 +00: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
Marek Roszko e6ed275c25 Repoint IU_PER_MILS 2022-09-16 21:09:26 -04:00
Marek Roszko a8613ee80f Combine Iu2Millimeter & remove PcbMm2iu 2022-09-16 21:09:26 -04:00
Mark Roszko b00178adb3 Nuke base_units from orbit 2022-09-16 04:38:10 +00:00
Jeff Young 5679b9dbdc Remove a few EDA_RECT instances. 2022-08-31 01:22:49 +01:00
Jeff Young 0c8787cbb9 Some more wxPoint/EDA_RECT yeeting. 2022-08-31 00:44:33 +01:00
Seth Hillbrand f1261e71d4 Replace boost::optional with std::optional 2022-08-25 15:50:47 -07:00
Wayne Stambaugh c72457482c Fix Eagle plugin footprint QA test issue.
Apparently mapping Eagle footprint layers to the KiCad Dwg_User
that were previously mapped to UNDEFINED_LAYER breaks the QA test
and causes the footprint editor to crash when opening Eagle
footprints.  This means that the potential data loss issue when
loading Eagle footprints is still in play.
2022-08-22 09:11:30 -04:00
Wayne Stambaugh 0bc1188897 Fix Eagle plugin board layer mapping issue.
The Eagle plugin layers have to be mapped differently depending on
whether a board is being imported or a footprint library is being
cached.  Footprint libraries can bypass the manual layer remapping
step that happens when importing a board.

Please note that when loading footprints in the footprint editor
and viewer, all layers that do not directly map to KiCad layers are
put on the Dwg_User layer so that there is data loss.  Users will
have to manually remap objects to the correct layer as required.
This is less than ideal but until the footprint library table parser
supports prompting users to remap unknown layers, it will have to do.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/11839
2022-08-21 14:56:04 -04:00
Seth Hillbrand 9828360759 Remove unused variable 2022-08-15 07:52:53 -07:00
Jeff Young a9536b5de9 CHANGED netclass assignments now done via canvas or via patterns. 2022-08-14 22:56:29 +01:00
Seth Hillbrand 2ee65b2d83 Force removal of zero-sized pads on load.
Pads with zero width or height cause issues when rendering and
selecting.  KiCad has never allowed these elements but hasn't prevented
importing systems where they exist.  This prevents their import and
cleans existing designs where the pads are placed

Fixes https://gitlab.com/kicad/code/kicad/issues/12200
2022-08-13 19:10:48 -07:00
Jeff Young 4afca58ce7 Eagle octagonal pads are regular (~29% chamfered).
Also cleans up setting of KeepTopBottom (which is ignored unless
we're doing optional flahing -- which we're not for Eagle imports).

Fixes https://gitlab.com/kicad/code/kicad/issues/11664
2022-05-23 10:43:34 +01:00
Marek Roszko 88c7322a0d EDA_TEXT Get/SetTextSize should use VECTOR2I 2022-05-14 08:16:15 -04:00
Jeff Young a33e23e25a Import radial dimensions from Eagle.
Fixes https://gitlab.com/kicad/code/kicad/issues/10763
2022-04-12 15:47:39 +01: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 2663ad5340 Implement Eagle text variables.
Also fixes two bugs:
1) subsequent text items that are marked >NAME or >VALUE will now get
imported as text items with ${REFERENCE} or ${VALUE} (instead of overwriting
the previous text item)

2) we no longer (accidentally) capitalize all text items.

Fixes https://gitlab.com/kicad/code/kicad/issues/11321
2022-04-10 17:29:47 +01:00
Jeff Young a23399a1af Formatting. 2022-04-10 17:29:47 +01:00
jean-pierre charras 5e52539939 eagle importer: fix incorrect conversion UTF8/wxString.
When importing a eagle board file using wxXmlDocument, the strings in eagle BOARD
(UTF8 encoded) are correctly converted to wxString (using unicode wide chars)
So trying to reconvert these strings using FROM_UTF8( <wxString>.c_str() )
is incorrect and can break initial string if non ASCII7 chars are found
2022-04-09 15:33:01 +02:00
Thomas Pointhuber bd18e340f4 eagle: introduce *.lbr footprint import test
Bugs found but not fixed yet:
* Reference and Value are not converted correctly yet
  * HOTFIX: test commented out
* GP3906-TLP and UBLOX_ZOE_M8-0-10 are not able to import the description again
  * HOTFIX: description removed from gold file
2022-04-02 20:07:16 +02:00
Jeff Young 843a56c4e4 Implement two-staged zone priority: assigned priority followed by UUID. 2022-03-01 14:53:35 +00:00
Steffen Mauch 78620347c8 Fixing Eagle refs that do not work with KiCad
KiCad has stricter requirements for what consititutes an annotated
symbol.  This checks for and corrects annotations that begin with '#',
do not begin with a non-numeric character or do not end with a number
2022-02-25 23:42:47 +00:00
Jeff Young b2e3f03222 More wide-string declarations. 2022-02-05 22:03:04 +00:00
Jeff Young 7ccac79192 More wxString wide literals. 2022-02-05 21:29:34 +00:00
Steffen Mauch 61b2b0ff0c EAGLE plugin: use specified RATIO value for text size calculation 2022-02-01 17:58:09 +00:00
Steffen Mauch 55b782d66e pcbnew: EAGLE importer does map value to wrong layer if nothing is defined in original EAGLE footprint
Fixes https://gitlab.com/kicad/code/kicad/issues/10311
2022-01-21 21:14:40 +00:00
Jeff Young 038db715a3 Move zone hatch orientation to EDA_ANGLE. 2022-01-19 00:34:03 +00:00
Jeff Young 0218b782f4 Angle cleanup in Eagle importer. 2022-01-18 02:31:37 +00:00
Jeff Young e84c574830 Some more EDA_ANGLE cleanup. 2022-01-16 19:16:18 +00:00
Jeff Young 07013d00e1 More EDA_ANGLE. 2022-01-14 16:08:19 +00:00
Jeff Young 1b19ff5f42 More EDA_ANGLE changes. 2022-01-14 16:08:19 +00:00
Jeff Young c9487bad18 Move BOARD_ITEM::Rotate() to EDA_ANGLE. 2022-01-14 16:08:19 +00:00
Jeff Young abd3f5bc2b Move footprints to EDA_ANGLE. 2022-01-14 16:08:18 +00:00
Jeff Young d485eb2514 Move pads to EDA_ANGLE. 2022-01-14 16:08:18 +00:00
Wayne Stambaugh a77b5649cc Footprint editor: fix Eagle plugin footprint library layer mapping bug.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10354
2022-01-12 20:51:45 -05:00
Marek Roszko fcfe42d67c Continue the war on wxPoint 2022-01-10 19:52:26 -05:00
Steffen Mauch 82f147ecef pcbnew: EAGLE plugin is case sensitive to >VALUE / >NAME
Fixes https://gitlab.com/kicad/code/kicad/issues/10253
2022-01-05 12:51:02 +00:00
Steffen Mauch a5307c6f59 pcbnew: fixing eagle_plugin with empty class names
Fixes #10229
https://gitlab.com/kicad/code/kicad/issues/10229
2022-01-05 12:19:53 +00:00
Marek Roszko 726d873c53 Tear down the wxPoint trigo helpers 2022-01-04 21:23:11 -05:00