diff options
author | Thomas Adam <thomas@xteddy.org> | 2018-08-18 19:02:39 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2018-08-18 19:02:39 +0100 |
commit | 522d751eee82b45dd508951c713ee9eba9de76ae (patch) | |
tree | 4dbb266fed907e67305fe249bc331606772ff033 /tty.c | |
parent | af679326b207eb36fb84814a28760fc2e582c2b4 (diff) | |
parent | 3bc08b0dc0c9868ba5acaa7b8f12159a9a66cf4a (diff) | |
download | rtmux-522d751eee82b45dd508951c713ee9eba9de76ae.tar.gz rtmux-522d751eee82b45dd508951c713ee9eba9de76ae.tar.bz2 rtmux-522d751eee82b45dd508951c713ee9eba9de76ae.zip |
Merge branch 'obsd-master'
Diffstat (limited to 'tty.c')
-rw-r--r-- | tty.c | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -698,6 +698,21 @@ tty_repeat_space(struct tty *tty, u_int n) tty_putn(tty, s, n, n); } +/* How many lines are taken up by the status line on this client? */ +u_int +tty_status_lines(struct client *c) +{ + u_int lines; + + if (c->flags & CLIENT_STATUSOFF) + lines = 0; + else + lines = status_line_size(c->session); + if (c->message_string != NULL || c->prompt_string != NULL) + lines = (lines == 0) ? 1 : lines; + return (lines); +} + /* * Is the region large enough to be worth redrawing once later rather than * probably several times now? Currently yes if it is more than 50% of the |