summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-03-19 22:11:51 +0100
committerBram Moolenaar <Bram@vim.org>2016-03-19 22:11:51 +0100
commit44a2f923c00f1384c9ecde12fb5b4711bc20702e (patch)
treeff48a0f263f488b023e5b4c7d45af05dade92e8f
parentcc6cf9b9f9045a7d8b5923ea0c556e9a4c2567d3 (diff)
patch 7.4.1611v7.4.1611
Problem: The versplit feature makes the code uneccessary complicated. Solution: Remove FEAT_VERTSPLIT, always support vertical splits when FEAT_WINDOWS is defined.
-rw-r--r--src/buffer.c13
-rw-r--r--src/charset.c6
-rw-r--r--src/eval.c8
-rw-r--r--src/ex_cmds.c2
-rw-r--r--src/ex_docmd.c24
-rw-r--r--src/ex_getln.c4
-rw-r--r--src/feature.h17
-rw-r--r--src/globals.h4
-rw-r--r--src/gui.c22
-rw-r--r--src/gui.h2
-rw-r--r--src/if_lua.c4
-rw-r--r--src/if_mzsch.c6
-rw-r--r--src/if_py_both.h4
-rw-r--r--src/if_ruby.c2
-rw-r--r--src/main.c2
-rw-r--r--src/misc1.c4
-rw-r--r--src/misc2.c4
-rw-r--r--src/move.c10
-rw-r--r--src/normal.c18
-rw-r--r--src/option.c27
-rw-r--r--src/option.h8
-rw-r--r--src/quickfix.c13
-rw-r--r--src/screen.c84
-rw-r--r--src/structs.h4
-rw-r--r--src/syntax.c2
-rw-r--r--src/term.c12
-rw-r--r--src/term.h2
-rw-r--r--src/ui.c20
-rw-r--r--src/version.c4
-rw-r--r--src/vim.h2
-rw-r--r--src/window.c204
31 files changed, 141 insertions, 397 deletions
diff --git a/src/buffer.c b/src/buffer.c
index 543b4a7078..9bc24bc126 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -4607,9 +4607,9 @@ do_arg_all(
old_curwin = curwin;
old_curtab = curtab;
-#ifdef FEAT_GUI
+# ifdef FEAT_GUI
need_mouse_correct = TRUE;
-#endif
+# endif
/*
* Try closing all windows that are not in the argument list.
@@ -4629,10 +4629,7 @@ do_arg_all(
buf = wp->w_buffer;
if (buf->b_ffname == NULL
|| (!keep_tabs && buf->b_nwindows > 1)
-#ifdef FEAT_VERTSPLIT
- || wp->w_width != Columns
-#endif
- )
+ || wp->w_width != Columns)
i = opened_len;
else
{
@@ -4901,13 +4898,11 @@ ex_buffer_all(exarg_T *eap)
{
wpnext = wp->w_next;
if ((wp->w_buffer->b_nwindows > 1
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
|| ((cmdmod.split & WSP_VERT)
? wp->w_height + wp->w_status_height < Rows - p_ch
- tabline_height()
: wp->w_width != Columns)
-#endif
-#ifdef FEAT_WINDOWS
|| (had_tab > 0 && wp != firstwin)
#endif
) && firstwin != lastwin
diff --git a/src/charset.c b/src/charset.c
index ad3f8bcfd7..e008399e15 100644
--- a/src/charset.c
+++ b/src/charset.c
@@ -1093,7 +1093,7 @@ win_lbr_chartabsize(
&& vim_isbreak(c)
&& !vim_isbreak(s[1])
&& wp->w_p_wrap
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
&& wp->w_width != 0
# endif
)
@@ -1250,10 +1250,10 @@ in_win_border(win_T *wp, colnr_T vcol)
int width1; /* width of first line (after line number) */
int width2; /* width of further lines */
-#ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
if (wp->w_width == 0) /* there is no border */
return FALSE;
-#endif
+# endif
width1 = W_WIDTH(wp) - win_col_off(wp);
if ((int)vcol < width1 - 1)
return FALSE;
diff --git a/src/eval.c b/src/eval.c
index a5c015d6a9..22ddafa872 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -13734,7 +13734,7 @@ f_has(typval_T *argvars, typval_T *rettv)
#ifdef FEAT_VIMINFO
"viminfo",
#endif
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
"vertsplit",
#endif
#ifdef FEAT_VIRTUALEDIT
@@ -20646,10 +20646,8 @@ f_winrestcmd(typval_T *argvars UNUSED, typval_T *rettv)
{
sprintf((char *)buf, "%dresize %d|", winnr, wp->w_height);
ga_concat(&ga, buf);
-# ifdef FEAT_VERTSPLIT
sprintf((char *)buf, "vert %dresize %d|", winnr, wp->w_width);
ga_concat(&ga, buf);
-# endif
++winnr;
}
ga_append(&ga, NUL);
@@ -20701,7 +20699,7 @@ f_winrestview(typval_T *argvars, typval_T *rettv UNUSED)
check_cursor();
win_new_height(curwin, curwin->w_height);
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
win_new_width(curwin, W_WIDTH(curwin));
# endif
changed_window_setting();
@@ -20756,7 +20754,7 @@ f_winwidth(typval_T *argvars, typval_T *rettv)
if (wp == NULL)
rettv->vval.v_number = -1;
else
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
rettv->vval.v_number = wp->w_width;
#else
rettv->vval.v_number = Columns;
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index 8a763c9a9d..b602979322 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -5867,11 +5867,9 @@ ex_help(exarg_T *eap)
* specified, the current window is vertically split and
* narrow. */
n = WSP_HELP;
-# ifdef FEAT_VERTSPLIT
if (cmdmod.split == 0 && curwin->w_width != Columns
&& curwin->w_width < 80)
n |= WSP_TOP;
-# endif
if (win_split(0, n) == FAIL)
goto erret;
#else
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 12730a93d2..26f4219521 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -2013,7 +2013,7 @@ do_one_cmd(
case 'v': if (checkforcmd(&ea.cmd, "vertical", 4))
{
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
cmdmod.split |= WSP_VERT;
#endif
continue;
@@ -7923,14 +7923,6 @@ ex_splitview(exarg_T *eap)
int browse_flag = cmdmod.browse;
# endif
-# ifndef FEAT_VERTSPLIT
- if (eap->cmdidx == CMD_vsplit || eap->cmdidx == CMD_vnew)
- {
- ex_ni(eap);
- return;
- }
-# endif
-
# ifdef FEAT_GUI
need_mouse_correct = TRUE;
# endif
@@ -7942,10 +7934,8 @@ ex_splitview(exarg_T *eap)
{
if (eap->cmdidx == CMD_split)
eap->cmdidx = CMD_new;
-# ifdef FEAT_VERTSPLIT
if (eap->cmdidx == CMD_vsplit)
eap->cmdidx = CMD_vnew;
-# endif
}
# endif
@@ -7964,9 +7954,7 @@ ex_splitview(exarg_T *eap)
# endif
# ifdef FEAT_BROWSE
if (cmdmod.browse
-# ifdef FEAT_VERTSPLIT
&& eap->cmdidx != CMD_vnew
-# endif
&& eap->cmdidx != CMD_new)
{
# ifdef FEAT_AUTOCMD
@@ -8224,11 +8212,10 @@ ex_resize(exarg_T *eap)
;
}
-#ifdef FEAT_GUI
+# ifdef FEAT_GUI
need_mouse_correct = TRUE;
-#endif
+# endif
n = atol((char *)eap->arg);
-#ifdef FEAT_VERTSPLIT
if (cmdmod.split & WSP_VERT)
{
if (*eap->arg == '-' || *eap->arg == '+')
@@ -8238,7 +8225,6 @@ ex_resize(exarg_T *eap)
win_setwidth_win((int)n, wp);
}
else
-#endif
{
if (*eap->arg == '-' || *eap->arg == '+')
n += curwin->w_height;
@@ -8397,7 +8383,7 @@ do_exedit(
if ((eap->cmdidx == CMD_new
|| eap->cmdidx == CMD_tabnew
|| eap->cmdidx == CMD_tabedit
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
|| eap->cmdidx == CMD_vnew
#endif
) && *eap->arg == NUL)
@@ -8409,7 +8395,7 @@ do_exedit(
old_curwin == NULL ? curwin : NULL);
}
else if ((eap->cmdidx != CMD_split
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& eap->cmdidx != CMD_vsplit
#endif
)
diff --git a/src/ex_getln.c b/src/ex_getln.c
index 8c77460be2..4577d1e8ec 100644
--- a/src/ex_getln.c
+++ b/src/ex_getln.c
@@ -500,11 +500,7 @@ getcmdline(
}
else
{
-# ifdef FEAT_VERTSPLIT
win_redraw_last_status(topframe);
-# else
- lastwin->w_redr_status = TRUE;
-# endif
redraw_statuslines();
}
KeyTyped = skt;
diff --git a/src/feature.h b/src/feature.h
index 455ab20ea0..75b888033f 100644
--- a/src/feature.h
+++ b/src/feature.h
@@ -97,6 +97,7 @@
/*
* +windows Multiple windows. Without this there is no help
* window and no status lines.
+ * +vertsplit Vertically split windows.
*/
#ifdef FEAT_SMALL
# define FEAT_WINDOWS
@@ -112,16 +113,6 @@
#endif
/*
- * +vertsplit Vertically split windows.
- */
-#ifdef FEAT_NORMAL
-# define FEAT_VERTSPLIT
-#endif
-#if defined(FEAT_VERTSPLIT) && !defined(FEAT_WINDOWS)
-# define FEAT_WINDOWS
-#endif
-
-/*
* +cmdhist Command line history.
*/
#ifdef FEAT_SMALL
@@ -144,8 +135,8 @@
# define FEAT_JUMPLIST
#endif
-/* the cmdline-window requires FEAT_VERTSPLIT and FEAT_CMDHIST */
-#if defined(FEAT_VERTSPLIT) && defined(FEAT_CMDHIST)
+/* the cmdline-window requires FEAT_WINDOWS and FEAT_CMDHIST */
+#if defined(FEAT_WINDOWS) && defined(FEAT_CMDHIST)
# define FEAT_CMDWIN
#endif
@@ -601,7 +592,7 @@
* +mksession ":mksession" command.
* Requires +windows and +vertsplit.
*/
-#if defined(FEAT_NORMAL) && defined(FEAT_WINDOWS) && defined(FEAT_VERTSPLIT)
+#if defined(FEAT_NORMAL) && defined(FEAT_WINDOWS)
# define FEAT_SESSION
#endif
diff --git a/src/globals.h b/src/globals.h
index bd9ef5c877..05dec4a0e3 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -427,7 +427,7 @@ EXTERN int gui_prev_topfill INIT(= 0);
EXTERN int drag_status_line INIT(= FALSE); /* dragging the status line */
EXTERN int postponed_mouseshape INIT(= FALSE); /* postponed updating the
mouse pointer shape */
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
EXTERN int drag_sep_line INIT(= FALSE); /* dragging vert separator */
# endif
# endif
@@ -1547,9 +1547,7 @@ EXTERN char_u e_umark[] INIT(= N_("E78: Unknown mark"));
EXTERN char_u e_wildexpand[] INIT(= N_("E79: Cannot expand wildcards"));
#ifdef FEAT_WINDOWS
EXTERN char_u e_winheight[] INIT(= N_("E591: 'winheight' cannot be smaller than 'winminheight'"));
-# ifdef FEAT_VERTSPLIT
EXTERN char_u e_winwidth[] INIT(= N_("E592: 'winwidth' cannot be smaller than 'winminwidth'"));
-# endif
#endif
EXTERN char_u e_write[] INIT(= N_("E80: Error while writing"));
EXTERN char_u e_zerocount[] INIT(= N_("Zero count"));
diff --git a/src/gui.c b/src/gui.c
index d5c0d3e224..8999f793ff 100644
--- a/src/gui.c
+++ b/src/gui.c
@@ -1812,7 +1812,7 @@ gui_write(
gui.scroll_region_bot = arg1;
}
break;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
case 'V': /* Set vertical scroll region */
if (arg1 < arg2)
{
@@ -3128,7 +3128,7 @@ button_set:
&& button != MOUSE_DRAG
# ifdef FEAT_MOUSESHAPE
&& !drag_status_line
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
&& !drag_sep_line
# endif
# endif
@@ -3406,7 +3406,7 @@ gui_init_which_components(char_u *oldval UNUSED)
case GO_RIGHT:
gui.which_scrollbars[SBAR_RIGHT] = TRUE;
break;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
case GO_VLEFT:
if (win_hasvertsplit())
gui.which_scrollbars[SBAR_LEFT] = TRUE;
@@ -3839,7 +3839,7 @@ gui_create_scrollbar(scrollbar_T *sb, int type, win_T *wp)
sb->max = 1;
sb->top = 0;
sb->height = 0;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
sb->width = 0;
#endif
sb->status_height = 0;
@@ -4121,7 +4121,7 @@ gui_update_scrollbars(
long val, size, max; /* need 32 bits here */
int which_sb;
int h, y;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
static win_T *prev_curwin = NULL;
#endif
@@ -4219,10 +4219,8 @@ gui_update_scrollbars(
#ifdef FEAT_WINDOWS
|| sb->top != wp->w_winrow
|| sb->status_height != wp->w_status_height
-# ifdef FEAT_VERTSPLIT
|| sb->width != wp->w_width
|| prev_curwin != curwin
-# endif
#endif
)
{
@@ -4232,9 +4230,7 @@ gui_update_scrollbars(
#ifdef FEAT_WINDOWS
sb->top = wp->w_winrow;
sb->status_height = wp->w_status_height;
-# ifdef FEAT_VERTSPLIT
sb->width = wp->w_width;
-# endif
#endif
/* Calculate height and position in pixels */
@@ -4316,7 +4312,7 @@ gui_update_scrollbars(
val, size, max);
}
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
prev_curwin = curwin;
#endif
--hold_gui_events;
@@ -4333,7 +4329,7 @@ gui_do_scrollbar(
int which, /* SBAR_LEFT or SBAR_RIGHT */
int enable) /* TRUE to enable scrollbar */
{
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
int midcol = curwin->w_wincol + curwin->w_width / 2;
int has_midcol = (wp->w_wincol <= midcol
&& wp->w_wincol + wp->w_width >= midcol);
@@ -4857,7 +4853,7 @@ gui_mouse_moved(int x, int y)
st[2] = KE_FILLER;
st[3] = (char_u)MOUSE_LEFT;
fill_mouse_coord(st + 4,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
wp->w_wincol == 0 ? -1 : wp->w_wincol + MOUSE_COLOFF,
#else
-1,
@@ -4934,11 +4930,9 @@ xy2win(int x UNUSED, int y UNUSED)
}
else if (row > wp->w_height) /* below status line */
update_mouseshape(SHAPE_IDX_CLINE);
-# ifdef FEAT_VERTSPLIT
else if (!(State & CMDLINE) && W_VSEP_WIDTH(wp) > 0 && col == wp->w_width
&& (row != wp->w_height || !stl_connected(wp)) && msg_scrolled == 0)
update_mouseshape(SHAPE_IDX_VSEP);
-# endif
else if (!(State & CMDLINE) && W_STATUS_HEIGHT(wp) > 0
&& row == wp->w_height && msg_scrolled == 0)
update_mouseshape(SHAPE_IDX_STATUS);
diff --git a/src/gui.h b/src/gui.h
index f119de5c12..4e557ad3b5 100644
--- a/src/gui.h
+++ b/src/gui.h
@@ -179,7 +179,7 @@ typedef struct GuiScrollbar
/* Values measured in characters: */
int top; /* Top of scroll bar (chars from row 0) */
int height; /* Current height of scroll bar in rows */
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
int width; /* Current width of scroll bar in cols */
#endif
int status_height; /* Height of status line */
diff --git a/src/if_lua.c b/src/if_lua.c
index 1c8512fec5..8d761004d3 100644
--- a/src/if_lua.c
+++ b/src/if_lua.c
@@ -1177,7 +1177,7 @@ luaV_window_index(lua_State *L)
lua_pushinteger(L, w->w_cursor.lnum);
else if (strncmp(s, "col", 3) == 0)
lua_pushinteger(L, w->w_cursor.col + 1);
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
else if (strncmp(s, "width", 5) == 0)
lua_pushinteger(L, W_WIDTH(w));
#endif
@@ -1220,7 +1220,7 @@ luaV_window_newindex (lua_State *L)
w->w_cursor.col = v - 1;
update_screen(VALID);
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
else if (strncmp(s, "width", 5) == 0)
{
win_T *win = curwin;
diff --git a/src/if_mzsch.c b/src/if_mzsch.c
index 4be3c7201b..a0c6483c1e 100644
--- a/src/if_mzsch.c
+++ b/src/if_mzsch.c
@@ -145,7 +145,7 @@ static Scheme_Object *get_window_num(void *, int, Scheme_Object **);
static Scheme_Object *get_window_buffer(void *, int, Scheme_Object **);
static Scheme_Object *get_window_height(void *, int, Scheme_Object **);
static Scheme_Object *set_window_height(void *, int, Scheme_Object **);
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
static Scheme_Object *get_window_width(void *, int, Scheme_Object **);
static Scheme_Object *set_window_width(void *, int, Scheme_Object **);
#endif
@@ -2066,7 +2066,7 @@ set_window_height(void *data, int argc, Scheme_Object **argv)
return scheme_void;
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
/* (get-win-width [window]) */
static Scheme_Object *
get_window_width(void *data, int argc, Scheme_Object **argv)
@@ -3718,7 +3718,7 @@ static Vim_Prim prims[]=
{get_window_buffer, "get-win-buffer", 0, 1},
{get_window_height, "get-win-height", 0, 1},
{set_window_height, "set-win-height", 1, 2},
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
{get_window_width, "get-win-width", 0, 1},
{set_window_width, "set-win-width", 1, 2},
#endif
diff --git a/src/if_py_both.h b/src/if_py_both.h
index 8070bd6e0e..3a80cb4eff 100644
--- a/src/if_py_both.h
+++ b/src/if_py_both.h
@@ -3673,8 +3673,6 @@ WindowAttr(WindowObject *self, char *name)
#ifdef FEAT_WINDOWS
else if (strcmp(name, "row") == 0)
return PyLong_FromLong((long)(self->win->w_winrow));
-#endif
-#ifdef FEAT_VERTSPLIT
else if (strcmp(name, "width") == 0)
return PyLong_FromLong((long)(W_WIDTH(self->win)));
else if (strcmp(name, "col") == 0)
@@ -3765,7 +3763,7 @@ WindowSetattr(WindowObject *self, char *name, PyObject *valObject)
return 0;
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
else if (strcmp(name, "width") == 0)
{
long width;
diff --git a/src/if_ruby.c b/src/if_ruby.c
index d609d344ea..a7a7772e3e 100644
--- a/src/if_ruby.c
+++ b/src/if_ruby.c
@@ -1449,7 +1449,7 @@ static VALUE window_width(VALUE self UNUSED)
static VALUE window_set_width(VALUE self UNUSED, VALUE width)
{
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
win_T *win = get_win(self);
win_T *savewin = curwin;
diff --git a/src/main.c b/src/main.c
index 83e55d1a70..35c940f6ab 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2088,7 +2088,7 @@ command_line_scan(mparm_T *parmp)
break;
case 'O': /* "-O[N]" open N vertical split windows */
-#if defined(FEAT_VERTSPLIT) && defined(FEAT_WINDOWS)
+#ifdef FEAT_WINDOWS
/* default is 0: open window for each file */
parmp->window_count = get_number_arg((char_u *)argv[0],
&argv_idx, 0);
diff --git a/src/misc1.c b/src/misc1.c
index 27ca83ef3c..a764a7b07e 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -1976,7 +1976,7 @@ plines_win_nofill(
if (!wp->w_p_wrap)
return 1;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (wp->w_width == 0)
return 1;
#endif
@@ -2052,7 +2052,7 @@ plines_win_col(win_T *wp, linenr_T lnum, long column)
if (!wp->w_p_wrap)
return lines + 1;
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (wp->w_width == 0)
return lines + 1;
#endif
diff --git a/src/misc2.c b/src/misc2.c
index e247a92ac5..ca340b71e5 100644
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -169,7 +169,7 @@ coladvance2(
if (finetune
&& curwin->w_p_wrap
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
&& curwin->w_width != 0
# endif
&& wcol >= (colnr_T)width)
@@ -3633,7 +3633,7 @@ get_shape_idx(int mouse)
}
if (mouse && drag_status_line)
return SHAPE_IDX_SDRAG;
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
if (mouse && drag_sep_line)
return SHAPE_IDX_VDRAG;
# endif
diff --git a/src/move.c b/src/move.c
index a505873f0b..1a00a4d16e 100644
--- a/src/move.c
+++ b/src/move.c
@@ -990,7 +990,7 @@ curs_columns(
curwin->w_wrow = curwin->w_height - 1;
}
else if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
@@ -1096,7 +1096,7 @@ curs_columns(
&& curwin->w_height != 0
&& curwin->w_cursor.lnum == curwin->w_topline
&& width > 0
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
@@ -1259,7 +1259,7 @@ scrolldown(
*/
wrow = curwin->w_wrow;
if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
@@ -1468,7 +1468,7 @@ scrolldown_clamp(void)
end_row += plines(curwin->w_topline - 1);
#endif
if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
@@ -1532,7 +1532,7 @@ scrollup_clamp(void)
start_row = curwin->w_wrow - plines(curwin->w_topline);
#endif
if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
diff --git a/src/normal.c b/src/normal.c
index 7f0d8bd74c..6af6296c9b 100644
--- a/src/normal.c
+++ b/src/normal.c
@@ -2306,8 +2306,6 @@ do_mouse(
int in_status_line; /* mouse in status line */
#ifdef FEAT_WINDOWS
static int in_tab_line = FALSE; /* mouse clicked in tab line */
-#endif
-#ifdef FEAT_VERTSPLIT
int in_sep_line; /* mouse in vertical separator line */
#endif
int c1, c2;
@@ -2384,13 +2382,11 @@ do_mouse(
drag_status_line = FALSE;
update_mouseshape(SHAPE_IDX_STATUS);
}
-# ifdef FEAT_VERTSPLIT
if (!is_drag && drag_sep_line)
{
drag_sep_line = FALSE;
update_mouseshape(SHAPE_IDX_VSEP);
}
-# endif
#endif
/*
@@ -2784,9 +2780,7 @@ do_mouse(
oap == NULL ? NULL : &(oap->inclusive), which_button);
moved = (jump_flags & CURSOR_MOVED);
in_status_line = (jump_flags & IN_STATUS_LINE);
-#ifdef FEAT_VERTSPLIT
in_sep_line = (jump_flags & IN_SEP_LINE);
-#endif
#ifdef FEAT_NETBEANS_INTG
if (isNetbeansBuffer(curbuf)
@@ -3022,7 +3016,6 @@ do_mouse(
}
#endif
}
-#ifdef FEAT_VERTSPLIT
else if (in_sep_line)
{
# ifdef FEAT_MOUSESHAPE
@@ -3033,7 +3026,6 @@ do_mouse(
}
# endif
}
-#endif
else if ((mod_mask & MOD_MASK_MULTI_CLICK) && (State & (NORMAL | INSERT))
&& mouse_has(MOUSE_VISUAL))
{
@@ -4401,10 +4393,10 @@ nv_screengo(oparg_T *oap, int dir, long dist)
if (width2 == 0)
width2 = 1; /* avoid divide by zero */
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
if (curwin->w_width != 0)
- {
#endif
+ {
/*
* Instead of sticking at the last character of the buffer line we
* try to stick in the last column of the screen.
@@ -4491,9 +4483,7 @@ nv_screengo(oparg_T *oap, int dir, long dist)
}
}
}
-#ifdef FEAT_VERTSPLIT
}
-#endif
if (virtual_active() && atend)
coladvance(MAXCOL);
@@ -7987,7 +7977,7 @@ nv_g_cmd(cmdarg_T *cap)
oap->motion_type = MCHAR;
oap->inclusive = FALSE;
if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
@@ -8054,7 +8044,7 @@ nv_g_cmd(cmdarg_T *cap)
oap->motion_type = MCHAR;
oap->inclusive = TRUE;
if (curwin->w_p_wrap
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
&& curwin->w_width != 0
#endif
)
diff --git a/src/option.c b/src/option.c
index fe2ae179a9..616f9a3039 100644
--- a/src/option.c
+++ b/src/option.c
@@ -243,8 +243,6 @@
#define PV_UL OPT_BOTH(OPT_BUF(BV_UL))
#ifdef FEAT_WINDOWS
# define PV_WFH OPT_WIN(WV_WFH)
-#endif
-#ifdef FEAT_VERTSPLIT
# define PV_WFW OPT_WIN(WV_WFW)
#endif
#define PV_WRAP OPT_WIN(WV_WRAP)
@@ -466,10 +464,9 @@ struct vimoption
# define ISP_LATIN1 (char_u *)"@,161-255"
#endif
-/* The 16 bit MS-DOS version is low on space, make the string as short as
- * possible when compiling with few features. */
+/* Make the string as short as possible when compiling with few features. */
#if defined(FEAT_DIFF) || defined(FEAT_FOLDING) || defined(FEAT_SPELL) \
- || defined(FEAT_VERTSPLIT) || defined(FEAT_CLIPBOARD) \
+ || defined(FEAT_WINDOWS) || defined(FEAT_CLIPBOARD) \
|| defined(FEAT_INS_EXPAND) || defined(FEAT_SYN_HL) || defined(FEAT_CONCEAL)
# define HIGHLIGHT_INIT "8:SpecialKey,@:NonText,d:Directory,e:ErrorMsg,i:IncSearch,l:Search,m:MoreMsg,M:ModeMsg,n:LineNr,N:CursorLineNr,r:Question,s:StatusLine,S:StatusLineNC,c:VertSplit,t:Title,v:Visual,V:VisualNOS,w:WarningMsg,W:WildMenu,f:Folded,F:FoldColumn,A:DiffAdd,C:DiffChange,D:DiffDelete,T:DiffText,>:SignColumn,-:Conceal,B:SpellBad,P:SpellCap,R:SpellRare,L:SpellLocal,+:Pmenu,=:PmenuSel,x:PmenuSbar,X:PmenuThumb,*:TabLine,#:TabLineSel,_:TabLineFill,!:CursorColumn,.:CursorLine,o:ColorColumn"
#else
@@ -1040,7 +1037,7 @@ static struct vimoption options[] =
(char_u *)&p_dy, PV_NONE,
{(char_u *)"", (char_u *)0L} SCRIPTID_INIT},
{"eadirection", "ead", P_STRING|P_VI_DEF,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
(char_u *)&p_ead, PV_NONE,
{(char_u *)"both", (char_u *)0L}
#else
@@ -2492,7 +2489,7 @@ static struct vimoption options[] =
#endif
{(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT},
{"splitright", "spr", P_BOOL|P_VI_DEF,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
(char_u *)&p_spr, PV_NONE,
#else
(char_u *)NULL, PV_NONE,
@@ -2892,7 +2889,7 @@ static struct vimoption options[] =
#endif
{(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT},
{"winfixwidth", "wfw", P_BOOL|P_VI_DEF|P_RSTAT,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
(char_u *)VAR_WIN, PV_WFW,
#else
(char_u *)NULL, PV_NONE,
@@ -2906,14 +2903,14 @@ static struct vimoption options[] =
#endif
{(char_u *)1L, (char_u *)0L} SCRIPTID_INIT},
{"winminwidth", "wmw", P_NUM|P_VI_DEF,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
(char_u *)&p_wmw, PV_NONE,
#else
(char_u *)NULL, PV_NONE,
#endif
{(char_u *)1L, (char_u *)0L} SCRIPTID_INIT},
{"winwidth", "wiw", P_NUM|P_VI_DEF,
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
(char_u *)&p_wiw, PV_NONE,
#else
(char_u *)NULL, PV_NONE,
@@ -2966,7 +2963,7 @@ static struct vimoption options[] =
p_term("t_CS", T_CCS)
p_term("t_Cs", T_UCS)
p_term("t_cs", T_CS)
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
p_term("t_CV", T_CSV)
#endif
p_term("t_da", T_DA)
@@ -3049,7 +3046,7 @@ static char *(p_bsdir_values[]) = {"current", "last", "buffer", NULL};
static char *(p_scbopt_values[]) = {"ver", "hor", "jump", NULL};
#endif
static char *(p_debug_values[]) = {"msg", "throw", "beep", NULL};
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
static char *(p_ead_values[]) = {"both", "ver", "hor", NULL};
#endif
#if defined(FEAT_QUICKFIX)
@@ -6796,7 +6793,7 @@ did_set_string_option(
}
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
/* 'eadirection' */
else if (varp == &p_ead)
{
@@ -8468,7 +8465,7 @@ set_num_option(
win_setminheight();
}
-# ifdef FEAT_VERTSPLIT
+# ifdef FEAT_WINDOWS
else if (pp == &p_wiw)
{
if (p_wiw < 1)
@@ -10259,8 +10256,6 @@ get_varp(struct vimoption *p)
#endif
#ifdef FEAT_WINDOWS
case PV_WFH: return (char_u *)&(curwin->w_p_wfh);
-#endif
-#ifdef FEAT_VERTSPLIT
case PV_WFW: return (char_u *)&(curwin->w_p_wfw);
#endif
#if defined(FEAT_WINDOWS) && defined(FEAT_QUICKFIX)
diff --git a/src/option.h b/src/option.h
index e962ba3793..cf7ba04e7e 100644
--- a/src/option.h
+++ b/src/option.h
@@ -463,7 +463,7 @@ static char *(p_dy_values[]) = {"lastline", "uhex", NULL};
#define DY_LASTLINE 0x001
#define DY_UHEX 0x002
EXTERN int p_ed; /* 'edcompatible' */
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
EXTERN char_u *p_ead; /* 'eadirection' */
#endif
EXTERN int p_ea; /* 'equalalways' */
@@ -802,7 +802,7 @@ EXTERN char_u *p_tal; /* 'tabline' */
#ifdef FEAT_SPELL
EXTERN char_u *p_sps; /* 'spellsuggest' */
#endif
-#ifdef FEAT_VERTSPLIT
+#ifdef FEAT_WINDOWS
EXTERN int p_spr; /* 'splitright' */
#endif
EXTERN int p_sol; /* 'startofline' */
@@ -957,8 +957,6 @@ EXTERN int p_wmnu; /* 'wildmenu' */
#ifdef FEAT_WINDOWS
EXTERN long p_wh; /* 'winheight' */
EXTERN long p_wmh; /* 'winminheight' */
-#endif
-#ifdef FEAT_VERTSPLIT
EXTERN long p_wmw; /* 'winminwidth' */
EXTERN long p_wiw; /* 'winwidth' */
#endif
@@ -1172,8 +1170,6 @@ enum
#endif