To: vim_dev@googlegroups.com Subject: Patch 8.0.1538 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.0.1538 Problem: Popupmenu is too far left when completion is long. (Linwei) Solution: Adjust column computations. (Hirohito Higashi, closes #2661) Files: src/popupmenu.c *** ../vim-8.0.1537/src/popupmnu.c 2018-02-17 20:35:24.430696008 +0100 --- src/popupmnu.c 2018-02-24 18:51:27.381828534 +0100 *************** *** 253,259 **** /* align right pum edge with "col" */ #ifdef FEAT_RIGHTLEFT if (curwin->w_p_rl ! && col < max_width + pum_scrollbar + 1) { pum_col = col + max_width + pum_scrollbar + 1; if (pum_col >= Columns) --- 253,259 ---- /* align right pum edge with "col" */ #ifdef FEAT_RIGHTLEFT if (curwin->w_p_rl ! && W_ENDCOL(curwin) < max_width + pum_scrollbar + 1) { pum_col = col + max_width + pum_scrollbar + 1; if (pum_col >= Columns) *************** *** 262,268 **** else if (!curwin->w_p_rl) #endif { ! if (col > Columns - max_width - pum_scrollbar) { pum_col = Columns - max_width - pum_scrollbar; if (pum_col < 0) --- 262,268 ---- else if (!curwin->w_p_rl) #endif { ! if (curwin->w_wincol > Columns - max_width - pum_scrollbar) { pum_col = Columns - max_width - pum_scrollbar; if (pum_col < 0) *** ../vim-8.0.1537/src/version.c 2018-02-24 18:30:51.177639381 +0100 --- src/version.c 2018-02-24 18:55:02.856480820 +0100 *************** *** 780,781 **** --- 780,783 ---- { /* Add new patch number below this line */ + /**/ + 1538, /**/ -- The Law, in its majestic equality, forbids the rich, as well as the poor, to sleep under the bridges, to beg in the streets, and to steal bread. -- Anatole France /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///