Mercurial > vim
diff src/ui.c @ 17754:65b89c9eb946 v8.1.1874
patch 8.1.1874: modeless selection in popup window overlaps scrollbar
commit https://github.com/vim/vim/commit/4dd751b95696957c7baabad2f19f9e02fc596eae
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Aug 17 19:10:53 2019 +0200
patch 8.1.1874: modeless selection in popup window overlaps scrollbar
Problem: Modeless selection in popup window overlaps scrollbar.
Solution: Subtract scrollbar from max_col. (closes https://github.com/vim/vim/issues/4773)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 17 Aug 2019 19:15:06 +0200 |
parents | 6ffe295f7492 |
children | 0f7ae8010787 |
line wrap: on
line diff
--- a/src/ui.c +++ b/src/ui.c @@ -1098,7 +1098,8 @@ clip_start_selection(int col, int row, i // Click in a popup window restricts selection to that window, // excluding the border. cb->min_col = wp->w_wincol + wp->w_popup_border[3]; - cb->max_col = wp->w_wincol + popup_width(wp) - wp->w_popup_border[1]; + cb->max_col = wp->w_wincol + popup_width(wp) + - wp->w_popup_border[1] - wp->w_has_scrollbar; if (cb->max_col > screen_Columns) cb->max_col = screen_Columns; cb->min_row = wp->w_winrow + wp->w_popup_border[0];