Stabilize the sdf-fonts feature

Enable the SDF feature by default in our compiler binaries

(Still disabled by default for other users because it takes up compile
time for something they probably don't need)
This commit is contained in:
Olivier Goffart 2025-02-19 21:24:53 +01:00 committed by GitHub
parent 28f83c64e2
commit 1e814c9bdc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 68 additions and 15 deletions

View file

@ -44,6 +44,9 @@ Set the `SLINT_EMBED_RESOURCES` target property on your CMake target to one of t
* `embed-files`: The raw files are embedded in the application binary.
* `embed-for-software-renderer`: The files will be loaded by the Slint compiler, optimized for use with the software renderer and embedded in the application binary.
* `embed-for-software-renderer-with-sdf`: Same as `embed-for-software-renderer`, but use [Signed Distance Fields (SDF)](https://en.wikipedia.org/wiki/Signed_distance_function) to render fonts.
This produces smaller binaries, but may result in slightly inferior visual output and slower rendering.
(Requires the `SLINT_FEATURE_SDF_FONTS` feature to be enabled.)
* `as-absolute-path`: The paths of files are made absolute and will be used at run-time to load the resources from the file system. This is the default.
This target property is initialised from the global `DEFAULT_SLINT_EMBED_RESOURCES` cache variable. Set it to configure the default for all CMake targets.