From 0f93766614bde055ce61e1b7ffc8f6b5aeef91d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Mon, 3 Feb 2025 15:30:00 +0100 Subject: [PATCH] osc: text-size: disable optimization The optimization prevents the forced-width to be set on the new combining character, causing issues when followed by more zero-width codepoints. --- osc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/osc.c b/osc.c index f6398165..eaf6e33e 100644 --- a/osc.c +++ b/osc.c @@ -1222,6 +1222,7 @@ kitty_text_size(struct terminal *term, char *string) LOG_DBG("len=%zu, forced=%d, calculated=%zu, using=%zu", len, forced_width, calculated_width, width); +#if 0 if (len == 1 && calculated_width == forced_width) { /* * Optimization: if there's a single codepoint, and either @@ -1233,6 +1234,7 @@ kitty_text_size(struct terminal *term, char *string) free(wchars); return; } +#endif uint32_t key = composed_key_from_chars(wchars, len);