This reverts commit decc7ed888.
This compilation options (-fpermissive) is no longer needed,
as the code that caused the warnings on GCC <7 is no longer
present.
The reason this error was GCC bug #56480 [1], which disallowed
the following (valid, in C++11) syntax:
template<> struct namespace_a::namespace_b::a_struct<TYPE>
{...}
And instead insisted on:
namespace namespace_a {
namespace namespace_b {
template<> struct a_struct<TYPE>
{...}
}
}
[1]: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56480
Test a few "centre-point-angle" cases and add some
generic geom code for testing vectors and boxes are within
tolerance (since rounding often creeps in).
Much of the arc-checking code will be useful to other
construction methods (e.g. point-point-point).
There are expected failures for the bbox code when
the arc passes though, but does not end on, a quadrant point
(0, 90, 180, 270). This is due to a defective
implementation of SHAPE_ARC::BBox() that does not take
into account the quadrant points. This will be fixed
as a follow-up.
Use the AddFileExtListToFilter() to also generate the
wildcard for "all files". This is because:
* Users can use AddFileExtListToFilter for the all files WC
with the same interface as for any other extensions.
* Users do not need to worry about wxGetTranslation, as the
_() is applied in the same way as the other *Wildcard() helpers,
and it is a function just like the others, so it is consistent
* There is a testable interface to document the expected result.
The test is added.
Varargs make it very hard to pass strings in flexibly
when they (and the number of them) are not known
at compile time.
For example, this allows up to now amalgamate the "single
ext" and "multiple ext" unit tests.
This adds a unit test for the recent AddFileExtListToFilter
to demonstrate how to use it and the expected output.
The unit tests are a bit clunky, as the vararg approach cannot
work winth strings passed at runtime.
The reduces a little bit of WX dependency, and makes
the timing code a bit more type-safe.
Also adds a more testable interface for the accelerated
zoom controller.
This is done to avoid a big chunk of conditionally-compiled code
in the middle of the event function.
Also separates the zoom logic from the WX_VIEW_CONTROLS object
and isolates it in a separate class behind a clearer interface.
Add some simple tests for sane steps on GTK+3-sized scroll
steps.
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.
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.
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.
Previous test strings did not utilize extended table unicode, so some
cases slipped through testing. When initializing wxString, we need to
be careful to specify that we are initializing from a UTF-8 string
otherwise the system will utilize a locale-specific initialization.
* Renames /qa/common to /qa/qa_utils, as it is not to do with /common
* Renames /qa/geometry to /qa/common
* Put existing geometry tests into a subdirectory of /qa/common, to
echo the layout of the main tree.
The intention is to provide a place to put tests of other libcommon
code in the /qa/common suite.
When editing the pcb, Ctrl-Click will highlight a net. This allows
de-highlight with the ESC/cancel action from the selection tool. Inside
the highlight tool, ESC reverts to the selection tool while keeping the
net highlighted.
Fixes: lp:1793842
* https://bugs.launchpad.net/kicad/+bug/1793842
Some actions, such as select trivial connection, don't need the
user to choose which trace at a corner to start from -- either
one will do. Same for moving a simple trace corner.
Likewise, Edit in Footprint Editor shouldn't ask if you mean the
footprint or the pad. Obviously it's the footprint.
This change adds a CLIENT_SELECTION_FILTER which allows clients
to do tool- or action-specific filtering of the selection before
the disambiguation menu is run.
It also removes some tool- and action-specific code which was
in the selection_tool and shouldn't have been.
Fixes: lp:1708869
* https://bugs.launchpad.net/kicad/+bug/1708869
- renamed connectivity.[h|cpp] to connectivity_data [.h|.cpp] so that the file name matches the main class name.
- GetNetItems() now returns a vector instead of a list