This was hard coded at 10IU, which was way too small for pcbnew and
still too small for schematic editor. Instead, we set a default of 50
and allow the user to adjust (smaller for less powerful machines)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16568
We are only the default global FcConfig created by calling FcInitLoadConfigAndFonts inside FcInit().
Calling FcInitLoadConfigAndFonts does nothing but creating another FcConfig option that never gets disposed or used because we use the FcConfig functions with null
1) Don't fracture font glyphs when generating them; we're going
to fracture during triangulation anyway.
2) Don't check for self-intersection when deciding to fracture.
It costs nearly as much as the fracture does.
3) Cache drawing sheet text.
4) Use the current font when checking for cache validity.
5) Parallelize glyph triangulation.
6) Don't invalidate bounding box caches when offset by {0,0}
7) Use the glyph cache when generating text effective shape.
8) Short-circuit NormalizeJustification() if its center/center.
9) Don't triangulate for GuessSelectionCandidates()
10) Avoid sqrt whenever possible.
11) Pre-allocate bezier and SHAPE_LINE_CHAIN buffers.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14303
Version 7 text alignment changed subtly for stroke fonts from version 6.
Additionally, the output has been different between screen and plotting,
leading to offset text in plotted output relative to the text shown on
screen.
This introduces a fudge factor in FONT::getLinePositions to correct the
offset in the plotting output relative to v6.
This also changes the SCH_PAINTER and PCB_PAINTER to correct the
relative offsets between GAL and PLOTTER classes. The source of these
offsets is atm unclear.
Fixes https://gitlab.com/kicad/code/kicad/issues/14755
Many minor tweaks were added that changed the output of the stroke font
from v5/v6. These offsets changed the gerber output expected. This
reverts the changes to something much closer to the v6 output. It is
not pixel-perfect but gets very close on most texts.
Fixes https://gitlab.com/kicad/code/kicad/issues/14609
* Add compare method to COLOR4D object.
* Add unit test to validate COLOR4D comparison method.
* Add missing color test in text attribute comparison method.
* Add unit test for text attribute object.
* Remove unnecessary headers from text attribute header.
* Move text attribute code into separate source file.
While convoluted, this model matches as best we have found so far, the
alignment with scintilla. The spacing is character size for N-1 of the
characters in the 4-space tab stops. The final character is sized for
the actual space character in the stroke font (0.761905)
Fixes https://gitlab.com/kicad/code/kicad/issues/13791
The overbar function in outline fonts recursively calls the text
function which already owns the lock. To avoid this, we have an
unlocked variant that is wrapped by the exposed text function
Fixes https://gitlab.com/kicad/code/kicad/issues/14015
ttf fonts can declare multiple language names. Many by default opt to just declare one and not tag it any particular language.
However, there are CJK languages that typically leverage this function the most. They'll tag both a "en" and a cjk lang family name in CJK characters.
To be as user friendly as possible, we need to display said fonts in the CJK languages if KiCad to set to such a locale.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14011
sentry KICAD-B1
https://freetype.org/freetype2/docs/reference/ft2-base_interface.html
[Since 2.5.6] In multi-threaded applications it is easiest to use one FT_Library object per thread.
In case this is too cumbersome, a single FT_Library object across threads is possible also, as long as a mutex lock is used around FT_New_Face and FT_Done_Face.
LoadFont()'s only usage already checked for nullptr to fallback, let's actually return nullptr on a failed load
Fixes sentry KICAD-8Z
Make the cause of sentry KICAD-95
If the font face doesn't include a Bold or Italic version, we still want
to display the font as bold/italic, so we fake it with freetype.
This also prevents recurring error messages where the outline font warns
about "substitutes" within the same font family.
Also allows variants on the weight descriptor to be used without
throwing a substitution warning
Fixes https://gitlab.com/kicad/code/kicad/issues/13654