aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2025-02-03 14:30:00 +0000
committerDaniel Eklöf <daniel@ekloef.se>2025-02-06 13:02:38 +0000
commit0f93766614bde055ce61e1b7ffc8f6b5aeef91d3 (patch)
treeaf7a1f2520035bfa03c56b893c88cb4c7086f612
parentdoc: ctlseq: add OSC 66 (kitty text sizing) (diff)
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.
-rw-r--r--osc.c2
1 files changed, 2 insertions, 0 deletions
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);