mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 8.1.1622: wrong width if displaying a lot of lines in a popup window
Problem: Wrong width if displaying a lot of lines in a popup window. Solution: Accurately compute the line overflow.
This commit is contained in:
@@ -855,8 +855,8 @@ popup_adjust_position(win_T *wp)
|
||||
if (wp->w_width < len)
|
||||
wp->w_width = len;
|
||||
// do not use the width of lines we're not going to show
|
||||
if (wp->w_maxheight > 0 && wp->w_buffer->b_ml.ml_line_count
|
||||
- wp->w_topline + 1 + wrapped > wp->w_maxheight)
|
||||
if (wp->w_maxheight > 0
|
||||
&& lnum - wp->w_topline + 1 + wrapped > wp->w_maxheight)
|
||||
break;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user