Commit Graph

95 Commits

Author SHA1 Message Date
Maciej Suminski af71d42307 Renamed PROPERTY_TYPE enum names to avoid a conflict on MSYS2 2022-08-22 21:32:32 -04:00
Maciej Suminski 95fd58b25a Properties meta-data for pcbnew classes 2022-08-22 21:32:00 -04:00
Jeff Young 4f0136db3b Attempt to fix std::initializer_list lifetime issue. 2022-08-21 20:54:41 +01:00
Jeff Young a9536b5de9 CHANGED netclass assignments now done via canvas or via patterns. 2022-08-14 22:56:29 +01:00
Jeff Young f41af10007 Clean up hole shapes for safety (smart pointer) and consistency. 2022-07-22 23:06:07 +01:00
Alex aaf99eb0cc Performance optimizations. 2022-07-11 21:25:12 +00:00
Seth Hillbrand 359d66bc81 Protect against invalid pads
Before dereferencing the front of the sequence, we have to ensure that
the pad exists on any layer.  If not, just return the default (probably
F_Cu) for the element
2022-06-16 08:20:47 -07:00
Jeff Young dfdedfa605 Fix some issue with NPTH pads with holes same size as pad. 2022-05-06 00:06:00 +01:00
Jeff Young f0dab2e07b Fix some layer handling issues. 2022-04-23 21:29:46 +01:00
Jeff Young dbee441328 We've probably smoked out enough of the GetLayer() issues.
... and GetProperty() can query GetLayer() in user scripts.
2022-04-14 17:09:27 +01:00
Seth Hillbrand b66df1e4f3 Remove dead code 2022-04-05 16:26:08 -07:00
Jeff Young 921181b20b Cleanup. 2022-04-04 20:43:08 +01:00
Seth Hillbrand 1926af0c34 UNDEFINED_LAYER is always flashed
This is already true for vias and should be true for pads as well

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

(cherry picked from commit 7d96d5940d)
2022-04-04 12:26:50 -07:00
Jeff Young 90af5a36d2 Show hole clearance lines around NPTH pads.
Also make the clearance line NONPLATED_HOLES colour, not the PADS_TH
colour.
2022-04-04 10:28:33 +01:00
Jeff Young f22316b868 Careful about hiding pad layers.
We also draw netnames and clearance lines based on some of these layers.
2022-04-04 10:28:33 +01:00
Seth Hillbrand 442aae19d9 Separate flashing check for connectivity
When building the connectivity database, we should not be using the
connectivity to check for shapes.

To make this deterministic, we introduce two flags (ALWAYS_FLASH and
NEVER_FLASH) that are used with connectivity building to determine
whether a pad is flashed for connectivity or not.  ZONE <-> PAD/VIA
connectivity will be checked with ALWAYS_FLASHED and all other
connectivity will be checked with NEVER_FLASHED if they are marked for
potential annular ring removal.  If they are not marked for removal,
they will be checked ALWAYS_FLASHED.

Fixes https://gitlab.com/kicad/code/kicad/issues/11114
2022-03-16 17:30:01 -07:00
jean-pierre charras f866d15154 Pcbnew: fix crash when clicking on a footprint on a filled zone area. 2022-03-07 13:56:47 +01:00
Jeff Young 0dc857b5ab Clean up pad handling in 3D viewer.
Most importantly, create F_Cu/B_Cu layers if they're otherwise empty
but we have plated pads to render on them.

Fixes https://gitlab.com/kicad/code/kicad/issues/10207
2022-03-06 13:57:12 +00:00
Seth Hillbrand b5c2f0d39a Remove the open array in favor of std containers
The containers allow iteration, size knowledge and lower bug surface
2022-03-03 16:03:26 -08:00
Jeff Young 08df5c0b01 Handle hidden layers in FP Editor.
Fixes https://gitlab.com/kicad/code/kicad/issues/10946
2022-02-23 15:31:07 +00:00
Jeff Young fad4c135fa Use only a physical connection to determine flashing of pads.
Checking for proper nets just confuses things when the nets are set
wrongly for some reason.  This way we generate clearer DRC errors.

Fixes https://gitlab.com/kicad/code/kicad/issues/10645
2022-02-20 20:54:56 +00:00
Jeff Young 1ee3ce45e8 Don't ask for layer of multi-layer objects. 2022-02-18 14:19:13 +00:00
Jeff Young 5efa354f0f Add asserts to flush out incorrect uses of GetLayer(). 2022-02-18 12:14:38 +00:00
Jeff Young 93c7046a77 Return nominal pad shape when a specific layer isn't specified.
Fixes https://gitlab.com/kicad/code/kicad/issues/10755
2022-02-11 22:09:22 +00:00
Jeff Young 50a4d610a6 Be cognizant of flashed layers when generating pad shapes. 2022-02-11 13:10:52 +00:00
Jeff Young 7ccac79192 More wxString wide literals. 2022-02-05 21:29:34 +00:00
Jeff Young b9eb3e9b05 Be more explicit about string conversions. 2022-02-03 23:07:41 +00:00
Jeff Young 4eac8d7c66 Remove unit-less angles from geometry lib APIs. 2022-01-20 21:10:04 +00:00
Jeff Young e61144d45a Finish with EDA_ANGLE. 2022-01-16 21:15:40 +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 3f98769a77 More EDA_ANGLE.
Includes bug fix for catastrophic error in Add() for converting to
radians.

Includes bug fixes for the fact that the pcbnew test can't seem to
find the ANGLE_* objects (getting all 0's instead).
2022-01-15 01:30:04 +00:00
Jeff Young 07013d00e1 More EDA_ANGLE. 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
Marek Roszko e4dbfcd92d Swap out some wxSize for VECTOR2I 2022-01-04 20:42:27 -05:00
Marek Roszko d1552c3fec Some more wxPoint removal 2022-01-01 12:11:21 -05:00
Marek Roszko c4c56de708 Neurotically update position wxPoint usages 2022-01-01 11:55:51 -05:00
Jeff Young ef10b36948 Add mask-to-copper clearance parameter and rename mask margin. 2021-12-24 12:36:41 +00:00
Jeff Young 32721755bf Hook up zone-pad connections to custom rules.
ADDED zone_connection constraint.
ADDED thermal_relief_gap and thermal_spoke_width constraints.

ADDED angle override for thermal relief spokes in Pad Properties.

Fixes https://gitlab.com/kicad/code/kicad/issues/4067
2021-12-23 22:30:26 +00:00
Jeff Young 1f9e75f676 Pad with hole same size or larger than pad isn't flashed.
... even if it's marked as being on copper layers.

Also changes the default hole clearance to 0.25mm.

Fixes https://gitlab.com/kicad/code/kicad/issues/9901
2021-12-08 23:16:33 +00:00
jean-pierre charras 3886e681ae PAD Copy CTOR: fix missing copy of m_pinType member. 2021-11-28 14:34:26 +01:00
Jeff Young 99ec2b1801 Don't hide original object when highlight is only part of it.
Fixes https://gitlab.com/kicad/code/kicad/issues/9772
2021-11-25 23:42:13 +00:00
Wayne Stambaugh 06f206104d Pcbnew: fix chamfered rectangular pad definitions in GenCAD exporter.
The pad comparison function was never updated when chamfered rectangular
and custom pads were added so if more that one variant of either of those
pad types existed in a design, only the first one would get generated and
assign to every pad of that type.

The custom pad primitive comparison has not be implemented so the exported
designs may be broken for custom pads.
2021-11-24 12:54:44 -05:00
Seth Hillbrand b022b314a4 Account for pad hole is BBox
The bounding box is used for hit testing.  If the hole is arbitrarily
larger than the pad, we need to allow the user to properly select it
2021-11-03 14:33:44 -07:00
Jeff Young 22ba640c2b Remove locking from footprint editor.
Fixes https://gitlab.com/kicad/code/kicad/issues/9496
2021-10-31 16:33:03 +00:00
Jeff Young 1abd45ac15 Report nets on pads. 2021-10-29 00:17:06 +01:00
Wayne Stambaugh 1f7fd436a2 Move board object polygon code into the object source files.
Having the board object polygon code all defined in a separate file made
finding the polygon code for an object difficult to find.
2021-10-25 17:42:11 -04:00
Jeff Young 463b82cf46 Be very careful when "doing what I mean".
Just wanting a SMD pad isn't enough -- the user may have already
set SMD settings into the master pad and changing the SizeX is
then very unexpected.  Make sure the settings directly conflict
before making any "do what I mean" adjustments.

Also fixes the parent-footprint info when no parent exists.

Also gives a better title to the dialog when used to edit the masterPad
properties.

Fixes https://gitlab.com/kicad/code/kicad/issues/9427
2021-10-20 08:59:25 +01:00
Seth Hillbrand 07b9e2ee51 Fix errant debug message
__WXDEBUG__ is only for internal WX debugging and is always enabled even
on release builds because it is defined to be 0, 1 or 2.  Use DEBUG to
limit to debug builds

Fixes https://gitlab.com/kicad/code/kicad/issues/9392
2021-10-13 09:16:55 -07:00