Commit Graph

42 Commits

Author SHA1 Message Date
Jeff Young e6ca9837a2 Clear numbers from non-numberable pads and don't run DRC on them.
This was also the last straw on the misnamed PAD::GetName() and
PAD::SetName(), which are now PAD::GetNumber() and PAD::SetNumber().

Fixes https://gitlab.com/kicad/code/kicad/issues/9017
2021-08-24 01:03:06 +01:00
Jeff Young fec34e8dd8 Get rid of an extraneous layer parameter.
Also adds a bit of nullptr safety.
2021-08-23 20:00:17 +01:00
Jeff Young 41619ebbe2 Decouple PROGRESS_REPORTER interface from implementations. 2021-08-14 21:05:49 +01: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
Wayne Stambaugh 369d813a32 Pass std::string by reference instead of on the stack where applicable. 2021-07-27 13:30:05 -04:00
Jeff Young 0fb864d596 Pull some name changes back from 7.0 to ease merging. 2021-07-21 20:58:59 +01:00
Jeff Young 0dfb5fcaf9 Error message cleanup.
wxString::Format is redundant in a wxLogXXX call.
Error messages should generally be translatable.
Error messages should use generally consistent sentence forms.
2021-06-26 22:53:24 +01:00
Jeff Young 8502fd6877 Divide-by-zero safety. 2021-06-24 12:18:22 +01:00
Jeff Young 50eea4f487 Import progress dialog for FabMaster.
Fixes https://gitlab.com/kicad/code/kicad/issues/5315
2021-06-24 00:21:37 +01:00
Jeff Young 096e342386 Prefix TRACK, ARC and VIA. 2021-06-11 22:07:02 +01:00
Marek Roszko 10e60acf34 Clean up including of board_design_settings.h 2021-06-06 15:03:42 -04:00
Ian McInerney 4f05262705 Cleanup includes in board.h and footprint.h 2021-06-03 20:19:52 +01:00
Seth Hillbrand 208dd5cbd5 Cleanup string handling in fabmaster import
Avoids round-tripping std::string->c_str->std::string and makes a few
auto references explicit
2021-06-01 13:54:34 -07:00
Marek Roszko 03cf2b517f Enum class PAD_ATTR_T
Renamed such that python stays the same
2021-05-01 10:51:54 -04:00
Marek Roszko b243c2280d enum class PAD_SHAPE_T 2021-05-01 08:22:35 -04:00
Marek Roszko 21fde9b629 enum class PCB_SHAPE_TYPE_T 2021-04-30 22:36:12 -04:00
Seth Hillbrand 7b3c7e1ef3 Fix some free/delete issues
Removes the C-format memory management
2021-04-08 16:58:45 -07:00
Seth Hillbrand bcc3767c2a FABMASTER: Fill both kinds of silk polys
Silkscreen polygons are always filled (I think) in FABMASTER.  Other
layer polygons are not
2021-02-27 06:58:04 -08:00
Seth Hillbrand 5d352d2373 FABMASTER: Enforce KiCad limits on line width
We require unfilled polygons to have positive width
2021-02-26 17:16:54 -08:00
Seth Hillbrand 7e0168a99d FABMASTER: Process newer outline tag
Allegro uses the subclass "DESIGN_OUTLINE" in newer version for their
edge cuts instead of just "OUTLINE".  This handles both.

Fixes https://gitlab.com/kicad/code/kicad/issues/7735
2021-02-26 17:06:56 -08:00
Seth Hillbrand c9b39aaaed FABMASTER: Process REFDES position
The reference designator is stored separately with the Tracks, so we
need to extract position/size data from it there and match back to the
components later.

Fixes https://gitlab.com/kicad/code/kicad/issues/7733
2021-02-26 17:04:21 -08:00
Seth Hillbrand 75c525af4f FABMASTER: Handle polygons better
Polygons in non-etch layers need special handling to ensure they get
treated the same.

Fixes https://gitlab.com/kicad/code/kicad/issues/7731
2021-02-26 14:01:04 -08:00
Seth Hillbrand 2d5015c217 FABMASTER: Try harder to figure out nets
Find all intersecting points both forward and back between the filled
areas and the outlines in order to determine the proper net assignment
for the zones

Also creates rule areas for special zones instead of filled zones

Fixes https://gitlab.com/kicad/code/kicad/issues/7732
2021-02-26 13:06:06 -08:00
Seth Hillbrand 73dd93701a FABMASTER: demote odd graphics warning
Drill layers have many different shapes in FABMASTER.  These are not
used for board information, so we can ignore them.
2021-02-26 11:37:21 -08:00
Seth Hillbrand ae2a9ef538 Use std::locale::classic static local
Prevents performance issues when creating new locales under MSVC
2021-02-26 11:37:21 -08:00
Seth Hillbrand 103dde67f6 FABMASTER: Handle rotated/flipped custom pads
The rotate mirror actions need to line up with the expectation.
FABMASTER keeps elements board-referenced while KiCad has some elements
referenced to the board and some referenced to the footprint
2021-02-26 11:37:21 -08:00
Seth Hillbrand ff1300d13b FABMASTER: Preallocate vectors
Reserves memory for vector elements based on file size.  This helps
reduce the number of re-allocations needed when reading large files
2021-02-26 11:37:21 -08:00
Jeff Young 86aaa2e9cb Rationalize footprint bounding boxes and cache all of them.
Fixes https://gitlab.com/kicad/code/kicad/issues/7720
2021-02-26 13:50:27 +00:00
Marek Roszko 622baa6531 Silence more unused exception var warnings 2021-02-20 12:01:51 -05:00
Seth Hillbrand de7d9ef874 Fix tabs 2021-02-15 08:09:20 -08:00
Seth Hillbrand 55db1aa5f5 Fix minor Fabmaster issue 2021-02-13 16:32:39 -08:00
Seth Hillbrand 016bffc899 Remove some more unneeded atof() calls 2021-02-05 10:18:34 -08:00
Seth Hillbrand 2e67cd2db8 Fix locale issue in Fabmaster import 2021-02-04 16:32:02 -08:00
Seth Hillbrand aa0db969ca Caching ConvexHull routine
Stores a cache of the convex hull similar to the bounding box.  Modifies
the hull based on actions to allow  complex footprint graphics without delay

Fixes https://gitlab.com/kicad/code/kicad/issues/7341
2021-02-04 15:56:52 -08:00
jean-pierre charras 0de3d48db5 typo 2021-02-04 09:00:35 +01:00
Seth Hillbrand 22d78a5827 FABMASTER: Handle flipped custom pads and rounded rects
Adds error messages for more cases and fallback for custom pads to
prevent invalid pad generation
2021-02-02 19:33:18 -08:00
Seth Hillbrand b54e951ed8 Fix a couple of checks in Fabmaster 2021-01-31 14:12:40 -08:00
Seth Hillbrand 89a72df0b1 Fix a few FABMASTER issues
- Custom pads now properly supported with offset/rotation
- Fix missing pads from alternate layers

Fixes https://gitlab.com/kicad/code/kicad/issues/7299
2021-01-27 17:50:14 -08:00
Seth Hillbrand 5a9c0a9b5a Quiet a few coverity warnings 2021-01-24 14:53:18 -08:00
Seth Hillbrand 060635b14c fabmaster: Fix graphic handling in geometry section 2021-01-19 12:16:40 -08:00
Jon Evans 1754504234 Fabmaster: fix MSVC build
std::map is not move-constructable on MSVC because
it is not declared noexcept (and is not required to be
by the standard)

This means that a struct containing graphic_element
cannot be inserted into a vector with move semantics without
compile errors.  However, wrapping it in a unique_ptr
works.
2021-01-17 10:23:31 -05:00
Seth Hillbrand 950db6ff9c pcbnew: Add Fabmaster import
Allows importing ASCII design output from OrCAD designs
2021-01-16 14:28:33 -08:00