This tells you the arguments when it fails.
BOOST_TEST is available in all our Boost.Test version.
Even if you didn't use it, these calls should have been
BOOST_TEST_EQUAL(A, B) which also tells you the
arguments on a test failure.
This makes it easier to see which pins have alt modes
available. There is an option to turn them off.
The icon positions are chosen so they they shouldn't
interfere as far as possible:
* If the text is inside, the icon goes more inside
the body
* If the text is above/below the pin, it goes away from
the body
This means it won't collide with a symbol wall in
most cases, but some symbols with alt pins on opposing
sides may need to be widened if the icons are show.
Includes a rather fiddly refactor of the SCH_PIN painter
function, which needs quite a lot of massaging to allow
it to figure out where an icon would go. Quite a bit
of logic is broken out into smaller encapsulations with
less visible state to each chunk.
Icon modes for base-name-selected and alt-selected are
included, but only the former works due to information
being thrown away during the SCH_PAINTER tempPin
process.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/11069
Reduces the need for client code to know it can exploit the
enum -1/+1 properties. ToHAlignment provides an explicit
contract for integral conversion, and also doesn't rely on the
int being exactly -1, 0 or 1 (failure to adhere to which would
be UB).
This is confusing because the pads don't get a locked item shadow,
so it's hard to see what is inhibiting a footprint move if a pad got
locked.
Rather than implement the shadow, disable pad locking in pcbnew
(no locking exists in FP editor). Pad lock state isn't persisted
to the board file, so it's not a fully supported action, and it's
unlikely to be actively useful.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/18862
PCB and footprint editors were already blocking this. Otherwise we would
get weird issues when pasting while drawing things like sheets or
textboxes that aren't selected while drawing.
While there is an example where the default text frame justification is center-center,
in other cases it should be left-bottom, but we don't know what controls this yet.
An example where text frames should be imported with center-center justification:
830d51b80c/RK3328.PcbDoc
But in "mb1897-bdp.zip" from https://gitlab.com/kicad/code/kicad/-/issues/18784
text frames should use left-bottom justification.
(cherry picked from commit 86f122416b)
GetCopperLayerStackMaxId() replaces GetCopperLayerCount()*2 and is more
understandable in code where the max allowed PCB_LAYER_ID value is needed.
Removed also a dead code related to GetCopperLayerCount() < 2, broken and not
allowed in Kicad.
These are added to from the activation delay thread, but
accessed from the tool thread (e.g. via computeAnchors)
so they should be protected from concurrent access.
Relates-To: https://gitlab.com/kicad/code/kicad/-/issues/18835
These shouldn't be bad, and probably don't actually happen,
but they will act to clear extant construction lines for no
new shown items, so may as well be clear that they don't
do anything.
While it's still session-limited, this means you don't have
to restart to get your locking ability back.
Finer-grained locking enablement probably makes better long-term
sense, but this at least prevents "gun shyness" about a setting
you can't turn off again easily.
Also it gets a bool's-worth of application configuration state
out of a dialog (it was a static).
ZONE has a huge number of state variables. Some of these
have setters that check m_foo == aNewFoo. This is only
good karma if m_foo is initialised!
This doesn't set all of the members (maybe it should,
or maybe there should be sub-objects with explicit ctors)
but at least it should prevent obvious un-inited reports.
Previously, when executing a left mouse button (LMB) click to drag the
selected table, the cells inside the table were selected instead of moving
or dragging the table. To fix this, the move action should be enabled
instead of cell selection when m_selection contains only PCB_TABLE as
selected item. Otherwise, cell selection should remain enabled.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17380
Like the DSNLEXER header, this has visibility in over 700
files, whereas well under half actually use any of it
(quite a bit, but not all, of it actually via DSNLEXER)
Many places already forward-declare the OUTPUTFORMATTER type,
by doing that for the others, it still possible to use the
non-IO methods without having to see richio.h.
It doesn't even use the forward-declared
SYMBOL_LIB_TABLE.
Including this pulls in the whole richio system,
and sch_symbol.h is a very-included header.
Quite a few things do use SYMBOL_LIB_TABLE, but nowhere
near as many as use SYMBOL.
This one isn't as invasive as the others, but it is still
an implementation class that's not needed for public use
of netlists.
Actually, this could even be local to kicad_netlist_reader.cpp
as it's literally only used there.
Now, dsnlexer.h is exposed to only the files it needs, rather
than nearly 800 files.
TEMPLATE_FIELDNAMES_LEXER is already forward declared - including the
header too drags DSNLEXER into many files, but it is literally only used
in template_fieldnames.cpp.
This drags in dsnlexer.h to everything that uses EMBEDDED_FILES, but the
parser is actually only used in two files. It's not the only thing to
drag it in, though.
Currently, touching dsnlexer.h rebuilds nearly 800 files, when it
actually is needed by about 50 at most.
When (key + and - ) switching to next/previous layer before any usage of
the PNS router, Pcbnew crashed, likely due to incorrect value (perhaps
missing init) of the PNS_KICAD_IFACE (m_iface) m_board member.
So ensure this member is up to date before using it in ROUTER TOOL events.