summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorbruvzg <7645683+bruvzg@users.noreply.github.com>2022-03-11 16:22:04 +0200
committerbruvzg <7645683+bruvzg@users.noreply.github.com>2022-03-22 16:16:04 +0200
commit803e1ae920a282a64c48d2623ca056362a3f2359 (patch)
treee345b852433573317ef4f68d41b4193d904925a7 /modules
parent4c55a6529a1b68483638257b742f261eedea1dbf (diff)
[Help] Add simulated slanted font support to the editor help.
Diffstat (limited to 'modules')
-rw-r--r--modules/text_server_adv/text_server_adv.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/text_server_adv/text_server_adv.cpp b/modules/text_server_adv/text_server_adv.cpp
index b5912893b1..e02ddbb3f4 100644
--- a/modules/text_server_adv/text_server_adv.cpp
+++ b/modules/text_server_adv/text_server_adv.cpp
@@ -1355,6 +1355,8 @@ _FORCE_INLINE_ bool TextServerAdvanced::_ensure_cache_for_size(FontDataAdvanced
fd->underline_position = (-FT_MulFix(fd->face->underline_position, fd->face->size->metrics.y_scale) / 64.0) / fd->oversampling * fd->scale;
fd->underline_thickness = (FT_MulFix(fd->face->underline_thickness, fd->face->size->metrics.y_scale) / 64.0) / fd->oversampling * fd->scale;
+ hb_font_set_synthetic_slant(fd->hb_handle, p_font_data->transform.elements[0][1]);
+
if (!p_font_data->face_init) {
// Get style flags and name.
if (fd->face->family_name != nullptr) {