This is a re-implementation of 39c2745f55fff72470ca1ea86ac7b1ea225908bd
that was removed by e5089d783d08f75e57b3ea90ed64a089e5b07b0b
This implementation works in the tool, containing side effects
(hopefully) better than the initial implementation. The multiple labels
are input as multiple lines instead of labels with spaces, allowing for
copy/paste between spreadsheets of labels
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10950
We still conflate the fieldID, the position in the
array of fields, and whether or not that means the
field is mandatory. But this attempts to clean up
*some* of that, without introducing too much risk.
Cloning the item into the previewe means that if we later increment
it, the preview clone doesn't update. Use the non-owning preview
interface to use the item directly in the preview.
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/19433
Recommendation is to avoid using the year nomenclature as this
information is already encoded in the git repo. Avoids needing to
repeatly update.
Also updates AUTHORS.txt from current repo with contributor names
Also adds a mode for AUTOADDED fields.
Also fixes a couple of bugs where a manual-level autoplaced
symbol would get reset back to auto-level when autoplaced.
It's possible you might want Exclude from Sim to be unit-specific,
but it's pretty hard to imagine how Exclude from Board, BOM,
or DNP could be unit-specific. (Maybe use a pill cutter on the chip?)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19029
The schematic commit system currently does not handle renaming symbols
in the symbol library editor or page settings in the schematic editor.
The schematic commit system will have to be modified to support the two
remaining direct calls to the undo/redo code.
Renaming a schematic sheet file can not be undone so it doesn't go
through the commit system. This meant that the schematic modified
flag was not getting set. If the only edit performed was renaming
a sheet file, the save modified flag would not get displayed when
closing the schematic editor.
Primary increment is the right most bit, secondary is the next
rightmost. So you can increment 'A1' to 'A2' or 'B1' with
Shift-Alt-Scroll and Ctrl-Alt-Scroll respectively.
These are context sensitive actions that increment "something"
about the selected item.
A generic 'increment' action can be produced, e.g. by other tools
or UI events, which has in increment step (positive or negative)
and an 'index' which determines what about the item should be
incremented - it's up to the increment action handler to decide
what that means.
And then add a primary and secondary inc/decrement action,
which allows to bind hotkeys to each.
Bind these to:
* Sym edit: increment pin names/number
increment text items
* Sch edit: increment lables and text
* FP/PCB: increment pin numbers
increment text items
This is useful when you want to copy text content out to some
external program (or put it in a text item/box).
I'm not sure it's possible to intuit exactly what a user wants,
as you will often want to copy items as the real items, and sometimes
as text. While KiCad might be able to make a smart guess, external
programs will have no chance!
The sheet list is returned as a copy of the cached list rather than a
reference to prevent external code from changing the list. While not as
performant, it eliminates the risk of the sheet list being altered in
ways that could break the schematic. The sheet list should only be
updated by calling SCHEMATIC::RefreshHierarchy() when any appropriate
sheet changes are made.
Note to developers: there is something inherently different about how the
QA tests are loading and handling schematics versus the schematic editor.
Using the cached sheet list for the SCHEMATIC object will cause some QA
test to fail. This is why SCHEMATIC::Hierarchy() has not replaced
SCHEMATIC::BuildSheetListSortedByPageNumbers() everywhere.
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).
A recent change set the parent member of a item put in the repeat list to
nullptr (this is OK) but the code to copy an item from this list did not
update this parent member.
This means that labels keep the position relative
to what they are connected to after the swap.
An attempt is made to map the fields of a label
into the position of a matching field (i.e. same name)
on the swapped-to label.
Move the SCH_FIELD rotation justification
handling to the SCH_FIELD class, so it's not just
SCH_LABEL that handles it.
https://gitlab.com/kicad/code/kicad/-/issues/18303
Also removes the side-effect that SCH_SHEET_LIST's
c'tor would sort the list (and write virtual page
numbers) anytime the starting sheet was the root.
Also, definitely don't build a SHEET_LIST (sorted or
otherwise) if you're not even going to use it.
Also don't build SCH_SHEET_LISTs on idle events. Better
to just always have the Next Sheet button enabled (we
already beep if you click it and there's no next sheet).
Also, use a SCREEN_LIST when you can. It's much cheaper
to create.
Includes:
- Fix GAL to draw closed polygons in eeschema
- Add functionality to eeschema to draw arbitary polygons
- Update polygon item previews to have customisable edge colour
- Add new SCH_RULE_AREA class, derived from a poly SCH_SHAPE
- Add SCH_RULE_AREA to paint and plot methods
- Add new rule area color preference to themes