forked from aniani/vim
patch 8.0.0543: test_edit causes older xfce4-terminal to close
Problem: Test_edit causes older xfce4-terminal to close. (Dominique Pelle) Solution: Reduce number of columns to 2000. Try to restore the window position.
This commit is contained in:
@@ -5241,24 +5241,6 @@ f_getwininfo(typval_T *argvars, typval_T *rettv)
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* "getwinposx()" function
|
||||
*/
|
||||
static void
|
||||
f_getwinposx(typval_T *argvars UNUSED, typval_T *rettv)
|
||||
{
|
||||
rettv->vval.v_number = -1;
|
||||
#ifdef FEAT_GUI
|
||||
if (gui.in_use)
|
||||
{
|
||||
int x, y;
|
||||
|
||||
if (gui_mch_get_winpos(&x, &y) == OK)
|
||||
rettv->vval.v_number = x;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* "win_findbuf()" function
|
||||
*/
|
||||
@@ -5306,6 +5288,32 @@ f_win_id2win(typval_T *argvars, typval_T *rettv)
|
||||
rettv->vval.v_number = win_id2win(argvars);
|
||||
}
|
||||
|
||||
/*
|
||||
* "getwinposx()" function
|
||||
*/
|
||||
static void
|
||||
f_getwinposx(typval_T *argvars UNUSED, typval_T *rettv)
|
||||
{
|
||||
rettv->vval.v_number = -1;
|
||||
#ifdef FEAT_GUI
|
||||
if (gui.in_use)
|
||||
{
|
||||
int x, y;
|
||||
|
||||
if (gui_mch_get_winpos(&x, &y) == OK)
|
||||
rettv->vval.v_number = x;
|
||||
}
|
||||
#endif
|
||||
#if defined(HAVE_TGETENT) && defined(FEAT_TERMRESPONSE)
|
||||
{
|
||||
int x, y;
|
||||
|
||||
if (term_get_winpos(&x, &y) == OK)
|
||||
rettv->vval.v_number = x;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* "getwinposy()" function
|
||||
*/
|
||||
@@ -5322,6 +5330,14 @@ f_getwinposy(typval_T *argvars UNUSED, typval_T *rettv)
|
||||
rettv->vval.v_number = y;
|
||||
}
|
||||
#endif
|
||||
#if defined(HAVE_TGETENT) && defined(FEAT_TERMRESPONSE)
|
||||
{
|
||||
int x, y;
|
||||
|
||||
if (term_get_winpos(&x, &y) == OK)
|
||||
rettv->vval.v_number = y;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user