From cb2a64c5854205092150afe80f96177764bd4038 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sat, 19 Apr 2025 12:16:48 +0200 Subject: [PATCH] csi: don't allow client app to enable grapheme-shaping when disabled at compile-time Closes #2039 --- CHANGELOG.md | 5 +++++ csi.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6958c869..c15e05bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -68,6 +68,11 @@ ### Fixed * `colors.alpha-mode=matching` not working as intended. +* Grapheme shaping was allowed to be "enabled" at runtime, even though + disabled at compile time. This caused mis-rendering of certain + codepoints ([#2039][2039]). + +[2039]: https://codeberg.org/dnkl/foot/issues/2039 ### Security diff --git a/csi.c b/csi.c index 81c71e31..b66fda21 100644 --- a/csi.c +++ b/csi.c @@ -558,7 +558,9 @@ decset_decrst(struct terminal *term, unsigned param, bool enable) break; case 2027: +#if defined(FOOT_GRAPHEME_CLUSTERING) term->grapheme_shaping = enable; +#endif break; case 2048: