Commit Graph

14399 Commits

Author SHA1 Message Date
Jeff Young 5c726744b6 Move Zone Properties dialog to Connect() strategy.
If checkboxes don't have individual IDs FormBuilder won't assign
them and the event table ends up connecting each checkbox to all
of the checkbox handlers in the dialog.

Fixes: lp:1801746
* https://bugs.launchpad.net/kicad/+bug/1801746
2018-11-08 21:27:15 +00:00
John Beard 4c355c32d3 Fix rounding in COLOR4D::ToColour
Due to the implicit floor of the cast from double to unsigned char,
there was a small rounding error in COLOUR4D's WX conversion function.

This fixes the failing tests.

Also make the cast to unsigned char explicit.
2018-11-08 14:40:42 -05:00
John Beard ee819216e2 QA: Make a separate unit test utils library, COLOR4D tests
This includes:

* Linkage against the Boost unit test libs
* Configuration of the Boost libs
* A place for common generics "extras" for unit test harnesses
  including
    * A simple way to allow "expected-failure" tests (without
      breaking Boost < 1.58, e.g. Ubuntu LTS)
    * Moving some simple numeric predicates from the geom tests
      to the utils library.

Expand unit test docs to describe the expected failures macro.

Add a few COLOR4D tests, including one with expected failures due
to a pre-existing bug. This will be fixed in a follow-up commit.
2018-11-08 14:40:42 -05:00
jean-pierre charras 0980f7232c Gerbview: minor fixes. 2018-11-08 16:49:50 +01:00
John Beard 5660ad86ea QA: Add TITLE_BLOCK tests
Add some unit tests on TITLE_BLOCK

This commit also requires some mocks so the libcommon stuff
can work:

* Needs a Kiface() function to be linkable
* Needs some stuff from common to be build specially
* Needs to define itself as one of the unit-having programs
  to appease the units defines.
2018-11-08 08:28:20 -05:00
John Beard 075f428aca Include directories are implied by legacy_gal linkage
This avoids having to manually specify include/legacy_gal
in and legacy GAL targets, and harominizes with legacy_wx.

This also means .cpp files in common/legacy_gal do not
need to specify the legacy_gal subdirectory, so they
will continue to work as needed when legacy_wx is removed.
2018-11-08 07:52:36 -05:00
Maciej Suminski 02f81d7419 Handle 'show page limits' in eeschema 2018-11-08 09:57:16 +01:00
Seth Hillbrand 4b931aeb57 pcbnew: Force cursor position when snapping
This places the crosshairs (confusingly named here) at the snap
position, either one of the snap points or the grid, depending on the
status of the hotkeys SHIFT/ALT.

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

Fixes: lp:1801369
* https://bugs.launchpad.net/kicad/+bug/1801369
2018-11-07 14:36:46 -08:00
Seth Hillbrand f2ccad39b6 pcbnew: Fix grid snapping for picker
Fixes: lp:1801373
* https://bugs.launchpad.net/kicad/+bug/1801373
2018-11-07 09:03:26 -08:00
Jeff Young cbd13c7127 Show dangling pins when moving items; don't when dragging.
Fixes: lp:1801962
* https://bugs.launchpad.net/kicad/+bug/1801962

Fixes: lp:1801959
* https://bugs.launchpad.net/kicad/+bug/1801959
2018-11-07 14:24:16 +00:00
Jeff Young 5c26b1dabd Don't use C-style cast when we don't actually know what it is. 2018-11-07 14:24:16 +00:00
Jeff Young 3439551543 Implement a work-around for net-ties.
Fixes: lp:1799318
* https://bugs.launchpad.net/kicad/+bug/1799318
2018-11-07 14:24:16 +00:00
Maciej Suminski 3e8b3e535a Added a comment for close event handlers in DIALOG_PRINT_GENERIC 2018-11-07 09:31:40 +01:00
qu1ck e789542ba4 Fix warning in dialog_print_generic.cpp 2018-11-07 09:26:47 +01:00
Seth Hillbrand 1f25fcd3d6 pcbnew: Shift zone filler to std::async 2018-11-06 09:28:12 -08:00
Seth Hillbrand a24bd9baa1 pcbnew: Adjust default update rate to 100ms
10ms was too fast to update the progress reporter and actually slowed
the process down for many machines.
2018-11-06 09:28:12 -08:00
jean-pierre charras 7c77b92cd8 remove fully outdated (and now incorrect) scripts. 2018-11-06 18:16:59 +01:00
jean-pierre charras 95bc4f74c5 Windows compil option: always define UNICODE and_UNICODE needed by Kicad that uses unicode. 2018-11-06 18:15:52 +01:00
Maciej Suminski d6bc402f14 Fix instantly disappearing pop-up menu in eeschema
Fixes: lp:1798453
* https://bugs.launchpad.net/kicad/+bug/1798453
2018-11-06 17:21:13 +01:00
Maciej Suminski 8091573bf7 Fix disappearing schematic components
SCH_COMPONENTs should be added to VIEW only when symbol links are
resolved. Otherwise a dummy component bounding box will be used when
inserting a component to VIEW R-tree.

Fixes: lp:1801800
* https://bugs.launchpad.net/kicad/+bug/1801800
2018-11-06 11:25:47 +01:00
jean-pierre charras 238abad004 Gerber job file: fix incorrect GUID.
Fixes: lp:1801696
https://bugs.launchpad.net/kicad/+bug/1801696
2018-11-06 08:16:07 +01:00
John Beard bec2920f12 QA: qa_utils has to be static
If qa_utils is not explicitly declared with STATIC, the build
fails in environments where the BUILD_SHARED_LIBS CMake option is
present and set to "ON". An example of this is Fedora COPR.
2018-11-05 14:27:17 -05:00
Maciej Suminski 4ad37bc9ea Limit 'items on disabled layers' DRC check to copper layers
Fixes: lp:1788248
* https://bugs.launchpad.net/kicad/+bug/1788248
2018-11-05 14:00:49 +01:00
Maciej Suminski 293bc52299 Fix off-grid block paste
Fixes: lp:1801625
* https://bugs.launchpad.net/kicad/+bug/1801625
2018-11-05 11:59:38 +01:00
jean-pierre charras 830c5e7db7 3D viewer: ensure 0 sized circles (that crash the viewer) are skipped. 2018-11-05 08:30:54 +01:00
Jeff Young 6e9475694c Fix bug with zone selection when zones are shown filled. 2018-11-04 19:17:53 +00:00
Jeff Young fec8ab372e Don't set the viewport when switching screens.
That's the job of ZoomAutomatique().

Fixes: lp:1799436
* https://bugs.launchpad.net/kicad/+bug/1799436
2018-11-04 19:17:53 +00:00
Seth Hillbrand df562b7ec0 pcbnew: Prevent degenerate values in Eagle import
Importing Eagle files allowed for invalid zone values for clearance and
minimum width that triggered asserts in the 3d-viewer.

Fixes: lp:1801188
* https://bugs.launchpad.net/kicad/+bug/1801188
2018-11-04 11:01:08 -08:00
jean-pierre charras 93d3e4ccf8 dialog_footprint_wizard_list_base.cpp: fix a minor wxWidgets alert. 2018-11-04 15:50:29 +01:00
Jeff Young 589e1f6a96 MSW and GTK need a separate dialog for opening/saving directories.
Fixes: lp:1801528
* https://bugs.launchpad.net/kicad/+bug/1801528
2018-11-04 12:35:01 +00:00
Jeff Young 68b07d1aff Add show/hide search tree to modedit, and fix it in libedit.
Fixes: lp:1801531
* https://bugs.launchpad.net/kicad/+bug/1801531
2018-11-04 12:35:01 +00:00
Jeff Young 6e810a00e4 Warp mouse from context menu before dragging.
Fixes: lp:1798815
* https://bugs.launchpad.net/kicad/+bug/1798815
2018-11-04 12:35:01 +00:00
Jeff Young 3bfd32cdc5 Inherit grid settings from PCBNew.
Fixes: lp:1801428
* https://bugs.launchpad.net/kicad/+bug/1801428
2018-11-04 12:35:01 +00:00
Nick Østergaard 8c1ebc4314 Remove shebang from footprint wizard plugin
Fedora packaging errors with ambiguous python shebang since current
rawhide (30).

So we should remove it as the footprint wizards are not to be executed
standalone.
2018-11-04 08:43:20 +01:00
Maciej Suminski 75896d767a Fix a crash in BOARD::SortedNetnamesList()
Variable netBuffer contains all NET_INFO items, whereas max_netcode
value is determined only basing on pad nets. After a netlist update
there still might be a NETINFO_ITEM that is not assigned to any pad and
has a net code higher than calculated max_netcode. Such situation
results in a out-of-bounds access in sortNetsByNodes().
2018-11-03 18:17:48 +01:00
jean-pierre charras 15fa8f8a22 Minor fixes. 2018-11-03 14:30:34 +01:00
Jeff Young 569d4a0f64 More selection logic improvements.
Separate out zone edges (which are quite specific, and should
win over most other things) from zone fills (which are pretty
generic and should only be considered when there's nothing else).

Also excludes zone fills when the zones aren't being shown as
filled.
2018-11-02 23:52:00 +00:00
Maciej Suminski dfccd8c5e4 Added level-of-details threshold for via net name layer 2018-11-03 00:48:03 +01:00
Maciej Suminski 8d73cfef2a Adjusted level-of-detail thresholds for BOARD_ITEMs visibility
Fixes: lp:1801056
* https://bugs.launchpad.net/kicad/+bug/1801056
2018-11-03 00:34:27 +01:00
Jeff Young 69952a7b9f Improve updating of symbol and footprint trees.
In particular, update highlighting when changing footprints.
2018-11-02 19:55:30 +00:00
Jeff Young d7ff3f8af5 Allow text on margin layer. 2018-11-02 19:55:30 +00:00
jean-pierre charras be0935b339 Eeschema: Update zoom/scale limits, due to recent change in GAL.
Fixes: lp:1797995
https://bugs.launchpad.net/kicad/+bug/1797995
2018-11-02 14:36:12 +01:00
jean-pierre charras 54fe060b5a add tool to open system file browser to main toolbar 2018-11-02 13:51:13 +01:00
jean-pierre charras d3dc56a42f pl_editor: cosmetic enhancements 2018-11-02 13:47:48 +01:00
jean-pierre charras d465af65a7 LIB_FIELD: fix incorrect text thickness for small sized texts.
Also remove duplicate code.
2018-11-02 11:36:07 +01:00
Maciej Suminski b7b9cccffc Moved wxPython/Phoenix detection to a separate CMake module 2018-11-02 11:28:30 +01:00
Maciej Suminski 23e574fbcd Remove a redundant semicolon in Python path configuration command 2018-11-02 10:40:05 +01:00
Maciej Suminski 1c19a50f31 Add license header to Findngspice.cmake 2018-11-02 09:42:08 +01:00
Maciej Suminski 179c46ce49 Handle another type of wxPython/Phoenix version string
Fixes: lp:1801109
* https://bugs.launchpad.net/kicad/+bug/1801109
2018-11-02 09:42:08 +01:00
jean-pierre charras 5e44686711 Eeschema, symbol editor: re-enable PNG export and fix a minor issue in SVG export (was in B&W mode instead of color).
Add a comment in plotter.h to avoid other errors when selecting plotting mode B&W or color

Fixes: lp:1801058
https://bugs.launchpad.net/kicad/+bug/1801058
2018-11-02 09:24:55 +01:00