Karsten Hopp 7b3c19
To: vim_dev@googlegroups.com
Karsten Hopp 7b3c19
Subject: Patch 7.4.212
Karsten Hopp 7b3c19
Fcc: outbox
Karsten Hopp 7b3c19
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 7b3c19
Mime-Version: 1.0
Karsten Hopp 7b3c19
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 7b3c19
Content-Transfer-Encoding: 8bit
Karsten Hopp 7b3c19
------------
Karsten Hopp 7b3c19
Karsten Hopp 7b3c19
Patch 7.4.212 (after 7.4.200)
Karsten Hopp 7b3c19
Problem:    Now that the +visual feature is always enabled the #ifdefs for it
Karsten Hopp 7b3c19
	    are not useful.
Karsten Hopp 7b3c19
Solution:   Remove the checks for FEAT_VISUAL.
Karsten Hopp 7b3c19
Files:	    src/buffer.c, src/charset.c, src/edit.c, src/eval.c,
Karsten Hopp 7b3c19
	    src/ex_cmds.c, src/ex_docmd.c, src/fold.c, src/getchar.c,
Karsten Hopp 7b3c19
	    src/gui.c, src/gui_mac.c, src/gui_w48.c, src/main.c, src/mark.c,
Karsten Hopp 7b3c19
	    src/menu.c, src/misc2.c, src/move.c, src/netbeans.c, src/normal.c,
Karsten Hopp 7b3c19
	    src/ops.c, src/option.c, src/os_msdos.c, src/os_qnx.c,
Karsten Hopp 7b3c19
	    src/quickfix.c, src/regexp.c, src/regexp_nfa.c, src/screen.c,
Karsten Hopp 7b3c19
	    src/search.c, src/spell.c, src/syntax.c, src/term.c, src/ui.c,
Karsten Hopp 7b3c19
	    src/undo.c, src/version.c, src/window.c, src/feature.h,
Karsten Hopp 7b3c19
	    src/globals.h, src/option.h, src/os_win32.h, src/structs.h
Karsten Hopp 7b3c19
Karsten Hopp 7b3c19
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/buffer.c	2014-03-12 18:55:52.100906804 +0100
Karsten Hopp 7b3c19
--- src/buffer.c	2014-03-23 13:01:39.843144050 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1432,1441 ****
Karsten Hopp 7b3c19
  	curwin->w_alt_fnum = curbuf->b_fnum; /* remember alternate file */
Karsten Hopp 7b3c19
      buflist_altfpos(curwin);			 /* remember curpos */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Don't restart Select mode after switching to another buffer. */
Karsten Hopp 7b3c19
      VIsual_reselect = FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* close_windows() or apply_autocmds() may change curbuf */
Karsten Hopp 7b3c19
      prevbuf = curbuf;
Karsten Hopp 7b3c19
--- 1432,1439 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/charset.c	2013-02-06 16:20:01.000000000 +0100
Karsten Hopp 7b3c19
--- src/charset.c	2014-03-23 13:02:19.467144657 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1380,1389 ****
Karsten Hopp 7b3c19
  		&& (State & NORMAL)
Karsten Hopp 7b3c19
  		&& !wp->w_p_list
Karsten Hopp 7b3c19
  		&& !virtual_active()
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		&& !(VIsual_active
Karsten Hopp 7b3c19
! 				   && (*p_sel == 'e' || ltoreq(*pos, VIsual)))
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		)
Karsten Hopp 7b3c19
  	    *cursor = vcol + incr - 1;	    /* cursor at end */
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
--- 1380,1386 ----
Karsten Hopp 7b3c19
  		&& (State & NORMAL)
Karsten Hopp 7b3c19
  		&& !wp->w_p_list
Karsten Hopp 7b3c19
  		&& !virtual_active()
Karsten Hopp 7b3c19
! 		&& !(VIsual_active && (*p_sel == 'e' || ltoreq(*pos, VIsual)))
Karsten Hopp 7b3c19
  		)
Karsten Hopp 7b3c19
  	    *cursor = vcol + incr - 1;	    /* cursor at end */
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1463,1469 ****
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Get the leftmost and rightmost virtual column of pos1 and pos2.
Karsten Hopp 7b3c19
   * Used for Visual block mode.
Karsten Hopp 7b3c19
--- 1460,1465 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1500,1506 ****
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	*right = to1;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * skipwhite: skip over ' ' and '\t'.
Karsten Hopp 7b3c19
--- 1496,1501 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/edit.c	2014-02-22 23:03:48.712901208 +0100
Karsten Hopp 7b3c19
--- src/edit.c	2014-03-23 13:03:11.951145462 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 220,228 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  static void ins_ctrl_ __ARGS((void));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static int ins_start_select __ARGS((int c));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  static void ins_insert __ARGS((int replaceState));
Karsten Hopp 7b3c19
  static void ins_ctrl_o __ARGS((void));
Karsten Hopp 7b3c19
  static void ins_shift __ARGS((int c, int lastc));
Karsten Hopp 7b3c19
--- 220,226 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 932,938 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * If 'keymodel' contains "startsel", may start selection.  If it
Karsten Hopp 7b3c19
  	 * does, a CTRL-O and c will be stuffed, we need to get these
Karsten Hopp 7b3c19
--- 930,935 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 940,946 ****
Karsten Hopp 7b3c19
  	 */
Karsten Hopp 7b3c19
  	if (ins_start_select(c))
Karsten Hopp 7b3c19
  	    continue;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * The big switch to handle a character in insert mode.
Karsten Hopp 7b3c19
--- 937,942 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6900,6906 ****
Karsten Hopp 7b3c19
  	    else if (cc != NUL)
Karsten Hopp 7b3c19
  		++curwin->w_cursor.col;	/* put cursor back on the NUL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    /* <C-S-Right> may have started Visual mode, adjust the position for
Karsten Hopp 7b3c19
  	     * deleted characters. */
Karsten Hopp 7b3c19
  	    if (VIsual_active && VIsual.lnum == curwin->w_cursor.lnum)
Karsten Hopp 7b3c19
--- 6896,6901 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6910,6921 ****
Karsten Hopp 7b3c19
  		if (VIsual.col > len)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    VIsual.col = len;
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  		    VIsual.coladd = 0;
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      did_ai = FALSE;
Karsten Hopp 7b3c19
--- 6905,6915 ----
Karsten Hopp 7b3c19
  		if (VIsual.col > len)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    VIsual.col = len;
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  		    VIsual.coladd = 0;
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      did_ai = FALSE;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8112,8120 ****
Karsten Hopp 7b3c19
      int		need_redraw = FALSE;
Karsten Hopp 7b3c19
      int		regname;
Karsten Hopp 7b3c19
      int		literally = 0;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		vis_active = VIsual_active;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If we are going to wait for a character, show a '"'.
Karsten Hopp 7b3c19
--- 8106,8112 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8218,8228 ****
Karsten Hopp 7b3c19
      if (need_redraw || stuff_empty())
Karsten Hopp 7b3c19
  	edit_unputchar();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Disallow starting Visual mode here, would get a weird mode. */
Karsten Hopp 7b3c19
      if (!vis_active && VIsual_active)
Karsten Hopp 7b3c19
  	end_visual_mode();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 8210,8218 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8419,8429 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	       )
Karsten Hopp 7b3c19
  	    && (restart_edit == NUL
Karsten Hopp 7b3c19
! 		   || (gchar_cursor() == NUL
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		       && !VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		      ))
Karsten Hopp 7b3c19
  #ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  	    && !revins_on
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 8409,8415 ----
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	       )
Karsten Hopp 7b3c19
  	    && (restart_edit == NUL
Karsten Hopp 7b3c19
! 		   || (gchar_cursor() == NUL && !VIsual_active))
Karsten Hopp 7b3c19
  #ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  	    && !revins_on
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8525,8531 ****
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * If 'keymodel' contains "startsel", may start selection.
Karsten Hopp 7b3c19
   * Returns TRUE when a CTRL-O and other keys stuffed.
Karsten Hopp 7b3c19
--- 8511,8516 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8581,8587 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      return FALSE;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * <Insert> key in Insert mode: toggle insert/replace mode.
Karsten Hopp 7b3c19
--- 8566,8571 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/eval.c	2014-02-24 03:31:55.816738026 +0100
Karsten Hopp 7b3c19
--- src/eval.c	2014-03-23 13:03:56.419146143 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 11833,11844 ****
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	case MLINE: buf[0] = 'V'; break;
Karsten Hopp 7b3c19
  	case MCHAR: buf[0] = 'v'; break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	case MBLOCK:
Karsten Hopp 7b3c19
  		buf[0] = Ctrl_V;
Karsten Hopp 7b3c19
  		sprintf((char *)buf + 1, "%ld", reglen + 1);
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      rettv->v_type = VAR_STRING;
Karsten Hopp 7b3c19
      rettv->vval.v_string = vim_strsave(buf);
Karsten Hopp 7b3c19
--- 11833,11842 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 12552,12560 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  	"virtualedit",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	"visual",
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  	"visualextra",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 12550,12556 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 14397,14403 ****
Karsten Hopp 7b3c19
      buf[1] = NUL;
Karsten Hopp 7b3c19
      buf[2] = NUL;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (VIsual_select)
Karsten Hopp 7b3c19
--- 14393,14398 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 14405,14413 ****
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    buf[0] = VIsual_mode;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (State == HITRETURN || State == ASKMORE || State == SETWSIZE
Karsten Hopp 7b3c19
  		|| State == CONFIRM)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	buf[0] = 'r';
Karsten Hopp 7b3c19
--- 14400,14406 ----
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    buf[0] = VIsual_mode;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (State == HITRETURN || State == ASKMORE || State == SETWSIZE
Karsten Hopp 7b3c19
  		|| State == CONFIRM)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	buf[0] = 'r';
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 16756,16762 ****
Karsten Hopp 7b3c19
  		case 'V': case 'l':	/* line-wise selection */
Karsten Hopp 7b3c19
  		    yank_type = MLINE;
Karsten Hopp 7b3c19
  		    break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		case 'b': case Ctrl_V:	/* block-wise selection */
Karsten Hopp 7b3c19
  		    yank_type = MBLOCK;
Karsten Hopp 7b3c19
  		    if (VIM_ISDIGIT(stropt[1]))
Karsten Hopp 7b3c19
--- 16749,16754 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 16766,16772 ****
Karsten Hopp 7b3c19
  			--stropt;
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		    break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 16758,16763 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 18769,18775 ****
Karsten Hopp 7b3c19
      typval_T	*argvars UNUSED;
Karsten Hopp 7b3c19
      typval_T	*rettv UNUSED;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      char_u	str[2];
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      rettv->v_type = VAR_STRING;
Karsten Hopp 7b3c19
--- 18760,18765 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 18780,18786 ****
Karsten Hopp 7b3c19
      /* A non-zero number or non-empty string argument: reset mode. */
Karsten Hopp 7b3c19
      if (non_zero_arg(&argvars[0]))
Karsten Hopp 7b3c19
  	curbuf->b_visual_mode_eval = NUL;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 18770,18775 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 19154,19167 ****
Karsten Hopp 7b3c19
  	return NULL;
Karsten Hopp 7b3c19
      if (name[0] == '.')				/* cursor */
Karsten Hopp 7b3c19
  	return &curwin->w_cursor;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (name[0] == 'v' && name[1] == NUL)	/* Visual start */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	    return &VIsual;
Karsten Hopp 7b3c19
  	return &curwin->w_cursor;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      if (name[0] == '\'')			/* mark */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	pp = getmark_buf_fnum(curbuf, name[1], FALSE, fnum);
Karsten Hopp 7b3c19
--- 19143,19154 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/ex_cmds.c	2014-03-19 17:41:20.390105580 +0100
Karsten Hopp 7b3c19
--- src/ex_cmds.c	2014-03-23 13:04:09.359146341 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3274,3286 ****
Karsten Hopp 7b3c19
  	goto theend;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * End Visual mode before switching to another buffer, so the text can be
Karsten Hopp 7b3c19
       * copied into the GUI selection buffer.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      reset_VIsual();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_AUTOCMD
Karsten Hopp 7b3c19
      if ((command != NULL || newlnum > (linenr_T)0)
Karsten Hopp 7b3c19
--- 3274,3284 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/ex_docmd.c	2014-03-12 21:28:09.481046816 +0100
Karsten Hopp 7b3c19
--- src/ex_docmd.c	2014-03-23 13:04:47.975146933 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8577,8586 ****
Karsten Hopp 7b3c19
  	beginline(BL_SOL | BL_FIX);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL)
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	end_visual_mode();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      switch (eap->cmdidx)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 8577,8584 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8991,9001 ****
Karsten Hopp 7b3c19
      RedrawingDisabled = 0;
Karsten Hopp 7b3c19
      p_lz = FALSE;
Karsten Hopp 7b3c19
      update_topline();
Karsten Hopp 7b3c19
!     update_screen(eap->forceit ? CLEAR :
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    VIsual_active ? INVERTED :
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    0);
Karsten Hopp 7b3c19
  #ifdef FEAT_TITLE
Karsten Hopp 7b3c19
      if (need_maketitle)
Karsten Hopp 7b3c19
  	maketitle();
Karsten Hopp 7b3c19
--- 8989,8995 ----
Karsten Hopp 7b3c19
      RedrawingDisabled = 0;
Karsten Hopp 7b3c19
      p_lz = FALSE;
Karsten Hopp 7b3c19
      update_topline();
Karsten Hopp 7b3c19
!     update_screen(eap->forceit ? CLEAR : VIsual_active ? INVERTED : 0);
Karsten Hopp 7b3c19
  #ifdef FEAT_TITLE
Karsten Hopp 7b3c19
      if (need_maketitle)
Karsten Hopp 7b3c19
  	maketitle();
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9030,9040 ****
Karsten Hopp 7b3c19
  	status_redraw_all();
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	status_redraw_curbuf();
Karsten Hopp 7b3c19
!     update_screen(
Karsten Hopp 7b3c19
! # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    VIsual_active ? INVERTED :
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! 	    0);
Karsten Hopp 7b3c19
      RedrawingDisabled = r;
Karsten Hopp 7b3c19
      p_lz = p;
Karsten Hopp 7b3c19
      out_flush();
Karsten Hopp 7b3c19
--- 9024,9030 ----
Karsten Hopp 7b3c19
  	status_redraw_all();
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	status_redraw_curbuf();
Karsten Hopp 7b3c19
!     update_screen(VIsual_active ? INVERTED : 0);
Karsten Hopp 7b3c19
      RedrawingDisabled = r;
Karsten Hopp 7b3c19
      p_lz = p;
Karsten Hopp 7b3c19
      out_flush();
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/fold.c	2013-11-05 07:12:59.000000000 +0100
Karsten Hopp 7b3c19
--- src/fold.c	2014-03-23 13:05:14.775147344 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 430,440 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      if (done == DONE_NOTHING)
Karsten Hopp 7b3c19
  	EMSG(_(e_nofold));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Force a redraw to remove the Visual highlighting. */
Karsten Hopp 7b3c19
      if (had_visual)
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /* openFold() {{{2 */
Karsten Hopp 7b3c19
--- 430,438 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 807,817 ****
Karsten Hopp 7b3c19
      if (!did_one)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	EMSG(_(e_nofold));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* Force a redraw to remove the Visual highlighting. */
Karsten Hopp 7b3c19
  	if (had_visual)
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	/* Deleting markers may make cursor column invalid. */
Karsten Hopp 7b3c19
--- 805,813 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1065,1071 ****
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /* foldAdjustVisual() {{{2 */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Adjust the Visual area to include any fold at the start or end completely.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 1061,1066 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1103,1109 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /* cursor_foldstart() {{{2 */
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 1098,1103 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/getchar.c	2014-03-12 20:17:47.748982126 +0100
Karsten Hopp 7b3c19
--- src/getchar.c	2014-03-23 13:05:45.383147813 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 870,876 ****
Karsten Hopp 7b3c19
  	c = read_redo(FALSE, old_redo);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (c == 'v')   /* redo Visual */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	VIsual = curwin->w_cursor;
Karsten Hopp 7b3c19
--- 870,875 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 880,886 ****
Karsten Hopp 7b3c19
  	redo_VIsual_busy = TRUE;
Karsten Hopp 7b3c19
  	c = read_redo(FALSE, old_redo);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* try to enter the count (in place of a previous count) */
Karsten Hopp 7b3c19
      if (count)
Karsten Hopp 7b3c19
--- 879,884 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1162,1168 ****
Karsten Hopp 7b3c19
      return typebuf.tb_maplen == 0;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Return the number of characters that are mapped (or not typed).
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 1160,1165 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1171,1177 ****
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      return typebuf.tb_maplen;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * remove "len" characters from typebuf.tb_buf[typebuf.tb_off + offset]
Karsten Hopp 7b3c19
--- 1168,1173 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2443,2449 ****
Karsten Hopp 7b3c19
  				idx = get_menu_index(current_menu, local_State);
Karsten Hopp 7b3c19
  				if (idx != MENU_INDEX_INVALID)
Karsten Hopp 7b3c19
  				{
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  				    /*
Karsten Hopp 7b3c19
  				     * In Select mode and a Visual mode menu
Karsten Hopp 7b3c19
  				     * is used:  Switch to Visual mode
Karsten Hopp 7b3c19
--- 2439,2444 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2457,2463 ****
Karsten Hopp 7b3c19
  					(void)ins_typebuf(K_SELECT_STRING,
Karsten Hopp 7b3c19
  						  REMAP_NONE, 0, TRUE, FALSE);
Karsten Hopp 7b3c19
  				    }
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  				    ins_typebuf(current_menu->strings[idx],
Karsten Hopp 7b3c19
  						current_menu->noremap[idx],
Karsten Hopp 7b3c19
  						0, TRUE,
Karsten Hopp 7b3c19
--- 2452,2457 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2516,2522 ****
Karsten Hopp 7b3c19
  			    break;
Karsten Hopp 7b3c19
  			}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			/*
Karsten Hopp 7b3c19
  			 * In Select mode and a Visual mode mapping is used:
Karsten Hopp 7b3c19
  			 * Switch to Visual mode temporarily.  Append K_SELECT
Karsten Hopp 7b3c19
--- 2510,2515 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2529,2535 ****
Karsten Hopp 7b3c19
  			    (void)ins_typebuf(K_SELECT_STRING, REMAP_NONE,
Karsten Hopp 7b3c19
  							      0, TRUE, FALSE);
Karsten Hopp 7b3c19
  			}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_EVAL
Karsten Hopp 7b3c19
  			/* Copy the values from *mp that are used, because
Karsten Hopp 7b3c19
--- 2522,2527 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/gui.c	2013-06-30 17:41:48.000000000 +0200
Karsten Hopp 7b3c19
--- src/gui.c	2014-03-23 13:05:57.623148000 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3132,3142 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (!mouse_has(checkfor) || checkfor == MOUSE_COMMAND)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* Don't do modeless selection in Visual mode. */
Karsten Hopp 7b3c19
  	if (checkfor != MOUSE_NONEF && VIsual_active && (State & NORMAL))
Karsten Hopp 7b3c19
  	    return;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * When 'mousemodel' is "popup", shift-left is translated to right.
Karsten Hopp 7b3c19
--- 3132,3140 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/gui_mac.c	2013-05-06 04:06:04.000000000 +0200
Karsten Hopp 7b3c19
--- src/gui_mac.c	2014-03-23 13:06:30.143148498 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1068,1078 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- 
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      reset_VIsual();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
- 
Karsten Hopp 7b3c19
      fnames = new_fnames_from_AEDesc(&theList, &numFiles, &error);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (error)
Karsten Hopp 7b3c19
--- 1068,1074 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1142,1148 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Update the screen display */
Karsten Hopp 7b3c19
      update_screen(NOT_VALID);
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Select the text if possible */
Karsten Hopp 7b3c19
      if (gotPosition)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 1138,1144 ----
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Update the screen display */
Karsten Hopp 7b3c19
      update_screen(NOT_VALID);
Karsten Hopp 7b3c19
! 
Karsten Hopp 7b3c19
      /* Select the text if possible */
Karsten Hopp 7b3c19
      if (gotPosition)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1160,1166 ****
Karsten Hopp 7b3c19
  	    VIsual.col = 0;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
      setcursor();
Karsten Hopp 7b3c19
      out_flush();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 1156,1162 ----
Karsten Hopp 7b3c19
  	    VIsual.col = 0;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
! 
Karsten Hopp 7b3c19
      setcursor();
Karsten Hopp 7b3c19
      out_flush();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/gui_w48.c	2014-03-19 12:37:18.537826062 +0100
Karsten Hopp 7b3c19
--- src/gui_w48.c	2014-03-23 13:06:44.959148725 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3708,3716 ****
Karsten Hopp 7b3c19
      DragQueryPoint(hDrop, &pt;;
Karsten Hopp 7b3c19
      MapWindowPoints(s_hwnd, s_textArea, &pt, 1);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      reset_VIsual();
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      fnames = (char_u **)alloc(cFiles * sizeof(char_u *));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 3708,3714 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/main.c	2014-01-14 12:57:00.000000000 +0100
Karsten Hopp 7b3c19
--- src/main.c	2014-03-23 13:07:21.771149289 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1057,1065 ****
Karsten Hopp 7b3c19
      if (!cmdwin && !noexmode && SETJMP(x_jump_env))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	State = NORMAL;
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	VIsual_active = FALSE;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  	got_int = TRUE;
Karsten Hopp 7b3c19
  	need_wait_return = FALSE;
Karsten Hopp 7b3c19
  	global_busy = FALSE;
Karsten Hopp 7b3c19
--- 1057,1063 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1096,1106 ****
Karsten Hopp 7b3c19
  		check_timestamps(FALSE);
Karsten Hopp 7b3c19
  	    if (need_wait_return)	/* if wait_return still needed ... */
Karsten Hopp 7b3c19
  		wait_return(FALSE);	/* ... call it now */
Karsten Hopp 7b3c19
! 	    if (need_start_insertmode && goto_im()
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		    && !VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		    )
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		need_start_insertmode = FALSE;
Karsten Hopp 7b3c19
  		stuffReadbuff((char_u *)"i");	/* start insert mode next */
Karsten Hopp 7b3c19
--- 1094,1100 ----
Karsten Hopp 7b3c19
  		check_timestamps(FALSE);
Karsten Hopp 7b3c19
  	    if (need_wait_return)	/* if wait_return still needed ... */
Karsten Hopp 7b3c19
  		wait_return(FALSE);	/* ... call it now */
Karsten Hopp 7b3c19
! 	    if (need_start_insertmode && goto_im() && !VIsual_active)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		need_start_insertmode = FALSE;
Karsten Hopp 7b3c19
  		stuffReadbuff((char_u *)"i");	/* start insert mode next */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1202,1208 ****
Karsten Hopp 7b3c19
  		diff_need_scrollbind = FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
! #if defined(FEAT_FOLDING) && defined(FEAT_VISUAL)
Karsten Hopp 7b3c19
  	    /* Include a closed fold completely in the Visual area. */
Karsten Hopp 7b3c19
  	    foldAdjustVisual();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 1196,1202 ----
Karsten Hopp 7b3c19
  		diff_need_scrollbind = FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
! #if defined(FEAT_FOLDING)
Karsten Hopp 7b3c19
  	    /* Include a closed fold completely in the Visual area. */
Karsten Hopp 7b3c19
  	    foldAdjustVisual();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1228,1239 ****
Karsten Hopp 7b3c19
  	    update_topline();
Karsten Hopp 7b3c19
  	    validate_cursor();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    if (VIsual_active)
Karsten Hopp 7b3c19
  		update_curbuf(INVERTED);/* update inverted part */
Karsten Hopp 7b3c19
! 	    else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		if (must_redraw)
Karsten Hopp 7b3c19
  		update_screen(0);
Karsten Hopp 7b3c19
  	    else if (redraw_cmdline || clear_cmdline)
Karsten Hopp 7b3c19
  		showmode();
Karsten Hopp 7b3c19
--- 1222,1230 ----
Karsten Hopp 7b3c19
  	    update_topline();
Karsten Hopp 7b3c19
  	    validate_cursor();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    if (VIsual_active)
Karsten Hopp 7b3c19
  		update_curbuf(INVERTED);/* update inverted part */
Karsten Hopp 7b3c19
! 	    else if (must_redraw)
Karsten Hopp 7b3c19
  		update_screen(0);
Karsten Hopp 7b3c19
  	    else if (redraw_cmdline || clear_cmdline)
Karsten Hopp 7b3c19
  		showmode();
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/mark.c	2013-11-03 00:20:46.000000000 +0100
Karsten Hopp 7b3c19
--- src/mark.c	2014-03-23 13:08:03.011149921 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 98,104 ****
Karsten Hopp 7b3c19
  	return OK;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (c == '<' || c == '>')
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (c == '<')
Karsten Hopp 7b3c19
--- 98,103 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 110,116 ****
Karsten Hopp 7b3c19
  	    curbuf->b_visual.vi_mode = 'v';
Karsten Hopp 7b3c19
  	return OK;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifndef EBCDIC
Karsten Hopp 7b3c19
      if (c > 'z')	    /* some islower() and isupper() cannot handle
Karsten Hopp 7b3c19
--- 109,114 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 340,348 ****
Karsten Hopp 7b3c19
      int		*fnum;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      pos_T		*posp;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      pos_T		*startp, *endp;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      static pos_T	pos_copy;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      posp = NULL;
Karsten Hopp 7b3c19
--- 338,344 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 403,409 ****
Karsten Hopp 7b3c19
  	curwin->w_cursor = pos;
Karsten Hopp 7b3c19
  	listcmd_busy = slcb;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if (c == '<' || c == '>')	/* start/end of visual area */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	startp = &buf->b_visual.vi_start;
Karsten Hopp 7b3c19
--- 399,404 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 428,434 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      else if (ASCII_ISLOWER(c))		/* normal named mark */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	posp = &(buf->b_namedm[c - 'a']);
Karsten Hopp 7b3c19
--- 423,428 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 757,766 ****
Karsten Hopp 7b3c19
      show_one_mark(']', arg, &curbuf->b_op_end, NULL, TRUE);
Karsten Hopp 7b3c19
      show_one_mark('^', arg, &curbuf->b_last_insert, NULL, TRUE);
Karsten Hopp 7b3c19
      show_one_mark('.', arg, &curbuf->b_last_change, NULL, TRUE);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      show_one_mark('<', arg, &curbuf->b_visual.vi_start, NULL, TRUE);
Karsten Hopp 7b3c19
      show_one_mark('>', arg, &curbuf->b_visual.vi_end, NULL, TRUE);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      show_one_mark(-1, arg, NULL, NULL, FALSE);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 751,758 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 892,901 ****
Karsten Hopp 7b3c19
  		    case '.': curbuf->b_last_change.lnum = 0; break;
Karsten Hopp 7b3c19
  		    case '[': curbuf->b_op_start.lnum    = 0; break;
Karsten Hopp 7b3c19
  		    case ']': curbuf->b_op_end.lnum      = 0; break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		    case '<': curbuf->b_visual.vi_start.lnum = 0; break;
Karsten Hopp 7b3c19
  		    case '>': curbuf->b_visual.vi_end.lnum   = 0; break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		    case ' ': break;
Karsten Hopp 7b3c19
  		    default:  EMSG2(_(e_invarg2), p);
Karsten Hopp 7b3c19
  			      return;
Karsten Hopp 7b3c19
--- 884,891 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1085,1095 ****
Karsten Hopp 7b3c19
  	    one_adjust_nodel(&(curbuf->b_changelist[i].lnum));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* Visual area */
Karsten Hopp 7b3c19
  	one_adjust_nodel(&(curbuf->b_visual.vi_start.lnum));
Karsten Hopp 7b3c19
  	one_adjust_nodel(&(curbuf->b_visual.vi_end.lnum));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_QUICKFIX
Karsten Hopp 7b3c19
  	/* quickfix marks */
Karsten Hopp 7b3c19
--- 1075,1083 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1136,1149 ****
Karsten Hopp 7b3c19
  		    if (win->w_tagstack[i].fmark.fnum == fnum)
Karsten Hopp 7b3c19
  			one_adjust_nodel(&(win->w_tagstack[i].fmark.mark.lnum));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    /* the displayed Visual area */
Karsten Hopp 7b3c19
  	    if (win->w_old_cursor_lnum != 0)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		one_adjust_nodel(&(win->w_old_cursor_lnum));
Karsten Hopp 7b3c19
  		one_adjust_nodel(&(win->w_old_visual_lnum));
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    /* topline and cursor position for windows with the same buffer
Karsten Hopp 7b3c19
  	     * other than the current window */
Karsten Hopp 7b3c19
--- 1124,1135 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1260,1270 ****
Karsten Hopp 7b3c19
  	col_adjust(&(curbuf->b_changelist[i]));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Visual area */
Karsten Hopp 7b3c19
      col_adjust(&(curbuf->b_visual.vi_start));
Karsten Hopp 7b3c19
      col_adjust(&(curbuf->b_visual.vi_end));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* previous context mark */
Karsten Hopp 7b3c19
      col_adjust(&(curwin->w_pcmark));
Karsten Hopp 7b3c19
--- 1246,1254 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/menu.c	2011-04-11 15:17:21.000000000 +0200
Karsten Hopp 7b3c19
--- src/menu.c	2014-03-23 13:08:19.091150168 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1640,1646 ****
Karsten Hopp 7b3c19
  	idx = MENU_INDEX_INSERT;
Karsten Hopp 7b3c19
      else if (state & CMDLINE)
Karsten Hopp 7b3c19
  	idx = MENU_INDEX_CMDLINE;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (VIsual_select)
Karsten Hopp 7b3c19
--- 1640,1645 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1648,1654 ****
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    idx = MENU_INDEX_VISUAL;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      else if (state == HITRETURN || state == ASKMORE)
Karsten Hopp 7b3c19
  	idx = MENU_INDEX_CMDLINE;
Karsten Hopp 7b3c19
      else if (finish_op)
Karsten Hopp 7b3c19
--- 1647,1652 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1811,1824 ****
Karsten Hopp 7b3c19
      static int
Karsten Hopp 7b3c19
  get_menu_mode()
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (VIsual_select)
Karsten Hopp 7b3c19
  	    return MENU_INDEX_SELECT;
Karsten Hopp 7b3c19
  	return MENU_INDEX_VISUAL;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      if (State & INSERT)
Karsten Hopp 7b3c19
  	return MENU_INDEX_INSERT;
Karsten Hopp 7b3c19
      if ((State & CMDLINE) || State == ASKMORE || State == HITRETURN)
Karsten Hopp 7b3c19
--- 1809,1820 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/misc2.c	2014-02-23 23:38:58.824760280 +0100
Karsten Hopp 7b3c19
--- src/misc2.c	2014-03-23 13:08:56.927150748 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 31,39 ****
Karsten Hopp 7b3c19
      if (virtual_op != MAYBE)
Karsten Hopp 7b3c19
  	return virtual_op;
Karsten Hopp 7b3c19
      return (ve_flags == VE_ALL
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    || ((ve_flags & VE_BLOCK) && VIsual_active && VIsual_mode == Ctrl_V)
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  	    || ((ve_flags & VE_INSERT) && (State & INSERT)));
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 31,37 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 149,157 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      one_more = (State & INSERT)
Karsten Hopp 7b3c19
  		    || restart_edit != NUL
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		    || (VIsual_active && *p_sel != 'o')
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  		    || ((ve_flags & VE_ONEMORE) && wcol < MAXCOL)
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 147,153 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 570,578 ****
Karsten Hopp 7b3c19
  	 * - in Visual mode and 'selection' isn't "old"
Karsten Hopp 7b3c19
  	 * - 'virtualedit' is set */
Karsten Hopp 7b3c19
  	if ((State & INSERT) || restart_edit
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		|| (VIsual_active && *p_sel != 'o')
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  		|| (ve_flags & VE_ONEMORE)
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 566,572 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 627,635 ****
Karsten Hopp 7b3c19
  adjust_cursor_col()
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (curwin->w_cursor.col > 0
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    && (!VIsual_active || *p_sel == 'o')
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  	    && gchar_cursor() == NUL)
Karsten Hopp 7b3c19
  	--curwin->w_cursor.col;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 621,627 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3290,3306 ****
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (State & NORMAL)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (VIsual_select)
Karsten Hopp 7b3c19
  		return SELECTMODE;
Karsten Hopp 7b3c19
  	    return VISUAL;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! 	else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    if (finish_op)
Karsten Hopp 7b3c19
! 		return OP_PENDING;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      return State;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 3282,3295 ----
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (State & NORMAL)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (VIsual_select)
Karsten Hopp 7b3c19
  		return SELECTMODE;
Karsten Hopp 7b3c19
  	    return VISUAL;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! 	else if (finish_op)
Karsten Hopp 7b3c19
! 	    return OP_PENDING;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      return State;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3738,3744 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      if (finish_op)
Karsten Hopp 7b3c19
  	return SHAPE_IDX_O;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (*p_sel == 'e')
Karsten Hopp 7b3c19
--- 3727,3732 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3746,3752 ****
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    return SHAPE_IDX_V;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      return SHAPE_IDX_N;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 3734,3739 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/move.c	2014-02-11 18:58:05.102320947 +0100
Karsten Hopp 7b3c19
--- src/move.c	2014-03-23 13:09:16.535151048 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2857,2873 ****
Karsten Hopp 7b3c19
      win_T	*old_curwin = curwin;
Karsten Hopp 7b3c19
      buf_T	*old_curbuf = curbuf;
Karsten Hopp 7b3c19
      int		restart_edit_save;
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		old_VIsual_select = VIsual_select;
Karsten Hopp 7b3c19
      int		old_VIsual_active = VIsual_active;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * loop through the cursorbound windows
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      VIsual_select = VIsual_active = 0;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
      for (curwin = firstwin; curwin; curwin = curwin->w_next)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf = curwin->w_buffer;
Karsten Hopp 7b3c19
--- 2857,2869 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2916,2925 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * reset current-window
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      VIsual_select = old_VIsual_select;
Karsten Hopp 7b3c19
      VIsual_active = old_VIsual_active;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
      curwin = old_curwin;
Karsten Hopp 7b3c19
      curbuf = old_curbuf;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 2912,2919 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/netbeans.c	2012-06-20 19:56:18.000000000 +0200
Karsten Hopp 7b3c19
--- src/netbeans.c	2014-03-23 13:09:29.163151241 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2232,2242 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    nb_set_curbuf(buf->bufp);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    /* Don't want Visual mode now. */
Karsten Hopp 7b3c19
  	    if (VIsual_active)
Karsten Hopp 7b3c19
  		end_visual_mode();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef NBDEBUG
Karsten Hopp 7b3c19
  	    s = args;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 2232,2240 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/normal.c	2014-03-12 17:41:59.128838878 +0100
Karsten Hopp 7b3c19
--- src/normal.c	2014-03-23 15:07:40.435259900 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 14,20 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #include "vim.h"
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * The Visual area is remembered for reselection.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 14,19 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 24,30 ****
Karsten Hopp 7b3c19
  static int	VIsual_mode_orig = NUL;		/* saved Visual mode */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  static int	restart_VIsual_select = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_EVAL
Karsten Hopp 7b3c19
  static void	set_vcount_ca __ARGS((cmdarg_T *cap, int *set_prevcount));
Karsten Hopp 7b3c19
--- 23,28 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 37,43 ****
Karsten Hopp 7b3c19
  static int	find_command __ARGS((int cmdchar));
Karsten Hopp 7b3c19
  static void	op_colon __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
  static void	op_function __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
! #if defined(FEAT_MOUSE) && defined(FEAT_VISUAL)
Karsten Hopp 7b3c19
  static void	find_start_of_word __ARGS((pos_T *));
Karsten Hopp 7b3c19
  static void	find_end_of_word __ARGS((pos_T *));
Karsten Hopp 7b3c19
  static int	get_mouse_class __ARGS((char_u *p));
Karsten Hopp 7b3c19
--- 35,41 ----
Karsten Hopp 7b3c19
  static int	find_command __ARGS((int cmdchar));
Karsten Hopp 7b3c19
  static void	op_colon __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
  static void	op_function __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
! #if defined(FEAT_MOUSE)
Karsten Hopp 7b3c19
  static void	find_start_of_word __ARGS((pos_T *));
Karsten Hopp 7b3c19
  static void	find_end_of_word __ARGS((pos_T *));
Karsten Hopp 7b3c19
  static int	get_mouse_class __ARGS((char_u *p));
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 48,56 ****
Karsten Hopp 7b3c19
  static int	checkclearopq __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
  static void	clearop __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
  static void	clearopbeep __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	unshift_special __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
  static void	del_from_showcmd __ARGS((int));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 46,52 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 117,141 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_VREPLACE
Karsten Hopp 7b3c19
  static void	nv_vreplace __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	v_swap_corners __ARGS((int cmdchar));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  static void	nv_replace __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	n_swapchar __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_cursormark __ARGS((cmdarg_T *cap, int flag, pos_T *pos));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	v_visop __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  static void	nv_subst __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_abbrev __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_optrans __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_gomark __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_pcmark __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_regname __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	nv_visual __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	n_start_visual_mode __ARGS((int c));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  static void	nv_window __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_suspend __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_g_cmd __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
--- 113,131 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 155,165 ****
Karsten Hopp 7b3c19
  static void	nv_wordcmd __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_beginline __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	adjust_cursor __ARGS((oparg_T *oap));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	adjust_for_sel __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static int	unadjust_for_sel __ARGS((void));
Karsten Hopp 7b3c19
  static void	nv_select __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  static void	nv_goto __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_normal __ARGS((cmdarg_T *cap));
Karsten Hopp 7b3c19
  static void	nv_esc __ARGS((cmdarg_T *oap));
Karsten Hopp 7b3c19
--- 145,153 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 248,271 ****
Karsten Hopp 7b3c19
      {Ctrl_N,	nv_down,	NV_STS,			FALSE},
Karsten Hopp 7b3c19
      {Ctrl_O,	nv_ctrlo,	0,			0},
Karsten Hopp 7b3c19
      {Ctrl_P,	nv_up,		NV_STS,			FALSE},
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      {Ctrl_Q,	nv_visual,	0,			FALSE},
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
-     {Ctrl_Q,	nv_ignore,	0,			0},
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {Ctrl_R,	nv_redo,	0,			0},
Karsten Hopp 7b3c19
      {Ctrl_S,	nv_ignore,	0,			0},
Karsten Hopp 7b3c19
      {Ctrl_T,	nv_tagpop,	NV_NCW,			0},
Karsten Hopp 7b3c19
      {Ctrl_U,	nv_halfpage,	0,			0},
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      {Ctrl_V,	nv_visual,	0,			FALSE},
Karsten Hopp 7b3c19
      {'V',	nv_visual,	0,			FALSE},
Karsten Hopp 7b3c19
      {'v',	nv_visual,	0,			FALSE},
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
-     {Ctrl_V,	nv_error,	0,			0},
Karsten Hopp 7b3c19
-     {'V',	nv_error,	0,			0},
Karsten Hopp 7b3c19
-     {'v',	nv_error,	0,			0},
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {Ctrl_W,	nv_window,	0,			0},
Karsten Hopp 7b3c19
      {Ctrl_X,	nv_addsub,	0,			0},
Karsten Hopp 7b3c19
      {Ctrl_Y,	nv_scroll_line,	0,			FALSE},
Karsten Hopp 7b3c19
--- 236,249 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 427,435 ****
Karsten Hopp 7b3c19
      {K_HELP,	nv_help,	NV_NCW,			0},
Karsten Hopp 7b3c19
      {K_F1,	nv_help,	NV_NCW,			0},
Karsten Hopp 7b3c19
      {K_XF1,	nv_help,	NV_NCW,			0},
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      {K_SELECT,	nv_select,	0,			0},
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_GUI
Karsten Hopp 7b3c19
      {K_VER_SCROLLBAR, nv_ver_scrollbar, 0,		0},
Karsten Hopp 7b3c19
      {K_HOR_SCROLLBAR, nv_hor_scrollbar, 0,		0},
Karsten Hopp 7b3c19
--- 405,411 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 579,589 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
      int		need_flushbuf;		/* need to call out_flush() */
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      pos_T	old_pos;		/* cursor position before command */
Karsten Hopp 7b3c19
      int		mapped_len;
Karsten Hopp 7b3c19
      static int	old_mapped_len = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int		idx;
Karsten Hopp 7b3c19
  #ifdef FEAT_EVAL
Karsten Hopp 7b3c19
      int		set_prevcount = FALSE;
Karsten Hopp 7b3c19
--- 555,563 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 643,651 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      mapped_len = typebuf_maplen();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      State = NORMAL_BUSY;
Karsten Hopp 7b3c19
  #ifdef USE_ON_FLY_SCROLL
Karsten Hopp 7b3c19
--- 617,623 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 666,672 ****
Karsten Hopp 7b3c19
      c = safe_vgetc();
Karsten Hopp 7b3c19
      LANGMAP_ADJUST(c, TRUE);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If a mapping was started in Visual or Select mode, remember the length
Karsten Hopp 7b3c19
       * of the mapping.  This is used below to not return to Insert mode for as
Karsten Hopp 7b3c19
--- 638,643 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 677,688 ****
Karsten Hopp 7b3c19
      else if (old_mapped_len
Karsten Hopp 7b3c19
  		|| (VIsual_active && mapped_len == 0 && typebuf_maplen() > 0))
Karsten Hopp 7b3c19
  	old_mapped_len = typebuf_maplen();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (c == NUL)
Karsten Hopp 7b3c19
  	c = K_ZERO;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * In Select mode, typed text replaces the selection.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 648,657 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 703,718 ****
Karsten Hopp 7b3c19
  	msg_nowait = TRUE;	/* don't delay going to insert mode */
Karsten Hopp 7b3c19
  	old_mapped_len = 0;	/* do go to Insert mode */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
      need_flushbuf = add_to_showcmd(c);
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  getcount:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (!(VIsual_active && VIsual_select))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * Handle a count before a command and compute ca.count0.
Karsten Hopp 7b3c19
--- 672,684 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 856,862 ****
Karsten Hopp 7b3c19
  	goto normal_end;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * In Visual/Select mode, a few keys are handled in a special way.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 822,827 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 892,898 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
      if (curwin->w_p_rl && KeyTyped && !KeyStuffed
Karsten Hopp 7b3c19
--- 857,862 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 930,940 ****
Karsten Hopp 7b3c19
  		    && !Recording
Karsten Hopp 7b3c19
  		    && !Exec_reg)
Karsten Hopp 7b3c19
  		|| ((ca.cmdchar == 'a' || ca.cmdchar == 'i')
Karsten Hopp 7b3c19
! 		    && (oap->op_type != OP_NOP
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 			|| VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		       ))))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int	*cp;
Karsten Hopp 7b3c19
  	int	repl = FALSE;	/* get character for replace mode */
Karsten Hopp 7b3c19
--- 894,900 ----
Karsten Hopp 7b3c19
  		    && !Recording
Karsten Hopp 7b3c19
  		    && !Exec_reg)
Karsten Hopp 7b3c19
  		|| ((ca.cmdchar == 'a' || ca.cmdchar == 'i')
Karsten Hopp 7b3c19
! 		    && (oap->op_type != OP_NOP || VIsual_active))))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int	*cp;
Karsten Hopp 7b3c19
  	int	repl = FALSE;	/* get character for replace mode */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1168,1174 ****
Karsten Hopp 7b3c19
  	msg_col = 0;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      old_pos = curwin->w_cursor;		/* remember where cursor was */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* When 'keymodel' contains "startsel" some keys start Select/Visual
Karsten Hopp 7b3c19
--- 1128,1133 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1188,1194 ****
Karsten Hopp 7b3c19
  	    mod_mask &= ~MOD_MASK_SHIFT;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Execute the command!
Karsten Hopp 7b3c19
--- 1147,1152 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1220,1231 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Get the length of mapped chars again after typing a count, second
Karsten Hopp 7b3c19
       * character or "z333<cr>". */
Karsten Hopp 7b3c19
      if (old_mapped_len > 0)
Karsten Hopp 7b3c19
  	old_mapped_len = typebuf_maplen();
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If an operation is pending, handle it...
Karsten Hopp 7b3c19
--- 1178,1187 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1247,1257 ****
Karsten Hopp 7b3c19
      if (       ((p_smd
Karsten Hopp 7b3c19
  		    && msg_silent == 0
Karsten Hopp 7b3c19
  		    && (restart_edit != 0
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			|| (VIsual_active
Karsten Hopp 7b3c19
  			    && old_pos.lnum == curwin->w_cursor.lnum
Karsten Hopp 7b3c19
  			    && old_pos.col == curwin->w_cursor.col)
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		       )
Karsten Hopp 7b3c19
  		    && (clear_cmdline
Karsten Hopp 7b3c19
  			|| redraw_cmdline)
Karsten Hopp 7b3c19
--- 1203,1211 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1259,1267 ****
Karsten Hopp 7b3c19
  		    && !msg_nowait
Karsten Hopp 7b3c19
  		    && KeyTyped)
Karsten Hopp 7b3c19
  		|| (restart_edit != 0
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		    && !VIsual_active
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		    && (msg_scroll
Karsten Hopp 7b3c19
  			|| emsg_on_display)))
Karsten Hopp 7b3c19
  	    && oap->regname == 0
Karsten Hopp 7b3c19
--- 1213,1219 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1368,1403 ****
Karsten Hopp 7b3c19
       * May switch from Visual to Select mode after CTRL-O command.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (       oap->op_type == OP_NOP
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    && ((restart_edit != 0 && !VIsual_active && old_mapped_len == 0)
Karsten Hopp 7b3c19
  		|| restart_VIsual_select == 1)
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
- 	    && restart_edit != 0
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    && !(ca.retval & CA_COMMAND_BUSY)
Karsten Hopp 7b3c19
  	    && stuff_empty()
Karsten Hopp 7b3c19
  	    && oap->regname == 0)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (restart_VIsual_select == 1)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    VIsual_select = TRUE;
Karsten Hopp 7b3c19
  	    showmode();
Karsten Hopp 7b3c19
  	    restart_VIsual_select = 0;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (restart_edit != 0
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		&& !VIsual_active && old_mapped_len == 0
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		)
Karsten Hopp 7b3c19
  	    (void)edit(restart_edit, FALSE, 1L);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (restart_VIsual_select == 2)
Karsten Hopp 7b3c19
  	restart_VIsual_select = 1;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Save count before an operator for next time. */
Karsten Hopp 7b3c19
      opcount = ca.opcount;
Karsten Hopp 7b3c19
--- 1320,1343 ----
Karsten Hopp 7b3c19
       * May switch from Visual to Select mode after CTRL-O command.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (       oap->op_type == OP_NOP
Karsten Hopp 7b3c19
  	    && ((restart_edit != 0 && !VIsual_active && old_mapped_len == 0)
Karsten Hopp 7b3c19
  		|| restart_VIsual_select == 1)
Karsten Hopp 7b3c19
  	    && !(ca.retval & CA_COMMAND_BUSY)
Karsten Hopp 7b3c19
  	    && stuff_empty()
Karsten Hopp 7b3c19
  	    && oap->regname == 0)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (restart_VIsual_select == 1)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    VIsual_select = TRUE;
Karsten Hopp 7b3c19
  	    showmode();
Karsten Hopp 7b3c19
  	    restart_VIsual_select = 0;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! 	if (restart_edit != 0 && !VIsual_active && old_mapped_len == 0)
Karsten Hopp 7b3c19
  	    (void)edit(restart_edit, FALSE, 1L);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (restart_VIsual_select == 2)
Karsten Hopp 7b3c19
  	restart_VIsual_select = 1;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Save count before an operator for next time. */
Karsten Hopp 7b3c19
      opcount = ca.opcount;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1437,1451 ****
Karsten Hopp 7b3c19
      int		empty_region_error;
Karsten Hopp 7b3c19
      int		restart_edit_save;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* The visual area is remembered for redo */
Karsten Hopp 7b3c19
      static int	    redo_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */
Karsten Hopp 7b3c19
      static linenr_T redo_VIsual_line_count; /* number of lines */
Karsten Hopp 7b3c19
      static colnr_T  redo_VIsual_vcol;	    /* number of cols or end column */
Karsten Hopp 7b3c19
      static long	    redo_VIsual_count;	    /* count for Visual operator */
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
      int		    include_line_break = FALSE;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_CLIPBOARD)
Karsten Hopp 7b3c19
--- 1377,1389 ----
Karsten Hopp 7b3c19
      int		empty_region_error;
Karsten Hopp 7b3c19
      int		restart_edit_save;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* The visual area is remembered for redo */
Karsten Hopp 7b3c19
      static int	    redo_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */
Karsten Hopp 7b3c19
      static linenr_T redo_VIsual_line_count; /* number of lines */
Karsten Hopp 7b3c19
      static colnr_T  redo_VIsual_vcol;	    /* number of cols or end column */
Karsten Hopp 7b3c19
      static long	    redo_VIsual_count;	    /* count for Visual operator */
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
      int		    include_line_break = FALSE;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_CLIPBOARD)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1459,1468 ****
Karsten Hopp 7b3c19
      if ((clip_star.available || clip_plus.available)
Karsten Hopp 7b3c19
  	    && oap->op_type != OP_NOP
Karsten Hopp 7b3c19
  	    && !gui_yank
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    && VIsual_active
Karsten Hopp 7b3c19
  	    && !redo_VIsual_busy
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  	    && oap->regname == 0)
Karsten Hopp 7b3c19
  	clip_auto_select();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 1397,1404 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1471,1483 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If an operation is pending, handle it...
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
!     if ((finish_op
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		|| VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		) && oap->op_type != OP_NOP)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	oap->is_VIsual = VIsual_active;
Karsten Hopp 7b3c19
  	if (oap->motion_force == 'V')
Karsten Hopp 7b3c19
  	    oap->motion_type = MLINE;
Karsten Hopp 7b3c19
--- 1407,1414 ----
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If an operation is pending, handle it...
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
!     if ((finish_op || VIsual_active) && oap->op_type != OP_NOP)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	oap->is_VIsual = VIsual_active;
Karsten Hopp 7b3c19
  	if (oap->motion_force == 'V')
Karsten Hopp 7b3c19
  	    oap->motion_type = MLINE;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1501,1517 ****
Karsten Hopp 7b3c19
  	    VIsual_select = FALSE;
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* Only redo yank when 'y' flag is in 'cpoptions'. */
Karsten Hopp 7b3c19
  	/* Never redo "zf" (define fold). */
Karsten Hopp 7b3c19
  	if ((vim_strchr(p_cpo, CPO_YANK) != NULL || oap->op_type != OP_YANK)
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		&& ((!VIsual_active || oap->motion_force)
Karsten Hopp 7b3c19
  		    /* Also redo Operator-pending Visual mode mappings */
Karsten Hopp 7b3c19
  		    || (VIsual_active && cap->cmdchar == ':'
Karsten Hopp 7b3c19
  						 && oap->op_type != OP_COLON))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		&& cap->cmdchar != 'D'
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  		&& oap->op_type != OP_FOLD
Karsten Hopp 7b3c19
--- 1432,1445 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1554,1560 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (redo_VIsual_busy)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /* Redo of an operation on a Visual area. Use the same size from
Karsten Hopp 7b3c19
--- 1482,1487 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1639,1645 ****
Karsten Hopp 7b3c19
  	    if (VIsual_mode == 'V')
Karsten Hopp 7b3c19
  		oap->start.col = 0;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * Set oap->start to the first position of the operated text, oap->end
Karsten Hopp 7b3c19
--- 1566,1571 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1690,1696 ****
Karsten Hopp 7b3c19
  	virtual_op = virtual_active();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active || redo_VIsual_busy)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (VIsual_mode == Ctrl_V)	/* block mode */
Karsten Hopp 7b3c19
--- 1616,1621 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1826,1834 ****
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
  		if (VIsual_mode != Ctrl_V && *ml_get_pos(&(oap->end)) == NUL
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			&& (include_line_break || !virtual_op)
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  			)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    oap->inclusive = FALSE;
Karsten Hopp 7b3c19
--- 1751,1759 ----
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
  		if (VIsual_mode != Ctrl_V && *ml_get_pos(&(oap->end)) == NUL
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			&& (include_line_break || !virtual_op)
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  			)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    oap->inclusive = FALSE;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1840,1848 ****
Karsten Hopp 7b3c19
  			{
Karsten Hopp 7b3c19
  			    ++oap->end.lnum;
Karsten Hopp 7b3c19
  			    oap->end.col = 0;
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			    oap->end.coladd = 0;
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  			    ++oap->line_count;
Karsten Hopp 7b3c19
  			}
Karsten Hopp 7b3c19
  			else
Karsten Hopp 7b3c19
--- 1765,1773 ----
Karsten Hopp 7b3c19
  			{
Karsten Hopp 7b3c19
  			    ++oap->end.lnum;
Karsten Hopp 7b3c19
  			    oap->end.col = 0;
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			    oap->end.coladd = 0;
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  			    ++oap->line_count;
Karsten Hopp 7b3c19
  			}
Karsten Hopp 7b3c19
  			else
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1868,1877 ****
Karsten Hopp 7b3c19
  	    if (!gui_yank)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		VIsual_active = FALSE;
Karsten Hopp 7b3c19
! # ifdef FEAT_MOUSE
Karsten Hopp 7b3c19
  		setmouse();
Karsten Hopp 7b3c19
  		mouse_dragging = 0;
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  		if (mode_displayed)
Karsten Hopp 7b3c19
  		    clear_cmdline = TRUE;   /* unshow visual mode later */
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
--- 1793,1802 ----
Karsten Hopp 7b3c19
  	    if (!gui_yank)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		VIsual_active = FALSE;
Karsten Hopp 7b3c19
! #ifdef FEAT_MOUSE
Karsten Hopp 7b3c19
  		setmouse();
Karsten Hopp 7b3c19
  		mouse_dragging = 0;
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		if (mode_displayed)
Karsten Hopp 7b3c19
  		    clear_cmdline = TRUE;   /* unshow visual mode later */
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1886,1892 ****
Karsten Hopp 7b3c19
  		    redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_MBYTE
Karsten Hopp 7b3c19
  	/* Include the trailing byte of a multi-byte char. */
Karsten Hopp 7b3c19
--- 1811,1816 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1921,1936 ****
Karsten Hopp 7b3c19
  	empty_region_error = (oap->empty
Karsten Hopp 7b3c19
  				&& vim_strchr(p_cpo, CPO_EMPTYREGION) != NULL);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* Force a redraw when operating on an empty Visual region, when
Karsten Hopp 7b3c19
  	 * 'modifiable is off or creating a fold. */
Karsten Hopp 7b3c19
  	if (oap->is_VIsual && (oap->empty || !curbuf->b_p_ma
Karsten Hopp 7b3c19
! # ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  		    || oap->op_type == OP_FOLD
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  		    ))
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * If the end of an operator is in column one while oap->motion_type
Karsten Hopp 7b3c19
--- 1845,1858 ----
Karsten Hopp 7b3c19
  	empty_region_error = (oap->empty
Karsten Hopp 7b3c19
  				&& vim_strchr(p_cpo, CPO_EMPTYREGION) != NULL);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* Force a redraw when operating on an empty Visual region, when
Karsten Hopp 7b3c19
  	 * 'modifiable is off or creating a fold. */
Karsten Hopp 7b3c19
  	if (oap->is_VIsual && (oap->empty || !curbuf->b_p_ma
Karsten Hopp 7b3c19
! #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  		    || oap->op_type == OP_FOLD
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		    ))
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * If the end of an operator is in column one while oap->motion_type
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1943,1952 ****
Karsten Hopp 7b3c19
  		&& oap->inclusive == FALSE
Karsten Hopp 7b3c19
  		&& !(cap->retval & CA_NO_ADJ_OP_END)
Karsten Hopp 7b3c19
  		&& oap->end.col == 0
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		&& (!oap->is_VIsual || *p_sel == 'o')
Karsten Hopp 7b3c19
  		&& !oap->block_mode
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		&& oap->line_count > 1)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    oap->end_adjusted = TRUE;	    /* remember that we did this */
Karsten Hopp 7b3c19
--- 1865,1872 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1971,1981 ****
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	case OP_LSHIFT:
Karsten Hopp 7b3c19
  	case OP_RSHIFT:
Karsten Hopp 7b3c19
! 	    op_shift(oap, TRUE,
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		    oap->is_VIsual ? (int)cap->count1 :
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		    1);
Karsten Hopp 7b3c19
  	    auto_format(FALSE, TRUE);
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 1891,1897 ----
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	case OP_LSHIFT:
Karsten Hopp 7b3c19
  	case OP_RSHIFT:
Karsten Hopp 7b3c19
! 	    op_shift(oap, TRUE, oap->is_VIsual ? (int)cap->count1 : 1);
Karsten Hopp 7b3c19
  	    auto_format(FALSE, TRUE);
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1988,2002 ****
Karsten Hopp 7b3c19
  		beep_flush();
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! 		(void)do_join(oap->line_count, oap->op_type == OP_JOIN, TRUE, TRUE);
Karsten Hopp 7b3c19
  		auto_format(FALSE, TRUE);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	case OP_DELETE:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;	    /* don't reselect now */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    if (empty_region_error)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		vim_beep();
Karsten Hopp 7b3c19
--- 1904,1917 ----
Karsten Hopp 7b3c19
  		beep_flush();
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! 		(void)do_join(oap->line_count, oap->op_type == OP_JOIN,
Karsten Hopp 7b3c19
! 								  TRUE, TRUE);
Karsten Hopp 7b3c19
  		auto_format(FALSE, TRUE);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	case OP_DELETE:
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;	    /* don't reselect now */
Karsten Hopp 7b3c19
  	    if (empty_region_error)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		vim_beep();
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2026,2034 ****
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	case OP_CHANGE:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;	    /* don't reselect now */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    if (empty_region_error)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		vim_beep();
Karsten Hopp 7b3c19
--- 1941,1947 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2126,2134 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	case OP_INSERT:
Karsten Hopp 7b3c19
  	case OP_APPEND:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;	/* don't reselect now */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  	    if (empty_region_error)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
--- 2039,2045 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2158,2166 ****
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	case OP_REPLACE:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    VIsual_reselect = FALSE;	/* don't reselect now */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  	    if (empty_region_error)
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 2069,2075 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2220,2228 ****
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    curwin->w_cursor = old_cursor;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	oap->block_mode = FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	clearop(oap);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 2129,2135 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2235,2245 ****
Karsten Hopp 7b3c19
      oparg_T	*oap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      stuffcharReadbuff(':');
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->is_VIsual)
Karsten Hopp 7b3c19
  	stuffReadbuff((char_u *)"'<,'>");
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * Make the range look nice, so it can be repeated.
Karsten Hopp 7b3c19
--- 2142,2150 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2404,2417 ****
Karsten Hopp 7b3c19
      pos_T	save_cursor;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      win_T	*old_curwin = curwin;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      static pos_T orig_cursor;
Karsten Hopp 7b3c19
      colnr_T	leftcol, rightcol;
Karsten Hopp 7b3c19
      pos_T	end_visual;
Karsten Hopp 7b3c19
      int		diff;
Karsten Hopp 7b3c19
      int		old_active = VIsual_active;
Karsten Hopp 7b3c19
      int		old_mode = VIsual_mode;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int		regname;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_FOLDING)
Karsten Hopp 7b3c19
--- 2309,2320 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2432,2446 ****
Karsten Hopp 7b3c19
  	if (!gui.in_use)
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    if (VIsual_active)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		if (!mouse_has(MOUSE_VISUAL))
Karsten Hopp 7b3c19
  		    return FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
! 	    else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		if (State == NORMAL && !mouse_has(MOUSE_NORMAL))
Karsten Hopp 7b3c19
  		return FALSE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 2335,2346 ----
Karsten Hopp 7b3c19
  	if (!gui.in_use)
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (VIsual_active)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		if (!mouse_has(MOUSE_VISUAL))
Karsten Hopp 7b3c19
  		    return FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
! 	    else if (State == NORMAL && !mouse_has(MOUSE_NORMAL))
Karsten Hopp 7b3c19
  		return FALSE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2509,2522 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifndef FEAT_VISUAL
Karsten Hopp 7b3c19
-     /*
Karsten Hopp 7b3c19
-      * ALT is only used for starting/extending Visual mode.
Karsten Hopp 7b3c19
-      */
Karsten Hopp 7b3c19
-     if ((mod_mask & MOD_MASK_ALT))
Karsten Hopp 7b3c19
- 	return FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
- 
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * CTRL right mouse button does CTRL-T
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 2409,2414 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2586,2592 ****
Karsten Hopp 7b3c19
  		return FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
  	     * If visual was active, yank the highlighted text and put it
Karsten Hopp 7b3c19
  	     * before the mouse pointer position.
Karsten Hopp 7b3c19
--- 2478,2483 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2607,2613 ****
Karsten Hopp 7b3c19
  		do_always = TRUE;	/* ignore 'mouse' setting next time */
Karsten Hopp 7b3c19
  		return FALSE;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
  	     * The rest is below jump_to_mouse()
Karsten Hopp 7b3c19
  	     */
Karsten Hopp 7b3c19
--- 2498,2503 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2761,2767 ****
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    /* First set the cursor position before showing the popup
Karsten Hopp 7b3c19
  		     * menu. */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		    if (VIsual_active)
Karsten Hopp 7b3c19
  		    {
Karsten Hopp 7b3c19
  			pos_T    m_pos;
Karsten Hopp 7b3c19
--- 2651,2656 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2800,2815 ****
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		    else
Karsten Hopp 7b3c19
  			jump_flags = MOUSE_MAY_STOP_VIS;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  		if (jump_flags)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    jump_flags = jump_to_mouse(jump_flags, NULL, which_button);
Karsten Hopp 7b3c19
! 		    update_curbuf(
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 			    VIsual_active ? INVERTED :
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 			    VALID);
Karsten Hopp 7b3c19
  		    setcursor();
Karsten Hopp 7b3c19
  		    out_flush();    /* Update before showing popup menu */
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
--- 2689,2699 ----
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		    else
Karsten Hopp 7b3c19
  			jump_flags = MOUSE_MAY_STOP_VIS;
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  		if (jump_flags)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    jump_flags = jump_to_mouse(jump_flags, NULL, which_button);
Karsten Hopp 7b3c19
! 		    update_curbuf(VIsual_active ? INVERTED : VALID);
Karsten Hopp 7b3c19
  		    setcursor();
Karsten Hopp 7b3c19
  		    out_flush();    /* Update before showing popup menu */
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2832,2838 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if ((State & (NORMAL | INSERT))
Karsten Hopp 7b3c19
  			    && !(mod_mask & (MOD_MASK_SHIFT | MOD_MASK_CTRL)))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 2716,2721 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2872,2878 ****
Karsten Hopp 7b3c19
  		jump_flags |= MOUSE_MAY_VIS;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If an operator is pending, ignore all drags and releases until the
Karsten Hopp 7b3c19
--- 2755,2760 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2941,2947 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Set global flag that we are extending the Visual area with mouse
Karsten Hopp 7b3c19
       * dragging; temporarily minimize 'scrolloff'. */
Karsten Hopp 7b3c19
      if (VIsual_active && is_drag && p_so)
Karsten Hopp 7b3c19
--- 2823,2828 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3040,3046 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      else if ((State & INSERT) && VIsual_active)
Karsten Hopp 7b3c19
  	stuffcharReadbuff(Ctrl_O);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Middle mouse click: Put text before cursor.
Karsten Hopp 7b3c19
--- 2921,2926 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3118,3128 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      else if ((mod_mask & MOD_MASK_SHIFT))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! 	if (State & INSERT
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		|| (VIsual_active && VIsual_select)
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		)
Karsten Hopp 7b3c19
  	    stuffcharReadbuff(Ctrl_O);
Karsten Hopp 7b3c19
  	if (which_button == MOUSE_LEFT)
Karsten Hopp 7b3c19
  	    stuffcharReadbuff('*');
Karsten Hopp 7b3c19
--- 2998,3004 ----
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      else if ((mod_mask & MOD_MASK_SHIFT))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! 	if ((State & INSERT) || (VIsual_active && VIsual_select))
Karsten Hopp 7b3c19
  	    stuffcharReadbuff(Ctrl_O);
Karsten Hopp 7b3c19
  	if (which_button == MOUSE_LEFT)
Karsten Hopp 7b3c19
  	    stuffcharReadbuff('*');
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3153,3159 ****
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if ((mod_mask & MOD_MASK_MULTI_CLICK) && (State & (NORMAL | INSERT))
Karsten Hopp 7b3c19
  	     && mouse_has(MOUSE_VISUAL))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 3029,3034 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3267,3278 ****
Karsten Hopp 7b3c19
  	    || (VIsual_active && p_smd && msg_silent == 0
Karsten Hopp 7b3c19
  				 && (!old_active || VIsual_mode != old_mode)))
Karsten Hopp 7b3c19
  	redraw_cmdline = TRUE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      return moved;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Move "pos" back to the start of the word it's in.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 3142,3151 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3372,3381 ****
Karsten Hopp 7b3c19
  	return 1;
Karsten Hopp 7b3c19
      return c;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  #endif /* FEAT_MOUSE */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Check if  highlighting for visual mode is possible, give a warning message
Karsten Hopp 7b3c19
   * if not.
Karsten Hopp 7b3c19
--- 3245,3252 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3468,3474 ****
Karsten Hopp 7b3c19
  	VIsual_reselect = FALSE;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_BEVAL)
Karsten Hopp 7b3c19
  static int find_is_eval_item __ARGS((char_u *ptr, int *colp, int *nbp, int dir));
Karsten Hopp 7b3c19
--- 3339,3344 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3802,3812 ****
Karsten Hopp 7b3c19
  checkclearopq(oap)
Karsten Hopp 7b3c19
      oparg_T	*oap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (oap->op_type == OP_NOP
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    && !VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    )
Karsten Hopp 7b3c19
  	return FALSE;
Karsten Hopp 7b3c19
      clearopbeep(oap);
Karsten Hopp 7b3c19
      return TRUE;
Karsten Hopp 7b3c19
--- 3672,3678 ----
Karsten Hopp 7b3c19
  checkclearopq(oap)
Karsten Hopp 7b3c19
      oparg_T	*oap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (oap->op_type == OP_NOP && !VIsual_active)
Karsten Hopp 7b3c19
  	return FALSE;
Karsten Hopp 7b3c19
      clearopbeep(oap);
Karsten Hopp 7b3c19
      return TRUE;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3830,3836 ****
Karsten Hopp 7b3c19
      beep_flush();
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Remove the shift modifier from a special key.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 3696,3701 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3849,3866 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      cap->cmdchar = simplify_key(cap->cmdchar, &mod_mask);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_CMDL_INFO) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Routines for displaying a partly typed command
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL	/* need room for size of Visual area */
Karsten Hopp 7b3c19
! # define SHOWCMD_BUFLEN SHOWCMD_COLS + 1 + 30
Karsten Hopp 7b3c19
! #else
Karsten Hopp 7b3c19
! # define SHOWCMD_BUFLEN SHOWCMD_COLS + 1
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  static char_u	showcmd_buf[SHOWCMD_BUFLEN];
Karsten Hopp 7b3c19
  static char_u	old_showcmd_buf[SHOWCMD_BUFLEN];  /* For push_showcmd() */
Karsten Hopp 7b3c19
  static int	showcmd_is_clear = TRUE;
Karsten Hopp 7b3c19
--- 3714,3726 ----
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      cap->cmdchar = simplify_key(cap->cmdchar, &mod_mask);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_CMDL_INFO) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Routines for displaying a partly typed command
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #define SHOWCMD_BUFLEN SHOWCMD_COLS + 1 + 30
Karsten Hopp 7b3c19
  static char_u	showcmd_buf[SHOWCMD_BUFLEN];
Karsten Hopp 7b3c19
  static char_u	old_showcmd_buf[SHOWCMD_BUFLEN];  /* For push_showcmd() */
Karsten Hopp 7b3c19
  static int	showcmd_is_clear = TRUE;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3874,3880 ****
Karsten Hopp 7b3c19
      if (!p_sc)
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active && !char_avail())
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int		cursor_bot = lt(VIsual, curwin->w_cursor);
Karsten Hopp 7b3c19
--- 3734,3739 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3960,3966 ****
Karsten Hopp 7b3c19
  	showcmd_visual = TRUE;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	showcmd_buf[0] = NUL;
Karsten Hopp 7b3c19
  	showcmd_visual = FALSE;
Karsten Hopp 7b3c19
--- 3819,3824 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4203,4212 ****
Karsten Hopp 7b3c19
      int		want_hor;
Karsten Hopp 7b3c19
      win_T	*old_curwin = curwin;
Karsten Hopp 7b3c19
      buf_T	*old_curbuf = curbuf;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		old_VIsual_select = VIsual_select;
Karsten Hopp 7b3c19
      int		old_VIsual_active = VIsual_active;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      colnr_T	tgt_leftcol = curwin->w_leftcol;
Karsten Hopp 7b3c19
      long	topline;
Karsten Hopp 7b3c19
      long	y;
Karsten Hopp 7b3c19
--- 4061,4068 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4223,4231 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * loop through the scrollbound windows and scroll accordingly
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      VIsual_select = VIsual_active = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      for (curwin = firstwin; curwin; curwin = curwin->w_next)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf = curwin->w_buffer;
Karsten Hopp 7b3c19
--- 4079,4085 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4280,4289 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * reset current-window
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      VIsual_select = old_VIsual_select;
Karsten Hopp 7b3c19
      VIsual_active = old_VIsual_active;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      curwin = old_curwin;
Karsten Hopp 7b3c19
      curbuf = old_curbuf;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 4134,4141 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5239,5249 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  		    if (checkclearop(cap->oap))
Karsten Hopp 7b3c19
  			break;
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		    if (VIsual_active && get_visual_text(cap, &ptr, &len)
Karsten Hopp 7b3c19
  								      == FAIL)
Karsten Hopp 7b3c19
  			return;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  		    if (ptr == NULL)
Karsten Hopp 7b3c19
  		    {
Karsten Hopp 7b3c19
  			pos_T	pos = curwin->w_cursor;
Karsten Hopp 7b3c19
--- 5091,5099 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5411,5422 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Ignore 'Q' in Visual mode, just give a beep.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	vim_beep();
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
  	do_exmode(FALSE);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 5261,5269 ----
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Ignore 'Q' in Visual mode, just give a beep.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	vim_beep();
Karsten Hopp 7b3c19
!     else if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
  	do_exmode(FALSE);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5430,5440 ****
Karsten Hopp 7b3c19
      int	    old_p_im;
Karsten Hopp 7b3c19
      int	    cmd_result;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (cap->oap->op_type != OP_NOP)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
--- 5277,5285 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5494,5508 ****
Karsten Hopp 7b3c19
  nv_ctrlg(cap)
Karsten Hopp 7b3c19
      cmdarg_T *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)	/* toggle Selection/Visual mode */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	VIsual_select = !VIsual_select;
Karsten Hopp 7b3c19
  	showmode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
  	/* print full name if count given or :cd used */
Karsten Hopp 7b3c19
  	fileinfo((int)cap->count0, FALSE, TRUE);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 5339,5350 ----
Karsten Hopp 7b3c19
  nv_ctrlg(cap)
Karsten Hopp 7b3c19
      cmdarg_T *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (VIsual_active)	/* toggle Selection/Visual mode */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	VIsual_select = !VIsual_select;
Karsten Hopp 7b3c19
  	showmode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
  	/* print full name if count given or :cd used */
Karsten Hopp 7b3c19
  	fileinfo((int)cap->count0, FALSE, TRUE);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5514,5527 ****
Karsten Hopp 7b3c19
  nv_ctrlh(cap)
Karsten Hopp 7b3c19
      cmdarg_T *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active && VIsual_select)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	cap->cmdchar = 'x';	/* BS key behaves like 'x' in Select mode */
Karsten Hopp 7b3c19
  	v_visop(cap);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	nv_left(cap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 5356,5367 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5558,5564 ****
Karsten Hopp 7b3c19
  nv_ctrlo(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active && VIsual_select)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	VIsual_select = FALSE;
Karsten Hopp 7b3c19
--- 5398,5403 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5566,5572 ****
Karsten Hopp 7b3c19
  	restart_VIsual_select = 2;	/* restart Select mode later */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	cap->count1 = -cap->count1;
Karsten Hopp 7b3c19
  	nv_pcmark(cap);
Karsten Hopp 7b3c19
--- 5405,5410 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5675,5684 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (cmdchar == ']' || cmdchar == Ctrl_RSB || cmdchar == 'K')
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active && get_visual_text(cap, &ptr, &n) == FAIL)
Karsten Hopp 7b3c19
  	    return;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	if (checkclearopq(cap->oap))
Karsten Hopp 7b3c19
  	    return;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
--- 5513,5520 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5872,5878 ****
Karsten Hopp 7b3c19
      vim_free(buf);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Get visually selected text, within one line only.
Karsten Hopp 7b3c19
   * Returns FAIL if more than one line selected.
Karsten Hopp 7b3c19
--- 5708,5713 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5917,5923 ****
Karsten Hopp 7b3c19
      reset_VIsual_and_resel();
Karsten Hopp 7b3c19
      return OK;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * CTRL-T: backwards in tag stack
Karsten Hopp 7b3c19
--- 5752,5757 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6040,6050 ****
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      long	n;
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
!     int		PAST_LINE;
Karsten Hopp 7b3c19
! #else
Karsten Hopp 7b3c19
! # define PAST_LINE 0
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (mod_mask & (MOD_MASK_SHIFT | MOD_MASK_CTRL))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 5874,5880 ----
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      long	n;
Karsten Hopp 7b3c19
!     int		past_line;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (mod_mask & (MOD_MASK_SHIFT | MOD_MASK_CTRL))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6057,6081 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      cap->oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
      cap->oap->inclusive = FALSE;
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
!     PAST_LINE = (VIsual_active && *p_sel != 'o');
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
!      * In virtual mode, there's no such thing as "PAST_LINE", as lines are
Karsten Hopp 7b3c19
!      * (theoretically) infinitely long.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (virtual_active())
Karsten Hopp 7b3c19
! 	PAST_LINE = 0;
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      for (n = cap->count1; n > 0; --n)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! 	if ((!PAST_LINE && oneright() == FAIL)
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		|| (PAST_LINE && *ml_get_cursor() == NUL)
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
--- 5887,5907 ----
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      cap->oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
      cap->oap->inclusive = FALSE;
Karsten Hopp 7b3c19
!     past_line = (VIsual_active && *p_sel != 'o');
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
!      * In virtual edit mode, there's no such thing as "past_line", as lines
Karsten Hopp 7b3c19
!      * are (theoretically) infinitely long.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (virtual_active())
Karsten Hopp 7b3c19
! 	past_line = 0;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      for (n = cap->count1; n > 0; --n)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! 	if ((!past_line && oneright() == FAIL)
Karsten Hopp 7b3c19
! 		|| (past_line && *ml_get_cursor() == NUL)
Karsten Hopp 7b3c19
  		)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6123,6148 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	else if (PAST_LINE)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  	    if (virtual_active())
Karsten Hopp 7b3c19
  		oneright();
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! # ifdef FEAT_MBYTE
Karsten Hopp 7b3c19
  		if (has_mbyte)
Karsten Hopp 7b3c19
  		    curwin->w_cursor.col +=
Karsten Hopp 7b3c19
  					 (*mb_ptr2len)(ml_get_cursor());
Karsten Hopp 7b3c19
  		else
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  		    ++curwin->w_cursor.col;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
      if (n != cap->count1 && (fdo_flags & FDO_HOR) && KeyTyped
Karsten Hopp 7b3c19
--- 5949,5972 ----
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! 	else if (past_line)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  	    if (virtual_active())
Karsten Hopp 7b3c19
  		oneright();
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! #ifdef FEAT_MBYTE
Karsten Hopp 7b3c19
  		if (has_mbyte)
Karsten Hopp 7b3c19
  		    curwin->w_cursor.col +=
Karsten Hopp 7b3c19
  					 (*mb_ptr2len)(ml_get_cursor());
Karsten Hopp 7b3c19
  		else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  		    ++curwin->w_cursor.col;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
      if (n != cap->count1 && (fdo_flags & FDO_HOR) && KeyTyped
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6503,6511 ****
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    curwin->w_cursor.coladd = 0;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	adjust_for_sel(cap);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  	if ((fdo_flags & FDO_HOR) && KeyTyped && cap->oap->op_type == OP_NOP)
Karsten Hopp 7b3c19
  	    foldOpenCursor();
Karsten Hopp 7b3c19
--- 6327,6333 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6754,6760 ****
Karsten Hopp 7b3c19
  	    int	    dir = (cap->cmdchar == ']' && cap->nchar == 'p')
Karsten Hopp 7b3c19
  							 ? FORWARD : BACKWARD;
Karsten Hopp 7b3c19
  	    int	    regname = cap->oap->regname;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    int	    was_visual = VIsual_active;
Karsten Hopp 7b3c19
  	    int	    line_count = curbuf->b_ml.ml_line_count;
Karsten Hopp 7b3c19
  	    pos_T   start, end;
Karsten Hopp 7b3c19
--- 6576,6581 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6766,6779 ****
Karsten Hopp 7b3c19
  		end =  equalpos(start,VIsual) ? curwin->w_cursor : VIsual;
Karsten Hopp 7b3c19
  		curwin->w_cursor = (dir == BACKWARD ? start : end);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  # ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  	    adjust_clip_reg(&regname);
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
  	    prep_redo_cmd(cap);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    do_put(regname, dir, cap->count1, PUT_FIXINDENT);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    if (was_visual)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		VIsual = start;
Karsten Hopp 7b3c19
--- 6587,6598 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6802,6808 ****
Karsten Hopp 7b3c19
  		    redraw_later(SOME_VALID);
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 6621,6626 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6936,6944 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  	    curwin->w_cursor.coladd = 0;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    adjust_for_sel(cap);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
--- 6754,6760 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7027,7037 ****
Karsten Hopp 7b3c19
  nv_undo(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (cap->oap->op_type == OP_LOWER
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    || VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    )
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* translate "<Visual>u" to "<Visual>gu" and "guu" to "gugu" */
Karsten Hopp 7b3c19
  	cap->cmdchar = 'g';
Karsten Hopp 7b3c19
--- 6843,6849 ----
Karsten Hopp 7b3c19
  nv_undo(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (cap->oap->op_type == OP_LOWER || VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* translate "<Visual>u" to "<Visual>gu" and "guu" to "gugu" */
Karsten Hopp 7b3c19
  	cap->cmdchar = 'g';
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7089,7095 ****
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Visual mode "r" */
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 6901,6906 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7105,7111 ****
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
      /* Break tabs, etc. */
Karsten Hopp 7b3c19
--- 6916,6921 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7273,7279 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * 'o': Exchange start and end of Visual area.
Karsten Hopp 7b3c19
   * 'O': same, but in block mode exchange left and right corners.
Karsten Hopp 7b3c19
--- 7083,7088 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7326,7332 ****
Karsten Hopp 7b3c19
  	curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * "R" (cap->arg is FALSE) and "gR" (cap->arg is TRUE).
Karsten Hopp 7b3c19
--- 7135,7140 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7335,7341 ****
Karsten Hopp 7b3c19
  nv_Replace(cap)
Karsten Hopp 7b3c19
      cmdarg_T	    *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)		/* "R" is replace lines */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	cap->cmdchar = 'c';
Karsten Hopp 7b3c19
--- 7143,7148 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7344,7352 ****
Karsten Hopp 7b3c19
  	VIsual_mode = 'V';
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (!checkclearopq(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (!curbuf->b_p_ma)
Karsten Hopp 7b3c19
  	    EMSG(_(e_modifiable));
Karsten Hopp 7b3c19
--- 7151,7157 ----
Karsten Hopp 7b3c19
  	VIsual_mode = 'V';
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (!checkclearopq(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (!curbuf->b_p_ma)
Karsten Hopp 7b3c19
  	    EMSG(_(e_modifiable));
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7369,7384 ****
Karsten Hopp 7b3c19
  nv_vreplace(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	cap->cmdchar = 'r';
Karsten Hopp 7b3c19
  	cap->nchar = cap->extra_char;
Karsten Hopp 7b3c19
  	nv_replace(cap);	/* Do same as "r" in Visual mode for now */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! 	if (!checkclearopq(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (!curbuf->b_p_ma)
Karsten Hopp 7b3c19
  	    EMSG(_(e_modifiable));
Karsten Hopp 7b3c19
--- 7174,7186 ----
Karsten Hopp 7b3c19
  nv_vreplace(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	cap->cmdchar = 'r';
Karsten Hopp 7b3c19
  	cap->nchar = cap->extra_char;
Karsten Hopp 7b3c19
  	nv_replace(cap);	/* Do same as "r" in Visual mode for now */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (!checkclearopq(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (!curbuf->b_p_ma)
Karsten Hopp 7b3c19
  	    EMSG(_(e_modifiable));
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7525,7531 ****
Karsten Hopp 7b3c19
      curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Handle commands that are operators in Visual mode.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 7327,7332 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7550,7556 ****
Karsten Hopp 7b3c19
      cap->cmdchar = *(vim_strchr(trans, cap->cmdchar) + 1);
Karsten Hopp 7b3c19
      nv_operator(cap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * "s" and "S" commands.
Karsten Hopp 7b3c19
--- 7351,7356 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7559,7565 ****
Karsten Hopp 7b3c19
  nv_subst(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)	/* "vs" and "vS" are the same as "vc" */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (cap->cmdchar == 'S')
Karsten Hopp 7b3c19
--- 7359,7364 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7571,7577 ****
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	nv_optrans(cap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 7370,7375 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7585,7596 ****
Karsten Hopp 7b3c19
      if (cap->cmdchar == K_DEL || cap->cmdchar == K_KDEL)
Karsten Hopp 7b3c19
  	cap->cmdchar = 'x';		/* DEL key behaves like 'x' */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* in Visual mode these commands are operators */
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	v_visop(cap);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	nv_optrans(cap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 7383,7392 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7758,7764 ****
Karsten Hopp 7b3c19
  	clearopbeep(cap->oap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Handle "v", "V" and "CTRL-V" commands.
Karsten Hopp 7b3c19
   * Also for "gh", "gH" and "g^H" commands: Always start Select mode, cap->arg
Karsten Hopp 7b3c19
--- 7554,7559 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7950,7956 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * CTRL-W: Window commands
Karsten Hopp 7b3c19
--- 7745,7750 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7975,7984 ****
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      clearop(cap->oap);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	end_visual_mode();		/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      do_cmdline_cmd((char_u *)"st");
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 7769,7776 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 7990,7998 ****
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      oparg_T	*oap = cap->oap;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      pos_T	tpos;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int		i;
Karsten Hopp 7b3c19
      int		flag = FALSE;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 7782,7788 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8025,8031 ****
Karsten Hopp 7b3c19
  	do_cmdline_cmd((char_u *)"%s//~/&";;
Karsten Hopp 7b3c19
  	break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * "gv": Reselect the previous Visual area.  If Visual already active,
Karsten Hopp 7b3c19
       *	     exchange previous and current Visual area.
Karsten Hopp 7b3c19
--- 7815,7820 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8126,8132 ****
Karsten Hopp 7b3c19
  	cap->arg = TRUE;
Karsten Hopp 7b3c19
  	nv_visual(cap);
Karsten Hopp 7b3c19
  	break;
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* "gn", "gN" visually select next/previous search match
Karsten Hopp 7b3c19
       * "gn" selects next match
Karsten Hopp 7b3c19
--- 7915,7920 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8134,8142 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      case 'N':
Karsten Hopp 7b3c19
      case 'n':
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (!current_search(cap->count1, cap->nchar == 'n'))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    clearopbeep(oap);
Karsten Hopp 7b3c19
  	break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 7922,7928 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8258,8266 ****
Karsten Hopp 7b3c19
  				    && vim_iswhite(ptr[curwin->w_cursor.col]))
Karsten Hopp 7b3c19
  		--curwin->w_cursor.col;
Karsten Hopp 7b3c19
  	    curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    adjust_for_sel(cap);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 8044,8050 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8657,8667 ****
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      /* In Visual mode and typing "gUU" triggers an operator */
Karsten Hopp 7b3c19
!     if (cap->oap->op_type == OP_UPPER
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    || VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    )
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* translate "gUU" to "gUgU" */
Karsten Hopp 7b3c19
  	cap->cmdchar = 'g';
Karsten Hopp 7b3c19
--- 8441,8447 ----
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      /* In Visual mode and typing "gUU" triggers an operator */
Karsten Hopp 7b3c19
!     if (cap->oap->op_type == OP_UPPER || VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* translate "gUU" to "gUgU" */
Karsten Hopp 7b3c19
  	cap->cmdchar = 'g';
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8683,8693 ****
Karsten Hopp 7b3c19
  nv_tilde(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (!p_to
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    && !VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    && cap->oap->op_type != OP_TILDE)
Karsten Hopp 7b3c19
  	n_swapchar(cap);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
--- 8463,8469 ----
Karsten Hopp 7b3c19
  nv_tilde(cap)
Karsten Hopp 7b3c19
      cmdarg_T	*cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
!     if (!p_to && !VIsual_active && cap->oap->op_type != OP_TILDE)
Karsten Hopp 7b3c19
  	n_swapchar(cap);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8906,8914 ****
Karsten Hopp 7b3c19
  	clearopbeep(cap->oap);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	adjust_for_sel(cap);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  	if ((fdo_flags & FDO_HOR) && KeyTyped && cap->oap->op_type == OP_NOP)
Karsten Hopp 7b3c19
  	    foldOpenCursor();
Karsten Hopp 7b3c19
--- 8682,8688 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8931,8939 ****
Karsten Hopp 7b3c19
       * - 'virtualedit' is not "all" and not "onemore".
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (curwin->w_cursor.col > 0 && gchar_cursor() == NUL
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		&& (!VIsual_active || *p_sel == 'o')
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  		&& !virtual_active() && (ve_flags & VE_ONEMORE) == 0
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 8705,8711 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8968,8974 ****
Karsten Hopp 7b3c19
  			       one-character line). */
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * In exclusive Visual mode, may include the last character.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 8740,8745 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 8979,8989 ****
Karsten Hopp 7b3c19
      if (VIsual_active && cap->oap->inclusive && *p_sel == 'e'
Karsten Hopp 7b3c19
  	    && gchar_cursor() != NUL && lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! # ifdef FEAT_MBYTE
Karsten Hopp 7b3c19
  	if (has_mbyte)
Karsten Hopp 7b3c19
  	    inc_cursor();
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  	    ++curwin->w_cursor.col;
Karsten Hopp 7b3c19
  	cap->oap->inclusive = FALSE;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
--- 8750,8760 ----
Karsten Hopp 7b3c19
      if (VIsual_active && cap->oap->inclusive && *p_sel == 'e'
Karsten Hopp 7b3c19
  	    && gchar_cursor() != NUL && lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
! #ifdef FEAT_MBYTE
Karsten Hopp 7b3c19
  	if (has_mbyte)
Karsten Hopp 7b3c19
  	    inc_cursor();
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  	    ++curwin->w_cursor.col;
Karsten Hopp 7b3c19
  	cap->oap->inclusive = FALSE;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9044,9050 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * "G", "gg", CTRL-END, CTRL-HOME.
Karsten Hopp 7b3c19
--- 8815,8820 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9095,9107 ****
Karsten Hopp 7b3c19
  	if (cmdwin_type != 0)
Karsten Hopp 7b3c19
  	    cmdwin_result = Ctrl_C;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    end_visual_mode();		/* stop Visual */
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	/* CTRL-\ CTRL-G restarts Insert mode when 'insertmode' is set. */
Karsten Hopp 7b3c19
  	if (cap->nchar == Ctrl_G && p_im)
Karsten Hopp 7b3c19
  	    restart_edit = 'a';
Karsten Hopp 7b3c19
--- 8865,8875 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9132,9140 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  		&& cmdwin_type == 0
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		&& !VIsual_active
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		&& no_reason)
Karsten Hopp 7b3c19
  	    MSG(_("Type  :quit<Enter>  to exit Vim"));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 8900,8906 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9152,9158 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	end_visual_mode();	/* stop Visual */
Karsten Hopp 7b3c19
--- 8918,8923 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9160,9169 ****
Karsten Hopp 7b3c19
  	curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (no_reason)
Karsten Hopp 7b3c19
! 	    vim_beep();
Karsten Hopp 7b3c19
      clearop(cap->oap);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* A CTRL-C is often used at the start of a menu.  When 'insertmode' is
Karsten Hopp 7b3c19
--- 8925,8932 ----
Karsten Hopp 7b3c19
  	curwin->w_set_curswant = TRUE;
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (no_reason)
Karsten Hopp 7b3c19
! 	vim_beep();
Karsten Hopp 7b3c19
      clearop(cap->oap);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* A CTRL-C is often used at the start of a menu.  When 'insertmode' is
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9187,9206 ****
Karsten Hopp 7b3c19
      if (cap->cmdchar == K_INS || cap->cmdchar == K_KINS)
Karsten Hopp 7b3c19
  	cap->cmdchar = 'i';
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* in Visual mode "A" and "I" are an operator */
Karsten Hopp 7b3c19
      if (VIsual_active && (cap->cmdchar == 'A' || cap->cmdchar == 'I'))
Karsten Hopp 7b3c19
  	v_visop(cap);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* in Visual mode and after an operator "a" and "i" are for text objects */
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if ((cap->cmdchar == 'a' || cap->cmdchar == 'i')
Karsten Hopp 7b3c19
! 	    && (cap->oap->op_type != OP_NOP
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		|| VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  #ifdef FEAT_TEXTOBJ
Karsten Hopp 7b3c19
  	nv_object(cap);
Karsten Hopp 7b3c19
--- 8950,8962 ----
Karsten Hopp 7b3c19
      if (cap->cmdchar == K_INS || cap->cmdchar == K_KINS)
Karsten Hopp 7b3c19
  	cap->cmdchar = 'i';
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* in Visual mode "A" and "I" are an operator */
Karsten Hopp 7b3c19
      if (VIsual_active && (cap->cmdchar == 'A' || cap->cmdchar == 'I'))
Karsten Hopp 7b3c19
  	v_visop(cap);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* in Visual mode and after an operator "a" and "i" are for text objects */
Karsten Hopp 7b3c19
!     else if ((cap->cmdchar == 'a' || cap->cmdchar == 'i')
Karsten Hopp 7b3c19
! 	    && (cap->oap->op_type != OP_NOP || VIsual_active))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  #ifdef FEAT_TEXTOBJ
Karsten Hopp 7b3c19
  	nv_object(cap);
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9467,9478 ****
Karsten Hopp 7b3c19
  nv_join(cap)
Karsten Hopp 7b3c19
      cmdarg_T *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)	/* join the visual lines */
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (cap->count0 <= 1)
Karsten Hopp 7b3c19
  	    cap->count0 = 2;	    /* default for join is two lines! */
Karsten Hopp 7b3c19
--- 9223,9231 ----
Karsten Hopp 7b3c19
  nv_join(cap)
Karsten Hopp 7b3c19
      cmdarg_T *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      if (VIsual_active)	/* join the visual lines */
Karsten Hopp 7b3c19
  	nv_operator(cap);
Karsten Hopp 7b3c19
!     else if (!checkclearop(cap->oap))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (cap->count0 <= 1)
Karsten Hopp 7b3c19
  	    cap->count0 = 2;	    /* default for join is two lines! */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9495,9506 ****
Karsten Hopp 7b3c19
  nv_put(cap)
Karsten Hopp 7b3c19
      cmdarg_T  *cap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		regname = 0;
Karsten Hopp 7b3c19
      void	*reg1 = NULL, *reg2 = NULL;
Karsten Hopp 7b3c19
      int		empty = FALSE;
Karsten Hopp 7b3c19
      int		was_visual = FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int		dir;
Karsten Hopp 7b3c19
      int		flags = 0;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 9248,9257 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9526,9532 ****
Karsten Hopp 7b3c19
  	if (cap->cmdchar == 'g')
Karsten Hopp 7b3c19
  	    flags |= PUT_CURSEND;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /* Putting in Visual mode: The put text replaces the selected
Karsten Hopp 7b3c19
--- 9277,9282 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9536,9549 ****
Karsten Hopp 7b3c19
  	     */
Karsten Hopp 7b3c19
  	    was_visual = TRUE;
Karsten Hopp 7b3c19
  	    regname = cap->oap->regname;
Karsten Hopp 7b3c19
! # ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  	    adjust_clip_reg(&regname);
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  	   if (regname == 0 || regname == '"'
Karsten Hopp 7b3c19
  				     || VIM_ISDIGIT(regname) || regname == '-'
Karsten Hopp 7b3c19
! # ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  		    || (clip_unnamed && (regname == '*' || regname == '+'))
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  		    )
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
--- 9286,9299 ----
Karsten Hopp 7b3c19
  	     */
Karsten Hopp 7b3c19
  	    was_visual = TRUE;
Karsten Hopp 7b3c19
  	    regname = cap->oap->regname;
Karsten Hopp 7b3c19
! #ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  	    adjust_clip_reg(&regname);
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  	   if (regname == 0 || regname == '"'
Karsten Hopp 7b3c19
  				     || VIM_ISDIGIT(regname) || regname == '-'
Karsten Hopp 7b3c19
! #ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  		    || (clip_unnamed && (regname == '*' || regname == '+'))
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  		    )
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9591,9600 ****
Karsten Hopp 7b3c19
  	    /* May have been reset in do_put(). */
Karsten Hopp 7b3c19
  	    VIsual_active = TRUE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	do_put(cap->oap->regname, dir, cap->count1, flags);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* If a register was saved, put it back now. */
Karsten Hopp 7b3c19
  	if (reg2 != NULL)
Karsten Hopp 7b3c19
  	    put_register(regname, reg2);
Karsten Hopp 7b3c19
--- 9341,9348 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9621,9627 ****
Karsten Hopp 7b3c19
  		coladvance((colnr_T)MAXCOL);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	auto_format(FALSE, TRUE);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
--- 9369,9374 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9642,9652 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)  /* switch start and end of visual */
Karsten Hopp 7b3c19
  	v_swap_corners(cap->cmdchar);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	n_opencmd(cap);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 9389,9397 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/ops.c	2014-03-19 18:57:27.730175565 +0100
Karsten Hopp 7b3c19
--- src/ops.c	2014-03-23 15:08:16.095260447 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 57,65 ****
Karsten Hopp 7b3c19
      char_u	**y_array;	/* pointer to array of line pointers */
Karsten Hopp 7b3c19
      linenr_T	y_size;		/* number of lines in y_array */
Karsten Hopp 7b3c19
      char_u	y_type;		/* MLINE, MCHAR or MBLOCK */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      colnr_T	y_width;	/* only set if y_type == MBLOCK */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  } y_regs[NUM_REGISTERS];
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  static struct yankreg	*y_current;	    /* ptr to current yankreg */
Karsten Hopp 7b3c19
--- 57,63 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 107,123 ****
Karsten Hopp 7b3c19
  static int	yank_copy_line __ARGS((struct block_def *bd, long y_idx));
Karsten Hopp 7b3c19
  #ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  static void	copy_yank_reg __ARGS((struct yankreg *reg));
Karsten Hopp 7b3c19
- # if defined(FEAT_VISUAL) || defined(FEAT_EVAL)
Karsten Hopp 7b3c19
  static void	may_set_selection __ARGS((void));
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  static void	dis_msg __ARGS((char_u *p, int skip_esc));
Karsten Hopp 7b3c19
  #if defined(FEAT_COMMENTS) || defined(PROTO)
Karsten Hopp 7b3c19
  static char_u	*skip_comment __ARGS((char_u *line, int process, int include_space, int *is_comment));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static void	block_prep __ARGS((oparg_T *oap, struct block_def *, linenr_T, int));
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #if defined(FEAT_CLIPBOARD) || defined(FEAT_EVAL)
Karsten Hopp 7b3c19
  static void	str_to_reg __ARGS((struct yankreg *y_ptr, int type, char_u *str, long len, long blocklen));
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 105,117 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 187,193 ****
Karsten Hopp 7b3c19
      return i;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Return TRUE if operator "op" always works on whole lines.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 181,186 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 197,203 ****
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      return opchars[op][2];
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Get first operator command character.
Karsten Hopp 7b3c19
--- 190,195 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 232,249 ****
Karsten Hopp 7b3c19
      long	    i;
Karsten Hopp 7b3c19
      int		    first_char;
Karsten Hopp 7b3c19
      char_u	    *s;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		    block_col = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (u_save((linenr_T)(oap->start.lnum - 1),
Karsten Hopp 7b3c19
  				       (linenr_T)(oap->end.lnum + 1)) == FAIL)
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->block_mode)
Karsten Hopp 7b3c19
  	block_col = curwin->w_cursor.col;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      for (i = oap->line_count; --i >= 0; )
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 224,237 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 272,286 ****
Karsten Hopp 7b3c19
      foldOpenCursor();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->block_mode)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curwin->w_cursor.lnum = oap->start.lnum;
Karsten Hopp 7b3c19
  	curwin->w_cursor.col = block_col;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (curs_top)	    /* put cursor on first line, for ">>" */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curwin->w_cursor.lnum = oap->start.lnum;
Karsten Hopp 7b3c19
  	beginline(BL_SOL | BL_FIX);   /* shift_line() may have set cursor.col */
Karsten Hopp 7b3c19
--- 260,271 ----
Karsten Hopp 7b3c19
      foldOpenCursor();
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (oap->block_mode)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curwin->w_cursor.lnum = oap->start.lnum;
Karsten Hopp 7b3c19
  	curwin->w_cursor.col = block_col;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (curs_top)	    /* put cursor on first line, for ">>" */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curwin->w_cursor.lnum = oap->start.lnum;
Karsten Hopp 7b3c19
  	beginline(BL_SOL | BL_FIX);   /* shift_line() may have set cursor.col */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 733,746 ****
Karsten Hopp 7b3c19
       * there is no change still need to remove the Visual highlighting. */
Karsten Hopp 7b3c19
      if (last_changed != 0)
Karsten Hopp 7b3c19
  	changed_lines(first_changed, 0,
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		oap->is_VIsual ? start_lnum + oap->line_count :
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		last_changed + 1, 0L);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if (oap->is_VIsual)
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (oap->line_count > p_report)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 718,727 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 948,954 ****
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * Obtain the contents of a "normal" register. The register is made empty.
Karsten Hopp 7b3c19
   * The returned pointer has allocated memory, use put_register() later.
Karsten Hopp 7b3c19
--- 929,934 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1016,1025 ****
Karsten Hopp 7b3c19
      *y_current = *(struct yankreg *)reg;
Karsten Hopp 7b3c19
      vim_free(reg);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! # ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
      /* Send text written to clipboard register to the clipboard. */
Karsten Hopp 7b3c19
      may_set_selection();
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      void
Karsten Hopp 7b3c19
--- 996,1005 ----
Karsten Hopp 7b3c19
      *y_current = *(struct yankreg *)reg;
Karsten Hopp 7b3c19
      vim_free(reg);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
      /* Send text written to clipboard register to the clipboard. */
Karsten Hopp 7b3c19
      may_set_selection();
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      void
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1034,1040 ****
Karsten Hopp 7b3c19
      vim_free(reg);
Karsten Hopp 7b3c19
      *y_current = tmp;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_MOUSE) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 1014,1019 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1634,1643 ****
Karsten Hopp 7b3c19
      int			n;
Karsten Hopp 7b3c19
      linenr_T		lnum;
Karsten Hopp 7b3c19
      char_u		*ptr;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      char_u		*newp, *oldp;
Karsten Hopp 7b3c19
      struct block_def	bd;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      linenr_T		old_lcount = curbuf->b_ml.ml_line_count;
Karsten Hopp 7b3c19
      int			did_yank = FALSE;
Karsten Hopp 7b3c19
      int			orig_regname = oap->regname;
Karsten Hopp 7b3c19
--- 1613,1620 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1670,1679 ****
Karsten Hopp 7b3c19
       * delete linewise.  Don't do this for the change command or Visual mode.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (       oap->motion_type == MCHAR
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    && !oap->is_VIsual
Karsten Hopp 7b3c19
  	    && !oap->block_mode
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    && oap->line_count > 1
Karsten Hopp 7b3c19
  	    && oap->motion_force == NUL
Karsten Hopp 7b3c19
  	    && oap->op_type == OP_DELETE)
Karsten Hopp 7b3c19
--- 1647,1654 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1787,1793 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * block mode delete
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 1762,1767 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1838,1846 ****
Karsten Hopp 7b3c19
  						       oap->end.lnum + 1, 0L);
Karsten Hopp 7b3c19
  	oap->line_count = 0;	    /* no lines deleted */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (oap->motion_type == MLINE)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (oap->op_type == OP_CHANGE)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
--- 1812,1818 ----
Karsten Hopp 7b3c19
  						       oap->end.lnum + 1, 0L);
Karsten Hopp 7b3c19
  	oap->line_count = 0;	    /* no lines deleted */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (oap->motion_type == MLINE)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (oap->op_type == OP_CHANGE)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1924,1936 ****
Karsten Hopp 7b3c19
  		return FAIL;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    /* if 'cpoptions' contains '$', display '$' at end of change */
Karsten Hopp 7b3c19
! 	    if (	   vim_strchr(p_cpo, CPO_DOLLAR) != NULL
Karsten Hopp 7b3c19
  		    && oap->op_type == OP_CHANGE
Karsten Hopp 7b3c19
  		    && oap->end.lnum == curwin->w_cursor.lnum
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		    && !oap->is_VIsual
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		    )
Karsten Hopp 7b3c19
  		display_dollar(oap->end.col - !oap->inclusive);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    n = oap->end.col - oap->start.col + 1 - !oap->inclusive;
Karsten Hopp 7b3c19
--- 1896,1905 ----
Karsten Hopp 7b3c19
  		return FAIL;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    /* if 'cpoptions' contains '$', display '$' at end of change */
Karsten Hopp 7b3c19
! 	    if (       vim_strchr(p_cpo, CPO_DOLLAR) != NULL
Karsten Hopp 7b3c19
  		    && oap->op_type == OP_CHANGE
Karsten Hopp 7b3c19
  		    && oap->end.lnum == curwin->w_cursor.lnum
Karsten Hopp 7b3c19
! 		    && !oap->is_VIsual)
Karsten Hopp 7b3c19
  		display_dollar(oap->end.col - !oap->inclusive);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    n = oap->end.col - oap->start.col + 1 - !oap->inclusive;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1967,1977 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! 		(void)del_bytes((long)n, !virtual_op, oap->op_type == OP_DELETE
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 				    && !oap->is_VIsual
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 							);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else				/* delete characters between lines */
Karsten Hopp 7b3c19
--- 1936,1943 ----
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
! 		(void)del_bytes((long)n, !virtual_op,
Karsten Hopp 7b3c19
! 				oap->op_type == OP_DELETE && !oap->is_VIsual);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else				/* delete characters between lines */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2008,2018 ****
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		/* delete from start of line until op_end */
Karsten Hopp 7b3c19
  		curwin->w_cursor.col = 0;
Karsten Hopp 7b3c19
! 		(void)del_bytes((long)n, !virtual_op, oap->op_type == OP_DELETE
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 					&& !oap->is_VIsual
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 							    );
Karsten Hopp 7b3c19
  		curwin->w_cursor = curpos;	/* restore curwin->w_cursor */
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    if (curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count)
Karsten Hopp 7b3c19
--- 1974,1981 ----
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		/* delete from start of line until op_end */
Karsten Hopp 7b3c19
  		curwin->w_cursor.col = 0;
Karsten Hopp 7b3c19
! 		(void)del_bytes((long)n, !virtual_op,
Karsten Hopp 7b3c19
! 				oap->op_type == OP_DELETE && !oap->is_VIsual);
Karsten Hopp 7b3c19
  		curwin->w_cursor = curpos;	/* restore curwin->w_cursor */
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    if (curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2025,2038 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  setmarks:
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->block_mode)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf->b_op_end.lnum = oap->end.lnum;
Karsten Hopp 7b3c19
  	curbuf->b_op_end.col = oap->start.col;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	curbuf->b_op_end = oap->start;
Karsten Hopp 7b3c19
      curbuf->b_op_start = oap->start;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 1988,1999 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2318,2326 ****
Karsten Hopp 7b3c19
      oparg_T	*oap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      pos_T		pos;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      struct block_def	bd;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int			did_change = FALSE;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (u_save((linenr_T)(oap->start.lnum - 1),
Karsten Hopp 7b3c19
--- 2279,2285 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2328,2334 ****
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      pos = oap->start;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->block_mode)		    /* Visual block mode */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	for (; pos.lnum <= oap->end.lnum; ++pos.lnum)
Karsten Hopp 7b3c19
--- 2287,2292 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2340,2346 ****
Karsten Hopp 7b3c19
  	    one_change = swapchars(oap->op_type, &pos, bd.textlen);
Karsten Hopp 7b3c19
  	    did_change |= one_change;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! # ifdef FEAT_NETBEANS_INTG
Karsten Hopp 7b3c19
  	    if (netbeans_active() && one_change)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		char_u *ptr = ml_get_buf(curbuf, pos.lnum, FALSE);
Karsten Hopp 7b3c19
--- 2298,2304 ----
Karsten Hopp 7b3c19
  	    one_change = swapchars(oap->op_type, &pos, bd.textlen);
Karsten Hopp 7b3c19
  	    did_change |= one_change;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #ifdef FEAT_NETBEANS_INTG
Karsten Hopp 7b3c19
  	    if (netbeans_active() && one_change)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		char_u *ptr = ml_get_buf(curbuf, pos.lnum, FALSE);
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2350,2362 ****
Karsten Hopp 7b3c19
  		netbeans_inserted(curbuf, pos.lnum, bd.textcol,
Karsten Hopp 7b3c19
  						&ptr[bd.textcol], bd.textlen);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	if (did_change)
Karsten Hopp 7b3c19
  	    changed_lines(oap->start.lnum, 0, oap->end.lnum + 1, 0L);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else				    /* not block mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (oap->motion_type == MLINE)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
--- 2308,2319 ----
Karsten Hopp 7b3c19
  		netbeans_inserted(curbuf, pos.lnum, bd.textcol,
Karsten Hopp 7b3c19
  						&ptr[bd.textcol], bd.textlen);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	if (did_change)
Karsten Hopp 7b3c19
  	    changed_lines(oap->start.lnum, 0, oap->end.lnum + 1, 0L);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else				    /* not block mode */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (oap->motion_type == MLINE)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2412,2422 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (!did_change && oap->is_VIsual)
Karsten Hopp 7b3c19
  	/* No change: need to remove the Visual selection */
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Set '[ and '] marks.
Karsten Hopp 7b3c19
--- 2369,2377 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3018,3027 ****
Karsten Hopp 7b3c19
      if (       oap->motion_type == MCHAR
Karsten Hopp 7b3c19
  	    && oap->start.col == 0
Karsten Hopp 7b3c19
  	    && !oap->inclusive
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    && (!oap->is_VIsual || *p_sel == 'o')
Karsten Hopp 7b3c19
  	    && !oap->block_mode
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    && oap->end.col == 0
Karsten Hopp 7b3c19
  	    && yanklines > 1)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 2973,2980 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3032,3040 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      y_current->y_size = yanklines;
Karsten Hopp 7b3c19
      y_current->y_type = yanktype;   /* set the yank register type */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      y_current->y_width = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      y_current->y_array = (char_u **)lalloc_clear((long_u)(sizeof(char_u *) *
Karsten Hopp 7b3c19
  							    yanklines), TRUE);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 2985,2991 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3047,3053 ****
Karsten Hopp 7b3c19
      y_idx = 0;
Karsten Hopp 7b3c19
      lnum = oap->start.lnum;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->block_mode)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Visual block mode */
Karsten Hopp 7b3c19
--- 2998,3003 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3057,3075 ****
Karsten Hopp 7b3c19
  	if (curwin->w_curswant == MAXCOL && y_current->y_width > 0)
Karsten Hopp 7b3c19
  	    y_current->y_width--;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      for ( ; lnum <= yankendlnum; lnum++, y_idx++)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	switch (y_current->y_type)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    case MBLOCK:
Karsten Hopp 7b3c19
  		block_prep(oap, &bd, lnum, FALSE);
Karsten Hopp 7b3c19
  		if (yank_copy_line(&bd, y_idx) == FAIL)
Karsten Hopp 7b3c19
  		    goto fail;
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    case MLINE:
Karsten Hopp 7b3c19
  		if ((y_current->y_array[y_idx] =
Karsten Hopp 7b3c19
--- 3007,3022 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3206,3214 ****
Karsten Hopp 7b3c19
      if (mess)			/* Display message about yank? */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (yanktype == MCHAR
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		&& !oap->block_mode
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		&& yanklines == 1)
Karsten Hopp 7b3c19
  	    yanklines = 0;
Karsten Hopp 7b3c19
  	/* Some versions of Vi use ">=" here, some don't...  */
Karsten Hopp 7b3c19
--- 3153,3159 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3218,3234 ****
Karsten Hopp 7b3c19
  	    update_topline_redraw();
Karsten Hopp 7b3c19
  	    if (yanklines == 1)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		if (oap->block_mode)
Karsten Hopp 7b3c19
  		    MSG(_("block of 1 line yanked"));
Karsten Hopp 7b3c19
  		else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		    MSG(_("1 line yanked"));
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    else if (oap->block_mode)
Karsten Hopp 7b3c19
  		smsg((char_u *)_("block of %ld lines yanked"), yanklines);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  		smsg((char_u *)_("%ld lines yanked"), yanklines);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
--- 3163,3175 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3239,3249 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      curbuf->b_op_start = oap->start;
Karsten Hopp 7b3c19
      curbuf->b_op_end = oap->end;
Karsten Hopp 7b3c19
!     if (yanktype == MLINE
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		&& !oap->block_mode
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
!        )
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf->b_op_start.col = 0;
Karsten Hopp 7b3c19
  	curbuf->b_op_end.col = MAXCOL;
Karsten Hopp 7b3c19
--- 3180,3186 ----
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      curbuf->b_op_start = oap->start;
Karsten Hopp 7b3c19
      curbuf->b_op_end = oap->end;
Karsten Hopp 7b3c19
!     if (yanktype == MLINE && !oap->block_mode)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf->b_op_start.col = 0;
Karsten Hopp 7b3c19
  	curbuf->b_op_end.col = MAXCOL;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3380,3386 ****
Karsten Hopp 7b3c19
      long	i;			/* index in y_array[] */
Karsten Hopp 7b3c19
      int		y_type;
Karsten Hopp 7b3c19
      long	y_size;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		oldlen;
Karsten Hopp 7b3c19
      long	y_width = 0;
Karsten Hopp 7b3c19
      colnr_T	vcol;
Karsten Hopp 7b3c19
--- 3317,3322 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3388,3394 ****
Karsten Hopp 7b3c19
      int		incr = 0;
Karsten Hopp 7b3c19
      long	j;
Karsten Hopp 7b3c19
      struct block_def bd;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      char_u	**y_array = NULL;
Karsten Hopp 7b3c19
      long	nr_lines = 0;
Karsten Hopp 7b3c19
      pos_T	new_cursor;
Karsten Hopp 7b3c19
--- 3324,3329 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3497,3510 ****
Karsten Hopp 7b3c19
  	get_yank_register(regname, FALSE);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	y_type = y_current->y_type;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	y_width = y_current->y_width;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	y_size = y_current->y_size;
Karsten Hopp 7b3c19
  	y_array = y_current->y_array;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (y_type == MLINE)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (flags & PUT_LINE_SPLIT)
Karsten Hopp 7b3c19
--- 3432,3442 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3535,3541 ****
Karsten Hopp 7b3c19
  	curbuf->b_op_start = curwin->w_cursor;	/* default for '[ mark */
Karsten Hopp 7b3c19
  	curbuf->b_op_end = curwin->w_cursor;	/* default for '] mark */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (flags & PUT_LINE)	/* :put command or "p" in Visual line mode. */
Karsten Hopp 7b3c19
  	y_type = MLINE;
Karsten Hopp 7b3c19
--- 3467,3472 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3547,3553 ****
Karsten Hopp 7b3c19
  	goto end;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (y_type == MBLOCK)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	lnum = curwin->w_cursor.lnum + y_size + 1;
Karsten Hopp 7b3c19
--- 3478,3483 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3556,3564 ****
Karsten Hopp 7b3c19
  	if (u_save(curwin->w_cursor.lnum - 1, lnum) == FAIL)
Karsten Hopp 7b3c19
  	    goto end;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	if (y_type == MLINE)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	lnum = curwin->w_cursor.lnum;
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
--- 3486,3492 ----
Karsten Hopp 7b3c19
  	if (u_save(curwin->w_cursor.lnum - 1, lnum) == FAIL)
Karsten Hopp 7b3c19
  	    goto end;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else if (y_type == MLINE)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	lnum = curwin->w_cursor.lnum;
Karsten Hopp 7b3c19
  #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3610,3616 ****
Karsten Hopp 7b3c19
      lnum = curwin->w_cursor.lnum;
Karsten Hopp 7b3c19
      col = curwin->w_cursor.col;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Block mode
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 3538,3543 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3792,3798 ****
Karsten Hopp 7b3c19
  	    curwin->w_cursor.lnum = lnum;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * Character or Line mode
Karsten Hopp 7b3c19
--- 3719,3724 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3866,3882 ****
Karsten Hopp 7b3c19
  			curwin->w_cursor.col += (colnr_T)(totlen - 1);
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		if (VIsual_active)
Karsten Hopp 7b3c19
  		    lnum++;
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    } while (
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		    VIsual_active && lnum <= curbuf->b_visual.vi_end.lnum
Karsten Hopp 7b3c19
! #else
Karsten Hopp 7b3c19
! 		    FALSE /* stop after 1 paste */
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		    );
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    curbuf->b_op_end = curwin->w_cursor;
Karsten Hopp 7b3c19
  	    /* For "CTRL-O p" in Insert mode, put cursor after last char */
Karsten Hopp 7b3c19
--- 3792,3800 ----
Karsten Hopp 7b3c19
  			curwin->w_cursor.col += (colnr_T)(totlen - 1);
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  		if (VIsual_active)
Karsten Hopp 7b3c19
  		    lnum++;
Karsten Hopp 7b3c19
! 	    } while (VIsual_active && lnum <= curbuf->b_visual.vi_end.lnum);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    curbuf->b_op_end = curwin->w_cursor;
Karsten Hopp 7b3c19
  	    /* For "CTRL-O p" in Insert mode, put cursor after last char */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4038,4046 ****
Karsten Hopp 7b3c19
      if (regname == '=')
Karsten Hopp 7b3c19
  	vim_free(y_array);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      VIsual_active = FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* If the cursor is past the end of the line put it at the end. */
Karsten Hopp 7b3c19
      adjust_cursor_eol();
Karsten Hopp 7b3c19
--- 3956,3962 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4729,4739 ****
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
      curwin->w_cursor = oap->start;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->is_VIsual)
Karsten Hopp 7b3c19
  	/* When there is no change: need to remove the Visual selection */
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Set '[ mark at the start of the formatted area */
Karsten Hopp 7b3c19
      curbuf->b_op_start = oap->start;
Karsten Hopp 7b3c19
--- 4645,4653 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4765,4771 ****
Karsten Hopp 7b3c19
  	saved_cursor.lnum = 0;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->is_VIsual)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	win_T	*wp;
Karsten Hopp 7b3c19
--- 4679,4684 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4783,4789 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_EVAL) || defined(PROTO)
Karsten Hopp 7b3c19
--- 4696,4701 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4794,4804 ****
Karsten Hopp 7b3c19
  op_formatexpr(oap)
Karsten Hopp 7b3c19
      oparg_T	*oap;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (oap->is_VIsual)
Karsten Hopp 7b3c19
  	/* When there is no change: need to remove the Visual selection */
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (fex_format(oap->start.lnum, oap->line_count, NUL) != 0)
Karsten Hopp 7b3c19
  	/* As documented: when 'formatexpr' returns non-zero fall back to
Karsten Hopp 7b3c19
--- 4706,4714 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5238,5244 ****
Karsten Hopp 7b3c19
      return FALSE;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * prepare a few things for block mode yank/delete/tilde
Karsten Hopp 7b3c19
   *
Karsten Hopp 7b3c19
--- 5148,5153 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5397,5403 ****
Karsten Hopp 7b3c19
      bdp->textcol = (colnr_T) (pstart - line);
Karsten Hopp 7b3c19
      bdp->textstart = pstart;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  static void reverse_line __ARGS((char_u *s));
Karsten Hopp 7b3c19
--- 5306,5311 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5748,5766 ****
Karsten Hopp 7b3c19
  	str = skipwhite(skiptowhite(str));
Karsten Hopp 7b3c19
  	if (STRNCMP(str, "CHAR", 4) == 0)
Karsten Hopp 7b3c19
  	    y_current->y_type = MCHAR;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	else if (STRNCMP(str, "BLOCK", 5) == 0)
Karsten Hopp 7b3c19
  	    y_current->y_type = MBLOCK;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    y_current->y_type = MLINE;
Karsten Hopp 7b3c19
  	/* get the block width; if it's missing we get a zero, which is OK */
Karsten Hopp 7b3c19
  	str = skipwhite(skiptowhite(str));
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	y_current->y_width = getdigits(&str);
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
- 	(void)getdigits(&str);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      while (!(eof = viminfo_readline(virp))
Karsten Hopp 7b3c19
--- 5656,5668 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5868,5878 ****
Karsten Hopp 7b3c19
  	    case MCHAR:
Karsten Hopp 7b3c19
  		type = (char_u *)"CHAR";
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    case MBLOCK:
Karsten Hopp 7b3c19
  		type = (char_u *)"BLOCK";
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    default:
Karsten Hopp 7b3c19
  		sprintf((char *)IObuff, _("E574: Unknown register type %d"),
Karsten Hopp 7b3c19
  							    y_regs[i].y_type);
Karsten Hopp 7b3c19
--- 5770,5778 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 5886,5898 ****
Karsten Hopp 7b3c19
  	fprintf(fp, "\"%c", c);
Karsten Hopp 7b3c19
  	if (c == execreg_lastc)
Karsten Hopp 7b3c19
  	    fprintf(fp, "@");
Karsten Hopp 7b3c19
! 	fprintf(fp, "\t%s\t%d\n", type,
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		    (int)y_regs[i].y_width
Karsten Hopp 7b3c19
! #else
Karsten Hopp 7b3c19
! 		    0
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		    );
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* If max_num_lines < 0, then we save ALL the lines in the register */
Karsten Hopp 7b3c19
  	if (max_num_lines > 0 && num_lines > max_num_lines)
Karsten Hopp 7b3c19
--- 5786,5792 ----
Karsten Hopp 7b3c19
  	fprintf(fp, "\"%c", c);
Karsten Hopp 7b3c19
  	if (c == execreg_lastc)
Karsten Hopp 7b3c19
  	    fprintf(fp, "@");
Karsten Hopp 7b3c19
! 	fprintf(fp, "\t%s\t%d\n", type, (int)y_regs[i].y_width);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* If max_num_lines < 0, then we save ALL the lines in the register */
Karsten Hopp 7b3c19
  	if (max_num_lines > 0 && num_lines > max_num_lines)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6039,6048 ****
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      struct yankreg *old_y_previous, *old_y_current;
Karsten Hopp 7b3c19
      pos_T	old_cursor;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      pos_T	old_visual;
Karsten Hopp 7b3c19
      int		old_visual_mode;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      colnr_T	old_curswant;
Karsten Hopp 7b3c19
      int		old_set_curswant;
Karsten Hopp 7b3c19
      pos_T	old_op_start, old_op_end;
Karsten Hopp 7b3c19
--- 5933,5940 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6063,6072 ****
Karsten Hopp 7b3c19
  	old_set_curswant = curwin->w_set_curswant;
Karsten Hopp 7b3c19
  	old_op_start = curbuf->b_op_start;
Karsten Hopp 7b3c19
  	old_op_end = curbuf->b_op_end;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	old_visual = VIsual;
Karsten Hopp 7b3c19
  	old_visual_mode = VIsual_mode;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	clear_oparg(&oa);
Karsten Hopp 7b3c19
  	oa.regname = (cbd == &clip_plus ? '+' : '*');
Karsten Hopp 7b3c19
  	oa.op_type = OP_YANK;
Karsten Hopp 7b3c19
--- 5955,5962 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6084,6093 ****
Karsten Hopp 7b3c19
  	curwin->w_set_curswant = old_set_curswant;
Karsten Hopp 7b3c19
  	curbuf->b_op_start = old_op_start;
Karsten Hopp 7b3c19
  	curbuf->b_op_end = old_op_end;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	VIsual = old_visual;
Karsten Hopp 7b3c19
  	VIsual_mode = old_visual_mode;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 5974,5981 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6190,6196 ****
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- # if defined(FEAT_VISUAL) || defined(FEAT_EVAL)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * If we have written to a clipboard register, send the text to the clipboard.
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 6078,6083 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6208,6214 ****
Karsten Hopp 7b3c19
  	clip_gen_set_selection(&clip_plus);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #endif /* FEAT_CLIPBOARD || PROTO */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 6095,6100 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6273,6282 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (y_current->y_array != NULL)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (reglen != NULL && y_current->y_type == MBLOCK)
Karsten Hopp 7b3c19
  	    *reglen = y_current->y_width;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	return y_current->y_type;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      return MAUTO;
Karsten Hopp 7b3c19
--- 6159,6166 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6454,6464 ****
Karsten Hopp 7b3c19
      get_yank_register(name, TRUE);
Karsten Hopp 7b3c19
      if (!y_append && !must_append)
Karsten Hopp 7b3c19
  	free_yank_all();
Karsten Hopp 7b3c19
- #ifndef FEAT_VISUAL
Karsten Hopp 7b3c19
-     /* Just in case - make sure we don't use MBLOCK */
Karsten Hopp 7b3c19
-     if (yank_type == MBLOCK)
Karsten Hopp 7b3c19
- 	yank_type = MAUTO;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      str_to_reg(y_current, yank_type, str, len, block_len);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  # ifdef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
--- 6338,6343 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6496,6504 ****
Karsten Hopp 7b3c19
      int		append = FALSE;		/* append to last line in register */
Karsten Hopp 7b3c19
      char_u	*s;
Karsten Hopp 7b3c19
      char_u	**pp;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      long	maxlen;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (y_ptr->y_array == NULL)		/* NULL means empty register */
Karsten Hopp 7b3c19
  	y_ptr->y_size = 0;
Karsten Hopp 7b3c19
--- 6375,6381 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6539,6547 ****
Karsten Hopp 7b3c19
  	pp[lnum] = y_ptr->y_array[lnum];
Karsten Hopp 7b3c19
      vim_free(y_ptr->y_array);
Karsten Hopp 7b3c19
      y_ptr->y_array = pp;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      maxlen = 0;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Find the end of each line and save it into the array.
Karsten Hopp 7b3c19
--- 6416,6422 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6552,6561 ****
Karsten Hopp 7b3c19
  	    if (str[i] == '\n')
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  	i -= start;			/* i is now length of line */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (i > maxlen)
Karsten Hopp 7b3c19
  	    maxlen = i;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	if (append)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    --lnum;
Karsten Hopp 7b3c19
--- 6427,6434 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6585,6596 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      y_ptr->y_type = type;
Karsten Hopp 7b3c19
      y_ptr->y_size = lnum;
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (type == MBLOCK)
Karsten Hopp 7b3c19
  	y_ptr->y_width = (blocklen < 0 ? maxlen - 1 : blocklen);
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	y_ptr->y_width = 0;
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif /* FEAT_CLIPBOARD || FEAT_EVAL || PROTO */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 6458,6467 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6684,6695 ****
Karsten Hopp 7b3c19
      long	word_count_cursor = 0;
Karsten Hopp 7b3c19
      int		eol_size;
Karsten Hopp 7b3c19
      long	last_check = 100000L;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      long	line_count_selected = 0;
Karsten Hopp 7b3c19
      pos_T	min_pos, max_pos;
Karsten Hopp 7b3c19
      oparg_T	oparg;
Karsten Hopp 7b3c19
      struct block_def	bd;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Compute the length of the file in characters.
Karsten Hopp 7b3c19
--- 6555,6564 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6705,6711 ****
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
  	    eol_size = 1;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
--- 6574,6579 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6749,6755 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    line_count_selected = max_pos.lnum - min_pos.lnum + 1;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	for (lnum = 1; lnum <= curbuf->b_ml.ml_line_count; ++lnum)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
--- 6617,6622 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6762,6768 ****
Karsten Hopp 7b3c19
  		last_check = byte_count + 100000L;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    /* Do extra processing for VIsual mode. */
Karsten Hopp 7b3c19
  	    if (VIsual_active
Karsten Hopp 7b3c19
  		    && lnum >= min_pos.lnum && lnum <= max_pos.lnum)
Karsten Hopp 7b3c19
--- 6629,6634 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6773,6785 ****
Karsten Hopp 7b3c19
  		switch (VIsual_mode)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    case Ctrl_V:
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			virtual_op = virtual_active();
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  			block_prep(&oparg, &bd, lnum, 0);
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			virtual_op = MAYBE;
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  			s = bd.textstart;
Karsten Hopp 7b3c19
  			len = (long)bd.textlen;
Karsten Hopp 7b3c19
  			break;
Karsten Hopp 7b3c19
--- 6639,6651 ----
Karsten Hopp 7b3c19
  		switch (VIsual_mode)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    case Ctrl_V:
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			virtual_op = virtual_active();
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  			block_prep(&oparg, &bd, lnum, 0);
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
  			virtual_op = MAYBE;
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  			s = bd.textstart;
Karsten Hopp 7b3c19
  			len = (long)bd.textlen;
Karsten Hopp 7b3c19
  			break;
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6811,6817 ****
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
  		/* In non-visual mode, check for the line the cursor is on */
Karsten Hopp 7b3c19
  		if (lnum == curwin->w_cursor.lnum)
Karsten Hopp 7b3c19
--- 6677,6682 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6833,6839 ****
Karsten Hopp 7b3c19
  	if (!curbuf->b_p_eol && curbuf->b_p_bin)
Karsten Hopp 7b3c19
  	    byte_count -= eol_size;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (VIsual_mode == Ctrl_V && curwin->w_curswant < MAXCOL)
Karsten Hopp 7b3c19
--- 6698,6703 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6864,6870 ****
Karsten Hopp 7b3c19
  			byte_count_cursor, byte_count);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    p = ml_get_curline();
Karsten Hopp 7b3c19
  	    validate_virtcol();
Karsten Hopp 7b3c19
--- 6728,6733 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/option.c	2014-03-12 18:55:52.100906804 +0100
Karsten Hopp 7b3c19
--- src/option.c	2014-03-23 13:28:12.359168452 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1629,1639 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  			    SCRIPTID_INIT},
Karsten Hopp 7b3c19
      {"keymodel",    "km",   P_STRING|P_VI_DEF|P_COMMA|P_NODUP,
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			    (char_u *)&p_km, PV_NONE,
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
- 			    (char_u *)NULL, PV_NONE,
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  			    {(char_u *)"", (char_u *)0L} SCRIPTID_INIT},
Karsten Hopp 7b3c19
      {"keywordprg",  "kp",   P_STRING|P_EXPAND|P_VI_DEF|P_SECURE,
Karsten Hopp 7b3c19
  			    (char_u *)&p_kp, PV_KP,
Karsten Hopp 7b3c19
--- 1629,1635 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2190,2208 ****
Karsten Hopp 7b3c19
  			    (char_u *)&p_secure, PV_NONE,
Karsten Hopp 7b3c19
  			    {(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT},
Karsten Hopp 7b3c19
      {"selection",   "sel",  P_STRING|P_VI_DEF,
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			    (char_u *)&p_sel, PV_NONE,
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
- 			    (char_u *)NULL, PV_NONE,
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  			    {(char_u *)"inclusive", (char_u *)0L}
Karsten Hopp 7b3c19
  			    SCRIPTID_INIT},
Karsten Hopp 7b3c19
      {"selectmode",  "slm",  P_STRING|P_VI_DEF|P_COMMA|P_NODUP,
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			    (char_u *)&p_slm, PV_NONE,
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
- 			    (char_u *)NULL, PV_NONE,
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  			    {(char_u *)"", (char_u *)0L} SCRIPTID_INIT},
Karsten Hopp 7b3c19
      {"sessionoptions", "ssop", P_STRING|P_VI_DEF|P_COMMA|P_NODUP,
Karsten Hopp 7b3c19
  #ifdef FEAT_SESSION
Karsten Hopp 7b3c19
--- 2186,2196 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2979,2991 ****
Karsten Hopp 7b3c19
  static char *(p_wak_values[]) = {"yes", "menu", "no", NULL};
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  static char *(p_mousem_values[]) = {"extend", "popup", "popup_setpos", "mac", NULL};
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static char *(p_sel_values[]) = {"inclusive", "exclusive", "old", NULL};
Karsten Hopp 7b3c19
  static char *(p_slm_values[]) = {"mouse", "key", "cmd", NULL};
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static char *(p_km_values[]) = {"startsel", "stopsel", NULL};
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_BROWSE
Karsten Hopp 7b3c19
  static char *(p_bsdir_values[]) = {"current", "last", "buffer", NULL};
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 2967,2975 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6578,6584 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* 'selection' */
Karsten Hopp 7b3c19
      else if (varp == &p_sel)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 6562,6567 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6593,6599 ****
Karsten Hopp 7b3c19
  	if (check_opt_strings(p_slm, p_slm_values, TRUE) != OK)
Karsten Hopp 7b3c19
  	    errmsg = e_invarg;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_BROWSE
Karsten Hopp 7b3c19
      /* 'browsedir' */
Karsten Hopp 7b3c19
--- 6576,6581 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6605,6611 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* 'keymodel' */
Karsten Hopp 7b3c19
      else if (varp == &p_km)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 6587,6592 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6617,6623 ****
Karsten Hopp 7b3c19
  	    km_startsel = (vim_strchr(p_km, 'a') != NULL);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* 'mousemodel' */
Karsten Hopp 7b3c19
      else if (varp == &p_mousem)
Karsten Hopp 7b3c19
--- 6598,6603 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/os_msdos.c	2013-05-06 04:06:04.000000000 +0200
Karsten Hopp 7b3c19
--- src/os_msdos.c	2014-03-23 13:28:24.855168644 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2270,2278 ****
Karsten Hopp 7b3c19
  		default:
Karsten Hopp 7b3c19
  		case 'L':	type = MLINE;	break;
Karsten Hopp 7b3c19
  		case 'C':	type = MCHAR;	break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		case 'B':	type = MBLOCK;	break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 2270,2276 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2799,2807 ****
Karsten Hopp 7b3c19
  	    default:
Karsten Hopp 7b3c19
  	    case MLINE:	    clip_sel_type = "L";	break;
Karsten Hopp 7b3c19
  	    case MCHAR:	    clip_sel_type = "C";	break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    case MBLOCK:    clip_sel_type = "B";	break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	movedata(
Karsten Hopp 7b3c19
--- 2797,2803 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/os_qnx.c	2011-09-21 19:48:08.000000000 +0200
Karsten Hopp 7b3c19
--- src/os_qnx.c	2014-03-23 13:28:38.815168858 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 78,86 ****
Karsten Hopp 7b3c19
  		default: /* fallthrough to line type */
Karsten Hopp 7b3c19
  		case 'L': type = MLINE; break;
Karsten Hopp 7b3c19
  		case 'C': type = MCHAR; break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		case 'B': type = MBLOCK; break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	    is_type_set = TRUE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
--- 78,84 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 143,151 ****
Karsten Hopp 7b3c19
  		default: /* fallthrough to MLINE */
Karsten Hopp 7b3c19
  		case MLINE:	*vim_clip = 'L'; break;
Karsten Hopp 7b3c19
  		case MCHAR:	*vim_clip = 'C'; break;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		case MBLOCK:	*vim_clip = 'B'; break;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    vim_strncpy(text_clip, str, len);
Karsten Hopp 7b3c19
--- 141,147 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/quickfix.c	2014-03-12 19:41:37.096948866 +0100
Karsten Hopp 7b3c19
--- src/quickfix.c	2014-03-23 13:28:50.907169043 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2347,2355 ****
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	height = QF_WINHEIGHT;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      reset_VIsual_and_resel();			/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_GUI
Karsten Hopp 7b3c19
      need_mouse_correct = TRUE;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 2347,2353 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/regexp.c	2013-11-21 17:12:55.000000000 +0100
Karsten Hopp 7b3c19
--- src/regexp.c	2014-03-23 13:29:14.495169404 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4179,4187 ****
Karsten Hopp 7b3c19
  			    - (*mb_head_off)(regline, reginput - 1), reg_buf);
Karsten Hopp 7b3c19
      return -1;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- 
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  static int reg_match_visual __ARGS((void));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 4179,4186 ----
Karsten Hopp 7b3c19
  			    - (*mb_head_off)(regline, reginput - 1), reg_buf);
Karsten Hopp 7b3c19
      return -1;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
! 
Karsten Hopp 7b3c19
  static int reg_match_visual __ARGS((void));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4258,4264 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      return TRUE;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #define ADVANCE_REGINPUT() mb_ptr_adv(reginput)
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 4257,4262 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4440,4448 ****
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	  case RE_VISUAL:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	    if (!reg_match_visual())
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		status = RA_NOMATCH;
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 4438,4444 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/regexp_nfa.c	2013-11-28 14:20:11.000000000 +0100
Karsten Hopp 7b3c19
--- src/regexp_nfa.c	2014-03-23 13:29:31.367169663 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6403,6416 ****
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    case NFA_VISUAL:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		result = reg_match_visual();
Karsten Hopp 7b3c19
  		if (result)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    add_here = TRUE;
Karsten Hopp 7b3c19
  		    add_state = t->state->out;
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	    case NFA_MOPEN1:
Karsten Hopp 7b3c19
--- 6403,6414 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/screen.c	2013-12-11 15:51:54.000000000 +0100
Karsten Hopp 7b3c19
--- src/screen.c	2014-03-23 13:32:10.787172106 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 446,453 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_RUBY) || defined(FEAT_PERL) || defined(FEAT_VISUAL) || \
Karsten Hopp 7b3c19
-     (defined(FEAT_CLIPBOARD) && defined(FEAT_X11)) || defined(PROTO)
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * update all windows that are editing the current buffer
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
--- 446,451 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 458,464 ****
Karsten Hopp 7b3c19
      redraw_curbuf_later(type);
Karsten Hopp 7b3c19
      update_screen(type);
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
   * update_screen()
Karsten Hopp 7b3c19
--- 456,461 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 596,609 ****
Karsten Hopp 7b3c19
  		    && curwin->w_botfill == curwin->w_old_botfill
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  		    && curwin->w_topline == curwin->w_lines[0].wl_lnum)
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		|| (type == INVERTED
Karsten Hopp 7b3c19
  		    && VIsual_active
Karsten Hopp 7b3c19
  		    && curwin->w_old_cursor_lnum == curwin->w_cursor.lnum
Karsten Hopp 7b3c19
  		    && curwin->w_old_visual_mode == VIsual_mode
Karsten Hopp 7b3c19
  		    && (curwin->w_valid & VALID_VIRTCOL)
Karsten Hopp 7b3c19
  		    && curwin->w_old_curswant == curwin->w_curswant)
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		))
Karsten Hopp 7b3c19
  	curwin->w_redr_type = type;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 593,604 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1030,1039 ****
Karsten Hopp 7b3c19
  				   updating.  0 when no mid area updating. */
Karsten Hopp 7b3c19
      int		bot_start = 999;/* first row of the bot area that needs
Karsten Hopp 7b3c19
  				   updating.  999 when no bot area updating */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		scrolled_down = FALSE;	/* TRUE when scrolled down when
Karsten Hopp 7b3c19
  					   w_topline got smaller a bit */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_SEARCH_EXTRA
Karsten Hopp 7b3c19
      matchitem_T *cur;		/* points to the match list */
Karsten Hopp 7b3c19
      int		top_to_mod = FALSE;    /* redraw above mod_top */
Karsten Hopp 7b3c19
--- 1025,1032 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1354,1362 ****
Karsten Hopp 7b3c19
  			    /* Need to update rows that are new, stop at the
Karsten Hopp 7b3c19
  			     * first one that scrolled down. */
Karsten Hopp 7b3c19
  			    top_end = i;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			    scrolled_down = TRUE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  			    /* Move the entries that were scrolled, disable
Karsten Hopp 7b3c19
  			     * the entries for the lines to be redrawn. */
Karsten Hopp 7b3c19
--- 1347,1353 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1513,1519 ****
Karsten Hopp 7b3c19
  	type = NOT_VALID;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* check if we are updating or removing the inverted part */
Karsten Hopp 7b3c19
      if ((VIsual_active && buf == curwin->w_buffer)
Karsten Hopp 7b3c19
  	    || (wp->w_old_cursor_lnum != 0 && type != NOT_VALID))
Karsten Hopp 7b3c19
--- 1504,1509 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1708,1714 ****
Karsten Hopp 7b3c19
  	wp->w_old_visual_lnum = 0;
Karsten Hopp 7b3c19
  	wp->w_old_visual_col = 0;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_SYN_HL) || defined(FEAT_SEARCH_EXTRA)
Karsten Hopp 7b3c19
      /* reset got_int, otherwise regexp won't work */
Karsten Hopp 7b3c19
--- 1698,1703 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2670,2676 ****
Karsten Hopp 7b3c19
       * 6. set highlighting for the Visual area an other text.
Karsten Hopp 7b3c19
       * If all folded lines are in the Visual area, highlight the line.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active && wp->w_buffer == curwin->w_buffer)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (ltoreq(curwin->w_cursor, VIsual))
Karsten Hopp 7b3c19
--- 2659,2664 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2718,2724 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_SYN_HL
Karsten Hopp 7b3c19
      /* Show 'cursorcolumn' in the fold line. */
Karsten Hopp 7b3c19
--- 2706,2711 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2876,2885 ****
Karsten Hopp 7b3c19
      int		fromcol, tocol;		/* start/end of inverting */
Karsten Hopp 7b3c19
      int		fromcol_prev = -2;	/* start of inverting after cursor */
Karsten Hopp 7b3c19
      int		noinvcur = FALSE;	/* don't invert the cursor */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      pos_T	*top, *bot;
Karsten Hopp 7b3c19
      int		lnum_in_visual_area = FALSE;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      pos_T	pos;
Karsten Hopp 7b3c19
      long	v;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 2863,2870 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3090,3096 ****
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      fromcol = -10;
Karsten Hopp 7b3c19
      tocol = MAXCOL;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active && wp->w_buffer == curwin->w_buffer)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  					/* Visual is after curwin->w_cursor */
Karsten Hopp 7b3c19
--- 3075,3080 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3183,3191 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * handle 'incsearch' and ":s///c" highlighting
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
! 	if (highlight_match
Karsten Hopp 7b3c19
  	    && wp == curwin
Karsten Hopp 7b3c19
  	    && lnum >= curwin->w_cursor.lnum
Karsten Hopp 7b3c19
  	    && lnum <= curwin->w_cursor.lnum + search_match_lines)
Karsten Hopp 7b3c19
--- 3167,3173 ----
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * handle 'incsearch' and ":s///c" highlighting
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
!     else if (highlight_match
Karsten Hopp 7b3c19
  	    && wp == curwin
Karsten Hopp 7b3c19
  	    && lnum >= curwin->w_cursor.lnum
Karsten Hopp 7b3c19
  	    && lnum <= curwin->w_cursor.lnum + search_match_lines)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3324,3330 ****
Karsten Hopp 7b3c19
  	    mb_ptr_adv(ptr);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_SYN_HL) || defined(FEAT_VIRTUALEDIT) || defined(FEAT_VISUAL)
Karsten Hopp 7b3c19
  	/* When:
Karsten Hopp 7b3c19
  	 * - 'cuc' is set, or
Karsten Hopp 7b3c19
  	 * - 'colorcolumn' is set, or
Karsten Hopp 7b3c19
--- 3306,3311 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3333,3359 ****
Karsten Hopp 7b3c19
  	 * the end of the line may be before the start of the displayed part.
Karsten Hopp 7b3c19
  	 */
Karsten Hopp 7b3c19
  	if (vcol < v && (
Karsten Hopp 7b3c19
! # ifdef FEAT_SYN_HL
Karsten Hopp 7b3c19
! 	     wp->w_p_cuc
Karsten Hopp 7b3c19
! 	     || draw_color_col
Karsten Hopp 7b3c19
! #  if defined(FEAT_VIRTUALEDIT) || defined(FEAT_VISUAL)
Karsten Hopp 7b3c19
! 	     ||
Karsten Hopp 7b3c19
! #  endif
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! # ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
! 	     virtual_active()
Karsten Hopp 7b3c19
! #  ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	     ||
Karsten Hopp 7b3c19
! #  endif
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	     (VIsual_active && wp->w_buffer == curwin->w_buffer)
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! 	     ))
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    vcol = v;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* Handle a character that's not completely on the screen: Put ptr at
Karsten Hopp 7b3c19
  	 * that character but skip the first few screen characters. */
Karsten Hopp 7b3c19
--- 3314,3329 ----
Karsten Hopp 7b3c19
  	 * the end of the line may be before the start of the displayed part.
Karsten Hopp 7b3c19
  	 */
Karsten Hopp 7b3c19
  	if (vcol < v && (
Karsten Hopp 7b3c19
! #ifdef FEAT_SYN_HL
Karsten Hopp 7b3c19
! 	     wp->w_p_cuc || draw_color_col ||
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! #ifdef FEAT_VIRTUALEDIT
Karsten Hopp 7b3c19
! 	     virtual_active() ||
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	     (VIsual_active && wp->w_buffer == curwin->w_buffer)))
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    vcol = v;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* Handle a character that's not completely on the screen: Put ptr at
Karsten Hopp 7b3c19
  	 * that character but skip the first few screen characters. */
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4500,4508 ****
Karsten Hopp 7b3c19
  			&& ((wp->w_p_list && lcs_eol > 0)
Karsten Hopp 7b3c19
  			    || ((fromcol >= 0 || fromcol_prev >= 0)
Karsten Hopp 7b3c19
  				&& tocol > vcol
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  				&& VIsual_mode != Ctrl_V
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  				&& (
Karsten Hopp 7b3c19
  # ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  				    wp->w_p_rl ? (col >= 0) :
Karsten Hopp 7b3c19
--- 4470,4476 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4854,4864 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	    if (lcs_eol == lcs_eol_one
Karsten Hopp 7b3c19
  		    && ((area_attr != 0 && vcol == fromcol
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			    && (VIsual_mode != Ctrl_V
Karsten Hopp 7b3c19
  				|| lnum == VIsual.lnum
Karsten Hopp 7b3c19
  				|| lnum == curwin->w_cursor.lnum)
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  			    && c == NUL)
Karsten Hopp 7b3c19
  #ifdef FEAT_SEARCH_EXTRA
Karsten Hopp 7b3c19
  			/* highlight 'hlsearch' match at end of line */
Karsten Hopp 7b3c19
--- 4822,4830 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9659,9668 ****
Karsten Hopp 7b3c19
      do_mode = ((p_smd && msg_silent == 0)
Karsten Hopp 7b3c19
  	    && ((State & INSERT)
Karsten Hopp 7b3c19
  		|| restart_edit
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		|| VIsual_active
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 		));
Karsten Hopp 7b3c19
      if (do_mode || Recording)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
--- 9625,9631 ----
Karsten Hopp 7b3c19
      do_mode = ((p_smd && msg_silent == 0)
Karsten Hopp 7b3c19
  	    && ((State & INSERT)
Karsten Hopp 7b3c19
  		|| restart_edit
Karsten Hopp 7b3c19
! 		|| VIsual_active));
Karsten Hopp 7b3c19
      if (do_mode || Recording)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9790,9796 ****
Karsten Hopp 7b3c19
  		if ((State & INSERT) && p_paste)
Karsten Hopp 7b3c19
  		    MSG_PUTS_ATTR(_(" (paste)"), attr);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		if (VIsual_active)
Karsten Hopp 7b3c19
  		{
Karsten Hopp 7b3c19
  		    char *p;
Karsten Hopp 7b3c19
--- 9753,9758 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9810,9816 ****
Karsten Hopp 7b3c19
  		    }
Karsten Hopp 7b3c19
  		    MSG_PUTS_ATTR(_(p), attr);
Karsten Hopp 7b3c19
  		}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		MSG_PUTS_ATTR(" --", attr);
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 9772,9777 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 9839,9849 ****
Karsten Hopp 7b3c19
  	msg_clr_cmdline();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDL_INFO
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* In Visual mode the size of the selected area must be redrawn. */
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	clear_showcmd();
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* If the last window has no status line, the ruler is after the mode
Karsten Hopp 7b3c19
       * message and must be redrawn */
Karsten Hopp 7b3c19
--- 9800,9808 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/search.c	2014-01-14 21:31:30.000000000 +0100
Karsten Hopp 7b3c19
--- src/search.c	2014-03-23 13:34:46.351174489 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 506,512 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
!  * lowest level search function.
Karsten Hopp 7b3c19
   * Search for 'count'th occurrence of pattern 'pat' in direction 'dir'.
Karsten Hopp 7b3c19
   * Start at position 'pos' and return the found position in 'pos'.
Karsten Hopp 7b3c19
   *
Karsten Hopp 7b3c19
--- 506,512 ----
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
!  * Lowest level search function.
Karsten Hopp 7b3c19
   * Search for 'count'th occurrence of pattern 'pat' in direction 'dir'.
Karsten Hopp 7b3c19
   * Start at position 'pos' and return the found position in 'pos'.
Karsten Hopp 7b3c19
   *
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3198,3204 ****
Karsten Hopp 7b3c19
      cls_bigword = bigword;
Karsten Hopp 7b3c19
      clearpos(&start_pos);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Correct cursor when 'selection' is exclusive */
Karsten Hopp 7b3c19
      if (VIsual_active && *p_sel == 'e' && lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
  	dec_cursor();
Karsten Hopp 7b3c19
--- 3198,3203 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3208,3214 ****
Karsten Hopp 7b3c19
       * character, select the word and/or white space under the cursor.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      if (!VIsual_active || equalpos(curwin->w_cursor, VIsual))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * Go to start of current word or white space.
Karsten Hopp 7b3c19
--- 3207,3212 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3245,3251 ****
Karsten Hopp 7b3c19
  		include_white = TRUE;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /* should do something when inclusive == FALSE ! */
Karsten Hopp 7b3c19
--- 3243,3248 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3253,3259 ****
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);	/* update the inversion */
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    oap->start = start_pos;
Karsten Hopp 7b3c19
  	    oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
--- 3250,3255 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3267,3273 ****
Karsten Hopp 7b3c19
      while (count > 0)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	inclusive = TRUE;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (VIsual_active && lt(curwin->w_cursor, VIsual))
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
--- 3263,3268 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3288,3294 ****
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    /*
Karsten Hopp 7b3c19
  	     * Move cursor forward one word and/or white area.
Karsten Hopp 7b3c19
--- 3283,3288 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3334,3351 ****
Karsten Hopp 7b3c19
  	    back_in_line();
Karsten Hopp 7b3c19
  	    if (cls() == 0 && curwin->w_cursor.col > 0)
Karsten Hopp 7b3c19
  	    {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		if (VIsual_active)
Karsten Hopp 7b3c19
  		    VIsual = curwin->w_cursor;
Karsten Hopp 7b3c19
  		else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		    oap->start = curwin->w_cursor;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	curwin->w_cursor = pos;	/* put cursor back at end */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (*p_sel == 'e' && inclusive && ltoreq(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
--- 3328,3342 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3357,3363 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	oap->inclusive = inclusive;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      return OK;
Karsten Hopp 7b3c19
--- 3348,3353 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3384,3390 ****
Karsten Hopp 7b3c19
      pos = start_pos;
Karsten Hopp 7b3c19
      findsent(FORWARD, 1L);	/* Find start of next sentence. */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * When the Visual area is bigger than one character: Extend it.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 3374,3379 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3471,3477 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	return OK;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If the cursor started on a blank, check if it is just before the start
Karsten Hopp 7b3c19
--- 3460,3465 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3521,3527 ****
Karsten Hopp 7b3c19
  	    find_first_blank(&start_pos);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Avoid getting stuck with "is" on a single space before a sentence. */
Karsten Hopp 7b3c19
--- 3509,3514 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3534,3540 ****
Karsten Hopp 7b3c19
  	redraw_curbuf_later(INVERTED);	/* update the inversion */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* include a newline after the sentence, if there is one */
Karsten Hopp 7b3c19
  	if (incl(&curwin->w_cursor) == -1)
Karsten Hopp 7b3c19
--- 3521,3526 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3574,3582 ****
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If we start on '(', '{', ')', '}', etc., use the whole block inclusive.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (!VIsual_active || equalpos(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	setpcmark();
Karsten Hopp 7b3c19
  	if (what == '{')		/* ignore indent */
Karsten Hopp 7b3c19
--- 3560,3566 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3587,3593 ****
Karsten Hopp 7b3c19
  	    /* cursor on '(' or '{', move cursor just after it */
Karsten Hopp 7b3c19
  	    ++curwin->w_cursor.col;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if (lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	old_start = VIsual;
Karsten Hopp 7b3c19
--- 3571,3576 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3595,3601 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	old_end = VIsual;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * Search backwards for unclosed '(', '{', etc..
Karsten Hopp 7b3c19
--- 3578,3583 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3641,3647 ****
Karsten Hopp 7b3c19
  		if (decl(&curwin->w_cursor) != 0)
Karsten Hopp 7b3c19
  		    break;
Karsten Hopp 7b3c19
  	    }
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/*
Karsten Hopp 7b3c19
  	 * In Visual mode, when the resulting area is not bigger than what we
Karsten Hopp 7b3c19
  	 * started with, extend it to the next block, and then exclude again.
Karsten Hopp 7b3c19
--- 3623,3628 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3666,3676 ****
Karsten Hopp 7b3c19
  	    curwin->w_cursor = *end_pos;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  	else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	    break;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (*p_sel == 'e')
Karsten Hopp 7b3c19
--- 3647,3655 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3683,3689 ****
Karsten Hopp 7b3c19
  	showmode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	oap->start = start_pos;
Karsten Hopp 7b3c19
  	oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
--- 3662,3667 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3807,3823 ****
Karsten Hopp 7b3c19
      old_pos = curwin->w_cursor;
Karsten Hopp 7b3c19
      old_end = curwin->w_cursor;		    /* remember where we started */
Karsten Hopp 7b3c19
      old_start = old_end;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (!VIsual_active || *p_sel == 'e')
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	decl(&old_end);			    /* old_end is inclusive */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If we start on "<aaa>" select that block.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (!VIsual_active || equalpos(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	setpcmark();
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 3785,3797 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3843,3849 ****
Karsten Hopp 7b3c19
  	    old_end = curwin->w_cursor;
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      else if (lt(VIsual, curwin->w_cursor))
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	old_start = VIsual;
Karsten Hopp 7b3c19
--- 3817,3822 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3851,3857 ****
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  	old_end = VIsual;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  again:
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
--- 3824,3829 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3951,3957 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* If the end is before the start there is no text between tags, select
Karsten Hopp 7b3c19
--- 3923,3928 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3966,3972 ****
Karsten Hopp 7b3c19
  	showmode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	oap->start = start_pos;
Karsten Hopp 7b3c19
  	oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
--- 3937,3942 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4010,4016 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      start_lnum = curwin->w_cursor.lnum;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * When visual area is more than one line: extend it.
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 3980,3985 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4064,4070 ****
Karsten Hopp 7b3c19
  	curwin->w_cursor.col = 0;
Karsten Hopp 7b3c19
  	return retval;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * First move back to the start_lnum of the paragraph or white lines
Karsten Hopp 7b3c19
--- 4033,4038 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4136,4142 ****
Karsten Hopp 7b3c19
  	while (start_lnum > 1 && linewhite(start_lnum - 1))
Karsten Hopp 7b3c19
  	    --start_lnum;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Problem: when doing "Vipipip" nothing happens in a single white
Karsten Hopp 7b3c19
--- 4104,4109 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4149,4155 ****
Karsten Hopp 7b3c19
  	showmode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	oap->start.lnum = start_lnum;
Karsten Hopp 7b3c19
  	oap->start.col = 0;
Karsten Hopp 7b3c19
--- 4116,4121 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4247,4253 ****
Karsten Hopp 7b3c19
      int		col_end;
Karsten Hopp 7b3c19
      int		col_start = curwin->w_cursor.col;
Karsten Hopp 7b3c19
      int		inclusive = FALSE;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		vis_empty = TRUE;	/* Visual selection <= 1 char */
Karsten Hopp 7b3c19
      int		vis_bef_curs = FALSE;	/* Visual starts before cursor */
Karsten Hopp 7b3c19
      int		inside_quotes = FALSE;	/* Looks like "i'" done before */
Karsten Hopp 7b3c19
--- 4213,4218 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4331,4347 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
!     if (line[col_start] == quotechar
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    || !vis_empty
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    )
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int	first_col = col_start;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (!vis_empty)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (vis_bef_curs)
Karsten Hopp 7b3c19
--- 4296,4306 ----
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
!     if (line[col_start] == quotechar || !vis_empty)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int	first_col = col_start;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	if (!vis_empty)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    if (vis_bef_curs)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4349,4355 ****
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  		first_col = find_prev_quote(line, col_start, quotechar, NULL);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
  	/* The cursor is on a quote, we don't know if it's the opening or
Karsten Hopp 7b3c19
  	 * closing quote.  Search from the start of the line to find out.
Karsten Hopp 7b3c19
  	 * Also do this when there is a Visual area, a' may leave the cursor
Karsten Hopp 7b3c19
--- 4308,4314 ----
Karsten Hopp 7b3c19
  	    else
Karsten Hopp 7b3c19
  		first_col = find_prev_quote(line, col_start, quotechar, NULL);
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
! 
Karsten Hopp 7b3c19
  	/* The cursor is on a quote, we don't know if it's the opening or
Karsten Hopp 7b3c19
  	 * closing quote.  Search from the start of the line to find out.
Karsten Hopp 7b3c19
  	 * Also do this when there is a Visual area, a' may leave the cursor
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4406,4419 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Set start position.  After vi" another i" must include the ".
Karsten Hopp 7b3c19
       * For v2i" include the quotes. */
Karsten Hopp 7b3c19
!     if (!include && count < 2
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 	    && (vis_empty || !inside_quotes)
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	    )
Karsten Hopp 7b3c19
  	++col_start;
Karsten Hopp 7b3c19
      curwin->w_cursor.col = col_start;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Set the start of the Visual area when the Visual area was empty, we
Karsten Hopp 7b3c19
--- 4365,4373 ----
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Set start position.  After vi" another i" must include the ".
Karsten Hopp 7b3c19
       * For v2i" include the quotes. */
Karsten Hopp 7b3c19
!     if (!include && count < 2 && (vis_empty || !inside_quotes))
Karsten Hopp 7b3c19
  	++col_start;
Karsten Hopp 7b3c19
      curwin->w_cursor.col = col_start;
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Set the start of the Visual area when the Visual area was empty, we
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4433,4439 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	oap->start = curwin->w_cursor;
Karsten Hopp 7b3c19
  	oap->motion_type = MCHAR;
Karsten Hopp 7b3c19
--- 4387,4392 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4441,4454 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Set end position. */
Karsten Hopp 7b3c19
      curwin->w_cursor.col = col_end;
Karsten Hopp 7b3c19
!     if ((include || count > 1
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
! 		/* After vi" another i" must include the ". */
Karsten Hopp 7b3c19
  		|| (!vis_empty && inside_quotes)
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  	) && inc_cursor() == 2)
Karsten Hopp 7b3c19
  	inclusive = TRUE;
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (vis_empty || vis_bef_curs)
Karsten Hopp 7b3c19
--- 4394,4403 ----
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Set end position. */
Karsten Hopp 7b3c19
      curwin->w_cursor.col = col_end;
Karsten Hopp 7b3c19
!     if ((include || count > 1 /* After vi" another i" must include the ". */
Karsten Hopp 7b3c19
  		|| (!vis_empty && inside_quotes)
Karsten Hopp 7b3c19
  	) && inc_cursor() == 2)
Karsten Hopp 7b3c19
  	inclusive = TRUE;
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	if (vis_empty || vis_bef_curs)
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4480,4486 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
      else
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Set inclusive and other oap's flags. */
Karsten Hopp 7b3c19
  	oap->inclusive = inclusive;
Karsten Hopp 7b3c19
--- 4429,4434 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4491,4497 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #endif /* FEAT_TEXTOBJ */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #if defined(FEAT_VISUAL) || defined(PROTO)
Karsten Hopp 7b3c19
  static int is_one_char __ARGS((char_u *pattern));
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 4439,4444 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4690,4696 ****
Karsten Hopp 7b3c19
      vim_regfree(regmatch.regprog);
Karsten Hopp 7b3c19
      return result;
Karsten Hopp 7b3c19
  }
Karsten Hopp 7b3c19
- #endif /* FEAT_VISUAL */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_LISP) || defined(FEAT_CINDENT) || defined(FEAT_TEXTOBJ) \
Karsten Hopp 7b3c19
  	|| defined(PROTO)
Karsten Hopp 7b3c19
--- 4637,4642 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/spell.c	2014-03-08 16:13:39.123462070 +0100
Karsten Hopp 7b3c19
--- src/spell.c	2014-03-23 13:35:15.195174931 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 10191,10197 ****
Karsten Hopp 7b3c19
      if (no_spell_checking(curwin))
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* Use the Visually selected text as the bad word.  But reject
Karsten Hopp 7b3c19
--- 10191,10196 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 10209,10218 ****
Karsten Hopp 7b3c19
  	++badlen;
Karsten Hopp 7b3c19
  	end_visual_mode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! 	/* Find the start of the badly spelled word. */
Karsten Hopp 7b3c19
! 	if (spell_move_to(curwin, FORWARD, TRUE, TRUE, NULL) == 0
Karsten Hopp 7b3c19
  	    || curwin->w_cursor.col > prev_cursor.col)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* No bad word or it starts after the cursor: use the word under the
Karsten Hopp 7b3c19
--- 10208,10215 ----
Karsten Hopp 7b3c19
  	++badlen;
Karsten Hopp 7b3c19
  	end_visual_mode();
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
!     /* Find the start of the badly spelled word. */
Karsten Hopp 7b3c19
!     else if (spell_move_to(curwin, FORWARD, TRUE, TRUE, NULL) == 0
Karsten Hopp 7b3c19
  	    || curwin->w_cursor.col > prev_cursor.col)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	/* No bad word or it starts after the cursor: use the word under the
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/syntax.c	2013-11-28 18:53:47.000000000 +0100
Karsten Hopp 7b3c19
--- src/syntax.c	2014-03-23 13:35:30.379175164 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6837,6846 ****
Karsten Hopp 7b3c19
  	CENT("SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue",
Karsten Hopp 7b3c19
  	     "SignColumn term=standout ctermbg=Grey ctermfg=DarkBlue guibg=Grey guifg=DarkBlue"),
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	CENT("Visual term=reverse",
Karsten Hopp 7b3c19
  	     "Visual term=reverse guibg=LightGrey"),
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_DIFF
Karsten Hopp 7b3c19
  	CENT("DiffAdd term=bold ctermbg=LightBlue",
Karsten Hopp 7b3c19
  	     "DiffAdd term=bold ctermbg=LightBlue guibg=LightBlue"),
Karsten Hopp 7b3c19
--- 6837,6844 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6927,6936 ****
Karsten Hopp 7b3c19
  	CENT("SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan",
Karsten Hopp 7b3c19
  	     "SignColumn term=standout ctermbg=DarkGrey ctermfg=Cyan guibg=Grey guifg=Cyan"),
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	CENT("Visual term=reverse",
Karsten Hopp 7b3c19
  	     "Visual term=reverse guibg=DarkGrey"),
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_DIFF
Karsten Hopp 7b3c19
  	CENT("DiffAdd term=bold ctermbg=DarkBlue",
Karsten Hopp 7b3c19
  	     "DiffAdd term=bold ctermbg=DarkBlue guibg=DarkBlue"),
Karsten Hopp 7b3c19
--- 6925,6932 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/term.c	2014-03-19 14:01:53.153903819 +0100
Karsten Hopp 7b3c19
--- src/term.c	2014-03-23 13:35:43.519175365 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3456,3467 ****
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #  ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_VISUAL;
Karsten Hopp 7b3c19
!     else
Karsten Hopp 7b3c19
! #  endif
Karsten Hopp 7b3c19
! 	if (State == HITRETURN || State == ASKMORE || State == SETWSIZE)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_RETURN;
Karsten Hopp 7b3c19
      else if (State & INSERT)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_INSERT;
Karsten Hopp 7b3c19
--- 3456,3464 ----
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_VISUAL;
Karsten Hopp 7b3c19
!     else if (State == HITRETURN || State == ASKMORE || State == SETWSIZE)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_RETURN;
Karsten Hopp 7b3c19
      else if (State & INSERT)
Karsten Hopp 7b3c19
  	checkfor = MOUSE_INSERT;
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/ui.c	2013-07-13 20:57:08.000000000 +0200
Karsten Hopp 7b3c19
--- src/ui.c	2014-03-23 13:36:15.459175855 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2610,2622 ****
Karsten Hopp 7b3c19
  	if (on_sep_line)
Karsten Hopp 7b3c19
  	    return IN_SEP_LINE;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	if (flags & MOUSE_MAY_STOP_VIS)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    end_visual_mode();
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);	/* delete the inversion */
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #if defined(FEAT_CMDWIN) && defined(FEAT_CLIPBOARD)
Karsten Hopp 7b3c19
  	/* Continue a modeless selection in another window. */
Karsten Hopp 7b3c19
  	if (cmdwin_type != 0 && row < W_WINROW(curwin))
Karsten Hopp 7b3c19
--- 2610,2620 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2686,2717 ****
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* Before jumping to another buffer, or moving the cursor for a left
Karsten Hopp 7b3c19
  	 * click, stop Visual mode. */
Karsten Hopp 7b3c19
  	if (VIsual_active
Karsten Hopp 7b3c19
  		&& (wp->w_buffer != curwin->w_buffer
Karsten Hopp 7b3c19
  		    || (!on_status_line
Karsten Hopp 7b3c19
! # ifdef FEAT_VERTSPLIT
Karsten Hopp 7b3c19
  			&& !on_sep_line
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
! # ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  			&& (
Karsten Hopp 7b3c19
! #  ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  			    wp->w_p_rl ? col < W_WIDTH(wp) - wp->w_p_fdc :
Karsten Hopp 7b3c19
! #  endif
Karsten Hopp 7b3c19
  			    col >= wp->w_p_fdc
Karsten Hopp 7b3c19
! #  ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  				  + (cmdwin_type == 0 && wp == curwin ? 0 : 1)
Karsten Hopp 7b3c19
- #  endif
Karsten Hopp 7b3c19
- 			    )
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
  			&& (flags & MOUSE_MAY_STOP_VIS))))
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    end_visual_mode();
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);	/* delete the inversion */
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  	if (cmdwin_type != 0 && wp != curwin)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
--- 2684,2713 ----
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* Before jumping to another buffer, or moving the cursor for a left
Karsten Hopp 7b3c19
  	 * click, stop Visual mode. */
Karsten Hopp 7b3c19
  	if (VIsual_active
Karsten Hopp 7b3c19
  		&& (wp->w_buffer != curwin->w_buffer
Karsten Hopp 7b3c19
  		    || (!on_status_line
Karsten Hopp 7b3c19
! #ifdef FEAT_VERTSPLIT
Karsten Hopp 7b3c19
  			&& !on_sep_line
Karsten Hopp 7b3c19
! #endif
Karsten Hopp 7b3c19
! #ifdef FEAT_FOLDING
Karsten Hopp 7b3c19
  			&& (
Karsten Hopp 7b3c19
! # ifdef FEAT_RIGHTLEFT
Karsten Hopp 7b3c19
  			    wp->w_p_rl ? col < W_WIDTH(wp) - wp->w_p_fdc :
Karsten Hopp 7b3c19
! # endif
Karsten Hopp 7b3c19
  			    col >= wp->w_p_fdc
Karsten Hopp 7b3c19
! # ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  				  + (cmdwin_type == 0 && wp == curwin ? 0 : 1)
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
+ 			    )
Karsten Hopp 7b3c19
+ #endif
Karsten Hopp 7b3c19
  			&& (flags & MOUSE_MAY_STOP_VIS))))
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    end_visual_mode();
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);	/* delete the inversion */
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  	if (cmdwin_type != 0 && wp != curwin)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2801,2814 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      else /* keep_window_focus must be TRUE */
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	/* before moving the cursor for a left click, stop Visual mode */
Karsten Hopp 7b3c19
  	if (flags & MOUSE_MAY_STOP_VIS)
Karsten Hopp 7b3c19
  	{
Karsten Hopp 7b3c19
  	    end_visual_mode();
Karsten Hopp 7b3c19
  	    redraw_curbuf_later(INVERTED);	/* delete the inversion */
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #if defined(FEAT_CMDWIN) && defined(FEAT_CLIPBOARD)
Karsten Hopp 7b3c19
  	/* Continue a modeless selection in another window. */
Karsten Hopp 7b3c19
--- 2797,2808 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2933,2939 ****
Karsten Hopp 7b3c19
      if (mouse_comp_pos(curwin, &row, &col, &curwin->w_cursor.lnum))
Karsten Hopp 7b3c19
  	mouse_past_bottom = TRUE;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* Start Visual mode before coladvance(), for when 'sel' != "old" */
Karsten Hopp 7b3c19
      if ((flags & MOUSE_MAY_VIS) && !VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 2927,2932 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2947,2953 ****
Karsten Hopp 7b3c19
  	if (p_smd && msg_silent == 0)
Karsten Hopp 7b3c19
  	    redraw_cmdline = TRUE;	/* show visual mode later */
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      curwin->w_curswant = col;
Karsten Hopp 7b3c19
      curwin->w_set_curswant = FALSE;	/* May still have been TRUE */
Karsten Hopp 7b3c19
--- 2940,2945 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/undo.c	2014-03-12 16:51:35.060792541 +0100
Karsten Hopp 7b3c19
--- src/undo.c	2014-03-23 13:37:05.435176620 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 532,540 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	/* save named marks and Visual marks for undo */
Karsten Hopp 7b3c19
  	mch_memmove(uhp->uh_namedm, curbuf->b_namedm, sizeof(pos_T) * NMARKS);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	uhp->uh_visual = curbuf->b_visual;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  	curbuf->b_u_newhead = uhp;
Karsten Hopp 7b3c19
  	if (curbuf->b_u_oldhead == NULL)
Karsten Hopp 7b3c19
--- 532,538 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1014,1029 ****
Karsten Hopp 7b3c19
      /* Assume NMARKS will stay the same. */
Karsten Hopp 7b3c19
      for (i = 0; i < NMARKS; ++i)
Karsten Hopp 7b3c19
  	serialize_pos(uhp->uh_namedm[i], fp);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      serialize_visualinfo(&uhp->uh_visual, fp);
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
-     {
Karsten Hopp 7b3c19
- 	visualinfo_T info;
Karsten Hopp 7b3c19
- 
Karsten Hopp 7b3c19
- 	memset(&info, 0, sizeof(visualinfo_T));
Karsten Hopp 7b3c19
- 	serialize_visualinfo(&info, fp);
Karsten Hopp 7b3c19
-     }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      put_time(fp, uhp->uh_time);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Optional fields. */
Karsten Hopp 7b3c19
--- 1012,1018 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1082,1095 ****
Karsten Hopp 7b3c19
      uhp->uh_flags = get2c(fp);
Karsten Hopp 7b3c19
      for (i = 0; i < NMARKS; ++i)
Karsten Hopp 7b3c19
  	unserialize_pos(&uhp->uh_namedm[i], fp);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      unserialize_visualinfo(&uhp->uh_visual, fp);
Karsten Hopp 7b3c19
- #else
Karsten Hopp 7b3c19
-     {
Karsten Hopp 7b3c19
- 	visualinfo_T info;
Karsten Hopp 7b3c19
- 	unserialize_visualinfo(&info, fp);
Karsten Hopp 7b3c19
-     }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      uhp->uh_time = get8ctime(fp);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* Optional fields. */
Karsten Hopp 7b3c19
--- 1071,1077 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2406,2414 ****
Karsten Hopp 7b3c19
      int		old_flags;
Karsten Hopp 7b3c19
      int		new_flags;
Karsten Hopp 7b3c19
      pos_T	namedm[NMARKS];
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      visualinfo_T visualinfo;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      int		empty_buffer;		    /* buffer became empty */
Karsten Hopp 7b3c19
      u_header_T	*curhead = curbuf->b_u_curhead;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 2388,2394 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2430,2438 ****
Karsten Hopp 7b3c19
       * save marks before undo/redo
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
      mch_memmove(namedm, curbuf->b_namedm, sizeof(pos_T) * NMARKS);
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      visualinfo = curbuf->b_visual;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      curbuf->b_op_start.lnum = curbuf->b_ml.ml_line_count;
Karsten Hopp 7b3c19
      curbuf->b_op_start.col = 0;
Karsten Hopp 7b3c19
      curbuf->b_op_end.lnum = 0;
Karsten Hopp 7b3c19
--- 2410,2416 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2602,2614 ****
Karsten Hopp 7b3c19
  	    curbuf->b_namedm[i] = curhead->uh_namedm[i];
Karsten Hopp 7b3c19
  	    curhead->uh_namedm[i] = namedm[i];
Karsten Hopp 7b3c19
  	}
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (curhead->uh_visual.vi_start.lnum != 0)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	curbuf->b_visual = curhead->uh_visual;
Karsten Hopp 7b3c19
  	curhead->uh_visual = visualinfo;
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * If the cursor is only off by one line, put it at the same position as
Karsten Hopp 7b3c19
--- 2580,2590 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/version.c	2014-03-22 13:29:57.693846167 +0100
Karsten Hopp 7b3c19
--- src/version.c	2014-03-23 15:01:49.719254526 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 642,656 ****
Karsten Hopp 7b3c19
  #else
Karsten Hopp 7b3c19
  	"-virtualedit",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  	"+visual",
Karsten Hopp 7b3c19
! # ifdef FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  	"+visualextra",
Karsten Hopp 7b3c19
- # else
Karsten Hopp 7b3c19
- 	"-visualextra",
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  #else
Karsten Hopp 7b3c19
! 	"-visual",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VIMINFO
Karsten Hopp 7b3c19
  	"+viminfo",
Karsten Hopp 7b3c19
--- 642,652 ----
Karsten Hopp 7b3c19
  #else
Karsten Hopp 7b3c19
  	"-virtualedit",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  	"+visual",
Karsten Hopp 7b3c19
! #ifdef FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  	"+visualextra",
Karsten Hopp 7b3c19
  #else
Karsten Hopp 7b3c19
! 	"-visualextra",
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_VIMINFO
Karsten Hopp 7b3c19
  	"+viminfo",
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/window.c	2014-01-10 15:53:09.000000000 +0100
Karsten Hopp 7b3c19
--- src/window.c	2014-03-23 13:38:17.767177729 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 130,138 ****
Karsten Hopp 7b3c19
      case Ctrl_S:
Karsten Hopp 7b3c19
      case 's':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_QUICKFIX
Karsten Hopp 7b3c19
  		/* When splitting the quickfix window open a new buffer in it,
Karsten Hopp 7b3c19
  		 * don't replicate the quickfix buffer. */
Karsten Hopp 7b3c19
--- 130,136 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 150,158 ****
Karsten Hopp 7b3c19
      case Ctrl_V:
Karsten Hopp 7b3c19
      case 'v':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  # ifdef FEAT_QUICKFIX
Karsten Hopp 7b3c19
  		/* When splitting the quickfix window open a new buffer in it,
Karsten Hopp 7b3c19
  		 * don't replicate the quickfix buffer. */
Karsten Hopp 7b3c19
--- 148,154 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 170,178 ****
Karsten Hopp 7b3c19
      case Ctrl_HAT:
Karsten Hopp 7b3c19
      case '^':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		STRCPY(cbuf, "split #");
Karsten Hopp 7b3c19
  		if (Prenum)
Karsten Hopp 7b3c19
  		    vim_snprintf((char *)cbuf + 7, sizeof(cbuf) - 7,
Karsten Hopp 7b3c19
--- 166,172 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 184,192 ****
Karsten Hopp 7b3c19
      case Ctrl_N:
Karsten Hopp 7b3c19
      case 'n':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_QUICKFIX
Karsten Hopp 7b3c19
  newwindow:
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 178,184 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 206,223 ****
Karsten Hopp 7b3c19
  /* quit current window */
Karsten Hopp 7b3c19
      case Ctrl_Q:
Karsten Hopp 7b3c19
      case 'q':
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		do_cmdline_cmd((char_u *)"quit");
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /* close current window */
Karsten Hopp 7b3c19
      case Ctrl_C:
Karsten Hopp 7b3c19
      case 'c':
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		do_cmdline_cmd((char_u *)"close");
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 198,211 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 226,234 ****
Karsten Hopp 7b3c19
      case Ctrl_Z:
Karsten Hopp 7b3c19
      case 'z':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		do_cmdline_cmd((char_u *)"pclose");
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 214,220 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 248,256 ****
Karsten Hopp 7b3c19
      case Ctrl_O:
Karsten Hopp 7b3c19
      case 'o':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		do_cmdline_cmd((char_u *)"only");
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 234,240 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 399,416 ****
Karsten Hopp 7b3c19
      case Ctrl_R:
Karsten Hopp 7b3c19
      case 'r':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		win_rotate(FALSE, (int)Prenum1);    /* downwards */
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  /* rotate windows upwards */
Karsten Hopp 7b3c19
      case 'R':
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		win_rotate(TRUE, (int)Prenum1);	    /* upwards */
Karsten Hopp 7b3c19
  		break;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 383,396 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 499,507 ****
Karsten Hopp 7b3c19
      case ']':
Karsten Hopp 7b3c19
      case Ctrl_RSB:
Karsten Hopp 7b3c19
  		CHECK_CMDWIN
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  		reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  		if (Prenum)
Karsten Hopp 7b3c19
  		    postponed_split = Prenum;
Karsten Hopp 7b3c19
  		else
Karsten Hopp 7b3c19
--- 479,485 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 612,620 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  		    case ']':
Karsten Hopp 7b3c19
  		    case Ctrl_RSB:
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  			reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  			if (Prenum)
Karsten Hopp 7b3c19
  			    postponed_split = Prenum;
Karsten Hopp 7b3c19
  			else
Karsten Hopp 7b3c19
--- 590,596 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 3726,3734 ****
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
      tabpage_T	*tp = curtab;
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      reset_VIsual_and_resel();	/* stop Visual mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_AUTOCMD
Karsten Hopp 7b3c19
      if (trigger_leave_autocmds)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
--- 3702,3708 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 4029,4040 ****
Karsten Hopp 7b3c19
  	return;
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (wp->w_buffer != curbuf)
Karsten Hopp 7b3c19
  	reset_VIsual_and_resel();
Karsten Hopp 7b3c19
      else if (VIsual_active)
Karsten Hopp 7b3c19
  	wp->w_cursor = curwin->w_cursor;
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_GUI
Karsten Hopp 7b3c19
      need_mouse_correct = TRUE;
Karsten Hopp 7b3c19
--- 4003,4012 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6037,6043 ****
Karsten Hopp 7b3c19
      long	count;
Karsten Hopp 7b3c19
      linenr_T	*file_lnum;
Karsten Hopp 7b3c19
  {
Karsten Hopp 7b3c19
- # ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      if (VIsual_active)
Karsten Hopp 7b3c19
      {
Karsten Hopp 7b3c19
  	int	len;
Karsten Hopp 7b3c19
--- 6009,6014 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 6048,6054 ****
Karsten Hopp 7b3c19
  	return find_file_name_in_path(ptr, len,
Karsten Hopp 7b3c19
  		     FNAME_MESS|FNAME_EXP|FNAME_REL, count, curbuf->b_ffname);
Karsten Hopp 7b3c19
      }
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
      return file_name_at_cursor(FNAME_MESS|FNAME_HYP|FNAME_EXP|FNAME_REL, count,
Karsten Hopp 7b3c19
  			       file_lnum);
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
--- 6019,6024 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/feature.h	2014-03-12 17:56:42.960852421 +0100
Karsten Hopp 7b3c19
--- src/feature.h	2014-03-23 13:39:02.003178407 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 214,220 ****
Karsten Hopp 7b3c19
   * +visual		Visual mode - now always included.
Karsten Hopp 7b3c19
   * +visualextra		Extra features for Visual mode (mostly block operators).
Karsten Hopp 7b3c19
   */
Karsten Hopp 7b3c19
- #define FEAT_VISUAL
Karsten Hopp 7b3c19
  #ifdef FEAT_NORMAL
Karsten Hopp 7b3c19
  # define FEAT_VISUALEXTRA
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 214,219 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1138,1150 ****
Karsten Hopp 7b3c19
  #ifdef FEAT_GUI
Karsten Hopp 7b3c19
  # ifndef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  #  define FEAT_CLIPBOARD
Karsten Hopp 7b3c19
- #  ifndef FEAT_VISUAL
Karsten Hopp 7b3c19
- #   define FEAT_VISUAL
Karsten Hopp 7b3c19
- #  endif
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #if defined(FEAT_NORMAL) && defined(FEAT_VISUAL) \
Karsten Hopp 7b3c19
  	&& (defined(UNIX) || defined(VMS)) \
Karsten Hopp 7b3c19
  	&& defined(WANT_X11) && defined(HAVE_X11)
Karsten Hopp 7b3c19
  # define FEAT_XCLIPBOARD
Karsten Hopp 7b3c19
--- 1137,1146 ----
Karsten Hopp 7b3c19
  #ifdef FEAT_GUI
Karsten Hopp 7b3c19
  # ifndef FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  #  define FEAT_CLIPBOARD
Karsten Hopp 7b3c19
  # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
! #if defined(FEAT_NORMAL) \
Karsten Hopp 7b3c19
  	&& (defined(UNIX) || defined(VMS)) \
Karsten Hopp 7b3c19
  	&& defined(WANT_X11) && defined(HAVE_X11)
Karsten Hopp 7b3c19
  # define FEAT_XCLIPBOARD
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/globals.h	2014-02-22 23:03:48.712901208 +0100
Karsten Hopp 7b3c19
--- src/globals.h	2014-03-23 13:39:17.407178643 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 662,668 ****
Karsten Hopp 7b3c19
  				/* set to TRUE when "-s" commandline argument
Karsten Hopp 7b3c19
  				 * used for ex */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  EXTERN pos_T	VIsual;		/* start position of active Visual selection */
Karsten Hopp 7b3c19
  EXTERN int	VIsual_active INIT(= FALSE);
Karsten Hopp 7b3c19
  				/* whether Visual mode is active */
Karsten Hopp 7b3c19
--- 662,667 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 677,683 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  EXTERN int	redo_VIsual_busy INIT(= FALSE);
Karsten Hopp 7b3c19
  				/* TRUE when redoing Visual */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_MOUSE
Karsten Hopp 7b3c19
  /*
Karsten Hopp 7b3c19
--- 676,681 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1178,1188 ****
Karsten Hopp 7b3c19
  EXTERN int	fill_diff INIT(= '-');
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  /* Whether 'keymodel' contains "stopsel" and "startsel". */
Karsten Hopp 7b3c19
  EXTERN int	km_stopsel INIT(= FALSE);
Karsten Hopp 7b3c19
  EXTERN int	km_startsel INIT(= FALSE);
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #ifdef FEAT_CMDWIN
Karsten Hopp 7b3c19
  EXTERN int	cedit_key INIT(= -1);	/* key value of 'cedit' option */
Karsten Hopp 7b3c19
--- 1176,1184 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/option.h	2014-03-12 18:55:52.104906804 +0100
Karsten Hopp 7b3c19
--- src/option.h	2014-03-23 13:39:30.991178851 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 572,580 ****
Karsten Hopp 7b3c19
  EXTERN char_u	*p_isp;		/* 'isprint' */
Karsten Hopp 7b3c19
  EXTERN int	p_js;		/* 'joinspaces' */
Karsten Hopp 7b3c19
  EXTERN char_u	*p_kp;		/* 'keywordprg' */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  EXTERN char_u	*p_km;		/* 'keymodel' */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_LANGMAP
Karsten Hopp 7b3c19
  EXTERN char_u	*p_langmap;	/* 'langmap'*/
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
--- 572,578 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 681,690 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  EXTERN char_u	*p_sections;	/* 'sections' */
Karsten Hopp 7b3c19
  EXTERN int	p_secure;	/* 'secure' */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
  EXTERN char_u	*p_sel;		/* 'selection' */
Karsten Hopp 7b3c19
  EXTERN char_u	*p_slm;		/* 'selectmode' */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  #ifdef FEAT_SESSION
Karsten Hopp 7b3c19
  EXTERN char_u	*p_ssop;	/* 'sessionoptions' */
Karsten Hopp 7b3c19
  EXTERN unsigned	ssop_flags;
Karsten Hopp 7b3c19
--- 679,686 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/os_win32.h	2013-09-25 19:13:32.000000000 +0200
Karsten Hopp 7b3c19
--- src/os_win32.h	2014-03-23 13:39:49.819179139 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 68,74 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #define USE_FNAME_CASE		/* adjust case of file names */
Karsten Hopp 7b3c19
! #if !defined(FEAT_CLIPBOARD) && defined(FEAT_VISUAL) && defined(FEAT_MOUSE)
Karsten Hopp 7b3c19
  # define FEAT_CLIPBOARD		/* include clipboard support */
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  #if defined(__DATE__) && defined(__TIME__)
Karsten Hopp 7b3c19
--- 68,74 ----
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
  #define USE_FNAME_CASE		/* adjust case of file names */
Karsten Hopp 7b3c19
! #if !defined(FEAT_CLIPBOARD) && defined(FEAT_MOUSE)
Karsten Hopp 7b3c19
  # define FEAT_CLIPBOARD		/* include clipboard support */
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  #if defined(__DATE__) && defined(__TIME__)
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/structs.h	2014-03-12 18:55:52.104906804 +0100
Karsten Hopp 7b3c19
--- src/structs.h	2014-03-23 13:40:19.175179589 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 346,354 ****
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
      int		uh_flags;	/* see below */
Karsten Hopp 7b3c19
      pos_T	uh_namedm[NMARKS];	/* marks before undo/after redo */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      visualinfo_T uh_visual;	/* Visual areas before undo/after redo */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      time_t	uh_time;	/* timestamp when the change was made */
Karsten Hopp 7b3c19
      long	uh_save_nr;	/* set when the file was saved after the
Karsten Hopp 7b3c19
  				   changes in this block */
Karsten Hopp 7b3c19
--- 346,352 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1406,1417 ****
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      pos_T	b_namedm[NMARKS]; /* current named marks (mark.c) */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /* These variables are set when VIsual_active becomes FALSE */
Karsten Hopp 7b3c19
      visualinfo_T b_visual;
Karsten Hopp 7b3c19
! # ifdef FEAT_EVAL
Karsten Hopp 7b3c19
      int		b_visual_mode_eval;  /* b_visual.vi_mode for visualmode() */
Karsten Hopp 7b3c19
- # endif
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      pos_T	b_last_cursor;	/* cursor position when last unloading this
Karsten Hopp 7b3c19
--- 1404,1413 ----
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      pos_T	b_namedm[NMARKS]; /* current named marks (mark.c) */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /* These variables are set when VIsual_active becomes FALSE */
Karsten Hopp 7b3c19
      visualinfo_T b_visual;
Karsten Hopp 7b3c19
! #ifdef FEAT_EVAL
Karsten Hopp 7b3c19
      int		b_visual_mode_eval;  /* b_visual.vi_mode for visualmode() */
Karsten Hopp 7b3c19
  #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      pos_T	b_last_cursor;	/* cursor position when last unloading this
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1980,1986 ****
Karsten Hopp 7b3c19
  				       time through cursupdate() to the
Karsten Hopp 7b3c19
  				       current virtual column */
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * the next six are used to update the visual part
Karsten Hopp 7b3c19
       */
Karsten Hopp 7b3c19
--- 1976,1981 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 1991,1997 ****
Karsten Hopp 7b3c19
      linenr_T	w_old_visual_lnum;  /* last known start of visual part */
Karsten Hopp 7b3c19
      colnr_T	w_old_visual_col;   /* last known start of visual part */
Karsten Hopp 7b3c19
      colnr_T	w_old_curswant;	    /* last known value of Curswant */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
  
Karsten Hopp 7b3c19
      /*
Karsten Hopp 7b3c19
       * "w_topline", "w_leftcol" and "w_skipcol" specify the offsets for
Karsten Hopp 7b3c19
--- 1986,1991 ----
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 2293,2302 ****
Karsten Hopp 7b3c19
  				   (inclusive) */
Karsten Hopp 7b3c19
      int		empty;		/* op_start and op_end the same (only used by
Karsten Hopp 7b3c19
  				   do_change()) */
Karsten Hopp 7b3c19
- #ifdef FEAT_VISUAL
Karsten Hopp 7b3c19
      int		is_VIsual;	/* operator on Visual area */
Karsten Hopp 7b3c19
      int		block_mode;	/* current operator is Visual block mode */
Karsten Hopp 7b3c19
- #endif
Karsten Hopp 7b3c19
      colnr_T	start_vcol;	/* start col for block mode operator */
Karsten Hopp 7b3c19
      colnr_T	end_vcol;	/* end col for block mode operator */
Karsten Hopp 7b3c19
  #ifdef FEAT_AUTOCMD
Karsten Hopp 7b3c19
--- 2287,2294 ----
Karsten Hopp 7b3c19
*** ../vim-7.4.211/src/version.c	2014-03-22 13:29:57.693846167 +0100
Karsten Hopp 7b3c19
--- src/version.c	2014-03-23 15:01:49.719254526 +0100
Karsten Hopp 7b3c19
***************
Karsten Hopp 7b3c19
*** 740,741 ****
Karsten Hopp 7b3c19
--- 736,739 ----
Karsten Hopp 7b3c19
  {   /* Add new patch number below this line */
Karsten Hopp 7b3c19
+ /**/
Karsten Hopp 7b3c19
+     212,
Karsten Hopp 7b3c19
  /**/
Karsten Hopp 7b3c19
Karsten Hopp 7b3c19
-- 
Karsten Hopp 7b3c19
If all you have is a hammer, everything looks like a nail.
Karsten Hopp 7b3c19
When your hammer is C++, everything begins to look like a thumb.
Karsten Hopp 7b3c19
			-- Steve Hoflich, comp.lang.c++
Karsten Hopp 7b3c19
Karsten Hopp 7b3c19
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 7b3c19
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 7b3c19
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 7b3c19
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///