Commit Graph

16238 Commits

Author SHA1 Message Date
Jeff Young f9702aab87 Immediate actions for PlEditor, PcbNew, etc. 2019-06-25 11:34:28 +01:00
Jeff Young cda3a82c66 Implement our own navigation out of a grid.
While wxWidgets has Navigate() and NavigateIn(), they're not compiled
on GTK because it supposedly has native TAB control.  Of course its
native TAB control won't get you out of a grid, so that leaves us in
a bit of a pinch.  This implements a poor-man's Navigate() which will
at least get us out of the grid.

Fixes: lp:1810569
* https://bugs.launchpad.net/kicad/+bug/1810569
2019-06-25 11:34:28 +01:00
Jeff Young f088d4d762 Add env-var setting to CommonSettingsChanged().
Fixes: lp:1804925
* https://bugs.launchpad.net/kicad/+bug/1804925
2019-06-25 11:34:28 +01:00
Jeff Young 3784950603 Added more sophisticated checking for thermal spoke connections.
And, again, some more performance optimizations to make up for it.
2019-06-25 11:34:28 +01:00
Jeff Young 49610085ea Don't try to show sub-dialog in OnActivate(). High Sierra asserts.
Fixes: lp:1832635
* https://bugs.launchpad.net/kicad/+bug/1832635
2019-06-25 11:34:28 +01:00
Jeff Young 0ed26e4e33 Fix some geometry error in thermal spoke calculations.
Also introduces some performance enhancements to make up for the
extra time spent in the calculations.
2019-06-25 11:34:28 +01:00
Jeff Young 65821f747d Bring 3D viewer in line with Pcbnew's solder mask rendering. 2019-06-25 11:34:28 +01:00
Jeff Young e5cb8a0310 Bug fixes for rotated pad thermal spokes. 2019-06-25 11:34:28 +01:00
Jeff Young f8f1476f63 Performance enhancement for Fracture(). 2019-06-25 11:34:28 +01:00
Jeff Young 1099befab1 Performance improvement for SHAPE_LINE_CHANGE::PointInside().
It was calculating the bounding box twice (and failing to honour
the accuracy parameter on the bounding box test).

Worse, constructing the bounding box is about the same speed as
the rigorous test, so it never improves things.
2019-06-25 11:34:28 +01:00
Jeff Young 70e6d95c7f More zone fill performance enhancements.
Knocking out unconnected spokes turns out to be very expensive, so
keep them in a list and only apply them if they're connected.
2019-06-25 11:34:28 +01:00
Jeff Young 14986d1e0e Zone fill performance enhancements.
Batch up fast operations to reduce the number of slow operations
required.
2019-06-25 11:34:28 +01:00
Jeff Young 79cd457ba7 Implement thermal spokes for custom pad shapes.
The thermal spokes are anchored at the pad anchor.  They may or may
not make sense, depending on the pad shape.  It's up to the author
to move the anchor around as necessary or to not use thermals.
2019-06-25 11:34:28 +01:00
Jeff Young a19c668891 Add tooltip for local ratsnest tool. 2019-06-25 11:34:27 +01:00
Jeff Young f70ab6203b Make all inner layers available for hotkey assignments.
Fixes: lp:1787073
* https://bugs.launchpad.net/kicad/+bug/1787073
2019-06-25 11:34:27 +01:00
Jeff Young ba7cf09ad5 Add zone display mode toggle action.
Fixes: lp:1759574
* https://bugs.launchpad.net/kicad/+bug/1759574
2019-06-25 11:34:27 +01:00
Jeff Young fbfcba6e4d Add action for context menu (right-mouse-click).
Fixes: lp:1663595
* https://bugs.launchpad.net/kicad/+bug/1663595
2019-06-25 11:34:27 +01:00
Jeff Young e1d5cf1a87 Change pad solder masks to use rounded-corner clearances.
This assumes maximum registration errors are a vector, rather than
an amount in both x and y axes.  Lots more disucssion in the bug
report and on the forum (link in the bug report).

Also makes large changes to the painting of pads, but they now use
the same code as plotting, so if there are any changes then they
were errors before since plotting represents "truth".

Fixes: lp:1563744
* https://bugs.launchpad.net/kicad/+bug/1563744
2019-06-25 11:34:27 +01:00
Jeff Young 5c89e4490e Change zone fill algorithm to better handle thermal reliefs.
Thermal reliefs must not knock-out spokes of other pads, while
clearances must knock-out spokes of all pads.  Therefore we now
do all thermal reliefs, then all spokes, then all clearances.

Fixes: lp:602176
* https://bugs.launchpad.net/kicad/+bug/602176

Fixes: lp:1782957
* https://bugs.launchpad.net/kicad/+bug/1782957
2019-06-25 11:34:27 +01:00
jean-pierre charras 29ca96cfe7 Gerber drill file: Modify a aperture attribute for oblong holes (slots).
Oblong holes (slots) use now a aperture attribute similar to round holes.
(The previous attribute "slot" is now deprecated)
However they have a specific aperture, and a comment is added in drill files for these apertures.
2019-06-25 09:43:29 +02:00
jean-pierre charras 70ff2e14a5 Eeschema: avoid crashes when the tool highlight or delete is activated and clicking in a empty schematic.
Was a nullptr not tested.
2019-06-25 08:31:22 +02:00
Seth Hillbrand 98124e68c7 Update exit strategy to match UI guidelines
In singletop mode, all frames show the "Quit" option in the file menu
and will quit on Ctrl-Q.  When launched from the main KiCad interface,
sub-programs show the "Close" option instead and will close with Ctrl-W.
In this mode, Ctrl-Q will instruct the main program to exit.

Fixes: lp:1779938
* https://bugs.launchpad.net/kicad/+bug/1779938
2019-06-24 21:46:42 -07:00
Seth Hillbrand f9c476d851 Cleanup EDA_DRAW_FRAME init 2019-06-24 21:46:42 -07:00
Tomasz Włostowski 6180687bbd TestSegmentHit: add corner case for null segment (start == end)
Fixes: lp:1833059
* https://bugs.launchpad.net/kicad/+bug/1833059
2019-06-25 01:06:25 +02:00
Tomasz Włostowski d7fe307913 eeschema: automatically insert junctions at pin connections if needed during file load
EEschema optimizes wires by merging colinear segments. If a schematic opened without a valid
cache library or missing installed libraries and later saved, this optimization can cause connectivity
errors. In order to fix that we check each pin-wire connection and junctions if necessary.
2019-06-25 01:06:25 +02:00
Seth Hillbrand ec3158d03a pcbnew: Don't clear module flags on revert
The RebuildSelection routine now handles updating the selection based on
flags.

Fixes: lp:1831881
* https://bugs.launchpad.net/kicad/+bug/1831881
2019-06-24 10:26:37 -07:00
Seth Hillbrand 0bce0f37e4 pcbnew: Avoid wxassert in message
wxstring::Printf() needs size_t cast to acceptable type or it gives an
assertion in debug mode.

(cherry picked from commit e8ce0ba6ef)
2019-06-24 09:42:40 -07:00
Wayne Stambaugh 15e6bcc86b Footprint library nickname comparison fixes.
Footprint library nicknames are case sensitive but the comparison for
the library tree control was case insensitive.

Also make the footprint name comparisons case sensitive as well.  While
not strictly necessary, the plan is to start using the name defined in
the footprint file instead of the file name which will allow for case
sensitivity.

Fixes lp:1833701

https://bugs.launchpad.net/kicad/+bug/1833701
(cherry picked from commit d8fff5c820)
2019-06-24 08:03:28 -04:00
Seth Hillbrand 6d60b98dc8 Fix bug in tesselation
When we hit a self-intersection, we need to be careful that we don't
lose the stop vertex.

Fixes: lp:1833819
* https://bugs.launchpad.net/kicad/+bug/1833819
2019-06-23 20:55:55 -07:00
Seth Hillbrand 172542cfc4 Enforce build order with qa system
The QA objects link to the direct kiface objects, which creates a second
dependency on the generated lexer files.  To ensure that the primary
apps are finished building them in a (potentially) different thread, we
set a false dependency on the final build product in the qa CMake.

Fixes: lp:1833851
* https://bugs.launchpad.net/kicad/+bug/1833851
2019-06-23 12:52:20 -07:00
jean-pierre charras 710a82bc51 Eeschema: fix an issue in netlists when using "<root sheet>" as root sheet path name.
Netlists do not accept any char in netnames (especially spice).
They must use only "/" as root sheet path name.

Especially _( "<root sheet>" ) breaks netlists because:
- there is a space in name, and special chars (< and >)
- it is a translatable name. so the actual name cannot be managed.
- most of netlist code in Kicad expects a "/" as root path.
2019-06-23 19:37:41 +02:00
Seth Hillbrand 251e0ca19c Minor bug fix to zones
On linux, m_brdOutlinesValid initialized to "true" which prevented
non-copper zones from filling correctly
2019-06-22 10:56:37 -07:00
Seth Hillbrand 1ece1172c5 pcbnew: Ensure save dialog with zones
Fixes: lp:1833748
* https://bugs.launchpad.net/kicad/+bug/1833748

(cherry picked from commit febc8cd6aa)
2019-06-22 08:55:23 -07:00
jean-pierre charras c8c318510e Pcbnew, zones filler: fix a bug I introduced in my commit b1803bc. 2019-06-22 16:41:20 +02:00
jean-pierre charras b1803bcf02 Pcbnew, zones filled: fix incorrect clipping of filled areas outside the board outlines.
fix also an other minor issue: these filled areas were slightly too large.
2019-06-22 09:55:57 +02:00
Seth Hillbrand d132cf37e0 Allow null path in 3d model
This allows a setting where the path is not one of the options.  This
permits the user to select once to go to any path option (rather than
off the current and then back to currect) when the filetree doesn't
match the dropdown.  This also selects the drop down item if it matches
the tree.

(cherry picked from commit f5284ced54)
2019-06-20 20:15:40 -07:00
Seth Hillbrand 39c2745f55 eeschema: Allow spaces in label names for multilabeling
This adds the functionality to add multiple labels to your schematic at
once by using spaces in the original label name.

Fixes: lp:1095113
* https://bugs.launchpad.net/kicad/+bug/1095113
2019-06-20 16:21:49 -07:00
Wayne Stambaugh 57a60a32f5 KiCad: fix project tree open in system path bug.
Don't pass relative paths to the system file manager.  The current working
directory may not be the current project path which may end up opening the
system file manager in an unexpected folder.

Fallback to the user's document folder when a valid project path is not
found.
2019-06-20 15:18:43 -04:00
jean-pierre charras e1a2cbbea1 Eeschema: fix for root sheet plot filename, in non English languages. 2019-06-20 17:00:06 +02:00
Seth Hillbrand 3bd2b7762a Fixup previous move commit
The previous commit missed a case where the number was so large that it
overflowed the integer invalidating the comparison.  This protects
against that case by using floating point comparison.

(cherry picked from commit f25ae373bb)
2019-06-20 06:48:10 -07:00
Seth Hillbrand 4a18f9db3a pcbnew: Enforce maximum movement in Move Exact
This checks the movement against a maximum value that would place the
selection outside of the valid area for the footprint or board.

Fixes: lp:1833478
* https://bugs.launchpad.net/kicad/+bug/1833478

(cherry picked from commit 845833e8fd)
2019-06-20 06:40:33 -07:00
jean-pierre charras b8d2fef079 pl_editor: fix a crash when cancelling the "add bitmap dialog" by escape key. 2019-06-20 13:05:23 +02:00
Seth Hillbrand 77cefe0c16 Normalize line endings
A few files snuck in with CRLF for the line endings.  These make it hard
to look at diffs as every line appears to have changed.  This commit
makes only line ending changes, so can be ignored
2019-06-19 15:18:30 -07:00
Jeff Young 6aa0ceff36 Don't throw out search hits because they have unit children. 2019-06-19 21:27:58 +01:00
Jeff Young 485d436860 Clear ctx-menu before rebuilding; don't veto ctx-menu mousewarp for non-ctx-menu dialog.
Fixes: lp:1833312
* https://bugs.launchpad.net/kicad/+bug/1833312
2019-06-19 21:17:56 +01:00
Jeff Young 4054d7ddf7 Don't try an intertwine deletion and junction fixup.
Fixes: lp:1833224
* https://bugs.launchpad.net/kicad/+bug/1833224
2019-06-19 19:30:38 +01:00
Jeff Young bacb8c26cc Fix compiler warnings. 2019-06-19 19:10:46 +01:00
Jeff Young eb95202708 Fix grid update when edited from menubar.
Fixes: lp:1833399
* https://bugs.launchpad.net/kicad/+bug/1833399
2019-06-19 18:35:17 +01:00
Jeff Young 730b89af6d Another round of changes for immediate actions. 2019-06-19 18:35:17 +01:00
Jeff Young 3a0256aade Add handle-based editing for eeschema bitmaps.
Also cleans out a bunch of duplicated functionality from the image
editor dialog.

Fixes: lp:1828722
* https://bugs.launchpad.net/kicad/+bug/1828722
2019-06-19 18:35:17 +01:00