aboutsummaryrefslogtreecommitdiffstats
path: root/zellij-server/src/panes/plugin_pane.rs
diff options
context:
space:
mode:
authorSatoru Higa <satoruhiga@gmail.com>2026-04-03 17:21:34 +0900
committerGitHub <noreply@github.com>2026-04-03 10:21:34 +0200
commit27a825ebdcae75d00a90396acf861fe1c90a2a6d (patch)
tree107a4a6a9f4dbc323eecfbaadbcb0425daa148a5 /zellij-server/src/panes/plugin_pane.rs
parentfix(windows): encode modifiers in raw bytes for non-Char keys (#4967) (diff)
downloadsl0ppij-27a825ebdcae75d00a90396acf861fe1c90a2a6d.tar.gz
sl0ppij-27a825ebdcae75d00a90396acf861fe1c90a2a6d.tar.xz
sl0ppij-27a825ebdcae75d00a90396acf861fe1c90a2a6d.zip
fix: position host cursor for CJK IME even when app hides cursor (#4951)
* fix: position host cursor for CJK IME even when app hides cursor When apps like Claude Code (ink/React library) hide the cursor during rendering, Zellij's render_cursor() was not sending a CUP sequence to the host terminal. This caused IME composition candidates to appear at the wrong position, breaking CJK input in these apps. Change cursor_coordinates() to return the cursor position unconditionally (as long as it is within bounds) along with a bool indicating visibility. render_cursor() now positions the host cursor even when the app has hidden it, so the IME subsystem can read the correct cursor position. * add test * rustfmt --------- Co-authored-by: Aram Drevekenin <aram@poor.dev>
Diffstat (limited to 'zellij-server/src/panes/plugin_pane.rs')
-rw-r--r--zellij-server/src/panes/plugin_pane.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/zellij-server/src/panes/plugin_pane.rs b/zellij-server/src/panes/plugin_pane.rs
index aeed38c7..10e7186c 100644
--- a/zellij-server/src/panes/plugin_pane.rs
+++ b/zellij-server/src/panes/plugin_pane.rs
@@ -252,7 +252,7 @@ impl Pane for PluginPane {
self.should_render.insert(client_id, true);
}
- fn cursor_coordinates(&self, client_id: Option<ClientId>) -> Option<(usize, usize)> {
+ fn cursor_coordinates(&self, client_id: Option<ClientId>) -> Option<(usize, usize, bool)> {
let own_content_columns = self.get_content_columns();
let own_content_rows = self.get_content_rows();
let Offset { top, left, .. } = self.content_offset;
@@ -265,7 +265,7 @@ impl Pane for PluginPane {
if x >= own_content_columns || y >= own_content_rows {
None
} else {
- Some((x, y)) // these are 0 indexed
+ Some((x, y, true)) // plugins always show cursor when position is set
}
})
} else {