Commit Graph

10597 Commits

Author SHA1 Message Date
Ian McInerney aa09418a14 Fixup memory lifespan of GAL options for the settings preview canvas
The canvas keeps a reference to the settings object, so we
can't pass one from the stack because it runs into lifetime
issues.

Also cleanup some loop-iterator problems.

Fixes https://gitlab.com/kicad/code/kicad/issues/6338
2020-12-01 01:12:07 +00:00
Jeff Young dadfe03804 Reinstate 5.1 net-tie hack since "real" net-ties got pushed to 7.0.
Fixes https://gitlab.com/kicad/code/kicad/issues/6556
2020-11-30 16:11:15 +00:00
jean-pierre charras 7261086779 gendrill_file_writer_base: better algo to sort holes:
Holes were correctly sorted by size, but inside the same hole size
the holes were strangely sorted.
Now holes are sorted by hole size, and (inside the same size) by position.

Fixes #6553
https://gitlab.com/kicad/code/kicad/issues/6553
2020-11-30 16:59:13 +01:00
Jeff Young c66e373119 Cleanup of PCBNew message panel routines.
Also fixes bugs where invalid netclasses were reported as "Default",
and SMD pads were reported as having "0.0000" drills.
2020-11-30 14:38:06 +00:00
Jeff Young 3a9a6e22bc Fix issues in reporting netclasses.
1) make sure we get the default netclass when we want it
2) escape for HTML (particularly important for "<invalid>", but also
for reporting user rule names, netclass names, etc.)
2020-11-30 14:38:06 +00:00
Jeff Young 3989c19c41 Don't test pad:track clearances in pad tester.
They've already been tested in the track tester.

Fixes https://gitlab.com/kicad/code/kicad/issues/6554
2020-11-30 14:38:06 +00:00
Wayne Stambaugh 1f8b7b6149 Pcbnew: change block selection and heuristic context menu modifier keys.
Do not use the alt modifier key to force the display of the heuristic
context menu.  This causes a conflict with menu selection on windows
and immediately dismisses the disambiguation context menu.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/1873
2020-11-30 08:51:09 -05:00
Jeff Young e09271ca0e Fixes for hole clearance and hole-to-hole tests.
1) Separate out CONSTRAINT types
2) Filter both source and dest pads/vias for drilled holes when doing
   hole-to-hole checks.  We were checking the items being put into the
   DRC RTree, but not the items we were scanning.
3) Add hole clearance to Board Setup Constraints panel.

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

Fixes https://gitlab.com/kicad/code/kicad/issues/4683
2020-11-29 23:35:23 +00:00
Jeff Young 0c2cd1abb2 File left out of last commit.
Fixes https://gitlab.com/kicad/code/kicad/issues/6478
2020-11-29 21:21:20 +00:00
Jeff Young b171d381f0 Collapse Redraw3DView and Update3DView into a single routine.
Also fixes some errors about what the flag meant (model changed,
NOT redraw immediately).

Fixes https://gitlab.com/kicad/code/kicad/issues/6478
2020-11-29 21:08:30 +00:00
Jeff Young 3ca06700fc Formatting. 2020-11-29 20:00:16 +00:00
Marek Roszko 9322b3a4e1 Use the C++ isnan function 2020-11-29 11:30:45 -05:00
Jeff Young 889408c96a More improvements to new selection disambiguation.
Also a rationalization of text polygon generators, with the "standard"
version inherited from BOARD_ITEM now giving the bounding box.  This
requires callers who want the (much) more expensive stroke-based one
to call it explicitly (and brings PCB_TEXT in line with the was FP_TEXT
already was.

Fixes https://gitlab.com/kicad/code/kicad/issues/6525
2020-11-29 14:02:46 +00:00
Jeff Young 3c25abbf2f Ignore netcode when expanding track selections.
Fixes https://gitlab.com/kicad/code/kicad/issues/6529
2020-11-29 10:57:45 +00:00
Michael Kavanagh becc811775 Make path substitutions grid read only in lib table dialog
Fixes https://gitlab.com/kicad/code/kicad/issues/5624
2020-11-29 09:51:53 +00:00
Jon Evans f78d909ffb Correctly set up projects for converted boards
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6209
2020-11-28 22:46:05 -05:00
Marek Roszko 5e117bfaa5 Don't allow nan values for dxf text alignment points to creep in
Literally the only place dxflib decides to default to NaN....
2020-11-28 20:13:42 -05:00
Marek Roszko cc7264c0b9 Subtract off the block's base point coordinate from the insert translation 2020-11-28 20:13:42 -05:00
Marek Roszko cac0d93dfd Implement DXF INSERT scale
This has a chance of being wrong due to how the dimensions are stored in these intermediate objects
2020-11-28 20:13:42 -05:00
Jeff Young e4d0ffd607 Retire old SKIP_STRUCT filtering.
We already added the checkedPairs stuff which deals with a:b vs b:a
better, and the SKIP_STRUCT version had side-effects between the two
tests.

Fixes https://gitlab.com/kicad/code/kicad/issues/6539
2020-11-29 00:08:23 +00:00
Roberto Fernandez Bautista 0691e942f4 CADSTAR Archive Importer: Fix duplicate KIID for loaded elements
Don't use clone to copy an EDA_ITEM. Use Duplicate().
Even if you give the clone a new KIID, all its children will still be clones.
Create Duplicate() in LIB_PART
2020-11-28 17:18:17 +00:00
Roberto Fernandez Bautista 71f9847601 CADSTAR Archive Importer: Only load the Master variant 2020-11-28 17:18:17 +00:00
Roberto Fernandez Bautista e3334cd25c Non-KiCad Project importers: Do not rebuild the netlist or reannotate after import
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6383
2020-11-28 17:18:17 +00:00
Roberto Fernandez Bautista 78e3f917d9 CADSTAR PCB Archive Importer: Fix loading of old CADSTAR designs and Do Not Keep Upright
Older CADSTAR versions used 1/10 degree whereas newer versions use 1/1000 degree.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6437
2020-11-28 17:18:17 +00:00
Roberto Fernandez Bautista f2ba9f7ac3 CADSTAR PCB Archive Importer: Correctly load the pad numbers as per the original design
To load the pad numbers correctly we need to also check the PART DEFINITION for each component
2020-11-28 17:18:17 +00:00
Roberto Fernandez Bautista 5db78a3d53 Fix typo in zone filling progress reporter. "insulated" -> "isolated" 2020-11-28 17:18:17 +00:00
Jeff Young d3c952b122 Commit pending changes from grids.
Fixes https://gitlab.com/kicad/code/kicad/issues/6527
2020-11-28 11:44:05 +00:00
Jeff Young b1adb93c16 PCB_GROUP_Ts need to be added and removed from view.
The SELECTION_TOOL's m_enteredGroup also needs to be updated when
said group is deleted via undo or redo.

Fixes https://gitlab.com/kicad/code/kicad/issues/6493
2020-11-27 23:34:58 +00:00
Jeff Young 190197794d Apply a similar fix as pads for B&W via printing.
Fixes https://gitlab.com/kicad/code/kicad/issues/6496
2020-11-27 22:31:07 +00:00
Jeff Young 896ad4a749 Rewrite PCBNew selection disambiguation based on shapes.
The new shape architecture gives us the opportunity to make text
selection much more intuitive by actually looking at the glyph
shapes.  Before text would be selected when you clicked in the
descenders area (which was usually blank given uppercase letters
and digits).

Fixes https://gitlab.com/kicad/code/kicad/issues/6525
2020-11-27 22:03:14 +00:00
Jeff Young 0293f880ec Fix a bunch of group issues with importing graphics.
Groups do not own their children; they only reference them.  That
being said, they do own *selection* and *moving* of their children.
This might address some of 6493, but in any case will be a
pre-requisite for fixing it.

Fixes https://gitlab.com/kicad/code/kicad/issues/6493
2020-11-27 22:03:14 +00:00
Jon Evans 0bbb7bdb0c Allow selecting graphic footprints in high-contrast mode
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6490
2020-11-26 20:11:16 -05:00
Jeff Young 6f3b0c452f Make sure unfilled zones get an MD5 hash.
Fixes https://gitlab.com/kicad/code/kicad/issues/6515
2020-11-26 20:21:46 +00:00
Jeff Young 06b9439dbf Edge Cuts shapes have zero width.
Fixes https://gitlab.com/kicad/code/kicad/issues/6517
2020-11-26 17:42:46 +00:00
Jeff Young b3204a06fd Minor layout improvements to Router Settings dialog. 2020-11-26 17:41:09 +00:00
Jeff Young fc2bdc49de Once more into the depths of hell... er, I mean fix a focus issue.
So the new steals-focus protection stuff works well when there's a
focused control, but not as well when there's a modal dialog up which
happens not to have a focused control (or worse, a focusable control).

This adds a second mechanism for also checking to see if a modal dialog
is up (something that wxWidgets, true to form, makes very difficult).

Fixes https://gitlab.com/kicad/code/kicad/issues/6520
2020-11-26 16:47:40 +00:00
Jeff Young 2a87980d45 Remove overly verbose messaging. 2020-11-26 16:47:40 +00:00
Jeff Young 94de8ada97 Formatting and naming conventions. 2020-11-26 16:47:40 +00:00
Jeff Young 09587ef4fb Another attempt at GTK fix. 2020-11-26 00:05:57 +00:00
Jeff Young 96acb12295 Attempt to fix GTK compile issue. 2020-11-25 23:07:49 +00:00
Jeff Young b8414174af Duplicate Eeschema's select-ref-number strategy in PCBNew.
Fixes https://gitlab.com/kicad/code/kicad/issues/6504
2020-11-25 17:13:00 +00:00
Jeff Young 7a2a302117 Fix several issues with pad/hole colors when B&W printing.
Fixes https://gitlab.com/kicad/code/kicad/issues/6496
2020-11-25 17:13:00 +00:00
jean-pierre charras 5c08ad1ab9 Fix a few issues when copying a footprint from fp editor to clipboard, and paste it:
- ref and value texts were converted to user texts.
- fpid was left empty, thus creating a potential issue if pasted in the board editor.
Now:
- ref and value texts are no changed, and not copied is pasted in the footprint editor
(these texts already exist)
- a dummy fpid (clipboard:<md5 string>) is added if pasted in board editor
(Pasting a (partial) footprint from fp editor to a board editor is certainly not
a good idea but is possible)
2020-11-25 17:13:35 +01:00
jean-pierre charras 68625494f3 specctra_export: fix an issue with custom and chamfered/round rect pads.
Is some cases a created pad stack name had the same name as an other pad stack
having a slightly different shape, thus creating pads with a incorrect shape on board.

Fixes #6495
https://gitlab.com/kicad/code/kicad/issues/6495
2020-11-25 13:57:46 +01:00
Marek Roszko 5607420339 Fix polylines being skipped in DXF blocks 2020-11-25 00:06:02 -05:00
Ian McInerney d50d728d19 Cleanup compiler warnings 2020-11-25 00:08:09 +00:00
Jeff Young 1cae0b6c08 Make sure board edges have 0 width.
When we divide up a rectangle or polygon (for better RTree usage)
we need to make sure the individual segments also have their widths
zeroed out.

Fixes https://gitlab.com/kicad/code/kicad/issues/6482
2020-11-24 23:49:28 +00:00
Jeff Young 9c7c05c161 Mostly formatting cleanup but a few type-casting cleanups too. 2020-11-24 22:16:41 +00:00
Jeff Young 31a26e7d25 Add missing GetEffectiveShape(). 2020-11-24 22:16:27 +00:00
Jeff Young d1bddcf879 Implement GetEffectiveShape() for PCB_TARGET_Ts.
Fixes https://gitlab.com/kicad/code/kicad/issues/6488
2020-11-24 20:21:40 +00:00