Commit Graph

15821 Commits

Author SHA1 Message Date
John Beard f7d35cf94b Sexpr: needs to be a STATIC lib
Fedora COPR builds with -DBUILD_SHARED_LIBS:BOOL=ON, which
means this breaks until the sexpr lib target is explicitly
STATIC
2019-04-24 17:31:22 +01:00
John Beard 15bba27406 BITMAP_BASE: Add const image data accessor
This allows a const BITMAP_BASE to expose const image
data. This is currently done with const_casts, which is
"OK", only as long as the source image is not declared
const, in which case it's undefined behaviour.

Also immediately dereference the pointer to a reference
if it's not checked to make the non-null requirements
explicit at the point of access.
2019-04-24 17:31:22 +01:00
Jeff Young 5e556f0c6a Fix segfault when finishing a wire at a connection point. 2019-04-24 14:43:10 +01:00
Jeff Young e046e8f593 Fix crash when <esc>ing from Hierarchical Sheet drawing tool. 2019-04-24 13:43:46 +01:00
John Beard e687d14903 Remove useless const_casts
Both versions of EDA_DRAW_FRAME::isBusy have a useless const_cast.

GetScreen() const returns a non-const SCH_SCREEN already, it doesn't
need to be cast, and it's stored in const SCH_SCREEN anyway.
2019-04-24 09:46:01 +01:00
Jeff Young d281f051ed Move eeschema delete tool to modern toolset. 2019-04-23 14:19:55 +01:00
Jeff Young a967adbf26 Don't toggle selection twice when trying to select.
Also fixes issues with trying to use a CONTEXT_MENU as a wxMenu.
2019-04-23 14:19:55 +01:00
Tomasz Włostowski 9e00f48efc router: copy m_maxClearance when cloning/branching PNS::NODEs
Fixes: lp:1813328
* https://bugs.launchpad.net/kicad/+bug/1813328
2019-04-23 12:00:54 +02:00
Jeff Young b6674e3bcb Prevent segfault when running selection disambiguation menu. 2019-04-23 10:59:07 +01:00
Jon Evans ff6a8cd537 Revert "Remove UpdatePins call from connectivity calculation"
This reverts commit b351e70d13.

Causes crashes on entering subsheets; don't have time to debug yet
2019-04-22 23:31:11 -04:00
Jon Evans 782b8227fa Clean up connection message panel info 2019-04-22 22:58:41 -04:00
Jon Evans b351e70d13 Remove UpdatePins call from connectivity calculation 2019-04-22 22:49:24 -04:00
Jon Evans 62811d3209 Squish some warnings 2019-04-22 21:18:47 -04:00
Jeff Young c994961ebf Fix for SCH_PIN operator= from Simon Richter. 2019-04-23 00:27:59 +01:00
Jeff Young b03e9061ff Have another go at fixing 'w' command when wire tool is already active. 2019-04-23 00:11:26 +01:00
Jeff Young 0445a9913f Deactivate tool on block action.
Fixes: lp:1825855
* https://bugs.launchpad.net/kicad/+bug/1825855
2019-04-23 00:11:19 +01:00
Jeff Young f6d0166584 Don't exit wire tool at end of wire.
Fixes: lp:1825871
* https://bugs.launchpad.net/kicad/+bug/1825871
2019-04-22 22:13:47 +01:00
Jeff Young 1a007c3e4b Implement SCH_SELECTION_TOOL (but still with legacy semantics). 2019-04-22 22:08:18 +01:00
Jeff Young e885d739a4 Simiplify VECTOR2 -> wxPoint conversions.
There has always been an operator specified, but it's explicit so
most folks don't notice it.
2019-04-22 22:08:18 +01:00
Jeff Young 8e812c012d Second activation of wire or bus tool should start drawing.
Fixes: lp:1825871
* https://bugs.launchpad.net/kicad/+bug/1825871
2019-04-22 22:08:18 +01:00
Jeff Young 17b3b8f30d Fix wandering text problem.
Setting a variable on a temp copy doesn't do much of use.

Fixes: lp:1825853
* https://bugs.launchpad.net/kicad/+bug/1825853
2019-04-22 22:08:18 +01:00
Jeff Young 5e2cf51309 Improve robustness of SCH_PIN storage architecture.
In particular, allow short-term storage of pointers to SCH_PINs.
2019-04-22 11:19:43 +01:00
Jeff Young a461eae8b9 Fix 100s of usages of GetFlags() which conflated != 0 with being edited.
While this was true long ago, many flags have been added since which
have nothing to do with editing (HIGHLIGHTED, BEGIN_ONPAD, etc.)
2019-04-22 09:58:06 +01:00
Jeff Young 64ba866146 Fix ignoreMouseEvents getting stuck in drawing tool.
Fixes: lp:1825613
* https://bugs.launchpad.net/kicad/+bug/1825613
2019-04-22 09:32:57 +01:00
jean-pierre charras 6e8dd598c0 Minor fixes in translatable strings. Fix also a minor compil warning. 2019-04-22 09:34:28 +02:00
John Beard 1a9aa2e92d Use old-style boost includes
The Boost::boost style library dependencies don't work
on some CMake versions (couldn't find library -lBoost::boost)

Use ${Boost_INCLUDE_DIRS} in the target_include_dirs() instead.
2019-04-22 01:02:13 +01:00
Jon Evans e2c12d8c25 Overhaul connectivity neighbor and global connection processing 2019-04-21 19:10:44 -04:00
jean-pierre charras 223e24f423 export_hyperlynx.cpp: better message in a warning. 2019-04-21 12:03:00 +02:00
Simon Richter 2b3b26b502 Remove two extraneous spaces from a tooltip 2019-04-20 22:04:22 +01:00
Simon Richter ed4c9f7ddb Use format string for composed strings
Some translations may need this.
2019-04-20 22:01:43 +01:00
Jon Evans dffd1179c5 Add a mechanism to load kifaces when run from the build directory
This is useful when working on code paths that rely on KiWay
communications, since you can run and debug the kicad application
without needing to run an install task first.
2019-04-20 15:08:34 -04:00
John Beard 957f868e2f Docs: add a 'technical todo' list
Provides a place to record work that is pending due to
library, compiler or language restrictions.

Because some of this work will be pending for several years
until supported distros support the relevant versions, having
this centrally documented prevents it being forgotten.

Also includes current distro versions for extant "LTS"
distros that are likely to be the distros holding back
library versions.

Only includes things we currently actually do work around
in the code, or things that are direct C++ replacements
(e.g. Boost libraries being adopted to C++).
This is as opposed to more opinion-based "we should
 do it this way, it's better" things, which should be
proposed for discussion first.
2019-04-20 15:32:12 +01:00
Jon Evans 77fe7d8325 Remove netlist QC code; it's outlived its usefulness 2019-04-19 22:53:16 -04:00
Jon Evans 5b226f6c96 Allow extra tildes at end of bus names
Fixes: lp:1825579
* https://bugs.launchpad.net/kicad/+bug/1825579
2019-04-19 22:26:24 -04:00
Jon Evans eca9cc35c6 Update all labels on a migrated bus 2019-04-19 22:10:30 -04:00
Jon Evans a92bb94612 Ignore multiple identical bus labels
Fixes: lp:1825560
* https://bugs.launchpad.net/kicad/+bug/1825560
2019-04-19 22:03:22 -04:00
Jeff Young f2d9887409 Make usage of BRIGHTENED consistent (m_Flags, not m_Status). 2019-04-19 17:19:41 +01:00
Jeff Young 5113c3cc58 Hook up <esc> to cancelInteractive ACTION. 2019-04-19 17:08:19 +01:00
Jeff Young 954998ec9a Lay the foundation for handling selected SCH_ITEMs. 2019-04-19 16:54:29 +01:00
Jeff Young e9c1cd2371 Fix duplicate hotkeys. 2019-04-19 01:07:36 +01:00
Jeff Young d88126e519 Tidy up and fix end sheet command. 2019-04-19 01:00:54 +01:00
Jeff Young f274e0f68b Move some more immediate actions to modern toolset. 2019-04-19 00:42:50 +01:00
Jeff Young d0bc84bcbf Don't allow legacy and modern toolset to fight over moving objects.
Fixes: lp:1825427
* https://bugs.launchpad.net/kicad/+bug/1825427
2019-04-19 00:42:36 +01:00
Jeff Young 2bcf38d2b6 Add try/catch block around writing a new library.
Fixes: lp:1825203
* https://bugs.launchpad.net/kicad/+bug/1825203
2019-04-18 22:00:32 +01:00
Jeff Young cc18464f8f Move sheet drawing and resizing to modern toolset and fix some bugs.
Fixes: lp:1825204
* https://bugs.launchpad.net/kicad/+bug/1825204
2019-04-18 18:19:12 +01:00
John Beard 3d7c070faf Dev doc: Fix and add link
Fix the libngspice link markdown.

Add a link to the testing page from the relevant section on QA test
options.
2019-04-18 17:16:35 +01:00
John Beard 6ad97e5b5b Kicad Curl: Ignore unused functions for OpenSSL >= 1.1.0
In OpenSSL 1.1.0 and newer, the locking callback macros do nothing.
This causes unused warnings for the static function lock_callback.

Ignore this function on newer OpenSSL builds, but keep
the infrastructure for now.

When OpenSSL's min version is 1.1 or greater, all the locking
infrastructure can be removed.
2019-04-18 16:24:29 +01:00
John Beard 02fca8e0df Pcbnew: fix -Wmaybe-uninitialized in legacy PCB plugin
In the failure case, the "makeType" is uninitialised. In a non-debug
build, wxFAIL will compile out and the uninitialised behaviour will
happen silently. In a debug build, it'll assert, and then do the
uninitialised behaviour anyway.

Continue explicity to avoid this.
2019-04-18 15:28:33 +01:00
John Beard f4ba3cd910 QA: Add build-time option to enable XML output from tests
This allows CI tools to get machine-readable test reports.

By default, this is off - when you test normally, you probably
want the regular console spew.

Boost tests use the in-built Boost test command line options.

The Python tests take an --xml parameter and output the tests
there.
2019-04-18 10:59:06 +01:00
John Beard 4214437d18 QA: Only build kicad2step tests if the lib exists
If neither OCC or OCE is available, the kicad2step_lib
target is not created, so the unit tests also cannot
be built. Detect missing libs and abort the test
target creation in that case.

Reverts (and fixes): 3a8ffd66c
2019-04-18 10:13:17 +01:00