summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbruvzg <7645683+bruvzg@users.noreply.github.com>2022-01-23 11:09:10 +0200
committerbruvzg <7645683+bruvzg@users.noreply.github.com>2022-01-23 11:09:10 +0200
commit3940bf586b60a6c8b9afd0a37b3632dd241349ce (patch)
treea7e6efe7380f497e09051e4eaa816a65a70f4b12
parentce42ab238ac5a16c32058c4b4564b7fefeaf8e07 (diff)
[Editor] Disable contextual alternates (coding ligatures) outside of code editor.
-rw-r--r--editor/editor_fonts.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/editor/editor_fonts.cpp b/editor/editor_fonts.cpp
index 6ca878e68d..0c9a7b2972 100644
--- a/editor/editor_fonts.cpp
+++ b/editor/editor_fonts.cpp
@@ -270,6 +270,9 @@ void editor_register_fonts(Ref<Theme> p_theme) {
/* Hack */
Ref<FontData> dfmono = load_cached_internal_font(_font_JetBrainsMono_Regular, _font_JetBrainsMono_Regular_size, font_hinting, font_antialiased, true);
+ Dictionary opentype_features;
+ opentype_features["calt"] = 0;
+ dfmono->set_opentype_feature_overrides(opentype_features); // Disable contextual alternates (coding ligatures).
// Default font
MAKE_DEFAULT_FONT(df, String());