patch 9.1.1391: Vim does not have a vertical tabpanel
Problem: Vim does not have a tabpanel
Solution: include the tabpanel feature
(Naruhiko Nishino, thinca)
closes: #17263
Co-authored-by: thinca <thinca@gmail.com>
Signed-off-by: Naruhiko Nishino <naru123456789@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/popupwin.c b/src/popupwin.c
index 60a54d7..a9a2843 100644
--- a/src/popupwin.c
+++ b/src/popupwin.c
@@ -86,7 +86,7 @@
if (STRCMP(key, "line") == 0)
n = screen_screenrow() + 1 + n;
else // "col"
- n = screen_screencol() + 1 + n;
+ n = screen_screencol() + 1 + n - TPL_LCOL(NULL);
// Zero means "not set", use -1 instead.
if (n == 0)
@@ -1545,7 +1545,7 @@
}
if (center_hor)
{
- wp->w_wincol = (Columns - wp->w_width - extra_width) / 2;
+ wp->w_wincol = (Columns - wp->w_width - extra_width - TPL_LCOL(NULL)) / 2;
if (wp->w_wincol < 0)
wp->w_wincol = 0;
}
@@ -4081,7 +4081,7 @@
// win_update() doesn't handle them.
top_off = popup_top_extra(wp);
left_extra = wp->w_popup_padding[3] + wp->w_popup_border[3]
- - wp->w_popup_leftoff;
+ + TPL_LCOL(NULL) - wp->w_popup_leftoff;
if (wp->w_wincol + left_extra < 0)
left_extra = -wp->w_wincol;
wp->w_winrow += top_off;
@@ -4163,7 +4163,7 @@
}
// Title goes on top of border or padding.
- title_wincol = wp->w_wincol + 1;
+ title_wincol = wp->w_wincol + 1 + TPL_LCOL(NULL);
if (wp->w_popup_title != NULL)
{
title_len = vim_strsize(wp->w_popup_title);
@@ -4191,7 +4191,7 @@
wp->w_popup_border[0] > 0 ? border_attr[0] : popup_attr);
}
- wincol = wp->w_wincol - wp->w_popup_leftoff;
+ wincol = wp->w_wincol - wp->w_popup_leftoff + TPL_LCOL(NULL);
top_padding = wp->w_popup_padding[0];
if (wp->w_popup_border[0] > 0)
{
@@ -4229,7 +4229,7 @@
{
padcol = wincol + wp->w_popup_border[3];
padendcol = wp->w_wincol + total_width - wp->w_popup_border[1]
- - wp->w_has_scrollbar;
+ + TPL_LCOL(NULL) - wp->w_has_scrollbar;
if (padcol < 0)
{
padendcol += padcol;
@@ -4327,7 +4327,7 @@
if (wp->w_has_scrollbar)
{
int line = i - top_off;
- int scroll_col = wp->w_wincol + total_width - 1
+ int scroll_col = wp->w_wincol + total_width - 1 + TPL_LCOL(NULL)
- wp->w_popup_border[1];
if (line >= 0 && line < wp->w_height)