1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-12-04 14:46:46 -05:00

Merge pull request #1461 from kaffeekanne/fix-inputwindow

Set input window size to max window size
This commit is contained in:
Michael Vetter 2020-12-12 08:21:55 +01:00 committed by GitHub
commit d4069f9c40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -309,7 +309,7 @@ _inp_win_update_virtual(void)
int wcols = getmaxx(stdscr);
int row = screen_inputwin_row();
if (inp_win != NULL) {
pnoutrefresh(inp_win, 0, pad_start, row, 0, row, wcols - 2);
pnoutrefresh(inp_win, 0, pad_start, row, 0, row, wcols - 1);
}
}
@ -387,7 +387,7 @@ _inp_win_handle_scroll(void)
if (col == 0) {
pad_start = 0;
} else if (col >= pad_start + (wcols - 2)) {
} else if (col >= pad_start + (wcols - 1)) {
pad_start = col - (wcols / 2);
if (pad_start < 0) {
pad_start = 0;