Mercurial > vim
diff src/ui.c @ 16253:f28ef3d27f91 v8.1.1131
patch 8.1.1131: getwinpos() does not work in the MS-Windows console
commit https://github.com/vim/vim/commit/16c34c37659e6afca74169969bdacb6b866548c9
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Apr 6 22:01:24 2019 +0200
patch 8.1.1131: getwinpos() does not work in the MS-Windows console
Problem: getwinpos() does not work in the MS-Windows console.
Solution: Implement getwinpos().
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 06 Apr 2019 22:15:04 +0200 |
parents | e0a6298bd70f |
children | 7ae2396cef62 |
line wrap: on
line diff
--- a/src/ui.c +++ b/src/ui.c @@ -629,6 +629,7 @@ ui_new_shellsize(void) #if ((defined(FEAT_EVAL) || defined(FEAT_TERMINAL)) \ && (defined(FEAT_GUI) \ + || defined(MSWIN) \ || (defined(HAVE_TGETENT) && defined(FEAT_TERMRESPONSE)))) \ || defined(PROTO) /* @@ -642,10 +643,14 @@ ui_get_winpos(int *x, int *y, varnumber_ if (gui.in_use) return gui_mch_get_winpos(x, y); # endif -# if defined(HAVE_TGETENT) && defined(FEAT_TERMRESPONSE) +# if defined(MSWIN) && !defined(FEAT_GUI) + return mch_get_winpos(x, y); +# else +# if defined(HAVE_TGETENT) && defined(FEAT_TERMRESPONSE) return term_get_winpos(x, y, timeout); -# else +# else return FAIL; +# endif # endif } #endif