Skip to content

Commit

Permalink
patch 8.1.0041: attribute "width" missing from python window attribut…
Browse files Browse the repository at this point in the history
…e list

Problem:    Attribute "width" missing from python window attribute list.
Solution:   Add the item. (Ken Takata) Order the list like the items are used
            in the WindowAttr() function.
  • Loading branch information
brammool committed Jun 10, 2018
1 parent e31e256 commit e950f99
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 4 deletions.
15 changes: 13 additions & 2 deletions src/if_py_both.h
Original file line number Diff line number Diff line change
Expand Up @@ -3836,9 +3836,20 @@ get_firstwin(TabPageObject *tabObject)
else
return firstwin;
}

// Use the same order as in the WindowAttr() function.
static char *WindowAttrs[] = {
"buffer", "cursor", "height", "vars", "options", "number", "row", "col",
"tabpage", "valid",
"buffer",
"cursor",
"height",
"row",
"width",
"col",
"vars",
"options",
"number",
"tabpage",
"valid",
NULL
};

Expand Down
2 changes: 1 addition & 1 deletion src/testdir/test86.ok
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ vim.current.window:Window:True
vim.current.tabpage:TabPage:True
current:__dir__,__members__,buffer,line,range,tabpage,window
buffer:__dir__,__members__,append,mark,name,number,options,range,valid,vars
window:__dir__,__members__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars
window:__dir__,__members__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars,width
tabpage:__dir__,__members__,number,valid,vars,window,windows
range:__dir__,__members__,append,end,start
dictionary:__dir__,__members__,get,has_key,items,keys,locked,pop,popitem,scope,update,values
Expand Down
2 changes: 1 addition & 1 deletion src/testdir/test87.ok
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ vim.current.window:Window:True
vim.current.tabpage:TabPage:True
current:__dir__,buffer,line,range,tabpage,window
buffer:__dir__,append,mark,name,number,options,range,valid,vars
window:__dir__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars
window:__dir__,buffer,col,cursor,height,number,options,row,tabpage,valid,vars,width
tabpage:__dir__,number,valid,vars,window,windows
range:__dir__,append,end,start
dictionary:__dir__,get,has_key,items,keys,locked,pop,popitem,scope,update,values
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -761,6 +761,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
41,
/**/
40,
/**/
Expand Down

0 comments on commit e950f99

Please sign in to comment.