mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
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 #4773)
This commit is contained in:
3
src/ui.c
3
src/ui.c
@@ -1098,7 +1098,8 @@ clip_start_selection(int col, int row, int repeated_click)
|
||||
// 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];
|
||||
|
Reference in New Issue
Block a user