Given that we compare the dot product (square of length) to s_min_dot,
it means that s_min_dot also needs to be square, or we wind up
converting line segments into circles that are visually distinct from
circles, leading to gaps in polylines.
(cherry picked from commit 0823692dda)
When dragging, you will seldom want to snap to the original item. This
commit prevents the "size of track" snap to the original item and
replaces it with an auxilary grid origin for the snap. This means
effectively that the snap will happen to grid for the original item
unless the cursor is closer to the original item line than it is to the
grid crossing.
Fixes: lp:1820248
* https://bugs.launchpad.net/kicad/+bug/1820248
(cherry picked from commit 0de25e557b)
Control ordering is critical to make dialog mnemonics work correct. The
static text with the mnemonic must immediately proceed the control and
no additional controls can be added between static text/control pair.
Fixing this required adding the units static text controls after all of
the mnemonic static text controls and their associated edit controls.
Mnemonics do not work for read only controls so all of the combobox
controls were moved after the text controls.
Fixes lp:1818930
https://bugs.launchpad.net/kicad/+bug/1818930
(cherry picked from commit 92fe201c5b)
libcontext currently restores and saves the FPSCR register
on ppc64. This behavior is fine (though unnecessary) on the
ELFv1 ABI which designates the register as volatile, but has
been observed to cause crashes on ELFv2 systems.
The ELFv2 ABI designates the FPSCR register as Limited-access
and specifies specific conditions that must be met to clobber
it. It does not seem that a context swap function meets these
conditions (and indeed, the save/restore register example in the
ABI document does not modify FPSCR).
This patch fixes ELFv2 ABI compliance by removing the FPSCR
save/restore code in libcontext entirely. This fixes observed
crashes on the platform and should have no consequence for
ELFv1 support.
Fixes: lp:1840088
* https://bugs.launchpad.net/kicad/+bug/1840088
(cherry picked from commit 3e22b75948)
The use of wxPATH_UNIX when calling GetFullPath() on windows drops the
volume identifier (c:\) from the file name which will cause comparison
failures.
(cherry picked from commit 0328f3e33b)
Set default dialog size to -1,-1 to allow the dialog to size itself
properly to prevent the buttons in the standard dialog button sizer
from being truncated.
Fixes lp:1839695
https://bugs.launchpad.net/kicad/+bug/1839695
(cherry picked from commit e3e546f7d2)
Do no rename symbol library files to the new project name. Only rename
the cache library. This prevents breaking symbol library links in the
schematic due to the project symbol library table pointing to the wrong
library file name.
Fixes lp:1837667
https://bugs.launchpad.net/kicad/+bug/1837667
(cherry picked from commit c7fc54b348)
When removing a junction, we need to keep the next pointer for deleted
item, marking them with a flag until committed.
Fixes: lp:1837398
* https://bugs.launchpad.net/kicad/+bug/1837398
Check for symbol libraries that somehow ended up in the project file
after remapping occurred and remove all of them to prevent potentially
broken symbol library links.
Add nagware dialog to warn the user and a checkbox to never show the
dialog again.
Fixes lp:1838185
https://bugs.launchpad.net/kicad/+bug/1838185
(cherry picked from commit 8789ab9265)
Remove an existing sheet from the current page that requires a schematic
load from file to prevent a corrupt screen list from causing a segfault.
Merge the edit sheet file loading with the append schematic code since
they are functionally the same. This allows the sheet edit code to
take advantage of all of the added broken symbol library links added in
the recent append schematic fixes.
Fixes lp:1835841
https://bugs.launchpad.net/kicad/+bug/1835841
(cherry picked from commit b595dc0d3b)
Do not add cache library from another project to old library list. This
is wrong and can cause all kinds of symbol library linking issues. It's
better to force the user to fix broken symbol library links than the false
security of using multiple cache libraries.
Use correct paths when appending schematic outside of the current project
path when hierarchical sheets are appended. If the path can be relative,
give the user the option to use either relative or absolute paths.
Do not change symbol library names in schematics appended from a source
outside the current project. This will almost ensure the symbol library
links will be broken in the source project.
When the appended schematic is from another project, attempt to check all
of the possible combinations of symbol library table importing that could
cause broken symbol library links and give the user the option of canceling
the append operation or live with the possibility that there may be broken
symbol library links.
When the append schematic is in the current project path but not part of
the schematic, check to see if there are any library nicknames that do
no exist in the project symbol library table and give the user a chance
to cancel the append process.
(cherry picked from commit 9fae30162d)
While we do not generate these arcs internally, some external tools
generate arcs that are technically valid but display correctly only
because of an oddity in the degeneracy mapping.
Fixes: lp:1838557
* https://bugs.launchpad.net/kicad/+bug/1838557
In rare cases, the VRML triangulator may claim to work but return empty
vectors. These cases need to be caught before we dereference the vector
elements.
Fixes: lp:1838448
* https://bugs.launchpad.net/kicad/+bug/1838448
This fixes two display issues in the project template selector. The
first captured HTML tags in the template title display and the second
prevented more than one line for showing (at least on GTK) in the
preview. This prevented disambiguation between the various templates.
This fixes the last suffix that was missed by 168fa09f5. The schematic
backup files should have the suffix .sch-bak to distinguish from
.kicad_pcb-bak or other backups.