Commit Graph

19 Commits

Author SHA1 Message Date
Salvador E. Tropea b21e65fc5f Fix compatibility with wxWidgets 3.0.x
- Use CanonicalName when GetCanonicalWithRegion() isn't available
2023-02-22 19:23:55 +00:00
Marek Roszko fd4a0dbedf Fix up handling of font names available in multiple names
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


(cherry picked from commit 39e69a3d29)
2023-02-22 01:27:09 +00:00
Seth Hillbrand bcc1e28bab Fix Windows build error
bc Microsoft owns all the words
2023-01-25 16:45:04 -08:00
Seth Hillbrand cf52bfcc55 Handle missing Bold/Ital outline fonts
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
2023-01-25 13:13:38 -08:00
Marek Roszko 0ff32d20cd wxS more things 2023-01-22 09:41:42 -05:00
Marek Roszko ac94995f70 Some more wxS 2023-01-16 19:07:50 -05:00
Ola Rinta-Koski 6196f2bdf0 Version info: report all font libraries 2022-03-07 14:01:37 +00:00
jean-pierre charras 2485648a54 Fix typo in a copy/paste and a minor compil warning 2022-02-07 17:32:19 +01:00
jean-pierre charras a37a7aa1d5 move a misplaced include 2022-02-07 08:22:43 +01:00
Marek Roszko 41f54349a5 Replace inserts/push_backs with emplace in some spots 2022-02-05 19:53:31 -05:00
Jeff Young a808e2396b Run font/laguage checks only on Mac. 2022-01-18 14:19:57 +00:00
Jeff Young d4ff829c26 Trace logging for fonts. 2022-01-18 14:08:47 +00:00
Jeff Young 7d032f9c2f Outline font rendering for Cairo, plotter, printer and 3D viewer.
Fixes https://gitlab.com/kicad/code/kicad/issues/10319
2022-01-10 01:54:28 +00:00
Jeff Young 78cac128b7 Careful: symbol fonts have no language.
Also a bit of clean up to shut up a false-positive in Coverity (and
clangd) on dereferencing a possibly (not) nullptr.
2022-01-09 11:34:20 +00:00
Jeff Young a170d3f006 Commenting. 2022-01-09 11:34:20 +00:00
Jeff Young a4349ae638 Cleanup and error reporting for fonts. 2022-01-09 11:34:20 +00:00
Jeff Young 6242b40cde Supported language filtering for fonts.
If the language isn't supported by the system, no point showing the
user the fonts.
2022-01-08 22:02:17 +00:00
Ola Rinta-Koski 5b7198dfc8 Fixes as per @sethhillbrand's comments 2022-01-08 16:47:45 +00:00
Ola Rinta-Koski 9b406c1da4 Outline font support. 2022-01-08 16:47:45 +00:00