aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-08-23 07:31:39 -0400
committerJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-08-23 07:46:51 -0400
commit2a1887c2df27c5f91f0f2f6ad6c70da60239cfce (patch)
treed3fcdf232e623f322a64f0fd3b79518bfe4d7429 /src/nvim/eval.c
parentc58054c231f11cfd911795b572029e9360835bbb (diff)
downloadrneovim-2a1887c2df27c5f91f0f2f6ad6c70da60239cfce.tar.gz
rneovim-2a1887c2df27c5f91f0f2f6ad6c70da60239cfce.tar.bz2
rneovim-2a1887c2df27c5f91f0f2f6ad6c70da60239cfce.zip
vim-patch:8.1.0187: getwininfo() and win_screenpos() return different numbers
Problem: getwininfo() and win_screenpos() return different numbers. Solution: Add one to "wincol" and "winrow" from getwininfo(). https://github.com/vim/vim/commit/7132ddc1014a4e1230f0080e418221e5843e1277
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r--src/nvim/eval.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 94f559c0dc..3d56522f79 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -10839,12 +10839,12 @@ static dict_T *get_win_info(win_T *wp, int16_t tpnr, int16_t winnr)
tv_dict_add_nr(dict, S_LEN("winnr"), winnr);
tv_dict_add_nr(dict, S_LEN("winid"), wp->handle);
tv_dict_add_nr(dict, S_LEN("height"), wp->w_height);
- tv_dict_add_nr(dict, S_LEN("winrow"), wp->w_winrow);
+ tv_dict_add_nr(dict, S_LEN("winrow"), wp->w_winrow + 1);
tv_dict_add_nr(dict, S_LEN("topline"), wp->w_topline);
tv_dict_add_nr(dict, S_LEN("botline"), wp->w_botline - 1);
tv_dict_add_nr(dict, S_LEN("width"), wp->w_width);
tv_dict_add_nr(dict, S_LEN("bufnr"), wp->w_buffer->b_fnum);
- tv_dict_add_nr(dict, S_LEN("wincol"), wp->w_wincol);
+ tv_dict_add_nr(dict, S_LEN("wincol"), wp->w_wincol + 1);
tv_dict_add_nr(dict, S_LEN("terminal"), bt_terminal(wp->w_buffer));
tv_dict_add_nr(dict, S_LEN("quickfix"), bt_quickfix(wp->w_buffer));