Skip to content

Commit a0d8f31

Browse files
Jocelyn Falempekdj0c
authored andcommitted
Fix CSI 18t and 19t reporting size.
The reported screen size was 1 cell too big in both direction. The CSI dsr command added +1 for the cursor position, and it was wrongly added for the screen size. Signed-off-by: Jocelyn Falempe <[email protected]>
1 parent d3cdc0e commit a0d8f31

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/tsm/tsm-vte.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1811,7 +1811,7 @@ static void csi_report_window_size(struct tsm_vte *vte)
18111811

18121812
w = tsm_screen_get_width(vte->con);
18131813
h = tsm_screen_get_height(vte->con);
1814-
len = snprintf(buf, sizeof(buf), "\e[%u;%u;%ut", resp, h + 1, w + 1);
1814+
len = snprintf(buf, sizeof(buf), "\e[%u;%u;%ut", resp, h, w);
18151815
if (len >= sizeof(buf))
18161816
return;
18171817
vte_write(vte, buf, len);

0 commit comments

Comments
 (0)