Jon Evans
af58281a08
ADDED: Expand selection for graphics in PCB
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12032
2023-08-01 21:14:58 -04:00
Jon Evans
ca4d6e8d1d
Fix msvc being unhappy
2023-08-01 19:59:58 -04:00
Jon Evans
cc7d470f8b
PNS: Improve behavior of dragging vias
...
- Fall back to walkaround when drag fails
- Properly check collisions with holes
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15117
2023-08-01 19:03:04 -04:00
Jon Evans
9741d57447
Remove duplicate path for extracting project text variables
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15283
2023-08-01 17:25:34 -04:00
Jon Evans
2459949d0d
A BOARD may not always have a project
...
For example, if it's the footprint editor model
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15283
2023-08-01 17:19:21 -04:00
Seth Hillbrand
f3d65b5156
Revise method of selecting footprints in contrast
...
When working in high contrast mode, we want to be able to select a
footprint with only elements in, e.g. silk and fab layers.
The previous design for footprint IsOnLayer had one behavior of every
other element and a different behavior for footprints. This leads to
multiple bugs as new features use the overloaded IsOnLayer expecting it
to report if the element exists on a layer or not.
For footprints, we need a different routine to determine whether or not
to select the footprint when clicking on it. IsOnLayer will report if
the footprint has any elements on a specific layer but we don't want to
use the bbox for a hittest because large footprints with through hole
pads will exist on every layer and have an enormous bbox. Instead, we
filter footprints based on the hittest of each element. This behaves in
a more logical fashion, allowing you to select a footprint by clicking
on a visible element of that footprint.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15284
2023-08-01 10:43:13 -07:00
Mike Williams
65450d9b5d
Fields: don't unchanged fields as changed
2023-07-31 15:10:30 -04:00
jean-pierre charras
e188b5f8f4
APPEARANCE_CONTROLS, preset layers: re-allow storing object visibility in
...
a User preset, and use the last defined object visibility when switching to
a builtin preset
Fixes #15282
https://gitlab.com/kicad/code/kicad/-/issues/15282
2023-07-31 18:40:23 +02:00
Mike Williams
744452d092
Sch/PCB: allow back-updating schematic fields from PCB
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/15285
2023-07-31 10:38:43 -04:00
Roberto Fernandez Bautista
54f401c72c
Fix import of legacy stroked zone fill + add parsing of segments fills
2023-07-30 20:56:28 +02:00
John Beard
478df24f36
Fix fillets and chamfers when the original lines become zero-length
...
This needs the ITEM_MODIFICATION_ROUTINE to learn to delete items.
Condense the item change handlers into a single injected object
(ITEM_MODIFICATION_ROUTINE::CHANGE_HANDLER) and provide the basic
implementation that just takes some callables.
This simplifies the construction of the routines and also would make
a CHANGE_HANDLER object possible that can be reused between different
tools.
2023-07-30 15:12:28 +01:00
John Beard
da0daffa89
Remove more special-casing for fp-edit commit handling
...
In the EDIT_TOOL::ModifyLines method, there was some
remaining special-casing for FP childen commits.
One bit was put back by mistake (in
0b32ae3f4b
) because I thought I'd
left it out of the refactor. In fact it was removed slightly later in
1218f61d0a
.
THe other bit is omitting Modify commits in the FP-editor (what the
reinstatement of the above code was trying to cause). This shouldn't
be needed any more.
However, something is still incomplete here as the tools still don't
work correctly in the footprint editor. However, I don't think it's
substantially _more_ broken with the special casing removed and at
least it's less confusing.
Related to: https://gitlab.com/kicad/code/kicad/-/issues/15253
2023-07-30 15:10:30 +01:00
jean-pierre charras
abcd753bd3
PANEL_SETUP_BOARD_STACKUP: do not try to init params managed by PANEL_SETUP_BOARD_FINISH
...
Fixes #15288
https://gitlab.com/kicad/code/kicad/-/issues/15288
2023-07-29 09:43:32 +02:00
jean-pierre charras
60806edac0
Gerber export X3: fix an incorrect keyword ("route" must be "rout")
2023-07-27 20:11:04 +02:00
Seth Hillbrand
96a34e5b57
Consolidate Maximum clearance calculation
...
We were calculating the same thing in three locations and we missed
adding the clearance from the footprints in, resulting in bad fills and
missed drc errors (see QA addition)
2023-07-26 12:55:48 -07:00
Seth Hillbrand
812c56bdc7
Clarify NeighboringSegmentFilter
...
This doesn't affect behavior but makes the code more readable
2023-07-25 11:05:56 -07:00
jean-pierre charras
a16ab0aae1
Replace SHAPE_T::RECT by SHAPE_T::RECTANGLE: RECT creates a collision name
...
issue with a Windows header on msys2.
Change very similar to the commit 9a47b344
about class PAD_SHAPE.
No actual code change
2023-07-25 09:11:55 +02:00
Seth Hillbrand
000998ccae
When routing, check for board-level clearances
...
If the board-level clearance exceeds the max pad/track clearance, we end
up missing collisions in the router.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15162
2023-07-24 15:19:21 -07:00
Seth Hillbrand
32ad42a435
Add 3dconnexion driver version check
...
Re-enable 3dconnexion driver by default as we are able to gate the
driver versions
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13362
2023-07-24 18:09:52 +00:00
John Beard
0b32ae3f4b
Reinstate fp-editor-specific commit handling in fillet/chamfer tools
...
This check was omitted in the refactor of the fillet tool, and
resulted in a bug when undoing the action: the modified lines would
not be un-modified.
2023-07-23 14:48:31 +01:00
jean-pierre charras
dda9d6c86c
BOARD_NETLIST_UPDATER: Minor fix
2023-07-23 13:06:31 +02:00
Alex Shvartzkop
430da67222
Altium PCB import: support dashed outlines (Region kind 2)
2023-07-22 22:38:05 +05:00
jean-pierre charras
8425e5a0b7
footprint.cpp::GetBoundingBox( bool aIncludeText, bool aIncludeInvisibleText ):
...
Do not include invisible fields when aIncludeInvisibleText is false.
2023-07-22 11:48:17 +02:00
jean-pierre charras
878a67ca65
BOARD_NETLIST_UPDATER: fix incorrect handling of new fields added to a Fp
...
- the new field position/rotation is now the same as its footprint parent.
- it is added to the view.
2023-07-22 10:52:49 +02: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
John Beard
a61b9f4459
Pad dialog: respect IPC maximum pad radius
...
The IPC-7351C rule (which may be IPC 7352 now), is 25%, or
0.25mm, whichever is smaller. Currently the default ratio is 25%, which
is incorrect for pads with shortest edges over 1mm.
This also means that the "25%" default is applied in one place:
previously sometimes the value came from the default set in PAD,
rather than the value set by this dialog. While the PAD default isn't
changed here, this dialog no longer relies on that value for its
behaviour.
2023-07-22 00:45:36 +01:00
Josue
7f9742791a
Re-word `tent vias` value setting in board_setup and plot
...
Fix: https://gitlab.com/kicad/code/kicad/-/issues/15210
2023-07-21 17:56:46 -05:00
Seth Hillbrand
7fe83993cf
Be smarter about releasing lockfiles
...
If KiCad crashes or exits without deleting the lockfile, don't show the
warning message unless we are not the one who locked it or there are
other KiCad instances running locally.
This should catch 99% of the cases where the message is shown
incorrectly. There may be some corner cases where the lock file is
created on a network drive using two different machines with the same
name and same user but these cases should be (famous last words)
sufficiently rare as to not be observed in practice
2023-07-21 15:40:19 -07:00
Alex Shvartzkop
e7af4b86b8
Altium PCB: support solder/paste mask expansion rules.
...
- Writes expansion values to board design settings
- Imports footprint regions on Cu layers as pads
- Adds support for holes in non-Cu polygons in footprints
2023-07-21 20:03:03 +05:00
Alex Shvartzkop
448de72823
Fix reading legacy zone fills which were based on stroked polygons.
2023-07-21 17:11:09 +05:00
Alex Shvartzkop
ef66fe88ac
Altium PCB import: import holes in non-Cu polygons.
2023-07-21 08:03:03 +05:00
Alex Shvartzkop
eb6cd4cc5d
Altium PCB import: remove more invalid polygons.
2023-07-21 08:03:03 +05:00
Alex Shvartzkop
f29bacbccd
Altium PCB import: some tweaks for font sizes.
2023-07-21 05:08:11 +05:00
Alex Shvartzkop
02652437bf
Altium PCB import: fix garbage symbols in font names.
2023-07-21 05:08:11 +05:00
Seth Hillbrand
6a09cf3551
Refill legacy zone fills on open
...
Previous check only looked for the existence of a new (as of v6) flag
that controlled which strategy we took. Previous versions did not write
this flag and so will not hit the check. This works around a missing
version bump from when the feature was introduced.
2023-07-19 14:29:12 -07:00
jean-pierre charras
f8fcf3852f
revert a change committed my mistake (in commit aa3e2988
)
2023-07-18 17:14:51 +02:00
jean-pierre charras
aa3e298890
Kicad manager: build the PLUGIN_CONTENT_MANAGER only un request, not in
...
KICAD_MANAGER_FRAME Ctor. Two advantages:
- it is built after the splash screen is dismissed.
- if there are issues when creating the PLUGIN_CONTENT_MANAGER, this is more
easy to debug
2023-07-18 11:19:52 +02:00
Jeff Young
29bb51560c
Fix control enablement in global edit dialogs.
2023-07-17 18:30:07 +01:00
Jeff Young
a1de7a77f4
Improve informational hierarchy of PNS Router Settings dialog.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15182
2023-07-17 16:01:15 +01:00
Jeff Young
5e18287ff9
Re-implement some commented-out hole clearance checking in router.
2023-07-17 16:01:15 +01:00
Jeff Young
c3c7f731df
Fix usage of AUI SetAuiPaneSize() hack in FOOTPRINT_EDIT_FRAME.
...
This brings it in line with PCB_EDIT_FRAME, which seems to work
reasonably well.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14297
2023-07-16 22:29:21 +01:00
Jeff Young
c2e7827774
Override FOOTPRINT::GetCenter() to ignore text.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15209
2023-07-16 18:01:45 +01:00
John Beard
ab55684f0b
ADDED: Add step parameter to footprint pad renumbering
...
Also includes persisting settings for next dialog invocation
and use the TransferDataFromWindow function rather than per-field
accessor methods.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/10651
2023-07-16 15:37:12 +01:00
Jeff Young
a09a5cb641
More undo cleanup.
...
The symbol editor has few enough items that it will still be performant
if we always send a selected-item-modifed event. (As it turns out we
were doing that anyway as the check for child-modified flags didn't
also check for selected.)
2023-07-16 14:43:29 +01:00
Roberto Fernandez Bautista
cf0b719a4a
Fix some unreachable code msvc warnings
2023-07-16 15:41:05 +02:00
Jeff Young
581cbfc112
Don't treat a rule area as an edge cut in the router.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15200
2023-07-15 18:30:15 +01:00
Jeff Young
0446152d15
(Very) minor performance improvement.
2023-07-15 17:55:12 +01:00
Jeff Young
1218f61d0a
Implement undo/redo for footprint children.
...
Our special-cases to handle the fact that we didn't do this had far
outgrown the code necessary to actually handle it.
2023-07-15 17:37:31 +01:00
Marek Roszko
3233bbe0ba
Make exported date time strings use ISO8601 format
...
Also rename the function to be explicit on its result format
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15185
2023-07-14 23:24:12 -04:00
Jeff Young
c3222b0652
Clear edit flags on footprint children in footprint editor.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15199
2023-07-14 22:16:11 +01:00
Jeff Young
d02e94805a
Store original boardItem (before promoting ent.m_item to parent footprint).
2023-07-14 20:43:13 +01:00
Jeff Young
cbf685ad76
Clear owner of old watcher before resetting std::unique_ptr.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15173
2023-07-14 19:32:20 +01:00
Seth Hillbrand
f45883ac3d
Ensure watcher is valid
...
Call ordering appears to allow invalid m_watcher settings for MacOS, so
we need to check if m_watcher has been initialized before clearing
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15173
2023-07-14 09:11:08 -07:00
jean-pierre charras
3ac454153e
Pcbnew, footprint editor: fix crash due to a null pointer use
2023-07-14 15:13:17 +02:00
Josue Huaroto
4cad021ef4
Add Open preferences folder button in Preferences Dialog
2023-07-13 14:10:31 +00:00
Jeff Young
cf8294b5c2
Remove a bunch of blind (and a few redundant) static_casts.
2023-07-13 14:14:45 +01:00
Ian McInerney
ae60b57c3d
Add default parameter to PCB image placement action
2023-07-13 13:15:19 +01:00
jean-pierre charras
7ac0ca9c14
Pcbnew, undo_redo: Do not cast to BOARD_ITEM items that are only EDA_ITEM
...
A BOARD_ITEM is derived from EDA_ITEM, so the cast is not possible
Fixes #15177
https://gitlab.com/kicad/code/kicad/-/issues/15177
2023-07-13 10:53:50 +02:00
Ian McInerney
e82a58a12e
Changed: Allow filling/unfilling individual zones with no selection
...
The draft fill and single zone unfill would only work if something was
selected first, this allows them to call the selection operation to
request what is under the cursor. Also properly gate the operation to
not cause crashes/issues when the selection contains non-zone items.
2023-07-12 23:00:13 +01:00
Seth Hillbrand
dde017cdc2
Force remove tree watcher when setting
...
The lib watch on Mac may not actually remove the tree on DTOR, so we
need to force the removal. This also adds some additional debug flags
if the issue continues
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15173
2023-07-12 14:29:06 -07:00
Ian McInerney
a8f628d0df
Add virtual destructor for base class
2023-07-12 19:39:15 +01:00
John Beard
09c0f713cd
Add fillet and chamfer icons
2023-07-12 19:21:47 +01:00
John Beard
a72ab9f351
Put fillet, chamfer and extend in a submenu
2023-07-12 19:21:47 +01:00
John Beard
046d978ba7
ADDED: Pcbnew chamfer and extend tools
...
Using the new ITEM_MODIFICATION_ROUTINE system, drop in two new
tools: chamfer and line extend. These are two geometric operations
that are relatively common when editing footprints in particular.
Chamfer delegates the geometric calculations to a dedicated unit
in kimath/geometry.
2023-07-12 19:21:37 +01:00
John Beard
8e0e9ce752
Generalise fillet tool
...
Describe the actions of the fillet tools is a generic way, so that the
same general pattern can be used for other tools that modify shapes on
the BOARD.
Basically, an "ITEM_MODIFICATION_ROUTINE" is defined, which is
configured and called multiple times, calling back to the EDIT_TOOL when
it modifies or creates an item.
The motivation here is to make it easier to slot in new line-based
tools like chamfer, extend and so on without having to redo the
complicated item, selection and commit handling each time, and keep the
core "routines" simple and decoupled from the EDIT_TOOL's
internals.
This also resolves #15094 because the new commit handling does the right
thing when items were "conjured up" for the fillet (e.g. when a
rectangle is decomposed into lines).
Fixes : #15094
2023-07-12 19:21:26 +01:00
Seth Hillbrand
3030c80de7
Record hole knockouts in zone filler earlier
...
Spokes are placed across an entire pad when filling, so the hole
knockouts need to knocked out prior to deflating
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15160
2023-07-12 11:17:57 -07:00
Jeff Young
8f754c7c3e
A more performant and slighty more aggressive blob trimmer.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14462
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14107
2023-07-12 17:30:42 +01:00
Jeff Young
56752e9bad
Move some MRU paths from app to project.
...
Also augments Save As path updating to handle these newly-moved paths,
and to handle absolute paths that point into the project directory.
2023-07-12 17:30:42 +01:00
jean-pierre charras
2e7db309bd
Fix typo
2023-07-12 17:24:03 +02:00
jean-pierre charras
b47f172e57
PCB_VIA::SetLayerSet( LSET aLayerSet ): fix bug: it must consider only copper layers.
...
Its purpose is to initialize the top and the bottom copper layers connected
by this via. So only copper layers in LSET must be analyzed.
2023-07-12 13:02:05 +02:00
Jeff Young
be63e1824e
Create filled polygons when centerline is chosen.
2023-07-12 10:41:46 +01:00
jean-pierre charras
2cb23bd43a
VIA on solder mask: fix incorrect size (radius) of displayed mask
2023-07-11 17:35:30 +02:00
jean-pierre charras
74c5f5a054
Ensure a layer exists before using it.
...
Fixes #15170
https://gitlab.com/kicad/code/kicad/-/issues/15170
2023-07-11 16:19:46 +02:00
Jeff Young
c3d10084b9
ADDED footprint associations dialog.
2023-07-11 14:52:05 +01:00
Mike Williams
3a7de82243
PCB: respect styling settings when inserting footprint from editor
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/15155
2023-07-11 08:16:48 -04:00
jean-pierre charras
ab4535f01b
Pcbnew, show solder mask on VIAS: refinement: take in account the mask expansion.
2023-07-11 11:07:50 +02:00
Jeff Young
879e6c302d
Redraw via mask layers when switching Tented Vias on/off.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15164
2023-07-10 23:29:54 +01:00
Ian McInerney
aab8d2b036
Give autocomplete routing a default parameter
...
Fixes KICAD-2M4
2023-07-10 19:41:03 +01:00
Jeff Young
8f5b7569d1
Split StyleFootprints into separate bools for fields vs text & graphics.
...
Also moves the settings from Board Setup to Preferences > PCB Editor.
Also collapses Track Drag Mode from radio buttons to a choice menu to
save space and allow it to be with the other editing action modes.
2023-07-10 17:15:57 +01:00
Jeff Young
db61fe03b3
Prefer MRU path to LastImportExportPath for importing footprints.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15102
2023-07-09 22:28:26 +01:00
Jeff Young
df63ca0189
Save a bit of space in FP 3D preview by moving board thickness to dlg.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13896
2023-07-09 20:36:55 +01:00
jean-pierre charras
bdaad32dc8
Pcbnew: fix crash when trying to delete a DIMENSION living in a footprint
...
Fixes #15156
https://gitlab.com/kicad/code/kicad/-/issues/15156
2023-07-09 20:02:56 +02:00
Jeff Young
a66360525a
Broaden "Style footprint fields" to cover graphics as well.
...
Also cleans up the layout of the symbol & fp properties dialogs.
Also fixes the background colour of the link textEdit controls on Mac.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8161
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15152
2023-07-09 12:45:55 +01:00
Mike Williams
cc7798745e
Board Settings: control styling of footprint fields
...
Can use library values or board default settings. Defaults to board
default settings.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/8161
2023-07-08 19:58:11 -04:00
Jeff Young
1d0a5ca34b
No point in having a RATSNEST_VIEW_ITEM in FP editor, viewer, etc.
2023-07-08 22:54:14 +01:00
Jeff Young
5bf257cdf6
Don't blindly cast to PCBNEW_SETTING: we may be in CVPCB....
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15153
2023-07-08 22:50:22 +01:00
Mike Williams
bfc3dcbe26
Footprint Editor: don't override field text sizes in editor
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/15134
2023-07-08 16:50:15 -04:00
StuartTylerRelytDesigns
d26aa7dc20
Pcbnew moveIndividually ctrl-M mangles 2+ tracks
...
CHANGED: moveIndividually ctrl-M not mangle tracks and add grid snapping
Fixes https://gitlab.com/kicad/code/kicad/issues/15124
2023-07-08 09:11:53 +00:00
Jeff Young
dc838bc50f
Formatting.
2023-07-07 23:41:58 +01:00
Jeff Young
9d9344a815
Save, clear, and restore selection around a footprint reload.
...
Also fixes a bug with the footprint's UUIDs getting reset.
2023-07-07 23:41:58 +01:00
Seth Hillbrand
954b265839
Check for zone-zone overlap
...
Instead of just checking for the zone outline, we adjust to check the
full fill area of the zones for intersection and overlaps
2023-07-07 11:52:25 -07:00
jean-pierre charras
27072e52f7
Fix a compil and Coverity warnings
2023-07-07 10:28:01 +02:00
jean-pierre charras
4f7e9bead5
Fix a typo than can create a crash
...
Fixes #15126
https://gitlab.com/kicad/code/kicad/-/issues/15126
2023-07-07 10:17:02 +02:00
John Beard
ef8cf2d12b
Avoid inheriting for POSITIONING_TOOLS_MENU
...
This only uses the public interface of CONDITIONAL_MENU,
so we can just make on of those and save declaring a wrapper
type.
2023-07-06 21:11:51 +01:00
Mike Williams
efb452df37
PCB: selectionCursor can optionally take a filter list
...
Make sure we pass a default nullptr parameter if we want everything.
2023-07-06 11:25:53 -04:00
Mike Williams
a1f42b823f
PCB: drop unused lockable items list
...
Unused by any code, and list is incorrect anyway.
2023-07-06 11:25:41 -04:00
Kuba Sunderland-Ober
3b261256e7
Use static casts between related classes.
2023-07-05 10:20:18 +00:00
Ian McInerney
50e0a3a500
Move layer ID to action mapping to PCB_ACTIONS
...
This mapping function is better suited for a method of the actions
itself rather than just a helper function in one file.
2023-07-05 11:09:34 +01:00
Alex Shvartzkop
a80ac8286d
EAGLE PCB import: fix footprint text alignment.
2023-07-05 02:56:06 +03:00
jean-pierre charras
33e489c4a8
Pcbnew, PlotInteractiveLayer(): do not print useless info in a PDF plot.
...
It makes this ifo more easily readable.
- Remove duplicate properties
- Do not plot empty properties
- do not plot lib descr and keywords, useless in a pdf plot.
2023-07-04 20:02:28 +02:00
Alex Shvartzkop
e892405738
Altium PCB import: read and apply TrueType font names to text.
2023-07-04 13:29:42 +03:00
Alex Shvartzkop
536744d37a
Altium PCB import: fix text positioning when not bottom-left aligned.
2023-07-04 13:16:25 +03:00
Alex Shvartzkop
847f538192
Altium PCB import: turn off Keep upright for footprint texts.
...
Looks like it was set to true by mistake.
2023-07-04 13:11:43 +03:00
Alex Shvartzkop
b09ab2daab
Don't duplicate footprint bookmarks when plotting multiple PCB layers.
2023-07-04 08:08:52 +03:00
Jeff Young
67c9d3932b
Another attempt to fix qa error.
2023-07-03 16:26:20 +01:00
Jeff Young
def1a9f39c
Add SHORT_NET_NAME processing to footprint variable resolution.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15095
2023-07-02 10:58:10 +01:00
Jeff Young
bcfb6e4888
Fix diagrams of meander dimensions.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10073
2023-07-01 17:06:00 +01:00
Jeff Young
6da71e5d24
Allow routing to a free pad (even if it has a hole).
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15093
2023-07-01 14:23:38 +01:00
Jeff Young
63daf336b8
Formatting.
2023-07-01 14:23:38 +01:00
jean-pierre charras
2c068ab86d
Fix incorrect comment. No code change.
2023-07-01 14:17:57 +02:00
Jeff Young
9af065684b
Show Properties Manager menu entry for FP Editor.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15088
2023-07-01 12:01:35 +01:00
Jeff Young
9ff33e5ec6
Remove BOARD_COMMIT( TOOL_MANAGER ).
...
It initializes both m_isFootprintEditor and m_isBoardEditor to false,
causing all sorts of trouble.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15072
2023-07-01 11:52:46 +01:00
jean-pierre charras
011a8f29a3
Pcbnew, Update footprint: fix broken initialization of fields (especially ref and value)
...
- Revert commit 86e0e1cc
, broken
- add comments to avoid a similar mistake
- ensure Reference and Value are correctly handled.
Fixes #15091
https://gitlab.com/kicad/code/kicad/-/issues/15091
2023-07-01 12:29:02 +02:00
Jeff Young
eb8994fde5
Disable locked in the FP Editor.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15089
2023-06-30 20:51:18 +01:00
Jeff Young
7ed5963b4f
Disable positioning tools when a move is in progress.
...
Also fixes a typo in EDIT_TOOL::doMoveSelection().
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15090
2023-06-30 20:37:03 +01:00
Jeff Young
773e1a1ab6
Actions with a COMMIT must be run synchronously.
...
Note that "immediate" doesn't mean quite the same thing: while it will
enter the tool immediately, it won't necessarily finish the tool during
the call if the tool has an event loop. So for something like Rotate
"immediate" and "synchronous" have the same behaviour, but for something
like Move they do not.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15085
2023-06-30 18:57:37 +01:00
jean-pierre charras
8d46ed3c72
PCad importer: fix segfault in PCAD2KICAD::PCAD_ARC::AddToBoard
...
Fixes #15086
https://gitlab.com/kicad/code/kicad/-/issues/15086
2023-06-30 17:51:03 +02:00
Jeff Young
dd83217062
Add DRC testing for copper graphic to zone fill collisions.
2023-06-30 14:04:20 +01:00
Ian McInerney
533d7531a1
Via routing actions need to use int flags
...
The actions the router uses for via placement can be a combination of
enum values, so the actions must use an int parameter instead of the
enum type.
Fixes KICAD-2DS
2023-06-29 23:21:15 +01:00
qu1ck
ec94439df4
Footprints swig API: access shown text in fields
2023-06-29 20:36:27 +00:00
jean-pierre charras
5b42348834
Pcbnew: shows the UUID of a footprint in DIALOG_FOOTPRINT_PROPERTIES.
...
This is an important property of a footprint, but it is never shown to
a user, although it is used in a lot of cases.
2023-06-29 12:36:20 +02:00
Ian McInerney
30f20a694d
Give default parameter to net highlight/selection events
...
Fixes KICAD-2C7
Fixes KICAD-2C3
2023-06-29 00:17:12 +01:00
Ian McInerney
0de6fb03ba
Give updateLocalRatsnest action a default parameter
...
Fixes KICAD-2BX
2023-06-29 00:17:12 +01:00
Ian McInerney
459e6e192a
Give placeFootprint action a default nullptr parameter
...
Fixes KICAD-2BT
2023-06-29 00:17:12 +01:00
Ian McInerney
d923b871d7
Remove group reference when exporting individual footprints
2023-06-29 00:17:12 +01:00
Jeff Young
1411b09178
Remove EDIT_TOOL's quasi-global BOARD_COMMIT.
...
It had several encapsulation leakage issues, as well as poorly-defined
behaviour of undo for chained-actions (append-to-board, and then rotate
while moving, for instance).
2023-06-27 17:04:18 +01:00
jean-pierre charras
af71308184
pcb_parser and pcb_plugin: fix incorrect handling of rotation of PCB_TEXTs
...
in footprints when the text angle is 0 but the fp orientation is not 0.
It was due to the fact angle 0 is not written in file and use the default
value of the created PCB_TEXT in footprint, that is not always 0
Now the angle is always written in file.
Fixes #15054
https://gitlab.com/kicad/code/kicad/-/issues/15054
2023-06-27 08:53:04 +02:00
Seth Hillbrand
f3122184df
Remove existing footprint when force-reloading
...
Needs to clear the existing footprint in ReloadFootprint prior to
loading the new one.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15040
2023-06-26 17:04:03 -07:00
Ian McInerney
2fb6f19a84
Separate immediate and delayed action dispatch
...
Using a boolean argument just leads to a lot of trailing booleans in the
function calls and is not user friendly. Instead, introduce PostAction()
to send an action that runs after the coroutine (equivalent to passing
false or the default argument), and leave RunAction as the immediate
execution function.
2023-06-27 00:57:59 +01:00
Jeff Young
3bdc66d3ed
Save project to disk whenever we save the board to disk.
...
This prevents data loss in the event of a subsequent crash.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14991
2023-06-26 16:59:47 +01:00
jean-pierre charras
7e8070b700
pcb_parser: fix incorrect handling of rotation of PCB_TEXTs in footprints.
...
Fixes #15054
https://gitlab.com/kicad/code/kicad/-/issues/15054
2023-06-26 11:27:20 +02:00
jean-pierre charras
44810e8c09
footprint reader: fix broken handling of "Keep Upright" option.
...
texts inside footprints must have this option ON by default.
When disable, the keyword "unlocked" must be in field description.
2023-06-25 12:44:33 +02:00
Jeff Young
493828cc6b
Eradicate a bunch of calls to dyn_cast.
...
Also deletes PAD::GetParent() which fails to look for parent footprint
through groups.
2023-06-25 11:10:07 +01:00
Jeff Young
300a60e88e
Eradicate a bunch of calls to dyn_cast.
2023-06-25 11:10:05 +01:00
jean-pierre charras
994459fd47
fp editor: fix a crash due to a null pointer when reading a .kicad_mod file
...
It happens if the footprint has some non mandatory fields (user fields).
2023-06-25 10:16:23 +02:00
jean-pierre charras
1094cc5331
Fix issues related to the splash screen when no config file found:
...
- do not show it before the application is actually started.
- hide the splash screen before displaying dialogs.
Fixes #15047
https://gitlab.com/kicad/code/kicad/-/issues/15047
2023-06-24 18:09:43 +02:00
Jeff Young
b3d7aea4df
dyn_cast<PCB_TEXT*> won't find PCB_FIELDs.
...
We really should get rid of dyn_cast entirely....
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15052
2023-06-24 15:48:57 +01:00
Ian McInerney
b8e9544828
Remove temporary footprint from pcb group before deletion
...
Bounding box computation uses a temporary footprint, but the clone
operation keeps the group information. We can't delete a footprint if it
has group information, so just delete the group information.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14909
2023-06-24 00:04:06 +01:00
jean-pierre charras
f56ea370be
PCB_FIELD::GetCanonicalName() must return the canonical name (not a translation)
2023-06-23 18:48:11 +02:00
jean-pierre charras
d8034b9c15
Revert "PCB Fields: save untranslated names"
...
This reverts commit b47fcac666
.
The root issue was a bug in SCH_FIELD::GetCanonicalName(), now fixed.
2023-06-23 17:48:19 +02:00
Mike Williams
b47fcac666
PCB Fields: save untranslated names
2023-06-23 09:18:55 -04:00
Tomasz Wlostowski
61391e3984
router: take holes into account when building the restricted items set for collision search
2023-06-23 14:52:45 +02:00
Jon Evans
7804c2177c
Do not force focus on dataview in RC dialogs
...
On GTK, this causes the first item to be selected, firing the
selection handler and causing unwanted side effects.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/11925
2023-06-23 08:09:53 -04:00
Jon Evans
504e02192c
Relax handling of duplicate netclasses in Altium parser
...
There are some "good" boards that have this for some reason
2023-06-23 08:09:53 -04:00
Jon Evans
3a0f8214fa
ADDED: Properties panel for schematic editor
...
Initial infrastructure work; follow-ons will add more
properties for schematic items.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6351
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14105
2023-06-22 22:32:24 -04:00
Jon Evans
39073642a7
Properties: disable pad y-size when circular
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15038
2023-06-22 19:19:33 -04:00
Tomasz Wlostowski
a0a68d198c
router: when no collision search context is provided, assume differentNetsOnly is true
2023-06-22 23:52:21 +02:00
Tomasz Wlostowski
bd5954242e
router: provisional fix for 14926
2023-06-22 16:52:34 +02:00
Wayne Stambaugh
a5411218a2
Fix minor board file white space formatting issue.
2023-06-21 13:42:24 -04:00
Jeff Young
0fde88eefc
Protect custom rule function caches from transient items.
2023-06-21 18:14:41 +01:00
Jeff Young
94a23971cc
Performance improvements.
2023-06-21 17:00:32 +01:00
Kuba Sunderland-Ober
b60f7d4136
Make comparison operators const.
2023-06-21 08:49:26 +00:00
Mike Williams
fa84575510
FP Text Grid: avoid ambiguous fallthrough
...
Works, but bug-prone and suspicious looking.
2023-06-20 19:23:29 -04:00
Ian McInerney
f14feafc6b
Convert selection vector to EDA_ITEMS for base tool call
...
The base tool expects a generic EDA_ITEMS, but the existing vector
doesn't easily cast, so add a temporary one.
2023-06-20 21:52:50 +01:00
Ian McInerney
f899d9676f
Remove unneeded parameter from tool call
2023-06-20 21:52:50 +01:00
Ian McInerney
0a3b6c2d23
Fix call to properties when editing newly placed dimension
...
The edit is intended to be on the newly placed dimension, but the actual
properties tool doesn't take an item, so it was always looking up the
item to edit using the current selection/cursor position. Make this more
robust by just calling the edit properties directly on the item.
2023-06-20 21:52:50 +01:00
Ian McInerney
3c24ddd8cc
Fix passing CLIENT_SELECTION_FILTER through the tool framework
2023-06-20 21:52:50 +01:00
Ian McInerney
480223f67c
More RunAction specialization
2023-06-20 21:52:50 +01:00
Ian McInerney
3718ecfcd8
Simplify forcing action parameters to have a specific type
2023-06-20 21:52:50 +01:00
Ian McInerney
07cc85e76c
Fix more places where casts into RunAction were happening
2023-06-20 21:52:50 +01:00
Ian McInerney
8f3d159905
Update the net highlight action to properly use the action parameters
2023-06-20 21:52:50 +01:00
Ian McInerney
8b833211b5
Add parameter to repair board action
...
The tool checks for a boolean action, so default to giving false (which
makes it run in interactive mode).
2023-06-20 21:52:50 +01:00
Ian McInerney
b04e54dbea
Switch TOOL_EVENT and TOOL_ACTION to have a std::any parameter
...
Using std::any from C++17 allows for proper type handling in the
parameter field, removing the need for casting to void* and then casting
the void* to the desired type.
2023-06-20 21:52:50 +01:00
Mike Williams
1d26b454f4
SCH -> PCB Fields: bump file versions
2023-06-20 18:34:52 +00:00
Mike Williams
86e0e1cccb
PCB, Change Footprint: actually update text attributes
2023-06-20 18:34:52 +00:00
Mike Williams
a24c55affe
PCB Fields: fix up python, API
...
Remove SetFields from both symbol and footprint, it doesn't handle
mandatory fields and is unlikely to ever be safe.
2023-06-20 18:34:52 +00:00
Mike Williams
85c633eb00
QA: PCB Fields bug fixes
2023-06-20 18:34:52 +00:00
Mike Williams
85f889bc19
Fields: Description now mandatory
...
Propagate from symbols to footprints, footprints keep a library
description, too. (GetLibDescription())
2023-06-20 18:34:52 +00:00
Mike Williams
636db607c1
Footprints: upgrade Sheetpath and Sheetfile to tagged items in file
...
Rather than loose kv properties.
2023-06-20 18:34:52 +00:00
Mike Williams
993bb84240
PCB_FIELD: bug fixes
2023-06-20 18:34:52 +00:00
Mike Williams
b81fcaeaf7
PCB Fields: use validators in dialogs, restrict editing of footprint
2023-06-20 18:34:52 +00:00
Mike Williams
ad7d9ec956
PCB: footprint properties dialog fields fixes
2023-06-20 18:34:52 +00:00
Mike Williams
74606cda9c
PCB: text properties dialog should indicate "Offset X/Y:" properly
2023-06-20 18:34:52 +00:00
Mike Williams
78f1040f33
PCB Fields: register with properties manager
2023-06-20 18:34:52 +00:00
Mike Williams
00f6f5011c
PCB Fields: add saving / reading support to PCB files
...
Use common text effects parsing with PCB_TEXT
2023-06-20 18:34:52 +00:00
Mike Williams
6d93950dcc
PCB: abolish TEXT_TYPE::TEXT_is_*
...
PCB_TEXT is now always what was formerly TEXT_is_DIVERS and PCB_FIELDs
now what mandatory field type they are already.
2023-06-20 18:34:52 +00:00
Mike Williams
37837dc392
PCB: introduce PCB_FIELD_T
2023-06-20 18:34:52 +00:00
Mike Williams
a859b25d2c
PCB: convert footprints to use PCB_FIELDs for fields from schematics
2023-06-20 18:34:52 +00:00
Mike Williams
968785382e
PCB_FIELD: add new field item similar to SCH_FIELD
2023-06-20 18:34:52 +00:00
Mike Williams
8e13f2d535
Netlist/Footprints: parse fields out of netlist into footprint
...
The properties section duplicates all of these fields, but also contains
a large amount of other cruft.
2023-06-20 18:34:52 +00:00
Mike Williams
bd5d3533d8
Footprints: rename Fabrication Attributes to just Attributes
...
Makes it consistent with the Symbol attributes that are often
synchronized.
2023-06-20 18:34:52 +00:00
Mike Williams
028f500cd9
Footprints: rename properties to fields for consistency with symbols
2023-06-20 18:34:52 +00:00
Jeff Young
40abb013ec
Don't consider a group to be on a copper layer.
...
Its members can be on copper layers, but the group itself isn't on any
layer.
Also fixes a bug where we were trying to clone TRIANGULATED_POLYGON::TRI
shapes as indexable sub-shapes. (The TRI only has indexes into its
parent, so cloning it will only result in segfaults down the line.)
Also fixes a bug where we weren't including copper items inside groups
when checking footprint net ties.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15021
2023-06-20 18:13:21 +01:00
jean-pierre charras
21f2f98270
drc_test_provider_connection_width: fix crash due to a null pointer.
...
Fix a crash (tested on W10 - MSYS2) when running DRC on the board
attached to issue #15005
Fixes #15005
https://gitlab.com/kicad/code/kicad/-/issues/15005
2023-06-20 16:32:07 +02:00
Jeff Young
4473ebb02d
Clear arcs before deflating area outline.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15007
2023-06-20 14:19:21 +01:00
Jeff Young
8c29091001
Add a "hyperzoom" mode for debugging "up close".
2023-06-20 14:19:21 +01:00
Jon Evans
7d6cb4e77b
DRC markers should not be considered inactive layers
2023-06-19 21:58:08 -04:00
Jeff Young
b1cdcca9e6
Use hypertext link for Edit Ingored Tests in both ERC and DRC.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15010
2023-06-19 23:53:42 +01:00
Jeff Young
30336b2fe3
Unify go-back-one-step processing for drawing tools (and router).
...
Also warps mouse on all go-back-one-step operations for better feedback.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14981
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9985
2023-06-19 17:14:32 +01:00
Jeff Young
252769d53e
ADDED "clear color" command to Appearance/Nets context menu.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14451
2023-06-19 17:14:32 +01:00
Jon Evans
55c00f1845
ADDED: Initial support for importing Solidworks PCB files
2023-06-19 11:57:33 -04:00
jean-pierre charras
9537fd4e45
Pcbnew, graphic importer: convert arc with large radius to segment.
...
Arcs having a too large radius cannot be safely handled.
The criteria (not perfect) is radius < INT_MAX/2 to use arcs
Fixes #14210
https://gitlab.com/kicad/code/kicad/-/issues/14210
2023-06-19 10:43:30 +02:00
Jeff Young
ecb2fcd559
Don't trip over null strings.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14989
2023-06-18 20:28:11 +01:00
Jon Evans
b424dc11e1
Hotkey feedback for inactive layer display mode
2023-06-17 23:47:26 -04:00
Jeff Young
fb40c202a1
Refine track dangling test.
...
Turns out Clean Up Tracks and Vias wants a different answer from DRC.
2023-06-17 22:56:57 +01:00
Jeff Young
4e3730f653
Track not dangling if entirely covered by pad.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14211
2023-06-17 21:13:30 +01:00
Jeff Young
3b8cc3a3ac
Tab-order fix provided by aris-kimi.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9406
2023-06-17 18:41:17 +01:00
Jeff Young
1c7971c4dc
Cleanup.
2023-06-17 18:12:13 +01:00
Jeff Young
9fbaa238a2
Don't create 22.5-degree gateways if we're not cardinal or diagonal.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14984
2023-06-17 16:05:35 +01:00
Jeff Young
cf4f0723f8
Select first unassigned symbol when running CvPCB.
...
Also cleans up some dead code, and makes more use of sharing.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9938
2023-06-17 12:44:59 +01:00
Jeff Young
ef6866757e
Treat undo as backspace and/or escape when drawing. Ignore redo.
...
Undo == backspace when drawing a polygon or chained lines. Otherwise
it's an escape.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14961
2023-06-16 22:08:21 +01:00
Alex Shvartzkop
d3be62f644
Adapt panels to PAGED_DIALOG sizing algorithm.
...
Also some cosmetic fixes (GTK).
2023-06-16 19:12:37 +03:00
Alex Shvartzkop
f5da58e17d
PAGED_DIALOG: allow setting initial size in ctor.
2023-06-16 18:53:00 +03:00
Jeff Young
da558f57d4
Don't leave selection lying around when swapping out footprints.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14971
2023-06-16 16:29:52 +01:00
Wayne Stambaugh
285f8a0e59
Command line PCB gerber export fix and improvement.
...
The --board-plot-params argument was never parsed so it was always ignored.
[ADDED] A '--no-protel-ext' option to allow plotting gerbers with the KiCad
file extension (gbr) instead of the Protel gerber file extensions.
(cherry picked from commit 4e79d1ecdd
)
2023-06-16 07:17:39 -04:00
jean-pierre charras
c37332bdb3
Plot Solder mask layer: do not add items on edge_cut, but not on mask layer
...
it happened only when creating a solder mask plot with a minimum thickness.
This was a legacy option, incorrect now.
Fixes #14960
https://gitlab.com/kicad/code/kicad/-/issues/14960
2023-06-16 09:47:58 +02:00
Ian McInerney
63e91366e2
Add variable initializations
2023-06-15 23:49:24 +01:00
Ian McInerney
b73cc7db4a
Fix a few accidental copies in loop iterators
2023-06-15 22:57:05 +01:00
Ian McInerney
753cc6679b
Remove temp items from its group before deleting them
...
The 1st level items being copied don't have their group information
copied, and we assert that it has been removed from the group on
deleting it, so we just reset the group membership to prevent the
assert.
Fixes sentry KICAD-22S
2023-06-14 23:33:41 +01:00
Ian McInerney
137640ac28
Remove group association before plotting board outline in drill map
...
The plotter doesn't care about the grouping, and we expect the item to
have no group on deletion, so temporary items like this shouldn't be
part of one.
(Sentry issue KICAD-24Y)
2023-06-14 00:26:46 +01:00
Yang Hongbo
fe1b1becef
Check visibility when switching layer in router tool
...
When routing and using layerNext (hotkey '+') to switch to next layer,
it will skip invisible layer, when click BUT_LEFT, the new line should
be in the same layer (visible layer)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14480
2023-06-13 09:46:12 -07:00
Jeff Young
9ed2458f00
Reset session drawing props after Board Setup.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14932
2023-06-13 11:06:10 +01:00
Marek Roszko
a87fada9e5
Minor tweaks to support wx3.3
2023-06-12 20:52:47 -04:00
Ian McInerney
1c138b4f3e
Rename function in Footprint wizard to prevent impoper override
...
The ReloadFootprint function now exists in the base class with 1
argument, but this frame already had a similar function with no
arguments. Rename this one to RegenerateFootprint to prevent warnings.
2023-06-12 23:14:56 +01:00
Jeff Young
782c73300b
Move drawing sheet datastructures to EDA_IU_SCALE.
...
Or mostly, at least. Plotters still define their own mils-to-iu scale.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14934
2023-06-12 22:34:25 +01:00
Jeff Young
b7f0aae006
Nullptr safety for UI Conditions.
...
We don't really control when these are called, so best not to assume
we've finished initialization of the frame/screen/document/whatever.
Possible fix for KICAD-KY.
2023-06-12 12:38:50 +01:00
Jeff Young
aa8a903940
Cleanup.
2023-06-12 11:14:27 +01:00
Jeff Young
a3754785df
BoardDesignSettings are owned by FOOTPRINT_EDITOR_SETTINGS in the FP Editor.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14925
2023-06-12 10:08:41 +01:00
CraftedNightmare
aa667bea0f
eeschema: Fix Search pane not remembering docking sizes and positions
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14120 for eeschema
Fixes that Show Search Panel Checkbox can get out of sync when restarting
eeschema while the search pane is active
2023-06-11 20:23:24 +00:00
CraftedNightmare
d94e9b31b1
Fix Search pane not remembering docking sizes and positions
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14120
2023-06-11 20:23:24 +00:00
Jeff Young
93789e75b9
Re-create missing exclusion markers if DRC was cancelled.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14919
2023-06-11 12:14:27 +01:00
Jeff Young
3159391e28
Make sure infobar gets created earlier.
...
(restoreLastFootprint() might want it.)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14922
2023-06-11 11:40:51 +01:00
Jeff Young
4fc6047f91
Make sure infobar gets created earlier.
...
restoreLastFootprint() might want it.
2023-06-11 11:02:56 +01:00
Roberto Fernandez Bautista
3d1b96d6ca
Cleanup jobs handlers (+Fix build)
2023-06-11 00:12:53 +02:00
Roberto Fernandez Bautista
3f758711fd
Use external REPORTER for EESCHEMA_JOBS_HANDLER / PCB_JOBS_HANDLER
2023-06-10 23:35:32 +02:00
Jeff Young
fcb156c323
Make sure opposite-corner rects test the same.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14907
2023-06-10 22:30:04 +01:00
Jeff Young
96a221ceba
Refresh delete immediately; don't wait for next mouse motion.
2023-06-10 21:11:05 +01:00
Jeff Young
111d0a2c14
Check for proxy references and values in Selectable().
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14911
2023-06-10 17:47:29 +01:00
Jeff Young
f66b9f75a3
Allow EDA_COMBINED_MATCHER use in KiCad find architecture.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12532
2023-06-10 14:50:06 +01:00
Jeff Young
d18b0c62f6
Make FOOTPRINT_PREVIEW_PANEL a FPHOLDER.
...
Also makes sure it get its user_units set up.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14913
2023-06-10 13:36:17 +01:00
Roberto Fernandez Bautista
0159be8ddd
Fix build (broken in 90ff331c
)
2023-06-10 14:21:10 +02:00
Roberto Fernandez Bautista
90ff331c58
Refactor: Move static to be inside ZONE_SETTINGS
2023-06-10 12:03:41 +02:00
Alex
2450435131
Support --mirror option in "kicad-cli pcb export pdf"
2023-06-10 04:54:11 +03:00
Jeff Young
e698156975
Upgrade many editing actions to SCHEMATIC_COMMIT.
2023-06-09 22:41:47 +01:00
Jon Evans
3a2cc8f56f
Net Inspector: clear sort ordering during rebuild
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14697
2023-06-09 09:06:11 -04:00
jean-pierre charras
639da0eb5a
Fix a wxWidgets alert when deleting the last entry in a lib table.
2023-06-09 08:09:22 +02:00
jean-pierre charras
14c10d2a37
PANEL_FP_PROPERTIES_3D_MODEL: fix a wxWidgets alert.
...
Happens when there is no 3D model in 3D grid list, and when trying to add
a new 3D model, but canceling the 3D dialog file selector.
2023-06-08 17:46:38 +02:00
Tomasz Wlostowski
3667e4f6b2
router: correctly assign owner via/pad to its hole when committing the world state
...
fixes #14852
2023-06-08 11:57:23 +02:00
Jeff Young
d5b5a3eaf4
Add action info to Undo/Redo menus.
...
Note that this only works where a BOARD_COMMIT or SCHEMATIC_COMMIT is used.
(BOARD_COMMIT is used almost universally in PCBNew, but SCHEMATIC_COMMIT
has very little adoption in EEschema so far.)
2023-06-07 14:37:34 +01:00
Nils VAN ZUIJLEN
518741c52a
cli: add an option to the pcb exports for plotting negative svg and pdf
...
ADDED: The -n or --negative option for exporting negative svg or pdf plots
from kicad-cli. Example usage: kicad-cli pcb export svg -n -l B.Cu board.kicad_pcb
2023-06-07 13:28:52 +00:00
jean-pierre charras
f92271af2c
DIALOG_GEN_FOOTPRINT_POSITION: replace "Gerber (experimental)" by "Gerber X3"
...
Gerber position file is now not experimental, and is accepted by some board houses.
2023-06-07 11:43:30 +02:00
Jeff Young
9a757e8e44
Restore over-aggressive CLion cleanup.
2023-06-06 15:49:41 +01:00
Jeff Young
9fe00bb808
Cleanup. No (intentional) functional changes.
2023-06-06 12:30:35 +01:00
Jeff Young
c5e7d800a4
Back out earlier diamond-to-rectangle fix for one that's more targeted.
...
(And doesn't fail qa_pcbnew.)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14828
2023-06-05 21:26:37 +01:00
Jeff Young
4ea41174c3
Variable names and minor performance fixes.
2023-06-05 21:26:37 +01:00
jean-pierre charras
6eda60e503
Pcbnew: UI change: move layer selector from main toolbar to auxiliary toolbar
2023-06-05 20:31:18 +02:00
Jeff Young
aafbbb4c63
Clean up includes.
2023-06-05 11:01:10 +01:00
Jeff Young
7a3a8b67c1
Exclude redraws during closing (particularly of RATSNEST_VIEW_ITEM).
2023-06-05 11:01:10 +01:00
Jeff Young
29aabcf77e
Naming clarity. No functional changes.
2023-06-05 11:01:10 +01:00
Jeff Young
f3d3ade1dc
Increased mutex safety.
...
Don't even query the size() without having at least a shared_lock.
*May* prevent KICAD-4S, but seems unlikely.
2023-06-05 11:01:10 +01:00
Marek Roszko
b41606ecf7
Use the correct printf format for the move individually status text
...
Fixes sentry KICAD-1ZT
2023-06-04 21:08:13 -04:00
Jeff Young
0091b9f897
Prevent Sentry KICAD-MM crash.
...
It'd be nicer to know what happens, but we don't have a reproducible
case, so this "fix" will at least prevent that particular crash.
2023-06-04 23:00:44 +01:00
Jeff Young
1528f4700c
Treat canvas item as current when tree view contains no selection.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12702
2023-06-04 20:52:12 +01:00
Seth Hillbrand
e4fe27993e
Fix wxCHECK_MSG in DRC
...
The layers check needs to look for testing against technical layers for
those vias that pass the outer layers
2023-06-03 20:25:35 -07:00
Jeff Young
5875f89531
Centralize text size clamping.
...
Also introduces alg::clamp to improve readability of
std::max( min, std::max( value, max ) )
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14876
2023-06-03 20:29:51 +01:00
Wayne Stambaugh
bdee545841
Coverity warning fixes.
2023-06-03 07:28:17 -04:00
Seth Hillbrand
7f5d790610
Ensure we aren't trying to access a closed board
2023-06-02 15:47:46 -07:00
Jeff Young
97cf7c874e
Handle Altium dimension angles and non-unit suffixes.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13751
2023-06-02 18:30:16 +01:00
Jeff Young
3c8d2bfca5
Assertion checking for hole/parent ownership mismatch.
...
(This mismatch is the root of the problem in issue #14852.)
2023-06-02 18:30:16 +01:00
jean-pierre charras
9a47b34499
Replace PAD_SHAPE::RECT by PAD_SHAPE::RECTANGLE to avoid a collision NAME with a windows header on MSYS2, creating many compil warnings. No actual code change.
2023-06-02 12:18:24 +02:00
Tomasz Włostowski
3c3517cc36
router: can't add a clone of a VIA's hole when adding the via to INDEX - this will result in bogus colliding objects
...
This commit partially reverts deb3cbf8
. VIA and SOLID operator='s introduced in it do a good job but the cloning of holes in addHole() causes bogus collisions.
2023-06-01 22:47:02 +02:00
jean-pierre charras
db3cf4274b
Modify the order of an include to avoid a collision name with a windows
...
header that prevent Kicad build (msys2 specific)
2023-06-01 16:26:19 +02:00
Jeff Young
deb3cbf89b
Prevent use-after-free crashes by not fighting over who owns a HOLE.
...
The diff-pair placer creates DIFF_PAIRs on the stack, which have
VIAs in them, which have HOLEs in them. The HOLEs get put in the
NODE's index, and we then crash later when doing a collision after
the stack variable has gone out of scope.
The stack variable is also copied while doing a search for "best",
and without the operator= definitions the "best" and the "original"
both think they own the HOLE.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14852
2023-06-01 15:07:29 +01:00
Seth Hillbrand
c7758999af
Handle LOCKFILE logistics for ro
...
We need to check if a lockfile is valid to determine if we should
override the lock. Valid() is true if the lockfile couldn't be created
b/c of permissions or if the lockfile could be created and acquired.
2023-05-31 17:04:32 -07:00
Seth Hillbrand
aacf8f50bf
Remove unneeded headers from pcbnew_scripting_helpers.h
2023-05-31 15:54:46 -07:00
Jeff Young
ddd2cb005b
Don't allow setting a pad width or height of 0.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14278
2023-05-31 23:41:43 +01:00
Tomasz Wlostowski
7966126040
router: invalidate items freed by PNS::NODE in the clearance cache
...
This was causing intermittent shove hiccups/freezes as RULE_RESOLVER::GetClearance() could return a bogus clearance value, taking
a cached value for an item that does not exist anymore. If the allocator/stack accidentally reclaimed such item's address - we were getting
very nasty and difficult to reproduce misbehaviours of the shove algorithm. Hopefully this patch fixes this. More info in the comments.
Note to self - I'm still not fully convinced I want PNS::ITEM pointers as the cache key, probably a unique counter would be better here.
2023-06-01 00:01:15 +02:00
Seth Hillbrand
14f6e32c74
ADDED: Change watcher for libraries
...
When editing or viewing library symbols, the files are watched for
underlying changes. If any occur, the user is either prompted to reload
(if reloading would overwrite their current edits) or the file is
silently updated to the current version on disk.
This also sets a custom assertion handler to avoid unneeded crashes when
recieving invalid SAMBA packets and turns off assertions entirely when
running in release (non-debug) mode
2023-05-31 13:46:00 -07:00
Tomasz Wlostowski
15db42d9c8
router: fix use-after-free crash in drag walkaround mode
2023-05-31 22:20:28 +02:00
Tomasz Wlostowski
5100345c6e
router: prevent pushout/bogus collision of via with is own hole (or copper) when dragging
...
The root cause was not removing the original (pre-dragging) via from the world, comparing the ITEM::Parent() pointers of the items was only hiding the main issue.
This also fixes the PNSViaCollisions test in the qa/ suite.
2023-05-31 17:06:24 +02:00
Jeff Young
8baf2a832f
Make pad flipping work both from parent footprint *and* individually.
...
The last fix was for individual pads, but it broke when the whole
footprint was flipped for rotated footprints.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14829
2023-05-31 11:13:35 +01:00
Jon Evans
3783fc8f5a
Remove unused line
2023-05-30 20:06:18 -04:00
Jeff Young
4874537c40
Push/pop router tool for inline drag.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14832
2023-05-30 18:02:12 +01:00
Jeff Young
c36b0fcda7
Make sure 3D file browser is treated as modal by quit.
...
(Otherwise we crash when freeing it during the quit.)
2023-05-30 14:58:46 +01:00
jean-pierre charras
6b845b9054
Fix compil warnings and a wxWidgets alert.
2023-05-30 09:00:46 +02:00
Jon Evans
141cc85ff3
PNS: Work around collision checking issues in shove mode
...
Need to special-case shove mode since 942ee13c
introduced
collision checking in all modes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14836
2023-05-29 18:19:47 -04:00
Roberto Fernandez Bautista
bb90aa24b7
Add basic QA test to CADSTAR PCB footprint import
2023-05-29 23:29:28 +02:00
Roberto Fernandez Bautista
3b56b7bf68
Fix assert in PROPERTY_ENUM (ENUM_MAP<PCB_LAYER_ID> was not initialised)
2023-05-29 23:29:28 +02:00
Jeff Young
f5791f5dc6
Left some fixes out of previous commit.
2023-05-29 16:22:24 +01:00
Roberto Fernandez Bautista
9633c8af22
CADSTAR PCB: Fix regression in loading of thermal pads
...
Due to removal of SetPos0 in 28028c94
, we now don't need to compensate
for the position of the footprint while importing.
2023-05-29 16:41:47 +02:00
Jeff Young
65e53b8ecd
Move SHAPE_POLY_SET::Inflate's error spec from a seg-count to a max-deviation.
...
1) Also reorders parameters to make sure the compiler helps out.
2) This also makes it harder to mess up the discrepency between
BOX2I/wxRECT/etc::Inflate() and SHAPE_POLY_SET::Inflate.
3) Also fixes a couple of bugs where the corner strategy was passed
in as a segCount.
4) Also fixes a couple of bugs where the error wasn't forced to the
outside to match the ERROR_LOCATION.
5) Also fixes a couple of bugs where the seg count was specified
without regard to an already passed-in max deviation
2023-05-29 15:29:03 +01:00
jean-pierre charras
ef4dded915
PCB_TEXT::TransformTextToPolySet(): fix incorrect param when calling Inflate()
...
This incorrect value created hang when clicking on a pcb text.
2023-05-29 14:21:10 +02:00
Roberto Fernandez Bautista
dfebe516c5
CADSTAR PCB: Fix memory leak
2023-05-28 23:56:43 +02:00
Roberto Fernandez Bautista
a119bd604d
Refactor: Move DIALOG_PLUGIN_OPTIONS to common and use enum for event ID
2023-05-28 23:56:41 +02:00
Jeff Young
c71cf21e2f
Use rendered text to generate bounding box for knockout text.
...
Don't open-code knockout text shape generation in several different
places.
Make sure triangulated knockout text gets clearance added when
specified.
Collapse duplicated footprint text item plot routine (they're no
longer any different from plotting pcb text items).
2023-05-28 17:20:11 +01:00
Jeff Young
95a09f686b
Revert attempt to use drawing code to generate text bounding boxes.
2023-05-27 22:11:34 +01:00
Jeff Young
cb53a18ee3
Bug fixes for handling boolean flags in DRC rules.
2023-05-26 18:44:33 +01:00
Jeff Young
768fbf5af2
Give up on trying to calculate text bounding boxes.
...
It results in too many hacks strewn through the code. Just draw the
text and measure it.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14803
2023-05-26 18:44:33 +01:00
Jon Evans
942ee13cd1
PNS: Allow width-caused DRC violations at start of route
...
Also fix an issue where DRC violations introduced by the
width change action could be committed in walk/shove mode.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14805
2023-05-25 23:10:00 -04:00
Jeff Young
50da4e483e
Tailor inspector text properties for dimension objects.
2023-05-25 16:18:37 +01:00
Jeff Young
05fef51d81
Push rendering portion of text cache generation down into CALLBACK_GAL.
2023-05-25 11:25:32 +01:00
Jeff Young
1518ddde74
Push much of text var autocomplete down into SCINTILLA_TRICKS.
...
Shared code == fewer bugs. Well, in theory anyway....
2023-05-25 10:24:50 +01:00
Jeff Young
14f004d2a5
Hook up text variable auto-complete for PCBNew.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14777
2023-05-25 10:24:50 +01:00
Seth Hillbrand
48ecd742eb
Maintain file permissions when renaming
...
Temporary and autosave files do not neccessarily have the correct
permissions set to replace existing project files. This updates the
permissions to match the existing values where possible
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13574
2023-05-24 17:09:38 -07:00
Seth Hillbrand
122be418bb
Upgrade file locking
...
wxSingleInstanceChecker is meant for running programs, not file locking.
This implements an RAII class for file locking that stores the lock
files next to the file being locked, allowing it to be easily found and
removed. Also includes the ability to override the lock, with
information about the original owner
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14734
2023-05-24 13:51:54 -07:00
jean-pierre charras
76d66571e4
Pcbnew: fix crash when trying to save a board with a text with overbar and
...
using a non Kicad font
PCB_PLUGIN::formatRenderCache() was considering all shapes in cache are polygons,
but this is not true: some items can be stroke shapes.
Fixes #14804
https://gitlab.com/kicad/code/kicad/-/issues/14804
2023-05-24 18:21:50 +02:00
Jeff Young
2ac3f4cc9e
Undo strategy based on being in a footprint, not footprint editor.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14799
2023-05-23 17:56:12 +01:00
Jeff Young
56853a6209
Change teardrop edge shape to a checkbox.
2023-05-23 17:45:26 +01:00
Jeff Young
b442d769fd
Don't allow collisions with self.
...
The previous test didn't handle is-self-tests between a hole and
its override in a different NODE. When calculating the pushout
force we don't remove the via (and its hole) from the current
node until after the calculation, so we end up checking for
collisions between the new (cloned) via's hole and the original
hole in the root node.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14795
2023-05-23 14:10:22 +01:00
Wayne Stambaugh
5b539958a2
Fix track and via properties dialog radio buttons on GTK.
2023-05-22 13:54:13 -04:00
Jeff Young
00986484e0
Attempt to fix teardrop radio buttons on GTK.
2023-05-22 14:48:53 +01:00
Wayne Stambaugh
a13a49f45a
Fix clipped combobox entry in board editor text box dialog.
...
The layer combobox color swatch was clipped when the combobox was
closed when the dialog was launched. Setting the minimum width
resolved the issue. This may have been a GTK only issue.
2023-05-22 08:54:48 -04:00
Jeff Young
df763eaf88
Reconcile PNS router with DRC.
...
Hole-to-hole is only for drilled holes.
NPTH slots also get EDGE_CLEARANCE applied.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14771
2023-05-21 19:58:00 +01:00
Jeff Young
7e51077992
STL is your friend... until it's not.
...
Operator[] was creating an empty entry in the connectivity map,
fooling us into thinking the item had already been added.
Worryingly, this bug has been in there since 2017; a recent
change in teardrops just happened to expose it.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14781
2023-05-21 17:56:43 +01:00
Jeff Young
ff9a5b8373
Remove change from teardrop merge that wasn't needed for final impl.
2023-05-21 16:39:18 +01:00
Jeff Young
502da2d03c
Performance improvements.
2023-05-21 11:23:56 +01:00
Jeff Young
08a9d4b26f
ADDED preference for ratsnest thickness.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14708
2023-05-21 00:07:08 +01:00
Jeff Young
80aef37cc4
Don't consider shorted items when opitmizing ratsnest.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14715
2023-05-20 22:54:44 +01:00
Jeff Young
ea341289de
Fix uninitialized variable (Coverity report).
2023-05-20 21:10:09 +01:00
Marek Roszko
8a7044c3fb
Fix some more warnings
2023-05-20 08:00:16 -04:00
Alex
9d452a6097
Fix opening boards with deprecated features.
2023-05-20 07:39:01 +03:00
Jeff Young
4c59365867
Blind attempt to fix pns-debug-tool linking issue.
2023-05-19 19:26:03 +01:00
Jeff Young
8b1fd62d35
Make pad & via teardrops 1st-class citizens (props of the pad/via)
...
Change teardrop generation to rely more heavily on BOARD_CONNECTIVITY
for improved performance.
Add updating of teardrops on BOARD_COMMIT::Push().
Also converts m_CopperItemRTreeCache to std::shared_ptr.
We don't copy it around anyway, and having to create a new set
of std::unique_ptr's for each operation is likely to be more
expensive than std::shared_ptr's overhead.
2023-05-19 18:02:03 +01:00
jean-pierre charras
86c75cf261
Fix a compil issue.
2023-05-19 09:24:49 +02:00
Marek Roszko
3bf2fb2c0e
Fix more C5266 warnings
2023-05-18 22:08:50 -04:00
Jon Evans
27afd22bbf
Specctra: remove grouped tracks from group before cleaning up
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14763
2023-05-17 23:03:06 -04:00
Seth Hillbrand
0de24bfd59
Cleanup text alignment between version 6 and 7
...
Version 7 text alignment changed subtly for stroke fonts from version 6.
Additionally, the output has been different between screen and plotting,
leading to offset text in plotted output relative to the text shown on
screen.
This introduces a fudge factor in FONT::getLinePositions to correct the
offset in the plotting output relative to v6.
This also changes the SCH_PAINTER and PCB_PAINTER to correct the
relative offsets between GAL and PLOTTER classes. The source of these
offsets is atm unclear.
Fixes https://gitlab.com/kicad/code/kicad/issues/14755
2023-05-17 13:33:49 -07:00
Ian McInerney
20ec8ed303
Fix GitLab URLs to point to the correct project page
...
GitLab 16.0 removes support for URLs that don't contain /-/ after the
repository name, so the report bug feature and various links we had in
the source (including the git-fixes script) would lead to a 404 error.
See GitLab docs for deprecation/removal notice:
https://docs.gitlab.com/ee/update/deprecations.html?removal_milestone=16.0#legacy-urls-replaced-or-removed
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/14759
2023-05-17 11:23:00 +01:00
jean-pierre charras
66651327bd
STEP export: in board outlines, export Circles as Cylinders, round 2.
...
Other arcs (not 360 deg arcs) are still exported as polylines
2023-05-16 13:39:16 +02:00
jean-pierre charras
99bdb82dff
Revert "STEP export: in board outlines, export Circles as Cylinders."
...
This reverts commit 09515fe821
.
It does not pass a QA test
2023-05-16 09:59:53 +02:00
jean-pierre charras
09515fe821
STEP export: in board outlines, export Circles as Cylinders.
...
Other arcs (not 360 deg arcs) are still exported as polylines
2023-05-16 08:46:34 +02:00
Jon Evans
94130716a5
PNS: Collision search context may be null
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14741
2023-05-14 17:20:59 -04:00
Alex
d790865549
Make sure text bounding box exists when syncing PNS world.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14733
2023-05-14 13:40:14 +03:00
jean-pierre charras
22de1c8813
Teardrop dialog: refinements. Show a PROGRESS_REPORTER when refilling zones.
2023-05-12 10:06:20 +02:00
Steve Bollinger
85f4f0d6c8
pcbnew: switching track posture may not work on first attempt
...
If you drag a track out and connect to a pad then press the hotkey
to switch the track posture it may not switch because the track
posture selected when the pad was reached is different than the one
that the mouse trail placer drew. As the aspect switching is done
in the mouse trail placer it does not know that the line placer
already override the track.
To correct this, in LINE_PLACER::FlipPosture() if the aspect is not
currently manually forced then copy the current aspect from the
line placer to m_mouseTrailPlacer before calling the FlipPosture()
method of m_mouseTrailPlacer. This will only be done once per
dragging session as once the aspect is manually forced it remains
manually forced. This seems to fix the issue with no undesirable
side effects.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/12369
2023-05-11 23:35:21 +00:00
Jon Evans
89aae88e96
PNS: make sure context options are used in collideSimple
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14659
2023-05-11 16:48:15 -04:00
Jon Evans
2e60315959
PNS: Don't use clearance epsilon for calculating shove distances
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14707
2023-05-11 13:09:03 -04:00
Jeff Young
35158a7db9
Use track opacity for teardrops.
2023-05-11 15:57:44 +01:00
Jeff Young
4da6d5ff28
Add "generate raw teardrops" option to Add Teardrops dialog.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14711
Fixes https://gitlab.com/kicad/code/kicad/issues/14704
2023-05-11 15:47:42 +01:00
Jeff Young
daa3a1aae9
Revert addition of update-teardrops checkbox to DRC dialog.
2023-05-11 14:53:28 +01:00
Jeff Young
9481a218c7
Lazy loading of stackup UI widgets.
2023-05-11 14:37:48 +01:00
Jeff Young
3f44c811c7
Don't run onPageChanged() event handler during initialization.
2023-05-11 12:51:55 +01:00
Jeff Young
03c9b1c202
Move remainder of Board Setup to lazy loading.
2023-05-11 11:43:10 +01:00
Jeff Young
ddc6ecf7be
Lazy loading of Schematic Setup panels.
2023-05-11 11:43:10 +01:00
Jon Evans
932f171e96
Remove hard-coded safety margin from specctra output
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14713
2023-05-10 21:55:47 -04:00
Jeff Young
9ae8255202
Insta-prefs.
2023-05-10 18:14:14 +01:00
jean-pierre charras
31d613c746
Fix a few Coverity warnings (not initialized vars)
...
It also fixes a potential crash when closing Kicad.
2023-05-10 09:21:39 +02:00
Jeff Young
245c3ba6e4
CLang can't do a dynamic_cast across the KiWay.
...
Rely on DRC for text readability instead.
(Fixes Sentry KICAD-R4 on Mac, and the assert when opening
Preferences from a non-PCBNew-module window.)
2023-05-09 11:10:33 +01:00
Jeff Young
2dcbc10a09
Performance optimization.
2023-05-08 11:46:04 +01:00
Jeff Young
5b3798a370
Holes need a parent.
...
SetHole() handles all this for us. Make sure it's called.
Fixes https://gitlab.com/kicad/code/kicad/issues/14702
2023-05-08 11:41:12 +01:00
Jeff Young
f883b7fd4d
Fix layout inconsistencies in Gen Footprint Pos file dialog.
2023-05-08 10:57:43 +01:00
Jon Evans
b06f90335b
PNS: Remove holes when removing items with holes
...
Related to https://gitlab.com/kicad/code/kicad/-/issues/14702
2023-05-07 22:12:11 -04:00
Jeff Young
7978941fa8
Don't allow thickness of 0 in case of an empty stackup.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/10790
2023-05-07 22:24:40 +01:00
Jeff Young
5bf450a89f
Performance. (Coverity)
2023-05-07 14:58:44 +01:00
Jeff Young
2762fa7787
ADDED: track width & via size filters in Edit Track & Via Properties
...
Fixes https://gitlab.com/kicad/code/kicad/issues/13315
2023-05-06 23:20:39 +01:00
Jeff Young
7bb81f7573
Expand solder mask for pads *defined* to be on copper layers.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14693
2023-05-06 21:39:01 +01:00
Lucas Dumont
a22e6db982
Add Zone when dragging component
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14629
2023-05-06 09:32:38 +00:00
Jeff Young
b41d446f58
Fix a bunch more issues with sheetpaths and allowExtraText.
...
A sheetpath is required to correctly resolve text variables.
Depending on currentSheet is rife with bugs.
There are many places where we do *not* want to be prepending
field names to the field values, such as netlisting,
building PDF hypertext menus, etc.
Also, Find/Replace needs to work on unresolved text, as
that's what we're going to display (and if replace nuked
your variable references you wouldn't be happy).
2023-05-05 17:23:52 +01:00
Jeff Young
cd43dccb18
Add missing property to footprint texts table.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14357
2023-05-03 17:57:13 +01:00
jean-pierre charras
152f6d80e5
Use operator at() instead of [] to access a std::array item
...
It helps debug.
2023-05-03 16:40:40 +02:00
jean-pierre charras
631dde3ed1
Pcbnew: fix crash when loading a file having vias on connected layers only.
...
It was due to an access out of bounds in a std::array
Fixes #14668
https://gitlab.com/kicad/code/kicad/issues/14668
2023-05-03 16:06:32 +02:00
Jeff Young
0eac5c6748
Tighten lifecycle management of CN_ANCHOR/CN_ITEM.
...
In particular, when a CN_ITEM is freed set all its anchor's
item pointers to NULL. (The anchors have a separate
lifecycle due to being std::shared_ptrs.)
Hopefully fixes Sentry KICAD-KV.
2023-05-03 10:50:31 +01:00
Jeff Young
b53f337938
More accurate terminology for cross-probe settings.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/13088
2023-05-03 10:50:31 +01:00
Jeff Young
f27bc16d62
Cleanup API and use text bounding box for routing.
...
If someone wants to route around the text more tightly
they can now convert the text to polygons.
Fixes https://gitlab.com/kicad/code/kicad/issues/14252
2023-05-02 16:03:43 +01:00
Jeff Young
80f8cd2254
Commenting and formatting.
2023-05-02 14:16:02 +01:00
Jeff Young
df7d62fdd3
Added a sort-order dropdown to lib-tree filters.
...
Also simplifies the scoring algorithm so that it only
differentiates between exact-match, match-at-start and
any-match. The rest of the position-based matching
stuff is gone, as is the knowledge of the name vs the
keywords vs the description. All that is left to the
provider of the weighted search terms array.
2023-05-01 21:26:43 +01:00
Mike Williams
04a53ea40d
Picker Tools: make sure we know what tool we are
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/14621
2023-05-01 12:43:09 -04:00
Mike Williams
39cc686dc4
Back Annotation: add support for DNP and Exclude from BOM attributes
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/14584
2023-05-01 08:54:14 -04:00
Jeff Young
c31fb435e6
Add missing setting to Dimension Properties dialog.
...
Also fixes a bug where during file save we were calling
GetPosition() on the PCB_TEXT but getting the DIMENSION's
version.
Fixes https://gitlab.com/kicad/code/kicad/issues/8447
2023-04-30 22:45:19 +01:00
Jeff Young
2f9889ff62
Add settings for plotting PDF property popups.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14450
2023-04-30 18:10:04 +01:00
jean-pierre charras
096af19d9a
Minor fix and cosmetic change:
...
- SCH_SYMBOL::GetMsgPanelInfo(): slighly change the displayed lines to allow
longer strings in Description and Keywords
- panel_setup_rules_help.md: fix incorrect html link (URI), creating ERR 404
2023-04-30 17:37:30 +02:00
Jeff Young
1c6b765ba5
Formatting and cleanup.
2023-04-30 13:43:25 +01:00
Jeff Young
af7753c7cd
Record parent rule for DRC assertions.
...
(Particularly important if the rule specified a severity.)
Also fixes a bug looking up LSET layer names in the
GetStandardLayerNames array (which aren't the same).
https://forum.kicad.info/t/a-few-questions-about-custom-rules-syntax/40068/7
2023-04-30 13:01:09 +01:00
Seth Hillbrand
f4b43617e7
Add COMMIT structure to Schematic and Symbol editors
...
Provides a single-point access for modifying the schematic and symbol
elements that allows chaining updates and reverting partial changes.
Standardizes the undo hierarchy between pcb and schematic editors
As this is another layer on the existing undo/redo structure, the
initial commit does not replace all undo/redo calls currently existing.
These will be handled in a series of follow-on commits
2023-04-28 17:05:47 -07:00
Jeff Young
251161dbeb
Bring inspection reporting in line with zone filler
...
1) "clearance" rules don't apply to NPTH holes with no copper
2) local zone clearance applies even if other item has no copper
Fixes https://gitlab.com/kicad/code/kicad/issues/14575
2023-04-28 22:15:10 +01:00
Jeff Young
16e000f2b0
Use Net() accessor uniformly; init hole parent in VIA::Clone()
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14603
2023-04-28 18:32:58 +01:00
Jeff Young
6807ca6f9f
Allow text input to Convert to Polygon/Zone/Keepout.
...
Also fixes non-copper zone filler to honor fill keepouts.
Fixes https://gitlab.com/kicad/code/kicad/issues/14566
2023-04-28 17:43:08 +01:00
Lucas Dumont
b1a4353c34
Update collide for hole
...
As hole don't keep track of the net, update the collide function to keep it working
2023-04-28 10:20:55 +00:00
Jeff Young
b2a45023bc
Tighten ownership model of PNS::ITEM.
...
In particular, ownership must be explicitly set. It is
no longer inherited through copy/clone/etc.
2023-04-28 11:05:39 +01:00
Jeff Young
9646e3c1c0
Simplify PNS::VIA construction.
2023-04-28 00:32:49 +01:00
Lucas Dumont
c781fde236
pcbnew: don't move twice
...
In pcbnew, if you press M to move your selection and press M again, then escape, you will trigger the https://gitlab.com/kicad/code/kicad/-/blob/master/common/tool/tools_holder.cpp#L106 assert
2023-04-26 15:37:18 +00:00
Lucas Dumont
2992d7c68b
Fix typo in QueryConstraint switch
2023-04-26 13:20:32 +00:00
jean-pierre charras
2f392352b5
EDIT_TOOL::doMoveSelection(): avoid calling PushTool() and, just after,PopTool()
...
for the *same* event: TOOLS_HOLDER::PopTool() does not work fine in this case.
2023-04-26 13:00:50 +02:00
Seth Hillbrand
f7f52d77e4
Rework Copper Sliver check
...
Adds QA checks to copper sliver tests. Adds the following checks:
- Dot product between two arms (quickly avoids checks for >90°)
- Checks the sliver is convex (area test)
- Eliminates minor slivers with angles that are approximately 0 and ones
with the opposite side width beneath a configurable level
- Updates Clipper2 to fix a couple of jagged edges on inflate
- Adds simplify during zone fill inflation to limit jaggies
Fixes https://gitlab.com/kicad/code/kicad/issues/14549
2023-04-25 10:32:46 -07:00
jean-pierre charras
b9ed84b7db
Fix minor compil warnings
2023-04-25 12:43:15 +02:00
Lucas Dumont
e2e901de1d
Don't override clearance when routing
...
The default `m_overrideClearance = -1` used here was changed to 1.
Reseting it to -1 to solve linked issue
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14595
2023-04-25 09:18:53 +00:00
Jeff Young
676a15df65
Don't try to keep track of a HOLE's net.
...
Keep track of it's parentPadVia instead.
Fixes https://gitlab.com/kicad/code/kicad/issues/14603
2023-04-24 18:32:17 +01:00
jean-pierre charras
d180ce7865
Pcbnew, minor fix: make Image Properties dialog re-sizable.
2023-04-24 10:21:31 +02:00
jean-pierre charras
8fc70d577f
better QFNWizard.
2023-04-23 17:34:21 +02:00
jean-pierre charras
c617abe8e9
SCH_BITMAP and PCB_BITMAP: rename m_image to m_bitmapBase. Add more info
...
in GetMsgPanelInfo() (PPI, scale).
m_image name was confusing: it is not a wxImage, but a BITMAP_BASE item,
and m_image name was already in use in BITMAP_BASE, used inside SCH_IMAGE.
Bitmap properties dialog: show PPI value and add Title to dialog.
2023-04-22 17:28:06 +02:00
jean-pierre charras
0c544f1f45
FOOTPRINT_EDIT_FRAME: do not delete settings when closing the frame.
...
They now are read when starting kicad, and must be not deleted.
2023-04-22 11:46:52 +02:00
Marek Roszko
dbed94e4b1
Fix gerbers and drill plot not logging errors
...
Partial fix for https://gitlab.com/kicad/code/kicad/-/issues/14437
2023-04-20 23:39:59 -04:00
Marek Roszko
9f64c7f354
Load custom drawing sheets for pcb cli
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14171
2023-04-20 23:17:52 -04:00
Seth Hillbrand
990641d2eb
Cleanup printf bits
2023-04-20 15:19:04 -07:00
Seth Hillbrand
4b91c0c8ee
Handle multiple holes in footprints
...
Our basic logic for whether we have a hole or an outline in a footprint
checks if there is copper pads outside of the closed edge. This misses
the case where the footprint is used to align multiple holes but has no
copper. Since we do not support multiple outlines in a board, we can
safely assume that multiple, closed edges in a footprint represent holes
and not outlines
Fixes https://gitlab.com/kicad/code/kicad/issues/14468
2023-04-20 14:56:36 -07:00
Seth Hillbrand
b56db30019
Ensure that even open paths with fills are filled
...
SVG paths that are "open" can still have a fill internally, so avoid
dropping fills for these non-standard polygons
Fixes https://gitlab.com/kicad/code/kicad/issues/14518
2023-04-20 12:31:04 -07:00
jean-pierre charras
d4cf063e40
Fix a few more doxygen errors (no actual code change)
2023-04-19 20:24:42 +02:00
jean-pierre charras
a20f757d8c
undo a change (it was only a test) committed by mistake.
2023-04-19 16:57:35 +02:00
jean-pierre charras
1406341d2d
Fix a few doxygen errors (no actual code change)
2023-04-19 16:20:24 +02:00
Marek Roszko
ea077bc34d
Banish ignore.h to core
2023-04-18 22:44:04 -04:00
Seth Hillbrand
32d17547e5
Fixup settings loading
...
Settings loading needs to account for potential chaining, so each
instance should be created before being Load()ed. Additionally, add the
settings loading to QA
2023-04-18 16:00:31 -07:00
Seth Hillbrand
e6ab9a88ce
Remove locks from settings
...
Settings should be initialized on start-up. This removes the option of
lazily loading the settings from file and instead requires all settings
needed to be loaded on KiFACE start before requesting data from the
settings object
2023-04-18 13:40:25 -07:00
Jeff Young
c682d11fa0
Trim VRML export layers to board outline.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/14557
2023-04-18 17:31:29 +01:00
jean-pierre charras
ba12f00c15
Pcbnew: re-add draw umbilical line for texts in footprints.
...
It was lost after removing FP_TEXT in code.
2023-04-18 09:48:46 +02:00
Jeff Young
7e5fedef6a
Markup fixes.
...
1) allow escape sequences inside markup sequences
2) keep overbar when inside nested markup
3) always place overbar at full height, not sub/superscript height
Fixes https://gitlab.com/kicad/code/kicad/issues/14553
Fixes https://gitlab.com/kicad/code/kicad/issues/13449
2023-04-17 17:56:54 +01:00
qu1ck
9b58f50c68
Add usable PCB_GROUP::GetItems() swig wrapper
2023-04-17 15:41:49 +00:00
Nimish Telang
51e55dd750
Convert sprintf to snprintf in most files
2023-04-17 15:39:34 +00:00
jean-pierre charras
d0676118c1
BOARD_NETLIST_UPDATER: better warning message (I hope...) in Report.
...
Fixes #14548
https://gitlab.com/kicad/code/kicad/issues/14548
2023-04-17 14:30:47 +02:00
Lucas Dumont
469fe76994
pcbnew: Fix crash with differential routing
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14537
2023-04-17 14:17:14 +12:00
jean-pierre charras
725c2fd661
footprint wizards: fix for my previous commit 50502c4
2023-04-16 17:16:54 +02:00