diff src/popupmnu.c @ 17811:b5499bf22a97 v8.1.1902

patch 8.1.1902: cannot have an info popup without a border Commit: https://github.com/vim/vim/commit/bd483b3f577ee1af7c8c8bf440f5d81613336975 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Aug 21 15:13:41 2019 +0200 patch 8.1.1902: cannot have an info popup without a border Problem: Cannot have an info popup without a border. Solution: Add the "border" item to 'completepopup'.
author Bram Moolenaar <Bram@vim.org>
date Wed, 21 Aug 2019 15:15:03 +0200
parents 59f8948b7590
children 8ca20b0a3dc3
line wrap: on
line diff
--- a/src/popupmnu.c
+++ b/src/popupmnu.c
@@ -745,6 +745,7 @@ pum_set_selected(int n, int repeat)
 		if (use_popup)
 		{
 		    int col = pum_col + pum_width + 1;
+		    int row = pum_row + pum_selected - pum_first + 1;
 
 		    if (Columns - col < 20 && Columns - col < pum_col)
 		    {
@@ -755,8 +756,8 @@ pum_set_selected(int n, int repeat)
 		    else
 			curwin->w_maxwidth = Columns - col + 1;
 		    curwin->w_maxwidth -= popup_extra_width(curwin);
-		    popup_set_wantpos_rowcol(curwin,
-				      pum_row + pum_selected - pum_first, col);
+		    row -= popup_top_extra(curwin);
+		    popup_set_wantpos_rowcol(curwin, row, col);
 		}
 # endif
 		if (!resized