Also make sure that value field is updated from name changes when the
symbol is a power symbol (even if it's from the schematic instead of
the library).
Fixes https://gitlab.com/kicad/code/kicad/issues/11093
(cherry picked from commit a9eb7a0e28)
Arcs can be altered by the process of changing from on-disk
representation to in-memory representation. Saving back to disk without
modifying the arc should not modify the calculated values.
This stores a copy of the on-disk representation that is only used to
save back to disk in the event that the arc is not modified during
editing.
Fixes https://gitlab.com/kicad/code/kicad/issues/10442
(cherry picked from commit cd7141fd10)
Also makes sure the progress dialog is closed when we're done reading
symbols (it used to stay up for much of the symbol editor initialization).
Also makes sure that any cancel in the preLoad step is honoured in the
sync step. (The preload is done because it is multi-threaded and therefore
faster than the single-threaded sync.)
Also makes sure that individual threads pay attention to the cancellation,
not just the GUI thread.
Fixes https://gitlab.com/kicad/code/kicad/issues/8372
(cherry picked from commit 1f16092e29)
Count() returns unsigned values. Since, we subtract 1 from this value,
if the count is 0, we will underflow the unsigned value, creating an
extremely large value that we multiply by the interline spacing.
Use GAL_DRAWING_CONTEXT as this unlocks the context in its destructor,
so that when an exception is thrown inside the `try` block, it should
automatically unlock before we switch backend.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10840
(cherry picked from commit 1b6fe615e5)
Also fixes a bug where zones meeting at a point would get merged
resulting in a self-intersecting zone.
Also fixes a bug where undo would not be handled correctly when zones
could not be merged.
Fixes https://gitlab.com/kicad/code/kicad/issues/10466
(cherry picked from commit d5a2059c21)
gcc doesn't need it and computes during compile regardless, but experimenting in godbolt, both clang and MSVC actually do need it or else it's partially computed at runtime
(cherry picked from commit ca7840334c)
WxString does not allocate space for wide strings needed during
conversion unless the string is explicitly wide. This can cause buffer
over/underflow
Fixes https://gitlab.com/kicad/code/kicad/issues/10605
Ctrl-A moves cursor to beginning of current line in text box.
Ctrl-E moves cursor to the end of the line.
This change makes navigation in Scintilla text boxes consistent
with other text boxes in KiCad.
Fixes https://gitlab.com/kicad/code/kicad/issues/9996
(cherry picked from commit 23fdbe4b21)
We were checking for duplicate tracks by looking to see if the two
tracks had two shared points. A null track always matched this case,
which removed the valid track. We solve this by avoiding null tracks in
the duplicate checker. They are removed separately in the null track
stage.
This also fixes a GTK-specific tree issue where we require the
BeforeReset()/AfterReset() calls instead of Cleared() to prevent GTK
from dereferencing a parent after freeing
Fixes https://gitlab.com/kicad/code/kicad/issues/10624
The zoom selection should only change when requested by the user, not in
response to UI updates. This can cause unexpected zoom shifts when the
calculated zoom is within a range of one of the presets. It also adds
unneeded calls during the UI update cycle
Fixes https://gitlab.com/kicad/code/kicad/issues/10498