Index: tches/vim-7.0-fixes-10.patch
===================================================================
--- patches/vim-7.0-fixes-10.patch	(revision 01d2e8d9784534b56d86b7d5bf053758bb8afb85)
+++ 	(revision )
@@ -1,2302 +1,0 @@
-Submitted By: Jim Gifford (jim at linuxfromscratch dot org)
-Date: 2006-08-27
-Initial Package Version: 7.0
-Origin: Upstream
-Upstream Status: Applied
-Description: Contains Patch 001-004, 006-026, 028-031, 033-044, 036-056,
-        058-064, and 066 from Upstream
-        005, 027, 032, 045, 057, and 066 is for the extras, Mac, or
-        Windows 32 only
-
-diff -Naur vim70.orig/configure vim70/configure
---- vim70.orig/configure	2004-07-05 02:02:24.000000000 -0700
-+++ vim70/configure	2006-08-09 08:37:06.000000000 -0700
-@@ -3,4 +3,4 @@
- # This is just a stub for the Unix configure script, to provide support for
- # doing "./configure" in the top Vim directory.
- 
--cd src && ./configure "$@"
-+cd src && exec ./configure "$@"
-diff -Naur vim70.orig/runtime/autoload/ccomplete.vim vim70/runtime/autoload/ccomplete.vim
---- vim70.orig/runtime/autoload/ccomplete.vim	2006-05-03 07:35:56.000000000 -0700
-+++ vim70/runtime/autoload/ccomplete.vim	2006-07-14 08:51:21.000000000 -0700
-@@ -1,7 +1,7 @@
- " Vim completion script
- " Language:	C
- " Maintainer:	Bram Moolenaar <Bram@vim.org>
--" Last Change:	2006 May 03
-+" Last Change:	2006 May 08
- 
- 
- " This function is used for the 'omnifunc' option.
-@@ -458,7 +458,7 @@
- " member.
- function! s:StructMembers(typename, items, all)
-   " Todo: What about local structures?
--  let fnames = join(map(tagfiles(), 'escape(v:val, " \\")'))
-+  let fnames = join(map(tagfiles(), 'escape(v:val, " \\#%")'))
-   if fnames == ''
-     return []
-   endif
-diff -Naur vim70.orig/runtime/autoload/gzip.vim vim70/runtime/autoload/gzip.vim
---- vim70.orig/runtime/autoload/gzip.vim	2006-03-31 07:12:15.000000000 -0800
-+++ vim70/runtime/autoload/gzip.vim	2006-08-09 08:37:36.000000000 -0700
-@@ -1,6 +1,6 @@
- " Vim autoload file for editing compressed files.
- " Maintainer: Bram Moolenaar <Bram@vim.org>
--" Last Change: 2006 Mar 31
-+" Last Change: 2006 Jul 19
- 
- " These functions are used by the gzip plugin.
- 
-@@ -127,9 +127,9 @@
-     let nmt = s:tempname(nm)
-     if rename(nm, nmt) == 0
-       if exists("b:gzip_comp_arg")
--	call system(a:cmd . " " . b:gzip_comp_arg . " " . nmt)
-+	call system(a:cmd . " " . b:gzip_comp_arg . " '" . nmt . "'")
-       else
--	call system(a:cmd . " " . nmt)
-+	call system(a:cmd . " '" . nmt . "'")
-       endif
-       call rename(nmt . "." . expand("<afile>:e"), nm)
-     endif
-diff -Naur vim70.orig/runtime/autoload/paste.vim vim70/runtime/autoload/paste.vim
---- vim70.orig/runtime/autoload/paste.vim	2006-04-21 11:31:01.000000000 -0700
-+++ vim70/runtime/autoload/paste.vim	2006-07-14 08:51:21.000000000 -0700
-@@ -1,6 +1,6 @@
- " Vim support file to help with paste mappings and menus
- " Maintainer:	Bram Moolenaar <Bram@vim.org>
--" Last Change:	2006 Apr 21
-+" Last Change:	2006 Jun 23
- 
- " Define the string to use for items that are present both in Edit, Popup and
- " Toolbar menu.  Also used in mswin.vim and macmap.vim.
-@@ -12,7 +12,7 @@
- if has("virtualedit")
-   let paste#paste_cmd = {'n': ":call paste#Paste()<CR>"}
-   let paste#paste_cmd['v'] = '"-c<Esc>' . paste#paste_cmd['n']
--  let paste#paste_cmd['i'] = '<Esc>' . paste#paste_cmd['n'] . 'gi'
-+  let paste#paste_cmd['i'] = 'x<BS><Esc>' . paste#paste_cmd['n'] . 'gi'
- 
-   func! paste#Paste()
-     let ove = &ve
-diff -Naur vim70.orig/runtime/autoload/spellfile.vim vim70/runtime/autoload/spellfile.vim
---- vim70.orig/runtime/autoload/spellfile.vim	2006-02-01 04:12:24.000000000 -0800
-+++ vim70/runtime/autoload/spellfile.vim	2006-07-14 08:51:21.000000000 -0700
-@@ -1,9 +1,9 @@
- " Vim script to download a missing spell file
- " Maintainer:	Bram Moolenaar <Bram@vim.org>
--" Last Change:	2006 Feb 01
-+" Last Change:	2006 May 10
- 
- if !exists('g:spellfile_URL')
--  let g:spellfile_URL = 'ftp://ftp.vim.org/pub/vim/unstable/runtime/spell'
-+  let g:spellfile_URL = 'ftp://ftp.vim.org/pub/vim/runtime/spell'
- endif
- let s:spellfile_URL = ''    " Start with nothing so that s:donedict is reset.
- 
-@@ -61,13 +61,13 @@
-     new
-     setlocal bin
-     echo 'Downloading ' . fname . '...'
--    exe 'Nread ' g:spellfile_URL . '/' . fname
-+    call spellfile#Nread(fname)
-     if getline(2) !~ 'VIMspell'
-       " Didn't work, perhaps there is an ASCII one.
-       g/^/d
-       let fname = a:lang . '.ascii.spl'
-       echo 'Could not find it, trying ' . fname . '...'
--      exe 'Nread ' g:spellfile_URL . '/' . fname
-+      call spellfile#Nread(fname)
-       if getline(2) !~ 'VIMspell'
- 	echo 'Sorry, downloading failed'
- 	bwipe!
-@@ -95,7 +95,7 @@
- 	g/^/d
- 	let fname = substitute(fname, '\.spl$', '.sug', '')
- 	echo 'Downloading ' . fname . '...'
--	exe 'Nread ' g:spellfile_URL . '/' . fname
-+	call spellfile#Nread(fname)
- 	if getline(2) !~ 'VIMsug'
- 	  echo 'Sorry, downloading failed'
- 	else
-@@ -109,3 +109,10 @@
-     bwipe
-   endif
- endfunc
-+
-+" Read "fname" from the ftp server.
-+function! spellfile#Nread(fname)
-+  let machine = substitute(g:spellfile_URL, 'ftp://\([^/]*\).*', '\1', '')
-+  let dir = substitute(g:spellfile_URL, 'ftp://[^/]*/\(.*\)', '\1', '')
-+  exe 'Nread "' . machine . ' anonymous vim7user ' . dir . '/' . a:fname . '"'
-+endfunc
-diff -Naur vim70.orig/runtime/plugin/matchparen.vim vim70/runtime/plugin/matchparen.vim
---- vim70.orig/runtime/plugin/matchparen.vim	2006-04-27 06:31:26.000000000 -0700
-+++ vim70/runtime/plugin/matchparen.vim	2006-08-09 08:36:40.000000000 -0700
-@@ -1,6 +1,6 @@
- " Vim plugin for showing matching parens
- " Maintainer:  Bram Moolenaar <Bram@vim.org>
--" Last Change: 2006 Apr 27
-+" Last Change: 2006 Jun 26
- 
- " Exit quickly when:
- " - this plugin was already loaded (or disabled)
-@@ -90,19 +90,19 @@
-   " Find the match.  When it was just before the cursor move it there for a
-   " moment.
-   if before > 0
--    let save_cursor = getpos('.')
-+    let save_cursor = winsaveview()
-     call cursor(c_lnum, c_col - before)
-   endif
- 
-   " When not in a string or comment ignore matches inside them.
-   let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' .
--	\ '=~?  "string\\|comment"'
-+	\ '=~?  "string\\|character\\|singlequote\\|comment"'
-   execute 'if' s_skip '| let s_skip = 0 | endif'
- 
-   let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
- 
-   if before > 0
--    call setpos('.', save_cursor)
-+    call winrestview(save_cursor)
-   endif
- 
-   " If a match is found setup match highlighting.
-diff -Naur vim70.orig/runtime/scripts.vim vim70/runtime/scripts.vim
---- vim70.orig/runtime/scripts.vim	2006-03-28 11:30:49.000000000 -0800
-+++ vim70/runtime/scripts.vim	2006-08-09 08:38:04.000000000 -0700
-@@ -1,7 +1,7 @@
- " Vim support file to detect file types in scripts
- "
- " Maintainer:	Bram Moolenaar <Bram@vim.org>
--" Last change:	2006 Mar 28
-+" Last change:	2006 Jul 08
- 
- " This file is called by an autocommand for every file that has just been
- " loaded into a buffer.  It checks if the type of file can be recognized by
-@@ -54,6 +54,12 @@
-     let s:name = substitute(s:line1, '^#!\s*\S*[/\\]\(\i\+\).*', '\1', '')
-   endif
- 
-+  " tcl scripts may have #!/bin/sh in the first line and "exec wish" in the
-+  " third line.  Suggested by Steven Atkinson.
-+  if getline(3) =~ '^exec wish'
-+    let s:name = 'wish'
-+  endif
-+
-   " Bourne-like shell scripts: bash bash2 ksh ksh93 sh
-   if s:name =~ '^\(bash\d*\|\|ksh\d*\|sh\)\>'
-     call SetFileTypeSH(s:line1)	" defined in filetype.vim
-diff -Naur vim70.orig/src/buffer.c vim70/src/buffer.c
---- vim70.orig/src/buffer.c	2006-04-26 14:37:23.000000000 -0700
-+++ vim70/src/buffer.c	2006-08-19 16:39:01.000000000 -0700
-@@ -5420,11 +5420,7 @@
-     buf_T	*newbuf;
-     int		differ = TRUE;
-     linenr_T	lnum;
--#ifdef FEAT_AUTOCMD
-     aco_save_T	aco;
--#else
--    buf_T	*old_curbuf = curbuf;
--#endif
-     exarg_T	ea;
- 
-     /* Allocate a buffer without putting it in the buffer list. */
-@@ -5439,13 +5435,8 @@
- 	return TRUE;
-     }
- 
--#ifdef FEAT_AUTOCMD
-     /* set curwin/curbuf to buf and save a few things */
-     aucmd_prepbuf(&aco, newbuf);
--#else
--    curbuf = newbuf;
--    curwin->w_buffer = newbuf;
--#endif
- 
-     if (ml_open(curbuf) == OK
- 	    && readfile(buf->b_ffname, buf->b_fname,
-@@ -5466,13 +5457,8 @@
-     }
-     vim_free(ea.cmd);
- 
--#ifdef FEAT_AUTOCMD
-     /* restore curwin/curbuf and a few other things */
-     aucmd_restbuf(&aco);
--#else
--    curbuf = old_curbuf;
--    curwin->w_buffer = old_curbuf;
--#endif
- 
-     if (curbuf != newbuf)	/* safety check */
- 	wipe_buffer(newbuf, FALSE);
-diff -Naur vim70.orig/src/configure vim70/src/configure
---- vim70.orig/src/configure	2006-05-07 07:17:49.000000000 -0700
-+++ vim70/src/configure	2006-08-09 08:37:06.000000000 -0700
-@@ -2,5 +2,9 @@
- # run the automatically generated configure script
- CONFIG_STATUS=auto/config.status \
- 	auto/configure "$@" --srcdir="${srcdir:-.}" --cache-file=auto/config.cache
-+result=$?
-+
- # Stupid autoconf 2.5x causes this file to be left behind.
- if test -f configure.lineno; then rm -f configure.lineno; fi
-+
-+exit $result
-diff -Naur vim70.orig/src/edit.c vim70/src/edit.c
---- vim70.orig/src/edit.c	2006-05-07 04:48:51.000000000 -0700
-+++ vim70/src/edit.c	2006-08-27 12:47:33.000000000 -0700
-@@ -719,9 +719,14 @@
- #ifdef FEAT_INS_EXPAND
- 	/*
- 	 * Special handling of keys while the popup menu is visible or wanted
--	 * and the cursor is still in the completed word.
-+	 * and the cursor is still in the completed word.  Only when there is
-+	 * a match, skip this when no matches were found.
- 	 */
--	if (compl_started && pum_wanted() && curwin->w_cursor.col >= compl_col)
-+	if (compl_started
-+		&& pum_wanted()
-+		&& curwin->w_cursor.col >= compl_col
-+		&& (compl_shown_match == NULL
-+		    || compl_shown_match != compl_shown_match->cp_next))
- 	{
- 	    /* BS: Delete one character from "compl_leader". */
- 	    if ((c == K_BS || c == Ctrl_H)
-@@ -751,7 +756,7 @@
- 		    continue;
- 		}
- 
--		/* Pressing CTRL-Y selects the current match.  Shen
-+		/* Pressing CTRL-Y selects the current match.  When
- 		 * compl_enter_selects is set the Enter key does the same. */
- 		if (c == Ctrl_Y || (compl_enter_selects
- 				   && (c == CAR || c == K_KENTER || c == NL)))
-@@ -877,6 +882,7 @@
- 		/* Close the cmdline window. */
- 		cmdwin_result = K_IGNORE;
- 		got_int = FALSE; /* don't stop executing autocommands et al. */
-+		nomove = TRUE;
- 		goto doESCkey;
- 	    }
- #endif
-@@ -2409,6 +2415,7 @@
-     compl_matches = ins_compl_make_cyclic();
-     compl_started = TRUE;
-     compl_used_match = TRUE;
-+    compl_cont_status = 0;
- 
-     compl_curr_match = compl_first_match;
-     ins_complete(Ctrl_N);
-@@ -2753,6 +2760,7 @@
- 	}
- 	else
- # endif
-+	    if (count > 0)	/* avoid warning for using "files" uninit */
- 	{
- 	    ins_compl_files(count, files, thesaurus, flags,
- 							&regmatch, buf, &dir);
-@@ -3015,9 +3023,6 @@
-     if ((int)(p - line) - (int)compl_col <= 0)
- 	return K_BS;
- 
--    /* For redo we need to repeat this backspace. */
--    AppendCharToRedobuff(K_BS);
--
-     /* Deleted more than what was used to find matches or didn't finish
-      * finding all matches: need to look for matches all over again. */
-     if (curwin->w_cursor.col <= compl_col + compl_length
-@@ -3046,7 +3051,6 @@
-     ins_compl_delete();
-     ins_bytes(compl_leader + curwin->w_cursor.col - compl_col);
-     compl_used_match = FALSE;
--    compl_enter_selects = FALSE;
- 
-     if (compl_started)
- 	ins_compl_set_original_text(compl_leader);
-@@ -3076,6 +3080,7 @@
- 	compl_restarting = FALSE;
-     }
- 
-+#if 0   /* disabled, made CTRL-L, BS and typing char jump to original text. */
-     if (!compl_used_match)
-     {
- 	/* Go to the original text, since none of the matches is inserted. */
-@@ -3087,6 +3092,8 @@
- 	compl_curr_match = compl_shown_match;
- 	compl_shows_dir = compl_direction;
-     }
-+#endif
-+    compl_enter_selects = !compl_used_match;
- 
-     /* Show the popup menu with a different set of matches. */
-     ins_compl_show_pum();
-@@ -3115,10 +3122,6 @@
- #endif
- 	ins_char(c);
- 
--    /* For redo we need to count this character so that the number of
--     * backspaces is correct. */
--    AppendCharToRedobuff(c);
--
-     /* If we didn't complete finding matches we must search again. */
-     if (compl_was_interrupted)
- 	ins_compl_restart();
-@@ -3175,10 +3178,32 @@
-     char_u	*p;
-     int		len = curwin->w_cursor.col - compl_col;
-     int		c;
-+    compl_T	*cp;
- 
-     p = compl_shown_match->cp_str;
-     if ((int)STRLEN(p) <= len)   /* the match is too short */
--	return;
-+    {
-+	/* When still at the original match use the first entry that matches
-+	 * the leader. */
-+	if (compl_shown_match->cp_flags & ORIGINAL_TEXT)
-+	{
-+	    p = NULL;
-+	    for (cp = compl_shown_match->cp_next; cp != NULL
-+				 && cp != compl_first_match; cp = cp->cp_next)
-+	    {
-+		if (ins_compl_equal(cp, compl_leader,
-+						   (int)STRLEN(compl_leader)))
-+		{
-+		    p = cp->cp_str;
-+		    break;
-+		}
-+	    }
-+	    if (p == NULL || (int)STRLEN(p) <= len)
-+		return;
-+	}
-+	else
-+	    return;
-+    }
-     p += len;
- #ifdef FEAT_MBYTE
-     c = mb_ptr2char(p);
-@@ -3198,7 +3223,6 @@
-     int	    c;
- {
-     char_u	*ptr;
--    int		temp;
-     int		want_cindent;
-     int		retval = FALSE;
- 
-@@ -3354,6 +3378,7 @@
- 	    if (compl_curr_match != NULL || compl_leader != NULL || c == Ctrl_E)
- 	    {
- 		char_u	*p;
-+		int	temp = 0;
- 
- 		/*
- 		 * If any of the original typed text has been changed, eg when
-@@ -3369,16 +3394,21 @@
- 		    ptr = compl_leader;
- 		else
- 		    ptr = compl_orig_text;
--		p = compl_orig_text;
--		for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp]; ++temp)
--		    ;
-+		if (compl_orig_text != NULL)
-+		{
-+		    p = compl_orig_text;
-+		    for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp];
-+								       ++temp)
-+			;
- #ifdef FEAT_MBYTE
--		if (temp > 0)
--		    temp -= (*mb_head_off)(compl_orig_text, p + temp);
-+		    if (temp > 0)
-+			temp -= (*mb_head_off)(compl_orig_text, p + temp);
- #endif
--		for (p += temp; *p != NUL; mb_ptr_adv(p))
--		    AppendCharToRedobuff(K_BS);
--		AppendToRedobuffLit(ptr + temp, -1);
-+		    for (p += temp; *p != NUL; mb_ptr_adv(p))
-+			AppendCharToRedobuff(K_BS);
-+		}
-+		if (ptr != NULL)
-+		    AppendToRedobuffLit(ptr + temp, -1);
- 	    }
- 
- #ifdef FEAT_CINDENT
-@@ -4100,6 +4130,21 @@
- 		&& compl_shown_match->cp_next != NULL
- 		&& compl_shown_match->cp_next != compl_first_match)
- 	    compl_shown_match = compl_shown_match->cp_next;
-+
-+	/* If we didn't find it searching forward, and compl_shows_dir is
-+	 * backward, find the last match. */
-+	if (compl_shows_dir == BACKWARD
-+		&& !ins_compl_equal(compl_shown_match,
-+				      compl_leader, (int)STRLEN(compl_leader))
-+		&& (compl_shown_match->cp_next == NULL
-+		    || compl_shown_match->cp_next == compl_first_match))
-+	{
-+	    while (!ins_compl_equal(compl_shown_match,
-+				      compl_leader, (int)STRLEN(compl_leader))
-+		    && compl_shown_match->cp_prev != NULL
-+		    && compl_shown_match->cp_prev != compl_first_match)
-+		compl_shown_match = compl_shown_match->cp_prev;
-+	}
-     }
- 
-     if (allow_get_expansion && insert_match
-@@ -4124,8 +4169,6 @@
-     {
- 	if (compl_shows_dir == FORWARD && compl_shown_match->cp_next != NULL)
- 	{
--	    if (compl_pending != 0)
--		--compl_pending;
- 	    compl_shown_match = compl_shown_match->cp_next;
- 	    found_end = (compl_first_match != NULL
- 			   && (compl_shown_match->cp_next == compl_first_match
-@@ -4134,14 +4177,24 @@
- 	else if (compl_shows_dir == BACKWARD
- 					&& compl_shown_match->cp_prev != NULL)
- 	{
--	    if (compl_pending != 0)
--		++compl_pending;
- 	    found_end = (compl_shown_match == compl_first_match);
- 	    compl_shown_match = compl_shown_match->cp_prev;
- 	    found_end |= (compl_shown_match == compl_first_match);
- 	}
- 	else
- 	{
-+	    if (!allow_get_expansion)
-+	    {
-+		if (advance)
-+		{
-+		    if (compl_shows_dir == BACKWARD)
-+			compl_pending -= todo + 1;
-+		    else
-+			compl_pending += todo + 1;
-+		}
-+		return -1;
-+	    }
-+
- 	    if (advance)
- 	    {
- 		if (compl_shows_dir == BACKWARD)
-@@ -4149,14 +4202,27 @@
- 		else
- 		    ++compl_pending;
- 	    }
--	    if (!allow_get_expansion)
--		return -1;
- 
- 	    /* Find matches. */
- 	    num_matches = ins_compl_get_exp(&compl_startpos);
--	    if (compl_pending != 0 && compl_direction == compl_shows_dir
-+
-+	    /* handle any pending completions */
-+	    while (compl_pending != 0 && compl_direction == compl_shows_dir
- 								   && advance)
--		compl_shown_match = compl_curr_match;
-+	    {
-+		if (compl_pending > 0 && compl_shown_match->cp_next != NULL)
-+		{
-+		    compl_shown_match = compl_shown_match->cp_next;
-+		    --compl_pending;
-+		}
-+		if (compl_pending < 0 && compl_shown_match->cp_prev != NULL)
-+		{
-+		    compl_shown_match = compl_shown_match->cp_prev;
-+		    ++compl_pending;
-+		}
-+		else
-+		    break;
-+	    }
- 	    found_end = FALSE;
- 	}
- 	if ((compl_shown_match->cp_flags & ORIGINAL_TEXT) == 0
-@@ -4265,9 +4331,9 @@
- 	return;
-     count = 0;
- 
--    ++no_mapping;
-+    /* Check for a typed key.  Do use mappings, otherwise vim_is_ctrl_x_key()
-+     * can't do its work correctly. */
-     c = vpeekc_any();
--    --no_mapping;
-     if (c != NUL)
-     {
- 	if (vim_is_ctrl_x_key(c) && c != Ctrl_X && c != Ctrl_R)
-@@ -4277,12 +4343,27 @@
- 	    (void)ins_compl_next(FALSE, ins_compl_key2count(c),
- 						    c != K_UP && c != K_DOWN);
- 	}
--	else if (c != Ctrl_R)
--	    compl_interrupted = TRUE;
-+	else
-+	{
-+	    /* Need to get the character to have KeyTyped set.  We'll put it
-+	     * back with vungetc() below. */
-+	    c = safe_vgetc();
-+
-+	    /* Don't interrupt completion when the character wasn't typed,
-+	     * e.g., when doing @q to replay keys. */
-+	    if (c != Ctrl_R && KeyTyped)
-+		compl_interrupted = TRUE;
-+
-+	    vungetc(c);
-+	}
-     }
-     if (compl_pending != 0 && !got_int)
--	(void)ins_compl_next(FALSE, compl_pending > 0
--				      ? compl_pending : -compl_pending, TRUE);
-+    {
-+	int todo = compl_pending > 0 ? compl_pending : -compl_pending;
-+
-+	compl_pending = 0;
-+	(void)ins_compl_next(FALSE, todo, TRUE);
-+    }
- }
- 
- /*
-@@ -4611,10 +4692,12 @@
- 				     (int)STRLEN(compl_pattern), curs_col);
- 	    if (compl_xp.xp_context == EXPAND_UNSUCCESSFUL
- 		    || compl_xp.xp_context == EXPAND_NOTHING)
--		return FAIL;
--	    startcol = (int)(compl_xp.xp_pattern - compl_pattern);
--	    compl_col = startcol;
--	    compl_length = curs_col - startcol;
-+		/* No completion possible, use an empty pattern to get a
-+		 * "pattern not found" message. */
-+		compl_col = curs_col;
-+	    else
-+		compl_col = (int)(compl_xp.xp_pattern - compl_pattern);
-+	    compl_length = curs_col - compl_col;
- 	}
- 	else if (ctrl_x_mode == CTRL_X_FUNCTION || ctrl_x_mode == CTRL_X_OMNI)
- 	{
-@@ -4668,11 +4751,17 @@
- 	    else
- 		compl_col = spell_word_start(startcol);
- 	    if (compl_col >= (colnr_T)startcol)
--		return FAIL;
--	    spell_expand_check_cap(compl_col);
-+	    {
-+		compl_length = 0;
-+		compl_col = curs_col;
-+	    }
-+	    else
-+	    {
-+		spell_expand_check_cap(compl_col);
-+		compl_length = (int)curs_col - compl_col;
-+	    }
- 	    /* Need to obtain "line" again, it may have become invalid. */
- 	    line = ml_get(curwin->w_cursor.lnum);
--	    compl_length = (int)curs_col - compl_col;
- 	    compl_pattern = vim_strnsave(line + compl_col, compl_length);
- 	    if (compl_pattern == NULL)
- #endif
-diff -Naur vim70.orig/src/eval.c vim70/src/eval.c
---- vim70.orig/src/eval.c	2006-05-05 10:15:26.000000000 -0700
-+++ vim70/src/eval.c	2006-08-19 16:40:29.000000000 -0700
-@@ -8252,6 +8252,12 @@
- 	EMSG(_("E785: complete() can only be used in Insert mode"));
- 	return;
-     }
-+
-+    /* Check for undo allowed here, because if something was already inserted
-+     * the line was already saved for undo and this check isn't done. */
-+    if (!undo_allowed())
-+	return;
-+
-     if (argvars[1].v_type != VAR_LIST || argvars[1].vval.v_list == NULL)
-     {
- 	EMSG(_(e_invarg));
-@@ -9792,6 +9798,9 @@
-     varnumber_T		n;
-     int			error = FALSE;
- 
-+    /* Position the cursor.  Needed after a message that ends in a space. */
-+    windgoto(msg_row, msg_col);
-+
-     ++no_mapping;
-     ++allow_keys;
-     if (argvars[0].v_type == VAR_UNKNOWN)
-@@ -11312,14 +11321,19 @@
- 
- static int inputsecret_flag = 0;
- 
-+static void get_user_input __ARGS((typval_T *argvars, typval_T *rettv, int inputdialog));
-+
- /*
-- * "input()" function
-- *     Also handles inputsecret() when inputsecret is set.
-+ * This function is used by f_input() and f_inputdialog() functions. The third
-+ * argument to f_input() specifies the type of completion to use at the
-+ * prompt. The third argument to f_inputdialog() specifies the value to return
-+ * when the user cancels the prompt.
-  */
-     static void
--f_input(argvars, rettv)
-+get_user_input(argvars, rettv, inputdialog)
-     typval_T	*argvars;
-     typval_T	*rettv;
-+    int		inputdialog;
- {
-     char_u	*prompt = get_tv_string_chk(&argvars[0]);
-     char_u	*p = NULL;
-@@ -11369,10 +11383,10 @@
- 	    if (defstr != NULL)
- 		stuffReadbuffSpec(defstr);
- 
--	    if (argvars[2].v_type != VAR_UNKNOWN)
-+	    if (!inputdialog && argvars[2].v_type != VAR_UNKNOWN)
- 	    {
- 		char_u	*xp_name;
--		int		xp_namelen;
-+		int	xp_namelen;
- 		long	argt;
- 
- 		rettv->vval.v_string = NULL;
-@@ -11404,6 +11418,18 @@
- }
- 
- /*
-+ * "input()" function
-+ *     Also handles inputsecret() when inputsecret is set.
-+ */
-+    static void
-+f_input(argvars, rettv)
-+    typval_T	*argvars;
-+    typval_T	*rettv;
-+{
-+    get_user_input(argvars, rettv, FALSE);
-+}
-+
-+/*
-  * "inputdialog()" function
-  */
-     static void
-@@ -11443,7 +11469,7 @@
-     }
-     else
- #endif
--	f_input(argvars, rettv);
-+	get_user_input(argvars, rettv, TRUE);
- }
- 
- /*
-@@ -11471,6 +11497,7 @@
-     }
- 
-     msg_start();
-+    msg_row = Rows - 1;	/* for when 'cmdheight' > 1 */
-     lines_left = Rows;	/* avoid more prompt */
-     msg_scroll = TRUE;
-     msg_clr_eos();
-@@ -13250,7 +13277,7 @@
- 	if (argvars[2].v_type != VAR_UNKNOWN)
- 	    EMSG2(_(e_toomanyarg), "remove()");
- 	else if ((d = argvars[0].vval.v_dict) != NULL
--		&& !tv_check_lock(d->dv_lock, (char_u *)"remove()"))
-+		&& !tv_check_lock(d->dv_lock, (char_u *)"remove() argument"))
- 	{
- 	    key = get_tv_string_chk(&argvars[1]);
- 	    if (key != NULL)
-@@ -13270,7 +13297,7 @@
-     else if (argvars[0].v_type != VAR_LIST)
- 	EMSG2(_(e_listdictarg), "remove()");
-     else if ((l = argvars[0].vval.v_list) != NULL
--	    && !tv_check_lock(l->lv_lock, (char_u *)"remove()"))
-+	    && !tv_check_lock(l->lv_lock, (char_u *)"remove() argument"))
-     {
- 	int	    error = FALSE;
- 
-@@ -14157,11 +14184,7 @@
-     typval_T	*rettv;
- {
-     buf_T	*buf;
--#ifdef FEAT_AUTOCMD
-     aco_save_T	aco;
--#else
--    buf_T	*save_curbuf;
--#endif
-     char_u	*varname, *bufvarname;
-     typval_T	*varp;
-     char_u	nbuf[NUMBUFLEN];
-@@ -14178,12 +14201,7 @@
-     if (buf != NULL && varname != NULL && varp != NULL)
-     {
- 	/* set curbuf to be our buf, temporarily */
--#ifdef FEAT_AUTOCMD
- 	aucmd_prepbuf(&aco, buf);
--#else
--	save_curbuf = curbuf;
--	curbuf = buf;
--#endif
- 
- 	if (*varname == '&')
- 	{
-@@ -14210,11 +14228,7 @@
- 	}
- 
- 	/* reset notion of buffer */
--#ifdef FEAT_AUTOCMD
- 	aucmd_restbuf(&aco);
--#else
--	curbuf = save_curbuf;
--#endif
-     }
- }
- 
-@@ -16438,9 +16452,12 @@
-     long	i = 0;
-     long	n;
- 
--    /* List must be: [fnum, lnum, col, coladd] */
--    if (arg->v_type != VAR_LIST || l == NULL
--				      || l->lv_len != (fnump == NULL ? 3 : 4))
-+    /* List must be: [fnum, lnum, col, coladd], where "fnum" is only there
-+     * when "fnump" isn't NULL and "coladd" is optional. */
-+    if (arg->v_type != VAR_LIST
-+	    || l == NULL
-+	    || l->lv_len < (fnump == NULL ? 2 : 3)
-+	    || l->lv_len > (fnump == NULL ? 3 : 4))
- 	return FAIL;
- 
-     if (fnump != NULL)
-@@ -16466,8 +16483,9 @@
- #ifdef FEAT_VIRTUALEDIT
-     n = list_find_nr(l, i, NULL);
-     if (n < 0)
--	return FAIL;
--    posp->coladd = n;
-+	posp->coladd = 0;
-+    else
-+	posp->coladd = n;
- #endif
- 
-     return OK;
-@@ -17759,6 +17777,13 @@
-     }
-     else		    /* add a new variable */
-     {
-+	/* Can't add "v:" variable. */
-+	if (ht == &vimvarht)
-+	{
-+	    EMSG2(_(e_illvar), name);
-+	    return;
-+	}
-+
- 	/* Make sure the variable name is valid. */
- 	for (p = varname; *p != NUL; ++p)
- 	    if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p))
-@@ -18786,6 +18811,7 @@
- 		if (dict_add(fudi.fd_dict, fudi.fd_di) == FAIL)
- 		{
- 		    vim_free(fudi.fd_di);
-+		    vim_free(fp);
- 		    goto erret;
- 		}
- 	    }
-@@ -18963,7 +18989,8 @@
-     else if (lead > 0)
-     {
- 	lead = 3;
--	if (eval_fname_sid(lv.ll_exp_name != NULL ? lv.ll_exp_name : *pp))
-+	if ((lv.ll_exp_name != NULL && eval_fname_sid(lv.ll_exp_name))
-+						       || eval_fname_sid(*pp))
- 	{
- 	    /* It's "s:" or "<SID>" */
- 	    if (current_SID <= 0)
-@@ -19685,6 +19712,7 @@
-     v->di_tv.vval.v_list = &fc.l_varlist;
-     vim_memset(&fc.l_varlist, 0, sizeof(list_T));
-     fc.l_varlist.lv_refcount = 99999;
-+    fc.l_varlist.lv_lock = VAR_FIXED;
- 
-     /*
-      * Set a:firstline to "firstline" and a:lastline to "lastline".
-diff -Naur vim70.orig/src/ex_cmds.h vim70/src/ex_cmds.h
---- vim70.orig/src/ex_cmds.h	2006-04-07 02:44:46.000000000 -0700
-+++ vim70/src/ex_cmds.h	2006-07-14 08:51:21.000000000 -0700
-@@ -262,7 +262,7 @@
- EX(CMD_comclear,	"comclear",	ex_comclear,
- 			TRLBAR|CMDWIN),
- EX(CMD_compiler,	"compiler",	ex_compiler,
--			BANG|TRLBAR|WORD1),
-+			BANG|TRLBAR|WORD1|CMDWIN),
- EX(CMD_continue,	"continue",	ex_continue,
- 			TRLBAR|SBOXOK|CMDWIN),
- EX(CMD_confirm,		"confirm",	ex_wrongmodifier,
-diff -Naur vim70.orig/src/ex_docmd.c vim70/src/ex_docmd.c
---- vim70.orig/src/ex_docmd.c	2006-05-05 09:33:19.000000000 -0700
-+++ vim70/src/ex_docmd.c	2006-08-19 16:34:11.000000000 -0700
-@@ -833,7 +833,7 @@
-      * If requested, store and reset the global values controlling the
-      * exception handling (used when debugging).
-      */
--    else if (flags & DOCMD_EXCRESET)
-+    if (flags & DOCMD_EXCRESET)
- 	save_dbg_stuff(&debug_saved);
- 
-     initial_trylevel = trylevel;
-@@ -1710,6 +1710,10 @@
-     save_cmdmod = cmdmod;
-     vim_memset(&cmdmod, 0, sizeof(cmdmod));
- 
-+    /* "#!anything" is handled like a comment. */
-+    if ((*cmdlinep)[0] == '#' && (*cmdlinep)[1] == '!')
-+	goto doend;
-+
-     /*
-      * Repeat until no more command modifiers are found.
-      */
-diff -Naur vim70.orig/src/ex_getln.c vim70/src/ex_getln.c
---- vim70.orig/src/ex_getln.c	2006-04-30 08:32:01.000000000 -0700
-+++ vim70/src/ex_getln.c	2006-08-19 16:33:52.000000000 -0700
-@@ -5982,6 +5982,8 @@
-     typestr[0] = cmdwin_type;
-     typestr[1] = NUL;
-     apply_autocmds(EVENT_CMDWINENTER, typestr, typestr, FALSE, curbuf);
-+    if (restart_edit != 0)	/* autocmd with ":startinsert" */
-+	stuffcharReadbuff(K_NOP);
- # endif
- 
-     i = RedrawingDisabled;
-diff -Naur vim70.orig/src/fileio.c vim70/src/fileio.c
---- vim70.orig/src/fileio.c	2006-04-30 08:28:57.000000000 -0700
-+++ vim70/src/fileio.c	2006-08-19 16:39:01.000000000 -0700
-@@ -6450,17 +6450,10 @@
-     int		old_ro = buf->b_p_ro;
-     buf_T	*savebuf;
-     int		saved = OK;
--#ifdef FEAT_AUTOCMD
-     aco_save_T	aco;
- 
-     /* set curwin/curbuf for "buf" and save some things */
-     aucmd_prepbuf(&aco, buf);
--#else
--    buf_T	*save_curbuf = curbuf;
--
--    curbuf = buf;
--    curwin->w_buffer = buf;
--#endif
- 
-     /* We only want to read the text from the file, not reset the syntax
-      * highlighting, clear marks, diff status, etc.  Force the fileformat
-@@ -6573,14 +6566,9 @@
- 	    curbuf->b_p_ro |= old_ro;
-     }
- 
--#ifdef FEAT_AUTOCMD
-     /* restore curwin/curbuf and a few other things */
-     aucmd_restbuf(&aco);
-     /* Careful: autocommands may have made "buf" invalid! */
--#else
--    curwin->w_buffer = save_curbuf;
--    curbuf = save_curbuf;
--#endif
- }
- 
- /*ARGSUSED*/
-@@ -8088,6 +8076,7 @@
-  * Search a window for the current buffer.  Save the cursor position and
-  * screen offset.
-  * Set "curbuf" and "curwin" to match "buf".
-+ * When FEAT_AUTOCMD is not defined another version is used, see below.
-  */
-     void
- aucmd_prepbuf(aco, buf)
-@@ -8151,6 +8140,7 @@
- /*
-  * Cleanup after executing autocommands for a (hidden) buffer.
-  * Restore the window as it was (if possible).
-+ * When FEAT_AUTOCMD is not defined another version is used, see below.
-  */
-     void
- aucmd_restbuf(aco)
-@@ -9063,8 +9053,38 @@
-     return retval;
- }
- 
-+#else	/* FEAT_AUTOCMD */
-+
-+/*
-+ * Prepare for executing commands for (hidden) buffer "buf".
-+ * This is the non-autocommand version, it simply saves "curbuf" and sets
-+ * "curbuf" and "curwin" to match "buf".
-+ */
-+    void
-+aucmd_prepbuf(aco, buf)
-+    aco_save_T	*aco;		/* structure to save values in */
-+    buf_T	*buf;		/* new curbuf */
-+{
-+    aco->save_buf = buf;
-+    curbuf = buf;
-+    curwin->w_buffer = buf;
-+}
-+
-+/*
-+ * Restore after executing commands for a (hidden) buffer.
-+ * This is the non-autocommand version.
-+ */
-+    void
-+aucmd_restbuf(aco)
-+    aco_save_T	*aco;		/* structure holding saved values */
-+{
-+    curbuf = aco->save_buf;
-+    curwin->w_buffer = curbuf;
-+}
-+
- #endif	/* FEAT_AUTOCMD */
- 
-+
- #if defined(FEAT_AUTOCMD) || defined(FEAT_WILDIGN) || defined(PROTO)
- /*
-  * Try matching a filename with a "pattern" ("prog" is NULL), or use the
-diff -Naur vim70.orig/src/gui_at_fs.c vim70/src/gui_at_fs.c
---- vim70.orig/src/gui_at_fs.c	2005-07-09 04:30:17.000000000 -0700
-+++ vim70/src/gui_at_fs.c	2006-07-14 08:51:21.000000000 -0700
-@@ -1861,27 +1861,27 @@
-     XtPointer	pnew;
- {
-     SFDir	*dir;
--    int		nw;
-+    int		nw = (int)(long)pnew;
- 
-     dir = &(SFdirs[SFdirPtr + (int)(long)n]);
- 
- #ifdef FEAT_GUI_NEXTAW
--    if ((int)(long)pnew < 0)
-+    if (nw < 0)
-     {
--	if ((int)(long)pnew > -SFvScrollHeight)
--	    (int)(long)pnew = -1;
-+	if (nw > -SFvScrollHeight)
-+	    nw = -1;
- 	else
--	    (int)(long)pnew = -SFlistSize;
-+	    nw = -SFlistSize;
-     }
--    else if ((int)(long)pnew > 0)
-+    else if (nw > 0)
-     {
--	if ((int)(long)pnew < SFvScrollHeight)
--	    (int)(long)pnew = 1;
-+	if (nw < SFvScrollHeight)
-+	    nw = 1;
- 	else
--	    (int)(long)pnew = SFlistSize;
-+	    nw = SFlistSize;
-     }
- #endif
--    nw = dir->vOrigin + (int)(long)pnew;
-+    nw += dir->vOrigin;
- 
-     if (nw > dir->nEntries - SFlistSize)
- 	nw = dir->nEntries - SFlistSize;
-@@ -1941,27 +1941,27 @@
-     XtPointer	pnew;
- {
-     SFDir	*dir;
--    int		nw;
-+    int		nw = (int)(long)pnew;
- 
-     dir = &(SFdirs[SFdirPtr + (int)(long)n]);
- 
- #ifdef FEAT_GUI_NEXTAW
--    if ((int)(long)pnew < 0)
-+    if (nw < 0)
-     {
--	if ((int)(long)pnew > -SFhScrollWidth)
--	    (int)(long)pnew = -1;
-+	if (nw > -SFhScrollWidth)
-+	    nw = -1;
- 	else
--	    (int)(long)pnew = -SFcharsPerEntry;
-+	    nw = -SFcharsPerEntry;
-     }
--    else if ((int)(long)pnew > 0)
-+    else if (nw > 0)
-     {
--	if ((int)(long)pnew < SFhScrollWidth)
--	    (int)(long)pnew = 1;
-+	if (nw < SFhScrollWidth)
-+	    nw = 1;
- 	else
--	    (int)(long)pnew = SFcharsPerEntry;
-+	    nw = SFcharsPerEntry;
-     }
- #endif
--    nw = dir->hOrigin + (int)(long)pnew;
-+    nw += dir->hOrigin;
- 
-     if (nw > dir->nChars - SFcharsPerEntry)
- 	nw = dir->nChars - SFcharsPerEntry;
-@@ -2038,26 +2038,26 @@
-     XtPointer	client_data;
-     XtPointer	pnew;
- {
--    int		nw;
-+    int		nw = (int)(long)pnew;
-     float	f;
- 
- #ifdef FEAT_GUI_NEXTAW
--    if ((int)(long)pnew < 0)
-+    if (nw < 0)
-     {
--	if ((int)(long)pnew > -SFpathScrollWidth)
--	    (int)(long)pnew = -1;
-+	if (nw > -SFpathScrollWidth)
-+	    nw = -1;
- 	else
--	    (int)(long)pnew = -3;
-+	    nw = -3;
-     }
--    else if ((int)(long)pnew > 0)
-+    else if (nw > 0)
-     {
--	if ((int)(long)pnew < SFpathScrollWidth)
--	    (int)(long)pnew = 1;
-+	if (nw < SFpathScrollWidth)
-+	    nw = 1;
- 	else
--	    (int)(long)pnew = 3;
-+	    nw = 3;
-     }
- #endif
--    nw = SFdirPtr + (int)(long)pnew;
-+    nw += SFdirPtr;
- 
-     if (nw > SFdirEnd - 3)
- 	nw = SFdirEnd - 3;
-diff -Naur vim70.orig/src/gui.c vim70/src/gui.c
---- vim70.orig/src/gui.c	2006-05-03 04:00:59.000000000 -0700
-+++ vim70/src/gui.c	2006-07-14 08:51:21.000000000 -0700
-@@ -4515,7 +4515,7 @@
-     int		y;
- {
-     win_T	*wp;
--    char_u	st[6];
-+    char_u	st[8];
- 
-     /* Ignore this while still starting up. */
-     if (!gui.in_use || gui.starting)
-@@ -4603,11 +4603,11 @@
-     /* Don't move the mouse when it's left or right of the Vim window */
-     if (x < 0 || x > Columns * gui.char_width)
- 	return;
-+    if (y >= 0
- # ifdef FEAT_WINDOWS
--    if (Y_2_ROW(y) >= tabline_height())
--# else
--    if (y >= 0)
-+	    && Y_2_ROW(y) >= tabline_height()
- # endif
-+       )
- 	wp = xy2win(x, y);
-     if (wp != curwin && wp != NULL)	/* If in other than current window */
-     {
-diff -Naur vim70.orig/src/gui_xmebw.c vim70/src/gui_xmebw.c
---- vim70.orig/src/gui_xmebw.c	2006-04-30 08:32:32.000000000 -0700
-+++ vim70/src/gui_xmebw.c	2006-07-14 08:51:21.000000000 -0700
-@@ -47,13 +47,13 @@
- #include "gui_xmebwp.h"
- 
- /* Provide some missing wrappers, which are missed from the LessTif
-- * implementation.
-+ * implementation.  Also missing in Motif 1.2 and earlier.
-  *
-  * We neither use XmeGetPixmapData or _XmGetPixmapData, since with LessTif the
-  * pixmap will not appear in it's caches properly. We cache the interresting
-  * values in XmEnhancedButtonPart instead ourself.
-  */
--#ifdef LESSTIF_VERSION
-+#if defined(LESSTIF_VERSION) || (XmVersion <= 1002)
- # ifndef Lab_IsMenupane
- #  define Lab_IsMenupane(w) (Lab_MenuType(w) == (int)XmMENU_POPUP || \
- 		    Lab_MenuType(w) == (int)XmMENU_PULLDOWN)
-@@ -480,7 +480,7 @@
- 	    || (eb->core.height <= 2 * eb->primitive.highlight_thickness))
- 	return;
- 
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
-     {
- 	XmDisplay	dpy;
- 
-@@ -641,7 +641,7 @@
-     GC		tmp_gc = NULL;
-     Boolean	replaceGC = False;
-     Boolean	deadjusted = False;
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
-     XmDisplay	dpy = (XmDisplay)XmGetXmDisplay(XtDisplay(eb));
-     Boolean	etched_in = dpy->display.enable_etched_in_menu;
- #else
-@@ -726,7 +726,7 @@
- 	if ((((ShellWidget) XtParent(XtParent(eb)))->shell.popped_up)
- 		&& _XmGetInDragMode((Widget) eb))
- 	{
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
- 	    XmDisplay dpy = (XmDisplay) XmGetXmDisplay(XtDisplay(wid));
- 	    Boolean etched_in = dpy->display.enable_etched_in_menu;
- #else
-@@ -810,7 +810,7 @@
- 
-     if (Lab_IsMenupane(eb))
-     {
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
- 	XmDisplay dpy = (XmDisplay) XmGetXmDisplay(XtDisplay(wid));
- 	Boolean etched_in = dpy->display.enable_etched_in_menu;
- #else
-@@ -1150,7 +1150,7 @@
- Redisplay(Widget w, XEvent *event, Region region)
- {
-     XmEnhancedButtonWidget  eb = (XmEnhancedButtonWidget) w;
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
-     XmDisplay		    dpy;
-     XtEnum		    default_button_emphasis;
- #endif
-@@ -1162,7 +1162,7 @@
-     if (!XtIsRealized((Widget)eb))
- 	return;
- 
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
-     dpy = (XmDisplay)XmGetXmDisplay(XtDisplay(eb));
-     default_button_emphasis = dpy->display.default_button_emphasis;
- #endif
-@@ -1241,7 +1241,7 @@
-     {
- 	int adjust = 0;
- 
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
- 	/*
- 	 *  NOTE: PushButton has two types of shadows: primitive-shadow and
- 	 *  default-button-shadow.  If pushbutton is in a menu only primitive
-@@ -1289,7 +1289,7 @@
- 			  adjust, adjust, rectwidth, rectheight, borderwidth);
- 	    }
- 
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
- 	    switch (default_button_emphasis)
- 	    {
- 		case XmINTERNAL_HIGHLIGHT:
-@@ -1365,7 +1365,7 @@
- 		    default_button_shadow_thickness =
- 			       eb->pushbutton.default_button_shadow_thickness;
- 
--#ifndef LESSTIF_VERSION
-+#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
- 		/*
- 		 * Compute location of bounding box to contain the
- 		 * defaultButtonShadow.
-diff -Naur vim70.orig/src/if_perl.xs vim70/src/if_perl.xs
---- vim70.orig/src/if_perl.xs	2006-03-06 10:57:16.000000000 -0800
-+++ vim70/src/if_perl.xs	2006-08-19 16:39:02.000000000 -0700
-@@ -155,8 +155,8 @@
- static int (*perl_run)(PerlInterpreter*);
- static int (*perl_parse)(PerlInterpreter*, XSINIT_t, int, char**, char**);
- static void* (*Perl_get_context)(void);
--static void (*Perl_croak)(pTHX_ const char*, ...) __attribute__((noreturn));
--static void (*Perl_croak_nocontext)(const char*, ...) __attribute__((noreturn));
-+static void (*Perl_croak)(pTHX_ const char*, ...);
-+static void (*Perl_croak_nocontext)(const char*, ...);
- static I32 (*Perl_dowantarray)(pTHX);
- static void (*Perl_free_tmps)(pTHX);
- static HV* (*Perl_gv_stashpv)(pTHX_ const char*, I32);
-@@ -1056,7 +1056,6 @@
-     int i;
-     long lnum;
-     char *line;
--    buf_T *savebuf;
-     PPCODE:
-     if (buf_valid(vimbuf))
-     {
-@@ -1069,14 +1068,20 @@
- 	    line = SvPV(ST(i),PL_na);
- 	    if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count && line != NULL)
- 	    {
--		savebuf = curbuf;
--		curbuf = vimbuf;
-+		aco_save_T	aco;
-+
-+		/* set curwin/curbuf for "vimbuf" and save some things */
-+		aucmd_prepbuf(&aco, vimbuf);
-+
- 		if (u_savesub(lnum) == OK)
- 		{
- 		    ml_replace(lnum, (char_u *)line, TRUE);
- 		    changed_bytes(lnum, 0);
- 		}
--		curbuf = savebuf;
-+
-+		/* restore curwin/curbuf and a few other things */
-+		aucmd_restbuf(&aco);
-+		/* Careful: autocommands may have made "vimbuf" invalid! */
- 	    }
- 	}
-     }
-@@ -1087,7 +1092,6 @@
- 
-     PREINIT:
-     long i, lnum = 0, count = 0;
--    buf_T *savebuf;
-     PPCODE:
-     if (buf_valid(vimbuf))
-     {
-@@ -1114,16 +1118,23 @@
- 	    {
- 		if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count)
- 		{
--		    savebuf = curbuf;
--		    curbuf = vimbuf;
-+		    aco_save_T	aco;
-+
-+		    /* set curwin/curbuf for "vimbuf" and save some things */
-+		    aucmd_prepbuf(&aco, vimbuf);
-+
- 		    if (u_savedel(lnum, 1) == OK)
- 		    {
- 			ml_delete(lnum, 0);
- 			deleted_lines_mark(lnum, 1L);
--			if (savebuf == curbuf)
-+			if (aco.save_buf == curbuf)
- 			    check_cursor();
- 		    }
--		    curbuf = savebuf;
-+
-+		    /* restore curwin/curbuf and a few other things */
-+		    aucmd_restbuf(&aco);
-+		    /* Careful: autocommands may have made "vimbuf" invalid! */
-+
- 		    update_curbuf(VALID);
- 		}
- 	    }
-@@ -1138,7 +1149,6 @@
-     int		i;
-     long	lnum;
-     char	*line;
--    buf_T	*savebuf;
-     PPCODE:
-     if (buf_valid(vimbuf))
-     {
-@@ -1151,14 +1161,21 @@
- 	    line = SvPV(ST(i),PL_na);
- 	    if (lnum >= 0 && lnum <= vimbuf->b_ml.ml_line_count && line != NULL)
- 	    {
--		savebuf = curbuf;
--		curbuf = vimbuf;
-+		aco_save_T	aco;
-+
-+		/* set curwin/curbuf for "vimbuf" and save some things */
-+		aucmd_prepbuf(&aco, vimbuf);
-+
- 		if (u_inssub(lnum + 1) == OK)
- 		{
- 		    ml_append(lnum, (char_u *)line, (colnr_T)0, FALSE);
- 		    appended_lines_mark(lnum, 1L);
- 		}
--		curbuf = savebuf;
-+
-+		/* restore curwin/curbuf and a few other things */
-+		aucmd_restbuf(&aco);
-+		/* Careful: autocommands may have made "vimbuf" invalid! */
-+
- 		update_curbuf(VALID);
- 	    }
- 	}
-diff -Naur vim70.orig/src/if_ruby.c vim70/src/if_ruby.c
---- vim70.orig/src/if_ruby.c	2006-04-30 08:37:52.000000000 -0700
-+++ vim70/src/if_ruby.c	2006-08-19 16:39:01.000000000 -0700
-@@ -643,11 +643,14 @@
- 
- static VALUE set_buffer_line(buf_T *buf, linenr_T n, VALUE str)
- {
--    buf_T *savebuf = curbuf;
--    char *line = STR2CSTR(str);
-+    char	*line = STR2CSTR(str);
-+    aco_save_T	aco;
-+
-+    if (n > 0 && n <= buf->b_ml.ml_line_count && line != NULL)
-+    {
-+	/* set curwin/curbuf for "buf" and save some things */
-+	aucmd_prepbuf(&aco, buf);
- 
--    if (n > 0 && n <= buf->b_ml.ml_line_count && line != NULL) {
--	curbuf = buf;
- 	if (u_savesub(n) == OK) {
- 	    ml_replace(n, (char_u *)line, TRUE);
- 	    changed();
-@@ -655,10 +658,15 @@
- 	    syn_changed(n); /* recompute syntax hl. for this line */
- #endif
- 	}
--	curbuf = savebuf;
-+
-+	/* restore curwin/curbuf and a few other things */
-+	aucmd_restbuf(&aco);
-+	/* Careful: autocommands may have made "buf" invalid! */
-+
- 	update_curbuf(NOT_VALID);
-     }
--    else {
-+    else
-+    {
- 	rb_raise(rb_eIndexError, "index %d out of buffer", n);
- 	return Qnil; /* For stop warning */
-     }
-@@ -676,12 +684,15 @@
- 
- static VALUE buffer_delete(VALUE self, VALUE num)
- {
--    buf_T *buf = get_buf(self);
--    buf_T *savebuf = curbuf;
--    long n = NUM2LONG(num);
-+    buf_T	*buf = get_buf(self);
-+    long	n = NUM2LONG(num);
-+    aco_save_T	aco;
-+
-+    if (n > 0 && n <= buf->b_ml.ml_line_count)
-+    {
-+	/* set curwin/curbuf for "buf" and save some things */
-+	aucmd_prepbuf(&aco, buf);
- 
--    if (n > 0 && n <= buf->b_ml.ml_line_count) {
--	curbuf = buf;
- 	if (u_savedel(n, 1) == OK) {
- 	    ml_delete(n, 0);
- 
-@@ -691,10 +702,15 @@
- 
- 	    changed();
- 	}
--	curbuf = savebuf;
-+
-+	/* restore curwin/curbuf and a few other things */
-+	aucmd_restbuf(&aco);
-+	/* Careful: autocommands may have made "buf" invalid! */
-+
- 	update_curbuf(NOT_VALID);
-     }
--    else {
-+    else
-+    {
- 	rb_raise(rb_eIndexError, "index %d out of buffer", n);
-     }
-     return Qnil;
-@@ -702,13 +718,16 @@
- 
- static VALUE buffer_append(VALUE self, VALUE num, VALUE str)
- {
--    buf_T *buf = get_buf(self);
--    buf_T *savebuf = curbuf;
--    char *line = STR2CSTR(str);
--    long n = NUM2LONG(num);
-+    buf_T	*buf = get_buf(self);
-+    char	*line = STR2CSTR(str);
-+    long	n = NUM2LONG(num);
-+    aco_save_T	aco;
-+
-+    if (n >= 0 && n <= buf->b_ml.ml_line_count && line != NULL)
-+    {
-+	/* set curwin/curbuf for "buf" and save some things */
-+	aucmd_prepbuf(&aco, buf);
- 
--    if (n >= 0 && n <= buf->b_ml.ml_line_count && line != NULL) {
--	curbuf = buf;
- 	if (u_inssub(n + 1) == OK) {
- 	    ml_append(n, (char_u *) line, (colnr_T) 0, FALSE);
- 
-@@ -718,7 +737,11 @@
- 
- 	    changed();
- 	}
--	curbuf = savebuf;
-+
-+	/* restore curwin/curbuf and a few other things */
-+	aucmd_restbuf(&aco);
-+	/* Careful: autocommands may have made "buf" invalid! */
-+
- 	update_curbuf(NOT_VALID);
-     }
-     else {
-diff -Naur vim70.orig/src/main.c vim70/src/main.c
---- vim70.orig/src/main.c	2006-05-03 10:36:44.000000000 -0700
-+++ vim70/src/main.c	2006-08-19 16:32:24.000000000 -0700
-@@ -564,7 +564,11 @@
-      */
-     if (p_lpl)
-     {
-+# ifdef VMS	/* Somehow VMS doesn't handle the "**". */
-+	source_runtime((char_u *)"plugin/*.vim", TRUE);
-+# else
- 	source_runtime((char_u *)"plugin/**/*.vim", TRUE);
-+# endif
- 	TIME_MSG("loading plugins");
-     }
- #endif
-@@ -3208,10 +3212,15 @@
-      * Register for remote command execution with :serversend and --remote
-      * unless there was a -X or a --servername '' on the command line.
-      * Only register nongui-vim's with an explicit --servername argument.
-+     * When running as root --servername is also required.
-      */
-     if (X_DISPLAY != NULL && parmp->servername != NULL && (
- #  ifdef FEAT_GUI
--		gui.in_use ||
-+		(gui.in_use
-+#   ifdef UNIX
-+		 && getuid() != 0
-+#   endif
-+		) ||
- #  endif
- 		parmp->serverName_arg != NULL))
-     {
-diff -Naur vim70.orig/src/Makefile vim70/src/Makefile
---- vim70.orig/src/Makefile	2006-05-07 06:25:27.000000000 -0700
-+++ vim70/src/Makefile	2006-07-14 08:51:21.000000000 -0700
-@@ -2177,6 +2177,7 @@
- 	cd $(SHADOWDIR)/xxd; ln -s ../../xxd/*.[ch] ../../xxd/Make* .
- 	if test -d $(RSRC_DIR); then \
- 		cd $(SHADOWDIR); \
-+		ln -s ../infplist.xml .; \
- 		ln -s ../$(RSRC_DIR) ../os_mac.rsr.hqx ../dehqx.py .; \
- 	fi
- 	mkdir $(SHADOWDIR)/testdir
-diff -Naur vim70.orig/src/mbyte.c vim70/src/mbyte.c
---- vim70.orig/src/mbyte.c	2006-04-30 04:51:01.000000000 -0700
-+++ vim70/src/mbyte.c	2006-08-19 16:34:45.000000000 -0700
-@@ -311,7 +311,11 @@
- 
- #define IDX_MACROMAN	57
-     {"macroman",	ENC_8BIT + ENC_MACROMAN, 0},	/* Mac OS */
--#define IDX_COUNT	58
-+#define IDX_DECMCS	58
-+    {"dec-mcs",		ENC_8BIT,		0},	/* DEC MCS */
-+#define IDX_HPROMAN8	59
-+    {"hp-roman8",	ENC_8BIT,		0},	/* HP Roman8 */
-+#define IDX_COUNT	60
- };
- 
- /*
-@@ -359,6 +363,8 @@
-     {"932",		IDX_CP932},
-     {"949",		IDX_CP949},
-     {"936",		IDX_CP936},
-+    {"gbk",		IDX_CP936},
-+    {"gb18030",		IDX_CP936},	/* only 99% the same */
-     {"950",		IDX_CP950},
-     {"eucjp",		IDX_EUC_JP},
-     {"unix-jis",	IDX_EUC_JP},
-@@ -386,6 +392,7 @@
-     {"950",		IDX_BIG5},
- #endif
-     {"mac",		IDX_MACROMAN},
-+    {"mac-roman",	IDX_MACROMAN},
-     {NULL,		0}
- };
- 
-diff -Naur vim70.orig/src/menu.c vim70/src/menu.c
---- vim70.orig/src/menu.c	2006-05-03 10:30:48.000000000 -0700
-+++ vim70/src/menu.c	2006-08-19 16:40:11.000000000 -0700
-@@ -511,6 +511,14 @@
- 	 * name (without mnemonic and accelerator text). */
- 	next_name = menu_name_skip(name);
- 	dname = menu_text(name, NULL, NULL);
-+	if (dname == NULL)
-+	    goto erret;
-+	if (*dname == NUL)
-+	{
-+	    /* Only a mnemonic or accelerator is not valid. */
-+	    EMSG(_("E792: Empty menu name"));
-+	    goto erret;
-+	}
- 
- 	/* See if it's already there */
- 	lower_pri = menup;
-@@ -704,6 +712,7 @@
- 	parent = menu;
- 	name = next_name;
- 	vim_free(dname);
-+	dname = NULL;
- 	if (pri_tab[pri_idx + 1] != -1)
- 	    ++pri_idx;
-     }
-@@ -793,6 +802,22 @@
- erret:
-     vim_free(path_name);
-     vim_free(dname);
-+
-+    /* Delete any empty submenu we added before discovering the error.  Repeat
-+     * for higher levels. */
-+    while (parent != NULL && parent->children == NULL)
-+    {
-+	if (parent->parent == NULL)
-+	    menup = &root_menu;
-+	else
-+	    menup = &parent->parent->children;
-+	for ( ; *menup != NULL && *menup != parent; menup = &((*menup)->next))
-+	    ;
-+	if (*menup == NULL) /* safety check */
-+	    break;
-+	parent = parent->parent;
-+	free_menu(menup);
-+    }
-     return FAIL;
- }
- 
-@@ -1753,6 +1778,27 @@
- }
- 
- /*
-+ * Check that a pointer appears in the menu tree.  Used to protect from using
-+ * a menu that was deleted after it was selected but before the event was
-+ * handled.
-+ * Return OK or FAIL.  Used recursively.
-+ */
-+    int
-+check_menu_pointer(root, menu_to_check)
-+    vimmenu_T *root;
-+    vimmenu_T *menu_to_check;
-+{
-+    vimmenu_T	*p;
-+
-+    for (p = root; p != NULL; p = p->next)
-+	if (p == menu_to_check
-+		|| (p->children != NULL
-+		    && check_menu_pointer(p->children, menu_to_check) == OK))
-+	    return OK;
-+    return FAIL;
-+}
-+
-+/*
-  * After we have started the GUI, then we can create any menus that have been
-  * defined.  This is done once here.  add_menu_path() may have already been
-  * called to define these menus, and may be called again.  This function calls
-diff -Naur vim70.orig/src/message.c vim70/src/message.c
---- vim70.orig/src/message.c	2006-05-06 13:07:37.000000000 -0700
-+++ vim70/src/message.c	2006-07-14 08:51:21.000000000 -0700
-@@ -4175,15 +4175,16 @@
- 			str_arg_l = 0;
- 		    else
- 		    {
--			/* memchr on HP does not like n > 2^31  !!! */
--			char *q = memchr(str_arg, '\0',
-+			/* Don't put the #if inside memchr(), it can be a
-+			 * macro. */
- #if SIZEOF_INT <= 2
--				precision
-+			char *q = memchr(str_arg, '\0', precision);
- #else
--				precision <= (size_t)0x7fffffffL ? precision
--						       : (size_t)0x7fffffffL
-+			/* memchr on HP does not like n > 2^31  !!! */
-+			char *q = memchr(str_arg, '\0',
-+				  precision <= (size_t)0x7fffffffL ? precision
-+						       : (size_t)0x7fffffffL);
- #endif
--						       );
- 			str_arg_l = (q == NULL) ? precision : q - str_arg;
- 		    }
- 		    break;
-diff -Naur vim70.orig/src/misc1.c vim70/src/misc1.c
---- vim70.orig/src/misc1.c	2006-04-30 08:30:02.000000000 -0700
-+++ vim70/src/misc1.c	2006-08-19 16:32:45.000000000 -0700
-@@ -4492,7 +4492,7 @@
- 		int l = mb_ptr2len(s);
- 
- 		while (--l > 0)
--		    *d++ = *s++;
-+		    *d++ = *++s;
- 	    }
- # endif
- 	}
-diff -Naur vim70.orig/src/netbeans.c vim70/src/netbeans.c
---- vim70.orig/src/netbeans.c	2006-04-22 11:00:05.000000000 -0700
-+++ vim70/src/netbeans.c	2006-08-09 08:38:32.000000000 -0700
-@@ -1986,6 +1986,8 @@
- 	    if (buf->bufp != NULL)
- 		do_buffer(DOBUF_WIPE, DOBUF_FIRST, FORWARD,
- 						     buf->bufp->b_fnum, TRUE);
-+	    buf->bufp = NULL;
-+	    buf->initDone = FALSE;
- 	    doupdate = 1;
- /* =====================================================================*/
- 	}
-diff -Naur vim70.orig/src/normal.c vim70/src/normal.c
---- vim70.orig/src/normal.c	2006-04-29 06:11:18.000000000 -0700
-+++ vim70/src/normal.c	2006-08-19 16:40:11.000000000 -0700
-@@ -2504,7 +2504,8 @@
- 	     * NOTE: Ignore right button down and drag mouse events.
- 	     * Windows only shows the popup menu on the button up event.
- 	     */
--#if defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_PHOTON)
-+#if defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_GTK) \
-+			  || defined(FEAT_GUI_PHOTON) || defined(FEAT_GUI_MAC)
- 	    if (!is_click)
- 		return FALSE;
- #endif
-diff -Naur vim70.orig/src/ops.c vim70/src/ops.c
---- vim70.orig/src/ops.c	2006-04-30 08:13:44.000000000 -0700
-+++ vim70/src/ops.c	2006-08-09 08:33:53.000000000 -0700
-@@ -2413,6 +2413,7 @@
- 	else
- 	{
- 	    curwin->w_cursor = oap->end;
-+	    check_cursor_col();
- 
- 	    /* Works just like an 'i'nsert on the next character. */
- 	    if (!lineempty(curwin->w_cursor.lnum)
-@@ -3492,8 +3493,15 @@
- # endif
- 	if (flags & PUT_CURSEND)
- 	{
-+	    colnr_T len;
-+
- 	    curwin->w_cursor = curbuf->b_op_end;
- 	    curwin->w_cursor.col++;
-+
-+	    /* in Insert mode we might be after the NUL, correct for that */
-+	    len = (colnr_T)STRLEN(ml_get_curline());
-+	    if (curwin->w_cursor.col > len)
-+		curwin->w_cursor.col = len;
- 	}
- 	else
- 	    curwin->w_cursor.lnum = lnum;
-diff -Naur vim70.orig/src/option.c vim70/src/option.c
---- vim70.orig/src/option.c	2006-05-03 10:32:28.000000000 -0700
-+++ vim70/src/option.c	2006-08-09 08:34:17.000000000 -0700
-@@ -2294,7 +2294,7 @@
- 			    {(char_u *)0L, (char_u *)0L}
- #endif
- 			    },
--    {"spellsuggest", "sps", P_STRING|P_VI_DEF|P_EXPAND|P_SECURE,
-+    {"spellsuggest", "sps", P_STRING|P_VI_DEF|P_EXPAND|P_SECURE|P_COMMA,
- #ifdef FEAT_SPELL
- 			    (char_u *)&p_sps, PV_NONE,
- 			    {(char_u *)"best", (char_u *)0L}
-@@ -5227,13 +5227,13 @@
- 	    case PV_STL:	return &curwin->w_p_stl_flags;
- #endif
- #ifdef FEAT_EVAL
-+# ifdef FEAT_FOLDING
- 	    case PV_FDE:	return &curwin->w_p_fde_flags;
- 	    case PV_FDT:	return &curwin->w_p_fdt_flags;
-+# endif
- # ifdef FEAT_BEVAL
- 	    case PV_BEXPR:	return &curbuf->b_p_bexpr_flags;
- # endif
--#endif
--#if defined(FEAT_EVAL)
- # if defined(FEAT_CINDENT)
- 	    case PV_INDE:	return &curbuf->b_p_inde_flags;
- # endif
-@@ -6325,7 +6325,8 @@
- 	    else
- 		errmsg = check_stl_option(p_ruf);
- 	}
--	else
-+	/* check 'statusline' only if it doesn't start with "%!" */
-+	else if (varp != &p_stl || s[0] != '%' || s[1] != '!')
- 	    errmsg = check_stl_option(s);
- 	if (varp == &p_ruf && errmsg == NULL)
- 	    comp_col();
-diff -Naur vim70.orig/src/os_unix.c vim70/src/os_unix.c
---- vim70.orig/src/os_unix.c	2006-05-01 01:13:15.000000000 -0700
-+++ vim70/src/os_unix.c	2006-07-14 08:51:21.000000000 -0700
-@@ -4971,7 +4971,8 @@
- 		    if (((*file)[*num_file] = alloc(len + 2)) != NULL)
- 		    {
- 			STRCPY((*file)[*num_file], p);
--			if (!after_pathsep((*file)[*num_file] + len))
-+			if (!after_pathsep((*file)[*num_file],
-+						    (*file)[*num_file] + len))
- 			{
- 			    (*file)[*num_file][len] = psepc;
- 			    (*file)[*num_file][len + 1] = NUL;
-@@ -5757,8 +5758,13 @@
-     int		retval_int = 0;
-     int		success = FALSE;
- 
--    /* Get a handle to the DLL module. */
-+    /*
-+     * Get a handle to the DLL module.
-+     */
- # if defined(USE_DLOPEN)
-+    /* First clear any error, it's not cleared by the dlopen() call. */
-+    (void)dlerror();
-+
-     hinstLib = dlopen((char *)libname, RTLD_LAZY
- #  ifdef RTLD_LOCAL
- 	    | RTLD_LOCAL
-diff -Naur vim70.orig/src/popupmnu.c vim70/src/popupmnu.c
---- vim70.orig/src/popupmnu.c	2006-04-20 13:18:37.000000000 -0700
-+++ vim70/src/popupmnu.c	2006-08-27 12:48:28.000000000 -0700
-@@ -552,6 +552,9 @@
- {
-     pum_array = NULL;
-     redraw_all_later(SOME_VALID);
-+#ifdef FEAT_WINDOWS
-+    redraw_tabline = TRUE;
-+#endif
-     status_redraw_all();
- }
- 
-diff -Naur vim70.orig/src/proto/menu.pro vim70/src/proto/menu.pro
---- vim70.orig/src/proto/menu.pro	2006-05-07 06:08:51.000000000 -0700
-+++ vim70/src/proto/menu.pro	2006-08-19 16:40:11.000000000 -0700
-@@ -10,6 +10,7 @@
- extern int menu_is_child_of_popup __ARGS((vimmenu_T *menu));
- extern int menu_is_toolbar __ARGS((char_u *name));
- extern int menu_is_separator __ARGS((char_u *name));
-+extern int check_menu_pointer __ARGS((vimmenu_T *root, vimmenu_T *menu_to_check));
- extern void gui_create_initial_menus __ARGS((vimmenu_T *menu));
- extern void gui_update_menus __ARGS((int modes));
- extern int gui_is_menu_shortcut __ARGS((int key));
-diff -Naur vim70.orig/src/proto/undo.pro vim70/src/proto/undo.pro
---- vim70.orig/src/proto/undo.pro	2006-05-07 06:09:11.000000000 -0700
-+++ vim70/src/proto/undo.pro	2006-07-14 10:51:11.000000000 -0700
-@@ -4,6 +4,7 @@
- extern int u_savesub __ARGS((linenr_T lnum));
- extern int u_inssub __ARGS((linenr_T lnum));
- extern int u_savedel __ARGS((linenr_T lnum, long nlines));
-+extern int undo_allowed __ARGS((void));
- extern void u_undo __ARGS((int count));
- extern void u_redo __ARGS((int count));
- extern void undo_time __ARGS((long step, int sec, int absolute));
-diff -Naur vim70.orig/src/quickfix.c vim70/src/quickfix.c
---- vim70.orig/src/quickfix.c	2006-05-03 00:47:42.000000000 -0700
-+++ vim70/src/quickfix.c	2006-08-19 16:39:02.000000000 -0700
-@@ -602,13 +602,19 @@
- 		else
- 		    type = 0;
- 		/*
--		 * Extract error message data from matched line
-+		 * Extract error message data from matched line.
-+		 * We check for an actual submatch, because "\[" and "\]" in
-+		 * the 'errorformat' may cause the wrong submatch to be used.
- 		 */
- 		if ((i = (int)fmt_ptr->addr[0]) > 0)		/* %f */
- 		{
--		    int c = *regmatch.endp[i];
-+		    int c;
-+
-+		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
-+			continue;
- 
- 		    /* Expand ~/file and $HOME/file to full path. */
-+		    c = *regmatch.endp[i];
- 		    *regmatch.endp[i] = NUL;
- 		    expand_env(regmatch.startp[i], namebuf, CMDBUFFSIZE);
- 		    *regmatch.endp[i] = c;
-@@ -618,35 +624,63 @@
- 			continue;
- 		}
- 		if ((i = (int)fmt_ptr->addr[1]) > 0)		/* %n */
-+		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    enr = (int)atol((char *)regmatch.startp[i]);
-+		}
- 		if ((i = (int)fmt_ptr->addr[2]) > 0)		/* %l */
-+		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    lnum = atol((char *)regmatch.startp[i]);
-+		}
- 		if ((i = (int)fmt_ptr->addr[3]) > 0)		/* %c */
-+		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    col = (int)atol((char *)regmatch.startp[i]);
-+		}
- 		if ((i = (int)fmt_ptr->addr[4]) > 0)		/* %t */
-+		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    type = *regmatch.startp[i];
-+		}
- 		if (fmt_ptr->flags == '+' && !multiscan)	/* %+ */
- 		    STRCPY(errmsg, IObuff);
- 		else if ((i = (int)fmt_ptr->addr[5]) > 0)	/* %m */
- 		{
-+		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
-+			continue;
- 		    len = (int)(regmatch.endp[i] - regmatch.startp[i]);
- 		    vim_strncpy(errmsg, regmatch.startp[i], len);
- 		}
- 		if ((i = (int)fmt_ptr->addr[6]) > 0)		/* %r */
-+		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    tail = regmatch.startp[i];
-+		}
- 		if ((i = (int)fmt_ptr->addr[7]) > 0)		/* %p */
- 		{
-+		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
-+			continue;
- 		    col = (int)(regmatch.endp[i] - regmatch.startp[i] + 1);
- 		    if (*((char_u *)regmatch.startp[i]) != TAB)
- 			use_viscol = TRUE;
- 		}
- 		if ((i = (int)fmt_ptr->addr[8]) > 0)		/* %v */
- 		{
-+		    if (regmatch.startp[i] == NULL)
-+			continue;
- 		    col = (int)atol((char *)regmatch.startp[i]);
- 		    use_viscol = TRUE;
- 		}
- 		if ((i = (int)fmt_ptr->addr[9]) > 0)		/* %s */
- 		{
-+		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
-+			continue;
- 		    len = (int)(regmatch.endp[i] - regmatch.startp[i]);
- 		    if (len > CMDBUFFSIZE - 5)
- 			len = CMDBUFFSIZE - 5;
-@@ -2429,32 +2463,19 @@
-     qf_info_T	*qi;
- {
-     buf_T	*buf;
--#ifdef FEAT_AUTOCMD
-     aco_save_T	aco;
--#else
--    buf_T	*save_curbuf;
--#endif
- 
-     /* Check if a buffer for the quickfix list exists.  Update it. */
-     buf = qf_find_buf(qi);
-     if (buf != NULL)
-     {
--#ifdef FEAT_AUTOCMD
- 	/* set curwin/curbuf to buf and save a few things */
- 	aucmd_prepbuf(&aco, buf);
--#else
--	save_curbuf = curbuf;
--	curbuf = buf;
--#endif
- 
- 	qf_fill_buffer(qi);
- 
--#ifdef FEAT_AUTOCMD
- 	/* restore curwin/curbuf and a few other things */
- 	aucmd_restbuf(&aco);
--#else
--	curbuf = save_curbuf;
--#endif
- 
- 	(void)qf_win_pos_update(qi, 0);
-     }
-@@ -2943,10 +2964,8 @@
- #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL)
-     char_u	*save_ei = NULL;
- #endif
--#ifndef FEAT_AUTOCMD
--    buf_T	*save_curbuf;
--#else
-     aco_save_T	aco;
-+#ifdef FEAT_AUTOCMD
-     char_u	*au_name =  NULL;
-     int		flags = 0;
-     colnr_T	col;
-@@ -3167,24 +3186,13 @@
- 		     * need to be done now, in that buffer.  And the modelines
- 		     * need to be done (again).  But not the window-local
- 		     * options! */
--#if defined(FEAT_AUTOCMD)
- 		    aucmd_prepbuf(&aco, buf);
--#else
--		    save_curbuf = curbuf;
--		    curbuf = buf;
--		    curwin->w_buffer = curbuf;
--#endif
- #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL)
- 		    apply_autocmds(EVENT_FILETYPE, buf->b_p_ft,
- 						     buf->b_fname, TRUE, buf);
- #endif
- 		    do_modelines(OPT_NOWIN);
--#if defined(FEAT_AUTOCMD)
- 		    aucmd_restbuf(&aco);
--#else
--		    curbuf = save_curbuf;
--		    curwin->w_buffer = curbuf;
--#endif
- 		}
- 	    }
- 	}
-@@ -3285,11 +3293,7 @@
- {
-     buf_T	*newbuf;
-     int		failed = TRUE;
--#ifdef FEAT_AUTOCMD
-     aco_save_T	aco;
--#else
--    buf_T	*old_curbuf = curbuf;
--#endif
- 
-     /* Allocate a buffer without putting it in the buffer list. */
-     newbuf = buflist_new(NULL, NULL, (linenr_T)1, BLN_DUMMY);
-@@ -3299,13 +3303,8 @@
-     /* Init the options. */
-     buf_copy_options(newbuf, BCO_ENTER | BCO_NOHELP);
- 
--#ifdef FEAT_AUTOCMD
-     /* set curwin/curbuf to buf and save a few things */
-     aucmd_prepbuf(&aco, newbuf);
--#else
--    curbuf = newbuf;
--    curwin->w_buffer = newbuf;
--#endif
- 
-     /* Need to set the filename for autocommands. */
-     (void)setfname(curbuf, fname, NULL, FALSE);
-@@ -3336,13 +3335,8 @@
- 	}
-     }
- 
--#ifdef FEAT_AUTOCMD
-     /* restore curwin/curbuf and a few other things */
-     aucmd_restbuf(&aco);
--#else
--    curbuf = old_curbuf;
--    curwin->w_buffer = old_curbuf;
--#endif
- 
-     if (!buf_valid(newbuf))
- 	return NULL;
-diff -Naur vim70.orig/src/screen.c vim70/src/screen.c
---- vim70.orig/src/screen.c	2006-05-05 03:13:55.000000000 -0700
-+++ vim70/src/screen.c	2006-07-14 10:50:30.000000000 -0700
-@@ -2612,7 +2612,8 @@
- #ifdef FEAT_LINEBREAK
-     int		need_showbreak = FALSE;
- #endif
--#if defined(FEAT_SIGNS) || (defined(FEAT_QUICKFIX) && defined(FEAT_WINDOWS))
-+#if defined(FEAT_SIGNS) || (defined(FEAT_QUICKFIX) && defined(FEAT_WINDOWS)) \
-+	|| defined(FEAT_SYN_HL) || defined(FEAT_DIFF)
- # define LINE_ATTR
-     int		line_attr = 0;		/* atrribute for the whole line */
- #endif
-@@ -2626,7 +2627,7 @@
-     int		prev_c = 0;		/* previous Arabic character */
-     int		prev_c1 = 0;		/* first composing char for prev_c */
- #endif
--#if defined(FEAT_DIFF) || defined(LINE_ATTR)
-+#if defined(LINE_ATTR)
-     int		did_line_attr = 0;
- #endif
- 
-@@ -4116,17 +4117,12 @@
- 		    --ptr;	    /* put it back at the NUL */
- 		}
- #endif
--#if defined(FEAT_DIFF) || defined(LINE_ATTR)
-+#if defined(LINE_ATTR)
- 		else if ((
- # ifdef FEAT_DIFF
--			    diff_hlf != (hlf_T)0
--#  ifdef LINE_ATTR
--			    ||
--#  endif
-+			    diff_hlf != (hlf_T)0 ||
- # endif
--# ifdef LINE_ATTR
- 			    line_attr != 0
--# endif
- 			) && (
- # ifdef FEAT_RIGHTLEFT
- 			    wp->w_p_rl ? (col >= 0) :
-@@ -4237,7 +4233,7 @@
- 	 * At end of the text line or just after the last character.
- 	 */
- 	if (c == NUL
--#if defined(FEAT_DIFF) || defined(LINE_ATTR)
-+#if defined(LINE_ATTR)
- 		|| did_line_attr == 1
- #endif
- 		)
-@@ -4258,7 +4254,7 @@
- 				|| prevcol == (long)match_hl[0].startcol
- 				|| prevcol == (long)match_hl[1].startcol
- 				|| prevcol == (long)match_hl[2].startcol)
--# if defined(FEAT_DIFF) || defined(LINE_ATTR)
-+# if defined(LINE_ATTR)
- 			    && did_line_attr <= 1
- # endif
- 			   )
-@@ -7133,6 +7129,12 @@
- 	return;
-     entered = TRUE;
- 
-+    /*
-+     * Note that the window sizes are updated before reallocating the arrays,
-+     * thus we must not redraw here!
-+     */
-+    ++RedrawingDisabled;
-+
-     win_new_shellsize();    /* fit the windows in the new sized shell */
- 
-     comp_col();		/* recompute columns for shown command and ruler */
-@@ -7367,6 +7369,7 @@
- #endif
- 
-     entered = FALSE;
-+    --RedrawingDisabled;
- 
- #ifdef FEAT_AUTOCMD
-     if (starting == 0)
-diff -Naur vim70.orig/src/spell.c vim70/src/spell.c
---- vim70.orig/src/spell.c	2006-05-05 00:49:58.000000000 -0700
-+++ vim70/src/spell.c	2006-08-09 08:31:46.000000000 -0700
-@@ -2108,7 +2108,8 @@
- 	 * possible. */
- 	STRCPY(buf, line);
- 	if (lnum < wp->w_buffer->b_ml.ml_line_count)
--	    spell_cat_line(buf + STRLEN(buf), ml_get(lnum + 1), MAXWLEN);
-+	    spell_cat_line(buf + STRLEN(buf),
-+			  ml_get_buf(wp->w_buffer, lnum + 1, FALSE), MAXWLEN);
- 
- 	p = buf + skip;
- 	endp = buf + len;
-@@ -10070,6 +10071,7 @@
- 
- 	/* List the suggestions. */
- 	msg_start();
-+	msg_row = Rows - 1;	/* for when 'cmdheight' > 1 */
- 	lines_left = Rows;	/* avoid more prompt */
- 	vim_snprintf((char *)IObuff, IOSIZE, _("Change \"%.*s\" to:"),
- 						sug.su_badlen, sug.su_badptr);
-diff -Naur vim70.orig/src/structs.h vim70/src/structs.h
---- vim70.orig/src/structs.h	2006-04-09 10:57:46.000000000 -0700
-+++ vim70/src/structs.h	2006-08-19 16:39:02.000000000 -0700
-@@ -2213,18 +2213,20 @@
- 
- /*
-  * Struct to save values in before executing autocommands for a buffer that is
-- * not the current buffer.
-+ * not the current buffer.  Without FEAT_AUTOCMD only "curbuf" is remembered.
-  */
- typedef struct
- {
-     buf_T	*save_buf;	/* saved curbuf */
-+#ifdef FEAT_AUTOCMD
-     buf_T	*new_curbuf;	/* buffer to be used */
-     win_T	*save_curwin;	/* saved curwin, NULL if it didn't change */
-     win_T	*new_curwin;	/* new curwin if save_curwin != NULL */
-     pos_T	save_cursor;	/* saved cursor pos of save_curwin */
-     linenr_T	save_topline;	/* saved topline of save_curwin */
--#ifdef FEAT_DIFF
-+# ifdef FEAT_DIFF
-     int		save_topfill;	/* saved topfill of save_curwin */
-+# endif
- #endif
- } aco_save_T;
- 
-diff -Naur vim70.orig/src/term.c vim70/src/term.c
---- vim70.orig/src/term.c	2006-05-03 10:34:57.000000000 -0700
-+++ vim70/src/term.c	2006-08-19 16:40:11.000000000 -0700
-@@ -4783,6 +4783,14 @@
- 		return -1;
- 	    current_menu = (vimmenu_T *)val;
- 	    slen += num_bytes;
-+
-+	    /* The menu may have been deleted right after it was used, check
-+	     * for that. */
-+	    if (check_menu_pointer(root_menu, current_menu) == FAIL)
-+	    {
-+		key_name[0] = KS_EXTRA;
-+		key_name[1] = (int)KE_IGNORE;
-+	    }
- 	}
- # endif
- # ifdef FEAT_GUI_TABLINE
-diff -Naur vim70.orig/src/undo.c vim70/src/undo.c
---- vim70.orig/src/undo.c	2006-04-21 02:30:59.000000000 -0700
-+++ vim70/src/undo.c	2006-07-14 10:51:11.000000000 -0700
-@@ -84,7 +84,6 @@
- static void u_unch_branch __ARGS((u_header_T *uhp));
- static u_entry_T *u_get_headentry __ARGS((void));
- static void u_getbot __ARGS((void));
--static int undo_allowed __ARGS((void));
- static int u_savecommon __ARGS((linenr_T, linenr_T, linenr_T));
- static void u_doit __ARGS((int count));
- static void u_undoredo __ARGS((int undo));
-@@ -196,7 +195,7 @@
-  * Return TRUE when undo is allowed.  Otherwise give an error message and
-  * return FALSE.
-  */
--    static int
-+    int
- undo_allowed()
- {
-     /* Don't allow changes when 'modifiable' is off.  */
-diff -Naur vim70.orig/src/version.c vim70/src/version.c
---- vim70.orig/src/version.c	2006-05-03 00:50:42.000000000 -0700
-+++ vim70/src/version.c	2006-08-27 12:48:28.000000000 -0700
-@@ -667,6 +667,126 @@
- static int included_patches[] =
- {   /* Add new patch number below this line */
- /**/
-+    66,
-+/**/
-+    64,
-+/**/
-+    63,
-+/**/
-+    62,
-+/**/
-+    61,
-+/**/
-+    60,
-+/**/
-+    59,
-+/**/
-+    58,
-+/**/
-+    56,
-+/**/
-+    55,
-+/**/
-+    54,
-+/**/
-+    53,
-+/**/
-+    52,
-+/**/
-+    51,
-+/**/
-+    50,
-+/**/
-+    49,
-+/**/
-+    48,
-+/**/
-+    47,
-+/**/
-+    46,
-+/**/
-+    44,
-+/**/
-+    43,
-+/**/
-+    42,
-+/**/
-+    41,
-+/**/
-+    40,
-+/**/
-+    39,
-+/**/
-+    38,
-+/**/
-+    37,
-+/**/
-+    36,
-+/**/
-+    35,
-+/**/
-+    34,
-+/**/
-+    33,
-+/**/
-+    31,
-+/**/
-+    30,
-+/**/
-+    29,
-+/**/
-+    28,
-+/**/
-+    26,
-+/**/
-+    25,
-+/**/
-+    24,
-+/**/
-+    23,
-+/**/
-+    22,
-+/**/
-+    21,
-+/**/
-+    20,
-+/**/
-+    19,
-+/**/
-+    18,
-+/**/
-+    17,
-+/**/
-+    16,
-+/**/
-+    15,
-+/**/
-+    14,
-+/**/
-+    13,
-+/**/
-+    12,
-+/**/
-+    11,
-+/**/
-+    10,
-+/**/
-+    9,
-+/**/
-+    8,
-+/**/
-+    7,
-+/**/
-+    6,
-+/**/
-+    4,
-+/**/
-+    3,
-+/**/
-+    2,
-+/**/
-+    1,
-+/**/
-     0
- };
- 
-diff -Naur vim70.orig/src/vim.h vim70/src/vim.h
---- vim70.orig/src/vim.h	2006-04-30 08:32:38.000000000 -0700
-+++ vim70/src/vim.h	2006-07-14 08:51:21.000000000 -0700
-@@ -585,7 +585,6 @@
- #define INSERT		0x10	/* Insert mode */
- #define LANGMAP		0x20	/* Language mapping, can be combined with
- 				   INSERT and CMDLINE */
--#define MAP_ALL_MODES	0x3f	/* all mode bits used for mapping */
- 
- #define REPLACE_FLAG	0x40	/* Replace mode flag */
- #define REPLACE		(REPLACE_FLAG + INSERT)
-@@ -605,6 +604,9 @@
- #define CONFIRM		0x800	/* ":confirm" prompt */
- #define SELECTMODE	0x1000	/* Select mode, only for mappings */
- 
-+#define MAP_ALL_MODES	(0x3f | SELECTMODE)	/* all mode bits used for
-+						 * mapping */
-+
- /* directions */
- #define FORWARD			1
- #define BACKWARD		(-1)
-@@ -1983,7 +1985,7 @@
- /* values for vim_handle_signal() that are not a signal */
- #define SIGNAL_BLOCK	-1
- #define SIGNAL_UNBLOCK  -2
--#if !defined(UNIX) && !defined(VMS)
-+#if !defined(UNIX) && !defined(VMS) && !defined(OS2)
- # define vim_handle_signal(x) 0
- #endif
- 
-	
Index: patches/vim-7.0-fixes-12.patch
===================================================================
--- patches/vim-7.0-fixes-12.patch	(revision d28a23b8d22943835e3a279db1c51beef59d58bc)
+++ patches/vim-7.0-fixes-12.patch	(revision d28a23b8d22943835e3a279db1c51beef59d58bc)
@@ -0,0 +1,6503 @@
+Submitted By: Jim Gifford (jim at linuxfromscratch dot org)
+Date: 2006-09-11
+Initial Package Version: 7.0
+Origin: Upstream
+Upstream Status: Applied
+Description: Contains Patch 001-004, 006-026, 028-031, 033-044, 036-056,
+        058-064, 066-073, and 075-099  from Upstream
+        005, 027, 032, 045, 057, 066, and 074 are for the extras, Mac, or
+        Windows 32 only
+
+diff -Naur vim70.orig/configure vim70/configure
+--- vim70.orig/configure	2004-07-05 02:02:24.000000000 -0700
++++ vim70/configure	2006-08-09 08:37:06.000000000 -0700
+@@ -3,4 +3,4 @@
+ # This is just a stub for the Unix configure script, to provide support for
+ # doing "./configure" in the top Vim directory.
+ 
+-cd src && ./configure "$@"
++cd src && exec ./configure "$@"
+diff -Naur vim70.orig/runtime/autoload/ccomplete.vim vim70/runtime/autoload/ccomplete.vim
+--- vim70.orig/runtime/autoload/ccomplete.vim	2006-05-03 07:35:56.000000000 -0700
++++ vim70/runtime/autoload/ccomplete.vim	2006-07-14 08:51:21.000000000 -0700
+@@ -1,7 +1,7 @@
+ " Vim completion script
+ " Language:	C
+ " Maintainer:	Bram Moolenaar <Bram@vim.org>
+-" Last Change:	2006 May 03
++" Last Change:	2006 May 08
+ 
+ 
+ " This function is used for the 'omnifunc' option.
+@@ -458,7 +458,7 @@
+ " member.
+ function! s:StructMembers(typename, items, all)
+   " Todo: What about local structures?
+-  let fnames = join(map(tagfiles(), 'escape(v:val, " \\")'))
++  let fnames = join(map(tagfiles(), 'escape(v:val, " \\#%")'))
+   if fnames == ''
+     return []
+   endif
+diff -Naur vim70.orig/runtime/autoload/gzip.vim vim70/runtime/autoload/gzip.vim
+--- vim70.orig/runtime/autoload/gzip.vim	2006-03-31 07:12:15.000000000 -0800
++++ vim70/runtime/autoload/gzip.vim	2006-08-09 08:37:36.000000000 -0700
+@@ -1,6 +1,6 @@
+ " Vim autoload file for editing compressed files.
+ " Maintainer: Bram Moolenaar <Bram@vim.org>
+-" Last Change: 2006 Mar 31
++" Last Change: 2006 Jul 19
+ 
+ " These functions are used by the gzip plugin.
+ 
+@@ -127,9 +127,9 @@
+     let nmt = s:tempname(nm)
+     if rename(nm, nmt) == 0
+       if exists("b:gzip_comp_arg")
+-	call system(a:cmd . " " . b:gzip_comp_arg . " " . nmt)
++	call system(a:cmd . " " . b:gzip_comp_arg . " '" . nmt . "'")
+       else
+-	call system(a:cmd . " " . nmt)
++	call system(a:cmd . " '" . nmt . "'")
+       endif
+       call rename(nmt . "." . expand("<afile>:e"), nm)
+     endif
+diff -Naur vim70.orig/runtime/autoload/paste.vim vim70/runtime/autoload/paste.vim
+--- vim70.orig/runtime/autoload/paste.vim	2006-04-21 11:31:01.000000000 -0700
++++ vim70/runtime/autoload/paste.vim	2006-07-14 08:51:21.000000000 -0700
+@@ -1,6 +1,6 @@
+ " Vim support file to help with paste mappings and menus
+ " Maintainer:	Bram Moolenaar <Bram@vim.org>
+-" Last Change:	2006 Apr 21
++" Last Change:	2006 Jun 23
+ 
+ " Define the string to use for items that are present both in Edit, Popup and
+ " Toolbar menu.  Also used in mswin.vim and macmap.vim.
+@@ -12,7 +12,7 @@
+ if has("virtualedit")
+   let paste#paste_cmd = {'n': ":call paste#Paste()<CR>"}
+   let paste#paste_cmd['v'] = '"-c<Esc>' . paste#paste_cmd['n']
+-  let paste#paste_cmd['i'] = '<Esc>' . paste#paste_cmd['n'] . 'gi'
++  let paste#paste_cmd['i'] = 'x<BS><Esc>' . paste#paste_cmd['n'] . 'gi'
+ 
+   func! paste#Paste()
+     let ove = &ve
+diff -Naur vim70.orig/runtime/autoload/spellfile.vim vim70/runtime/autoload/spellfile.vim
+--- vim70.orig/runtime/autoload/spellfile.vim	2006-02-01 04:12:24.000000000 -0800
++++ vim70/runtime/autoload/spellfile.vim	2006-09-11 08:32:21.000000000 -0700
+@@ -1,9 +1,9 @@
+ " Vim script to download a missing spell file
+ " Maintainer:	Bram Moolenaar <Bram@vim.org>
+-" Last Change:	2006 Feb 01
++" Last Change:	2006 Aug 29
+ 
+ if !exists('g:spellfile_URL')
+-  let g:spellfile_URL = 'ftp://ftp.vim.org/pub/vim/unstable/runtime/spell'
++  let g:spellfile_URL = 'ftp://ftp.vim.org/pub/vim/runtime/spell'
+ endif
+ let s:spellfile_URL = ''    " Start with nothing so that s:donedict is reset.
+ 
+@@ -61,13 +61,13 @@
+     new
+     setlocal bin
+     echo 'Downloading ' . fname . '...'
+-    exe 'Nread ' g:spellfile_URL . '/' . fname
++    call spellfile#Nread(fname)
+     if getline(2) !~ 'VIMspell'
+       " Didn't work, perhaps there is an ASCII one.
+       g/^/d
+       let fname = a:lang . '.ascii.spl'
+       echo 'Could not find it, trying ' . fname . '...'
+-      exe 'Nread ' g:spellfile_URL . '/' . fname
++      call spellfile#Nread(fname)
+       if getline(2) !~ 'VIMspell'
+ 	echo 'Sorry, downloading failed'
+ 	bwipe!
+@@ -95,7 +95,7 @@
+ 	g/^/d
+ 	let fname = substitute(fname, '\.spl$', '.sug', '')
+ 	echo 'Downloading ' . fname . '...'
+-	exe 'Nread ' g:spellfile_URL . '/' . fname
++	call spellfile#Nread(fname)
+ 	if getline(2) !~ 'VIMsug'
+ 	  echo 'Sorry, downloading failed'
+ 	else
+@@ -109,3 +109,15 @@
+     bwipe
+   endif
+ endfunc
++
++" Read "fname" from the server.
++function! spellfile#Nread(fname)
++  if g:spellfile_URL =~ '^ftp://'
++    " for an ftp server use a default login and password to avoid a prompt
++    let machine = substitute(g:spellfile_URL, 'ftp://\([^/]*\).*', '\1', '')
++    let dir = substitute(g:spellfile_URL, 'ftp://[^/]*/\(.*\)', '\1', '')
++    exe 'Nread "' . machine . ' anonymous vim7user ' . dir . '/' . a:fname . '"'
++  else
++    exe 'Nread ' g:spellfile_URL . '/' . a:fname
++  endif
++endfunc
+diff -Naur vim70.orig/runtime/plugin/matchparen.vim vim70/runtime/plugin/matchparen.vim
+--- vim70.orig/runtime/plugin/matchparen.vim	2006-04-27 06:31:26.000000000 -0700
++++ vim70/runtime/plugin/matchparen.vim	2006-09-11 09:04:35.000000000 -0700
+@@ -1,6 +1,6 @@
+ " Vim plugin for showing matching parens
+ " Maintainer:  Bram Moolenaar <Bram@vim.org>
+-" Last Change: 2006 Apr 27
++" Last Change: 2006 Sep 09
+ 
+ " Exit quickly when:
+ " - this plugin was already loaded (or disabled)
+@@ -44,7 +44,7 @@
+   let before = 0
+ 
+   let c = getline(c_lnum)[c_col - 1]
+-  let plist = split(&matchpairs, ':\|,')
++  let plist = split(&matchpairs, '.\zs[:,]')
+   let i = index(plist, c)
+   if i < 0
+     " not found, in Insert mode try character before the cursor
+@@ -90,19 +90,19 @@
+   " Find the match.  When it was just before the cursor move it there for a
+   " moment.
+   if before > 0
+-    let save_cursor = getpos('.')
++    let save_cursor = winsaveview()
+     call cursor(c_lnum, c_col - before)
+   endif
+ 
+   " When not in a string or comment ignore matches inside them.
+   let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' .
+-	\ '=~?  "string\\|comment"'
++	\ '=~?  "string\\|character\\|singlequote\\|comment"'
+   execute 'if' s_skip '| let s_skip = 0 | endif'
+ 
+   let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
+ 
+   if before > 0
+-    call setpos('.', save_cursor)
++    call winrestview(save_cursor)
+   endif
+ 
+   " If a match is found setup match highlighting.
+diff -Naur vim70.orig/runtime/scripts.vim vim70/runtime/scripts.vim
+--- vim70.orig/runtime/scripts.vim	2006-03-28 11:30:49.000000000 -0800
++++ vim70/runtime/scripts.vim	2006-08-09 08:38:04.000000000 -0700
+@@ -1,7 +1,7 @@
+ " Vim support file to detect file types in scripts
+ "
+ " Maintainer:	Bram Moolenaar <Bram@vim.org>
+-" Last change:	2006 Mar 28
++" Last change:	2006 Jul 08
+ 
+ " This file is called by an autocommand for every file that has just been
+ " loaded into a buffer.  It checks if the type of file can be recognized by
+@@ -54,6 +54,12 @@
+     let s:name = substitute(s:line1, '^#!\s*\S*[/\\]\(\i\+\).*', '\1', '')
+   endif
+ 
++  " tcl scripts may have #!/bin/sh in the first line and "exec wish" in the
++  " third line.  Suggested by Steven Atkinson.
++  if getline(3) =~ '^exec wish'
++    let s:name = 'wish'
++  endif
++
+   " Bourne-like shell scripts: bash bash2 ksh ksh93 sh
+   if s:name =~ '^\(bash\d*\|\|ksh\d*\|sh\)\>'
+     call SetFileTypeSH(s:line1)	" defined in filetype.vim
+diff -Naur vim70.orig/runtime/tutor/Makefile vim70/runtime/tutor/Makefile
+--- vim70.orig/runtime/tutor/Makefile	2004-06-07 07:32:39.000000000 -0700
++++ vim70/runtime/tutor/Makefile	2006-09-11 09:26:16.000000000 -0700
+@@ -2,8 +2,13 @@
+ #
+ # The Japanese tutor exists in three encodings.  Use the UTF-8 version as the
+ # original and create the others with conversion.
++#
++# Similarly for Russian and Korean
+ 
+-all: tutor.ja.sjis tutor.ja.euc tutor.ko.euc
++all: tutor.ja.sjis tutor.ja.euc \
++	tutor.ko.euc \
++	tutor.ru tutor.ru.cp1251 \
++	tutor.gr tutor.gr.cp737
+ 
+ tutor.ja.sjis: tutor.ja.utf-8
+ 	nkf -WXs tutor.ja.utf-8 > tutor.ja.sjis
+@@ -13,3 +18,15 @@
+ 
+ tutor.ko.euc: tutor.ko.utf-8
+ 	iconv -f UTF-8 -t EUC-KR tutor.ko.utf-8 > tutor.ko.euc
++
++tutor.ru: tutor.ru.utf-8
++	iconv -f UTF-8 -t KOI8-R tutor.ru.utf-8 > tutor.ru
++
++tutor.ru.cp1251: tutor.ru.utf-8
++	iconv -f UTF-8 -t cp1251 tutor.ru.utf-8 > tutor.ru.cp1251
++
++tutor.gr: tutor.gr.utf-8
++	iconv -f UTF-8 -t ISO-8859-7 tutor.gr.utf-8 > tutor.gr
++
++tutor.gr.cp737: tutor.gr.utf-8
++	iconv -f UTF-8 -t cp737 tutor.gr.utf-8 > tutor.gr.cp737
+diff -Naur vim70.orig/runtime/tutor/tutor.gr.utf-8 vim70/runtime/tutor/tutor.gr.utf-8
+--- vim70.orig/runtime/tutor/tutor.gr.utf-8	1969-12-31 16:00:00.000000000 -0800
++++ vim70/runtime/tutor/tutor.gr.utf-8	2006-09-11 09:26:16.000000000 -0700
+@@ -0,0 +1,815 @@
++===============================================================================
++=    Î. Î±Î» Ï. Ï. Î® Ï Îž Î± Ï. Îµ    Ï. Ï. Î¿   V I M   T u t o r    -    Î.ÎºÎŽÎ¿Ï.Î· 1.5     =
++===============================================================================
++
++     Î. Vim ÎµÎ¯ÎœÎ±Î¹ Î­ÎœÎ±Ï. Ï.Î±ÎœÎ¯Ï.Ï.Ï.ÏÎ¿Ï. Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î·Ï. Ï.Î¿Ï. Î­Ï.ÎµÎ¹ Ï.Î¿Î»Î»Î­Ï. ÎµÎœÏ.Î¿Î»Î­Ï., Ï.Î¬ÏÎ±
++     Ï.Î¿Î»Î»Î­Ï. Î³Î¹Î± ÎœÎ± ÎµÎŸÎ·Î³Î®Ï.Î¿Ï.ÎŒÎµ Ï.Îµ ÎŒÎ¯Î± Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î· Ï.Ï.Ï.Ï. Î±Ï.Ï.Î®. Î.Ï.Ï.Î® Î· Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î·
++     Ï.Ï.ÎµÎŽÎ¹Î¬Ï.Ï.Î·ÎºÎµ Î³Î¹Î± ÎœÎ± Ï.ÎµÏÎ¹Î³ÏÎ¬Ï.ÎµÎ¹ Î¹ÎºÎ±ÎœÎ¿Ï.Î¿Î¹Î·Ï.Î¹ÎºÎ¬ Ï.Î¹Ï. ÎµÎœÏ.Î¿Î»Î­Ï. Ï.Î¿Ï. ÎžÎ± Ï.Î±Ï.
++     ÎºÎ¬ÎœÎ¿Ï.Îœ ÎœÎ± Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹ÎµÎ¯Ï.Îµ ÎµÏÎºÎ¿Î»Î± Ï.Î¿Îœ Vim Ï.Î±Îœ Î­ÎœÎ±Îœ Î³ÎµÎœÎ¹ÎºÎ®Ï. Ï.ÏÎ®Ï.Î·Ï. Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î·.
++
++     Î. ÎºÎ±Ï.Î¬ Ï.ÏÎ¿Ï.Î­Î³Î³Î¹Ï.Î· Ï.ÏÏ.ÎœÎ¿Ï. Ï.Î¿Ï. Î±Ï.Î±Î¹Ï.ÎµÎ¯Ï.Î±Î¹ Î³Î¹Î± ÎœÎ± Î¿Î»Î¿ÎºÎ»Î·ÏÏ.Ï.ÎµÏ.Îµ Ï.Î·Îœ Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î·
++     ÎµÎ¯ÎœÎ±Î¹ 25-30 Î»ÎµÏ.Ï.Î¬, ÎµÎŸÎ±ÏÏ.Ï.ÎœÏ.Î±Ï. Î±Ï.Ï. Ï.Î¿ Ï.Ï.Ï.Î¿ Ï.ÏÏ.ÎœÎ¿ ÎžÎ± ÎŸÎ¿ÎŽÎ­Ï.ÎµÏ.Îµ Î³Î¹Î±
++     Ï.ÎµÎ¹ÏÎ±ÎŒÎ±Ï.Î¹Ï.ÎŒÎ¿ÏÏ..
++
++     Î.Î¹ ÎµÎœÏ.Î¿Î»Î­Ï. Ï.Ï.Î± ÎŒÎ±ÎžÎ®ÎŒÎ±Ï.Î± ÎžÎ± Ï.ÏÎ¿Ï.Î¿Ï.Î¿Î¹Î®Ï.Î¿Ï.Îœ Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿. Î.Î·ÎŒÎ¹Î¿Ï.ÏÎ³Î®Ï.Ï.Îµ Î­ÎœÎ±
++     Î±ÎœÏ.Î¯Î³ÏÎ±Ï.Î¿ Î±Ï.Ï.Î¿Ï Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï. Î³Î¹Î± ÎœÎ± ÎµÎŸÎ±Ï.ÎºÎ·ÎžÎµÎ¯Ï.Îµ (Î±Îœ ÎŸÎµÎºÎ¹ÎœÎ®Ï.Î±Ï.Îµ Ï.Î¿
++     "Vimtutor" Î±Ï.Ï.Ï. ÎµÎ¯ÎœÎ±Î¹ Î®ÎŽÎ· Î­ÎœÎ± Î±ÎœÏ.Î¯Î³ÏÎ±Ï.Î¿).
++
++     Î.Î¯ÎœÎ±Î¹ Ï.Î·ÎŒÎ±ÎœÏ.Î¹ÎºÏ. ÎœÎ± ÎžÏ.ÎŒÎ¬Ï.Ï.Îµ Ï.Ï.Î¹ Î±Ï.Ï.Î® Î· Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î· ÎµÎ¯ÎœÎ±Î¹ Î¿ÏÎ³Î±ÎœÏ.ÎŒÎ­ÎœÎ· Î­Ï.Ï.Î¹
++     Ï.Ï.Ï.Îµ ÎœÎ± ÎŽÎ¹ÎŽÎ¬Ï.ÎºÎµÎ¹ ÎŒÎ­Ï.Ï. Ï.Î·Ï. Ï.ÏÎ®Ï.Î·Ï.. Î.Ï.Ï.Ï. Ï.Î·ÎŒÎ±Î¯ÎœÎµÎ¹ Ï.Ï.Î¹ Ï.ÏÎµÎ¹Î¬Î¶ÎµÏ.Î±Î¹ ÎœÎ±
++     ÎµÎºÏ.ÎµÎ»ÎµÎ¯Ï.Îµ Ï.Î¹Ï. ÎµÎœÏ.Î¿Î»Î­Ï. Î³Î¹Î± ÎœÎ± Ï.Î¹Ï. ÎŒÎ¬ÎžÎµÏ.Îµ Ï.Ï.Ï.Ï.Î¬. Î.Îœ ÎŽÎ¹Î±Î²Î¬Î¶ÎµÏ.Îµ ÎŒÏ.ÎœÎ¿ Ï.Î¿
++     ÎºÎµÎ¯ÎŒÎµÎœÎ¿, ÎžÎ± Ï.Î¹Ï. ÎŸÎµÏ.Î¬Ï.ÎµÏ.Îµ!
++
++     Î€Ï.ÏÎ±, Î²ÎµÎ²Î±Î¹Ï.ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¹ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ Shift-Lock Î.Î.Î ÎµÎ¯ÎœÎ±Î¹ Ï.Î±Ï.Î·ÎŒÎ­ÎœÎ¿ ÎºÎ±Î¹
++     Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ j Î±ÏÎºÎµÏ.Î­Ï. Ï.Î¿ÏÎ­Ï. Î³Î¹Î± ÎœÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ®Ï.ÎµÏ.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Î­Ï.Ï.Î¹
++     Ï.Ï.Ï.Îµ Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 1.1 ÎœÎ± Î³ÎµÎŒÎ¯Ï.ÎµÎ¹ Ï.Î»Î®ÏÏ.Ï. Ï.Î·Îœ Î¿ÎžÏ.ÎœÎ·.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		      Î.Î¬ÎžÎ·ÎŒÎ± 1.1:  Î.Î.Î€Î.Î.Î.ÎÎ.ÎÎ€Î.Î£ Î€Î.Î Î.Î¡Î.Î.Î.Î.
++
++  ** Î.Î¹Î± ÎœÎ± ÎºÎ¹ÎœÎ®Ï.ÎµÏ.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±, Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î± Ï.Î»Î®ÎºÏ.ÏÎ± h,j,k,l Ï.Ï.Ï.Ï. ÎŽÎµÎ¯Ï.ÎœÎµÏ.Î±Î¹. **
++	     ^
++	     k	      Hint: Î€Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ h ÎµÎ¯ÎœÎ±Î¹ Î±ÏÎ¹Ï.Ï.ÎµÏÎ¬ ÎºÎ±Î¹ ÎºÎ¹ÎœÎµÎ¯ Ï.Ï.' Î±ÏÎ¹Ï.Ï.ÎµÏÎ¬.
++       < h	 l >	    Î€Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ l ÎµÎ¯ÎœÎ±Î¹ ÎŽÎµÎŸÎ¹Î¬ ÎºÎ±Î¹ ÎºÎ¹ÎœÎµÎ¯ Ï.Ï.Î± ÎŽÎµÎŸÎ¹Î¬.
++	     j		    Î€Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ j ÎŒÎ¿Î¹Î¬Î¶ÎµÎ¹ ÎŒÎµ Î²ÎµÎ»Î¬ÎºÎ¹ Ï.ÏÎ¿Ï. Ï.Î± ÎºÎ¬Ï.Ï..
++	     v
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.ÏÎ¹Î³ÏÏÏ. Ï.Ï.Î·Îœ Î¿ÎžÏ.ÎœÎ· ÎŒÎ­Ï.ÏÎ¹ ÎœÎ± ÎœÎ¿Î¹Ï.ÎžÎµÏ.Îµ Î¬ÎœÎµÏ.Î±.
++
++  2. Î.ÏÎ±Ï.Î®Ï.Ï.Îµ Ï.Î±Ï.Î·ÎŒÎ­ÎœÎ¿ Ï.Î¿ ÎºÎ¬Ï.Ï. Ï.Î»Î®ÎºÏ.ÏÎ¿ (j) ÎŒÎ­Ï.ÏÎ¹ ÎœÎ± ÎµÏ.Î±ÎœÎ±Î»Î·Ï.ÎžÎµÎ¯.
++---> Î€Ï.ÏÎ± ÎŸÎ­ÏÎµÏ.Îµ Ï.Ï.Ï. ÎœÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¿ ÎµÏ.Ï.ÎŒÎµÎœÎ¿ ÎŒÎ¬ÎžÎ·ÎŒÎ±.
++
++  3. Î§ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Ï.ÎœÏ.Î±Ï. Ï.Î¿ ÎºÎ¬Ï.Ï. Ï.Î»Î®ÎºÏ.ÏÎ¿, ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 1.2.
++
++Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î.Îœ Î±ÎŒÏ.Î¹Î²Î¬Î»Î»ÎµÏ.Îµ Î³Î¹Î± ÎºÎ¬Ï.Î¹ Ï.Î¿Ï. Ï.Î±Ï.Î®Ï.Î±Ï.Îµ, Ï.Î±Ï.Î®Ï.Ï.Îµ <ESC> Î³Î¹Î± ÎœÎ± Î²ÏÎµÎžÎµÎ¯Ï.Îµ
++	  Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·. Î.ÎµÏ.Î¬ Ï.Î±Ï.Î®Ï.Ï.Îµ ÎŸÎ±ÎœÎ¬ Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î® Ï.Î¿Ï. ÎžÎ­Î»Î±Ï.Îµ.
++
++Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î€Î± Ï.Î»Î®ÎºÏ.ÏÎ± Ï.Î¿Ï. ÎŽÏÎ¿ÎŒÎ­Î± ÎžÎ± Ï.ÏÎ­Ï.ÎµÎ¹ ÎµÏ.Î¯Ï.Î·Ï. ÎœÎ± ÎŽÎ¿Ï.Î»ÎµÏÎ¿Ï.Îœ. Î.Î»Î»Î¬ ÎŒÎµ Ï.Î± hjkl
++	  ÎžÎ± ÎŒÏ.Î¿ÏÎµÎ¯Ï.Îµ ÎœÎ± ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Î¿Î»Ï Î³ÏÎ·Î³Î¿ÏÏ.Ï.ÎµÏÎ±, ÎŒÏ.Î»Î¹Ï. Ï.Î± Ï.Ï.ÎœÎ·ÎžÎ¯Ï.ÎµÏ.Îµ.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		Î.Î¬ÎžÎ·ÎŒÎ± 1.2:  Î.Î Î.Î.ÎÎ.ÎÎ€Î.Î£ Î.Î.Î. Î.Î.Î.Î.ÎÎ.ÎÎ€Î.Î£ Î£Î€Î.Î VIM
++
++  !! Î£Î.Î.Î.Î.Î©Î£Î.: Î ÏÎ¹Îœ ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ ÎºÎ¬Ï.Î¿Î¹Î¿ Î±Ï.Ï. Ï.Î± Î²Î®ÎŒÎ±Ï.Î±, ÎŽÎ¹Î±Î²Î¬Ï.Ï.Îµ Ï.Î»Î¿ Ï.Î¿ ÎŒÎ¬ÎžÎ·ÎŒÎ±!!
++
++  1. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ <ESC> (Î³Î¹Î± ÎœÎ± ÎµÎ¯Ï.Ï.Îµ Ï.Î¯Î³Î¿Ï.ÏÎ± Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·).
++
++  2. Î Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ:		:q! <ENTER>.
++
++---> Î.Ï.Ï.Ï. ÎµÎŸÎ­ÏÏ.ÎµÏ.Î±Î¹ Î±Ï.Ï. Ï.Î¿Îœ Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î· Î§Î©Î¡Î.Î£ ÎœÎ± Ï.Ï.Ï.ÎµÎ¹ Ï.Ï.Î¿Î¹ÎµÏ. Î±Î»Î»Î±Î³Î­Ï. Î­Ï.ÎµÏ.Îµ ÎºÎ¬ÎœÎµÎ¹.
++     Î.Îœ ÎžÎ­Î»ÎµÏ.Îµ ÎœÎ± Ï.Ï.Ï.ÎµÏ.Îµ Ï.Î¹Ï. Î±Î»Î»Î±Î³Î­Ï. ÎºÎ±Î¹ ÎœÎ± ÎµÎŸÎ­ÏÎžÎµÏ.Îµ Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ:
++	      :wq <ENTER>
++
++  3. Î.Ï.Î±Îœ ÎŽÎµÎ¯Ï.Îµ Ï.Î·Îœ Ï.ÏÎ¿Ï.ÏÎ¿Ï.Î® Ï.Î¿Ï. Ï.Î»Î¿Î¹Î¿Ï, Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î® ÎŒÎµ Ï.Î·Îœ Î¿Ï.Î¿Î¯Î±
++     ÎŒÏ.Î®ÎºÎ±Ï.Îµ Ï.Îµ Î±Ï.Ï.Î®Îœ Ï.Î·Îœ Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î·. Î.Ï.Î¿ÏÎµÎ¯ ÎœÎ± ÎµÎ¯ÎœÎ±Î¹:	vimtutor <ENTER>
++     Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ¬ ÎžÎ± Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î¿ÏÏ.Î±Ï.Îµ:			vim tutor <ENTER>
++
++---> 'vim' Ï.Î·ÎŒÎ±Î¯ÎœÎµÎ¹ ÎµÎ¹Ï.Î±Î³Ï.Î³Î® Ï.Ï.Î¿Îœ Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î· vim, 'tutor' ÎµÎ¯ÎœÎ±Î¹ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Ï.Î¿Ï.
++     ÎžÎ­Î»Î¿Ï.ÎŒÎµ ÎœÎ± ÎŽÎ¹Î¿ÏÎžÏ.Ï.Î¿Ï.ÎŒÎµ.
++
++  4. Î.Îœ Î­Ï.ÎµÏ.Îµ Î±Ï.Î¿ÎŒÎœÎ·ÎŒÎ¿ÎœÎµÏÏ.ÎµÎ¹ Î±Ï.Ï.Î¬ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± ÎºÎ±Î¹ Î­Ï.ÎµÏ.Îµ Î±Ï.Ï.Î¿Ï.ÎµÏ.Î¿Î¯ÎžÎ·Ï.Î·, ÎµÎºÏ.ÎµÎ»Î­Ï.Ï.Îµ
++     Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 1 Î­Ï.Ï. 3 Î³Î¹Î± ÎœÎ± Î²Î³ÎµÎ¯Ï.Îµ ÎºÎ±Î¹ ÎœÎ± ÎŒÏ.ÎµÎ¯Ï.Îµ ÎŸÎ±ÎœÎ¬ Ï.Ï.Î¿Îœ Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î·. Î.ÎµÏ.Î¬
++     ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ®Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎºÎ¬Ï.Ï. Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 1.3.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 1.3:  Î.Î.Î.Î¡Î.Î©Î£Î. Î.Î.Î.Î.Î.ÎÎ.Î¥ - Î.Î.Î.Î.Î¡Î.ÎŠÎ.
++
++   ** Î.Ï.Î¿ ÎµÎ¯Ï.Ï.Îµ Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Î±Ï.Î®Ï.Ï.Îµ  x  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î¿Îœ
++      Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î.Î¹Î± ÎœÎ± ÎŽÎ¹Î¿ÏÎžÏ.Ï.ÎµÏ.Îµ Ï.Î± Î»Î¬ÎžÎ·, ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Î¬ÎœÏ. Î±Ï.Ï.
++     Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Ï.Î¿Ï. ÎžÎ± ÎŽÎ¹Î±Î³ÏÎ±Ï.ÎµÎ¯.
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ x Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î¿Îœ Î±ÎœÎµÏ.Î¹ÎžÏÎŒÎ·Ï.Î¿ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±.
++
++  4. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 2 ÎŒÎ­Ï.ÏÎ¹ 4 ÎŒÎ­Ï.ÏÎ¹ Î· Ï.ÏÏ.Ï.Î±Ï.Î· ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Ï.Ï.Î®.
++
++---> The ccow jumpedd ovverr thhe mooon.
++
++  5. Î€Ï.ÏÎ± Ï.Î¿Ï. Î· Î³ÏÎ±ÎŒÎŒÎ® ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Ï.Ï.Î®, Ï.Î·Î³Î±Î¯ÎœÏ.Îµ Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 1.4.
++
++Î£Î.Î.Î.Î.Î©Î£Î.: Î.Î±ÎžÏ.Ï. ÎŽÎ¹Î±Ï.ÏÎ­Ï.ÎµÏ.Îµ Î±Ï.Ï.Î®Îœ Ï.Î·Îœ Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î·, Ï.ÏÎ¿Ï.Ï.Î±ÎžÎ®Ï.Ï.Îµ ÎœÎ± ÎŒÎ·Îœ
++	  Î±Ï.Î¿ÎŒÎœÎ·ÎŒÎ¿ÎœÎµÏÎµÏ.Îµ, ÎŒÎ±ÎžÎ±Î¯ÎœÎµÏ.Îµ ÎŒÎµ Ï.Î· Ï.ÏÎ®Ï.Î·.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 1.4: Î.Î.Î.Î¡Î.Î©Î£Î. Î.Î.Î.Î.Î.ÎÎ.Î¥ - Î Î.Î¡Î.Î.Î.Î.Î.Î.
++
++ ** Î.Ï.Î¿ ÎµÎ¯Ï.Ï.Îµ Ï.Îµ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Î±Ï.Î®Ï.Ï.Îµ  i  Î³Î¹Î± ÎœÎ± Ï.Î±ÏÎµÎŒÎ²Î¬Î»Î»ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î.Î¹Î± ÎœÎ± ÎºÎ¬ÎœÎµÏ.Îµ Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î¯ÎŽÎ¹Î± ÎŒÎµ Ï.Î·Îœ ÎŽÎµÏÏ.ÎµÏÎ·, ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ
++     ÎŽÏÎ¿ÎŒÎ­Î± Ï.Î¬ÎœÏ. Ï.Ï.Î¿Îœ Ï.ÏÏ.Ï.Î¿ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Î.Î.Î€Î. Î±Ï.Ï. Ï.Ï.Î¿Ï. ÎžÎ± Ï.Î±ÏÎµÎŒÎ²Î»Î·ÎžÎµÎ¯ Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿.
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿  i  ÎºÎ±Î¹ Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ Ï.Î¹Ï. Î±Ï.Î±ÏÎ±Î¯Ï.Î·Ï.ÎµÏ. Ï.ÏÎ¿Ï.ÎžÎ®ÎºÎµÏ..
++
++  4. Î.Î±ÎžÏ.Ï. ÎŽÎ¹Î¿ÏÎžÏ.ÎœÎµÏ.Îµ ÎºÎ¬ÎžÎµ Î»Î¬ÎžÎ¿Ï. Ï.Î±Ï.Î®Ï.Ï.Îµ <ESC> Î³Î¹Î± ÎœÎ± ÎµÏ.Î¹Ï.Ï.ÏÎ­Ï.ÎµÏ.Îµ Ï.Ï.Î·Îœ
++     Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 2 ÎŒÎ­Ï.ÏÎ¹ 4 Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î¿ÏÎžÏ.Ï.ÎµÏ.Îµ
++     Ï.Î·Îœ Ï.ÏÏ.Ï.Î±Ï.Î·.
++
++---> There is text misng this .
++---> There is some text missing from this line.
++
++  5. Î.Ï.Î±Îœ ÎµÎ¯Ï.Ï.Îµ Î¬ÎœÎµÏ.Î¿Î¹ ÎŒÎµ Ï.Î·Îœ Ï.Î±ÏÎµÎŒÎ²Î¿Î»Î® ÎºÎµÎ¹ÎŒÎ­ÎœÎ¿Ï. ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î·Îœ
++     Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.ÎµÏÎ¯Î»Î·Ï.Î·.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 1 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1. Î. ÎŽÏÎ¿ÎŒÎ­Î±Ï. ÎºÎ¹ÎœÎµÎ¯Ï.Î±Î¹ Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Ï.ÎœÏ.Î±Ï. ÎµÎ¯Ï.Îµ Ï.Î± Ï.Î»Î®ÎºÏ.ÏÎ± ÎŽÏÎ¿ÎŒÎ­Î± Î® Ï.Î± hjkl.
++	 h (Î±ÏÎ¹Ï.Ï.Î­ÏÎ±)	j (ÎºÎ¬Ï.Ï.)	k (Ï.Î¬ÎœÏ.)	l (ÎŽÎµÎŸÎ¹Î¬)
++
++  2. Î.Î¹Î± ÎœÎ± ÎŒÏ.ÎµÎ¯Ï.Îµ Ï.Ï.Î¿Îœ Vim (Î±Ï.Ï. Ï.Î·Îœ Ï.ÏÎ¿Ï.ÏÎ¿Ï.Î® %) Î³ÏÎ¬Ï.Ï.Îµ:  vim Î.Î¡Î§Î.Î.Î. <ENTER>
++
++  3. Î.Î¹Î± ÎœÎ± Î²Î³ÎµÎ¯Ï.Îµ Î³ÏÎ¬Ï.Ï.Îµ:  <ESC>   :q!   <ENTER>   Î³Î¹Î± Î±Ï.Ï.ÏÏÎ¹Ï.Î· Ï.Ï.Îœ Î±Î»Î»Î±Î³Ï.Îœ.
++		 Î. Î³ÏÎ¬Ï.Ï.Îµ:  <ESC>   :wq   <ENTER>   Î³Î¹Î± Î±Ï.Î¿ÎžÎ®ÎºÎµÏ.Ï.Î· Ï.Ï.Îœ Î±Î»Î»Î±Î³Ï.Îœ.
++
++  4. Î.Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Î­ÎœÎ±Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Îµ
++     Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Î±Ï.Î®Ï.Ï.Îµ:  x
++
++  5. Î.Î¹Î± ÎœÎ± ÎµÎ¹Ï.Î¬Î³ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ ÎµÎ¯Ï.Ï.Îµ Ï.Îµ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î³ÏÎ¬Ï.Ï.Îµ:
++	 i     Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿	<ESC>
++
++Î£Î.Î.Î.Î.Î©Î£Î.: Î Î±Ï.Ï.ÎœÏ.Î±Ï. <ESC> ÎžÎ± Ï.Î¿Ï.Î¿ÎžÎµÏ.Î·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î® ÎžÎ±
++	  Î±ÎºÏ.ÏÏ.Ï.ÎµÏ.Îµ ÎŒÎ¯Î± Î±ÎœÎµÏ.Î¹ÎžÏÎŒÎ·Ï.Î· ÎºÎ±Î¹ ÎŒÎµÏÎ¹ÎºÏ.Ï. Î¿Î»Î¿ÎºÎ»Î·ÏÏ.ÎŒÎ­ÎœÎ· ÎµÎœÏ.Î¿Î»Î®.
++
++Î€Ï.ÏÎ± Ï.Ï.ÎœÎµÏ.Î¯Ï.Ï.Îµ ÎŒÎµ Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 2.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Î.Î¬ÎžÎ·ÎŒÎ± 2.1: Î.ÎÎ€Î.Î.Î.Î£ Î.Î.Î.Î.Î¡Î.ÎŠÎ.Î£
++
++	 ** Î.ÏÎ¬Ï.Ï.Îµ  dw  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. ÎŒÎ¯Î±Ï. Î»Î­ÎŸÎ·Ï.. **
++
++  1. Î Î±Ï.Î®Ï.Ï.Îµ  <ESC>  Î³Î¹Î± ÎœÎ± Î²ÎµÎ²Î±Î¹Ï.ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¹ ÎµÎ¯Ï.Ï.Îµ Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·.
++
++  2. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  3. Î Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Î±ÏÏ.Î® Ï.Î·Ï. Î»Î­ÎŸÎ·Ï. Ï.Î¿Ï. Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ±Ï.ÎµÎ¯.
++
++  4. Î.ÏÎ¬Ï.Ï.Îµ  dw  Î³Î¹Î± ÎœÎ± ÎºÎ¬ÎœÎµÏ.Îµ Ï.Î·Îœ Î»Î­ÎŸÎ· ÎœÎ± ÎµÎŸÎ±Ï.Î±ÎœÎ¹Ï.Ï.ÎµÎ¯.
++
++Î£Î.Î.Î.Î.Î©Î£Î.: Î€Î± Î³ÏÎ¬ÎŒÎŒÎ±Ï.Î± dw ÎžÎ± ÎµÎŒÏ.Î±ÎœÎ¹Ï.Ï.Î¿ÏÎœ Ï.Ï.Î·Îœ Ï.ÎµÎ»ÎµÏ.Ï.Î±Î¯Î± Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·Ï. Î¿ÎžÏ.ÎœÎ·Ï. Ï.Ï.Î¿
++	  Ï.Î± Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³ÎµÎ¯Ï.Îµ. Î.Îœ Î³ÏÎ¬Ï.Î±Ï.Îµ ÎºÎ¬Ï.Î¹ Î»Î¬ÎžÎ¿Ï., Ï.Î±Ï.Î®Ï.Ï.Îµ  <ESC>  ÎºÎ±Î¹
++	  ÎŸÎµÎºÎ¹ÎœÎ®Ï.Ï.Îµ Î±Ï.Ï. Ï.Î·Îœ Î±ÏÏ.Î®.
++
++---> There are a some words fun that don't belong paper in this sentence.
++
++  5. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 3 ÎºÎ±Î¹ 4 ÎŒÎ­Ï.ÏÎ¹ Î· Ï.ÏÏ.Ï.Î±Ï.Î· ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Ï.Ï.Î® ÎºÎ±Î¹
++     Ï.Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 2.2.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 2.2: Î Î.Î¡Î.Î£Î£Î.Î€Î.Î¡Î.Î£ Î.ÎÎ€Î.Î.Î.Î£ Î.Î.Î.Î.Î¡Î.ÎŠÎ.Î£
++
++    ** Î Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ  d$  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.. **
++
++  1. Î Î±Ï.Î®Ï.Ï.Îµ  <ESC>  Î³Î¹Î± ÎœÎ± Î²ÎµÎ²Î±Î¹Ï.ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¹ ÎµÎ¯Ï.Ï.Îµ Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·.
++
++  2. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  3. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Ï.Ï.Ï.Ï.Î®Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï. (Î.Î.Î€Î. Ï.Î·Îœ Ï.ÏÏ.Ï.Î· . ).
++
++  4. Î Î±Ï.Î®Ï.Ï.Îµ   d$   Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++
++---> Somebody typed the end of this line twice. end of this line twice.
++
++  5. Î Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 2.3 Î³Î¹Î± ÎœÎ± ÎºÎ±Ï.Î±Î»Î¬Î²ÎµÏ.Îµ Ï.Î¹ Ï.Ï.ÎŒÎ²Î±Î¯ÎœÎµÎ¹.
++
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 2.3: Î Î.Î¡Î. Î.ÎÎ€Î.Î.Î©Î Î.Î.Î. Î.ÎÎ€Î.Î.Î.Î.Î.Î.ÎÎ©Î
++
++
++Î. ÎŒÎ¿ÏÏ.Î® Ï.Î·Ï. ÎµÎœÏ.Î¿Î»Î®Ï. ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®Ï.  d  ÎµÎ¯ÎœÎ±Î¹ Ï.Ï. ÎµÎŸÎ®Ï.:
++
++	 [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   d   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿	Î.	d   [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿
++  Î.Ï.Î¿Ï.:
++    Î±ÏÎ¹ÎžÎŒÏ.Ï. - Ï.Ï.Ï.ÎµÏ. Ï.Î¿ÏÎ­Ï. ÎžÎ± ÎµÎºÏ.ÎµÎ»ÎµÏ.Ï.ÎµÎ¯ Î· ÎµÎœÏ.Î¿Î»Î® (Ï.ÏÎ¿Î±Î¹ÏÎµÏ.Î¹ÎºÏ., ÎµÎŸ' Î¿ÏÎ¹Ï.ÎŒÎ¿Ï=1).
++    d - Î· ÎµÎœÏ.Î¿Î»Î® Ï.Î·Ï. ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®Ï..
++    Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿ - Ï.Î¬ÎœÏ. Ï.Îµ Ï.Î¹ ÎžÎ± Î»ÎµÎ¹Ï.Î¿Ï.ÏÎ³Î®Ï.ÎµÎ¹ Î· ÎµÎœÏ.Î¿Î»Î® (Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î»Î¯Ï.Ï.Î±).
++
++  Î.Î¯Î± ÎŒÎ¹ÎºÏÎ® Î»Î¯Ï.Ï.Î± Î±Ï.Ï. Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ±:
++    w - Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î»Î­ÎŸÎ·Ï., Ï.ÎµÏÎ¹Î»Î±ÎŒÎ²Î¬ÎœÎ¿ÎœÏ.Î±Ï. Ï.Î¿ ÎŽÎ¹Î¬Ï.Ï.Î·ÎŒÎ±.
++    e - Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î»Î­ÎŸÎ·Ï., Î§Î©Î¡Î.Î£ Ï.Î¿ ÎŽÎ¹Î¬Ï.Ï.Î·ÎŒÎ±.
++    $ - Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++
++Î£Î.Î.Î.Î.Î©Î£Î.:  Î.Î¹Î± Ï.Î¿Ï.Ï. Ï.ÏÏ.Î¿Ï.Ï. Ï.Î·Ï. Ï.ÎµÏÎ¹Ï.Î­Ï.ÎµÎ¹Î±Ï., Ï.Î±Ï.Ï.ÎœÏ.Î±Ï. Î±Ï.Î»Ï.Ï. Ï.Î¿ Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Ï.Î¿
++	   ÎµÎ¯Ï.Ï.Îµ Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Ï.ÏÎ¯Ï. ÎºÎ¬Ï.Î¿Î¹Î± ÎµÎœÏ.Î¿Î»Î® ÎžÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ®Ï.ÎµÏ.Îµ
++	   Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Ï.Ï. ÎºÎ±ÎžÎ¿ÏÎ¯Î¶ÎµÏ.Î±Î¹ Ï.Ï.Î·Îœ Î»Î¯Ï.Ï.Î± Î±ÎœÏ.Î¹ÎºÎµÎ¹ÎŒÎ­ÎœÏ.Îœ.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++	       Î.Î¬ÎžÎ·ÎŒÎ± 2.4: Î.Î.Î. Î.Î.Î.Î.Î¡Î.Î£Î. Î£Î€Î.Î 'Î.ÎÎ€Î.Î.Î.-Î.ÎÎ€Î.Î.Î.Î.Î.Î.ÎÎ.'
++
++	   ** Î Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³Î®Ï.Ï.Îµ  dd  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î»Î· Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®. **
++
++  Î.ÎŸÎ±Î¹Ï.Î¯Î±Ï. Ï.Î·Ï. Ï.Ï.Ï.ÎœÏ.Ï.Î·Ï.Î±Ï. Ï.Î·Ï. ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®Ï. Î¿Î»Ï.ÎºÎ»Î·ÏÎ·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï., Î¿Î¹ Ï.Ï.ÎµÎŽÎ¹Î±Ï.Ï.Î­Ï.
++  Ï.Î¿Ï. Vim Î±Ï.Î¿Ï.Î¬Ï.Î¹Ï.Î±Îœ Ï.Ï.Î¹ ÎžÎ± Î®Ï.Î±Îœ ÎµÏ.ÎºÎ¿Î»Ï.Ï.ÎµÏÎ¿ ÎœÎ± Î³ÏÎ¬Ï.ÎµÏ.Îµ Î±Ï.Î»Ï.Ï. ÎŽÏÎ¿ d Ï.Ï.Î·
++  Ï.ÎµÎ¹ÏÎ¬ Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ®.
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î· ÎŽÎµÏÏ.ÎµÏÎ· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·Ï. Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.ÏÎ¬Ï.Î·Ï..
++  2. Î.ÏÎ¬Ï.Ï.Îµ  dd  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++  3. Î€Ï.ÏÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î·Îœ Ï.Î­Ï.Î±ÏÏ.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++  4. Î.ÏÎ¬Ï.Ï.Îµ  2dd  (ÎžÏ.ÎŒÎ·ÎžÎµÎ¯Ï.Îµ  Î±ÏÎ¹ÎžÎŒÏ.Ï.-ÎµÎœÏ.Î¿Î»Î®-Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿) Î³Î¹Î± ÎœÎ±
++     ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ ÎŽÏÎ¿ Î³ÏÎ±ÎŒÎŒÎ­Ï..
++
++      1)  Roses are red,
++      2)  Mud is fun,
++      3)  Violets are blue,
++      4)  I have a car,
++      5)  Clocks tell time,
++      6)  Sugar is sweet
++      7)  And so are you.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Î.Î¬ÎžÎ·ÎŒÎ± 2.5: Î. Î.ÎÎ€Î.Î.Î. Î.ÎÎ.Î.Î¡Î.Î£Î.Î£
++
++	    ** Î Î±Ï.Î®Ï.Ï.Îµ  u  Î³Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.Î¹Ï. Ï.ÎµÎ»ÎµÏ.Ï.Î±Î¯ÎµÏ. ÎµÎœÏ.Î¿Î»Î­Ï.,
++	       U Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î¿ÏÎžÏ.Ï.ÎµÏ.Îµ Ï.Î»Î· Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ ---> ÎºÎ±Î¹
++     Ï.Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.Ï.Îµ Ï.Î¿Îœ Ï.Î¬ÎœÏ. Ï.Ï.Î¿ Ï.ÏÏ.Ï.Î¿ Î»Î¬ÎžÎ¿Ï..
++  2. Î Î±Ï.Î®Ï.Ï.Îµ  x  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î¿Îœ Ï.ÏÏ.Ï.Î¿ Î±ÎœÎµÏ.Î¹ÎžÏÎŒÎ·Ï.Î¿ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±.
++  3. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ  u  Î³Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.Î·Îœ Ï.ÎµÎ»ÎµÏ.Ï.Î±Î¯Î± ÎµÎºÏ.ÎµÎ»ÎµÏ.ÎŒÎ­ÎœÎ· ÎµÎœÏ.Î¿Î»Î®.
++  4. Î.Ï.Ï.Î® Ï.Î· Ï.Î¿ÏÎ¬ ÎŽÎ¹Î¿ÏÎžÏ.Ï.Ï.Îµ Ï.Î»Î± Ï.Î± Î»Î¬ÎžÎ· Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Ï.ÎœÏ.Î±Ï. Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î® x.
++  5. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ Î­ÎœÎ± ÎºÎµÏ.Î±Î»Î±Î¯Î¿  U  Î³Î¹Î± ÎœÎ± ÎµÏ.Î¹Ï.Ï.ÏÎ­Ï.ÎµÏ.Îµ Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Ï.Î·Îœ Î±ÏÏ.Î¹ÎºÎ®
++     Ï.Î·Ï. ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î·.
++  6. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ  u  ÎŒÎµÏÎ¹ÎºÎ­Ï. Ï.Î¿ÏÎ­Ï. Î³Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.Î·Îœ  U  ÎºÎ±Î¹
++     Ï.ÏÎ¿Î·Î³Î¿ÏÎŒÎµÎœÎµÏ. ÎµÎœÏ.Î¿Î»Î­Ï..
++  7. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ CTRL-R (ÎºÏÎ±Ï.Ï.ÎœÏ.Î±Ï. Ï.Î±Ï.Î·ÎŒÎ­ÎœÎ¿ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ CTRL ÎºÎ±ÎžÏ.Ï. Ï.Î±Ï.Î¬Ï.Îµ Ï.Î¿ R)
++     ÎŒÎµÏÎ¹ÎºÎ­Ï. Ï.Î¿ÏÎ­Ï. Î³Î¹Î± ÎœÎ± ÎµÏ.Î±ÎœÎ±Ï.Î­ÏÎµÏ.Îµ Ï.Î¹Ï. ÎµÎœÏ.Î¿Î»Î­Ï. (Î±ÎœÎ±Î¯ÏÎµÏ.Î· Ï.Ï.Îœ Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îœ).
++
++---> Fiix the errors oon thhis line and reeplace them witth undo.
++
++  8. Î.Ï.Ï.Î­Ï. ÎµÎ¯ÎœÎ±Î¹ Ï.Î¿Î»Ï Ï.ÏÎ®Ï.Î¹ÎŒÎµÏ. ÎµÎœÏ.Î¿Î»Î­Ï..  Î€Ï.ÏÎ± Ï.Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î·Îœ
++     Î ÎµÏÎ¯Î»Î·Ï.Î· Ï.Î¿Ï. Î.Î±ÎžÎ®ÎŒÎ±Ï.Î¿Ï. 2.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 2 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1. Î.Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Î»Î­ÎŸÎ·Ï. Î³ÏÎ¬Ï.Ï.Îµ:      dw
++
++  2. Î.Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï. Î³ÏÎ¬Ï.Ï.Îµ:    d$
++
++  3. Î.Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Î¿Î»Ï.ÎºÎ»Î·ÏÎ· Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î³ÏÎ¬Ï.Ï.Îµ:    dd
++
++  4. Î. ÎŒÎ¿ÏÏ.Î® Î³Î¹Î± ÎŒÎ¯Î± ÎµÎœÏ.Î¿Î»Î® Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· ÎµÎ¯ÎœÎ±Î¹:
++
++      [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   ÎµÎœÏ.Î¿Î»Î®   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿    Î.    ÎµÎœÏ.Î¿Î»Î®   [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿
++     Ï.Ï.Î¿Ï.:
++       Î±ÏÎ¹ÎžÎŒÏ.Ï. - Ï.Ï.Ï.ÎµÏ. Ï.Î¿ÏÎ­Ï. ÎœÎ± ÎµÏ.Î±ÎœÎ±Î»Î·Ï.ÎžÎµÎ¯ Î· ÎµÎœÏ.Î¿Î»Î®
++       ÎµÎœÏ.Î¿Î»Î® - Ï.Î¹ ÎœÎ± Î³Î¯ÎœÎµÎ¹, Ï.Ï.Ï.Ï. Î·  d  Î³Î¹Î± ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®
++       Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿ - Ï.Î¬ÎœÏ. Ï.Îµ Ï.Î¹ ÎœÎ± ÎµÎœÎµÏÎ³Î®Ï.ÎµÎ¹ Î· ÎµÎœÏ.Î¿Î»Î®, Ï.Ï.Ï.Ï.  w  (Î»Î­ÎŸÎ·),
++		     $ (Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.), ÎºÏ.Î».
++
++  5. Î.Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.ÏÎ¿Î·Î³Î¿ÏÎŒÎµÎœÎµÏ. ÎµÎœÎ­ÏÎ³ÎµÎ¹ÎµÏ., Ï.Î±Ï.Î®Ï.Ï.Îµ:        u   (Ï.ÎµÎ¶Ï. u)
++     Î.Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.Î»ÎµÏ. Ï.Î¹Ï. Î±Î»Î»Î±Î³Î­Ï. Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®, Ï.Î±Ï.Î®Ï.Ï.Îµ:  U  (ÎºÎµÏ.Î±Î»Î±Î¯Î¿ U)
++     Î.Î¹Î± ÎœÎ± Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÏ.Îµ Ï.Î¹Ï. Î±ÎœÎ±Î¹ÏÎ­Ï.ÎµÎ¹Ï., Ï.Î±Ï.Î®Ï.Ï.Îµ:               CTRL-R
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Î.Î¬ÎžÎ·ÎŒÎ± 3.1: Î. Î.ÎÎ€Î.Î.Î. Î€Î.Î Î.Î.Î.Î€Î.Î£Î.Î£
++
++
++  ** Î Î±Ï.Î®Ï.Ï.Îµ  p  Î³Î¹Î± ÎœÎ± Ï.Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.ÎµÏ.Îµ Ï.Î·Îœ Ï.ÎµÎ»ÎµÏ.Ï.Î±Î¯Î± ÎŽÎ¹Î±Î³ÏÎ±Ï.Î® ÎŒÎµÏ.Î¬ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±.  **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·Ï. Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î¿ÎŒÎ¬ÎŽÎ±Ï..
++
++  2. Î Î±Ï.Î®Ï.Ï.Îµ  dd  Î³Î¹Î± ÎœÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® ÎºÎ±Î¹ ÎœÎ± Ï.Î·Îœ Î±Ï.Î¿ÎžÎ·ÎºÎµÏÏ.ÎµÏ.Îµ Ï.Îµ
++     Ï.ÏÎ¿Ï.Ï.ÏÎ¹ÎœÎ® ÎŒÎœÎ®ÎŒÎ· Ï.Î¿Ï. Vim.
++
++  3. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î Î.ÎÎ© Î±Ï.Ï. ÎµÎºÎµÎ¯ Ï.Î¿Ï. ÎžÎ± Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± Ï.Î¬ÎµÎ¹
++     Î· ÎŽÎ¹Î±Î³ÏÎ±ÎŒÎŒÎ­ÎœÎ· Î³ÏÎ±ÎŒÎŒÎ®.
++
++  4. Î.Ï.Î¿ ÎµÎ¯Ï.Ï.Îµ Ï.Îµ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·, Ï.Î±Ï.Î®Ï.Ï.Îµ  p  Î³Î¹Î± ÎœÎ± Î²Î¬Î»ÎµÏ.Îµ Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++
++  5. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 2 Î­Ï.Ï. 4 Î³Î¹Î± ÎœÎ± Î²Î¬Î»ÎµÏ.Îµ Ï.Î»ÎµÏ. Ï.Î¹Ï. Î³ÏÎ±ÎŒÎŒÎ­Ï. Ï.Ï.Î·
++     Ï.Ï.Ï.Ï.Î® Ï.ÎµÎ¹ÏÎ¬.
++
++     d) Can you learn too?
++     b) Violets are blue,
++     c) Intelligence is learned,
++     a) Roses are red,
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		      Î.Î¬ÎžÎ·ÎŒÎ± 3.2: Î. Î.ÎÎ€Î.Î.Î. Î.ÎÎ€Î.Î.Î.Î€Î.Î£Î€Î.Î£Î.Î£
++
++
++    ** Î Î±Ï.Î®Ï.Ï.Îµ  r  ÎºÎ±Î¹ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Î³Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Î±Ï.Ï.Ï.Îœ Ï.Î¿Ï. ÎµÎ¯ÎœÎ±Î¹
++       ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Î­Ï.Ï.Î¹ Ï.Ï.Ï.Îµ ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Î¬ÎœÏ. Ï.Ï.Î¿ Ï.ÏÏ.Ï.Î¿ Î»Î¬ÎžÎ¿Ï..
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ  r  ÎºÎ±Î¹ ÎŒÎµÏ.Î¬ Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Î¿ Î¿Ï.Î¿Î¯Î¿Ï. ÎŽÎ¹Î¿ÏÎžÏ.ÎœÎµÎ¹ Ï.Î¿ Î»Î¬ÎžÎ¿Ï..
++
++  4. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 2 ÎºÎ±Î¹ 3 ÎŒÎ­Ï.ÏÎ¹ ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Ï.Ï.Î® Î· Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++
++--->  Whan this lime was tuoed in, someone presswd some wrojg keys!
++--->  When this line was typed in, someone pressed some wrong keys!
++
++  5. Î€Ï.ÏÎ± Ï.Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 3.2.
++
++Î£Î.Î.Î.Î.Î©Î£Î.: ÎÎ± ÎžÏ.ÎŒÎ¬Ï.Ï.Îµ Ï.Ï.Î¹ Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± ÎŒÎ±ÎžÎ±Î¯ÎœÎµÏ.Îµ ÎŒÎµ Ï.Î· Ï.ÏÎ®Ï.Î·, ÎºÎ±Î¹ Ï.Ï.Î¹ ÎŒÎµ
++	  Ï.Î·Îœ Î±Ï.Î¿ÎŒÎœÎ·ÎŒÏ.ÎœÎµÏ.Ï.Î·.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Î.Î¬ÎžÎ·ÎŒÎ± 3.3: Î. Î.ÎÎ€Î.Î.Î. Î.Î.Î.Î.Î.Î.Î£
++
++	   ** Î.Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Ï.ÎŒÎ®ÎŒÎ± Î® Ï.Î»Î· Ï.Î· Î»Î­ÎŸÎ·, Ï.Î±Ï.Î®Ï.Ï.Îµ  cw  . **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î€Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Î¬ÎœÏ. Ï.Ï.Î¿ u Ï.Î·Ï. Î»Î­ÎŸÎ·Ï. lubw.
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ  cw  ÎºÎ±Î¹ Ï.Î· Ï.Ï.Ï.Ï.Î® Î»Î­ÎŸÎ· (Ï.Ï.Î·Îœ Ï.ÎµÏÎ¯Ï.Ï.Ï.Ï.Î· Î±Ï.Ï.Î®, Î³ÏÎ¬Ï.Ï.Îµ  'ine'.)
++
++  4. Î Î±Ï.Î®Ï.Ï.Îµ <ESC> ÎºÎ±Î¹ Ï.Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î¿ ÎµÏ.Ï.ÎŒÎµÎœÎ¿ Î»Î¬ÎžÎ¿Ï. (Ï.Ï.Î¿Îœ Ï.ÏÏ.Ï.Î¿
++     Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Ï.ÏÎ¿Ï. Î±Î»Î»Î±Î³Î®).
++
++  5. Î.Ï.Î±ÎœÎ±Î»Î¬Î²ÎµÏ.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 3 ÎºÎ±Î¹ 4 ÎŒÎ­Ï.ÏÎ¹Ï. Ï.Ï.Î¿Ï. Î· Ï.ÏÏ.Ï.Î· Ï.ÏÏ.Ï.Î±Ï.Î· ÎœÎ± ÎµÎ¯ÎœÎ±Î¹
++     Î¯ÎŽÎ¹Î± ÎŒÎµ Ï.Î· ÎŽÎµÏÏ.ÎµÏÎ·.
++
++---> This lubw has a few wptfd that mrrf changing usf the change command.
++---> This line has a few words that need changing using the change command.
++
++Î Î±ÏÎ±Ï.Î·ÏÎµÎ¯Ï.Ï.Îµ Ï.Ï.Î¹ Î·  cw  Ï.Ï.Î¹ ÎŒÏ.ÎœÎ¿ Î±ÎœÏ.Î¹ÎºÎ±ÎžÎ¹Ï.Ï.Î¬ÎµÎ¹ Ï.Î· Î»Î­ÎŸÎ·, Î±Î»Î»Î¬ Ï.Î±Ï. ÎµÎ¹Ï.Î¬Î³ÎµÎ¹
++ÎµÏ.Î¯Ï.Î·Ï. Ï.Îµ Ï.Î±ÏÎµÎŒÎ²Î¿Î»Î®.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		     Î.Î¬ÎžÎ·ÎŒÎ± 3.4: Î Î.Î¡Î.Î£Î£Î.Î€Î.Î¡Î.Î£ Î.Î.Î.Î.Î.Î.Î£ Î.Î. c
++
++
++  ** Î. ÎµÎœÏ.Î¿Î»Î® Î±Î»Î»Î±Î³Î®Ï. Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹ÎµÎ¯Ï.Î±Î¹ ÎŒÎµ Ï.Î± Î¯ÎŽÎ¹Î± Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ± Ï.Î·Ï. ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®Ï.. **
++
++
++  1. Î. ÎµÎœÏ.Î¿Î»Î® Î±Î»Î»Î±Î³Î®Ï. ÎŽÎ¿Ï.Î»ÎµÏÎµÎ¹ ÎŒÎµ Ï.Î¿Îœ Î¯ÎŽÎ¹Î¿ Ï.ÏÏ.Ï.Î¿ Ï.Ï.Ï.Ï. Î· ÎŽÎ¹Î±Î³ÏÎ±Ï.Î®. Î. ÎŒÎ¿ÏÏ.Î® ÎµÎ¯ÎœÎ±Î¹:
++
++       [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   c   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿     Î.     c   [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿
++
++  2. Î€Î± Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Î¬Î»Î¹ Ï.Î± Î¯ÎŽÎ¹Î±, Ï.Ï.Ï.Ï. w (Î»Î­ÎŸÎ·), $ (Ï.Î­Î»Î¿Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.), ÎºÏ.Î».
++
++  3. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  4. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ Ï.ÏÏ.Ï.Î¿ Î»Î¬ÎžÎ¿Ï..
++
++  5. Î.ÏÎ¬Ï.Ï.Îµ  c$  Î³Î¹Î± ÎœÎ± ÎºÎ¬ÎœÎµÏ.Îµ Ï.Î¿ Ï.Ï.Ï.Î»Î¿Î¹Ï.Î¿ Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï. Î¯ÎŽÎ¹Î¿ ÎŒÎµ Ï.Î· ÎŽÎµÏÏ.ÎµÏÎ·
++     ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ <ESC>.
++
++---> The end of this line needs some help to make it like the second.
++---> The end of this line needs to be corrected using the  c$  command.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 3 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1. Î.Î¹Î± ÎœÎ± Ï.Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Î¿Ï. ÎŒÏ.Î»Î¹Ï. Î­Ï.ÎµÎ¹ ÎŽÎ¹Î±Î³ÏÎ±Ï.ÎµÎ¯, Ï.Î±Ï.Î®Ï.Ï.Îµ  p .
++     Î.Ï.Ï.Ï. Ï.Î¿Ï.Î¿ÎžÎµÏ.ÎµÎ¯ Ï.Î¿ ÎŽÎ¹Î±Î³ÏÎ±ÎŒÎŒÎ­ÎœÎ¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Î.Î.Î€Î. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± (Î±Îœ ÎŽÎ¹Î±Î³ÏÎ¬Ï.Ï.Î·ÎºÎµ
++     Î³ÏÎ±ÎŒÎŒÎ® ÎžÎ± Ï.Î¬ÎµÎ¹ ÎŒÎµÏ.Î¬ Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±.
++
++  2. Î.Î¹Î± ÎœÎ± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î±Ï.Ï.Î®Ï.ÎµÏ.Îµ Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±, Ï.Î±Ï.Î®Ï.Ï.Îµ  r
++     ÎºÎ±Î¹ ÎŒÎµÏ.Î¬ Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Ï.Î¿Ï. ÎžÎ± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î±Ï.Ï.Î®Ï.ÎµÎ¹ Ï.Î¿Îœ Î±ÏÏ.Î¹ÎºÏ..
++
++  3. Î. ÎµÎœÏ.Î¿Î»Î® Î±Î»Î»Î±Î³Î®Ï. Ï.Î±Ï. ÎµÏ.Î¹Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Ï.Î¿ ÎºÎ±ÎžÎ¿ÏÎ¹Ï.ÎŒÎ­ÎœÎ¿ Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿
++     Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î¿Ï. Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿. Î .Ï.. Î³ÏÎ¬Ï.Ï.Îµ  cw  Î³Î¹Î± ÎœÎ±
++     Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î»Î­ÎŸÎ·Ï., c$ Î³Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ
++     ÎŒÎ­Ï.ÏÎ¹ Ï.Î¿ Ï.Î­Î»Î¿Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++
++  4. Î. ÎŒÎ¿ÏÏ.Î® Î³Î¹Î± Ï.Î·Îœ Î±Î»Î»Î±Î³Î® ÎµÎ¯ÎœÎ±Î¹:
++
++	 [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   c   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿     Î.     c   [Î±ÏÎ¹ÎžÎŒÏ.Ï.]   Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿
++
++Î€Ï.ÏÎ± Ï.Ï.ÎœÎµÏ.Î¯Ï.Ï.Îµ ÎŒÎµ Ï.Î¿ ÎµÏ.Ï.ÎŒÎµÎœÎ¿ ÎŒÎ¬ÎžÎ·ÎŒÎ±.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		     Î.Î¬ÎžÎ·ÎŒÎ± 4.1: Î.Î.Î£Î. Î.Î.Î. Î.Î.Î€Î.Î£Î€Î.Î£Î. Î.Î¡Î§Î.Î.Î.Î¥
++
++
++ ** Î Î±Ï.Î®Ï.Ï.Îµ CTRL-g Î³Î¹Î± ÎœÎ± ÎµÎŒÏ.Î±ÎœÎ¹Ï.Ï.ÎµÎ¯ Î· ÎžÎ­Ï.Î· Ï.Î±Ï. Ï.Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎºÎ±Î¹ Î· ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î® Ï.Î¿Ï..
++    Î Î±Ï.Î®Ï.Ï.Îµ SHIFT-G Î³Î¹Î± ÎœÎ± Ï.Î¬Ï.Îµ Ï.Îµ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ® Ï.Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿. **
++
++  Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î.Î¹Î±Î²Î¬Ï.Ï.Îµ Î¿Î»Ï.ÎºÎ»Î·ÏÎ¿ Ï.Î¿ ÎŒÎ¬ÎžÎ·ÎŒÎ± Ï.ÏÎ¹Îœ ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ ÎºÎ¬Ï.Î¿Î¹Î¿ Î±Ï.Ï. Ï.Î± Î²Î®ÎŒÎ±Ï.Î±!!
++
++  1. Î.ÏÎ±Ï.Î®Ï.Ï.Îµ Ï.Î±Ï.Î·ÎŒÎ­ÎœÎ¿ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ Ctrl ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ  g . Î.Î¯Î± Î³ÏÎ±ÎŒÎŒÎ® ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î·Ï.
++     ÎžÎ± ÎµÎŒÏ.Î±ÎœÎ¹Ï.Ï.ÎµÎ¯ Ï.Ï.Î¿ ÎºÎ¬Ï.Ï. ÎŒÎ­ÏÎ¿Ï. Ï.Î·Ï. Ï.ÎµÎ»Î¯ÎŽÎ±Ï. ÎŒÎµ Ï.Î¿ Ï.ÎœÎ¿ÎŒÎ± Î±ÏÏ.ÎµÎ¯Î¿Ï. ÎºÎ±Î¹ Ï.Î·
++     Î³ÏÎ±ÎŒÎŒÎ® Ï.Î¿Ï. ÎµÎ¯Ï.Ï.Îµ. Î.Ï.ÎŒÎ·ÎžÎµÎ¯Ï.Îµ Ï.Î¿Îœ Î±ÏÎ¹ÎžÎŒÏ. Î³ÏÎ±ÎŒÎŒÎ®Ï. Î³Î¹Î± Ï.Î¿ Î.Î®ÎŒÎ± 3.
++
++  2. Î Î±Ï.Î®Ï.Ï.Îµ shift-G Î³Î¹Î± ÎœÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï..
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿Îœ Î±ÏÎ¹ÎžÎŒÏ. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï. Ï.Î¿Ï. Î®Ï.Î±Ï.Ï.Î±Îœ ÎºÎ±Î¹ ÎŒÎµÏ.Î¬ shift-G. Î.Ï.Ï.Ï. ÎžÎ±
++     Ï.Î±Ï. ÎµÏ.Î¹Ï.Ï.ÏÎ­Ï.ÎµÎ¹ Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î¿Ï. Î®Ï.Î±Ï.Ï.Î±Îœ Ï.ÏÎ¹Îœ Ï.Î±Ï.Î®Ï.ÎµÏ.Îµ Î³Î¹Î± Ï.ÏÏ.Ï.Î· Ï.Î¿ÏÎ¬ Ctrl-g.
++     (Î.Ï.Î±Îœ Ï.Î»Î·ÎºÏ.ÏÎ¿Î»Î¿Î³ÎµÎ¯Ï.Îµ Ï.Î¿Ï.Ï. Î±ÏÎ¹ÎžÎŒÎ¿ÏÏ., Î.Î.Î ÎžÎ± ÎµÎŒÏ.Î±ÎœÎ¯Î¶Î¿ÎœÏ.Î±Î¹ Ï.Ï.Î·Îœ Î¿ÎžÏ.ÎœÎ·).
++
++  4. Î.Îœ ÎœÎ¿Î¹Ï.ÎžÎµÏ.Îµ Ï.Î¯Î³Î¿Ï.ÏÎ¿Ï. Î³Î¹Î± Î±Ï.Ï.Ï., ÎµÎºÏ.ÎµÎ»Î­Ï.Ï.Îµ Ï.Î± Î²Î®ÎŒÎ±Ï.Î± 1 Î­Ï.Ï. 3.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Î.Î¬ÎžÎ·ÎŒÎ± 4.2: Î. Î.ÎÎ€Î.Î.Î. Î.ÎÎ.Î.Î.Î€Î.Î£Î.Î£
++
++
++	  ** Î Î±Ï.Î®Ï.Ï.Îµ   /   Î±ÎºÎ¿Î»Î¿Ï.ÎžÎ¿ÏÎŒÎµÎœÎ¿ Î±Ï.Ï. Ï.Î· Ï.ÏÎ¬Ï.Î· Ï.Î¿Ï. Ï.Î¬Ï.ÎœÎµÏ.Îµ. **
++
++  1. Î£Îµ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±  / . Î Î±ÏÎ±Ï.Î·ÏÎ®Ï.Ï.Îµ Ï.Ï.Î¹ Î±Ï.Ï.Ï.Ï. ÎºÎ±Î¹
++     Î¿ ÎŽÏÎ¿ÎŒÎ­Î±Ï. ÎµÎŒÏ.Î±ÎœÎ¯Î¶Î¿ÎœÏ.Î±Î¹ Ï.Ï.Î¿ ÎºÎ¬Ï.Ï. ÎŒÎ­ÏÎ¿Ï. Ï.Î·Ï. Î¿ÎžÏ.ÎœÎ·Ï. Ï.Ï.Ï.Ï. ÎŒÎµ Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î®  : .
++
++  2. Î€Ï.ÏÎ± Î³ÏÎ¬Ï.Ï.Îµ 'errroor' <ENTER>. Î.Ï.Ï.Î® ÎµÎ¯ÎœÎ±Î¹ Î· Î»Î­ÎŸÎ· Ï.Î¿Ï. ÎžÎ­Î»ÎµÏ.Îµ ÎœÎ± Ï.Î¬ÎŸÎµÏ.Îµ.
++
++  3. Î.Î¹Î± ÎœÎ± Ï.Î¬ÎŸÎµÏ.Îµ ÎŸÎ±ÎœÎ¬ Î³Î¹Î± Ï.Î·Îœ Î¯ÎŽÎ¹Î± Ï.ÏÎ¬Ï.Î·, Ï.Î±Ï.Î®Ï.Ï.Îµ Î±Ï.Î»Ï.Ï.  n .
++     Î.Î¹Î± ÎœÎ± Ï.Î¬ÎŸÎµÏ.Îµ Ï.Î·Îœ Î¯ÎŽÎ¹Î± Ï.ÏÎ¬Ï.Î· Ï.Ï.Î·Îœ Î±ÎœÏ.Î¯ÎžÎµÏ.Î· ÎºÎ±Ï.ÎµÏÎžÏ.ÎœÏ.Î·, Ï.Î±Ï.Î®Ï.Ï.Îµ  Shift-N .
++
++  4. Î.Îœ ÎžÎ­Î»ÎµÏ.Îµ ÎœÎ± Ï.Î¬ÎŸÎµÏ.Îµ Î³Î¹Î± ÎŒÎ¯Î± Ï.ÏÎ¬Ï.Î· Ï.ÏÎ¿Ï. Ï.Î± Ï.Î¯Ï.Ï., Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î®Ï.Ï.Îµ Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î®  ?  Î±ÎœÏ.Î¯ Ï.Î·Ï.  / .
++
++---> Î.Ï.Î±Îœ Î· Î±ÎœÎ±Î¶Î®Ï.Î·Ï.Î· Ï.Ï.Î¬Ï.ÎµÎ¹ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï. ÎžÎ± Ï.Ï.ÎœÎµÏ.Î¯Ï.ÎµÎ¹ Î±Ï.Ï. Ï.Î·Îœ Î±ÏÏ.Î®.
++
++  "errroor" is not the way to spell error;  errroor is an error.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 4.3: Î.Î¥Î¡Î.Î£Î. Î€Î.Î.Î¡Î.Î.Î£Î€Î©Î Î Î.Î¡Î.ÎÎ.Î.Î£Î.Î©Î
++
++
++	  ** Î Î±Ï.Î®Ï.Ï.Îµ   %   Î³Î¹Î± ÎœÎ± Î²ÏÎµÎ¯Ï.Îµ Ï.Î·Îœ Î±ÎœÏ.Î¯Ï.Ï.Î¿Î¹Ï.Î· ), ], Î® } . **
++
++  1. Î€Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Îµ ÎºÎ¬Ï.Î¿Î¹Î± (, [, Î® { Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ®
++     Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±  % .
++
++  3. Î. ÎŽÏÎ¿ÎŒÎ­Î±Ï. ÎžÎ± Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Î·Îœ Î±ÎœÏ.Î¯Ï.Ï.Î¿Î¹Ï.Î· Ï.Î±ÏÎ­ÎœÎžÎµÏ.Î· Î® Î±Î³ÎºÏÎ»Î·.
++
++  4. Î Î±Ï.Î®Ï.Ï.Îµ  %  Î³Î¹Î± ÎœÎ± ÎŒÎµÏ.Î±ÎºÎ¹ÎœÎ®Ï.ÎµÏ.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Î¯Ï.Ï. Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î±Î³ÎºÏÎ»Î·
++    (Ï.Î¿Ï. Î¶ÎµÏ.Î³Î±ÏÎ¹Î¿Ï).
++
++---> This ( is a test line with ('s, ['s ] and {'s } in it. ))
++
++Î£Î.Î.Î.Î.Î©Î£Î.: Î.Ï.Ï.Ï. ÎµÎ¯ÎœÎ±Î¹ Ï.Î¿Î»Ï Ï.ÏÎ®Ï.Î¹ÎŒÎ¿ Ï.Ï.Î·Îœ Î±Ï.Î¿Ï.Ï.Î±Î»ÎŒÎ¬Ï.Ï.Ï.Î· ÎµÎœÏ.Ï. Ï.ÏÎ¿Î³ÏÎ¬ÎŒÎŒÎ±Ï.Î¿Ï.
++	  ÎŒÎµ ÎŒÎ· Ï.Î±Î¹ÏÎ¹Î±Ï.Ï.Î­Ï. Ï.Î±ÏÎµÎœÎžÎ­Ï.ÎµÎ¹Ï.!
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		    Î.Î¬ÎžÎ·ÎŒÎ± 4.4: Î.ÎÎ.Î£ Î€Î¡Î.Î Î.Î£ Î.Î.Î. Î.Î.Î.Î.Î.Î. Î.Î.Î.Î©Î
++
++
++       ** Î.ÏÎ¬Ï.Ï.Îµ  :s/old/new/g  Î³Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Ï.Î¿ 'new' ÎŒÎµ Ï.Î¿ 'old'. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î.ÏÎ¬Ï.Ï.Îµ  :s/thee/the <ENTER> . Î£Î·ÎŒÎµÎ¹Ï.Ï.Ï.Îµ Ï.Ï.Î¹ Î±Ï.Ï.Î® Î· ÎµÎœÏ.Î¿Î»Î® Î±Î»Î»Î¬Î¶ÎµÎ¹ ÎŒÏ.ÎœÎ¿
++     Ï.Î·Îœ Ï.ÏÏ.Ï.Î· ÎµÎŒÏ.Î¬ÎœÎ¹Ï.Î· Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++
++  3. Î€Ï.ÏÎ± Î³ÏÎ¬Ï.Ï.Îµ   :s/thee/the/g    ÎµÎœÎœÎ¿Ï.ÎœÏ.Î±Ï. Î³ÎµÎœÎ¹ÎºÎ® Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Ï.Î·
++     Î³ÏÎ±ÎŒÎŒÎ®. Î.Ï.Ï.Ï. Î±Î»Î»Î¬Î¶ÎµÎ¹ Ï.Î»ÎµÏ. Ï.Î¹Ï. ÎµÎŒÏ.Î±ÎœÎ¯Ï.ÎµÎ¹Ï. ÎµÏ.Î¯ Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++
++---> thee best time to see thee flowers is in thee spring.
++
++  4. Î.Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ ÎºÎ¬ÎžÎµ ÎµÎŒÏ.Î¬ÎœÎ¹Ï.Î· ÎŒÎ¯Î±Ï. Ï.Ï.ÎŒÎ²Î¿Î»Î¿Ï.ÎµÎ¹ÏÎ¬Ï. ÎŒÎµÏ.Î±ÎŸÏ ÎŽÏÎ¿ Î³ÏÎ±ÎŒÎŒÏ.Îœ,
++     Î³ÏÎ¬Ï.Ï.Îµ   :#,#s/old/new/g   Ï.Ï.Î¿Ï. #,# Î¿Î¹ Î±ÏÎ¹ÎžÎŒÎ¿Î¯ Ï.Ï.Îœ ÎŽÏÎ¿ Î³ÏÎ±ÎŒÎŒÏ.Îœ.
++     Î.ÏÎ¬Ï.Ï.Îµ   :%s/old/new/g     Î³Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ ÎºÎ¬ÎžÎµ ÎµÎŒÏ.Î¬ÎœÎ¹Ï.Î· Ï.Îµ Ï.Î»Î¿ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿.
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 4 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1. Î€Î¿  Ctrl-g  ÎµÎŒÏ.Î±ÎœÎ¯Î¶ÎµÎ¹ Ï.Î· ÎžÎ­Ï.Î· Ï.Î±Ï. Ï.Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎºÎ±Î¹ Ï.Î·Îœ ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î® Ï.Î¿Ï..
++     Î€Î¿  Shift-G  Ï.Î·Î³Î±Î¯ÎœÎµÎ¹ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï.. Î.ÎœÎ±Ï. Î±ÏÎ¹ÎžÎŒÏ.Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.
++     Î±ÎºÎ¿Î»Î¿Ï.ÎžÎ¿ÏÎŒÎµÎœÎ¿Ï. Î±Ï.Ï.  Shift-G  Ï.Î·Î³Î±Î¯ÎœÎµÎ¹ Ï.Îµ ÎµÎºÎµÎ¯ÎœÎ· Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®.
++
++  2. Î.ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï.  /  Î±ÎºÎ¿Î»Î¿Ï.ÎžÎ¿ÏÎŒÎµÎœÎ¿ Î±Ï.Ï. ÎŒÎ¯Î± Ï.ÏÎ¬Ï.Î· Ï.Î¬Ï.ÎœÎµÎ¹ Ï.ÏÎ¿Ï. Ï.Î± Î.Î Î¡Î.Î£Î€Î. Î³Î¹Î±
++     Ï.Î· Ï.ÏÎ¬Ï.Î·. Î.ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï.  ?  Î±ÎºÎ¿Î»Î¿Ï.ÎžÎ¿ÏÎŒÎµÎœÎ¿ Î±Ï.Ï. ÎŒÎ¯Î± Ï.ÏÎ¬Ï.Î· Ï.Î¬Ï.ÎœÎµÎ¹ Ï.ÏÎ¿Ï. Ï.Î± Î Î.Î£Î©
++     Î³Î¹Î± Ï.Î· Ï.ÏÎ¬Ï.Î·. Î.ÎµÏ.Î¬ Î±Ï.Ï. ÎŒÎ¯Î± Î±ÎœÎ±Î¶Î®Ï.Î·Ï.Î· Ï.Î±Ï.Î®Ï.Ï.Îµ  n  Î³Î¹Î± ÎœÎ± Î²ÏÎµÎ¯Ï.Îµ Ï.Î·Îœ
++     ÎµÏ.Ï.ÎŒÎµÎœÎ· ÎµÎŒÏ.Î¬ÎœÎ¹Ï.Î· Ï.ÏÎ¿Ï. Ï.Î·Îœ Î¯ÎŽÎ¹Î± ÎºÎ±Ï.ÎµÏÎžÏ.ÎœÏ.Î· Î®  Shift-N  Î³Î¹Î± ÎœÎ± Ï.Î¬ÎŸÎµÏ.Îµ
++     Ï.ÏÎ¿Ï. Ï.Î·Îœ Î±ÎœÏ.Î¯ÎžÎµÏ.Î· ÎºÎ±Ï.ÎµÏÎžÏ.ÎœÏ.Î·.
++
++  3. Î Î±Ï.Ï.ÎœÏ.Î±Ï.  %  Ï.Ï.Î¿ Î¿ ÎŽÏÎ¿ÎŒÎ­Î±Ï. ÎµÎ¯ÎœÎ±Î¹ Ï.Î¬ÎœÏ. Ï.Îµ ÎŒÎ¯Î± (,),[,],{, Î® }  ÎµÎœÏ.Î¿Ï.Î¯Î¶ÎµÎ¹
++     Ï.Î¿ Î±ÎœÏ.Î¯Ï.Ï.Î¿Î¹Ï.Î¿ Ï.Î±Î¯ÏÎ¹ Ï.Î¿Ï. Î¶ÎµÏ.Î³Î±ÏÎ¹Î¿Ï.
++
++  4. Î.Î¹Î± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· ÎŒÎµ new Ï.Î¿Ï. Ï.ÏÏ.Ï.Î¿Ï. old Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î³ÏÎ¬Ï.Ï.Îµ  :s/old/new
++     Î.Î¹Î± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· ÎŒÎµ new Ï.Î»Ï.Îœ Ï.Ï.Îœ 'old' Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î³ÏÎ¬Ï.Ï.Îµ  :s/old/new/g
++     Î.Î¹Î± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.ÏÎ¬Ï.ÎµÏ.Îœ ÎŒÎµÏ.Î±ÎŸÏ ÎŽÏÎ¿ # Î³ÏÎ±ÎŒÎŒÏ.Îœ Î³ÏÎ¬Ï.Ï.Îµ      :#,#s/old/new/g
++     Î.Î¹Î± Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· Ï.Î»Ï.Îœ Ï.Ï.Îœ ÎµÎŒÏ.Î±ÎœÎ¯Ï.ÎµÏ.Îœ Ï.Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Î³ÏÎ¬Ï.Ï.Îµ    :%s/old/new/g
++     Î.Î¹Î± ÎµÏÏ.Ï.Î·Ï.Î· ÎµÏ.Î¹Î²ÎµÎ²Î±Î¯Ï.Ï.Î·Ï. ÎºÎ¬ÎžÎµ Ï.Î¿ÏÎ¬ Ï.ÏÎ¿Ï.ÎžÎ­Ï.Ï.Îµ Î­ÎœÎ± 'c'       "%s/old/new/gc
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Î.Î¬ÎžÎ·ÎŒÎ± 5.1: Î Î©Î£ Î.Î.Î€Î.Î.Î© Î.Î.Î. Î.Î.Î©Î€Î.Î¡Î.Î.Î. Î.ÎÎ€Î.Î.Î.
++
++
++** Î.ÏÎ¬Ï.Ï.Îµ  :!  Î±ÎºÎ¿Î»Î¿Ï.ÎžÎ¿ÏÎŒÎµÎœÎ¿ Î±Ï.Ï. ÎŒÎ¯Î± ÎµÎŸÏ.Ï.ÎµÏÎ¹ÎºÎ® ÎµÎœÏ.Î¿Î»Î® Î³Î¹Î± ÎœÎ± Ï.Î·Îœ ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ. **
++
++  1. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Î·Îœ Î¿Î¹ÎºÎµÎ¯Î± ÎµÎœÏ.Î¿Î»Î®  :  Î³Î¹Î± ÎœÎ± ÎžÎ­Ï.ÎµÏ.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ ÎºÎ¬Ï.Ï. ÎŒÎ­ÏÎ¿Ï.
++     Ï.Î·Ï. Î¿ÎžÏ.ÎœÎ·Ï.. Î.Ï.Ï.Ï. Ï.Î±Ï. ÎµÏ.Î¹Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± ÎŽÏ.Ï.ÎµÏ.Îµ ÎŒÎ¯Î± ÎµÎœÏ.Î¿Î»Î®.
++
++  2. Î€Ï.ÏÎ± Ï.Î±Ï.Î®Ï.Ï.Îµ  Ï.Î¿  !  (ÎžÎ±Ï.ÎŒÎ±Ï.Ï.Î¹ÎºÏ.). Î.Ï.Ï.Ï. Ï.Î±Ï. ÎµÏ.Î¹Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ
++     Î¿Ï.Î¿Î¹Î±ÎŽÎ®Ï.Î¿Ï.Îµ ÎµÎŸÏ.Ï.ÎµÏÎ¹ÎºÎ® ÎµÎœÏ.Î¿Î»Î® Ï.Î¿Ï. Ï.Î»Î¿Î¹Î¿Ï.
++
++  3. Î£Î±Îœ Ï.Î±ÏÎ¬ÎŽÎµÎ¹Î³ÎŒÎ± Î³ÏÎ¬Ï.Ï.Îµ  ls  ÎŒÎµÏ.Î¬ Î±Ï.Ï. Ï.Î¿ ! ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ <ENTER>. Î.Ï.Ï.Ï. ÎžÎ±
++     Ï.Î±Ï. ÎµÎŒÏ.Î±ÎœÎ¯Ï.ÎµÎ¹ ÎŒÎ¯Î± Î»Î¯Ï.Ï.Î± Ï.Î¿Ï. ÎºÎ±Ï.Î±Î»Ï.Î³Î¿Ï. Ï.Î±Ï., Î±ÎºÏÎ¹Î²Ï.Ï. Ï.Î±Îœ ÎœÎ± Î®Ï.Î±Ï.Ï.Î±Îœ Ï.Ï.Î·Îœ
++     Ï.ÏÎ¿Ï.ÏÎ¿Ï.Î® Ï.Î¿Ï. Ï.Î»Î¿Î¹Î¿Ï. Î. Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î®Ï.Ï.Îµ  :!dir  Î±Îœ Ï.Î¿ ls ÎŽÎµÎœ ÎŽÎ¿Ï.Î»ÎµÏÎµÎ¹.
++
++---> Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î.Î¯ÎœÎ±Î¹ ÎŽÏ.ÎœÎ±Ï.Ï.Îœ ÎœÎ± ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ Î¿Ï.Î¿Î¹Î±ÎŽÎ®Ï.Î¿Ï.Îµ ÎµÎŸÏ.Ï.ÎµÏÎ¹ÎºÎ® ÎµÎœÏ.Î¿Î»Î®
++     ÎŒÎµ Î±Ï.Ï.Ï.Îœ Ï.Î¿Îœ Ï.ÏÏ.Ï.Î¿.
++
++---> Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î.Î»ÎµÏ. Î¿Î¹ ÎµÎœÏ.Î¿Î»Î­Ï.  :  Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± Ï.ÎµÏÎŒÎ±Ï.Î¯Î¶Î¿ÎœÏ.Î±Î¹ Ï.Î±Ï.Ï.ÎœÏ.Î±Ï. Ï.Î¿ <ENTER>.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		 Î.Î¬ÎžÎ·ÎŒÎ± 5.2: Î Î.Î¡Î.Î£Î£Î.Î€Î.Î¡Î. Î Î.Î¡Î. Î.Î.Î.Î¡Î.ÎŠÎ.Î£ Î.Î¡Î§Î.Î.Î©Î
++
++
++   ** Î.Î¹Î± ÎœÎ± Ï.Ï.Ï.ÎµÏ.Îµ Ï.Î¹Ï. Î±Î»Î»Î¬Î³ÎµÏ. Ï.Î¿Ï. ÎºÎ¬ÎœÎ±Ï.Îµ Ï.Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿, Î³ÏÎ¬Ï.Ï.Îµ  :w Î.Î¡Î§Î.Î.Î..  **
++
++  1. Î.ÏÎ¬Ï.Ï.Îµ  :!dir  Î®  :!ls  Î³Î¹Î± ÎœÎ± Ï.Î¬ÏÎµÏ.Îµ ÎŒÎ¯Î± Î»Î¯Ï.Ï.Î± Ï.Î¿Ï. ÎºÎ±Ï.Î±Î»Ï.Î³Î¿Ï. Ï.Î±Ï..
++     Î.ÎŽÎ· ÎŸÎ­ÏÎµÏ.Îµ Ï.Ï.Î¹ Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± Ï.Î±Ï.Î®Ï.ÎµÏ.Îµ <ENTER> ÎŒÎµÏ.Î¬ Î±Ï.Ï. Î±Ï.Ï.Ï..
++
++  2. Î.Î¹Î±Î»Î­ÎŸÏ.Îµ Î­ÎœÎ± Ï.ÎœÎ¿ÎŒÎ± Î±ÏÏ.ÎµÎ¯Î¿Ï. Ï.Î¿Ï. ÎŽÎµÎœ Ï.Ï.Î¬ÏÏ.ÎµÎ¹ Î±ÎºÏ.ÎŒÎ±, Ï.Ï.Ï.Ï. Ï.Î¿ TEST.
++
++  3. Î€Ï.ÏÎ± Î³ÏÎ¬Ï.Ï.Îµ:  :w TEST  (Ï.Ï.Î¿Ï. TEST ÎµÎ¯ÎœÎ±Î¹ Ï.Î¿ Ï.ÎœÎ¿ÎŒÎ± Î±ÏÏ.ÎµÎ¯Î¿Ï. Ï.Î¿Ï. ÎŽÎ¹Î±Î»Î­ÎŸÎ±Ï.Îµ).
++
++  4. Î.Ï.Ï.Ï. Ï.Ï.Î¶ÎµÎ¹ Ï.Î»Î¿ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ (vim Tutor) ÎŒÎµ Ï.Î¿ Ï.ÎœÎ¿ÎŒÎ± TEST. Î.Î¹Î± ÎœÎ± Ï.Î¿
++     ÎµÏ.Î±Î»Î·ÎžÎµÏÏ.ÎµÏ.Îµ, Î³ÏÎ¬Ï.Ï.Îµ ÎŸÎ±ÎœÎ¬  :!dir Î³Î¹Î± ÎœÎ± ÎŽÎµÎ¯Ï.Îµ Ï.Î¿Îœ ÎºÎ±Ï.Î¬Î»Î¿Î³Ï. Ï.Î±Ï..
++
++---> Î£Î·ÎŒÎµÎ¹Ï.Ï.Ï.Îµ Ï.Ï.Î¹ Î±Îœ Î²Î³Î±Î¯ÎœÎ±Ï.Îµ Î±Ï.Ï. Ï.Î¿Îœ Vim ÎºÎ±Î¹ ÎŒÏ.Î±Î¯ÎœÎ±Ï.Îµ ÎŸÎ±ÎœÎ¬ ÎŒÎµ Ï.Î¿ Ï.ÎœÎ¿ÎŒÎ±
++     Î±ÏÏ.ÎµÎ¯Î¿Ï. TEST, Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎžÎ± Î®Ï.Î±Îœ Î±ÎºÏÎ¹Î²Î­Ï. Î±ÎœÏ.Î¯Î³ÏÎ±Ï.Î¿ Ï.Î¿Ï. tutor Ï.Ï.Î±Îœ Ï.Î¿ Ï.Ï.Ï.Î±Ï.Îµ.
++
++  5. Î€Ï.ÏÎ± ÎŽÎ¹Î±Î³ÏÎ¬Ï.Ï.Îµ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Î³ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï. (MS-DOS):      :!del TEST
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		     Î.Î¬ÎžÎ·ÎŒÎ± 5.3: Î.Î Î.Î.Î.Î.Î€Î.Î.Î. Î.ÎÎ€Î.Î.Î. Î.Î.Î.Î¡Î.ÎŠÎ.Î£
++
++
++	  ** Î.Î¹Î± ÎœÎ± Ï.Ï.Ï.ÎµÏ.Îµ Ï.ÎŒÎ®ÎŒÎ± Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï., Î³ÏÎ¬Ï.Ï.Îµ  :#,# w Î.Î¡Î§Î.Î.Î. **
++
++  1. Î.Î»Î»Î· ÎŒÎ¹Î± Ï.Î¿ÏÎ¬, Î³ÏÎ¬Ï.Ï.Îµ  :!dir  Î®  :!ls  Î³Î¹Î± ÎœÎ± Ï.Î¬ÏÎµÏ.Îµ ÎŒÎ¯Î± Î»Î¯Ï.Ï.Î± Î±Ï.Ï. Ï.Î¿Îœ
++     ÎºÎ±Ï.Î¬Î»Î¿Î³Ï. Ï.Î±Ï. ÎºÎ±Î¹ ÎŽÎ¹Î±Î»Î­ÎŸÏ.Îµ Î­ÎœÎ± ÎºÎ±Ï.Î¬Î»Î»Î·Î»Î¿ Ï.ÎœÎ¿ÎŒÎ± Î±ÏÏ.ÎµÎ¯Î¿Ï. Ï.Ï.Ï.Ï. Ï.Î¿ TEST.
++
++  2. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ Ï.Î¬ÎœÏ. ÎŒÎ­ÏÎ¿Ï. Î±Ï.Ï.Î®Ï. Ï.Î·Ï. Ï.ÎµÎ»Î¯ÎŽÎ±Ï. ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ
++     Ctrl-g  Î³Î¹Î± ÎœÎ± Î²ÏÎµÎ¯Ï.Îµ Ï.Î¿Îœ Î±ÏÎ¹ÎžÎŒÏ. Î±Ï.Ï.Î®Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++     ÎÎ. Î.Î¥Î.Î.Î£Î€Î. Î.Î¥Î€Î.Î Î€Î.Î Î.Î¡Î.Î.Î.Î.!
++
++  3. Î€Ï.ÏÎ± Ï.Î·Î³Î±Î¯ÎœÎµÏ.Îµ Ï.Ï.Î¿ ÎºÎ¬Ï.Ï. ÎŒÎ­ÏÎ¿Ï. Ï.Î·Ï. Ï.ÎµÎ»Î¯ÎŽÎ±Ï. ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ  Ctrl-g  ÎŸÎ±ÎœÎ¬.
++     ÎÎ. Î.Î¥Î.Î.Î£Î€Î. Î.Î.Î. Î.Î¥Î€Î.Î Î€Î.Î Î.Î¡Î.Î.Î.Î.!
++
++  4. Î.Î¹Î± ÎœÎ± Ï.Ï.Ï.ÎµÏ.Îµ Î.Î.ÎÎ. Î­ÎœÎ± Ï.ÎŒÎ®ÎŒÎ± Ï.Îµ Î±ÏÏ.ÎµÎ¯Î¿, Î³ÏÎ¬Ï.Ï.Îµ   :#,# w TEST
++     Ï.Ï.Î¿Ï. #,# Î¿Î¹ ÎŽÏÎ¿ Î±ÏÎ¹ÎžÎŒÎ¿Î¯ Ï.Î¿Ï. Î±Ï.Î¿ÎŒÎœÎ·ÎŒÎ¿ÎœÎµÏÏ.Î±Ï.Îµ (Ï.Î¬ÎœÏ.,ÎºÎ¬Ï.Ï.) ÎºÎ±Î¹ TEST Ï.Î¿
++     Ï.ÎœÎ¿ÎŒÎ± Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï. Ï.Î±Ï..
++
++  5. Î.Î±ÎœÎ¬, ÎŽÎµÎ¯Ï.Îµ Ï.Ï.Î¹ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎµÎ¯ÎœÎ±Î¹ ÎµÎºÎµÎ¯ ÎŒÎµ Ï.Î·Îœ  :!dir Î±Î»Î»Î¬ Î.Î.Î Ï.Î¿ ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÏ.Îµ.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Î.Î¬ÎžÎ·ÎŒÎ± 5.4: Î.ÎÎ.Î.Î€Î©ÎÎ€Î.Î£ Î.Î.Î. Î.ÎÎ©ÎÎ.ÎÎ€Î.Î£ Î.Î¡Î§Î.Î.Î.
++
++
++     ** Î.Î¹Î± ÎœÎ± ÎµÎ¹Ï.Î¬Î³ÎµÏ.Îµ Ï.Î± Ï.ÎµÏÎ¹ÎµÏ.Ï.ÎŒÎµÎœÎ± ÎµÎœÏ.Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï., Î³ÏÎ¬Ï.Ï.Îµ   :r Î.Î¡Î§Î.Î.Î. **
++
++  1. Î.ÏÎ¬Ï.Ï.Îµ  :!dir  Î³Î¹Î± ÎœÎ± Î²ÎµÎ²Î±Î¹Ï.ÎžÎµÎ¯Ï.Îµ Ï.Ï.Î¹ Ï.Î¿ TEST Ï.Ï.Î¬ÏÏ.ÎµÎ¹ Î±Ï.Ï. Ï.ÏÎ¹Îœ.
++
++  2. Î€Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ Ï.Î¬ÎœÏ. ÎŒÎ­ÏÎ¿Ï. Ï.Î·Ï. Ï.ÎµÎ»Î¯ÎŽÎ±Ï..
++
++Î£Î.Î.Î.Î.Î©Î£Î.:  Î.Ï.Ï.Ï.Î¿Ï. ÎµÎºÏ.ÎµÎ»Î­Ï.ÎµÏ.Îµ Ï.Î¿ Î.Î®ÎŒÎ± 3 ÎžÎ± ÎŽÎµÎ¯Ï.Îµ Ï.Î¿ Î.Î¬ÎžÎ·ÎŒÎ± 5.3.
++	   Î.ÎµÏ.Î¬ ÎºÎ¹ÎœÎ·ÎžÎµÎ¯Ï.Îµ Î.Î.Î€Î© ÎŸÎ±ÎœÎ¬ Ï.ÏÎ¿Ï. Ï.Î¿ ÎŒÎ¬ÎžÎ·ÎŒÎ± Î±Ï.Ï.Ï..
++
++  3. Î€Ï.ÏÎ± Î±ÎœÎ±ÎºÏ.Î®Ï.Ï.Îµ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Ï.Î±Ï. TEST Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Ï.ÎœÏ.Î±Ï. Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î®  :r TEST
++     Ï.Ï.Î¿Ï. TEST ÎµÎ¯ÎœÎ±Î¹ Ï.Î¿ Ï.ÎœÎ¿ÎŒÎ± Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï..
++
++Î£Î.Î.Î.Î.Î©Î£Î.:  Î€Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Ï.Î¿Ï. Î±ÎœÎ±ÎºÏ.Î¬Ï.Îµ Ï.Î¿Ï.Î¿ÎžÎµÏ.ÎµÎ¯Ï.Î±Î¹ ÎŸÎµÎºÎ¹ÎœÏ.ÎœÏ.Î±Ï. ÎµÎºÎµÎ¯ Ï.Î¿Ï. Î²ÏÎ¯Ï.ÎºÎµÏ.Î±Î¹
++	   Î¿ ÎŽÏÎ¿ÎŒÎ­Î±Ï..
++
++  4. Î.Î¹Î± ÎœÎ± ÎµÏ.Î±Î»Î·ÎžÎµÏÏ.ÎµÏ.Îµ Ï.Ï.Î¹ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ Î±ÎœÎ±ÎºÏ.Î®ÎžÎ·ÎºÎµ, Ï.Î¯Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎºÎ±Î¹
++     Ï.Î±ÏÎ±Ï.Î·ÏÎ®Ï.Ï.Îµ Ï.Ï.Î¹ Ï.Ï.Î¬ÏÏ.Î¿Ï.Îœ Ï.Ï.ÏÎ± ÎŽÏÎ¿ Î±ÎœÏ.Î¯Î³ÏÎ±Ï.Î± Ï.Î¿Ï. Î.Î±ÎžÎ®ÎŒÎ±Ï.Î¿Ï. 5.3, Ï.Î¿
++     Î±ÏÏ.Î¹ÎºÏ. ÎºÎ±Î¹ Î· Î­ÎºÎŽÎ¿Ï.Î· Ï.Î¿Ï. Î±ÏÏ.ÎµÎ¯Î¿Ï..
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 5 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1.  :!ÎµÎœÏ.Î¿Î»Î®  ÎµÎºÏ.ÎµÎ»ÎµÎ¯ ÎŒÎ¯Î± ÎµÎŸÏ.Ï.ÎµÏÎ¹ÎºÎ® ÎµÎœÏ.Î¿Î»Î®.
++
++      Î.ÎµÏÎ¹ÎºÎ¬ Ï.ÏÎ®Ï.Î¹ÎŒÎ± Ï.Î±ÏÎ±ÎŽÎµÎ¯Î³ÎŒÎ±Ï.Î± ÎµÎ¯ÎœÎ±Î¹ (MS-DOS):
++      :!dir            - ÎµÎŒÏ.Î¬ÎœÎ¹Ï.Î· Î»Î¯Ï.Ï.Î±Ï. ÎµÎœÏ.Ï. ÎºÎ±Ï.Î±Î»Ï.Î³Î¿Ï..
++      :!del Î.Î¡Î§Î.Î.Î.     - ÎŽÎ¹Î±Î³ÏÎ¬Ï.ÎµÎ¹ Ï.Î¿ Î.Î¡Î§Î.Î.Î..
++
++  2.  :w Î.Î¡Î§Î.Î.Î.   Î³ÏÎ¬Ï.ÎµÎ¹ Ï.Î¿ Ï.ÏÎ­Ï.Ï.Îœ Î±ÏÏ.ÎµÎ¯Î¿ Ï.Î¿Ï. Vim Ï.Ï.Î¿ ÎŽÎ¯Ï.ÎºÎ¿ ÎŒÎµ Ï.ÎœÎ¿ÎŒÎ± Î.Î¡Î§Î.Î.Î..
++
++  3.  :#,#w Î.Î¡Î§Î.Î.Î.   Ï.Ï.Î¶ÎµÎ¹ Ï.Î¹Ï. Î³ÏÎ±ÎŒÎŒÎ­Ï. Î±Ï.Ï. # ÎŒÎ­Ï.ÏÎ¹ # Ï.Ï.Î¿ Î.Î¡Î§Î.Î.Î..
++
++  4.  :r Î.Î¡Î§Î.Î.Î.  Î±ÎœÎ±ÎºÏ.ÎµÎ¯ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎŽÎ¯Ï.ÎºÎ¿Ï. Î.Î¡Î§Î.Î.Î. ÎºÎ±Î¹ Ï.Î¿ Ï.Î±ÏÎµÎŒÎ²Î¬Î»Î»ÎµÎ¹ ÎŒÎ­Ï.Î±
++      Ï.Ï.Î¿ Ï.ÏÎ­Ï.Î¿Îœ Î±ÏÏ.ÎµÎ¯Î¿ ÎŒÎµÏ.Î¬ Î±Ï.Ï. Ï.Î· ÎžÎ­Ï.Î· Ï.Î¿Ï. ÎŽÏÎ¿ÎŒÎ­Î±.
++
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Î.Î¬ÎžÎ·ÎŒÎ± 6.1: Î. Î.ÎÎ€Î.Î.Î. Î.ÎÎ.Î.Î.Î.Î.Î€Î.Î£
++
++
++      ** Î Î±Ï.Î®Ï.Ï.Îµ  o  Î³Î¹Î± ÎœÎ± Î±ÎœÎ¿Î¯ÎŸÎµÏ.Îµ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ® ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎºÎ±Î¹ ÎœÎ±
++	 Î²ÏÎµÎžÎµÎ¯Ï.Îµ Ï.Îµ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.ÎµÎ¹ÎŒÎ­ÎœÎ¿Ï.. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î Î±Ï.Î®Ï.Ï.Îµ  o (Ï.ÎµÎ¶Ï.) Î³Î¹Î± ÎœÎ± Î±ÎœÎ¿Î¯ÎŸÎµÏ.Îµ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ® Î.Î.Î€Î© Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎºÎ±Î¹ ÎœÎ±
++     Î²ÏÎµÎžÎµÎ¯Ï.Îµ Ï.Îµ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.ÎµÎ¹ÎŒÎ­ÎœÎ¿Ï..
++
++  3. Î€Ï.ÏÎ± Î±ÎœÏ.Î¹Î³ÏÎ¬Ï.Ï.Îµ Ï.Î· Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ ---> Î³ÏÎ±ÎŒÎŒÎ®  ÎºÎ±Î¹ Ï.Î±Ï.Î®Ï.Ï.Îµ <ESC> Î³Î¹Î± ÎœÎ±
++     Î²Î³ÎµÎ¯Ï.Îµ Î±Ï.Ï. Ï.Î·Îœ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.ÎµÎ¹ÎŒÎ­ÎœÎ¿Ï..
++
++---> After typing  o  the cursor is placed on the open line in Insert mode.
++
++  4. Î.Î¹Î± ÎœÎ± Î±ÎœÎ¿Î¯ÎŸÎµÏ.Îµ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ® Î Î.ÎÎ© Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±, Ï.Î±Ï.Î®Ï.Ï.Îµ Î±Ï.Î»Î¬ Î­ÎœÎ± ÎºÎµÏ.Î±Î»Î±Î¯Î¿
++     O, Î±ÎœÏ.Î¯ Î³Î¹Î± Î­ÎœÎ± Ï.ÎµÎ¶Ï.  o.  Î.Î¿ÎºÎ¹ÎŒÎ¬Ï.Ï.Îµ Ï.Î¿ Ï.Ï.Î·Îœ Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Î³ÏÎ±ÎŒÎŒÎ®.
++Î.ÎœÎ¿Î¯Î³ÎµÏ.Îµ Î³ÏÎ±ÎŒÎŒÎ® Ï.Î¬ÎœÏ. Î±Ï.Ï. Î±Ï.Ï.Î®Îœ Ï.Î±Ï.Ï.ÎœÏ.Î±Ï. Shift-O Ï.Ï.Î¿ Î¿ ÎŽÏÎ¿ÎŒÎ­Î±Ï. ÎµÎ¯ÎœÎ±Î¹ Ï.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Î.Î¬ÎžÎ·ÎŒÎ± 6.2: Î. Î.ÎÎ€Î.Î.Î. Î Î¡Î.Î£Î.Î.Î.Î.Î£
++
++	  ** Î Î±Ï.Î®Ï.Ï.Îµ   a   Î³Î¹Î± ÎœÎ± ÎµÎ¹Ï.Î¬Î³ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Î.Î.Î€Î. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Ï.ÏÏ.Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï. Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï.
++     Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ ---> Ï.Î±Ï.Ï.ÎœÏ.Î±Ï.  $  Ï.Ï.Î·Îœ Î.Î±ÎœÎ¿ÎœÎ¹ÎºÎ® Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î·.
++
++  2. Î Î±Ï.Î®Ï.Ï.Îµ Î­ÎœÎ±  a  (Ï.ÎµÎ¶Ï.) Î³Î¹Î± ÎœÎ± Ï.ÏÎ¿Ï.ÎžÎ­Ï.ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Î.Î.Î€Î. Î±Ï.Ï. Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±
++     Ï.Î¿Ï. ÎµÎ¯ÎœÎ±Î¹ ÎºÎ¬Ï.Ï. Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î±.  (Î€Î¿ ÎºÎµÏ.Î±Î»Î±Î¯Î¿  A  Ï.ÏÎ¿Ï.ÎžÎ­Ï.ÎµÎ¹ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï.
++     Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.).
++
++Î£Î·ÎŒÎµÎ¯Ï.Ï.Î·: Î.Ï.Ï.Ï. Î±Ï.Î¿Ï.ÎµÏÎ³ÎµÎ¹ Ï.Î¿ Ï.Î¬Ï.Î·ÎŒÎ± Ï.Î¿Ï.  i , Ï.Î¿Îœ Ï.ÎµÎ»ÎµÏ.Ï.Î±Î¯Î¿ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ±, Ï.Î¿
++	  ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Î·Ï. ÎµÎ¹Ï.Î±Î³Ï.Î³Î®Ï., <ESC>, ÎŽÏÎ¿ÎŒÎ­Î±-ÎŽÎµÎŸÎ¹Î¬, ÎºÎ±Î¹ Ï.Î­Î»Î¿Ï., x, ÎŒÏ.ÎœÎ¿ ÎºÎ±Î¹
++	  ÎŒÏ.ÎœÎ¿ Î³Î¹Î± ÎœÎ± Ï.ÏÎ¿Ï.ÎžÎ­Ï.ÎµÏ.Îµ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï. Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï.!
++
++  3. Î£Ï.ÎŒÏ.Î»Î·ÏÏ.Ï.Ï.Îµ Ï.Ï.ÏÎ± Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®. Î£Î·ÎŒÎµÎ¹Ï.Ï.Ï.Îµ ÎµÏ.Î¯Ï.Î·Ï. Ï.Ï.Î¹ Î· Ï.ÏÎ¿Ï.ÎžÎ®ÎºÎ· ÎµÎ¯ÎœÎ±Î¹
++     Î±ÎºÏÎ¹Î²Ï.Ï. Î¯ÎŽÎ¹Î± Ï.Ï.Î·Îœ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.ÎµÎ¹ÎŒÎ­ÎœÎ¿Ï. ÎŒÎµ Ï.Î·Îœ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.Î¹Ï.Î±Î³Ï.Î³Î®Ï., ÎµÎºÏ.Ï.Ï.
++     Î±Ï.Ï. Ï.Î· ÎžÎ­Ï.Î· Ï.Î¿Ï. ÎµÎ¹Ï.Î¬Î³ÎµÏ.Î±Î¹ Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿.
++
++---> This line will allow you to practice
++---> This line will allow you to practice appending text to the end of a line.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Î.Î¬ÎžÎ·ÎŒÎ± 6.3: Î.Î.Î.Î. Î.Î.Î.Î.Î£Î. Î€Î.Î£ Î.ÎÎ€Î.Î.Î.Î€Î.Î£Î€Î.Î£Î.Î£
++
++
++ ** Î Î±Ï.Î®Ï.Ï.Îµ ÎºÎµÏ.Î±Î»Î±Î¯Î¿  R  Î³Î¹Î± ÎœÎ± Î±Î»Î»Î¬ÎŸÎµÏ.Îµ Ï.ÎµÏÎ¹Ï.Ï.Ï.Ï.ÎµÏÎ¿Ï.Ï. Î±Ï.Ï. Î­ÎœÎ±Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎµÏ.. **
++
++  1. Î.ÎµÏ.Î±ÎºÎ¹ÎœÎµÎ¯Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î±ÏÎ±ÎºÎ¬Ï.Ï. Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ --->.
++
++  2. Î€Î¿Ï.Î¿ÎžÎµÏ.Î®Ï.Ï.Îµ Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Î±ÏÏ.Î® Ï.Î·Ï. Ï.ÏÏ.Ï.Î·Ï. Î»Î­ÎŸÎ·Ï. Ï.Î¿Ï. ÎµÎ¯ÎœÎ±Î¹ ÎŽÎ¹Î±Ï.Î¿ÏÎµÏ.Î¹ÎºÎ®
++     Î±Ï.Ï. Ï.Î· ÎŽÎµÏÏ.ÎµÏÎ· Î³ÏÎ±ÎŒÎŒÎ® Ï.Î·ÎŒÎµÎ¹Ï.ÎŒÎ­ÎœÎ· ÎŒÎµ ---> (Î· Î»Î­ÎŸÎ· 'last').
++
++  3. Î Î±Ï.Î®Ï.Ï.Îµ Ï.Ï.ÏÎ±  R   ÎºÎ±Î¹ Î±Î»Î»Î¬ÎŸÏ.Îµ Ï.Î¿ Ï.Ï.Ï.Î»Î¿Î¹Ï.Î¿ Ï.Î¿Ï. ÎºÎµÎ¹ÎŒÎ­ÎœÎ¿Ï. Ï.Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ®
++     Î³ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï. Ï.Î¬ÎœÏ. Î±Ï.Ï. Ï.Î¿ Ï.Î±Î»Î¹Ï. ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Ï.Ï.Îµ ÎœÎ± ÎºÎ¬ÎœÎµÏ.Îµ Ï.Î·Îœ Ï.ÏÏ.Ï.Î· Î³ÏÎ±ÎŒÎŒÎ® Î¯ÎŽÎ¹Î±
++     ÎŒÎµ Ï.Î· ÎŽÎµÏÏ.ÎµÏÎ·.
++
++---> To make the first line the same as the last on this page use the keys.
++---> To make the first line the same as the second, type R and the new text.
++
++  4. Î£Î·ÎŒÎµÎ¹Ï.Ï.Ï.Îµ Ï.Ï.Î¹ Ï.Ï.Î±Îœ Ï.Î±Ï.Î¬Ï.Îµ <ESC> Î³Î¹Î± ÎœÎ± Î²Î³ÎµÎ¯Ï.Îµ, Ï.Î±ÏÎ±ÎŒÎ­ÎœÎµÎ¹ Î¿Ï.Î¿Î¹Î¿ÎŽÎ®Ï.Î¿Ï.Îµ
++     Î±ÎœÎ±Î»Î»Î¿Î¯Ï.Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Î.Î¬ÎžÎ·ÎŒÎ± 6.4: Î¡Î¥Î.Î.Î.Î£Î. Î.Î Î.Î.Î.Î.Î.Î£
++
++
++   ** Î¡Ï.ÎžÎŒÎ¯Ï.Ï.Îµ ÎŒÎ¯Î± ÎµÏ.Î¹Î»Î¿Î³Î® Î­Ï.Ï.Î¹ Ï.Ï.Ï.Îµ Î· Î±ÎœÎ±Î¶Î®Ï.Î·Ï.Î· Î® Î· Î±ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î· ÎœÎ± Î±Î³ÎœÎ¿ÎµÎ¯
++      Ï.Î· ÎŽÎ¹Î±Ï.Î¿ÏÎ¬ Ï.ÎµÎ¶Ï.Îœ-ÎºÎµÏ.Î±Î»Î±Î¯Ï.Îœ **
++
++  1. ÎšÎ¬ÎŸÏ.Îµ Î³Î¹Î± 'ignore' ÎµÎ¹Ï.Î¬Î³Î¿ÎœÏ.Î±Ï.:
++     /ignore
++     Î£Ï.ÎœÎµÏ.Î¯Ï.Ï.Îµ Î±ÏÎºÎµÏ.Î­Ï. Ï.Î¿ÏÎ­Ï. Ï.Î±Ï.Ï.ÎœÏ.Î±Ï. Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ n.
++
++  2. Î.Î­Ï.Ï.Îµ Ï.Î·Îœ ÎµÏ.Î¹Î»Î¿Î³Î® 'ic' (Ignore case) Î³ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï.:
++     :set ic
++
++  3. ÎšÎ¬ÎŸÏ.Îµ Ï.Ï.ÏÎ± ÎŸÎ±ÎœÎ¬ Î³Î¹Î± 'ignore' Ï.Î±Ï.Ï.ÎœÏ.Î±Ï.: n
++     Î£Ï.ÎœÎµÏ.Î¯Ï.Ï.Îµ Ï.Î·Îœ Î±ÎœÎ±Î¶Î®Ï.Î·Ï.Î· ÎŒÎµÏÎ¹ÎºÎ­Ï. Î±ÎºÏ.ÎŒÎ± Ï.Î¿ÏÎ­Ï. Ï.Î±Ï.Ï.ÎœÏ.Î±Ï. Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ n
++
++  4. Î.Î­Ï.Ï.Îµ Ï.Î¹Ï. ÎµÏ.Î¹Î»Î¿Î³Î­Ï. 'hlsearch' ÎºÎ±Î¹ 'incsearch':
++     :set hls is
++
++  5. Î.Î¹Ï.Î¬Î³ÎµÏ.Îµ Ï.Ï.ÏÎ± ÎŸÎ±ÎœÎ¬ Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î® Î±ÎœÎ±Î¶Î®Ï.Î·Ï.Î·Ï., ÎºÎ±Î¹ ÎŽÎµÎ¯Ï.Îµ Ï.Î¹ Ï.Ï.ÎŒÎ²Î±Î¯ÎœÎµÎ¹
++     /ignore
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			       Î.Î.Î.Î.Î.Î. 6 Î Î.Î¡Î.Î.Î.ÎšÎ.
++
++
++  1. Î Î±Ï.Ï.ÎœÏ.Î±Ï.  o  Î±ÎœÎ¿Î¯Î³ÎµÎ¹ ÎŒÎ¯Î± Î³ÏÎ±ÎŒÎŒÎ® Î.Î.Î€Î© Î±Ï.Ï. Ï.Î¿Îœ ÎŽÏÎ¿ÎŒÎ­Î± ÎºÎ±Î¹ Ï.Î¿Ï.Î¿ÎžÎµÏ.ÎµÎ¯ Ï.Î¿Îœ
++     ÎŽÏÎ¿ÎŒÎ­Î± Ï.Ï.Î·Îœ Î±ÎœÎ¿Î¹Ï.Ï.Î® Î³ÏÎ±ÎŒÎŒÎ® Ï.Îµ Î.Î±Ï.Î¬Ï.Ï.Î±Ï.Î· Î.ÎµÎ¹ÎŒÎ­ÎœÎ¿Ï..
++
++  2. Î Î±Ï.Î®Ï.Ï.Îµ  a  Î³Î¹Î± ÎœÎ± ÎµÎ¹Ï.Î¬Î³ÎµÏ.Îµ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Î.Î.Î€Î. Ï.Î¿Îœ Ï.Î±ÏÎ±ÎºÏ.Î®ÏÎ± Ï.Ï.Î¿Îœ Î¿Ï.Î¿Î¯Î¿ ÎµÎ¯ÎœÎ±Î¹
++     Î¿ ÎŽÏÎ¿ÎŒÎ­Î±Ï.. Î Î±Ï.Ï.ÎœÏ.Î±Ï. ÎºÎµÏ.Î±Î»Î±Î¯Î¿  A  Î±Ï.Ï.Ï.ÎŒÎ±Ï.Î± Ï.ÏÎ¿Ï.ÎžÎ­Ï.ÎµÎ¹ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Ï.Î¿ Ï.Î­Î»Î¿Ï.
++     Ï.Î·Ï. Î³ÏÎ±ÎŒÎŒÎ®Ï..
++
++  3. Î Î±Ï.Ï.ÎœÏ.Î±Ï. ÎºÎµÏ.Î±Î»Î±Î¯Î¿  R  ÎµÎ¹Ï.Î­ÏÏ.ÎµÏ.Î±Î¹ Ï.Ï.Î·Îœ Î.Î±Ï.Î¬Ï.Ï.Î±Î· Î.ÎœÏ.Î¹ÎºÎ±Ï.Î¬Ï.Ï.Î±Ï.Î·Ï. ÎŒÎ­Ï.ÏÎ¹ ÎœÎ±
++     Ï.Î±Ï.Î·ÎžÎµÎ¯ Ï.Î¿ <ESC> ÎºÎ±Î¹ ÎœÎ± ÎµÎŸÎ­Î»ÎžÎµÎ¹.
++
++  4. Î.ÏÎ¬Ï.Î¿ÎœÏ.Î±Ï. ":set xxx" ÏÏ.ÎžÎŒÎ¯Î¶ÎµÎ¹ Ï.Î·Îœ ÎµÏ.Î¹Î»Î¿Î³Î® "xxx".
++
++
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		       Î.Î.Î.Î.Î.Î. 7: ON-LINE Î.ÎÎ€Î.Î.Î.Î£ Î.Î.Î.Î.Î.Î.Î.Î£
++
++
++		** Î§ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î®Ï.Ï.Îµ Ï.Î¿ on-line Ï.ÏÏ.Ï.Î·ÎŒÎ± Î²Î¿Î®ÎžÎµÎ¹Î±Ï. **
++
++  Î. Vim Î­Ï.ÎµÎ¹ Î­ÎœÎ± Ï.ÎµÏÎ¹ÎµÎºÏ.Î¹ÎºÏ. on-line Ï.ÏÏ.Ï.Î·ÎŒÎ± Î²Î¿Î®ÎžÎµÎ¹Î±Ï.. Î.Î¹Î± ÎœÎ± ÎŸÎµÎºÎ¹ÎœÎ®Ï.ÎµÎ¹,
++  ÎŽÎ¿ÎºÎ¹ÎŒÎ¬Ï.Ï.Îµ ÎºÎ¬Ï.Î¿Î¹Î¿ Î±Ï.Ï. Ï.Î± Ï.ÏÎ¯Î±:
++	- Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ <HELP> (Î±Îœ Î­Ï.ÎµÏ.Îµ ÎºÎ¬Ï.Î¿Î¹Î¿)
++	- Ï.Î±Ï.Î®Ï.Ï.Îµ Ï.Î¿ Ï.Î»Î®ÎºÏ.ÏÎ¿ <F1> (Î±Îœ Î­Ï.ÎµÏ.Îµ ÎºÎ¬Ï.Î¿Î¹Î¿)
++	- Î³ÏÎ¬Ï.Ï.Îµ   :help <ENTER>
++
++  Î.ÏÎ¬Ï.Ï.Îµ  :q <ENTER>   Î³Î¹Î± ÎœÎ± ÎºÎ»ÎµÎ¯Ï.ÎµÏ.Îµ Ï.Î¿ Ï.Î±ÏÎ¬ÎžÏ.ÏÎ¿ Ï.Î·Ï. Î²Î¿Î®ÎžÎµÎ¹Î±Ï..
++
++  Î.Ï.Î¿ÏÎµÎ¯Ï.Îµ ÎœÎ± Î²ÏÎµÎ¯Ï.Îµ Î²Î¿Î®ÎžÎµÎ¹Î± Ï.Î¬ÎœÏ. Ï.Îµ ÎºÎ¬ÎžÎµ Î±ÎœÏ.Î¹ÎºÎµÎ¯ÎŒÎµÎœÎ¿, ÎŽÎ¯ÎœÎ¿ÎœÏ.Î±Ï. ÎŒÎ¯Î± Ï.Î±ÏÎ¬ÎŒÎµÏ.ÏÎ¿
++  Ï.Ï.Î·Îœ ÎµÎœÏ.Î¿Î»Î® ":help".  Î.Î¿ÎºÎ¹ÎŒÎ¬Ï.Ï.Îµ Î±Ï.Ï.Î¬ (ÎŒÎ·Îœ ÎŸÎµÏ.ÎœÎ¬Ï.Îµ ÎœÎ± Ï.Î±Ï.Î¬Ï.Îµ <ENTER>):
++
++	:help w
++	:help c_<T
++	:help insert-index
++	:help user-manual
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Î.Î.Î.Î.Î.Î. 8: Î.Î.Î.Î.Î.Î¥Î¡Î.Î.Î£Î€Î. Î.ÎÎ. SCRIPT Î.Î.Î.Î.ÎÎ.Î£Î.Î£
++
++		   ** Î.ÎœÎµÏÎ³Î¿Ï.Î¿Î¹Î®Ï.Ï.Îµ Ï.Î±ÏÎ±ÎºÏ.Î·ÏÎ¹Ï.Ï.Î¹ÎºÎ¬ Ï.Î¿Ï. Vim **
++
++  Î. Vim Î­Ï.ÎµÎ¹ Ï.Î¿Î»Î»Î¬ Ï.ÎµÏÎ¹Ï.Ï.Ï.Ï.ÎµÏÎ± Ï.Î±ÏÎ±ÎºÏ.Î·ÏÎ¹Ï.Ï.Î¹ÎºÎ¬ Î±Ï.' Ï.,Ï.Î¹ Î¿ Vi, Î±Î»Î»Î¬ Ï.Î±
++  Ï.ÎµÏÎ¹Ï.Ï.Ï.Ï.ÎµÏÎ± ÎµÎ¯ÎœÎ±Î¹ Î±ÏÏ.Î¹ÎºÎ¬ Î±Ï.ÎµÎœÎµÏÎ³Î¿Ï.Î¿Î¹Î·ÎŒÎ­ÎœÎ±. Î.Î¹Î± ÎœÎ± Î±ÏÏ.Î¯Ï.ÎµÏ.Îµ ÎœÎ± Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹ÎµÎ¯Ï.Îµ
++  Ï.ÎµÏÎ¹Ï.Ï.Ï.Ï.ÎµÏÎ± Ï.Î±ÏÎ±ÎºÏ.Î·ÏÎ¹Ï.Ï.Î¹ÎºÎ¬ Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ± Ï.Ï.Î¹Î¬ÎŸÎµÏ.Îµ Î­ÎœÎ± Î±ÏÏ.ÎµÎ¯Î¿ "vimrc".
++
++  1. Î.ÏÏ.Î¯Ï.Ï.Îµ ÎŽÎ¹Î¿ÏÎžÏ.ÎœÎ¿ÎœÏ.Î±Ï. Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ "vimrc", Î±Ï.Ï.Ï. ÎµÎŸÎ±ÏÏ.Î¬Ï.Î±Î¹ Î±Ï.Ï. Ï.Î¿ Ï.ÏÏ.Ï.Î·ÎŒÎ¬ Ï.Î±Ï.:
++	:edit ~/.vimrc               Î³Î¹Î± Unix
++	:edit $VIM/_vimrc            Î³Î¹Î± MS-Windows
++
++  2. Î€Ï.ÏÎ± ÎµÎ¹Ï.Î¬Î³ÎµÏ.Îµ Ï.Î¿ ÎºÎµÎ¯ÎŒÎµÎœÎ¿ Ï.Î±ÏÎ±ÎŽÎµÎ¯Î³ÎŒÎ±Ï.Î¿Ï. Î³Î¹Î± Î±ÏÏ.ÎµÎ¯Î¿ "vimrc":
++	:read $VIMRUNTIME/vimrc_example.vim
++
++  3. Î.ÏÎ¬Ï.Ï.Îµ Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ ÎŒÎµ Ï.Î·Îœ:
++	:write
++
++  Î€Î·Îœ ÎµÏ.Ï.ÎŒÎµÎœÎ· Ï.Î¿ÏÎ¬ Ï.Î¿Ï. ÎžÎ± ÎŸÎµÎºÎ¹ÎœÎ®Ï.ÎµÏ.Îµ Ï.Î¿Îœ Vim ÎžÎ± Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î®Ï.ÎµÎ¹ Ï.Ï.Ï.Î¹Ï.ÎŒÏ.
++  Ï.ÏÎœÏ.Î±ÎŸÎ·Ï..  Î.Ï.Î¿ÏÎµÎ¯Ï.Îµ ÎœÎ± Ï.ÏÎ¿Ï.ÎžÎ­Ï.ÎµÏ.Îµ Ï.Î»ÎµÏ. Ï.Î¹Ï. Ï.ÏÎ¿Ï.Î¹ÎŒÏ.ÎŒÎµÎœÎµÏ. ÎµÏ.Î¹Î»Î¿Î³Î­Ï. Ï.' Î±Ï.Ï.Ï.
++  Ï.Î¿ Î±ÏÏ.ÎµÎ¯Î¿ "vimrc".
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++
++  Î.ÎŽÏ. Î¿Î»Î¿ÎºÎ»Î·ÏÏ.ÎœÎµÏ.Î±Î¹ Ï.Î¿ Vim Tutor. Î£ÎºÎ¿Ï.Ï.Ï. Ï.Î¿Ï. Î®Ï.Î±Îœ ÎœÎ± ÎŽÏ.Ï.ÎµÎ¹ ÎŒÎ¯Î± Ï.ÏÎœÏ.Î¿ÎŒÎ·
++  Ï.ÎµÏÎ¯Î»Î·Ï.Î· Ï.Î¿Ï. Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î· Vim, Ï.Î¿Ï.Î»Î¬Ï.Î¹Ï.Ï.Î¿Îœ Ï.Ï.Ï.Î· Ï.Ï.Ï.Îµ ÎœÎ± Ï.Î±Ï. ÎµÏ.Î¹Ï.ÏÎ­Ï.ÎµÎ¹ ÎœÎ±
++  Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Î®Ï.ÎµÏ.Îµ Ï.Î¿Îœ Ï.Ï.ÎœÏ.Î¬ÎºÏ.Î· Î±ÏÎºÎµÏ.Î¬ ÎµÏÎºÎ¿Î»Î±. Î.Ï.Î­Ï.ÎµÎ¹ Ï.Î¿Î»Ï Î±Ï.Ï. ÎŒÎ¯Î±
++  Î¿Î»Î¿ÎºÎ»Î·ÏÏ.ÎŒÎ­ÎœÎ· Ï.Î±ÏÎ¿Ï.Ï.Î¯Î±Ï.Î· ÎºÎ±ÎžÏ.Ï. Î¿ Vim Î­Ï.ÎµÎ¹ Ï.Î¬ÏÎ± Ï.Î¿Î»Î»Î­Ï. ÎµÎœÏ.Î¿Î»Î­Ï.. Î.Î¹Î±Î²Î¬Ï.Ï.Îµ
++  ÎºÎ±Ï.Ï.Ï.Î¹Îœ Ï.Î¿ ÎµÎ³Ï.ÎµÎ¹ÏÎ¯ÎŽÎ¹Î¿ Ï.ÏÎ®Ï.Î·Ï.:
++	":help user-manual".
++
++  Î.Î¹Î± Ï.ÎµÏÎ±Î¹Ï.Î­ÏÏ. ÎŽÎ¹Î¬Î²Î±Ï.ÎŒÎ± ÎºÎ±Î¹ ÎŒÎµÎ»Î­Ï.Î·, Ï.Ï.Ï.Ï.Î®ÎœÎµÏ.Î±Î¹ Î±Ï.Ï.Ï. Ï.Î¿ Î²Î¹Î²Î»Î¯Î¿:
++	Vim - Vi Improved - by Steve Oualline
++	Publisher: New Riders
++	Î€Î¿ Ï.ÏÏ.Ï.Î¿ Î²Î¹Î²Î»Î¯Î¿ Ï.Î»Î®ÏÏ.Ï. Î±Ï.Î¹ÎµÏÏ.ÎŒÎ­ÎœÎ¿ Ï.Ï.Î¿Îœ Vim.
++	Î.ÎŽÎ¹Î±Î¯Ï.ÎµÏÎ± Ï.ÏÎ®Ï.Î¹ÎŒÎ¿ Î³Î¹Î± Î±ÏÏ.Î¬ÏÎ¹Î¿Ï.Ï..
++	Î¥Ï.Î¬ÏÏ.Î¿Ï.Îœ Ï.Î¿Î»Î»Î¬ Ï.Î±ÏÎ±ÎŽÎµÎ¯Î³ÎŒÎ±Ï.Î± ÎºÎ±Î¹ ÎµÎ¹ÎºÏ.ÎœÎµÏ..
++	Î.ÎµÎ¯Ï.Îµ Ï.Î·Îœ http://iccf-holland.org/click5.html
++
++  Î.Ï.Ï.Ï. Ï.Î¿ Î²Î¹Î²Î»Î¯Î¿ ÎµÎ¯ÎœÎ±Î¹ Ï.Î±Î»Î¹Ï.Ï.ÎµÏÎ¿ ÎºÎ±Î¹ Ï.ÎµÏÎ¹Ï.Ï.Ï.Ï.ÎµÏÎ¿ Î³Î¹Î± Ï.Î¿Îœ Vi Ï.Î±ÏÎ¬ Î³Î¹Î± Ï.Î¿Îœ Vim,
++  Î±Î»Î»Î¬ ÎµÏ.Î¯Ï.Î·Ï. Ï.Ï.ÎœÎ¹Ï.Ï.Ï.ÎŒÎµÎœÎ¿:
++	Learning the Vi Editor - by Linda Lamb
++	Publisher: O'Reilly & Associates Inc.
++	Î.Î¯ÎœÎ±Î¹ Î­ÎœÎ± ÎºÎ±Î»Ï. Î²Î¹Î²Î»Î¯Î¿ Î³Î¹Î± ÎœÎ± ÎŒÎ¬ÎžÎµÏ.Îµ Ï.Ï.ÎµÎŽÏ.Îœ Ï.Î± Ï.Î¬ÎœÏ.Î± Ï.Î¿Ï. ÎžÎ­Î»ÎµÏ.Îµ
++	ÎœÎ± ÎºÎ¬ÎœÎµÏ.Îµ ÎŒÎµ Ï.Î¿Îœ Vi.
++	Î. Î­ÎºÏ.Î· Î­ÎºÎŽÎ¿Ï.Î· Ï.ÎµÏÎ¹Î­Ï.ÎµÎ¹ Î±ÎºÏ.ÎŒÎ± Ï.Î»Î·ÏÎ¿Ï.Î¿ÏÎ¯ÎµÏ. Î³Î¹Î± Ï.Î¿Îœ Vim.
++
++  Î.Ï.Ï.Î® Î· Ï.ÎµÏÎ¹Î®Î³Î·Ï.Î· Î³ÏÎ¬Ï.Ï.Î·ÎºÎµ Î±Ï.Ï. Ï.Î¿Ï.Ï. Michael C. Pierce ÎºÎ±Î¹ Robert K. Ware,
++  Colorado School of Mines Ï.ÏÎ·Ï.Î¹ÎŒÎ¿Ï.Î¿Î¹Ï.ÎœÏ.Î±Ï. Î¹ÎŽÎ­ÎµÏ. Î±Ï.Ï. Ï.Î¿Îœ Charles Smith,
++  Colorado State University.  E-mail: bware@mines.colorado.edu.
++
++  Î ÏÎ¿Ï.Î±ÏÎŒÎ¿Î³Î® Î³Î¹Î± Ï.Î¿Îœ Vim Î±Ï.Ï. Ï.Î¿Îœ Bram Moolenaar.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+diff -Naur vim70.orig/runtime/tutor/tutor.ru.utf-8 vim70/runtime/tutor/tutor.ru.utf-8
+--- vim70.orig/runtime/tutor/tutor.ru.utf-8	1969-12-31 16:00:00.000000000 -0800
++++ vim70/runtime/tutor/tutor.ru.utf-8	2006-09-11 08:57:09.000000000 -0700
+@@ -0,0 +1,834 @@
++===============================================================================
++=    Ð. ÐŸ Ð± Ñ. ÐŸ   Ð¿ ÐŸ Ð¶ Ð° Ð» ÐŸ Ð² Ð° Ñ. Ñ.   Ð²   Ñ. Ñ. Ðµ Ð± Ðœ Ðž Ðº   VIM  -  Ð.ÐµÑ.ÑÐžÑ 1.5 =
++===============================================================================
++     Vim --- ÑÑ.ÐŸ ÐŸÑ.ÐµÐœÑ. ÐŒÐŸÑ.ÐœÑ.Ð¹ Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ., ÐžÐŒÐµÑ.Ñ.ÐžÐ¹ ÐŒÐœÐŸÐ¶ÐµÑÑ.Ð²ÐŸ ÐºÐŸÐŒÐ°ÐœÐŽ, ÑÐ»ÐžÑ.ÐºÐŸÐŒ
++     ÐŒÐœÐŸÐ³ÐŸ ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. ÐžÑ. Ð²ÑÐµ ÐŒÐŸÐ¶ÐœÐŸ Ð±Ñ.Ð»ÐŸ ÐŸÐ¿ÐžÑÐ°Ñ.Ñ. Ð² Ñ.Ð°ÐºÐŸÐŒ Ñ.Ñ.ÐµÐ±ÐœÐžÐºÐµ, ÐºÐ°Ðº
++     ÑÑ.ÐŸÑ.. Ð­Ñ.ÐŸÑ. Ñ.Ñ.ÐµÐ±ÐœÐžÐº Ð¿Ñ.ÐžÐ·Ð²Ð°Ðœ ÐŸÐ±Ñ.ÑÑÐœÐžÑ.Ñ. ÐŽÐŸÑÑ.Ð°Ñ.ÐŸÑ.ÐœÐŸÐµ Ñ.ÐžÑÐ»ÐŸ ÐºÐŸÐŒÐ°ÐœÐŽ ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ,
++     Ñ.Ñ.ÐŸÐ±Ñ. Ð.Ñ. ÐŒÐŸÐ³Ð»Ðž Ñ Ð»ÐµÐ³ÐºÐŸÑÑ.Ñ.Ñ. ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.Ñ. Vim Ð² ÐºÐ°Ñ.ÐµÑÑ.Ð²Ðµ Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ.Ð° ÐŸÐ±Ñ.ÐµÐ³ÐŸ
++     ÐœÐ°Ð·ÐœÐ°Ñ.ÐµÐœÐžÑ.
++
++     Ð.Ð°ÐŒ Ð¿ÐŸÑ.Ñ.ÐµÐ±Ñ.ÐµÑ.ÑÑ Ð¿Ñ.ÐžÐ±Ð»ÐžÐ·ÐžÑ.ÐµÐ»Ñ.ÐœÐŸ 25-30 ÐŒÐžÐœÑ.Ñ. ÐœÐ° ÐŸÑÐ²ÐŸÐµÐœÐžÐµ ÐŽÐ°ÐœÐœÐŸÐ³ÐŸ Ñ.Ñ.ÐµÐ±ÐœÐžÐºÐ° Ð²
++     Ð·Ð°Ð²ÐžÑÐžÐŒÐŸÑÑ.Ðž ÐŸÑ. Ñ.ÐŸÐ³ÐŸ, ÑÐºÐŸÐ»Ñ.ÐºÐŸ Ð²Ñ.ÐµÐŒÐµÐœÐž Ð.Ñ. Ð¿ÐŸÑ.Ñ.Ð°Ñ.ÐžÑ.Ðµ ÐœÐ° ÑÐºÑÐ¿ÐµÑ.ÐžÐŒÐµÐœÑ.Ñ..
++
++     Ð.ÐŸÐŒÐ°ÐœÐŽÑ. Ð² Ñ.Ñ.ÐŸÐºÐ°Ñ. Ð±Ñ.ÐŽÑ.Ñ. ÐŒÐŸÐŽÐžÑ.ÐžÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ. Ñ.ÐµÐºÑÑ.. Ð¡ÐŸÐ·ÐŽÐ°Ð¹Ñ.Ðµ ÐºÐŸÐ¿ÐžÑ. ÑÑ.ÐŸÐ³ÐŸ Ñ.Ð°Ð¹Ð»Ð°,
++     Ñ.Ñ.ÐŸÐ±Ñ. Ð¿ÐŸÐ¿Ñ.Ð°ÐºÑ.ÐžÐºÐŸÐ²Ð°Ñ.Ñ.ÑÑ ÐœÐ° ÐœÐµÐ¹ (ÐµÑÐ»Ðž Ð.Ñ. Ð·Ð°Ð¿Ñ.ÑÑ.ÐžÐ»Ðž "vimtutor", Ñ.ÐŸ ÑÑ.ÐŸ Ñ.Ð¶Ðµ
++     ÐºÐŸÐ¿ÐžÑ).
++
++     Ð.Ð°Ð¶ÐœÐŸ Ð¿ÐŸÐŒÐœÐžÑ.Ñ., Ñ.Ñ.ÐŸ ÑÑ.ÐŸÑ. Ñ.Ñ.ÐµÐ±ÐœÐžÐº Ð¿Ñ.ÐµÐŽÐœÐ°Ð·ÐœÐ°Ñ.ÐµÐœ ÐŽÐ»Ñ ÐŸÐ±Ñ.Ñ.ÐµÐœÐžÑ Ð² Ð¿Ñ.ÐŸÑ.ÐµÑÑÐµ
++     ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°ÐœÐžÑ. Ð­Ñ.ÐŸ ÐŸÐ·ÐœÐ°Ñ.Ð°ÐµÑ., Ñ.Ñ.ÐŸ Ð.Ñ. ÐŽÐŸÐ»Ð¶ÐœÑ. Ð·Ð°Ð¿Ñ.ÑÐºÐ°Ñ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ,
++     Ñ.Ñ.ÐŸÐ±Ñ. ÐºÐ°Ðº ÑÐ»ÐµÐŽÑ.ÐµÑ. ÐžÑ. ÐžÐ·Ñ.Ñ.ÐžÑ.Ñ.. Ð.ÑÐ»Ðž Ð.Ñ. Ð¿Ñ.ÐŸÑÑ.ÐŸ Ð¿Ñ.ÐŸÑ.ÐžÑ.Ð°ÐµÑ.Ðµ Ñ.ÐµÐºÑÑ., Ñ.ÐŸ
++     Ð·Ð°Ð±Ñ.ÐŽÐµÑ.Ðµ ÐºÐŸÐŒÐ°ÐœÐŽÑ.!
++
++     Ð¢ÐµÐ¿ÐµÑ.Ñ. Ñ.Ð±ÐµÐŽÐžÑ.ÐµÑÑ. Ð² Ñ.ÐŸÐŒ, Ñ.Ñ.ÐŸ ÐºÐ»Ð°Ð²ÐžÑ.Ð° CapsLock ÐœÐµ Ð²ÐºÐ»Ñ.Ñ.ÐµÐœÐ° Ðž ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ
++     ÐºÐ»Ð°Ð²ÐžÑ.Ñ.   j   ÐœÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð·, Ñ.Ð°Ðº, Ñ.Ñ.ÐŸÐ±Ñ. Ð£Ñ.ÐŸÐº 1.1 Ð¿ÐŸÐ»ÐœÐŸÑÑ.Ñ.Ñ. Ð¿ÐŸÐŒÐµÑÑ.ÐžÐ»ÑÑ ÐœÐ°
++     ÑÐºÑ.Ð°ÐœÐµ.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Ð£Ñ.ÐŸÐº 1.1:  Ð.Ð.Ð Ð.Ð.Ð.Ð©Ð.ÐÐ.Ð. Ð.Ð£Ð Ð¡Ð.Ð Ð
++
++** Ð.Ð»Ñ Ð¿ÐµÑ.ÐµÐŒÐµÑ.ÐµÐœÐžÑ ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ðž h,j,k,l Ñ.Ð°Ðº, ÐºÐ°Ðº Ð¿ÐŸÐºÐ°Ð·Ð°ÐœÐŸ ÐœÐžÐ¶Ðµ. **
++	     ^
++	     k		Ð¡ÐŸÐ²ÐµÑ.Ñ.:	Ð.Ð»Ð°Ð²ÐžÑ.Ð° h ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ ÑÐ»ÐµÐ²Ð° Ðž Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ. Ð²Ð»ÐµÐ²ÐŸ.
++       < h	 l >		Ð.Ð»Ð°Ð²ÐžÑ.Ð° l ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ ÑÐ¿Ñ.Ð°Ð²Ð° Ðž Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ. Ð²Ð¿Ñ.Ð°Ð²ÐŸ.
++	     j			Ð.Ð»Ð°Ð²ÐžÑ.Ð° j Ð¿ÐŸÑ.ÐŸÐ¶Ð° ÐœÐ° ÑÑ.Ñ.ÐµÐ»ÐºÑ. `Ð²ÐœÐžÐ·'.
++	     v
++  1. Ð.ÐŸÐŽÐ²ÐžÐ³Ð°Ð¹Ñ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð¿ÐŸ ÑÐºÑ.Ð°ÐœÑ., Ð¿ÐŸÐºÐ° ÐœÐµ Ð¿ÐŸÑ.Ñ.Ð²ÑÑ.Ð²Ñ.ÐµÑ.Ðµ ÑÐµÐ±Ñ Ñ.Ð²ÐµÑ.ÐµÐœÐœÐŸ.
++
++  2. ÐÐ°ÐŽÐ°Ð²ÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. `Ð²ÐœÐžÐ·' (j) Ð¿ÐŸÐºÐ° ÐŸÐœÐ° ÐœÐµ ÐœÐ°Ñ.ÐœÐµÑ. Ð¿ÐŸÐ²Ñ.ÐŸÑ.ÑÑ.Ñ.ÑÑ.
++---> Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð.Ñ. Ð·ÐœÐ°ÐµÑ.Ðµ, ÐºÐ°Ðº Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ðº ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐŒÑ. Ñ.Ñ.ÐŸÐºÑ..
++
++  3. Ð.ÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. `Ð²ÐœÐžÐ·' Ð¿ÐµÑ.ÐµÐ¹ÐŽÐžÑ.Ðµ Ðº Ð£Ñ.ÐŸÐºÑ. 1.2.
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.ÑÐ»Ðž Ð²Ñ. Ð¿ÐŸÐºÐ° ÐœÐµ Ñ.Ð²ÐµÑ.ÐµÐœÑ. Ð² Ñ.ÐŸÐŒ, Ñ.Ñ.ÐŸ ÐœÐ°Ð±ÐžÑ.Ð°ÐµÑ.Ðµ, ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC> ÐŽÐ»Ñ
++	   Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐ° Ð² ÐŸÐ±Ñ.Ñ.ÐœÑ.Ð¹ Ñ.ÐµÐ¶ÐžÐŒ (Normal mode). Ð.ÐŸÑÐ»Ðµ ÑÑ.ÐŸÐ³ÐŸ Ð¿ÐµÑ.ÐµÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ
++	   Ñ.Ñ.ÐµÐ±Ñ.ÐµÐŒÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.Ð±Ñ.Ñ.ÐœÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ðž Ñ.Ð¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÑ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ (ÑÑ.Ñ.ÐµÐ»ÐºÐž) Ñ.Ð°ÐºÐ¶Ðµ ÐŽÐŸÐ»Ð¶ÐœÑ.
++	   Ñ.Ð°Ð±ÐŸÑ.Ð°Ñ.Ñ.. Ð.ÐŽÐœÐ°ÐºÐŸ, ÐºÐ»Ð°Ð²ÐžÑ.Ðž hjkl Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÑ. Ð.Ð°ÐŒ Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°Ñ.Ñ.ÑÑ
++	   Ð·ÐœÐ°Ñ.ÐžÑ.ÐµÐ»Ñ.ÐœÐŸ Ð±Ñ.ÑÑ.Ñ.ÐµÐµ, ÐºÐ°Ðº Ñ.ÐŸÐ»Ñ.ÐºÐŸ Ð.Ñ. ÐœÐ°Ñ.Ñ.ÐžÑ.ÐµÑÑ. ÐžÐŒÐž Ð¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.Ñ.ÑÑ.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Ð£Ñ.ÐŸÐº 1.2: Ð.ÐÐ.Ð£Ð¡Ð. Ð. Ð.ÐÐ.Ð.Ð ÐšÐ.ÐÐ.Ð. Ð ÐÐ.Ð.Ð¢Ð« Ð¡ VIM
++
++!! Ð.ÐÐ.Ð.ÐÐÐ.Ð.! Ð.Ñ.ÐµÐ¶ÐŽÐµ, Ñ.ÐµÐŒ Ð²Ñ.Ð¿ÐŸÐ»ÐœÑÑ.Ñ. Ð»Ñ.Ð±ÐŸÐ¹ ÐžÐ· ÐŸÐ¿ÐžÑÐ°ÐœÐœÑ.Ñ. ÐœÐžÐ¶Ðµ Ñ.Ð°Ð³ÐŸÐ², Ð¿Ñ.ÐŸÑ.Ñ.ÐžÑ.Ðµ
++			       Ñ.Ñ.ÐŸÐº Ñ.ÐµÐ»ÐžÐºÐŸÐŒ !!
++
++  1. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. <ESC> (ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ñ.ÐŽÐŸÑÑ.ÐŸÐ²ÐµÑ.ÐžÑ.Ñ.ÑÑ, Ñ.Ñ.ÐŸ Ð.Ñ. Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ
++     Ñ.ÐµÐ¶ÐžÐŒÐµ (Normal mode)).
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:			:q! <ENTER>.
++
++---> Ð­Ñ.ÐŸ Ð¿ÐŸÐ·Ð²ÐŸÐ»ÐžÑ. Ð.Ð°ÐŒ Ð²Ñ.Ð¹Ñ.Ðž ÐžÐ· Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ.Ð° Ð.Ð.Ð. Ð¡Ð.Ð¥Ð ÐÐÐ.ÐÐ.Ð¯ Ð»Ñ.Ð±Ñ.Ñ. ÑÐŽÐµÐ»Ð°ÐœÐœÑ.Ñ.
++     ÐžÐ·ÐŒÐµÐœÐµÐœÐžÐ¹. Ð.ÑÐ»Ðž Ð.Ñ. Ñ.ÐŸÑ.ÐžÑ.Ðµ ÑÐŸÑ.Ñ.Ð°ÐœÐžÑ.Ñ. ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ Ðž Ð²Ñ.Ð¹Ñ.Ðž:
++				:wq  <ENTER>
++
++  3. Ð.ÐŸÐ³ÐŽÐ° Ð.Ñ. Ñ.Ð²ÐžÐŽÐžÑ.Ðµ Ð¿Ñ.ÐžÐ³Ð»Ð°Ñ.ÐµÐœÐžÐµ ÐºÐŸÐŒÐ°ÐœÐŽÐœÐŸÐ¹ ÐŸÐ±ÐŸÐ»ÐŸÑ.ÐºÐž, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ÐºÐŸÐŒÐ°ÐœÐŽÑ.,
++     ÐºÐŸÑ.ÐŸÑ.Ð°Ñ Ð¿Ñ.ÐžÐ²ÐµÐ»Ð° Ð.Ð°Ñ Ð² ÑÑ.ÐŸÑ. Ñ.Ñ.ÐµÐ±ÐœÐžÐº. Ð­Ñ.ÐŸ ÐŒÐŸÐ¶ÐµÑ. Ð±Ñ.Ñ.Ñ.
++				vimtutor ru <ENTER>
++     Ð.Ð±Ñ.Ñ.ÐœÐŸ ÐŒÐŸÐ¶ÐœÐŸ ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.Ñ.:	vim tutor.ru <ENTER>
++
++---> 'vim' Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. Ð·Ð°Ð¿Ñ.ÑÑ.ÐžÑ.Ñ. Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ. vim, 'tutor.ru' --- ÑÑ.ÐŸ Ñ.Ð°Ð¹Ð», ÐºÐŸÑ.ÐŸÑ.Ñ.Ð¹
++     Ð.Ñ. Ð±Ñ.ÐŽÐµÑ.Ðµ Ñ.ÐµÐŽÐ°ÐºÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ..
++
++  4. Ð.ÑÐ»Ðž Ð.Ñ. Ñ.Ð²ÐµÑ.ÐµÐœÑ. Ð² Ñ.ÐŸÐŒ, Ñ.Ñ.ÐŸ Ð·Ð°Ð¿ÐŸÐŒÐœÐžÐ»Ðž ÑÑ.Ðž Ñ.Ð°Ð³Ðž, Ð²Ñ.Ð¿ÐŸÐ»ÐœÐžÑ.Ðµ Ñ.Ð°Ð³Ðž ÐŸÑ. 1 ÐŽÐŸ 3
++     Ñ.Ñ.ÐŸÐ±Ñ. Ð²Ñ.Ð¹Ñ.Ðž ÑÐœÐŸÐ²Ð° Ð·Ð°Ð¿Ñ.ÑÑ.ÐžÑ.Ñ. Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ.. Ð.Ð°Ñ.ÐµÐŒ Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ· Ðº
++     Ð£Ñ.ÐŸÐºÑ. 1.3.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Ð£Ñ.ÐŸÐº 1.3: Ð Ð.Ð.ÐÐ.Ð¢Ð.Ð Ð.Ð.ÐÐÐ.Ð. Ð¢Ð.Ð.Ð¡Ð¢Ð - Ð£Ð.ÐÐ.Ð.ÐÐ.Ð.
++
++
++** ÐÐ°Ñ.ÐŸÐŽÑÑÑ. Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ x, Ñ.Ñ.ÐŸÐ±Ñ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ñ. ÑÐžÐŒÐ²ÐŸÐ» Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ðº ÑÑ.Ñ.ÐŸÐºÐµ Ð²ÐœÐžÐ·Ñ., Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð.Ð»Ñ ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÑ ÐŸÑ.ÐžÐ±ÐŸÐº, Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ., Ð¿ÐŸÐºÐ° ÐŸÐœ ÐœÐµ ÐŸÐºÐ°Ð¶ÐµÑ.ÑÑ ÐœÐ°ÐŽ
++     Ñ.ÐŽÐ°Ð»ÑÐµÐŒÑ.ÐŒ ÑÐžÐŒÐ²ÐŸÐ»ÐŸÐŒ.
++
++  3. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. x ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ñ.Ñ.ÐµÐ±Ñ.ÐµÐŒÐŸÐ³ÐŸ ÑÐžÐŒÐ²ÐŸÐ»Ð°.
++
++  4. Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 2--4 Ð¿ÐŸÐºÐ° ÑÑ.Ñ.ÐŸÐºÐ° ÐœÐµ Ð±Ñ.ÐŽÐµÑ. ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐ°.
++
++---> Ð.Ñ. Ñ.Ñ.Ñ.ÐŸÐ¿ÐŸÑ.Ð° ÐºÐŸÐ¿Ñ.Ñ.Ñ. Ð¿Ð¿Ð¿Ñ.Ð»Ñ. Ð¿Ð¿ÐŸ Ð¿Ð¿Ð¿ÐŸÐ»Ñ. Ð»ÐµÑ.Ñ.ÐžÑ.Ñ..
++
++  5. Ð¢ÐµÐ¿ÐµÑ.Ñ., ÐºÐŸÐ³ÐŽÐ° ÑÑ.Ñ.ÐŸÐºÐ° ÐŸÑ.ÐºÐŸÑ.Ñ.ÐµÐºÑ.ÐžÑ.ÐŸÐ²Ð°ÐœÐ°, Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº Ñ.Ñ.ÐŸÐºÑ. 1.4.
++
++Ð.ÐÐ.Ð.Ð§ÐÐÐ.Ð.: Ð. Ñ.ÐŸÐŽÐµ ÐŸÑÐ²ÐŸÐµÐœÐžÑ ÑÑ.ÐŸÐ³ÐŸ Ñ.Ñ.ÐµÐ±ÐœÐžÐºÐ° ÐœÐµ Ð¿Ñ.Ñ.Ð°Ð¹Ñ.ÐµÑÑ. Ð·Ð°Ð¿ÐŸÐŒÐžÐœÐ°Ñ.Ñ., Ñ.Ñ.ÐžÑ.Ðµ
++	   Ð² Ð¿Ñ.ÐŸÑ.ÐµÑÑÐµ ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°ÐœÐžÑ.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Ð£Ñ.ÐŸÐº 1.4: Ð Ð.Ð.ÐÐ.Ð¢Ð.Ð Ð.Ð.ÐÐÐ.Ð. Ð¢Ð.Ð.Ð¡Ð¢Ð - Ð.Ð¡Ð¢ÐÐ.Ð.Ð
++
++
++ ** ÐÐ°Ñ.ÐŸÐŽÑÑÑ. Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ (Normal mode), ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ i ÐŽÐ»Ñ Ð²ÑÑ.Ð°Ð²ÐºÐž Ñ.ÐµÐºÑÑ.Ð°. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ðº Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ Ð²ÐœÐžÐ·Ñ., Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð.Ð»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. ÑÐŽÐµÐ»Ð°Ñ.Ñ. Ð¿ÐµÑ.Ð²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. ÐžÐŽÐµÐœÑ.ÐžÑ.ÐœÐŸÐ¹ Ð²Ñ.ÐŸÑ.ÐŸÐ¹, Ð¿ÐŸÐŒÐµÑÑ.ÐžÑ.Ðµ
++     ÐºÑ.Ñ.ÑÐŸÑ. ÐœÐ° ÑÐžÐŒÐ²ÐŸÐ» Ð.Ð.Ð Ð.Ð. ÐºÐŸÑ.ÐŸÑ.Ñ.ÐŒ ÑÐ»ÐµÐŽÑ.ÐµÑ. Ð²ÑÑ.Ð°Ð²ÐžÑ.Ñ. Ñ.ÐµÐºÑÑ..
++
++  3. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ i Ðž ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ Ñ.Ñ.ÐµÐ±Ñ.ÐµÐŒÑ.Ðµ ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÐžÑ.
++
++  4. Ð.ÐŸÑÐ»Ðµ ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÑ Ð²ÑÐµÑ. ÐŸÑ.ÐžÐ±ÐŸÐº ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC> ÐŽÐ»Ñ Ð²ÐŸÐ·Ð²Ñ.Ð°Ñ.Ð° Ð² ÐŸÐ±Ñ.Ñ.ÐœÑ.Ð¹ Ñ.ÐµÐ¶ÐžÐŒ.
++     Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 2--4, Ð¿ÐŸÐºÐ° Ñ.Ñ.Ð°Ð·Ð° ÐœÐµ Ð±Ñ.ÐŽÐµÑ. ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐ° Ð¿ÐŸÐ»ÐœÐŸÑÑ.Ñ.Ñ..
++
++---> Ð§Ð°ÑÑ.Ñ. Ñ.ÐµÐºÑÑ.Ð° Ð² ÑÑ.Ñ.ÐŸÐºÐµ Ð±ÐµÑÐ»ÐµÐŽÐœÐŸ .
++---> Ð§Ð°ÑÑ.Ñ. Ñ.ÐµÐºÑÑ.Ð° Ð² ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ Ð±ÐµÑÑÐ»ÐµÐŽÐœÐŸ Ð¿Ñ.ÐŸÐ¿Ð°Ð»Ð°.
++
++  5. Ð.ÐŸÐ³ÐŽÐ° ÐŸÑÐ²ÐŸÐžÑ.Ðµ Ð²ÑÑ.Ð°Ð²ÐºÑ. Ñ.ÐµÐºÑÑ.Ð°, Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ ÐŽÐ°Ð»Ñ.Ñ.Ðµ Ðº Ð ÐµÐ·Ñ.ÐŒÐµ.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 1
++
++  1. Ð.Ñ.Ñ.ÑÐŸÑ. Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ.ÑÑ Ð»ÐžÐ±ÐŸ ÐºÐ»Ð°Ð²ÐžÑ.Ð°ÐŒÐž ÑÐŸ ÑÑ.Ñ.ÐµÐ»ÐºÐ°ÐŒÐž, Ð»ÐžÐ±ÐŸ ÐºÐ»Ð°Ð²ÐžÑ.Ð°ÐŒÐž hjkl.
++	 h (Ð²Ð»ÐµÐ²ÐŸ)	j (Ð²ÐœÐžÐ·)       k (Ð²Ð²ÐµÑ.Ñ.)	    l (Ð²Ð¿Ñ.Ð°Ð²ÐŸ)
++
++  2. Ð.Ð»Ñ Ð·Ð°Ð¿Ñ.ÑÐºÐ° Vim (ÐžÐ· Ð¿Ñ.ÐžÐ³Ð»Ð°Ñ.ÐµÐœÐžÑ % ÐºÐŸÐŒÐ°ÐœÐŽÐœÐŸÐ¹ ÐŸÐ±ÐŸÐ»ÐŸÑ.ÐºÐž) ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:
++     vim Ð.Ð.Ð¯_Ð€ÐÐ.Ð.Ð <ENTER>
++
++  3. Ð.Ð»Ñ Ð·Ð°Ð²ÐµÑ.Ñ.ÐµÐœÐžÑ Ñ.Ð°Ð±ÐŸÑ.Ñ. Ñ Vim ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:
++     <ESC>   :q!	 <ENTER>  Ñ.Ñ.ÐŸÐ±Ñ. ÐŸÑ.ÐºÐ°Ð·Ð°Ñ.Ñ.ÑÑ ÐŸÑ. ÑÐŸÑ.Ñ.Ð°ÐœÐµÐœÐžÑ ÐžÐ·ÐŒÐµÐœÐµÐœÐžÐ¹.
++     Ð.Ð»Ðž ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:
++     <ESC>   :wq	 <ENTER>  Ñ.Ñ.ÐŸÐ±Ñ. ÑÐŸÑ.Ñ.Ð°ÐœÐžÑ.Ñ. ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ.
++
++  4. Ð.Ð»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ ÑÐžÐŒÐ²ÐŸÐ»Ð° Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ: x
++
++  5. Ð§Ñ.ÐŸÐ±Ñ. Ð²ÑÑ.Ð°Ð²ÐžÑ.Ñ. Ñ.ÐµÐºÑÑ. Ð¿ÐµÑ.ÐµÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:
++	 i     Ð²Ð²ÐŸÐŽÐžÑ.Ðµ Ñ.ÐµÐºÑÑ.	<ESC>
++
++Ð.ÐÐ.Ð.Ð§ÐÐÐ.Ð.: ÐÐ°Ð¶Ð°Ñ.ÐžÐµ <ESC> Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ. Ð.Ð°Ñ Ð² ÐŸÐ±Ñ.Ñ.ÐœÑ.Ð¹ Ñ.ÐµÐ¶ÐžÐŒ (Normal mode) Ð»ÐžÐ±ÐŸ
++	   Ð¿Ñ.ÐµÑ.Ð²ÐµÑ. ÐœÐµÐ¶ÐµÐ»Ð°Ñ.ÐµÐ»Ñ.ÐœÑ.Ñ. Ðž Ñ.Ð°ÑÑ.ÐžÑ.ÐœÐŸ Ð·Ð°Ð²ÐµÑ.Ñ.ÐµÐœÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++
++Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÐŒ Ðº Ð£Ñ.ÐŸÐºÑ. 2.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Ð£Ñ.ÐŸÐº 2.1: Ð.Ð.Ð.ÐÐÐ.Ð« Ð£Ð.ÐÐ.Ð.ÐÐ.Ð¯
++
++
++	** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ dw ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ñ.Ñ.Ð°ÑÑ.ÐºÐ° Ñ.ÐµÐºÑÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÐ»ÐŸÐ²Ð°. **
++
++  1. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC>, Ñ.Ñ.ÐŸÐ±Ñ. Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ð² ÐŸÐ±Ñ.Ñ.ÐœÑ.Ð¹ Ñ.ÐµÐ¶ÐžÐŒ.
++
++  2. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  3. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð² ÐœÐ°Ñ.Ð°Ð»ÐŸ ÑÐ»ÐŸÐ²Ð°, ÐºÐŸÑ.ÐŸÑ.ÐŸÐµ ÑÐ»ÐµÐŽÑ.ÐµÑ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ñ..
++
++  4. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ  dw , Ñ.Ñ.ÐŸÐ±Ñ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ñ. ÑÑ.ÐŸ ÑÐ»ÐŸÐ²ÐŸ.
++
++Ð.ÐÐ.Ð.Ð§ÐÐÐ.Ð.: Ð.ÐŸ Ð²Ñ.ÐµÐŒÑ ÐœÐ°Ð±ÐŸÑ.Ð° Ð±Ñ.ÐºÐ²Ñ. dw Ð¿ÐŸÑÐ²ÑÑ.ÑÑ Ð² Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ ÑÐºÑ.Ð°ÐœÐ°. Ð.ÑÐ»Ðž
++	   Ð.Ñ. Ñ.Ñ.ÐŸ-Ñ.ÐŸ ÐœÐ°Ð±ÐµÑ.ÐµÑ.Ðµ ÐœÐµÐ¿Ñ.Ð°Ð²ÐžÐ»Ñ.ÐœÐŸ, ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC> Ðž ÐœÐ°Ñ.ÐœÐžÑ.Ðµ ÑÐœÐ°Ñ.Ð°Ð»Ð°.
++
++---> ÐÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ ÑÐ»ÐŸÐ² Ñ.Ð°Ñ.ÐžÐœÐ°ÐŽ Ð² ÑÑ.ÐŸÐŒ Ð¿Ñ.ÐµÐŽÐ»ÐŸÐ¶ÐµÐœÐžÐž Ð°Ð²Ñ.ÐŸÐºÑ.Ð°Ðœ ÐžÐ·Ð»ÐžÑ.ÐœÐž.
++
++  5. Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 3 Ðž 4, Ð¿ÐŸÐºÐ° ÐœÐµ ÐžÑÐ¿Ñ.Ð°Ð²ÐžÑ.Ðµ Ð²ÑÐµ ÐŸÑ.ÐžÐ±ÐºÐž Ðž Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº
++     Ð£Ñ.ÐŸÐºÑ. 2.2.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Ð£Ñ.ÐŸÐº 2.2: Ð.Ð.Ð.Ð.Ð.ÐÐ.Ð¢Ð.Ð.Ð¬ÐÐ«Ð. Ð.Ð.Ð.ÐÐÐ.Ð« Ð£Ð.ÐÐ.Ð.ÐÐ.Ð¯
++
++
++	    ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ d$ ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ñ.ÐµÐºÑÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐž. **
++
++  1. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC>, Ñ.Ñ.ÐŸÐ±Ñ. Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ð² ÐŸÐ±Ñ.Ñ.ÐœÑ.Ð¹ Ñ.ÐµÐ¶ÐžÐŒ.
++
++  2. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  3. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ðº ÐºÐŸÐœÑ.Ñ. Ð¿Ñ.Ð°Ð²ÐžÐ»Ñ.ÐœÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž (Ð.Ð.Ð¡Ð.Ð. Ð¿ÐµÑ.Ð²ÐŸÐ¹ . ).
++
++  4. Ð§Ñ.ÐŸÐ±Ñ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ñ. ÐŸÑÑ.Ð°Ñ.ÐŸÐº ÑÑ.Ñ.ÐŸÐºÐž, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ  d$ .
++
++---> Ð.Ñ.ÐŸ-Ñ.ÐŸ ÐœÐ°Ð±Ñ.Ð°Ð» ÐŸÐºÐŸÐœÑ.Ð°ÐœÐžÐµ ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐŽÐ²Ð°Ð¶ÐŽÑ.. ÐŸÐºÐŸÐœÑ.Ð°ÐœÐžÐµ ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐŽÐ²Ð°Ð¶ÐŽÑ..
++
++
++  5.Ð§Ñ.ÐŸÐ±Ñ. Ð»Ñ.Ñ.Ñ.Ðµ Ñ.Ð°Ð·ÐŸÐ±Ñ.Ð°Ñ.Ñ.ÑÑ Ð² ÑÑ.ÐŸÐŒ, Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº Ð£Ñ.ÐŸÐºÑ. 2.3.
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Ð£Ñ.ÐŸÐº 2.3: Ð.Ð.Ð.ÐÐÐ.Ð« Ð. Ð.Ð.ÐªÐ.Ð.Ð¢Ð«
++
++
++  Ð€ÐŸÑ.ÐŒÐ°Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. `Ñ.ÐŽÐ°Ð»ÐµÐœÐžÐµ' d Ñ.Ð°ÐºÐŸÐ²:
++
++	 [Ñ.ÐžÑÐ»ÐŸ]   d	ÐŸÐ±Ñ.ÐµÐºÑ.	    Ð.Ð.Ð.	     d	 [Ñ.ÐžÑÐ»ÐŸ]   ÐŸÐ±Ñ.ÐµÐºÑ.
++  Ð.ÐŽÐµÑÑ.:
++    Ñ.ÐžÑÐ»ÐŸ  - ÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð· ÐžÑÐ¿ÐŸÐ»ÐœÐžÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. (ÐœÐµÐŸÐ±ÑÐ·Ð°Ñ.ÐµÐ»Ñ.ÐœÐŸ, Ð¿ÐŸ Ñ.ÐŒÐŸÐ»Ñ.Ð°ÐœÐžÑ.=1).
++    d      - ÐºÐŸÐŒÐ°ÐœÐŽÐ° Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ.
++    ÐŸÐ±Ñ.ÐµÐºÑ. - Ñ Ñ.ÐµÐŒ ÐºÐŸÐŒÐ°ÐœÐŽÐ° ÐŽÐŸÐ»Ð¶ÐœÐ° Ð±Ñ.Ñ.Ñ. Ð²Ñ.Ð¿ÐŸÐ»ÐœÐµÐœÐ° (Ð¿ÐµÑ.ÐµÑ.ÐžÑÐ»ÐµÐœÐŸ ÐœÐžÐ¶Ðµ).
++
++  Ð.Ñ.Ð°Ñ.ÐºÐžÐ¹ ÑÐ¿ÐžÑÐŸÐº ÐŸÐ±Ñ.ÐµÐºÑ.ÐŸÐ²:
++    w - ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÐ»ÐŸÐ²Ð°, Ð²ÐºÐ»Ñ.Ñ.Ð°Ñ Ð·Ð°Ð²ÐµÑ.Ñ.Ð°Ñ.Ñ.ÐžÐ¹ Ð¿Ñ.ÐŸÐ±ÐµÐ».
++    e - ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÐ»ÐŸÐ²Ð°, ÐÐ. Ð²ÐºÐ»Ñ.Ñ.Ð°Ñ Ð·Ð°Ð²ÐµÑ.Ñ.Ð°Ñ.Ñ.ÐžÐ¹ Ð¿Ñ.ÐŸÐ±ÐµÐ».
++    $ - ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐž.
++    ^ - ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐœÐ°Ñ.Ð°Ð»Ð° ÑÑ.Ñ.ÐŸÐºÐž.
++
++Ð.ÐÐ.Ð.Ð§ÐÐÐ.Ð.: Ð.Ñ.ÐŸÑÑ.ÐŸÐµ ÐœÐ°Ð¶Ð°Ñ.ÐžÐµ ÐœÐ° ÑÐžÐŒÐ²ÐŸÐ» ÐŸÐ±Ñ.ÐµÐºÑ.Ð° Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ (Normal mode)
++	   Ð±ÐµÐ· ÐŽÐŸÐ¿ÐŸÐ»ÐœÐžÑ.ÐµÐ»Ñ.ÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽ Ð¿ÐµÑ.ÐµÐŽÐ²ÐžÐœÐµÑ. ÐºÑ.Ñ.ÑÐŸÑ. Ñ.Ð°Ðº, ÐºÐ°Ðº Ñ.ÐºÐ°Ð·Ð°ÐœÐŸ Ð²
++	   ÑÐ¿ÐžÑÐºÐµ ÐŸÐ±Ñ.ÐµÐºÑ.ÐŸÐ².
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++	       Ð£Ñ.ÐŸÐº 2.4: Ð.Ð¡Ð.Ð.Ð®Ð§Ð.ÐÐ.Ð. Ð.Ð. Ð.Ð ÐÐ.Ð.Ð.Ð `Ð.Ð.Ð.ÐÐÐ.Ð-Ð.Ð.ÐªÐ.Ð.Ð¢'
++
++
++		 ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ dd ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ð²ÑÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐž. **
++
++  Ð.ÑÐ»ÐµÐŽÑÑ.Ð²ÐžÐµ Ñ.Ð°ÑÑ.ÐŸÐ³ÐŸ Ð¿Ñ.ÐžÐŒÐµÐœÐµÐœÐžÑ ÐŸÐ¿ÐµÑ.Ð°Ñ.ÐžÐž Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ð²ÑÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐž, Ñ.Ð°Ð·Ñ.Ð°Ð±ÐŸÑ.Ñ.ÐžÐºÐž
++  Vim Ñ.ÐµÑ.ÐžÐ»Ðž, Ñ.Ñ.ÐŸ ÐŽÐ»Ñ ÑÑ.ÐŸÐ³ÐŸ Ð¿Ñ.ÐŸÑ.Ðµ Ð²ÑÐµÐ³ÐŸ Ð¿Ñ.ÐŸÑÑ.ÐŸ ÐœÐ°Ð±Ñ.Ð°Ñ.Ñ. d ÐŽÐ²Ð°Ð¶ÐŽÑ..
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, ÐºÐŸ Ð²Ñ.ÐŸÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ Ñ.Ñ.Ð°Ð·Ñ..
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ dd ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ ÑÑ.Ñ.ÐŸÐºÐž.
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.ÐµÑÑ. Ðº Ñ.ÐµÑ.Ð²ÐµÑ.Ñ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ.
++  4. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ 2dd (Ð²ÑÐ¿ÐŸÐŒÐœÐžÑ.Ðµ Ð¿Ñ.Ð°Ð²ÐžÐ»ÐŸ `Ñ.ÐžÑÐ»ÐŸ-ÐºÐŸÐŒÐ°ÐœÐŽÐ°-ÐŸÐ±Ñ.ÐµÐºÑ.'), Ñ.Ñ.ÐŸÐ±Ñ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ñ.
++     ÐŽÐ²Ðµ ÑÑ.Ñ.ÐŸÐºÐž.
++
++      1)  Ð.ÐµÑ.ÐŸÐŒ Ñ Ñ.ÐŸÐ¶Ñ. ÐœÐ° ÑÑ.Ð°ÐŽÐžÐŸÐœ,
++      2)  Ð., ÐºÐ°Ðº Ð²ÐœÐµÐ·Ð°Ð¿ÐœÐŸ ÐºÐŸÐœÑ.ÐžÐ»ÑÑ ÐŽÐžÐ²Ð°Ðœ!
++      3)  Ð¯ Ð±ÐŸÐ»ÐµÑ. Ð·Ð° ``Ð.ÐµÐœÐžÑ.'', ``Ð.ÐµÐœÐžÑ.'' --- Ñ.ÐµÐŒÐ¿ÐžÐŸÐœ!
++      4)  Ð.ÐµÑ.Ð°Ð»Ñ.ÐœÐŸ Ñ Ð³Ð»ÑÐ¶Ñ. ÐœÐ° ÐœÐ°Ñ.Ðµ Ð¿ÐŸÐºÐŸÐ»ÐµÐœÐžÐµ!
++      5)  Ð.Ð³ÐŸ Ð³Ñ.ÑÐŽÑ.Ñ.ÐµÐµ ÐžÐ»Ñ. Ð¿Ñ.ÑÑ.ÐŸ ÐžÐ»Ñ. Ñ.ÐµÐŒÐœÐŸ...
++      6)  Ð¯ ÑÐžÐ¶Ñ. ÐœÐ° ÑÐºÐ°ÐŒÐµÐ¹ÐºÐµ Ð² Ð»ÐŸÐ¶Ðµ `Ð.'
++      7)  Ð. ÐžÐ³Ñ.Ð°Ñ. ÐœÐ° Ð±ÐŸÐ»Ñ.Ñ.ÐŸÐ¹ Ð¶ÐµÑÑ.ÑÐœÐŸÐ¹ Ñ.Ñ.Ñ.Ð±Ðµ.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Ð£Ñ.ÐŸÐº 2.5: Ð.Ð.Ð.ÐÐÐ.Ð `Ð.Ð¢Ð.ÐÐ¢'
++
++
++  ** ÐÐ°Ð¶ÐŒÐžÑ.Ðµ u	ÐŽÐ»Ñ ÐŸÑ.ÐŒÐµÐœÑ. Ñ.ÐµÐ·Ñ.Ð»Ñ.Ñ.Ð°Ñ.Ð° Ñ.Ð°Ð±ÐŸÑ.Ñ. Ð¿Ñ.ÐµÐŽÑ.ÐŽÑ.Ñ.ÐµÐ¹ ÐºÐŸÐŒÐ°ÐœÐŽÑ., U ÐŽÐ»Ñ ÐŸÑ.ÐŒÐµÐœÑ.
++			ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÐ¹ Ð²ÐŸ Ð²ÑÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ ---> Ðž Ñ.ÑÑ.Ð°ÐœÐŸÐ²ÐžÑ.Ðµ ÐµÐ³ÐŸ ÐœÐ°
++     Ð¿ÐµÑ.Ð²Ñ.Ñ. ÐŸÑ.ÐžÐ±ÐºÑ..
++  2. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ x ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ð¿ÐµÑ.Ð²ÐŸÐ³ÐŸ ÐœÐµÐ¿Ñ.Ð°Ð²ÐžÐ»Ñ.ÐœÐŸÐ³ÐŸ ÑÐžÐŒÐ²ÐŸÐ»Ð°.
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ u ÐŽÐ»Ñ ÐŸÑ.ÐŒÐµÐœÑ. (ÐŸÑ.ÐºÐ°Ñ.Ð°) Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ¹ Ð²Ñ.Ð¿ÐŸÐ»ÐœÐµÐœÐœÐŸÐ¹ ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++  4. Ð.ÑÐ¿Ñ.Ð°Ð²Ñ.Ñ.Ðµ Ð²ÑÐµ ÐŸÑ.ÐžÐ±ÐºÐž Ð² ÑÑ.Ñ.ÐŸÐºÐµ, ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ ÐºÐŸÐŒÐ°ÐœÐŽÑ. x .
++  5. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÑ.Ñ. U ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ð²ÐµÑ.ÐœÑ.Ñ.Ñ. Ð²ÑÑ. ÑÑ.Ñ.ÐŸÐºÑ. Ð² ÐžÑÑ.ÐŸÐŽÐœÐŸÐµ
++     ÑÐŸÑÑ.ÐŸÑÐœÐžÐµ.
++  6. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ u ÐœÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð· ÐŽÐ»Ñ ÐŸÑ.ÐŒÐµÐœÑ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. U Ðž Ð¿Ñ.ÐµÐŽÑ.ÐŽÑ.Ñ.ÐžÑ. ÐºÐŸÐŒÐ°ÐœÐŽ.
++  7. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ Ñ.ÐµÐ¿ÐµÑ.Ñ. CTRL-R (Ñ.ÐŽÐµÑ.Ð¶ÐžÐ²Ð°Ð¹Ñ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. CTRL ÐœÐ°Ð¶Ð°Ñ.ÐŸÐ¹ Ð² ÐŒÐŸÐŒÐµÐœÑ. ÐœÐ°Ð¶Ð°Ñ.ÐžÑ
++  R)     ÐœÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð· ÐŽÐ»Ñ Ð²ÐŸÐ·Ð²Ñ.Ð°Ñ.Ð° ÐºÐŸÐŒÐ°ÐœÐŽ (ÐŸÑ.ÐºÐ°Ñ. ÐŸÑ.ÐºÐ°Ñ.Ð°).
++
++---> Ð.ÑÐ¿Ñ.Ñ.Ð°Ð²Ñ.Ñ.Ðµ ÐŸÐŸÑ.ÐžÐ±ÐºÐž Ð² ÑÑ.ÐŸÐ¹Ð¹ ÑÑ.Ñ.ÐŸÐºÐµ Ðž Ð²ÐµÑ.ÐœÐžÑ.Ñ.Ðµ ÐžÑ. ÑÑ Ð¿ÐŸÐŒÐŸÑ.Ñ.Ñ.Ñ. `ÐŸÑ.ÐºÐ°Ñ.Ð°'.
++
++  8. Ð­Ñ.ÐŸ Ð±Ñ.Ð»Ðž ÐŸÑ.ÐµÐœÑ. Ð¿ÐŸÐ»ÐµÐ·ÐœÑ.Ðµ ÐºÐŸÐŒÐ°ÐœÐŽÑ.. Ð.Ð°Ð»ÐµÐµ Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº Ð ÐµÐ·Ñ.ÐŒÐµ Ð£Ñ.ÐŸÐºÐ° 2.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 2
++
++
++  1. Ð.Ð»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ñ.ÐµÐºÑÑ.Ð° ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÐ»ÐŸÐ²Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:    dw
++
++  2. Ð.Ð»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ñ.ÐµÐºÑÑ.Ð° ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐž ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:    d$
++
++  3. Ð.Ð»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ Ð²ÑÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:    dd
++
++  4. Ð€ÐŸÑ.ÐŒÐ°Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ ÐžÐŒÐµÐµÑ. Ð²ÐžÐŽ:
++
++       [Ñ.ÐžÑÐ»ÐŸ]   ÐºÐŸÐŒÐ°ÐœÐŽÐ°   ÐŸÐ±Ñ.ÐµÐºÑ.     Ð.Ð.Ð.     ÐºÐŸÐŒÐ°ÐœÐŽÐ°	[Ñ.ÐžÑÐ»ÐŸ]   ÐŸÐ±Ñ.ÐµÐºÑ.
++     Ð³ÐŽÐµ:
++       Ñ.ÐžÑÐ»ÐŸ   - ÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð· Ð¿ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ñ. Ð²Ñ.Ð¿ÐŸÐ»ÐœÐµÐœÐžÐµ ÐºÐŸÐŒÐ°ÐœÐŽÑ.
++       ÐºÐŸÐŒÐ°ÐœÐŽÐ° - Ñ.Ñ.ÐŸ Ð²Ñ.Ð¿ÐŸÐ»ÐœÐžÑ.Ñ., ÐœÐ°Ð¿Ñ.ÐžÐŒÐµÑ. d ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ
++       ÐŸÐ±Ñ.ÐµÐºÑ.  - ÐœÐ° Ñ.Ñ.ÐŸ ÐŽÐŸÐ»Ð¶ÐœÐ° Ð²ÐŸÐ·ÐŽÐµÐ¹ÑÑ.Ð²ÐŸÐ²Ð°Ñ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÐ°, ÐœÐ°Ð¿Ñ.ÐžÐŒÐµÑ. w (ÑÐ»ÐŸÐ²ÐŸ),
++		$ (ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐž), Ðž Ñ..ÐŽ.
++
++  5. Ð.Ð»Ñ ÐŸÑ.ÐŒÐµÐœÑ. (ÐŸÑ.ÐºÐ°Ñ.Ð°) Ð¿Ñ.ÐµÐŽÑ.ÐµÑÑ.Ð²Ñ.Ñ.Ñ.ÐžÑ. ÐŽÐµÐ¹ÑÑ.Ð²ÐžÐ¹ ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:  u (ÑÑ.Ñ.ÐŸÑ.ÐœÐ°Ñ u)
++     Ð.Ð»Ñ ÐŸÑ.ÐŒÐµÐœÑ. (ÐŸÑ.ÐºÐ°Ñ.Ð°) Ð²ÑÐµÑ. ÐžÐ·ÐŒÐµÐœÐµÐœÐžÐ¹ Ð² ÑÑ.Ñ.ÐŸÐºÐµ ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:  U (Ð¿Ñ.ÐŸÐ¿ÐžÑÐœÐ°Ñ U)
++     Ð.Ð»Ñ ÐŸÑ.ÐŒÐµÐœÑ. ÐŸÑ.ÐºÐ°Ñ.Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ:  CTRL-R
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Ð£Ñ.ÐŸÐº 3.1: Ð.Ð.Ð.ÐÐÐ.Ð Ð.Ð¡Ð¢ÐÐ.Ð.Ð.
++
++
++   ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ p ÐŽÐ»Ñ Ð²ÑÑ.Ð°Ð²ÐºÐž Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ³ÐŸ Ñ.ÐŽÐ°Ð»ÐµÐœÐœÐŸÐ³ÐŸ Ñ.ÐµÐºÑÑ.Ð° Ð¿ÐŸÑÐ»Ðµ ÐºÑ.Ñ.ÑÐŸÑ.Ð°. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ· Ðº Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ ÐžÐ· ÐœÐ°Ð±ÐŸÑ.Ð°.
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ dd ÐŽÐ»Ñ Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ ÑÑ.Ñ.ÐŸÐºÐž Ðž ÐµÐµ ÑÐŸÑ.Ñ.Ð°ÐœÐµÐœÐžÑ Ð² Ð±Ñ.Ñ.ÐµÑ.Ðµ Vim'Ð°.
++
++  3. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ðº ÑÑ.Ñ.ÐŸÐºÐµ ÐÐÐ. Ñ.ÐµÐŒ ÐŒÐµÑÑ.ÐŸÐŒ, ÐºÑ.ÐŽÐ° ÑÐ»ÐµÐŽÑ.ÐµÑ. Ð²ÑÑ.Ð°Ð²ÐžÑ.Ñ.
++     Ñ.ÐŽÐ°Ð»ÐµÐœÐœÑ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ..
++
++  4. ÐÐ°Ñ.ÐŸÐŽÑÑÑ. Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ p ÐŽÐ»Ñ Ð·Ð°ÐŒÐµÐœÑ. ÑÑ.Ñ.ÐŸÐºÐž.
++
++  5. Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 2--4, Ð¿ÐŸÐºÐ° ÐœÐµ Ñ.Ð°ÑÑÑ.Ð°Ð²ÐžÑ.Ðµ Ð²ÑÐµ ÑÑ.Ñ.ÐŸÐºÐž Ð² ÐœÑ.Ð¶ÐœÐŸÐŒ Ð¿ÐŸÑ.ÑÐŽÐºÐµ.
++
++     Ð³) Ð. Ð»Ñ.Ñ.Ñ.Ðµ Ð²Ñ.ÐŽÑ.ÐŒÐ°Ñ.Ñ. ÐœÐµ ÐŒÐŸÐ³.
++     Ð±) Ð.ÐŸÐ³ÐŽÐ° ÐœÐµ Ð² Ñ.Ñ.Ñ.ÐºÑ. Ð·Ð°ÐœÐµÐŒÐŸÐ³,
++     Ð²) Ð.Ðœ Ñ.Ð²Ð°Ð¶Ð°Ñ.Ñ. ÑÐµÐ±Ñ Ð·Ð°ÑÑ.Ð°Ð²ÐžÐ»
++     Ð°) Ð.ÐŸÐ¹ ÐŽÑÐŽÑ ÑÐ°ÐŒÑ.Ñ. Ñ.ÐµÑÑ.ÐœÑ.Ñ. Ð¿Ñ.Ð°Ð²ÐžÐ»
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		       Ð£Ñ.ÐŸÐº 3.2: Ð.Ð.Ð.ÐÐÐ.Ð Ð.ÐÐ.Ð.ÐÐ«
++
++
++	  ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ r Ðž ÑÐžÐŒÐ²ÐŸÐ», Ð·Ð°ÐŒÐµÐœÑÑ.Ñ.ÐžÐ¹ ÑÐžÐŒÐ²ÐŸÐ» Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð£ÑÑ.Ð°ÐœÐŸÐ²ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ñ.Ð°Ðº, Ñ.Ñ.ÐŸÐ±Ñ. ÐŸÐœ ÐœÐ°Ñ.ÐŸÐŽÐžÐ»ÑÑ ÐœÐ°ÐŽ Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÐŸÑ.ÐžÐ±ÐºÐŸÐ¹.
++
++  3. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ r	Ðž Ð·Ð°Ñ.ÐµÐŒ ÑÐžÐŒÐ²ÐŸÐ», ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÑÑ.Ñ.ÐžÐ¹ ÐŸÑ.ÐžÐ±ÐºÑ..
++
++  4. Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 2 Ðž 3, Ð¿ÐŸÐºÐ° Ð¿ÐµÑ.Ð²Ð°Ñ ÑÑ.Ñ.ÐŸÐºÐ° ÐœÐµ Ð±Ñ.ÐŽÐµÑ. ÐžÑÐ¿Ñ.Ð°Ð²Ð»ÐµÐœÐ°.
++
++--->  Ð. ÐŒÐŸÐŒÐµÐ³Ñ. ÐœÐ°Ð±Ñ.Ñ.Ð° ÑÑ.ÐŸÐ¹ Ñ.Ñ.Ñ.ÐŸÐºÐž ÐºÐŸÐµ0ÐºÑ.ÐŸ Ñ Ñ.Ñ.Ñ.ÐŽÐŸÐŒ Ð¿ÐŸÐ¿Ð²ÐŽÐ°Ð» Ð¿ÐŸ ÐºÐ»Ð²Ð°ÐžÑ.Ð°ÐŒ!
++--->  Ð. ÐŒÐŸÐŒÐµÐœÑ. ÐœÐ°Ð±ÐŸÑ.Ð° ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐºÐŸÐµ-ÐºÑ.ÐŸ Ñ Ñ.Ñ.Ñ.ÐŽÐŸÐŒ Ð¿ÐŸÐ¿Ð°ÐŽÐ°Ð» Ð¿ÐŸ ÐºÐ»Ð°Ð²ÐžÑ.Ð°ÐŒ!
++
++  5. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº Ð£Ñ.ÐŸÐºÑ. 3.2.
++
++Ð.ÐÐ.Ð.Ð§ÐÐÐ.Ð.: Ð.ÐŸÐŒÐœÐžÑ.Ðµ, Ñ.Ñ.ÐŸ Ð²Ñ. ÐŽÐŸÐ»Ð¶ÐœÑ. Ñ.Ñ.ÐžÑ.Ñ.ÑÑ Ð² Ð¿Ñ.ÐŸÑ.ÐµÑÑÐµ Ñ.Ð°Ð±ÐŸÑ.Ñ., Ð° ÐœÐµ Ð¿Ñ.ÐŸÑÑ.ÐŸ
++	   Ð·Ð°Ð¿ÐŸÐŒÐžÐœÐ°Ñ.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Ð£Ñ.ÐŸÐº 3.3: Ð.Ð.Ð.ÐÐÐ.Ð Ð.Ð.Ð.Ð.ÐÐ.ÐÐ.Ð¯
++
++
++		** Ð.Ð»Ñ ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ Ñ.Ð°ÑÑ.Ðž ÑÐ»ÐŸÐ²Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ cw . **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð Ð°ÑÐ¿ÐŸÐ»ÐŸÐ¶ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. ÐœÐ°ÐŽ Ð±Ñ.ÐºÐ²ÐŸÐ¹ `o' Ð² ÑÐ»ÐŸÐ²Ðµ `ÑÐŸÐ»Ð°'.
++
++  3. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ cw Ðž ÐžÑÐ¿Ñ.Ð°Ð²Ñ.Ñ.Ðµ ÑÐ»ÐŸÐ²ÐŸ (Ð² ÐŽÐ°ÐœÐœÐŸÐŒ ÑÐ»Ñ.Ñ.Ð°Ðµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ `Ð»ÐŸÐ²'.)
++
++  4. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC> Ðž Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐžÑ.Ðµ Ðº ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐ¹ ÐŸÑ.ÐžÐ±ÐºÐµ (Ðº Ð¿ÐµÑ.Ð²ÐŸÐŒÑ. ÑÐžÐŒÐ²ÐŸÐ»Ñ., ÐºÐŸÑ.ÐŸÑ.Ñ.Ð¹
++     ÐœÐ°ÐŽÐŸ ÐžÐ·ÐŒÐµÐœÐžÑ.Ñ..)
++
++  5. Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 3--4 Ð¿ÐŸÐºÐ° Ð¿ÐµÑ.Ð²ÐŸÐµ Ð¿Ñ.ÐµÐŽÐ»ÐŸÐ¶ÐµÐœÐžÐµ ÐœÐµ ÑÑ.Ð°ÐœÐµÑ. ÐžÐŽÐµÐœÑ.ÐžÑ.ÐœÑ.ÐŒ Ð²Ñ.ÐŸÑ.ÐŸÐŒÑ..
++
++---> ÐÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ ÑÐŸÐ»Ð° Ð² ÑÑ.Ð³Ñ. ÑÑ.Ñ.ÐŸÐºÐµ Ñ.Ð¿Ð³Ñ.Ñ.Ð±Ñ. Ñ.ÐµÐŽÐ°Ð»Ð·ÐºÑ.Ñ.ÐžÐµÑÐ²Ñ..
++---> ÐÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ ÑÐ»ÐŸÐ² Ð² ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ Ñ.Ñ.ÐµÐ±Ñ.Ñ.Ñ. Ñ.ÐµÐŽÐ°ÐºÑ.ÐžÑ.ÐŸÐ²Ð°ÐœÐžÑ.
++
++Ð.Ð±Ñ.Ð°Ñ.ÐžÑ.Ðµ Ð²ÐœÐžÐŒÐ°ÐœÐžÐµ, Ñ.Ñ.ÐŸ cw ÐœÐµ Ñ.ÐŸÐ»Ñ.ÐºÐŸ Ð·Ð°ÐŒÐµÐœÑÐµÑ. ÑÐ»ÐŸÐ²ÐŸ, ÐœÐŸ Ðž Ð¿ÐµÑ.ÐµÐ²ÐŸÐŽÐžÑ. Ð²Ð°Ñ Ð² Ñ.ÐµÐ¶ÐžÐŒ
++Ð²ÑÑ.Ð°Ð²ÐºÐž.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		  Ð£Ñ.ÐŸÐº 3.4: Ð.Ð Ð.Ð.Ð.Ð.Ð.ÐÐ.Ð. Ð.Ð.Ð.Ð.ÐÐ¯Ð¢Ð¬ Ð¡ Ð.Ð.Ð.ÐÐÐ.Ð.Ð. c
++
++
++** Ð.ÐŸÐŒÐ°ÐœÐŽÐ° Ð·Ð°ÐŒÐµÐœÑ. ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.ÐµÑ.ÑÑ Ñ Ñ.ÐµÐŒÐž Ð¶Ðµ ÐŸÐ±Ñ.ÐµÐºÑ.Ð°ÐŒÐž, Ñ.Ñ.ÐŸ Ðž ÐºÐŸÐŒÐ°ÐœÐŽÐ° Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ. **
++
++  1. Ð.ÐŸÐŒÐ°ÐœÐŽÐ° ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ Ð¿Ñ.ÐžÐŒÐµÐœÑÐµÑ.ÑÑ Ñ.Ð°ÐºÐžÐŒ Ð¶Ðµ ÐŸÐ±Ñ.Ð°Ð·ÐŸÐŒ, ÐºÐ°Ðº Ðž ÐºÐŸÐŒÐ°ÐœÐŽÐ° Ñ.ÐŽÐ°Ð»ÐµÐœÐžÑ.
++     Ð.Ðµ Ñ.ÐŸÑ.ÐŒÐ°Ñ. Ñ.Ð°ÐºÐŸÐ²:
++
++       [Ñ.ÐžÑÐ»ÐŸ]   c   ÐŸÐ±Ñ.ÐµÐºÑ.	   Ð.Ð.Ð.	    c	[Ñ.ÐžÑÐ»ÐŸ]   ÐŸÐ±Ñ.ÐµÐºÑ.
++
++  2. Ð.Ð±Ñ.ÐµÐºÑ.Ñ. Ñ.Ð°ÐºÐ¶Ðµ ÑÐŸÐ²Ð¿Ð°ÐŽÐ°Ñ.Ñ.: w (ÑÐ»ÐŸÐ²ÐŸ), $ (ÐºÐŸÐœÐµÑ. ÑÑ.Ñ.ÐŸÐºÐž) Ðž Ñ..Ð¿.
++
++  3. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  4. Ð.ÐµÑ.ÐµÐ¹ÐŽÐžÑ.Ðµ Ðº Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÐŸÑ.ÐžÐ±ÐºÐµ.
++
++  5. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ c$ Ðž ÐŸÑ.Ñ.ÐµÐŽÐ°ÐºÑ.ÐžÑ.Ñ.Ð¹Ñ.Ðµ Ð¿ÐµÑ.Ð²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. Ñ.Ð°Ðº, Ñ.Ñ.ÐŸÐ±Ñ. ÐŸÐœÐ° ÑÐŸÐ²Ð¿Ð°ÐŽÐ°Ð»Ð° ÑÐŸ
++     Ð²Ñ.ÐŸÑ.ÐŸÐ¹, Ð¿ÐŸÑÐ»Ðµ Ñ.ÐµÐ³ÐŸ ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC>.
++
++---> Ð.ÐŸÐœÐµÑ. ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐœÑ.Ð¶ÐŽÐ°ÐµÑ.ÑÑ Ð² Ð¿ÐŸÐŒÐŸÑ.Ðž, Ñ.Ñ.ÐŸÐ±Ñ. ÑÑ.Ð°Ñ.Ñ. Ð¿ÐŸÑ.ÐŸÐ¶ÐžÐŒ ÐœÐ° Ð²Ñ.ÐŸÑ.ÐŸÐ¹.
++---> Ð.ÐŸÐœÐµÑ. ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž ÐœÑ.Ð¶ÐŽÐ°ÐµÑ.ÑÑ Ð² Ð¿ÐŸÐŒÐŸÑ.Ðž ÐºÐŸÐŒÐ°ÐœÐŽÑ. c$ .
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 3
++
++
++  1. Ð.Ð»Ñ Ð²ÑÑ.Ð°Ð²ÐºÐž Ñ.ÐµÐºÑÑ.Ð°, ÐºÐŸÑ.ÐŸÑ.Ñ.Ð¹ Ñ.ÐŸÐ»Ñ.ÐºÐŸ Ñ.Ñ.ÐŸ Ð±Ñ.Ð» Ñ.ÐŽÐ°Ð»ÐµÐœ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ p . Ð­Ñ.Ð°
++     ÐºÐŸÐŒÐ°ÐœÐŽÐ° Ð²ÑÑ.Ð°Ð²ÐžÑ. Ñ.ÐŽÐ°Ð»ÐµÐœÐœÑ.Ð¹ Ñ.ÐµÐºÑÑ. Ð.Ð.Ð¡Ð.Ð. ÐºÑ.Ñ.ÑÐŸÑ.Ð° (ÐµÑÐ»Ðž Ð±Ñ.Ð»Ð° Ñ.ÐŽÐ°Ð»ÐµÐœÐ° ÑÑ.Ñ.ÐŸÐºÐ°,
++     Ñ.ÐŸ ÐŸÐœÐ° Ð±Ñ.ÐŽÐµÑ. Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐ° Ð² ÑÑ.Ñ.ÐŸÐºÐµ Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ).
++
++  2. Ð.Ð»Ñ Ð·Ð°ÐŒÐµÐœÑ. ÑÐžÐŒÐ²ÐŸÐ»Ð° Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ r Ðž Ð·Ð°Ñ.ÐµÐŒ Ð·Ð°ÐŒÐµÐœÑÑ.Ñ.ÐžÐ¹ ÑÐžÐŒÐ²ÐŸÐ».
++
++  3. Ð.ÐŸÐŒÐ°ÐœÐŽÐ° ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. Ð.Ð°ÐŒ ÐžÐ·ÐŒÐµÐœÐžÑ.Ñ. Ñ.ÐºÐ°Ð·Ð°ÐœÐœÑ.Ð¹ ÐŸÐ±Ñ.ÐµÐºÑ. ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ
++     ÐºÐŸÐœÑ.Ð° ÑÑ.ÐŸÐ³ÐŸ ÐŸÐ±Ñ.ÐµÐºÑ.Ð°. ÐÐ°Ð¿Ñ.ÐžÐŒÐµÑ., ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ cw ÐŽÐ»Ñ Ð·Ð°ÐŒÐµÐœÑ. ÐŸÑ. ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐŽÐŸ
++     ÐºÐŸÐœÑ.Ð° ÑÐ»ÐŸÐ²Ð°, c$ ÐŽÐ»Ñ ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ ÐŽÐŸ ÐºÐŸÐœÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐž.
++
++  4. Ð€ÐŸÑ.ÐŒÐ°Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ. ÐžÐ·ÐŒÐµÐœÐµÐœÐžÑ Ñ.Ð°ÐºÐŸÐ²:
++
++	 [Ñ.ÐžÑÐ»ÐŸ]   c	ÐŸÐ±Ñ.ÐµÐºÑ.	      Ð.Ð.Ð.	c   [Ñ.ÐžÑÐ»ÐŸ]   ÐŸÐ±Ñ.ÐµÐºÑ.
++
++Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐŸÑ.Ð¿Ñ.Ð°Ð²Ð»ÑÐ¹Ñ.ÐµÑÑ. Ðº ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐŒÑ. Ñ.Ñ.ÐŸÐºÑ..
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++	      Ð£Ñ.ÐŸÐº 4.1: Ð.ÐÐ€Ð.Ð Ð.ÐÐŠÐ.Ð¯ Ð. Ð€ÐÐ.Ð.Ð. Ð. Ð ÐÐ¡Ð.Ð.Ð.Ð.Ð.Ð.ÐÐ.Ð. Ð. ÐÐ.Ð.
++
++
++ ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ CTRL-g Ñ.Ñ.ÐŸÐ±Ñ. Ñ.Ð²ÐžÐŽÐµÑ.Ñ. Ð.Ð°Ñ.Ðµ ÐŒÐµÑÑ.ÐŸÑ.Ð°ÑÐ¿ÐŸÐ»ÐŸÐ¶ÐµÐœÐžÐµ Ð² Ñ.Ð°Ð¹Ð»Ðµ Ðž ÐžÐœÑ.ÐŸÑ.ÐŒÐ°Ñ.ÐžÑ.
++				    ÐŸ ÐœÐµÐŒ.
++	ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ SHIFT-G ÐŽÐ»Ñ Ð¿ÐµÑ.ÐµÐŒÐµÑ.ÐµÐœÐžÑ Ðº Ð·Ð°ÐŽÐ°ÐœÐœÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ Ð² Ñ.Ð°Ð¹Ð»Ðµ. **
++
++  Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.Ñ.ÐŸÑ.ÐžÑ.Ð°Ð¹Ñ.Ðµ Ð²ÐµÑÑ. Ñ.Ñ.ÐŸÐº Ð¿Ñ.ÐµÐ¶ÐŽÐµ Ñ.ÐµÐŒ Ð²Ñ.Ð¿ÐŸÐ»ÐœÑÑ.Ñ. Ð»Ñ.Ð±Ñ.Ðµ ÐºÐŸÐŒÐ°ÐœÐŽÑ.!!
++
++  1. Ð£ÐŽÐµÑ.Ð¶ÐžÐ²Ð°Ñ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. Ctrl ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ g . Ð.ÐœÐžÐ·Ñ. ÑÐºÑ.Ð°ÐœÐ° Ð¿ÐŸÑÐ²ÐžÑ.ÑÑ ÑÑ.Ñ.ÐŸÐºÐ° ÑÑ.Ð°Ñ.Ñ.ÑÐ° Ñ
++     ÐžÐŒÐµÐœÐµÐŒ Ñ.Ð°Ð¹Ð»Ð° Ðž ÐœÐŸÐŒÐµÑ.ÐŸÐŒ ÑÑ.Ñ.ÐŸÐºÐž, Ð² ÐºÐŸÑ.ÐŸÑ.ÐŸÐ¹ Ð.Ñ. ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÐµÑÑ.. Ð.Ð°Ð¿ÐŸÐŒÐœÐžÑ.Ðµ ÐœÐŸÐŒÐµÑ.
++     ÑÑ.Ñ.ÐŸÐºÐž, ÐŸÐœ Ð¿ÐŸÑ.Ñ.ÐµÐ±Ñ.ÐµÑ.ÑÑ ÐœÐ° ÐšÐ°Ð³Ðµ 3.
++
++  2. ÐÐ°Ð¶ÐŒÐžÑ.Ðµ shift-G ÐŽÐ»Ñ Ð¿ÐµÑ.ÐµÐŒÐµÑ.ÐµÐœÐžÑ Ðº ÐºÐŸÐœÑ.Ñ. Ñ.Ð°Ð¹Ð»Ð°.
++
++  3. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ÐœÐŸÐŒÐµÑ. ÑÑ.Ñ.ÐŸÐºÐž, Ð² ÐºÐŸÑ.ÐŸÑ.ÐŸÐ¹ Ð²Ñ. ÐœÐ°Ñ.ÐŸÐŽÐžÐ»ÐžÑÑ. Ðž Ð·Ð°Ñ.ÐµÐŒ shift-G. Ð­Ñ.ÐŸ
++     Ð²ÐµÑ.ÐœÐµÑ. Ð.Ð°Ñ Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð² ÐºÐŸÑ.ÐŸÑ.ÐŸÐ¹ Ð.Ñ. Ð±Ñ.Ð»Ðž, ÐºÐŸÐ³ÐŽÐ° Ð² Ð¿ÐµÑ.Ð²Ñ.Ð¹ Ñ.Ð°Ð· ÐœÐ°Ð¶Ð°Ð»Ðž Ctrl-g.
++     (Ð.ÐŸÐ³ÐŽÐ° Ð.Ñ. Ð±Ñ.ÐŽÐµÑ.Ðµ ÐœÐ°Ð±ÐžÑ.Ð°Ñ.Ñ. Ñ.ÐžÑ.Ñ.Ñ., ÐŸÐœÐž ÐÐ. ÐŸÑ.ÐŸÐ±Ñ.Ð°Ð·ÑÑ.ÑÑ ÐœÐ° ÑÐºÑ.Ð°ÐœÐµ.)
++
++  4. Ð.ÑÐ»Ðž Ð.Ñ. Ð·Ð°Ð¿ÐŸÐŒÐœÐžÐ»Ðž Ð²ÑÐµ Ð²Ñ.Ñ.ÐµÑÐºÐ°Ð·Ð°ÐœÐœÐŸÐµ, Ð²Ñ.Ð¿ÐŸÐ»ÐœÐžÑ.Ðµ Ñ.Ð°Ð³Ðž 1--3.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			   Ð£Ñ.ÐŸÐº 4.2: Ð.Ð.Ð.ÐÐÐ.Ð Ð.Ð.Ð.Ð¡Ð.Ð
++
++	      ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ  /  Ðž Ð·Ð°Ñ.ÐµÐŒ Ð²Ð²ÐµÐŽÐžÑ.Ðµ ÐžÑÐºÐŸÐŒÑ.Ñ. Ñ.Ñ.Ð°Ð·Ñ.. **
++
++  1. Ð. ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ (Normal mode) ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ÑÐžÐŒÐ²ÐŸÐ»  / . Ð.Ð±Ñ.Ð°Ñ.ÐžÑ.Ðµ Ð²ÐœÐžÐŒÐ°ÐœÐžÐµ,
++     Ñ.Ñ.ÐŸ ÐŸÐœ Ð²ÐŒÐµÑÑ.Ðµ Ñ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ Ð¿ÐŸÑÐ²ÐžÑ.ÑÑ Ð²ÐœÐžÐ·Ñ. ÑÐºÑ.Ð°ÐœÐ°, ÐºÐ°Ðº ÑÑ.ÐŸ Ð¿Ñ.ÐŸÐžÑÑ.ÐŸÐŽÐžÑ. Ñ
++     ÐºÐŸÐŒÐ°ÐœÐŽÐŸÐ¹ :	.
++
++  2. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ 'ÐŸÑ.Ñ.Ñ.ÐžÐ±ÐºÐ°' <ENTER>. Ð­Ñ.ÐŸ Ñ.ÐŸ ÑÐ»ÐŸÐ²ÐŸ, ÐºÐŸÑ.ÐŸÑ.ÐŸÐµ Ð.Ñ. Ð±Ñ.ÐŽÐµÑ.Ðµ
++     ÐžÑÐºÐ°Ñ.Ñ..
++
++  3. Ð.Ð»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ð¿ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ñ. Ð¿ÐŸÐžÑÐº, Ð¿Ñ.ÐŸÑÑ.ÐŸ ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ n .
++     Ð.Ð»Ñ Ð¿ÐŸÐžÑÐºÐ° ÑÑ.ÐŸÐ¹ Ñ.Ñ.Ð°Ð·Ñ. Ð² ÐŸÐ±Ñ.Ð°Ñ.ÐœÐŸÐŒ ÐœÐ°Ð¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÐž, ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ Shift-N .
++
++  4. Ð.ÑÐ»Ðž Ð.Ñ. Ð¶ÐµÐ»Ð°ÐµÑ.Ðµ ÑÑ.Ð°Ð·Ñ. ÐžÑÐºÐ°Ñ.Ñ. Ð² ÐŸÐ±Ñ.Ð°Ñ.ÐœÐŸÐŒ ÐœÐ°Ð¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÐž, ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ð¹Ñ.Ðµ
++     ÐºÐŸÐŒÐ°ÐœÐŽÑ. ? Ð²ÐŒÐµÑÑ.ÐŸ / .
++
++---> Ð.ÐŸÐ³ÐŽÐ° Ð.Ñ. Ð¿Ñ.Ðž Ð¿ÐŸÐžÑÐºÐµ ÐŽÐŸÑÑ.ÐžÐ³ÐœÐµÑ.Ðµ ÐºÐŸÐœÑ.Ð° Ñ.Ð°Ð¹Ð»Ð°, Ð¿ÐŸÐžÑÐº Ð±Ñ.ÐŽÐµÑ. Ð¿Ñ.ÐŸÐŽÐŸÐ»Ð¶ÐµÐœ Ñ
++     ÐœÐ°Ñ.Ð°Ð»Ð°.
++
++  "ÐŸÑ.Ñ.Ñ.ÐžÐ±ÐºÐ°" ÑÑ.ÐŸ ÐœÐµ ÑÐ¿ÐŸÑÐŸÐ± Ð¿Ñ.ÐŸÐžÐ·ÐœÐµÑÐµÐœÐžÑ ÑÐ»ÐŸÐ²Ð° `ÐŸÑ.ÐžÐ±ÐºÐ°';  ÐŸÑ.Ñ.Ñ.ÐžÐ±ÐºÐ° ÑÑ.ÐŸ ÐŸÑ.ÐžÐ±ÐºÐ°.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Ð£Ñ.ÐŸÐº 4.3: Ð.Ð.Ð.Ð¡Ð. Ð.ÐÐ ÐÐ«Ð¥ Ð¡Ð.Ð.Ð.Ð.Ð.
++
++
++		** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ % ÐŽÐ»Ñ Ð¿ÐŸÐžÑÐºÐ° Ð¿Ð°Ñ.ÐœÑ.Ñ. ),] ÐžÐ»Ðž } . **
++
++  1. Ð.ÐŸÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. ÐœÐ°ÐŽ Ð»Ñ.Ð±ÐŸÐ¹ ÐžÐ· (, [ ÐžÐ»Ðž { Ð² ÑÑ.Ñ.ÐŸÐºÐµ Ð²ÐœÐžÐ·Ñ., Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ÑÐžÐŒÐ²ÐŸÐ» % .
++
++  3. Ð.Ñ.Ñ.ÑÐŸÑ. ÐŽÐŸÐ»Ð¶ÐµÐœ Ð¿ÐµÑ.ÐµÑÐºÐŸÑ.ÐžÑ.Ñ. ÐœÐ° Ð¿Ð°Ñ.ÐœÑ.Ñ. ÑÐºÐŸÐ±ÐºÑ..
++
++  4. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ % ÐŽÐ»Ñ Ð²ÐŸÐ·Ð²Ñ.Ð°Ñ.Ð° ÐºÑ.Ñ.ÑÐŸÑ.Ð° ÐœÐ°Ð·Ð°ÐŽ Ðº Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÑÐºÐŸÐ±ÐºÐµ.
++
++---> Ð­Ñ.ÐŸ ( ÑÑ.Ñ.ÐŸÐºÐ°, ÑÐŸÐŽÐµÑ.Ð¶Ð°Ñ.Ð°Ñ Ñ.Ð°ÐºÐžÐµ (, Ñ.Ð°ÐºÐžÐµ [ ] Ðž Ñ.Ð°ÐºÐžÐµ { } ÑÐºÐŸÐ±ÐºÐž. ))
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð­Ñ.ÐŸ ÐŸÑ.ÐµÐœÑ. Ñ.ÐŽÐŸÐ±ÐœÐŸ Ð¿Ñ.Ðž ÐŸÑ.Ð»Ð°ÐŽÐºÐµ Ð¿Ñ.ÐŸÐ³Ñ.Ð°ÐŒÐŒ Ñ Ð¿Ñ.ÐŸÐ¿Ñ.Ñ.ÐµÐœÐœÑ.ÐŒÐž ÑÐºÐŸÐ±ÐºÐ°ÐŒÐž!
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		      Ð£Ñ.ÐŸÐº 4.4: Ð¡Ð.Ð.Ð¡Ð.Ð. Ð.Ð¡Ð.Ð ÐÐ.Ð.Ð.ÐÐ.Ð¯ Ð.ÐšÐ.Ð.Ð.Ð.
++
++
++	 ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :s/Ð±Ñ.Ð»ÐŸ/ÑÑ.Ð°Ð»ÐŸ/g ÐŽÐ»Ñ Ð·Ð°ÐŒÐµÐœÑ. 'Ð±Ñ.Ð»ÐŸ' ÐœÐ° 'ÑÑ.Ð°Ð»ÐŸ'. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :s/Ñ.Ð²ÐŸÐŽÑ./Ñ.Ð²ÐŸÐ¶Ñ. <ENTER> . Ð.Ð±Ñ.Ð°Ñ.ÐžÑ.Ðµ Ð²ÐœÐžÐŒÐ°ÐœÐžÐµ ÐœÐ° Ñ.ÐŸ, Ñ.Ñ.ÐŸ ÑÑ.Ð° ÐºÐŸÐŒÐ°ÐœÐŽÐ°
++     Ð·Ð°ÐŒÐµÐœÐžÑ. Ñ.ÐŸÐ»Ñ.ÐºÐŸ Ð¿ÐµÑ.Ð²ÐŸÐµ ÐœÐ°Ð¹ÐŽÐµÐœÐœÐŸÐµ Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÐµ Ð² ÑÑ.Ñ.ÐŸÐºÐµ.
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :s/Ñ.Ð²ÐŸÐŽÑ./Ñ.Ð²ÐŸÐ¶Ñ./g , ÐŸÐ·ÐœÐ°Ñ.Ð°Ñ.Ñ.ÐµÐµ Ð¿ÐŸÐŽÑÑ.Ð°ÐœÐŸÐ²ÐºÑ. Ð³Ð»ÐŸÐ±Ð°Ð»Ñ.ÐœÐŸ Ð²ÐŸ
++     Ð²ÑÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ. Ð­Ñ.ÐŸ Ð·Ð°ÐŒÐµÐœÐžÑ. Ð²ÑÐµ ÐœÐ°Ð¹ÐŽÐµÐœÐœÑ.Ðµ Ð² ÑÑ.Ñ.ÐŸÐºÐµ Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÑ.
++
++---> Ð¯ Ñ.Ð²ÐŸÐŽÑ. Ðº ÐŸÑ.Ð²ÐµÑ.Ð¶ÐµÐœÐœÑ.ÐŒ ÑÐµÐ»ÐµÐœÑ.ÑÐŒ, Ñ Ñ.Ð²ÐŸÐŽÑ. ÑÐºÐ²ÐŸÐ·Ñ. Ð²ÐµÐºÐŸÐ²ÐµÑ.ÐœÑ.Ð¹ ÑÑ.ÐŸÐœ, Ñ Ñ.Ð²ÐŸÐŽÑ. Ðº
++     Ð·Ð°Ð±Ñ.Ñ.Ñ.ÐŒ Ð¿ÐŸÐºÐŸÐ»ÐµÐœÑ.ÑÐŒ.
++
++  4. Ð.Ð»Ñ Ð·Ð°ÐŒÐµÐœÑ. Ð²ÑÐµÑ. Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÐ¹ Ð¿ÐŸÑÐ»ÐµÐŽÐŸÐ²Ð°Ñ.ÐµÐ»Ñ.ÐœÐŸÑÑ.Ðž ÑÐžÐŒÐ²ÐŸÐ»ÐŸÐ² ÐŒÐµÐ¶ÐŽÑ. ÐŽÐ²Ñ.ÐŒÑ
++     ÑÑ.Ñ.ÐŸÐºÐ°ÐŒÐž,
++     ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :#,#s/Ð±Ñ.Ð»ÐŸ/ÑÑ.Ð°Ð»ÐŸ/g  Ð³ÐŽÐµ #,# --- ÐœÐŸÐŒÐµÑ.Ð° ÑÑ.ÐžÑ. ÑÑ.Ñ.ÐŸÐº.
++     ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :%s/Ð±Ñ.Ð»ÐŸ/ÑÑ.Ð°Ð»ÐŸ/g    ÐŽÐ»Ñ Ð·Ð°ÐŒÐµÐœÑ. Ð²ÑÐµÑ. Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÐ¹ Ð²ÐŸ Ð²ÑÐµÐŒ Ñ.Ð°Ð¹Ð»Ðµ.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 4
++  1. Ctrl-g Ð¿ÐŸÐºÐ°Ð·Ñ.Ð²Ð°ÐµÑ. Ð²Ð°Ñ.Ðµ Ð¿ÐŸÐ»ÐŸÐ¶ÐµÐœÐžÐµ Ð² Ñ.Ð°Ð¹Ð»Ðµ Ðž ÐžÐœÑ.ÐŸÑ.ÐŒÐ°Ñ.ÐžÑ. ÐŸ ÐœÐµÐŒ.
++     Shift-G Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ. Ð.Ð°Ñ Ð² ÐºÐŸÐœÐµÑ. Ñ.Ð°Ð¹Ð»Ð°. ÐÐŸÐŒÐµÑ., Ð·Ð° ÐºÐŸÑ.ÐŸÑ.Ñ.ÐŒ ÑÐ»ÐµÐŽÑ.ÐµÑ. Shift-G
++     Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ðº ÑÑ.Ñ.ÐŸÐºÐµ Ñ ÑÑ.ÐžÐŒ ÐœÐŸÐŒÐµÑ.ÐŸÐŒ.
++
++  2. ÐÐ°Ð¶Ð°Ñ.ÐžÐµ / Ðž Ð·Ð°Ñ.ÐµÐŒ Ð²Ð²ÐŸÐŽ ÑÑ.Ñ.ÐŸÐºÐž Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. Ð¿Ñ.ÐŸÐžÐ·Ð²ÐµÑÑ.Ðž Ð¿ÐŸÐžÑÐº ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž
++     Ð.Ð.Ð.Ð Ð.Ð. Ð¿ÐŸ Ñ.ÐµÐºÑÑ.Ñ..
++     ÐÐ°Ð¶Ð°Ñ.ÐžÐµ ? Ðž Ð·Ð°Ñ.ÐµÐŒ Ð²Ð²ÐŸÐŽ ÑÑ.Ñ.ÐŸÐºÐž Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. Ð¿Ñ.ÐŸÐžÐ·Ð²ÐµÑÑ.Ðž Ð¿ÐŸÐžÑÐº ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž
++     ÐÐÐ.ÐÐ. Ð¿ÐŸ Ñ.ÐµÐºÑÑ.Ñ..
++     Ð.ÐŸÑÐ»Ðµ Ð¿ÐŸÐžÑÐºÐ° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ n ÐŽÐ»Ñ Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐ° Ðº ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐŒÑ. Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÑ. ÐžÑÐºÐŸÐŒÐŸÐ¹
++     ÑÑ.Ñ.ÐŸÐºÐž Ð² Ñ.ÐŸÐŒ Ð¶Ðµ ÐœÐ°Ð¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÐž ÐžÐ»Ðž Shift-N ÐŽÐ»Ñ Ð¿ÐµÑ.ÐµÑ.ÐŸÐŽÐ° Ð² Ð¿Ñ.ÐŸÑ.ÐžÐ²ÐŸÐ¿ÐŸÐ»ÐŸÐ¶ÐœÐŸÐŒ
++     ÐœÐ°Ð¿Ñ.Ð°Ð²Ð»ÐµÐœÐžÐž.
++
++  3. ÐÐ°Ð¶Ð°Ñ.ÐžÐµ % , ÐºÐŸÐ³ÐŽÐ° ÐºÑ.Ñ.ÑÐŸÑ. ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ ÐœÐ° (,),[,],{, ÐžÐ»Ðž } Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. ÐœÐ°Ð¹Ñ.Ðž
++     Ð¿Ð°Ñ.ÐœÑ.Ñ. ÑÐºÐŸÐ±ÐºÑ..
++
++  4. Ð.Ð»Ñ Ð¿ÐŸÐŽÑÑ.Ð°ÐœÐŸÐ²ÐºÐž `ÑÑ.Ð°Ð»ÐŸ' Ð²ÐŒÐµÑÑ.ÐŸ Ð¿ÐµÑ.Ð²ÐŸÐ³ÐŸ `Ð±Ñ.Ð»ÐŸ' Ð² ÑÑ.Ñ.ÐŸÐºÐµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ
++     :s/old/new
++     Ð.Ð»Ñ Ð¿ÐŸÐŽÑÑ.Ð°ÐœÐŸÐ²ÐºÐž `ÑÑ.Ð°Ð»ÐŸ' Ð²ÐŒÐµÑÑ.ÐŸ Ð²ÑÐµÑ. `Ð±Ñ.Ð»ÐŸ' Ð² ÑÑ.Ñ.ÐŸÐºÐµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ
++     :s/old/new/g
++     Ð.Ð»Ñ Ð·Ð°ÐŒÐµÐœÑ. Ð² ÐžÐœÑ.ÐµÑ.Ð²Ð°Ð»Ðµ ÐŒÐµÐ¶ÐŽÑ. ÐŽÐ²Ñ.ÐŒÑ ÑÑ.Ñ.ÐŸÐºÐ°ÐŒÐž, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ
++     :#,#s/old/new/g
++     Ð.Ð»Ñ Ð·Ð°ÐŒÐµÐœÑ. Ð²ÑÐµÑ. Ð²Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÐ¹ `Ð±Ñ.Ð»ÐŸ' ÐœÐ° `ÑÑ.Ð°Ð»ÐŸ' Ð² Ñ.Ð°Ð¹Ð»Ðµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ
++     :%s/old/new/g
++     Ð§Ñ.ÐŸÐ±Ñ. Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ. ÐºÐ°Ð¶ÐŽÑ.Ð¹ Ñ.Ð°Ð· Ð·Ð°Ð¿Ñ.Ð°Ñ.ÐžÐ²Ð°Ð» Ð¿ÐŸÐŽÑ.Ð²ÐµÑ.Ð¶ÐŽÐµÐœÐžÐµ, ÐŽÐŸÐ±Ð°Ð²Ñ.Ñ.Ðµ 'c'
++     :%s/old/new/gc
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		   Ð£Ñ.ÐŸÐº 5.1: Ð.ÐÐ. Ð.Ð«Ð.Ð.Ð.ÐÐ.Ð¢Ð¬ Ð.ÐÐ.ÐšÐÐ®Ð® Ð.Ð.Ð.ÐÐÐ.Ð£
++
++
++    ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :! Ðž Ð·Ð°Ñ.ÐµÐŒ Ð²ÐœÐµÑ.ÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ., ÐºÐŸÑ.ÐŸÑ.Ñ.Ñ. ÑÐ»ÐµÐŽÑ.ÐµÑ. Ð²Ñ.Ð¿ÐŸÐ»ÐœÐžÑ.Ñ.. **
++
++  1. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ Ñ.Ð¶Ðµ Ð·ÐœÐ°ÐºÐŸÐŒÑ.Ñ. Ð.Ð°ÐŒ ÐºÐŸÐŒÐ°ÐœÐŽÑ. : ÐŽÐ»Ñ Ñ.ÑÑ.Ð°ÐœÐŸÐ²ÐºÐž ÐºÑ.Ñ.ÑÐŸÑ.Ð° Ð² ÐºÐŸÐŒÐ°ÐœÐŽÐœÑ.Ñ.
++     ÑÑ.Ñ.ÐŸÐºÑ. Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ.Ð°. Ð­Ñ.ÐŸ Ð¿ÐŸÐ·Ð²ÐŸÐ»ÐžÑ. Ð.Ð°ÐŒ Ð²Ð²ÐµÑÑ.Ðž ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++
++  2. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ÑÐžÐŒÐ²ÐŸÐ» ! (Ð²ÐŸÑÐºÐ»ÐžÑ.Ð°Ñ.ÐµÐ»Ñ.ÐœÑ.Ð¹ Ð·ÐœÐ°Ðº). Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐŒÐŸÐ¶ÐœÐŸ ÐžÑÐ¿ÐŸÐ»ÐœÐžÑ.Ñ.
++     Ð²ÐœÐµÑ.ÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ., ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ ÐºÐŸÐŒÐ°ÐœÐŽÐœÑ.Ñ. ÐŸÐ±ÐŸÐ»ÐŸÑ.ÐºÑ..
++
++  3. Ð.Ð»Ñ Ð¿Ñ.ÐžÐŒÐµÑ.Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ ls Ð¿ÐŸÑÐ»Ðµ ! Ðž ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ENTER>. Ð­Ñ.Ð° ÐºÐŸÐŒÐ°ÐœÐŽÐ° Ð²Ñ.Ð²ÐµÐŽÐµÑ.
++     ÑÐ¿ÐžÑÐŸÐº Ñ.Ð°Ð¹Ð»ÐŸÐ² Ð² Ñ.ÐµÐºÑ.Ñ.ÐµÐŒ ÐºÐ°Ñ.Ð°Ð»ÐŸÐ³Ðµ, Ñ.ÐŸÑ.ÐœÐŸ Ñ.Ð°ÐºÐ¶Ðµ, ÐºÐ°Ðº ÐµÑÐ»Ðž Ð±Ñ. Ð.Ñ. Ð²Ð²ÐµÐ»Ðž ÑÑ.Ñ.
++     ÐºÐŸÐŒÐ°ÐœÐŽÑ. Ð² Ð¿Ñ.ÐžÐ³Ð»Ð°Ñ.ÐµÐœÐžÐž ÐŸÐ±ÐŸÐ»ÐŸÑ.ÐºÐž. Ð.Ð»Ðž Ð¿ÐŸÐ¿Ñ.ÐŸÐ±Ñ.Ð¹Ñ.Ðµ :!dir , ÐµÑÐ»Ðž Ð¿Ñ.ÐµÐŽÑ.ÐŽÑ.Ñ.Ð°Ñ
++     ÐºÐŸÐŒÐ°ÐœÐŽÐ° ÐœÐµ ÑÑ.Ð°Ð±ÐŸÑ.Ð°Ð»Ð°.
++
++---> Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð¢Ð°ÐºÐžÐŒ ÑÐ¿ÐŸÑÐŸÐ±ÐŸÐŒ ÐŒÐŸÐ¶ÐœÐŸ Ð²Ñ.Ð¿ÐŸÐ»ÐœÐžÑ.Ñ. Ð»Ñ.Ð±Ñ.Ñ. Ð²ÐœÐµÑ.ÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++
++---> Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.ÑÐµ ÐºÐŸÐŒÐ°ÐœÐŽÑ., ÐœÐ°Ñ.ÐžÐœÐ°Ñ.Ñ.ÐžÐµÑÑ Ñ : , ÐŽÐŸÐ»Ð¶ÐœÑ. Ð·Ð°Ð²ÐµÑ.Ñ.Ð°Ñ.Ñ.ÑÑ ÐœÐ°Ð¶Ð°Ñ.ÐžÐµÐŒ
++     <ENTER>.
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Ð£Ñ.ÐŸÐº 5.2: Ð.ÐÐ. Ð.ÐÐ.Ð.Ð¡ÐÐ¢Ð¬ Ð€ÐÐ.Ð.
++
++
++** Ð.Ð»Ñ ÑÐŸÑ.Ñ.Ð°ÐœÐµÐœÐžÑ ÐžÐ·ÐŒÐµÐœÐµÐœÐžÐ¹, Ð¿Ñ.ÐŸÐžÐ·Ð²ÐµÐŽÐµÐœÐœÑ.Ñ. Ð² Ñ.Ð°Ð¹Ð»Ðµ, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :w Ð.Ð.Ð¯_Ð€ÐÐ.Ð.Ð. **
++
++  1. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :!dir ÐžÐ»Ðž :!ls ÐŽÐ»Ñ Ð¿ÐŸÐ»Ñ.Ñ.ÐµÐœÐžÑ ÑÐ¿ÐžÑÐºÐ° Ñ.Ð°Ð¹Ð»ÐŸÐ² Ð² Ñ.ÐµÐºÑ.Ñ.ÐµÐŒ ÐºÐ°Ñ.Ð°Ð»ÐŸÐ³Ðµ.
++     Ð.Ð°Ðº Ð.Ð°ÐŒ Ñ.Ð¶Ðµ ÐžÐ·Ð²ÐµÑÑ.ÐœÐŸ, Ð.Ñ. ÐŽÐŸÐ»Ð¶ÐœÑ. ÐœÐ°Ð¶Ð°Ñ.Ñ. <ENTER> Ð¿ÐŸÑÐ»Ðµ Ð²Ð²ÐŸÐŽÐ° ÑÑ.ÐžÑ. ÐºÐŸÐŒÐ°ÐœÐŽ.
++
++  2. Ð.Ñ.ÐžÐŽÑ.ÐŒÐ°Ð¹Ñ.Ðµ ÐœÐ°Ð·Ð²Ð°ÐœÐžÐµ ÐŽÐ»Ñ Ñ.Ð°Ð¹Ð»Ð°, ÐºÐŸÑ.ÐŸÑ.ÐŸÐµ ÐµÑ.Ðµ ÐœÐµ ÑÑ.Ñ.ÐµÑÑ.Ð²Ñ.ÐµÑ., ÐœÐ°Ð¿Ñ.ÐžÐŒÐµÑ. TEST.
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :w TEST (Ð³ÐŽÐµ TEST --- ÑÑ.ÐŸ ÐžÐŒÑ Ñ.Ð°Ð¹Ð»Ð°, Ð¿Ñ.ÐžÐŽÑ.ÐŒÐ°ÐœÐœÐŸÐµ Ð.Ð°ÐŒÐž.)
++
++  4. Ð­Ñ.Ð° ÐºÐŸÐŒÐ°ÐœÐŽÐ° ÑÐŸÑ.Ñ.Ð°ÐœÐžÑ. Ð²ÐµÑÑ. Ñ.Ð°Ð¹Ð» (Ð£Ñ.ÐµÐ±ÐœÐžÐº Ð¿ÐŸ Vim) Ð¿ÐŸÐŽ ÐžÐŒÐµÐœÐµÐŒ TEST. Ð§Ñ.ÐŸÐ±Ñ.
++     Ñ.ÐŽÐŸÑÑ.ÐŸÐ²ÐµÑ.ÐžÑ.Ñ.ÑÑ Ð² ÑÑ.ÐŸÐŒ, ÑÐœÐŸÐ²Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :!dir Ðž Ð¿Ñ.ÐŸÑÐŒÐŸÑ.Ñ.ÐžÑ.Ðµ ÐºÐ°Ñ.Ð°Ð»ÐŸÐ³.
++
++---> Ð.Ð°ÐŒÐµÑ.Ñ.Ñ.Ðµ, Ñ.Ñ.ÐŸ ÐµÑÐ»Ðž Ð.Ñ. Ð²Ñ.Ð¹ÐŽÐµÑ.Ðµ ÐžÐ· Vim Ðž Ð·Ð°Ñ.ÐµÐŒ Ð·Ð°Ð¿Ñ.ÑÑ.ÐžÑ.Ðµ ÐµÐ³ÐŸ ÑÐœÐŸÐ²Ð° Ñ
++     Ñ.Ð°Ð¹Ð»ÐŸÐŒ TEST, ÑÑ.ÐŸÑ. Ñ.Ð°Ð¹Ð» Ð±Ñ.ÐŽÐµÑ. Ñ.ÐŸÑ.ÐœÐŸÐ¹ ÐºÐŸÐ¿ÐžÐµÐ¹ Ñ.Ñ.ÐµÐ±ÐœÐžÐºÐ° Ð² Ñ.ÐŸÑ. ÐŒÐŸÐŒÐµÐœÑ., ÐºÐŸÐ³ÐŽÐ°
++     Ð.Ñ. ÐµÐ³ÐŸ ÑÐŸÑ.Ñ.Ð°ÐœÐžÐ»Ðž.
++
++  5. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ñ.ÐŽÐ°Ð»ÐžÑ.Ðµ ÑÑ.ÐŸÑ. Ñ.Ð°Ð¹Ð», ÐœÐ°Ð±Ñ.Ð°Ð² :!del TEST
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		       Ð£Ñ.ÐŸÐº 5.3: Ð.Ð«Ð.Ð.Ð Ð.Ð§ÐÐ.Ð. Ð¡Ð.Ð¥Ð ÐÐÐ.ÐÐ.Ð.
++
++
++	 ** Ð.Ð»Ñ ÑÐŸÑ.Ñ.Ð°ÐœÐµÐœÐžÑ Ñ.Ð°ÑÑ.Ðž Ñ.Ð°Ð¹Ð»Ð°, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :#,# w Ð.Ð.Ð¯_Ð€ÐÐ.Ð.Ð **
++
++  1. Ð.Ñ.Ðµ Ñ.Ð°Ð· ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :!dir ÐžÐ»Ðž :!ls ÐŽÐ»Ñ Ð¿ÐŸÐ»Ñ.Ñ.ÐµÐœÐžÑ ÑÐ¿ÐžÑÐºÐ° Ñ.Ð°Ð¹Ð»ÐŸÐ² Ð² Ñ.ÐµÐºÑ.Ñ.ÐµÐŒ
++     ÐºÐ°Ñ.Ð°Ð»ÐŸÐ³Ðµ Ðž Ð²Ñ.Ð±ÐµÑ.ÐžÑ.Ðµ Ð¿ÐŸÐŽÑ.ÐŸÐŽÑÑ.ÐµÐµ ÐžÐŒÑ, ÐœÐ°Ð¿Ñ.ÐžÐŒÐµÑ. TEST.
++
++  2. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ðº ÐœÐ°Ñ.Ð°Ð»Ñ. ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.Ð°ÐœÐžÑ.Ñ. Ðž ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ Ctrl-g ÐŽÐ»Ñ ÐœÐ°Ñ.ÐŸÐ¶ÐŽÐµÐœÐžÑ
++     ÐœÐŸÐŒÐµÑ.Ð° ÑÑ.Ñ.ÐŸÐºÐžto. Ð.ÐÐ.Ð.Ð.ÐÐ.Ð¢Ð. Ð­Ð¢Ð.Ð¢ ÐÐ.Ð.Ð.Ð !
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.ÐµÑÑ. Ð² ÐºÐŸÐœÐµÑ. ÑÑ.Ñ.Ð°ÐœÐžÑ.Ñ. Ðž Ð²ÐœÐŸÐ²Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ Ctrl-g. Ð.ÐÐ.Ð.Ð.ÐÐ.Ð¢Ð.
++     Ð. Ð­Ð¢Ð.Ð¢ ÐÐ.Ð.Ð.Ð  Ð¢Ð.Ð.Ð.!
++
++  4. Ð.Ð»Ñ ÑÐŸÑ.Ñ.Ð°ÐœÐµÐœÐžÑ Ð¢Ð.Ð.Ð¬Ð.Ð. Ð§ÐÐ¡Ð¢Ð. Ñ.Ð°Ð¹Ð»Ð° ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :#,# w TEST , Ð³ÐŽÐµ #,# --- ÑÑ.ÐŸ
++     ÐœÐŸÐŒÐµÑ.Ð°, ÐºÐŸÑ.ÐŸÑ.Ñ.Ðµ Ð.Ñ. Ð·Ð°Ð¿ÐŸÐŒÐœÐžÐ»Ðž (ÐœÐ°Ñ.Ð°Ð»ÐŸ, ÐºÐŸÐœÐµÑ.), Ð° TEST --- ÐžÐŒÑ Ð²Ð°Ñ.ÐµÐ³ÐŸ Ñ.Ð°Ð¹Ð»Ð°.
++
++  5. Ð.Ð°Ðº Ðž Ð¿Ñ.ÐµÐ¶ÐŽÐµ, Ñ.Ð±ÐµÐŽÐžÑ.ÐµÑÑ. Ð² ÐœÐ°Ð»ÐžÑ.ÐžÐž ÑÑ.ÐŸÐ³ÐŸ Ñ.Ð°Ð¹Ð»Ð° ÐºÐŸÐŒÐ°ÐœÐŽÐŸÐ¹ :!dir , ÐœÐŸ ÐÐ.
++     Ð£Ð.ÐÐ.Ð¯Ð.Ð¢Ð. ÐµÐ³ÐŸ.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		    Ð£Ñ.ÐŸÐº 5.4: Ð§Ð¢Ð.ÐÐ.Ð. Ð. Ð.Ð.ÐªÐ.Ð.Ð.ÐÐ.ÐÐ.Ð. Ð€ÐÐ.Ð.Ð.Ð.
++
++	  ** Ð.Ð»Ñ Ð²ÑÑ.Ð°Ð²ÐºÐž ÑÐŸÐŽÐµÑ.Ð¶ÐžÐŒÐŸÐ³ÐŸ Ñ.Ð°Ð¹Ð»Ð°, ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ  :r FILENAME **
++
++  1. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ :!dir ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ñ.Ð±ÐµÐŽÐžÑ.Ñ.ÑÑ Ð² Ñ.ÐŸÐŒ, Ñ.Ñ.ÐŸ Ñ.Ð°Ð¹Ð» TEST Ð²ÑÐµ ÐµÑ.Ðµ
++     ÑÑ.Ñ.ÐµÑÑ.Ð²Ñ.ÐµÑ..
++
++  2. Ð£ÑÑ.Ð°ÐœÐŸÐ²ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð² Ð²ÐµÑ.Ñ.ÐœÐµÐ¹ Ñ.Ð°ÑÑ.Ðž ÑÑ.ÐŸÐ¹ ÑÑ.Ñ.Ð°ÐœÐžÑ.Ñ..
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.ÐŸÑÐ»Ðµ Ð²Ñ.Ð¿ÐŸÐ»ÐœÐµÐœÐžÑ Ñ.Ð°Ð³Ð° 3 Ð.Ñ. Ñ.Ð²ÐžÐŽÐžÑ.Ðµ Ð£Ñ.ÐŸÐº 5.3.	Ð.ÐŸÑÐ»Ðµ ÑÑ.ÐŸÐ³ÐŸ
++	   Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°Ð¹Ñ.ÐµÑÑ. Ð.ÐÐ.Ð., ÑÐœÐŸÐ²Ð° Ðº ÑÑ.ÐŸÐŒÑ. Ñ.Ñ.ÐŸÐºÑ..
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿Ñ.ÐŸÑ.ÐžÑ.Ð°Ð¹Ñ.Ðµ Ð.Ð°Ñ. Ñ.Ð°Ð¹Ð» TEST, ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ ÐºÐŸÐŒÐ°ÐœÐŽÑ. :r TEST , Ð³ÐŽÐµ
++     TEST --- ÑÑ.ÐŸ ÐžÐŒÑ Ñ.Ð°Ð¹Ð»Ð°.
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð.Ñ.ÐŸÑ.ÐžÑ.Ð°ÐœÐœÑ.Ð¹ Ð.Ð°ÐŒÐž Ñ.Ð°Ð¹Ð» Ð±Ñ.ÐŽÐµÑ. Ð²ÑÑ.Ð°Ð²Ð»ÐµÐœ Ð² Ñ.ÐŸÐŒ ÐŒÐµÑÑ.Ðµ, Ð³ÐŽÐµ ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ
++	   ÐºÑ.Ñ.ÑÐŸÑ..
++
++  4. Ð§Ñ.ÐŸÐ±Ñ. Ñ.Ð±ÐµÐŽÐžÑ.Ñ.ÑÑ Ð² Ñ.ÐŸÐŒ, Ñ.Ñ.ÐŸ Ñ.Ð°Ð¹Ð» Ð¿Ñ.ÐŸÑ.ÐžÑ.Ð°Ðœ, Ð¿ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.ÐµÑÑ. ÐœÐµÐŒÐœÐŸÐ³ÐŸ ÐœÐ°Ð·Ð°ÐŽ Ð¿ÐŸ
++     Ñ.ÐµÐºÑÑ.Ñ. Ðž Ð·Ð°ÐŒÐµÑ.Ñ.Ñ.Ðµ, Ñ.Ñ.ÐŸ Ñ.ÐµÐ¿ÐµÑ.Ñ. ÑÑ.Ñ.ÐµÑÑ.Ð²Ñ.Ñ.Ñ. ÐŽÐ²Ðµ ÐºÐŸÐ¿ÐžÐž Ð£Ñ.ÐŸÐºÐ° 5.3, ÐžÑÑ.ÐŸÐŽÐœÐ°Ñ
++     Ðž Ð¿ÐŸÐ»Ñ.Ñ.ÐµÐœÐœÐ°Ñ ÐžÐ· Ñ.Ð°Ð¹Ð»Ð°.
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 5
++
++
++  1.  :!ÐºÐŸÐŒÐ°ÐœÐŽÐ°  ÐžÑÐ¿ÐŸÐ»ÐœÑÐµÑ. Ð²ÐœÐµÑ.ÐœÑ.Ñ. ÐºÐŸÐŒÐ°ÐœÐŽÑ..
++
++      ÐÐµÐºÐŸÑ.ÐŸÑ.Ñ.Ðµ Ð¿ÐŸÐ»ÐµÐ·ÐœÑ.Ðµ Ð¿Ñ.ÐžÐŒÐµÑ.Ñ.:
++	  :!dir --- Ð²Ñ.Ð²ÐŸÐŽÐžÑ. ÑÐ¿ÐžÑÐŸÐº Ñ.Ð°Ð¹Ð»ÐŸÐ² Ð² ÐºÐ°Ñ.Ð°Ð»ÐŸÐ³Ðµ.
++	  :!del FILENAME --- Ñ.ÐŽÐ°Ð»ÑÐµÑ. Ñ.Ð°Ð¹Ð» FILENAME.
++
++  2.  :w FILENAME Ð·Ð°Ð¿ÐžÑÑ.Ð²Ð°ÐµÑ. Ñ.ÐµÐºÑ.Ñ.ÐžÐ¹ Ñ.ÐµÐŽÐ°ÐºÑ.ÐžÑ.Ñ.ÐµÐŒÑ.Ð¹ Ñ.Ð°Ð¹Ð» ÐœÐ° ÐŽÐžÑÐº
++      Ð¿ÐŸÐŽ ÐžÐŒÐµÐœÐµÐŒ FILENAME.
++
++  3.  :#,#w FILENAME ÑÐŸÑ.Ñ.Ð°ÐœÑÐµÑ. ÑÑ.Ñ.ÐŸÐºÐž ÐŸÑ. # ÐŽÐŸ # Ð² Ñ.Ð°Ð¹Ð» FILENAME.
++
++  4.  :r FILENAME ÑÑ.ÐžÑ.Ñ.Ð²Ð°ÐµÑ. Ñ ÐŽÐžÑÐºÐ° Ñ.Ð°Ð¹Ð» FILENAME Ðž Ð¿ÐŸÐŒÐµÑ.Ð°ÐµÑ. ÐµÐ³ÐŸ Ð² Ñ.ÐµÐºÑ.Ñ.ÐžÐ¹
++      Ñ.Ð°Ð¹Ð» ÑÐ»ÐµÐŽÐŸÐŒ Ð·Ð° Ð¿ÐŸÐ·ÐžÑ.ÐžÐµÐ¹ ÐºÑ.Ñ.ÑÐŸÑ.Ð°.
++
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			  Ð£Ñ.ÐŸÐº 6.1: Ð.Ð.Ð.ÐÐÐ.Ð Ð¡Ð.Ð.Ð.ÐÐÐ.Ð¯
++
++
++ ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ o Ñ.Ñ.ÐŸÐ±Ñ. ÑÐŸÐ·ÐŽÐ°Ñ.Ñ. Ð¿Ñ.ÑÑ.Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ Ðž Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ð² Ñ.ÐµÐ¶ÐžÐŒ
++			   Ð²ÑÑ.Ð°Ð²ÐºÐž (Insert mode) **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ o (Ð² ÐœÐžÐ¶ÐœÐµÐŒ Ñ.ÐµÐ³ÐžÑÑ.Ñ.Ðµ) ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. ÑÐŸÐ·ÐŽÐ°Ñ.Ñ. Ð¿Ñ.ÑÑ.Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ.
++     ÐÐ.Ð.Ð. ÐºÑ.Ñ.ÑÐŸÑ.Ð° Ðž Ð¿ÐµÑ.ÐµÐ¹Ñ.Ðž Ð² Ñ.ÐµÐ¶ÐžÐŒ Ð²ÑÑ.Ð°Ð²ÐºÐž (Insert mode).
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÑÐºÐŸÐ¿ÐžÑ.Ñ.Ð¹Ñ.Ðµ Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÑ.Ñ. ---> ÑÑ.Ñ.ÐŸÐºÑ. Ðž ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ <ESC> ÐŽÐ»Ñ Ð²Ñ.Ñ.ÐŸÐŽÐ° ÐžÐ·
++     Ñ.ÐµÐ¶ÐžÐŒÐ° Ð²ÑÑ.Ð°Ð²ÐºÐž.
++
++---> Ð.ÐŸÑÐ»Ðµ ÐœÐ°Ð¶Ð°Ñ.ÐžÑ o ÐºÑ.Ñ.ÑÐŸÑ. Ð¿ÐµÑ.ÐµÐ¹ÐŽÐµÑ. ÐœÐ° ÐœÐŸÐ²Ñ.Ñ. Ð¿Ñ.ÑÑ.Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. Ð² Ñ.ÐµÐ¶ÐžÐŒÐµ Ð²ÑÑ.Ð°Ð²ÐºÐž.
++
++  4. Ð.Ð»Ñ ÑÐŸÐ·ÐŽÐ°ÐœÐžÑ ÑÑ.Ñ.ÐŸÐºÐž Ð.Ð«ÐšÐ. ÐºÑ.Ñ.ÑÐŸÑ.Ð°, Ð¿Ñ.ÐŸÑÑ.ÐŸ ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÑ.Ñ. O, Ð²ÐŒÐµÑÑ.ÐŸ
++     ÑÑ.Ñ.ÐŸÑ.ÐœÐŸÐ¹ o. Ð.ÐŸÐ¿Ñ.ÐŸÐ±Ñ.Ð¹Ñ.Ðµ Ð¿Ñ.ÐŸÐŽÐµÐ»Ð°Ñ.Ñ. ÑÑ.ÐŸ Ñ ÐœÐžÐ¶ÐµÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐŸÐ¹.
++Ð¡ÐŸÐ·ÐŽÐ°Ð¹Ñ.Ðµ ÐœÐŸÐ²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. ÐœÐ°ÐŽ ÑÑ.ÐŸÐ¹, ÐœÐ°Ð¶Ð°Ð² Shift-O, Ð¿ÐŸÐŒÐµÑÑ.ÐžÐ² ÐºÑ.Ñ.ÑÐŸÑ. ÐœÐ° ÑÑ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ..
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			 Ð£Ñ.ÐŸÐº 6.2: Ð.Ð.Ð.ÐÐÐ.Ð Ð.Ð.Ð.ÐÐ.Ð.Ð.ÐÐ.Ð¯
++
++	    ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ a , Ñ.Ñ.ÐŸÐ±Ñ. Ð²ÑÑ.Ð°Ð²ÐžÑ.Ñ. Ñ.ÐµÐºÑÑ. Ð.Ð.Ð¡Ð.Ð. ÐºÑ.Ñ.ÑÐŸÑ.Ð°. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ð² ÐºÐŸÐœÐµÑ. Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐž, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ ---> ,
++     ÐœÐ°Ð±Ñ.Ð°Ð² $ Ð² ÐŸÐ±Ñ.Ñ.ÐœÐŸÐŒ Ñ.ÐµÐ¶ÐžÐŒÐµ (Normal mode).
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ a (Ð² ÐœÐžÐ¶ÐœÐµÐŒ Ñ.ÐµÐ³ÐžÑÑ.Ñ.Ðµ) ÐŽÐ»Ñ ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÐžÑ Ñ.ÐµÐºÑÑ.Ð° Ð.Ð.Ð¡Ð.Ð. ÑÐžÐŒÐ²ÐŸÐ»Ð°,
++     ÐœÐ°Ñ.ÐŸÐŽÑÑ.ÐµÐ³ÐŸÑÑ Ð¿ÐŸÐŽ ÐºÑ.Ñ.ÑÐŸÑ.ÐŸÐŒ. (Ð.Ð°Ð³Ð»Ð°Ð²ÐœÐ°Ñ A Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. ÐŽÐŸÐ±Ð°Ð²ÐžÑ.Ñ. Ð² ÐºÐŸÐœÐµÑ.
++     ÑÑ.Ñ.ÐŸÐºÐž.)
++
++Ð.Ð°ÐŒÐµÑ.Ð°ÐœÐžÐµ: Ð­Ñ.ÐŸ Ð¿ÐŸÐ·Ð²ÐŸÐ»ÑÐµÑ. ÐžÐ·Ð±ÐµÐ¶Ð°Ñ.Ñ. ÐœÐ°Ð¶Ð°Ñ.ÐžÑ i , Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ³ÐŸ ÑÐžÐŒÐ²ÐŸÐ»Ð°, Ñ.ÐµÐºÑÑ.Ð° ÐŽÐ»Ñ
++	   Ð²ÑÑ.Ð°Ð²ÐºÐž, <ESC>, ÐºÑ.Ñ.ÑÐŸÑ.-Ð²Ð¿Ñ.Ð°Ð²ÐŸ, Ðž, ÐœÐ°ÐºÐŸÐœÐµÑ., x , Ð¿Ñ.ÐŸÑÑ.ÐŸ ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ,
++	   Ñ.Ñ.ÐŸÐ±Ñ. ÐŽÐŸÐ±Ð°Ð²ÐžÑ.Ñ. Ñ.ÐµÑÑ. Ð² ÐºÐŸÐœÐµÑ. ÑÑ.Ñ.ÐŸÐºÐž!
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð·Ð°Ð²ÐµÑ.Ñ.ÐžÑ.Ðµ Ð¿ÐµÑ.Ð²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ.. Ð.Ð°ÐŒÐµÑ.Ñ.Ñ.Ðµ Ñ.Ð°ÐºÐ¶Ðµ, Ñ.Ñ.ÐŸ ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÐžÐµ ÑÑ.ÐŸ Ð²
++     Ñ.ÐŸÑ.ÐœÐŸÑÑ.Ðž Ñ.ÐŸ Ð¶Ðµ ÑÐ°ÐŒÐŸÐµ, Ñ.Ñ.ÐŸ Ðž Ñ.ÐµÐ¶ÐžÐŒ Ð²ÑÑ.Ð°Ð²ÐºÐž, Ð·Ð° ÐžÑÐºÐ»Ñ.Ñ.ÐµÐœÐžÐµÐŒ Ð¿ÐŸÐ·ÐžÑ.ÐžÐž, Ð²
++     ÐºÐŸÑ.ÐŸÑ.Ñ.Ñ. Ð±Ñ.ÐŽÐµÑ. Ð²ÑÑ.Ð°Ð²Ð»ÐµÐœ Ñ.ÐµÐºÑÑ..
++
++---> Ð­Ñ.Ð° ÑÑ.Ñ.ÐŸÑ.ÐºÐ° Ð¿ÐŸÐ·Ð²ÐŸÐ»ÐžÑ. Ð.Ð°ÐŒ Ð¿ÐŸÐ¿Ñ.Ð°ÐºÑ.ÐžÐºÐŸÐ²Ð°Ñ.Ñ.ÑÑ
++---> Ð­Ñ.Ð° ÑÑ.Ñ.ÐŸÑ.ÐºÐ° Ð¿ÐŸÐ·Ð²ÐŸÐ»ÐžÑ. Ð.Ð°ÐŒ Ð¿ÐŸÐ¿Ñ.Ð°ÐºÑ.ÐžÐºÐŸÐ²Ð°Ñ.Ñ.ÑÑ Ð² ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÐžÐž Ñ.ÐµÐºÑÑ.Ð° Ð² ÐºÐŸÐœÐµÑ.
++     ÑÑ.Ñ.ÐŸÐºÐž.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		       Ð£Ñ.ÐŸÐº 6.3: Ð.Ð©Ð. Ð.Ð.Ð.Ð Ð¡Ð.Ð.Ð¡Ð.Ð. Ð.ÐÐ.Ð.ÐÐ«
++
++
++       ** ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÑ.Ñ. R ÐŽÐ»Ñ Ð·Ð°ÐŒÐµÐœÑ. Ð±ÐŸÐ»ÐµÐµ, Ñ.ÐµÐŒ ÐŸÐŽÐœÐŸÐ³ÐŸ ÑÐžÐŒÐ²ÐŸÐ»Ð°. **
++
++  1. Ð.ÐµÑ.ÐµÐŒÐµÑÑ.ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð²ÐœÐžÐ·, Ðº ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ --->.
++
++  2. Ð Ð°ÑÐ¿ÐŸÐ»ÐŸÐ¶ÐžÑ.Ðµ ÐºÑ.Ñ.ÑÐŸÑ. Ð² ÐœÐ°Ñ.Ð°Ð»Ðµ Ð¿ÐµÑ.Ð²ÐŸÐ³ÐŸ ÑÐ»ÐŸÐ²Ð°, ÐŸÑ.Ð»ÐžÑ.Ð°Ñ.Ñ.ÐµÐ³ÐŸÑÑ ÐŸÑ.
++     ÑÐŸÐŸÑ.Ð²ÐµÑ.ÑÑ.Ð²Ñ.Ñ.Ñ.ÐµÐ³ÐŸ Ð² ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ, Ð¿ÐŸÐŒÐµÑ.ÐµÐœÐœÐŸÐ¹ ---> (ÑÐ»ÐŸÐ²ÐŸ 'Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ¹').
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ R Ðž Ð·Ð°ÐŒÐµÐœÐžÑ.Ðµ ÐŸÑÑ.Ð°Ñ.ÐŸÐº Ñ.ÐµÐºÑÑ.Ð° Ð² Ð¿ÐµÑ.Ð²ÐŸÐ¹ ÑÑ.Ñ.ÐŸÐºÐµ, ÐœÐ°Ð±Ñ.Ð°Ð²
++     Ð¿ÐŸÐ²ÐµÑ.Ñ. ÑÑ.Ð°Ñ.ÐŸÐ³ÐŸ Ñ.ÐµÐºÑÑ.Ð° Ñ.Ð°Ðº, Ñ.Ñ.ÐŸÐ±Ñ. ÐŸÐ±Ðµ ÑÑ.Ñ.ÐŸÐºÐž ÑÑ.Ð°Ð»Ðž ÐŸÐŽÐžÐœÐ°ÐºÐŸÐ²Ñ.ÐŒÐž.
++
++---> Ð.ÐµÑ.Ð²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. ÐŒÐŸÐ¶ÐœÐŸ ÑÑ.Ð°Ð²ÐœÑÑ.Ñ. Ñ Ð¿ÐŸÑÐ»ÐµÐŽÐœÐµÐ¹, ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ ÐºÐ»Ð°Ð²ÐžÑ.Ðž.
++---> Ð.ÐµÑ.Ð²Ñ.Ñ. ÑÑ.Ñ.ÐŸÐºÑ. ÐŒÐŸÐ¶ÐœÐŸ ÑÑ.Ð°Ð²ÐœÑÑ.Ñ. Ñ Ð²Ñ.ÐŸÑ.ÐŸÐ¹, ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ñ R Ðž ÐœÐ°Ð±Ñ.Ð°Ð² ÐœÐŸÐ²Ñ.Ð¹ Ñ.ÐµÐºÑÑ..
++
++  4. Ð.Ð±Ñ.Ð°Ñ.ÐžÑ.Ðµ Ð²ÐœÐžÐŒÐ°ÐœÐžÐµ, Ñ.Ñ.ÐŸ Ð¿Ñ.Ðž ÐœÐ°Ð¶Ð°Ñ.ÐžÐž <ESC> ÐŽÐ»Ñ Ð·Ð°Ð²ÐµÑ.Ñ.ÐµÐœÐžÑ, Ð»Ñ.Ð±ÐŸÐ¹
++     ÐœÐµ ÐžÐ·ÐŒÐµÐœÐµÐœÐœÑ.Ð¹ Ñ.ÐµÐºÑÑ. ÑÐŸÑ.Ñ.Ð°ÐœÐžÑ.ÑÑ.
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++			Ð£Ñ.ÐŸÐº 6.4: Ð£Ð¡Ð¢ÐÐÐ.Ð.Ð.Ð Ð.ÐÐ ÐÐ.Ð.Ð¢Ð Ð.Ð.
++
++
++** Ð£ÑÑ.Ð°ÐœÐŸÐ²ÐžÐŒ Ð¿Ð°Ñ.Ð°ÐŒÐµÑ.Ñ.Ñ. Ñ.Ð°Ðº, Ñ.Ñ.ÐŸÐ±Ñ. ÐžÐ³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ. Ñ.ÐµÐ³ÐžÑÑ.Ñ. Ð¿Ñ.Ðž Ð¿ÐŸÐžÑÐºÐµ ÐžÐ»Ðž Ð·Ð°ÐŒÐµÐœÐµ **
++
++
++  1. Ð.ÐŸÐžÑ.ÐžÑ.Ðµ ÑÐ»ÐŸÐ²ÐŸ 'ÐžÐ³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ.', ÐœÐ°Ð±Ñ.Ð°Ð²:
++     /ÐžÐ³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ.
++     Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ð¿ÐŸÐžÑÐº ÐœÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð·, ÐœÐ°Ð¶ÐžÐŒÐ°Ñ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. n
++
++  2. Ð.ÐºÐ»Ñ.Ñ.ÐžÑ.Ðµ Ð¿Ð°Ñ.Ð°ÐŒÐµÑ.Ñ. 'ic' (Ð.Ð³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ. Ñ.ÐµÐ³ÐžÑÑ.Ñ.), ÐœÐ°Ð±Ñ.Ð°Ð²:
++     :set ic
++
++  3. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÑÐœÐŸÐ²Ð° ÑÐŽÐµÐ»Ð°Ð¹Ñ.Ðµ Ð¿ÐŸÐžÑÐº ÑÐ»ÐŸÐ²Ð° 'ÐžÐ³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ.', ÐœÐ°Ð¶Ð°Ð²: n
++     Ð.ÐŸÐ²Ñ.ÐŸÑ.ÐžÑ.Ðµ Ð¿ÐŸÐžÑÐº ÐœÐµÑÐºÐŸÐ»Ñ.ÐºÐŸ Ñ.Ð°Ð·, ÐœÐ°Ð¶ÐžÐŒÐ°Ñ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. n
++
++  4. Ð.ÐºÐ»Ñ.Ñ.ÐžÑ.Ðµ Ð¿Ð°Ñ.Ð°ÐŒÐµÑ.Ñ.Ñ. 'hlsearch' Ðž 'incsearch':
++     :set hls is
++
++  5. Ð¢ÐµÐ¿ÐµÑ.Ñ. ÐŸÐ¿ÑÑ.Ñ. Ð²Ð²ÐµÐŽÐžÑ.Ðµ ÐºÐŸÐŒÐ°ÐœÐŽÑ. Ð¿ÐŸÐžÑÐºÐ° Ðž Ð¿ÐŸÑÐŒÐŸÑ.Ñ.ÐžÑ.Ðµ, Ñ.Ñ.ÐŸ Ð¿ÐŸÐ»Ñ.Ñ.ÐžÑ.ÑÑ:
++     /ÐžÐ³ÐœÐŸÑ.ÐžÑ.ÐŸÐ²Ð°Ñ.Ñ.
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++				Ð Ð.Ð.Ð®Ð.Ð. Ð£Ð Ð.Ð.Ð 6
++
++
++  1. ÐÐ°Ð¶Ð°Ñ.ÐžÐµ o ÑÐŸÐ·ÐŽÐ°ÐµÑ. ÑÑ.Ñ.ÐŸÐºÑ. ÐÐ.Ð.Ð. ÐºÑ.Ñ.ÑÐŸÑ.Ð° Ðž Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ. ÐºÑ.Ñ.ÑÐŸÑ. Ð² ÐœÐµÐµ Ð² Ñ.ÐµÐ¶ÐžÐŒÐµ
++     Ð²ÑÑ.Ð°Ð²ÐºÐž.
++     ÐÐ°Ð¶Ð°Ñ.ÐžÐµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÐŸÐ¹ O ÑÐŸÐ·ÐŽÐ°ÐµÑ. ÑÑ.Ñ.ÐŸÐºÑ. Ð.Ð«ÐšÐ. ÑÑ.Ñ.ÐŸÐºÐž, Ð² ÐºÐŸÑ.ÐŸÑ.ÐŸÐ¹ ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ
++     ÐºÑ.Ñ.ÑÐŸÑ..
++
++  2. ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ a ÐŽÐ»Ñ Ð²ÑÑ.Ð°Ð²ÐºÐž Ñ.ÐµÐºÑÑ.Ð° Ð.Ð.Ð¡Ð.Ð. ÑÐžÐŒÐ²ÐŸÐ»Ð°, ÐœÐ° ÐºÐŸÑ.ÐŸÑ.ÐŸÐŒ ÐœÐ°Ñ.ÐŸÐŽÐžÑ.ÑÑ ÐºÑ.Ñ.ÑÐŸÑ..
++     ÐÐ°Ð¶Ð°Ñ.ÐžÐµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÐŸÐ¹ A Ð°Ð²Ñ.ÐŸÐŒÐ°Ñ.ÐžÑ.ÐµÑÐºÐž Ð¿ÐµÑ.ÐµÐŒÐµÑ.Ð°ÐµÑ. Ð.Ð°Ñ ÐŽÐ»Ñ ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÐžÑ Ñ.ÐµÐºÑÑ.Ð°
++     Ð² ÐºÐŸÐœÐµÑ. ÑÑ.Ñ.ÐŸÐºÐž.
++
++  3. ÐÐ°Ð¶Ð°Ñ.ÐžÐµ Ð·Ð°Ð³Ð»Ð°Ð²ÐœÐŸÐ¹ R Ð¿ÐµÑ.ÐµÐ²ÐŸÐŽÐžÑ. Ð.Ð°Ñ Ð² Ñ.ÐµÐ¶ÐžÐŒ Ð·Ð°ÐŒÐµÐœÑ. ÐŽÐŸ Ñ.ÐµÑ. Ð¿ÐŸÑ., Ð¿ÐŸÐºÐ° ÐœÐµ
++     Ð±Ñ.ÐŽÐµÑ. ÐœÐ°Ð¶Ð°Ñ.Ð° ÐºÐ»Ð°Ð²ÐžÑ.Ð° <ESC> ÐŽÐ»Ñ Ð·Ð°Ð²ÐµÑ.Ñ.ÐµÐœÐžÑ.
++
++  4. ÐÐ°Ð±Ñ.Ð°Ð² ":set xxx" Ð²Ñ. ÑÐŒÐŸÐ¶ÐµÑ.Ðµ Ð²ÐºÐ»Ñ.Ñ.ÐžÑ.Ñ. Ð¿Ð°Ñ.Ð°ÐŒÐµÑ.Ñ. "xxx"
++
++
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		 Ð£Ñ.ÐŸÐº 7: Ð.Ð.Ð.ÐÐÐ.Ð« Ð.Ð.Ð.Ð£Ð§Ð.ÐÐ.Ð¯ Ð.Ð¡Ð¢Ð Ð.Ð.ÐÐÐ.Ð. Ð¡Ð.Ð ÐÐ.Ð.Ð.
++
++	       ** Ð.ÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.Ð¹Ñ.Ðµ Ð²ÑÑ.Ñ.ÐŸÐµÐœÐœÑ.Ñ. ÑÐ¿Ñ.Ð°Ð²ÐŸÑ.ÐœÑ.Ñ. ÑÐžÑÑ.ÐµÐŒÑ. **
++
++  Vim ÐŸÐ±Ð»Ð°ÐŽÐ°ÐµÑ. ÐŒÐŸÑ.ÐœÐŸÐ¹ Ð²ÑÑ.Ñ.ÐŸÐµÐœÐœÐŸÐ¹ ÑÐ¿Ñ.Ð°Ð²ÐŸÑ.ÐœÐŸÐ¹ ÑÐžÑÑ.ÐµÐŒÐŸÐ¹. Ð.Ð»Ñ ÐœÐ°Ñ.Ð°Ð»Ð° Ð¿ÐŸÐ¿Ñ.ÐŸÐ±Ñ.Ð¹Ñ.Ðµ
++  ÐŸÐŽÐžÐœ ÐžÐ· Ñ.Ñ.ÐµÑ. Ð²Ð°Ñ.ÐžÐ°ÐœÑ.ÐŸÐ²:
++	- ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. <HELP> (ÐµÑÐ»Ðž Ñ.Ð°ÐºÐŸÐ²Ð°Ñ ÐžÐŒÐµÐµÑ.ÑÑ ÐœÐ° ÐºÐ»Ð°Ð²ÐžÐ°Ñ.Ñ.Ñ.Ðµ)
++	- ÐœÐ°Ð¶ÐŒÐžÑ.Ðµ ÐºÐ»Ð°Ð²ÐžÑ.Ñ. <F1> (ÐµÑÐ»Ðž Ñ.Ð°ÐºÐŸÐ²Ð°Ñ ÐžÐŒÐµÐµÑ.ÑÑ ÐœÐ° ÐºÐ»Ð°Ð²ÐžÐ°Ñ.Ñ.Ñ.Ðµ)
++	- ÐœÐ°Ð±ÐµÑ.ÐžÑ.Ðµ   :help <ENTER>
++
++  ÐÐ°Ð±ÐµÑ.ÐžÑ.Ðµ   :q <ENTER>   Ñ.Ñ.ÐŸÐ±Ñ. Ð·Ð°ÐºÑ.Ñ.Ñ.Ñ. ÐŸÐºÐœÐŸ ÑÐ¿Ñ.Ð°Ð²ÐºÐž.
++
++  Ð.Ñ. ÐŒÐŸÐ¶ÐµÑ.Ðµ ÐœÐ°Ð¹Ñ.Ðž ÑÐ¿Ñ.Ð°Ð²ÐºÑ. ÐŽÐ»Ñ Ð»Ñ.Ð±ÐŸÐ³ÐŸ Ð¿ÐŸÐœÑÑ.ÐžÑ ÐžÐ»Ðž ÐºÐŸÐŒÐ°ÐœÐŽÑ., Ð¿Ñ.ÐŸÑÑ.ÐŸ Ð·Ð°ÐŽÐ°Ð²
++  ÑÐŸÐŸÑ.Ð²ÐµÑ.ÑÑ.Ð²Ñ.Ñ.Ñ.ÐžÐ¹ Ð°Ñ.Ð³Ñ.ÐŒÐµÐœÑ. ÐºÐŸÐŒÐ°ÐœÐŽÐµ ":help". Ð.ÐŸÐ¿Ñ.ÐŸÐ±Ñ.Ð¹Ñ.Ðµ ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐµ (ÐœÐµ Ð·Ð°Ð±Ñ.ÐŽÑ.Ñ.Ðµ
++  ÐœÐ°Ð¶Ð°Ñ.Ñ. <ENTER>):
++
++  :help w
++  :help c_<T
++  :help insert-index
++
++
++
++
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++		     Ð£Ñ.ÐŸÐº 8: Ð¡Ð.Ð.Ð.ÐÐÐ.Ð. Ð¡Ð¢ÐÐ Ð¢Ð.Ð.Ð.Ð.Ð. Ð¡Ð.Ð Ð.Ð.Ð¢Ð
++
++			** Ð.ÐºÐ»Ñ.Ñ.ÐžÐŒ Ð²ÐŸÐ·ÐŒÐŸÐ¶ÐœÐŸÑÑ.Ðž Vim **
++
++  Vim ÐžÐŒÐµÐµÑ. ÐœÐ°ÐŒÐœÐŸÐ³ÐŸ Ð±ÐŸÐ»Ñ.Ñ.Ðµ Ð²ÐŸÐ·ÐŒÐŸÐ¶ÐœÐŸÑÑ.ÐµÐ¹, Ñ.ÐµÐŒ Vi, ÐŸÐŽÐœÐ°ÐºÐŸ Ð±ÐŸÐ»Ñ.Ñ.ÐžÐœÑÑ.Ð²Ð°ÐŸ ÐžÐ· ÐœÐžÑ.
++  Ð²Ñ.ÐºÐ»Ñ.Ñ.ÐµÐœÑ. Ð¿ÐŸ Ñ.ÐŒÐŸÐ»Ñ.Ð°ÐœÐžÑ.. Ð.Ð»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. ÐœÐ°Ñ.Ð°Ñ.Ñ. ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.Ñ. ÐœÐŸÐ²Ñ.Ðµ
++  Ð²ÐŸÐ·ÐŒÐŸÐ¶ÐœÐŸÑÑ.Ðž Ð.Ð°ÐŒ ÑÐ»ÐµÐŽÑ.ÐµÑ. ÑÐŸÐ·ÐŽÐ°Ñ.Ñ. Ñ.Ð°Ð¹Ð» "vimrc".
++
++  1. Ð.Ñ.Ñ.ÐµÐŽÐ°ÐºÑ.ÐžÑ.Ñ.Ð¹Ñ.Ðµ Ñ.Ð°Ð¹Ð» "vimrc", ÐµÐ³ÐŸ Ñ.Ð°ÑÐ¿ÐŸÐ»ÐŸÐ¶ÐµÐœÐžÐµ Ð·Ð°Ð²ÐžÑÐžÑ. ÐŸÑ. ÐžÑÐ¿ÐŸÐ»Ñ.Ð·Ñ.ÐµÐŒÐŸÐ¹
++     ÑÐžÑÑ.ÐµÐŒÑ.:
++
++       :edit ~/.vimrc			ÐŽÐ»Ñ Unix
++       :edit $VIM/_vimrc		ÐŽÐ»Ñ MS-Windows
++
++  2. Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿Ñ.ÐŸÑ.ÐžÑ.Ð°Ð¹Ñ.Ðµ Ð¿Ñ.ÐžÐŒÐµÑ. Ñ.Ð°Ð¹Ð»Ð° "vimrc":
++
++       :read $VIMRUNTIME/vimrc_example.vim
++
++  3. Ð.Ð°Ð¿ÐžÑ.ÐžÑ.Ðµ Ñ.Ð°Ð¹Ð»:
++
++       :write
++
++  Ð¢ÐµÐ¿ÐµÑ.Ñ. Ð¿Ñ.Ðž ÑÐ»ÐµÐŽÑ.Ñ.Ñ.ÐµÐŒ Ð·Ð°Ð¿Ñ.ÑÐºÐµ Vim Ð±Ñ.ÐŽÐµÑ. Ð²ÐºÐ»Ñ.Ñ.ÐµÐœÐ° Ð¿ÐŸÐŽÑÐ²ÐµÑ.ÐºÐ° ÑÐžÐœÑ.Ð°ÐºÑÐžÑÐ°. Ð.ÑÐµ
++  ÐœÐ°ÑÑ.Ñ.ÐŸÐ¹ÐºÐž, Ð¿Ñ.ÐµÐŽÐ¿ÐŸÑ.ÐžÑ.Ð°ÐµÐŒÑ.Ðµ Ð.Ð°ÐŒÐž, ÐŒÐŸÐ³Ñ.Ñ. Ð±Ñ.Ñ.Ñ. ÐŽÐŸÐ±Ð°Ð²Ð»ÐµÐœÑ. Ð² Ñ.Ð°Ð¹Ð» "vimrc".
++
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++  ÐÐ° ÑÑ.ÐŸÐŒ Ð·Ð°Ð²ÐµÑ.Ñ.Ð°ÐµÑ.ÑÑ Ð£Ñ.ÐµÐ±ÐœÐžÐº Vim. Ð.Ðœ Ð±Ñ.Ð» Ð¿Ñ.ÐµÐŽÐœÐ°Ð·ÐœÐ°Ñ.ÐµÐœ ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. ÐŽÐ°Ñ.Ñ.
++  ÐŸÐ±Ñ.ÐµÐµ Ð¿Ñ.ÐµÐŽÑÑ.Ð°Ð²Ð»ÐµÐœÐžÐµ ÐŸ Ñ.ÐµÐŽÐ°ÐºÑ.ÐŸÑ.Ðµ Vim, ÐŽÐŸÑÑ.Ð°Ñ.ÐŸÑ.ÐœÐŸÐµ ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ñ Ð»ÐµÐ³ÐºÐŸÑÑ.Ñ.Ñ.
++  ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.Ñ. ÐµÐ³ÐŸ. Ð£Ñ.ÐµÐ±ÐœÐžÐº ÐŽÐ°Ð»ÐµÐº ÐŸÑ. Ð¿ÐŸÐ»ÐœÐŸÑ.Ñ., Ð¿ÐŸÑÐºÐŸÐ»Ñ.ÐºÑ. Vim ÐžÐŒÐµÐµÑ. ÐŸÑ.ÐµÐœÑ. ÐŒÐœÐŸÐ³ÐŸ
++  ÐºÐŸÐŒÐ°ÐœÐŽ. Ð.Ñ.ÐŸÑ.ÐžÑ.Ð°Ð¹Ñ.Ðµ Ñ.ÐµÐ¿ÐµÑ.Ñ. Ñ.Ñ.ÐºÐŸÐ²ÐŸÐŽÑÑ.Ð²ÐŸ Ð¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°Ñ.ÐµÐ»Ñ: ":help user-manual".
++
++  Ð.Ð»Ñ ÐŽÐ°Ð»Ñ.ÐœÐµÐ¹Ñ.ÐµÐ³ÐŸ Ñ.Ñ.ÐµÐœÐžÑ Ñ.ÐµÐºÐŸÐŒÐµÐœÐŽÑ.ÐµÑ.ÑÑ ÐºÐœÐžÐ³Ð°:
++	Vim - Vi Improved - ÐÐ²Ñ.ÐŸÑ.: Steve Oualline
++	Ð.Ð·ÐŽÐ°Ñ.ÐµÐ»Ñ.: New Riders
++  Ð­Ñ.Ð° ÐºÐœÐžÐ³Ð° Ð¿ÐŸÐ»ÐœÐŸÑÑ.Ñ.Ñ. Ð¿ÐŸÑÐ²ÑÑ.ÐµÐœÐ° Vim. Ð.ÑÐŸÐ±ÐµÐœÐœÐŸ Ð¿ÐŸÐ»ÐµÐ·ÐœÐ° ÐœÐŸÐ²ÐžÑ.ÐºÐ°ÐŒ. Ð¡ÐŸÐŽÐµÑ.Ð¶ÐžÑ.
++  ÐŒÐœÐŸÐ¶ÐµÑÑ.Ð²ÐŸ Ð¿Ñ.ÐžÐŒÐµÑ.ÐŸÐ² Ðž ÐžÐ»Ð»Ñ.ÑÑ.Ñ.Ð°Ñ.ÐžÐ¹.
++  Ð.Ð·Ð³Ð»ÑÐœÐžÑ.Ðµ ÐœÐ° See http://iccf-holland.org/click5.html
++
++  Ð¡Ð»ÐµÐŽÑ.Ñ.Ñ.Ð°Ñ ÐºÐœÐžÐ³Ð° Ð±ÐŸÐ»ÐµÐµ Ð¿ÐŸÑ.Ñ.ÐµÐœÐœÐŸÐ³ÐŸ Ð²ÐŸÐ·Ñ.Ð°ÑÑ.Ð° Ðž Ð¿ÐŸÑÐ²ÑÑ.ÐµÐœÐ° Ð±ÐŸÐ»Ñ.Ñ.Ðµ Vi, Ñ.ÐµÐŒ Vim,
++  ÐŸÐŽÐœÐ°ÐºÐŸ Ñ.Ð°ÐºÐ¶Ðµ Ñ.ÐµÐºÐŸÐŒÐµÐœÐŽÑ.ÐµÑ.ÑÑ:
++	Learning the Vi Editor - ÐÐ²Ñ.ÐŸÑ.: Linda Lamb
++	Ð.Ð·ÐŽÐ°Ñ.ÐµÐ»Ñ.: O'Reilly & Associates Inc.
++  Ð­Ñ.ÐŸ Ñ.ÐŸÑ.ÐŸÑ.Ð°Ñ ÐºÐœÐžÐ³Ð° ÐŽÐ»Ñ Ñ.ÐŸÐ³ÐŸ, Ñ.Ñ.ÐŸÐ±Ñ. Ñ.Ð·ÐœÐ°Ñ.Ñ. Ð²ÑÐµ, Ñ.Ñ.ÐŸ Ñ.ÐŸÐ»Ñ.ÐºÐŸ ÐŒÐŸÐ¶ÐœÐŸ Ð¿Ñ.ÐŸÐŽÐµÐ»Ñ.Ð²Ð°Ñ.Ñ. Ñ
++  Vi. ÐšÐµÑÑ.ÐŸÐµ ÐžÐ·ÐŽÐ°ÐœÐžÐµ Ñ.Ð°ÐºÐ¶Ðµ Ð²ÐºÐ»Ñ.Ñ.Ð°ÐµÑ. ÐžÐœÑ.ÐŸÑ.ÐŒÐ°Ñ.ÐžÑ. ÐŸ Vim.
++
++  Ð­Ñ.ÐŸÑ. Ñ.Ñ.ÐµÐ±ÐœÐžÐº Ð±Ñ.Ð» ÐœÐ°Ð¿ÐžÑÐ°Ðœ Michael C. Pierce Ðž Robert K. Ware, Colorado School
++  of Mines Ñ ÐžÑÐ¿ÐŸÐ»Ñ.Ð·ÐŸÐ²Ð°ÐœÐžÐµÐŒ ÐžÐŽÐµÐ¹, Ð¿Ñ.ÐµÐŽÐ»ÐŸÐ¶ÐµÐœÐœÑ.Ñ. Charles Smith, Colorado State
++  University. E-mail: bware@mines.colorado.edu.
++
++  Ð.ÐŸÑ.Ð°Ð±ÐŸÑ.Ð°ÐœÐŸ ÐŽÐ»Ñ Vim Bram Moolenaar.
++
++  Ð.ÐµÑ.ÐµÐ²ÐŸÐŽ: ÐÐœÐŽÑ.ÐµÐ¹ Ð.ÐžÑÐµÐ»ÐµÐ² <a_kissel@eudoramail.com>, 2002.
++  Translator: Andrey Kiselev <a_kissel@eudoramail.com>, 2002.
++~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+diff -Naur vim70.orig/runtime/tutor/tutor.vim vim70/runtime/tutor/tutor.vim
+--- vim70.orig/runtime/tutor/tutor.vim	2006-03-18 12:20:36.000000000 -0800
++++ vim70/runtime/tutor/tutor.vim	2006-09-11 09:26:16.000000000 -0700
+@@ -1,6 +1,6 @@
+ " Vim tutor support file
+ " Author: Eduardo F. Amatria <eferna1@platea.pntic.mec.es>
+-" Last Change:	2006 Mar 18
++" Last Change:	2006 Sep 09
+ 
+ " This small source file is used for detecting if a translation of the
+ " tutor file exist, i.e., a tutor.xx file, where xx is the language.
+@@ -93,9 +93,16 @@
+   endif
+ endif
+ 
+-" The Greek tutor is available in two encodings, guess which one to use
+-if s:ext =~? '\.gr' && &enc =~ 737
+-  let s:ext = ".gr.cp737"
++" The Greek tutor is available in three encodings, guess what to use.
++" We used ".gr" (Greece) instead of ".el" (Greek); accept both.
++if s:ext =~? '\.gr\|\.el'
++  if &enc == "iso-8859-7"
++    let s:ext = ".gr"
++  elseif &enc == "utf-8"
++    let s:ext = ".gr.utf-8"
++  elseif &enc =~ 737
++    let s:ext = ".gr.cp737"
++  endif
+ endif
+ 
+ " The Slovak tutor is available in two encodings, guess which one to use
+@@ -103,11 +110,15 @@
+   let s:ext = ".sk.cp1250"
+ endif
+ 
+-" The Russian tutor is available in two encodings, guess which one to use.
+-" This segment is from the above lines and modified by
+-" Alexey I. Froloff <raorn@altlinux.org> for Russian vim tutorial
+-if s:ext =~? '\.ru' && &enc =~ 1251
+-  let s:ext = ".ru.cp1251"
++" The Russian tutor is available in three encodings, guess which one to use.
++if s:ext =~? '\.ru'
++  if &enc == 'utf-8'
++    let s:ext = '.ru.utf-8'
++  elseif &enc =~ '1251'
++    let s:ext = '.ru.cp1251'
++  elseif &enc =~ 'koi8'
++    let s:ext = '.ru'
++  endif
+ endif
+ 
+ " Somehow ".ge" (Germany) is sometimes used for ".de" (Deutsch).
+diff -Naur vim70.orig/src/auto/configure vim70/src/auto/configure
+--- vim70.orig/src/auto/configure	2006-05-04 03:46:19.000000000 -0700
++++ vim70/src/auto/configure	2006-09-11 09:02:36.000000000 -0700
+@@ -4014,7 +4014,7 @@
+       LDFLAGS=$ldflags_save
+       if test $perl_ok = yes; then
+ 	if test "X$perlcppflags" != "X"; then
+-	  PERL_CFLAGS="$perlcppflags"
++	  	  PERL_CFLAGS=`echo "$perlcppflags" | sed 's/-pipe //'`
+ 	fi
+ 	if test "X$perlldflags" != "X"; then
+ 	  LDFLAGS="$perlldflags $LDFLAGS"
+diff -Naur vim70.orig/src/buffer.c vim70/src/buffer.c
+--- vim70.orig/src/buffer.c	2006-04-26 14:37:23.000000000 -0700
++++ vim70/src/buffer.c	2006-09-11 09:04:57.000000000 -0700
+@@ -434,12 +434,8 @@
+     if (usingNetbeans)
+ 	netbeans_file_closed(buf);
+ #endif
+-#ifdef FEAT_AUTOCHDIR
+-    /* Change directories when the acd option is set on. */
+-    if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	shorten_fnames(TRUE);
+-#endif
++    /* Change directories when the 'acd' option is set. */
++    DO_AUTOCHDIR
+ 
+     /*
+      * Remove the buffer from the list.
+@@ -1390,7 +1386,8 @@
+     }
+     else
+     {
+-	need_fileinfo = TRUE;		/* display file info after redraw */
++	if (!msg_silent)
++	    need_fileinfo = TRUE;	/* display file info after redraw */
+ 	(void)buf_check_timestamp(curbuf, FALSE); /* check if file changed */
+ #ifdef FEAT_AUTOCMD
+ 	curwin->w_topline = 1;
+@@ -1422,12 +1419,8 @@
+ 	netbeans_file_activated(curbuf);
+ #endif
+ 
+-#ifdef FEAT_AUTOCHDIR
+-    /* Change directories when the acd option is set on. */
+-    if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	shorten_fnames(TRUE);
+-#endif
++    /* Change directories when the 'acd' option is set. */
++    DO_AUTOCHDIR
+ 
+ #ifdef FEAT_KEYMAP
+     if (curbuf->b_kmap_state & KEYMAP_INIT)
+@@ -1436,6 +1429,18 @@
+     redraw_later(NOT_VALID);
+ }
+ 
++#if defined(FEAT_AUTOCHDIR) || defined(PROTO)
++/*
++ * Change to the directory of the current buffer.
++ */
++    void
++do_autochdir()
++{
++    if (curbuf->b_ffname != NULL && vim_chdirfile(curbuf->b_ffname) == OK)
++	shorten_fnames(TRUE);
++}
++#endif
++
+ /*
+  * functions for dealing with the buffer list
+  */
+@@ -3324,7 +3329,7 @@
+     {
+ 	usefmt = eval_to_string_safe(fmt + 2, NULL, use_sandbox);
+ 	if (usefmt == NULL)
+-	    usefmt = (char_u *)"";
++	    usefmt = fmt;
+     }
+ #endif
+ 
+@@ -5420,11 +5425,7 @@
+     buf_T	*newbuf;
+     int		differ = TRUE;
+     linenr_T	lnum;
+-#ifdef FEAT_AUTOCMD
+     aco_save_T	aco;
+-#else
+-    buf_T	*old_curbuf = curbuf;
+-#endif
+     exarg_T	ea;
+ 
+     /* Allocate a buffer without putting it in the buffer list. */
+@@ -5439,13 +5440,8 @@
+ 	return TRUE;
+     }
+ 
+-#ifdef FEAT_AUTOCMD
+     /* set curwin/curbuf to buf and save a few things */
+     aucmd_prepbuf(&aco, newbuf);
+-#else
+-    curbuf = newbuf;
+-    curwin->w_buffer = newbuf;
+-#endif
+ 
+     if (ml_open(curbuf) == OK
+ 	    && readfile(buf->b_ffname, buf->b_fname,
+@@ -5466,13 +5462,8 @@
+     }
+     vim_free(ea.cmd);
+ 
+-#ifdef FEAT_AUTOCMD
+     /* restore curwin/curbuf and a few other things */
+     aucmd_restbuf(&aco);
+-#else
+-    curbuf = old_curbuf;
+-    curwin->w_buffer = old_curbuf;
+-#endif
+ 
+     if (curbuf != newbuf)	/* safety check */
+ 	wipe_buffer(newbuf, FALSE);
+diff -Naur vim70.orig/src/configure vim70/src/configure
+--- vim70.orig/src/configure	2006-05-07 07:17:49.000000000 -0700
++++ vim70/src/configure	2006-08-09 08:37:06.000000000 -0700
+@@ -2,5 +2,9 @@
+ # run the automatically generated configure script
+ CONFIG_STATUS=auto/config.status \
+ 	auto/configure "$@" --srcdir="${srcdir:-.}" --cache-file=auto/config.cache
++result=$?
++
+ # Stupid autoconf 2.5x causes this file to be left behind.
+ if test -f configure.lineno; then rm -f configure.lineno; fi
++
++exit $result
+diff -Naur vim70.orig/src/configure.in vim70/src/configure.in
+--- vim70.orig/src/configure.in	2006-05-04 03:46:11.000000000 -0700
++++ vim70/src/configure.in	2006-09-11 09:02:36.000000000 -0700
+@@ -508,7 +508,8 @@
+       LDFLAGS=$ldflags_save
+       if test $perl_ok = yes; then
+ 	if test "X$perlcppflags" != "X"; then
+-	  PERL_CFLAGS="$perlcppflags"
++	  dnl remove -pipe, it confuses cproto
++	  PERL_CFLAGS=`echo "$perlcppflags" | sed 's/-pipe //'`
+ 	fi
+ 	if test "X$perlldflags" != "X"; then
+ 	  LDFLAGS="$perlldflags $LDFLAGS"
+diff -Naur vim70.orig/src/edit.c vim70/src/edit.c
+--- vim70.orig/src/edit.c	2006-05-07 04:48:51.000000000 -0700
++++ vim70/src/edit.c	2006-09-11 08:30:17.000000000 -0700
+@@ -129,7 +129,7 @@
+ 
+ static void ins_ctrl_x __ARGS((void));
+ static int  has_compl_option __ARGS((int dict_opt));
+-static int ins_compl_add __ARGS((char_u *str, int len, int icase, char_u *fname, char_u **cptext, int cdir, int flags, int dup));
++static int ins_compl_add __ARGS((char_u *str, int len, int icase, char_u *fname, char_u **cptext, int cdir, int flags, int adup));
+ static int  ins_compl_equal __ARGS((compl_T *match, char_u *str, int len));
+ static void ins_compl_longest_match __ARGS((compl_T *match));
+ static void ins_compl_add_matches __ARGS((int num_matches, char_u **matches, int icase));
+@@ -719,9 +719,14 @@
+ #ifdef FEAT_INS_EXPAND
+ 	/*
+ 	 * Special handling of keys while the popup menu is visible or wanted
+-	 * and the cursor is still in the completed word.
++	 * and the cursor is still in the completed word.  Only when there is
++	 * a match, skip this when no matches were found.
+ 	 */
+-	if (compl_started && pum_wanted() && curwin->w_cursor.col >= compl_col)
++	if (compl_started
++		&& pum_wanted()
++		&& curwin->w_cursor.col >= compl_col
++		&& (compl_shown_match == NULL
++		    || compl_shown_match != compl_shown_match->cp_next))
+ 	{
+ 	    /* BS: Delete one character from "compl_leader". */
+ 	    if ((c == K_BS || c == Ctrl_H)
+@@ -751,7 +756,7 @@
+ 		    continue;
+ 		}
+ 
+-		/* Pressing CTRL-Y selects the current match.  Shen
++		/* Pressing CTRL-Y selects the current match.  When
+ 		 * compl_enter_selects is set the Enter key does the same. */
+ 		if (c == Ctrl_Y || (compl_enter_selects
+ 				   && (c == CAR || c == K_KENTER || c == NL)))
+@@ -877,6 +882,7 @@
+ 		/* Close the cmdline window. */
+ 		cmdwin_result = K_IGNORE;
+ 		got_int = FALSE; /* don't stop executing autocommands et al. */
++		nomove = TRUE;
+ 		goto doESCkey;
+ 	    }
+ #endif
+@@ -2112,7 +2118,7 @@
+  * maybe because alloc() returns NULL, then FAIL is returned.
+  */
+     static int
+-ins_compl_add(str, len, icase, fname, cptext, cdir, flags, dup)
++ins_compl_add(str, len, icase, fname, cptext, cdir, flags, adup)
+     char_u	*str;
+     int		len;
+     int		icase;
+@@ -2120,7 +2126,7 @@
+     char_u	**cptext;   /* extra text for popup menu or NULL */
+     int		cdir;
+     int		flags;
+-    int		dup;	    /* accept duplicate match */
++    int		adup;	    /* accept duplicate match */
+ {
+     compl_T	*match;
+     int		dir = (cdir == 0 ? compl_direction : cdir);
+@@ -2134,7 +2140,7 @@
+     /*
+      * If the same match is already present, don't add it.
+      */
+-    if (compl_first_match != NULL && !dup)
++    if (compl_first_match != NULL && !adup)
+     {
+ 	match = compl_first_match;
+ 	do
+@@ -2399,7 +2405,7 @@
+     /* compl_pattern doesn't need to be set */
+     compl_orig_text = vim_strnsave(ml_get_curline() + compl_col, compl_length);
+     if (compl_orig_text == NULL || ins_compl_add(compl_orig_text,
+-			-1, FALSE, NULL, NULL, 0, ORIGINAL_TEXT, FALSE) != OK)
++			-1, p_ic, NULL, NULL, 0, ORIGINAL_TEXT, FALSE) != OK)
+ 	return;
+ 
+     /* Handle like dictionary completion. */
+@@ -2409,6 +2415,7 @@
+     compl_matches = ins_compl_make_cyclic();
+     compl_started = TRUE;
+     compl_used_match = TRUE;
++    compl_cont_status = 0;
+ 
+     compl_curr_match = compl_first_match;
+     ins_complete(Ctrl_N);
+@@ -2753,6 +2760,7 @@
+ 	}
+ 	else
+ # endif
++	    if (count > 0)	/* avoid warning for using "files" uninit */
+ 	{
+ 	    ins_compl_files(count, files, thesaurus, flags,
+ 							&regmatch, buf, &dir);
+@@ -2813,7 +2821,7 @@
+ 			ptr = find_word_end(ptr);
+ 		    add_r = ins_compl_add_infercase(regmatch->startp[0],
+ 					  (int)(ptr - regmatch->startp[0]),
+-						     FALSE, files[i], *dir, 0);
++						     p_ic, files[i], *dir, 0);
+ 		    if (thesaurus)
+ 		    {
+ 			char_u *wstart;
+@@ -2849,7 +2857,7 @@
+ 				ptr = find_word_end(ptr);
+ 			    add_r = ins_compl_add_infercase(wstart,
+ 				    (int)(ptr - wstart),
+-				    FALSE, files[i], *dir, 0);
++				    p_ic, files[i], *dir, 0);
+ 			}
+ 		    }
+ 		    if (add_r == OK)
+@@ -3015,9 +3023,6 @@
+     if ((int)(p - line) - (int)compl_col <= 0)
+ 	return K_BS;
+ 
+-    /* For redo we need to repeat this backspace. */
+-    AppendCharToRedobuff(K_BS);
+-
+     /* Deleted more than what was used to find matches or didn't finish
+      * finding all matches: need to look for matches all over again. */
+     if (curwin->w_cursor.col <= compl_col + compl_length
+@@ -3046,7 +3051,6 @@
+     ins_compl_delete();
+     ins_bytes(compl_leader + curwin->w_cursor.col - compl_col);
+     compl_used_match = FALSE;
+-    compl_enter_selects = FALSE;
+ 
+     if (compl_started)
+ 	ins_compl_set_original_text(compl_leader);
+@@ -3076,6 +3080,7 @@
+ 	compl_restarting = FALSE;
+     }
+ 
++#if 0   /* disabled, made CTRL-L, BS and typing char jump to original text. */
+     if (!compl_used_match)
+     {
+ 	/* Go to the original text, since none of the matches is inserted. */
+@@ -3087,9 +3092,15 @@
+ 	compl_curr_match = compl_shown_match;
+ 	compl_shows_dir = compl_direction;
+     }
++#endif
++    compl_enter_selects = !compl_used_match;
+ 
+     /* Show the popup menu with a different set of matches. */
+     ins_compl_show_pum();
++
++    /* Don't let Enter select the original text when there is no popup menu. */
++    if (compl_match_array == NULL)
++	compl_enter_selects = FALSE;
+ }
+ 
+ /*
+@@ -3115,10 +3126,6 @@
+ #endif
+ 	ins_char(c);
+ 
+-    /* For redo we need to count this character so that the number of
+-     * backspaces is correct. */
+-    AppendCharToRedobuff(c);
+-
+     /* If we didn't complete finding matches we must search again. */
+     if (compl_was_interrupted)
+ 	ins_compl_restart();
+@@ -3175,10 +3182,32 @@
+     char_u	*p;
+     int		len = curwin->w_cursor.col - compl_col;
+     int		c;
++    compl_T	*cp;
+ 
+     p = compl_shown_match->cp_str;
+     if ((int)STRLEN(p) <= len)   /* the match is too short */
+-	return;
++    {
++	/* When still at the original match use the first entry that matches
++	 * the leader. */
++	if (compl_shown_match->cp_flags & ORIGINAL_TEXT)
++	{
++	    p = NULL;
++	    for (cp = compl_shown_match->cp_next; cp != NULL
++				 && cp != compl_first_match; cp = cp->cp_next)
++	    {
++		if (ins_compl_equal(cp, compl_leader,
++						   (int)STRLEN(compl_leader)))
++		{
++		    p = cp->cp_str;
++		    break;
++		}
++	    }
++	    if (p == NULL || (int)STRLEN(p) <= len)
++		return;
++	}
++	else
++	    return;
++    }
+     p += len;
+ #ifdef FEAT_MBYTE
+     c = mb_ptr2char(p);
+@@ -3198,7 +3227,6 @@
+     int	    c;
+ {
+     char_u	*ptr;
+-    int		temp;
+     int		want_cindent;
+     int		retval = FALSE;
+ 
+@@ -3354,6 +3382,7 @@
+ 	    if (compl_curr_match != NULL || compl_leader != NULL || c == Ctrl_E)
+ 	    {
+ 		char_u	*p;
++		int	temp = 0;
+ 
+ 		/*
+ 		 * If any of the original typed text has been changed, eg when
+@@ -3369,16 +3398,21 @@
+ 		    ptr = compl_leader;
+ 		else
+ 		    ptr = compl_orig_text;
+-		p = compl_orig_text;
+-		for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp]; ++temp)
+-		    ;
++		if (compl_orig_text != NULL)
++		{
++		    p = compl_orig_text;
++		    for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp];
++								       ++temp)
++			;
+ #ifdef FEAT_MBYTE
+-		if (temp > 0)
+-		    temp -= (*mb_head_off)(compl_orig_text, p + temp);
++		    if (temp > 0)
++			temp -= (*mb_head_off)(compl_orig_text, p + temp);
+ #endif
+-		for (p += temp; *p != NUL; mb_ptr_adv(p))
+-		    AppendCharToRedobuff(K_BS);
+-		AppendToRedobuffLit(ptr + temp, -1);
++		    for (p += temp; *p != NUL; mb_ptr_adv(p))
++			AppendCharToRedobuff(K_BS);
++		}
++		if (ptr != NULL)
++		    AppendToRedobuffLit(ptr + temp, -1);
+ 	    }
+ 
+ #ifdef FEAT_CINDENT
+@@ -3578,7 +3612,7 @@
+ {
+     char_u	*word;
+     int		icase = FALSE;
+-    int		dup = FALSE;
++    int		adup = FALSE;
+     char_u	*(cptext[CPT_COUNT]);
+ 
+     if (tv->v_type == VAR_DICT && tv->vval.v_dict != NULL)
+@@ -3595,7 +3629,7 @@
+ 	if (get_dict_string(tv->vval.v_dict, (char_u *)"icase", FALSE) != NULL)
+ 	    icase = get_dict_number(tv->vval.v_dict, (char_u *)"icase");
+ 	if (get_dict_string(tv->vval.v_dict, (char_u *)"dup", FALSE) != NULL)
+-	    dup = get_dict_number(tv->vval.v_dict, (char_u *)"dup");
++	    adup = get_dict_number(tv->vval.v_dict, (char_u *)"dup");
+     }
+     else
+     {
+@@ -3604,7 +3638,7 @@
+     }
+     if (word == NULL || *word == NUL)
+ 	return FAIL;
+-    return ins_compl_add(word, -1, icase, NULL, cptext, dir, 0, dup);
++    return ins_compl_add(word, -1, icase, NULL, cptext, dir, 0, adup);
+ }
+ #endif
+ 
+@@ -3796,7 +3830,7 @@
+ 		    TAG_INS_COMP | (ctrl_x_mode ? TAG_VERBOSE : 0),
+ 		    TAG_MANY, curbuf->b_ffname) == OK && num_matches > 0)
+ 	    {
+-		ins_compl_add_matches(num_matches, matches, FALSE);
++		ins_compl_add_matches(num_matches, matches, p_ic);
+ 	    }
+ 	    p_ic = save_p_ic;
+ 	    break;
+@@ -3837,7 +3871,7 @@
+ 	    num_matches = expand_spelling(first_match_pos.lnum,
+ 				 first_match_pos.col, compl_pattern, &matches);
+ 	    if (num_matches > 0)
+-		ins_compl_add_matches(num_matches, matches, FALSE);
++		ins_compl_add_matches(num_matches, matches, p_ic);
+ #endif
+ 	    break;
+ 
+@@ -3971,7 +4005,7 @@
+ 			    continue;
+ 		    }
+ 		}
+-		if (ins_compl_add_infercase(ptr, len, FALSE,
++		if (ins_compl_add_infercase(ptr, len, p_ic,
+ 				 ins_buf == curbuf ? NULL : ins_buf->b_sfname,
+ 					   0, flags) != NOTDONE)
+ 		{
+@@ -4100,6 +4134,21 @@
+ 		&& compl_shown_match->cp_next != NULL
+ 		&& compl_shown_match->cp_next != compl_first_match)
+ 	    compl_shown_match = compl_shown_match->cp_next;
++
++	/* If we didn't find it searching forward, and compl_shows_dir is
++	 * backward, find the last match. */
++	if (compl_shows_dir == BACKWARD
++		&& !ins_compl_equal(compl_shown_match,
++				      compl_leader, (int)STRLEN(compl_leader))
++		&& (compl_shown_match->cp_next == NULL
++		    || compl_shown_match->cp_next == compl_first_match))
++	{
++	    while (!ins_compl_equal(compl_shown_match,
++				      compl_leader, (int)STRLEN(compl_leader))
++		    && compl_shown_match->cp_prev != NULL
++		    && compl_shown_match->cp_prev != compl_first_match)
++		compl_shown_match = compl_shown_match->cp_prev;
++	}
+     }
+ 
+     if (allow_get_expansion && insert_match
+@@ -4124,8 +4173,6 @@
+     {
+ 	if (compl_shows_dir == FORWARD && compl_shown_match->cp_next != NULL)
+ 	{
+-	    if (compl_pending != 0)
+-		--compl_pending;
+ 	    compl_shown_match = compl_shown_match->cp_next;
+ 	    found_end = (compl_first_match != NULL
+ 			   && (compl_shown_match->cp_next == compl_first_match
+@@ -4134,14 +4181,24 @@
+ 	else if (compl_shows_dir == BACKWARD
+ 					&& compl_shown_match->cp_prev != NULL)
+ 	{
+-	    if (compl_pending != 0)
+-		++compl_pending;
+ 	    found_end = (compl_shown_match == compl_first_match);
+ 	    compl_shown_match = compl_shown_match->cp_prev;
+ 	    found_end |= (compl_shown_match == compl_first_match);
+ 	}
+ 	else
+ 	{
++	    if (!allow_get_expansion)
++	    {
++		if (advance)
++		{
++		    if (compl_shows_dir == BACKWARD)
++			compl_pending -= todo + 1;
++		    else
++			compl_pending += todo + 1;
++		}
++		return -1;
++	    }
++
+ 	    if (advance)
+ 	    {
+ 		if (compl_shows_dir == BACKWARD)
+@@ -4149,14 +4206,27 @@
+ 		else
+ 		    ++compl_pending;
+ 	    }
+-	    if (!allow_get_expansion)
+-		return -1;
+ 
+ 	    /* Find matches. */
+ 	    num_matches = ins_compl_get_exp(&compl_startpos);
+-	    if (compl_pending != 0 && compl_direction == compl_shows_dir
++
++	    /* handle any pending completions */
++	    while (compl_pending != 0 && compl_direction == compl_shows_dir
+ 								   && advance)
+-		compl_shown_match = compl_curr_match;
++	    {
++		if (compl_pending > 0 && compl_shown_match->cp_next != NULL)
++		{
++		    compl_shown_match = compl_shown_match->cp_next;
++		    --compl_pending;
++		}
++		if (compl_pending < 0 && compl_shown_match->cp_prev != NULL)
++		{
++		    compl_shown_match = compl_shown_match->cp_prev;
++		    ++compl_pending;
++		}
++		else
++		    break;
++	    }
+ 	    found_end = FALSE;
+ 	}
+ 	if ((compl_shown_match->cp_flags & ORIGINAL_TEXT) == 0
+@@ -4265,9 +4335,9 @@
+ 	return;
+     count = 0;
+ 
+-    ++no_mapping;
++    /* Check for a typed key.  Do use mappings, otherwise vim_is_ctrl_x_key()
++     * can't do its work correctly. */
+     c = vpeekc_any();
+-    --no_mapping;
+     if (c != NUL)
+     {
+ 	if (vim_is_ctrl_x_key(c) && c != Ctrl_X && c != Ctrl_R)
+@@ -4277,12 +4347,27 @@
+ 	    (void)ins_compl_next(FALSE, ins_compl_key2count(c),
+ 						    c != K_UP && c != K_DOWN);
+ 	}
+-	else if (c != Ctrl_R)
+-	    compl_interrupted = TRUE;
++	else
++	{
++	    /* Need to get the character to have KeyTyped set.  We'll put it
++	     * back with vungetc() below. */
++	    c = safe_vgetc();
++
++	    /* Don't interrupt completion when the character wasn't typed,
++	     * e.g., when doing @q to replay keys. */
++	    if (c != Ctrl_R && KeyTyped)
++		compl_interrupted = TRUE;
++
++	    vungetc(c);
++	}
+     }
+     if (compl_pending != 0 && !got_int)
+-	(void)ins_compl_next(FALSE, compl_pending > 0
+-				      ? compl_pending : -compl_pending, TRUE);
++    {
++	int todo = compl_pending > 0 ? compl_pending : -compl_pending;
++
++	compl_pending = 0;
++	(void)ins_compl_next(FALSE, todo, TRUE);
++    }
+ }
+ 
+ /*
+@@ -4611,10 +4696,12 @@
+ 				     (int)STRLEN(compl_pattern), curs_col);
+ 	    if (compl_xp.xp_context == EXPAND_UNSUCCESSFUL
+ 		    || compl_xp.xp_context == EXPAND_NOTHING)
+-		return FAIL;
+-	    startcol = (int)(compl_xp.xp_pattern - compl_pattern);
+-	    compl_col = startcol;
+-	    compl_length = curs_col - startcol;
++		/* No completion possible, use an empty pattern to get a
++		 * "pattern not found" message. */
++		compl_col = curs_col;
++	    else
++		compl_col = (int)(compl_xp.xp_pattern - compl_pattern);
++	    compl_length = curs_col - compl_col;
+ 	}
+ 	else if (ctrl_x_mode == CTRL_X_FUNCTION || ctrl_x_mode == CTRL_X_OMNI)
+ 	{
+@@ -4668,11 +4755,17 @@
+ 	    else
+ 		compl_col = spell_word_start(startcol);
+ 	    if (compl_col >= (colnr_T)startcol)
+-		return FAIL;
+-	    spell_expand_check_cap(compl_col);
++	    {
++		compl_length = 0;
++		compl_col = curs_col;
++	    }
++	    else
++	    {
++		spell_expand_check_cap(compl_col);
++		compl_length = (int)curs_col - compl_col;
++	    }
+ 	    /* Need to obtain "line" again, it may have become invalid. */
+ 	    line = ml_get(curwin->w_cursor.lnum);
+-	    compl_length = (int)curs_col - compl_col;
+ 	    compl_pattern = vim_strnsave(line + compl_col, compl_length);
+ 	    if (compl_pattern == NULL)
+ #endif
+@@ -4720,7 +4813,7 @@
+ 	vim_free(compl_orig_text);
+ 	compl_orig_text = vim_strnsave(line + compl_col, compl_length);
+ 	if (compl_orig_text == NULL || ins_compl_add(compl_orig_text,
+-			-1, FALSE, NULL, NULL, 0, ORIGINAL_TEXT, FALSE) != OK)
++			-1, p_ic, NULL, NULL, 0, ORIGINAL_TEXT, FALSE) != OK)
+ 	{
+ 	    vim_free(compl_pattern);
+ 	    compl_pattern = NULL;
+@@ -8508,7 +8601,12 @@
+     tpos = curwin->w_cursor;
+     if (oneleft() == OK)
+     {
+-	start_arrow(&tpos);
++#if defined(FEAT_XIM) && defined(FEAT_GUI_GTK)
++	/* Only call start_arrow() when not busy with preediting, it will
++	 * break undo.  K_LEFT is inserted in im_correct_cursor(). */
++	if (!im_is_preediting())
++#endif
++	    start_arrow(&tpos);
+ #ifdef FEAT_RIGHTLEFT
+ 	/* If exit reversed string, position is fixed */
+ 	if (revins_scol != -1 && (int)curwin->w_cursor.col >= revins_scol)
+diff -Naur vim70.orig/src/eval.c vim70/src/eval.c
+--- vim70.orig/src/eval.c	2006-05-05 10:15:26.000000000 -0700
++++ vim70/src/eval.c	2006-09-11 09:04:12.000000000 -0700
+@@ -454,7 +454,7 @@
+ static char_u *deref_func_name __ARGS((char_u *name, int *lenp));
+ static int get_func_tv __ARGS((char_u *name, int len, typval_T *rettv, char_u **arg, linenr_T firstline, linenr_T lastline, int *doesrange, int evaluate, dict_T *selfdict));
+ static int call_func __ARGS((char_u *name, int len, typval_T *rettv, int argcount, typval_T *argvars, linenr_T firstline, linenr_T lastline, int *doesrange, int evaluate, dict_T *selfdict));
+-static void emsg_funcname __ARGS((char *msg, char_u *name));
++static void emsg_funcname __ARGS((char *ermsg, char_u *name));
+ 
+ static void f_add __ARGS((typval_T *argvars, typval_T *rettv));
+ static void f_append __ARGS((typval_T *argvars, typval_T *rettv));
+@@ -701,6 +701,7 @@
+ static void list_one_var_a __ARGS((char_u *prefix, char_u *name, int type, char_u *string));
+ static void set_var __ARGS((char_u *name, typval_T *varp, int copy));
+ static int var_check_ro __ARGS((int flags, char_u *name));
++static int var_check_fixed __ARGS((int flags, char_u *name));
+ static int tv_check_lock __ARGS((int lock, char_u *name));
+ static void copy_tv __ARGS((typval_T *from, typval_T *to));
+ static int item_copy __ARGS((typval_T *from, typval_T *to, int deep, int copyID));
+@@ -2260,7 +2261,7 @@
+ 	    EMSG(_(e_letunexp));
+ 	else
+ 	{
+-	    char_u	*tofree = NULL;
++	    char_u	*ptofree = NULL;
+ 	    char_u	*s;
+ 
+ 	    p = get_tv_string_chk(tv);
+@@ -2269,7 +2270,7 @@
+ 		s = get_reg_contents(*arg == '@' ? '"' : *arg, TRUE, TRUE);
+ 		if (s != NULL)
+ 		{
+-		    p = tofree = concat_str(s, p);
++		    p = ptofree = concat_str(s, p);
+ 		    vim_free(s);
+ 		}
+ 	    }
+@@ -2278,7 +2279,7 @@
+ 		write_reg_contents(*arg == '@' ? '"' : *arg, p, -1, FALSE);
+ 		arg_end = arg + 1;
+ 	    }
+-	    vim_free(tofree);
++	    vim_free(ptofree);
+ 	}
+     }
+ 
+@@ -3364,6 +3365,8 @@
+ 	hi = hash_find(ht, varname);
+ 	if (!HASHITEM_EMPTY(hi))
+ 	{
++	    if (var_check_fixed(HI2DI(hi)->di_flags, name))
++		return FAIL;
+ 	    if (var_check_ro(HI2DI(hi)->di_flags, name))
+ 		return FAIL;
+ 	    delete_var(ht, hi);
+@@ -6059,6 +6062,10 @@
+     tabpage_T	*tp;
+ #endif
+ 
++    /* Only do this once. */
++    want_garbage_collect = FALSE;
++    may_garbage_collect = FALSE;
++
+     /*
+      * 1. Go through all accessible variables and mark all lists and dicts
+      *    with copyID.
+@@ -7595,8 +7602,8 @@
+  * Give an error message with a function name.  Handle <SNR> things.
+  */
+     static void
+-emsg_funcname(msg, name)
+-    char	*msg;
++emsg_funcname(ermsg, name)
++    char	*ermsg;
+     char_u	*name;
+ {
+     char_u	*p;
+@@ -7605,7 +7612,7 @@
+ 	p = concat_str((char_u *)"<SNR>", name + 3);
+     else
+ 	p = name;
+-    EMSG2(_(msg), p);
++    EMSG2(_(ermsg), p);
+     if (p != name)
+ 	vim_free(p);
+ }
+@@ -8252,6 +8259,12 @@
+ 	EMSG(_("E785: complete() can only be used in Insert mode"));
+ 	return;
+     }
++
++    /* Check for undo allowed here, because if something was already inserted
++     * the line was already saved for undo and this check isn't done. */
++    if (!undo_allowed())
++	return;
++
+     if (argvars[1].v_type != VAR_LIST || argvars[1].vval.v_list == NULL)
+     {
+ 	EMSG(_(e_invarg));
+@@ -9173,25 +9186,25 @@
+     typval_T	save_key;
+     int		rem;
+     int		todo;
+-    char_u	*msg = map ? (char_u *)"map()" : (char_u *)"filter()";
++    char_u	*ermsg = map ? (char_u *)"map()" : (char_u *)"filter()";
+     int		save_did_emsg;
+ 
+     rettv->vval.v_number = 0;
+     if (argvars[0].v_type == VAR_LIST)
+     {
+ 	if ((l = argvars[0].vval.v_list) == NULL
+-		|| (map && tv_check_lock(l->lv_lock, msg)))
++		|| (map && tv_check_lock(l->lv_lock, ermsg)))
+ 	    return;
+     }
+     else if (argvars[0].v_type == VAR_DICT)
+     {
+ 	if ((d = argvars[0].vval.v_dict) == NULL
+-		|| (map && tv_check_lock(d->dv_lock, msg)))
++		|| (map && tv_check_lock(d->dv_lock, ermsg)))
+ 	    return;
+     }
+     else
+     {
+-	EMSG2(_(e_listdictarg), msg);
++	EMSG2(_(e_listdictarg), ermsg);
+ 	return;
+     }
+ 
+@@ -9223,7 +9236,7 @@
+ 		{
+ 		    --todo;
+ 		    di = HI2DI(hi);
+-		    if (tv_check_lock(di->di_tv.v_lock, msg))
++		    if (tv_check_lock(di->di_tv.v_lock, ermsg))
+ 			break;
+ 		    vimvars[VV_KEY].vv_str = vim_strsave(di->di_key);
+ 		    if (filter_map_one(&di->di_tv, expr, map, &rem) == FAIL
+@@ -9242,7 +9255,7 @@
+ 	{
+ 	    for (li = l->lv_first; li != NULL; li = nli)
+ 	    {
+-		if (tv_check_lock(li->li_tv.v_lock, msg))
++		if (tv_check_lock(li->li_tv.v_lock, ermsg))
+ 		    break;
+ 		nli = li->li_next;
+ 		if (filter_map_one(&li->li_tv, expr, map, &rem) == FAIL
+@@ -9598,7 +9611,9 @@
+     typval_T	*argvars;
+     typval_T	*rettv;
+ {
+-    garbage_collect();
++    /* This is postponed until we are back at the toplevel, because we may be
++     * using Lists and Dicts internally.  E.g.: ":echo [garbagecollect()]". */
++    want_garbage_collect = TRUE;
+ }
+ 
+ /*
+@@ -9792,6 +9807,9 @@
+     varnumber_T		n;
+     int			error = FALSE;
+ 
++    /* Position the cursor.  Needed after a message that ends in a space. */
++    windgoto(msg_row, msg_col);
++
+     ++no_mapping;
+     ++allow_keys;
+     if (argvars[0].v_type == VAR_UNKNOWN)
+@@ -11312,14 +11330,19 @@
+ 
+ static int inputsecret_flag = 0;
+ 
++static void get_user_input __ARGS((typval_T *argvars, typval_T *rettv, int inputdialog));
++
+ /*
+- * "input()" function
+- *     Also handles inputsecret() when inputsecret is set.
++ * This function is used by f_input() and f_inputdialog() functions. The third
++ * argument to f_input() specifies the type of completion to use at the
++ * prompt. The third argument to f_inputdialog() specifies the value to return
++ * when the user cancels the prompt.
+  */
+     static void
+-f_input(argvars, rettv)
++get_user_input(argvars, rettv, inputdialog)
+     typval_T	*argvars;
+     typval_T	*rettv;
++    int		inputdialog;
+ {
+     char_u	*prompt = get_tv_string_chk(&argvars[0]);
+     char_u	*p = NULL;
+@@ -11369,10 +11392,10 @@
+ 	    if (defstr != NULL)
+ 		stuffReadbuffSpec(defstr);
+ 
+-	    if (argvars[2].v_type != VAR_UNKNOWN)
++	    if (!inputdialog && argvars[2].v_type != VAR_UNKNOWN)
+ 	    {
+ 		char_u	*xp_name;
+-		int		xp_namelen;
++		int	xp_namelen;
+ 		long	argt;
+ 
+ 		rettv->vval.v_string = NULL;
+@@ -11404,6 +11427,18 @@
+ }
+ 
+ /*
++ * "input()" function
++ *     Also handles inputsecret() when inputsecret is set.
++ */
++    static void
++f_input(argvars, rettv)
++    typval_T	*argvars;
++    typval_T	*rettv;
++{
++    get_user_input(argvars, rettv, FALSE);
++}
++
++/*
+  * "inputdialog()" function
+  */
+     static void
+@@ -11443,7 +11478,7 @@
+     }
+     else
+ #endif
+-	f_input(argvars, rettv);
++	get_user_input(argvars, rettv, TRUE);
+ }
+ 
+ /*
+@@ -11471,6 +11506,7 @@
+     }
+ 
+     msg_start();
++    msg_row = Rows - 1;	/* for when 'cmdheight' > 1 */
+     lines_left = Rows;	/* avoid more prompt */
+     msg_scroll = TRUE;
+     msg_clr_eos();
+@@ -13250,7 +13286,7 @@
+ 	if (argvars[2].v_type != VAR_UNKNOWN)
+ 	    EMSG2(_(e_toomanyarg), "remove()");
+ 	else if ((d = argvars[0].vval.v_dict) != NULL
+-		&& !tv_check_lock(d->dv_lock, (char_u *)"remove()"))
++		&& !tv_check_lock(d->dv_lock, (char_u *)"remove() argument"))
+ 	{
+ 	    key = get_tv_string_chk(&argvars[1]);
+ 	    if (key != NULL)
+@@ -13270,7 +13306,7 @@
+     else if (argvars[0].v_type != VAR_LIST)
+ 	EMSG2(_(e_listdictarg), "remove()");
+     else if ((l = argvars[0].vval.v_list) != NULL
+-	    && !tv_check_lock(l->lv_lock, (char_u *)"remove()"))
++	    && !tv_check_lock(l->lv_lock, (char_u *)"remove() argument"))
+     {
+ 	int	    error = FALSE;
+ 
+@@ -14157,11 +14193,7 @@
+     typval_T	*rettv;
+ {
+     buf_T	*buf;
+-#ifdef FEAT_AUTOCMD
+     aco_save_T	aco;
+-#else
+-    buf_T	*save_curbuf;
+-#endif
+     char_u	*varname, *bufvarname;
+     typval_T	*varp;
+     char_u	nbuf[NUMBUFLEN];
+@@ -14178,12 +14210,7 @@
+     if (buf != NULL && varname != NULL && varp != NULL)
+     {
+ 	/* set curbuf to be our buf, temporarily */
+-#ifdef FEAT_AUTOCMD
+ 	aucmd_prepbuf(&aco, buf);
+-#else
+-	save_curbuf = curbuf;
+-	curbuf = buf;
+-#endif
+ 
+ 	if (*varname == '&')
+ 	{
+@@ -14210,11 +14237,7 @@
+ 	}
+ 
+ 	/* reset notion of buffer */
+-#ifdef FEAT_AUTOCMD
+ 	aucmd_restbuf(&aco);
+-#else
+-	curbuf = save_curbuf;
+-#endif
+     }
+ }
+ 
+@@ -16173,7 +16196,7 @@
+ 	curwin->w_curswant = get_dict_number(dict, (char_u *)"curswant");
+ 	curwin->w_set_curswant = FALSE;
+ 
+-	curwin->w_topline = get_dict_number(dict, (char_u *)"topline");
++	set_topline(curwin, get_dict_number(dict, (char_u *)"topline"));
+ #ifdef FEAT_DIFF
+ 	curwin->w_topfill = get_dict_number(dict, (char_u *)"topfill");
+ #endif
+@@ -16218,6 +16241,7 @@
+ #ifdef FEAT_VIRTUALEDIT
+     dict_add_nr_str(dict, "coladd", (long)curwin->w_cursor.coladd, NULL);
+ #endif
++    update_curswant();
+     dict_add_nr_str(dict, "curswant", (long)curwin->w_curswant, NULL);
+ 
+     dict_add_nr_str(dict, "topline", (long)curwin->w_topline, NULL);
+@@ -16438,9 +16462,12 @@
+     long	i = 0;
+     long	n;
+ 
+-    /* List must be: [fnum, lnum, col, coladd] */
+-    if (arg->v_type != VAR_LIST || l == NULL
+-				      || l->lv_len != (fnump == NULL ? 3 : 4))
++    /* List must be: [fnum, lnum, col, coladd], where "fnum" is only there
++     * when "fnump" isn't NULL and "coladd" is optional. */
++    if (arg->v_type != VAR_LIST
++	    || l == NULL
++	    || l->lv_len < (fnump == NULL ? 2 : 3)
++	    || l->lv_len > (fnump == NULL ? 3 : 4))
+ 	return FAIL;
+ 
+     if (fnump != NULL)
+@@ -16466,8 +16493,9 @@
+ #ifdef FEAT_VIRTUALEDIT
+     n = list_find_nr(l, i, NULL);
+     if (n < 0)
+-	return FAIL;
+-    posp->coladd = n;
++	posp->coladd = 0;
++    else
++	posp->coladd = n;
+ #endif
+ 
+     return OK;
+@@ -17759,6 +17787,13 @@
+     }
+     else		    /* add a new variable */
+     {
++	/* Can't add "v:" variable. */
++	if (ht == &vimvarht)
++	{
++	    EMSG2(_(e_illvar), name);
++	    return;
++	}
++
+ 	/* Make sure the variable name is valid. */
+ 	for (p = varname; *p != NUL; ++p)
+ 	    if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p))
+@@ -17792,7 +17827,7 @@
+ }
+ 
+ /*
+- * Return TRUE if di_flags "flags" indicate read-only variable "name".
++ * Return TRUE if di_flags "flags" indicates variable "name" is read-only.
+  * Also give an error message.
+  */
+     static int
+@@ -17814,6 +17849,23 @@
+ }
+ 
+ /*
++ * Return TRUE if di_flags "flags" indicates variable "name" is fixed.
++ * Also give an error message.
++ */
++    static int
++var_check_fixed(flags, name)
++    int		flags;
++    char_u	*name;
++{
++    if (flags & DI_FLAGS_FIX)
++    {
++	EMSG2(_("E795: Cannot delete variable %s"), name);
++	return TRUE;
++    }
++    return FALSE;
++}
++
++/*
+  * Return TRUE if typeval "tv" is set to be locked (immutable).
+  * Also give an error message, using "name".
+  */
+@@ -18786,6 +18838,7 @@
+ 		if (dict_add(fudi.fd_dict, fudi.fd_di) == FAIL)
+ 		{
+ 		    vim_free(fudi.fd_di);
++		    vim_free(fp);
+ 		    goto erret;
+ 		}
+ 	    }
+@@ -18963,7 +19016,8 @@
+     else if (lead > 0)
+     {
+ 	lead = 3;
+-	if (eval_fname_sid(lv.ll_exp_name != NULL ? lv.ll_exp_name : *pp))
++	if ((lv.ll_exp_name != NULL && eval_fname_sid(lv.ll_exp_name))
++						       || eval_fname_sid(*pp))
+ 	{
+ 	    /* It's "s:" or "<SID>" */
+ 	    if (current_SID <= 0)
+@@ -19685,6 +19739,7 @@
+     v->di_tv.vval.v_list = &fc.l_varlist;
+     vim_memset(&fc.l_varlist, 0, sizeof(list_T));
+     fc.l_varlist.lv_refcount = 99999;
++    fc.l_varlist.lv_lock = VAR_FIXED;
+ 
+     /*
+      * Set a:firstline to "firstline" and a:lastline to "lastline".
+@@ -19761,7 +19816,7 @@
+ 	    if (p_verbose >= 14)
+ 	    {
+ 		char_u	buf[MSG_BUF_LEN];
+-		char_u	numbuf[NUMBUFLEN];
++		char_u	numbuf2[NUMBUFLEN];
+ 		char_u	*tofree;
+ 
+ 		msg_puts((char_u *)"(");
+@@ -19773,8 +19828,8 @@
+ 			msg_outnum((long)argvars[i].vval.v_number);
+ 		    else
+ 		    {
+-			trunc_string(tv2string(&argvars[i], &tofree, numbuf, 0),
+-							    buf, MSG_BUF_CLEN);
++			trunc_string(tv2string(&argvars[i], &tofree,
++					      numbuf2, 0), buf, MSG_BUF_CLEN);
+ 			msg_puts(buf);
+ 			vim_free(tofree);
+ 		    }
+@@ -19852,13 +19907,13 @@
+ 	else
+ 	{
+ 	    char_u	buf[MSG_BUF_LEN];
+-	    char_u	numbuf[NUMBUFLEN];
++	    char_u	numbuf2[NUMBUFLEN];
+ 	    char_u	*tofree;
+ 
+ 	    /* The value may be very long.  Skip the middle part, so that we
+ 	     * have some idea how it starts and ends. smsg() would always
+ 	     * truncate it at the end. */
+-	    trunc_string(tv2string(fc.rettv, &tofree, numbuf, 0),
++	    trunc_string(tv2string(fc.rettv, &tofree, numbuf2, 0),
+ 							   buf, MSG_BUF_CLEN);
+ 	    smsg((char_u *)_("%s returning %s"), sourcing_name, buf);
+ 	    vim_free(tofree);
+diff -Naur vim70.orig/src/ex_cmds2.c vim70/src/ex_cmds2.c
+--- vim70.orig/src/ex_cmds2.c	2006-04-17 03:19:07.000000000 -0700
++++ vim70/src/ex_cmds2.c	2006-09-11 08:23:15.000000000 -0700
+@@ -3648,13 +3648,13 @@
+  * Return FALSE when not sourcing a file.
+  */
+     int
+-source_finished(getline, cookie)
+-    char_u	*(*getline) __ARGS((int, void *, int));
++source_finished(fgetline, cookie)
++    char_u	*(*fgetline) __ARGS((int, void *, int));
+     void	*cookie;
+ {
+-    return (getline_equal(getline, cookie, getsourceline)
++    return (getline_equal(fgetline, cookie, getsourceline)
+ 	    && ((struct source_cookie *)getline_cookie(
+-						 getline, cookie))->finished);
++						fgetline, cookie))->finished);
+ }
+ #endif
+ 
+diff -Naur vim70.orig/src/ex_cmds.c vim70/src/ex_cmds.c
+--- vim70.orig/src/ex_cmds.c	2006-04-22 11:56:56.000000000 -0700
++++ vim70/src/ex_cmds.c	2006-09-11 09:03:01.000000000 -0700
+@@ -95,7 +95,10 @@
+ 		_("<%s>%s%s  %d,  Hex %02x,  Octal %03o"),
+ 					   transchar(c), buf1, buf2, c, c, c);
+ #ifdef FEAT_MBYTE
+-	c = cc[ci++];
++	if (enc_utf8)
++	    c = cc[ci++];
++	else
++	    c = 0;
+ #endif
+     }
+ 
+@@ -108,7 +111,7 @@
+ 	if (len > 0)
+ 	    IObuff[len++] = ' ';
+ 	IObuff[len++] = '<';
+-	if (utf_iscomposing(c)
++	if (enc_utf8 && utf_iscomposing(c)
+ # ifdef USE_GUI
+ 		&& !gui.in_use
+ # endif
+@@ -120,7 +123,10 @@
+ 				    : _("> %d, Hex %08x, Octal %o"), c, c, c);
+ 	if (ci == MAX_MCO)
+ 	    break;
+-	c = cc[ci++];
++	if (enc_utf8)
++	    c = cc[ci++];
++	else
++	    c = 0;
+     }
+ #endif
+ 
+@@ -185,6 +191,7 @@
+ 	    new_indent = indent;
+ 	else
+ 	{
++	    has_tab = FALSE;	/* avoid uninit warnings */
+ 	    len = linelen(eap->cmdidx == CMD_right ? &has_tab
+ 						   : NULL) - get_indent();
+ 
+@@ -1772,10 +1779,9 @@
+ 				? (st_old.st_mode & 0020)
+ 				: (st_old.st_mode & 0002))))
+ 	{
+-	    int	tt;
++	    int	tt = msg_didany;
+ 
+ 	    /* avoid a wait_return for this message, it's annoying */
+-	    tt = msg_didany;
+ 	    EMSG2(_("E137: Viminfo file is not writable: %s"), fname);
+ 	    msg_didany = tt;
+ 	    fclose(fp_in);
+@@ -2458,6 +2464,8 @@
+ #ifdef FEAT_AUTOCMD
+ 	apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf);
+ #endif
++	/* Change directories when the 'acd' option is set. */
++	DO_AUTOCHDIR
+     }
+     /* print full file name if :cd used */
+     fileinfo(FALSE, FALSE, eap->forceit);
+@@ -2675,8 +2683,13 @@
+ 				 eap, eap->append, eap->forceit, TRUE, FALSE);
+ 
+ 	/* After ":saveas fname" reset 'readonly'. */
+-	if (eap->cmdidx == CMD_saveas && retval == OK)
+-	    curbuf->b_p_ro = FALSE;
++	if (eap->cmdidx == CMD_saveas)
++	{
++	    if (retval == OK)
++		curbuf->b_p_ro = FALSE;
++	    /* Change directories when the 'acd' option is set. */
++	    DO_AUTOCHDIR
++	}
+     }
+ 
+ theend:
+@@ -3547,11 +3560,9 @@
+ 	foldUpdateAll(curwin);
+ #endif
+ 
+-#ifdef FEAT_AUTOCHDIR
+-	if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	    shorten_fnames(TRUE);
+-#endif
++	/* Change directories when the 'acd' option is set. */
++	DO_AUTOCHDIR
++
+ 	/*
+ 	 * Careful: open_buffer() and apply_autocmds() may change the current
+ 	 * buffer and window.
+@@ -3718,12 +3729,8 @@
+     if (p_im)
+ 	need_start_insertmode = TRUE;
+ 
+-#ifdef FEAT_AUTOCHDIR
+-    /* Change directories when the acd option is set on. */
+-    if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	shorten_fnames(TRUE);
+-#endif
++    /* Change directories when the 'acd' option is set. */
++    DO_AUTOCHDIR
+ 
+ #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG)
+     if (gui.in_use && curbuf->b_ffname != NULL)
+diff -Naur vim70.orig/src/ex_cmds.h vim70/src/ex_cmds.h
+--- vim70.orig/src/ex_cmds.h	2006-04-07 02:44:46.000000000 -0700
++++ vim70/src/ex_cmds.h	2006-07-14 08:51:21.000000000 -0700
+@@ -262,7 +262,7 @@
+ EX(CMD_comclear,	"comclear",	ex_comclear,
+ 			TRLBAR|CMDWIN),
+ EX(CMD_compiler,	"compiler",	ex_compiler,
+-			BANG|TRLBAR|WORD1),
++			BANG|TRLBAR|WORD1|CMDWIN),
+ EX(CMD_continue,	"continue",	ex_continue,
+ 			TRLBAR|SBOXOK|CMDWIN),
+ EX(CMD_confirm,		"confirm",	ex_wrongmodifier,
+diff -Naur vim70.orig/src/ex_docmd.c vim70/src/ex_docmd.c
+--- vim70.orig/src/ex_docmd.c	2006-05-05 09:33:19.000000000 -0700
++++ vim70/src/ex_docmd.c	2006-09-11 09:27:48.000000000 -0700
+@@ -58,9 +58,9 @@
+ #endif
+ 
+ #ifdef FEAT_EVAL
+-static char_u	*do_one_cmd __ARGS((char_u **, int, struct condstack *, char_u *(*getline)(int, void *, int), void *cookie));
++static char_u	*do_one_cmd __ARGS((char_u **, int, struct condstack *, char_u *(*fgetline)(int, void *, int), void *cookie));
+ #else
+-static char_u	*do_one_cmd __ARGS((char_u **, int, char_u *(*getline)(int, void *, int), void *cookie));
++static char_u	*do_one_cmd __ARGS((char_u **, int, char_u *(*fgetline)(int, void *, int), void *cookie));
+ static int	if_level = 0;		/* depth in :if */
+ #endif
+ static char_u	*find_command __ARGS((exarg_T *eap, int *full));
+@@ -831,10 +831,13 @@
+ 
+     /*
+      * If requested, store and reset the global values controlling the
+-     * exception handling (used when debugging).
++     * exception handling (used when debugging).  Otherwise clear it to avoid
++     * a bogus compiler warning when the optimizer uses inline functions...
+      */
+-    else if (flags & DOCMD_EXCRESET)
++    if (flags & DOCMD_EXCRESET)
+ 	save_dbg_stuff(&debug_saved);
++    else
++	memset(&debug_saved, 0, 1);
+ 
+     initial_trylevel = trylevel;
+ 
+@@ -1574,24 +1577,24 @@
+ #endif
+ 
+ /*
+- * If "getline" is get_loop_line(), return TRUE if the getline it uses equals
+- * "func".  * Otherwise return TRUE when "getline" equals "func".
++ * If "fgetline" is get_loop_line(), return TRUE if the getline it uses equals
++ * "func".  * Otherwise return TRUE when "fgetline" equals "func".
+  */
+ /*ARGSUSED*/
+     int
+-getline_equal(getline, cookie, func)
+-    char_u	*(*getline) __ARGS((int, void *, int));
+-    void	*cookie;		/* argument for getline() */
++getline_equal(fgetline, cookie, func)
++    char_u	*(*fgetline) __ARGS((int, void *, int));
++    void	*cookie;		/* argument for fgetline() */
+     char_u	*(*func) __ARGS((int, void *, int));
+ {
+ #ifdef FEAT_EVAL
+     char_u		*(*gp) __ARGS((int, void *, int));
+     struct loop_cookie *cp;
+ 
+-    /* When "getline" is "get_loop_line()" use the "cookie" to find the
++    /* When "fgetline" is "get_loop_line()" use the "cookie" to find the
+      * function that's orignally used to obtain the lines.  This may be nested
+      * several levels. */
+-    gp = getline;
++    gp = fgetline;
+     cp = (struct loop_cookie *)cookie;
+     while (gp == get_loop_line)
+     {
+@@ -1600,29 +1603,29 @@
+     }
+     return gp == func;
+ #else
+-    return getline == func;
++    return fgetline == func;
+ #endif
+ }
+ 
+ #if defined(FEAT_EVAL) || defined(FEAT_MBYTE) || defined(PROTO)
+ /*
+- * If "getline" is get_loop_line(), return the cookie used by the original
++ * If "fgetline" is get_loop_line(), return the cookie used by the original
+  * getline function.  Otherwise return "cookie".
+  */
+ /*ARGSUSED*/
+     void *
+-getline_cookie(getline, cookie)
+-    char_u	*(*getline) __ARGS((int, void *, int));
+-    void	*cookie;		/* argument for getline() */
++getline_cookie(fgetline, cookie)
++    char_u	*(*fgetline) __ARGS((int, void *, int));
++    void	*cookie;		/* argument for fgetline() */
+ {
+ # ifdef FEAT_EVAL
+     char_u		*(*gp) __ARGS((int, void *, int));
+     struct loop_cookie *cp;
+ 
+-    /* When "getline" is "get_loop_line()" use the "cookie" to find the
++    /* When "fgetline" is "get_loop_line()" use the "cookie" to find the
+      * cookie that's orignally used to obtain the lines.  This may be nested
+      * several levels. */
+-    gp = getline;
++    gp = fgetline;
+     cp = (struct loop_cookie *)cookie;
+     while (gp == get_loop_line)
+     {
+@@ -1648,7 +1651,7 @@
+  * 5. parse arguments
+  * 6. switch on command name
+  *
+- * Note: "getline" can be NULL.
++ * Note: "fgetline" can be NULL.
+  *
+  * This function may be called recursively!
+  */
+@@ -1663,14 +1666,14 @@
+ #ifdef FEAT_EVAL
+ 			    cstack,
+ #endif
+-				    getline, cookie)
++				    fgetline, cookie)
+     char_u		**cmdlinep;
+     int			sourcing;
+ #ifdef FEAT_EVAL
+     struct condstack	*cstack;
+ #endif
+-    char_u		*(*getline) __ARGS((int, void *, int));
+-    void		*cookie;		/* argument for getline() */
++    char_u		*(*fgetline) __ARGS((int, void *, int));
++    void		*cookie;		/* argument for fgetline() */
+ {
+     char_u		*p;
+     linenr_T		lnum;
+@@ -1698,7 +1701,7 @@
+     if (quitmore
+ #ifdef FEAT_EVAL
+ 	    /* avoid that a function call in 'statusline' does this */
+-	    && !getline_equal(getline, cookie, get_func_line)
++	    && !getline_equal(fgetline, cookie, get_func_line)
+ #endif
+ 	    )
+ 	--quitmore;
+@@ -1710,6 +1713,10 @@
+     save_cmdmod = cmdmod;
+     vim_memset(&cmdmod, 0, sizeof(cmdmod));
+ 
++    /* "#!anything" is handled like a comment. */
++    if ((*cmdlinep)[0] == '#' && (*cmdlinep)[1] == '!')
++	goto doend;
++
+     /*
+      * Repeat until no more command modifiers are found.
+      */
+@@ -1724,8 +1731,8 @@
+ 
+ 	/* in ex mode, an empty line works like :+ */
+ 	if (*ea.cmd == NUL && exmode_active
+-			&& (getline_equal(getline, cookie, getexmodeline)
+-			    || getline_equal(getline, cookie, getexline))
++			&& (getline_equal(fgetline, cookie, getexmodeline)
++			    || getline_equal(fgetline, cookie, getexline))
+ 			&& curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count)
+ 	{
+ 	    ea.cmd = (char_u *)"+";
+@@ -1914,9 +1921,9 @@
+     /* Count this line for profiling if ea.skip is FALSE. */
+     if (do_profiling == PROF_YES && !ea.skip)
+     {
+-	if (getline_equal(getline, cookie, get_func_line))
+-	    func_line_exec(getline_cookie(getline, cookie));
+-	else if (getline_equal(getline, cookie, getsourceline))
++	if (getline_equal(fgetline, cookie, get_func_line))
++	    func_line_exec(getline_cookie(fgetline, cookie));
++	else if (getline_equal(fgetline, cookie, getsourceline))
+ 	    script_line_exec();
+     }
+ #endif
+@@ -2585,7 +2592,7 @@
+  * The "ea" structure holds the arguments that can be used.
+  */
+     ea.cmdlinep = cmdlinep;
+-    ea.getline = getline;
++    ea.getline = fgetline;
+     ea.cookie = cookie;
+ #ifdef FEAT_EVAL
+     ea.cstack = cstack;
+@@ -2623,9 +2630,9 @@
+ 	do_throw(cstack);
+     else if (check_cstack)
+     {
+-	if (source_finished(getline, cookie))
++	if (source_finished(fgetline, cookie))
+ 	    do_finish(&ea, TRUE);
+-	else if (getline_equal(getline, cookie, get_func_line)
++	else if (getline_equal(fgetline, cookie, get_func_line)
+ 						   && current_func_returned())
+ 	    do_return(&ea, TRUE, FALSE, NULL);
+     }
+@@ -6289,7 +6296,6 @@
+     exarg_T	*eap;
+ {
+     tabpage_T	*tp;
+-    int		h = tabline_height();
+ 
+ # ifdef FEAT_CMDWIN
+     if (cmdwin_type != 0)
+@@ -6321,9 +6327,6 @@
+ 	       )
+ 		tabpage_close(eap->forceit);
+ 	}
+-
+-    if (h != tabline_height())
+-	shell_new_rows();
+ }
+ 
+ /*
+@@ -6335,7 +6338,6 @@
+ {
+     tabpage_T	*tp;
+     int		done;
+-    int		h = tabline_height();
+ 
+ # ifdef FEAT_CMDWIN
+     if (cmdwin_type != 0)
+@@ -6364,9 +6366,6 @@
+ 		    break;
+ 	    }
+ 	}
+-
+-    if (h != tabline_height())
+-	shell_new_rows();
+ }
+ 
+ /*
+@@ -6390,6 +6389,8 @@
+ /*
+  * Close tab page "tp", which is not the current tab page.
+  * Note that autocommands may make "tp" invalid.
++ * Also takes care of the tab pages line disappearing when closing the
++ * last-but-one tab page.
+  */
+     void
+ tabpage_close_other(tp, forceit)
+@@ -6398,6 +6399,7 @@
+ {
+     int		done = 0;
+     win_T	*wp;
++    int		h = tabline_height();
+ 
+     /* Limit to 1000 windows, autocommands may add a window while we close
+      * one.  OK, so I'm paranoid... */
+@@ -6411,7 +6413,10 @@
+ 	if (!valid_tabpage(tp) || tp->tp_firstwin == wp)
+ 	    break;
+     }
++
+     redraw_tabline = TRUE;
++    if (h != tabline_height())
++	shell_new_rows();
+ }
+ 
+ /*
+@@ -8417,6 +8422,15 @@
+ 	else
+ 	    EMSG2(_(e_invarg2), eap->arg);
+     }
++
++    /* Make sure redirection is not off.  Can happen for cmdline completion
++     * that indirectly invokes a command to catch its output. */
++    if (redir_fd != NULL
++#ifdef FEAT_EVAL
++			  || redir_reg || redir_vname
++#endif
++							)
++	redir_off = FALSE;
+ }
+ 
+ /*
+diff -Naur vim70.orig/src/ex_getln.c vim70/src/ex_getln.c
+--- vim70.orig/src/ex_getln.c	2006-04-30 08:32:01.000000000 -0700
++++ vim70/src/ex_getln.c	2006-09-11 09:27:49.000000000 -0700
+@@ -324,6 +324,9 @@
+      */
+     for (;;)
+     {
++	redir_off = TRUE;	/* Don't redirect the typed command.
++				   Repeated, because a ":redir" inside
++				   completion may switch it on. */
+ #ifdef USE_ON_FLY_SCROLL
+ 	dont_scroll = FALSE;	/* allow scrolling here */
+ #endif
+@@ -4521,7 +4524,9 @@
+     flags |= EW_FILE | EW_EXEC;
+ 
+     /* For an absolute name we don't use $PATH. */
+-    if ((pat[0] == '.' && (vim_ispathsep(pat[1])
++    if (mch_isFullName(pat))
++	path = (char_u *)" ";
++    else if ((pat[0] == '.' && (vim_ispathsep(pat[1])
+ 			    || (pat[1] == '.' && vim_ispathsep(pat[2])))))
+ 	path = (char_u *)".";
+     else
+@@ -4534,6 +4539,9 @@
+     ga_init2(&ga, (int)sizeof(char *), 10);
+     for (s = path; *s != NUL; s = e)
+     {
++	if (*s == ' ')
++	    ++s;	/* Skip space used for absolute path name. */
++
+ #if defined(MSDOS) || defined(MSWIN) || defined(OS2)
+ 	e = vim_strchr(s, ';');
+ #else
+@@ -5982,6 +5990,8 @@
+     typestr[0] = cmdwin_type;
+     typestr[1] = NUL;
+     apply_autocmds(EVENT_CMDWINENTER, typestr, typestr, FALSE, curbuf);
++    if (restart_edit != 0)	/* autocmd with ":startinsert" */
++	stuffcharReadbuff(K_NOP);
+ # endif
+ 
+     i = RedrawingDisabled;
+diff -Naur vim70.orig/src/fileio.c vim70/src/fileio.c
+--- vim70.orig/src/fileio.c	2006-04-30 08:28:57.000000000 -0700
++++ vim70/src/fileio.c	2006-09-11 09:04:57.000000000 -0700
+@@ -316,6 +316,9 @@
+      * display the line. */
+     ex_no_reprint = TRUE;
+ 
++    /* don't display the file info for another buffer now */
++    need_fileinfo = FALSE;
++
+     /*
+      * For Unix: Use the short file name whenever possible.
+      * Avoids problems with networks and when directory names are changed.
+@@ -6450,17 +6453,10 @@
+     int		old_ro = buf->b_p_ro;
+     buf_T	*savebuf;
+     int		saved = OK;
+-#ifdef FEAT_AUTOCMD
+     aco_save_T	aco;
+ 
+     /* set curwin/curbuf for "buf" and save some things */
+     aucmd_prepbuf(&aco, buf);
+-#else
+-    buf_T	*save_curbuf = curbuf;
+-
+-    curbuf = buf;
+-    curwin->w_buffer = buf;
+-#endif
+ 
+     /* We only want to read the text from the file, not reset the syntax
+      * highlighting, clear marks, diff status, etc.  Force the fileformat
+@@ -6573,14 +6569,9 @@
+ 	    curbuf->b_p_ro |= old_ro;
+     }
+ 
+-#ifdef FEAT_AUTOCMD
+     /* restore curwin/curbuf and a few other things */
+     aucmd_restbuf(&aco);
+     /* Careful: autocommands may have made "buf" invalid! */
+-#else
+-    curwin->w_buffer = save_curbuf;
+-    curbuf = save_curbuf;
+-#endif
+ }
+ 
+ /*ARGSUSED*/
+@@ -6992,6 +6983,7 @@
+     {"FocusLost",	EVENT_FOCUSLOST},
+     {"FuncUndefined",	EVENT_FUNCUNDEFINED},
+     {"GUIEnter",	EVENT_GUIENTER},
++    {"GUIFailed",	EVENT_GUIFAILED},
+     {"InsertChange",	EVENT_INSERTCHANGE},
+     {"InsertEnter",	EVENT_INSERTENTER},
+     {"InsertLeave",	EVENT_INSERTLEAVE},
+@@ -8088,6 +8080,7 @@
+  * Search a window for the current buffer.  Save the cursor position and
+  * screen offset.
+  * Set "curbuf" and "curwin" to match "buf".
++ * When FEAT_AUTOCMD is not defined another version is used, see below.
+  */
+     void
+ aucmd_prepbuf(aco, buf)
+@@ -8151,6 +8144,7 @@
+ /*
+  * Cleanup after executing autocommands for a (hidden) buffer.
+  * Restore the window as it was (if possible).
++ * When FEAT_AUTOCMD is not defined another version is used, see below.
+  */
+     void
+ aucmd_restbuf(aco)
+@@ -9063,8 +9057,38 @@
+     return retval;
+ }
+ 
++#else	/* FEAT_AUTOCMD */
++
++/*
++ * Prepare for executing commands for (hidden) buffer "buf".
++ * This is the non-autocommand version, it simply saves "curbuf" and sets
++ * "curbuf" and "curwin" to match "buf".
++ */
++    void
++aucmd_prepbuf(aco, buf)
++    aco_save_T	*aco;		/* structure to save values in */
++    buf_T	*buf;		/* new curbuf */
++{
++    aco->save_buf = buf;
++    curbuf = buf;
++    curwin->w_buffer = buf;
++}
++
++/*
++ * Restore after executing commands for a (hidden) buffer.
++ * This is the non-autocommand version.
++ */
++    void
++aucmd_restbuf(aco)
++    aco_save_T	*aco;		/* structure holding saved values */
++{
++    curbuf = aco->save_buf;
++    curwin->w_buffer = curbuf;
++}
++
+ #endif	/* FEAT_AUTOCMD */
+ 
++
+ #if defined(FEAT_AUTOCMD) || defined(FEAT_WILDIGN) || defined(PROTO)
+ /*
+  * Try matching a filename with a "pattern" ("prog" is NULL), or use the
+diff -Naur vim70.orig/src/getchar.c vim70/src/getchar.c
+--- vim70.orig/src/getchar.c	2006-05-03 10:29:21.000000000 -0700
++++ vim70/src/getchar.c	2006-09-11 09:00:04.000000000 -0700
+@@ -1451,7 +1451,8 @@
+ {
+     updatescript(0);
+ #ifdef FEAT_EVAL
+-    garbage_collect();
++    if (may_garbage_collect)
++	garbage_collect();
+ #endif
+ }
+ 
+@@ -1502,6 +1503,13 @@
+     int		i;
+ #endif
+ 
++#ifdef FEAT_EVAL
++    /* Do garbage collection when garbagecollect() was called previously and
++     * we are now at the toplevel. */
++    if (may_garbage_collect && want_garbage_collect)
++	garbage_collect();
++#endif
++
+     /*
+      * If a character was put back with vungetc, it was already processed.
+      * Return it directly.
+@@ -1511,13 +1519,13 @@
+ 	c = old_char;
+ 	old_char = -1;
+ 	mod_mask = old_mod_mask;
+-	return c;
+     }
+-
+-    mod_mask = 0x0;
+-    last_recorded_len = 0;
+-    for (;;)			/* this is done twice if there are modifiers */
++    else
+     {
++      mod_mask = 0x0;
++      last_recorded_len = 0;
++      for (;;)			/* this is done twice if there are modifiers */
++      {
+ 	if (mod_mask)		/* no mapping after modifier has been read */
+ 	{
+ 	    ++no_mapping;
+@@ -1695,8 +1703,20 @@
+ 	}
+ #endif
+ 
+-	return c;
++	break;
++      }
+     }
++
++#ifdef FEAT_EVAL
++    /*
++     * In the main loop "may_garbage_collect" can be set to do garbage
++     * collection in the first next vgetc().  It's disabled after that to
++     * avoid internally used Lists and Dicts to be freed.
++     */
++    may_garbage_collect = FALSE;
++#endif
++
++    return c;
+ }
+ 
+ /*
+diff -Naur vim70.orig/src/globals.h vim70/src/globals.h
+--- vim70.orig/src/globals.h	2006-04-30 06:16:23.000000000 -0700
++++ vim70/src/globals.h	2006-09-11 09:00:04.000000000 -0700
+@@ -300,9 +300,16 @@
+ #endif
+ 
+ #ifdef FEAT_EVAL
+-EXTERN scid_T	current_SID INIT(= 0);	    /* ID of script being sourced or
+-					       was sourced to define the
+-					       current function. */
++/* Garbage collection can only take place when we are sure there are no Lists
++ * or Dictionaries being used internally.  This is flagged with
++ * "may_garbage_collect" when we are at the toplevel.
++ * "want_garbage_collect" is set by the garbagecollect() function, which means
++ * we do garbage collection before waiting for a char at the toplevel. */
++EXTERN int	may_garbage_collect INIT(= FALSE);
++EXTERN int	want_garbage_collect INIT(= FALSE);
++
++/* ID of script being sourced or was sourced to define the current function. */
++EXTERN scid_T	current_SID INIT(= 0);
+ #endif
+ 
+ #if defined(FEAT_EVAL) || defined(FEAT_SYN_HL)
+@@ -1441,7 +1448,7 @@
+ EXTERN char_u e_readonly[]	INIT(= N_("E45: 'readonly' option is set (add ! to override)"));
+ #ifdef FEAT_EVAL
+ EXTERN char_u e_readonlyvar[]	INIT(= N_("E46: Cannot change read-only variable \"%s\""));
+-EXTERN char_u e_readonlysbx[]	INIT(= N_("E46: Cannot set variable in the sandbox: \"%s\""));
++EXTERN char_u e_readonlysbx[]	INIT(= N_("E794: Cannot set variable in the sandbox: \"%s\""));
+ #endif
+ #ifdef FEAT_QUICKFIX
+ EXTERN char_u e_readerrf[]	INIT(= N_("E47: Error while reading errorfile"));
+diff -Naur vim70.orig/src/gui_at_fs.c vim70/src/gui_at_fs.c
+--- vim70.orig/src/gui_at_fs.c	2005-07-09 04:30:17.000000000 -0700
++++ vim70/src/gui_at_fs.c	2006-07-14 08:51:21.000000000 -0700
+@@ -1861,27 +1861,27 @@
+     XtPointer	pnew;
+ {
+     SFDir	*dir;
+-    int		nw;
++    int		nw = (int)(long)pnew;
+ 
+     dir = &(SFdirs[SFdirPtr + (int)(long)n]);
+ 
+ #ifdef FEAT_GUI_NEXTAW
+-    if ((int)(long)pnew < 0)
++    if (nw < 0)
+     {
+-	if ((int)(long)pnew > -SFvScrollHeight)
+-	    (int)(long)pnew = -1;
++	if (nw > -SFvScrollHeight)
++	    nw = -1;
+ 	else
+-	    (int)(long)pnew = -SFlistSize;
++	    nw = -SFlistSize;
+     }
+-    else if ((int)(long)pnew > 0)
++    else if (nw > 0)
+     {
+-	if ((int)(long)pnew < SFvScrollHeight)
+-	    (int)(long)pnew = 1;
++	if (nw < SFvScrollHeight)
++	    nw = 1;
+ 	else
+-	    (int)(long)pnew = SFlistSize;
++	    nw = SFlistSize;
+     }
+ #endif
+-    nw = dir->vOrigin + (int)(long)pnew;
++    nw += dir->vOrigin;
+ 
+     if (nw > dir->nEntries - SFlistSize)
+ 	nw = dir->nEntries - SFlistSize;
+@@ -1941,27 +1941,27 @@
+     XtPointer	pnew;
+ {
+     SFDir	*dir;
+-    int		nw;
++    int		nw = (int)(long)pnew;
+ 
+     dir = &(SFdirs[SFdirPtr + (int)(long)n]);
+ 
+ #ifdef FEAT_GUI_NEXTAW
+-    if ((int)(long)pnew < 0)
++    if (nw < 0)
+     {
+-	if ((int)(long)pnew > -SFhScrollWidth)
+-	    (int)(long)pnew = -1;
++	if (nw > -SFhScrollWidth)
++	    nw = -1;
+ 	else
+-	    (int)(long)pnew = -SFcharsPerEntry;
++	    nw = -SFcharsPerEntry;
+     }
+-    else if ((int)(long)pnew > 0)
++    else if (nw > 0)
+     {
+-	if ((int)(long)pnew < SFhScrollWidth)
+-	    (int)(long)pnew = 1;
++	if (nw < SFhScrollWidth)
++	    nw = 1;
+ 	else
+-	    (int)(long)pnew = SFcharsPerEntry;
++	    nw = SFcharsPerEntry;
+     }
+ #endif
+-    nw = dir->hOrigin + (int)(long)pnew;
++    nw += dir->hOrigin;
+ 
+     if (nw > dir->nChars - SFcharsPerEntry)
+ 	nw = dir->nChars - SFcharsPerEntry;
+@@ -2038,26 +2038,26 @@
+     XtPointer	client_data;
+     XtPointer	pnew;
+ {
+-    int		nw;
++    int		nw = (int)(long)pnew;
+     float	f;
+ 
+ #ifdef FEAT_GUI_NEXTAW
+-    if ((int)(long)pnew < 0)
++    if (nw < 0)
+     {
+-	if ((int)(long)pnew > -SFpathScrollWidth)
+-	    (int)(long)pnew = -1;
++	if (nw > -SFpathScrollWidth)
++	    nw = -1;
+ 	else
+-	    (int)(long)pnew = -3;
++	    nw = -3;
+     }
+-    else if ((int)(long)pnew > 0)
++    else if (nw > 0)
+     {
+-	if ((int)(long)pnew < SFpathScrollWidth)
+-	    (int)(long)pnew = 1;
++	if (nw < SFpathScrollWidth)
++	    nw = 1;
+ 	else
+-	    (int)(long)pnew = 3;
++	    nw = 3;
+     }
+ #endif
+-    nw = SFdirPtr + (int)(long)pnew;
++    nw += SFdirPtr;
+ 
+     if (nw > SFdirEnd - 3)
+ 	nw = SFdirEnd - 3;
+diff -Naur vim70.orig/src/gui_beval.c vim70/src/gui_beval.c
+--- vim70.orig/src/gui_beval.c	2006-05-04 12:29:51.000000000 -0700
++++ vim70/src/gui_beval.c	2006-09-11 08:23:15.000000000 -0700
+@@ -926,7 +926,7 @@
+ #  define IS_NONPRINTABLE(c) (((c) < 0x20 && (c) != TAB && (c) != NL) \
+ 			      || (c) == DEL)
+     static void
+-set_printable_label_text(GtkLabel *label, char_u *msg)
++set_printable_label_text(GtkLabel *label, char_u *text)
+ {
+     char_u	    *convbuf = NULL;
+     char_u	    *buf;
+@@ -940,14 +940,14 @@
+     /* Convert to UTF-8 if it isn't already */
+     if (output_conv.vc_type != CONV_NONE)
+     {
+-	convbuf = string_convert(&output_conv, msg, NULL);
++	convbuf = string_convert(&output_conv, text, NULL);
+ 	if (convbuf != NULL)
+-	    msg = convbuf;
++	    text = convbuf;
+     }
+ 
+     /* First let's see how much we need to allocate */
+     len = 0;
+-    for (p = msg; *p != NUL; p += charlen)
++    for (p = text; *p != NUL; p += charlen)
+     {
+ 	if ((*p & 0x80) == 0)	/* be quick for ASCII */
+ 	{
+@@ -992,7 +992,7 @@
+ 				     (unsigned long)pixel, &color);
+ 
+ 	pdest = buf;
+-	p = msg;
++	p = text;
+ 	while (*p != NUL)
+ 	{
+ 	    /* Be quick for ASCII */
+diff -Naur vim70.orig/src/gui.c vim70/src/gui.c
+--- vim70.orig/src/gui.c	2006-05-03 04:00:59.000000000 -0700
++++ vim70/src/gui.c	2006-09-11 09:28:13.000000000 -0700
+@@ -187,9 +187,10 @@
+ #endif
+ 
+ #ifdef FEAT_AUTOCMD
+-    /* If the GUI started successfully, trigger the GUIEnter event */
+-    if (gui.in_use)
+-	apply_autocmds(EVENT_GUIENTER, NULL, NULL, FALSE, curbuf);
++    /* If the GUI started successfully, trigger the GUIEnter event, otherwise
++     * the GUIFailed event. */
++    apply_autocmds(gui.in_use ? EVENT_GUIENTER : EVENT_GUIFAILED,
++						   NULL, NULL, FALSE, curbuf);
+ #endif
+ 
+     --recursive;
+@@ -3733,6 +3734,12 @@
+     if (dont_scroll || input_available())
+ 	return;
+ #endif
++#ifdef FEAT_INS_EXPAND
++    /* Disallow scrolling the current window when the completion popup menu is
++     * visible. */
++    if ((sb->wp == NULL || sb->wp == curwin) && pum_visible())
++	return;
++#endif
+ 
+ #ifdef FEAT_RIGHTLEFT
+     if (sb->wp == NULL && curwin->w_p_rl)
+@@ -4207,6 +4214,12 @@
+ 	updateWindow(wp);   /* update window, status line, and cmdline */
+     }
+ 
++#ifdef FEAT_INS_EXPAND
++    /* May need to redraw the popup menu. */
++    if (pum_visible())
++	pum_redraw();
++#endif
++
+     return (wp == curwin && !equalpos(curwin->w_cursor, old_cursor));
+ }
+ 
+@@ -4515,7 +4528,7 @@
+     int		y;
+ {
+     win_T	*wp;
+-    char_u	st[6];
++    char_u	st[8];
+ 
+     /* Ignore this while still starting up. */
+     if (!gui.in_use || gui.starting)
+@@ -4603,11 +4616,11 @@
+     /* Don't move the mouse when it's left or right of the Vim window */
+     if (x < 0 || x > Columns * gui.char_width)
+ 	return;
++    if (y >= 0
+ # ifdef FEAT_WINDOWS
+-    if (Y_2_ROW(y) >= tabline_height())
+-# else
+-    if (y >= 0)
++	    && Y_2_ROW(y) >= tabline_height()
+ # endif
++       )
+ 	wp = xy2win(x, y);
+     if (wp != curwin && wp != NULL)	/* If in other than current window */
+     {
+diff -Naur vim70.orig/src/gui_gtk.c vim70/src/gui_gtk.c
+--- vim70.orig/src/gui_gtk.c	2006-05-05 04:52:52.000000000 -0700
++++ vim70/src/gui_gtk.c	2006-09-11 08:23:15.000000000 -0700
+@@ -957,15 +957,15 @@
+ get_menu_position(vimmenu_T *menu)
+ {
+     vimmenu_T	*node;
+-    int		index = 0;
++    int		idx = 0;
+ 
+     for (node = menu->parent->children; node != menu; node = node->next)
+     {
+ 	g_return_val_if_fail(node != NULL, -1);
+-	++index;
++	++idx;
+     }
+ 
+-    return index;
++    return idx;
+ }
+ #endif /* FEAT_TOOLBAR && HAVE_GTK2 */
+ 
+@@ -2127,7 +2127,7 @@
+     char    **ync;  /* "yes no cancel" */
+     char    **buttons;
+     int	    n_buttons = 0;
+-    int	    index;
++    int	    idx;
+ 
+     button_string = vim_strsave(button_string); /* must be writable */
+     if (button_string == NULL)
+@@ -2161,12 +2161,12 @@
+      * Well, apparently somebody changed his mind: with GTK 2.2.4 it works the
+      * other way around...
+      */
+-    for (index = 1; index <= n_buttons; ++index)
++    for (idx = 1; idx <= n_buttons; ++idx)
+     {
+ 	char	*label;
+ 	char_u	*label8;
+ 
+-	label = buttons[index - 1];
++	label = buttons[idx - 1];
+ 	/*
+ 	 * Perform some guesswork to find appropriate stock items for the
+ 	 * buttons.  We have to compare with a sample of the translated
+@@ -2188,7 +2188,7 @@
+ 	    else if (button_equal(label, "Cancel")) label = GTK_STOCK_CANCEL;
+ 	}
+ 	label8 = CONVERT_TO_UTF8((char_u *)label);
+-	gtk_dialog_add_button(dialog, (const gchar *)label8, index);
++	gtk_dialog_add_button(dialog, (const gchar *)label8, idx);
+ 	CONVERT_TO_UTF8_FREE(label8);
+     }
+ 
+diff -Naur vim70.orig/src/gui_gtk_x11.c vim70/src/gui_gtk_x11.c
+--- vim70.orig/src/gui_gtk_x11.c	2006-05-04 23:58:59.000000000 -0700
++++ vim70/src/gui_gtk_x11.c	2006-09-11 08:23:16.000000000 -0700
+@@ -3233,12 +3233,12 @@
+ on_select_tab(
+ 	GtkNotebook	*notebook,
+ 	GtkNotebookPage *page,
+-	gint		index,
++	gint		idx,
+ 	gpointer	data)
+ {
+     if (!ignore_tabline_evt)
+     {
+-	if (send_tabline_event(index + 1) && gtk_main_level() > 0)
++	if (send_tabline_event(idx + 1) && gtk_main_level() > 0)
+ 	    gtk_main_quit();
+     }
+ }
+@@ -5303,13 +5303,13 @@
+ # ifdef HAVE_GTK2
+     if (font != NOFONT)
+     {
+-	char	*name = pango_font_description_to_string(font);
++	char	*pangoname = pango_font_description_to_string(font);
+ 
+-	if (name != NULL)
++	if (pangoname != NULL)
+ 	{
+-	    char_u	*s = vim_strsave((char_u *)name);
++	    char_u	*s = vim_strsave((char_u *)pangoname);
+ 
+-	    g_free(name);
++	    g_free(pangoname);
+ 	    return s;
+ 	}
+     }
+@@ -6241,24 +6241,20 @@
+ {
+     GdkGCValues values;
+     GdkGC *invert_gc;
+-    GdkColor foreground;
+-    GdkColor background;
+ 
+     if (gui.drawarea->window == NULL)
+ 	return;
+ 
+-    foreground.pixel = gui.norm_pixel ^ gui.back_pixel;
+-    background.pixel = gui.norm_pixel ^ gui.back_pixel;
+-
+-    values.foreground = foreground;
+-    values.background = background;
++    values.foreground.pixel = gui.norm_pixel ^ gui.back_pixel;
++    values.background.pixel = gui.norm_pixel ^ gui.back_pixel;
+     values.function = GDK_XOR;
+     invert_gc = gdk_gc_new_with_values(gui.drawarea->window,
+ 				       &values,
+ 				       GDK_GC_FOREGROUND |
+ 				       GDK_GC_BACKGROUND |
+ 				       GDK_GC_FUNCTION);
+-    gdk_gc_set_exposures(invert_gc, gui.visibility != GDK_VISIBILITY_UNOBSCURED);
++    gdk_gc_set_exposures(invert_gc, gui.visibility !=
++						   GDK_VISIBILITY_UNOBSCURED);
+     gdk_draw_rectangle(gui.drawarea->window, invert_gc,
+ 		       TRUE,
+ 		       FILL_X(c), FILL_Y(r),
+diff -Naur vim70.orig/src/gui_xmebw.c vim70/src/gui_xmebw.c
+--- vim70.orig/src/gui_xmebw.c	2006-04-30 08:32:32.000000000 -0700
++++ vim70/src/gui_xmebw.c	2006-07-14 08:51:21.000000000 -0700
+@@ -47,13 +47,13 @@
+ #include "gui_xmebwp.h"
+ 
+ /* Provide some missing wrappers, which are missed from the LessTif
+- * implementation.
++ * implementation.  Also missing in Motif 1.2 and earlier.
+  *
+  * We neither use XmeGetPixmapData or _XmGetPixmapData, since with LessTif the
+  * pixmap will not appear in it's caches properly. We cache the interresting
+  * values in XmEnhancedButtonPart instead ourself.
+  */
+-#ifdef LESSTIF_VERSION
++#if defined(LESSTIF_VERSION) || (XmVersion <= 1002)
+ # ifndef Lab_IsMenupane
+ #  define Lab_IsMenupane(w) (Lab_MenuType(w) == (int)XmMENU_POPUP || \
+ 		    Lab_MenuType(w) == (int)XmMENU_PULLDOWN)
+@@ -480,7 +480,7 @@
+ 	    || (eb->core.height <= 2 * eb->primitive.highlight_thickness))
+ 	return;
+ 
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+     {
+ 	XmDisplay	dpy;
+ 
+@@ -641,7 +641,7 @@
+     GC		tmp_gc = NULL;
+     Boolean	replaceGC = False;
+     Boolean	deadjusted = False;
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+     XmDisplay	dpy = (XmDisplay)XmGetXmDisplay(XtDisplay(eb));
+     Boolean	etched_in = dpy->display.enable_etched_in_menu;
+ #else
+@@ -726,7 +726,7 @@
+ 	if ((((ShellWidget) XtParent(XtParent(eb)))->shell.popped_up)
+ 		&& _XmGetInDragMode((Widget) eb))
+ 	{
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+ 	    XmDisplay dpy = (XmDisplay) XmGetXmDisplay(XtDisplay(wid));
+ 	    Boolean etched_in = dpy->display.enable_etched_in_menu;
+ #else
+@@ -810,7 +810,7 @@
+ 
+     if (Lab_IsMenupane(eb))
+     {
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+ 	XmDisplay dpy = (XmDisplay) XmGetXmDisplay(XtDisplay(wid));
+ 	Boolean etched_in = dpy->display.enable_etched_in_menu;
+ #else
+@@ -1150,7 +1150,7 @@
+ Redisplay(Widget w, XEvent *event, Region region)
+ {
+     XmEnhancedButtonWidget  eb = (XmEnhancedButtonWidget) w;
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+     XmDisplay		    dpy;
+     XtEnum		    default_button_emphasis;
+ #endif
+@@ -1162,7 +1162,7 @@
+     if (!XtIsRealized((Widget)eb))
+ 	return;
+ 
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+     dpy = (XmDisplay)XmGetXmDisplay(XtDisplay(eb));
+     default_button_emphasis = dpy->display.default_button_emphasis;
+ #endif
+@@ -1241,7 +1241,7 @@
+     {
+ 	int adjust = 0;
+ 
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+ 	/*
+ 	 *  NOTE: PushButton has two types of shadows: primitive-shadow and
+ 	 *  default-button-shadow.  If pushbutton is in a menu only primitive
+@@ -1289,7 +1289,7 @@
+ 			  adjust, adjust, rectwidth, rectheight, borderwidth);
+ 	    }
+ 
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+ 	    switch (default_button_emphasis)
+ 	    {
+ 		case XmINTERNAL_HIGHLIGHT:
+@@ -1365,7 +1365,7 @@
+ 		    default_button_shadow_thickness =
+ 			       eb->pushbutton.default_button_shadow_thickness;
+ 
+-#ifndef LESSTIF_VERSION
++#if !defined(LESSTIF_VERSION) && (XmVersion > 1002)
+ 		/*
+ 		 * Compute location of bounding box to contain the
+ 		 * defaultButtonShadow.
+diff -Naur vim70.orig/src/hardcopy.c vim70/src/hardcopy.c
+--- vim70.orig/src/hardcopy.c	2006-05-04 03:09:58.000000000 -0700
++++ vim70/src/hardcopy.c	2006-09-11 08:23:16.000000000 -0700
+@@ -1794,29 +1794,27 @@
+     static int
+ prt_resfile_next_line()
+ {
+-    int     index;
++    int     idx;
+ 
+     /* Move to start of next line and then find end of line */
+-    index = prt_resfile.line_end + 1;
+-    while (index < prt_resfile.len)
++    idx = prt_resfile.line_end + 1;
++    while (idx < prt_resfile.len)
+     {
+-	if (prt_resfile.buffer[index] != PSLF && prt_resfile.buffer[index]
+-									!= PSCR)
++	if (prt_resfile.buffer[idx] != PSLF && prt_resfile.buffer[idx] != PSCR)
+ 	    break;
+-	index++;
++	idx++;
+     }
+-    prt_resfile.line_start = index;
++    prt_resfile.line_start = idx;
+ 
+-    while (index < prt_resfile.len)
++    while (idx < prt_resfile.len)
+     {
+-	if (prt_resfile.buffer[index] == PSLF || prt_resfile.buffer[index]
+-									== PSCR)
++	if (prt_resfile.buffer[idx] == PSLF || prt_resfile.buffer[idx] == PSCR)
+ 	    break;
+-	index++;
++	idx++;
+     }
+-    prt_resfile.line_end = index;
++    prt_resfile.line_end = idx;
+ 
+-    return (index < prt_resfile.len);
++    return (idx < prt_resfile.len);
+ }
+ 
+     static int
+@@ -1837,14 +1835,14 @@
+ prt_resfile_skip_nonws(offset)
+     int     offset;
+ {
+-    int     index;
++    int     idx;
+ 
+-    index = prt_resfile.line_start + offset;
+-    while (index < prt_resfile.line_end)
++    idx = prt_resfile.line_start + offset;
++    while (idx < prt_resfile.line_end)
+     {
+-	if (isspace(prt_resfile.buffer[index]))
+-	    return index - prt_resfile.line_start;
+-	index++;
++	if (isspace(prt_resfile.buffer[idx]))
++	    return idx - prt_resfile.line_start;
++	idx++;
+     }
+     return -1;
+ }
+@@ -1853,14 +1851,14 @@
+ prt_resfile_skip_ws(offset)
+     int     offset;
+ {
+-    int     index;
++    int     idx;
+ 
+-    index = prt_resfile.line_start + offset;
+-    while (index < prt_resfile.line_end)
++    idx = prt_resfile.line_start + offset;
++    while (idx < prt_resfile.line_end)
+     {
+-	if (!isspace(prt_resfile.buffer[index]))
+-	    return index - prt_resfile.line_start;
+-	index++;
++	if (!isspace(prt_resfile.buffer[idx]))
++	    return idx - prt_resfile.line_start;
++	idx++;
+     }
+     return -1;
+ }
+@@ -2478,7 +2476,7 @@
+     char_u	*p_encoding;
+     struct prt_ps_encoding_S *p_mbenc;
+     struct prt_ps_encoding_S *p_mbenc_first;
+-    struct prt_ps_charset_S  *p_mbchar;
++    struct prt_ps_charset_S  *p_mbchar = NULL;
+ #endif
+ 
+ #if 0
+@@ -2516,7 +2514,6 @@
+     if (!(props & ENC_8BIT) && ((*p_pmcs != NUL) || !(props & ENC_UNICODE)))
+     {
+ 	p_mbenc_first = NULL;
+-	p_mbchar = NULL;
+ 	for (cmap = 0; cmap < NUM_ELEMENTS(prt_ps_mbfonts); cmap++)
+ 	    if (prt_match_encoding((char *)p_encoding, &prt_ps_mbfonts[cmap],
+ 								    &p_mbenc))
+diff -Naur vim70.orig/src/if_cscope.c vim70/src/if_cscope.c
+--- vim70.orig/src/if_cscope.c	2006-04-18 01:54:15.000000000 -0700
++++ vim70/src/if_cscope.c	2006-09-11 08:23:16.000000000 -0700
+@@ -989,8 +989,7 @@
+ {
+     int i;
+     char *cmd;
+-    char **matches, **contexts;
+-    int nummatches[CSCOPE_MAX_CONNECTIONS], totmatches, matched;
++    int nummatches[CSCOPE_MAX_CONNECTIONS], totmatches;
+ #ifdef FEAT_QUICKFIX
+     char cmdletter;
+     char *qfpos;
+@@ -1141,6 +1140,9 @@
+     else
+ #endif /* FEAT_QUICKFIX */
+     {
++	char **matches = NULL, **contexts = NULL;
++	int matched = 0;
++
+ 	/* read output */
+ 	cs_fill_results((char *)pat, totmatches, nummatches, &matches,
+ 							 &contexts, &matched);
+diff -Naur vim70.orig/src/if_perl.xs vim70/src/if_perl.xs
+--- vim70.orig/src/if_perl.xs	2006-03-06 10:57:16.000000000 -0800
++++ vim70/src/if_perl.xs	2006-08-19 16:39:02.000000000 -0700
+@@ -155,8 +155,8 @@
+ static int (*perl_run)(PerlInterpreter*);
+ static int (*perl_parse)(PerlInterpreter*, XSINIT_t, int, char**, char**);
+ static void* (*Perl_get_context)(void);
+-static void (*Perl_croak)(pTHX_ const char*, ...) __attribute__((noreturn));
+-static void (*Perl_croak_nocontext)(const char*, ...) __attribute__((noreturn));
++static void (*Perl_croak)(pTHX_ const char*, ...);
++static void (*Perl_croak_nocontext)(const char*, ...);
+ static I32 (*Perl_dowantarray)(pTHX);
+ static void (*Perl_free_tmps)(pTHX);
+ static HV* (*Perl_gv_stashpv)(pTHX_ const char*, I32);
+@@ -1056,7 +1056,6 @@
+     int i;
+     long lnum;
+     char *line;
+-    buf_T *savebuf;
+     PPCODE:
+     if (buf_valid(vimbuf))
+     {
+@@ -1069,14 +1068,20 @@
+ 	    line = SvPV(ST(i),PL_na);
+ 	    if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count && line != NULL)
+ 	    {
+-		savebuf = curbuf;
+-		curbuf = vimbuf;
++		aco_save_T	aco;
++
++		/* set curwin/curbuf for "vimbuf" and save some things */
++		aucmd_prepbuf(&aco, vimbuf);
++
+ 		if (u_savesub(lnum) == OK)
+ 		{
+ 		    ml_replace(lnum, (char_u *)line, TRUE);
+ 		    changed_bytes(lnum, 0);
+ 		}
+-		curbuf = savebuf;
++
++		/* restore curwin/curbuf and a few other things */
++		aucmd_restbuf(&aco);
++		/* Careful: autocommands may have made "vimbuf" invalid! */
+ 	    }
+ 	}
+     }
+@@ -1087,7 +1092,6 @@
+ 
+     PREINIT:
+     long i, lnum = 0, count = 0;
+-    buf_T *savebuf;
+     PPCODE:
+     if (buf_valid(vimbuf))
+     {
+@@ -1114,16 +1118,23 @@
+ 	    {
+ 		if (lnum > 0 && lnum <= vimbuf->b_ml.ml_line_count)
+ 		{
+-		    savebuf = curbuf;
+-		    curbuf = vimbuf;
++		    aco_save_T	aco;
++
++		    /* set curwin/curbuf for "vimbuf" and save some things */
++		    aucmd_prepbuf(&aco, vimbuf);
++
+ 		    if (u_savedel(lnum, 1) == OK)
+ 		    {
+ 			ml_delete(lnum, 0);
+ 			deleted_lines_mark(lnum, 1L);
+-			if (savebuf == curbuf)
++			if (aco.save_buf == curbuf)
+ 			    check_cursor();
+ 		    }
+-		    curbuf = savebuf;
++
++		    /* restore curwin/curbuf and a few other things */
++		    aucmd_restbuf(&aco);
++		    /* Careful: autocommands may have made "vimbuf" invalid! */
++
+ 		    update_curbuf(VALID);
+ 		}
+ 	    }
+@@ -1138,7 +1149,6 @@
+     int		i;
+     long	lnum;
+     char	*line;
+-    buf_T	*savebuf;
+     PPCODE:
+     if (buf_valid(vimbuf))
+     {
+@@ -1151,14 +1161,21 @@
+ 	    line = SvPV(ST(i),PL_na);
+ 	    if (lnum >= 0 && lnum <= vimbuf->b_ml.ml_line_count && line != NULL)
+ 	    {
+-		savebuf = curbuf;
+-		curbuf = vimbuf;
++		aco_save_T	aco;
++
++		/* set curwin/curbuf for "vimbuf" and save some things */
++		aucmd_prepbuf(&aco, vimbuf);
++
+ 		if (u_inssub(lnum + 1) == OK)
+ 		{
+ 		    ml_append(lnum, (char_u *)line, (colnr_T)0, FALSE);
+ 		    appended_lines_mark(lnum, 1L);
+ 		}
+-		curbuf = savebuf;
++
++		/* restore curwin/curbuf and a few other things */
++		aucmd_restbuf(&aco);
++		/* Careful: autocommands may have made "vimbuf" invalid! */
++
+ 		update_curbuf(VALID);
+ 	    }
+ 	}
+diff -Naur vim70.orig/src/if_ruby.c vim70/src/if_ruby.c
+--- vim70.orig/src/if_ruby.c	2006-04-30 08:37:52.000000000 -0700
++++ vim70/src/if_ruby.c	2006-08-19 16:39:01.000000000 -0700
+@@ -643,11 +643,14 @@
+ 
+ static VALUE set_buffer_line(buf_T *buf, linenr_T n, VALUE str)
+ {
+-    buf_T *savebuf = curbuf;
+-    char *line = STR2CSTR(str);
++    char	*line = STR2CSTR(str);
++    aco_save_T	aco;
++
++    if (n > 0 && n <= buf->b_ml.ml_line_count && line != NULL)
++    {
++	/* set curwin/curbuf for "buf" and save some things */
++	aucmd_prepbuf(&aco, buf);
+ 
+-    if (n > 0 && n <= buf->b_ml.ml_line_count && line != NULL) {
+-	curbuf = buf;
+ 	if (u_savesub(n) == OK) {
+ 	    ml_replace(n, (char_u *)line, TRUE);
+ 	    changed();
+@@ -655,10 +658,15 @@
+ 	    syn_changed(n); /* recompute syntax hl. for this line */
+ #endif
+ 	}
+-	curbuf = savebuf;
++
++	/* restore curwin/curbuf and a few other things */
++	aucmd_restbuf(&aco);
++	/* Careful: autocommands may have made "buf" invalid! */
++
+ 	update_curbuf(NOT_VALID);
+     }
+-    else {
++    else
++    {
+ 	rb_raise(rb_eIndexError, "index %d out of buffer", n);
+ 	return Qnil; /* For stop warning */
+     }
+@@ -676,12 +684,15 @@
+ 
+ static VALUE buffer_delete(VALUE self, VALUE num)
+ {
+-    buf_T *buf = get_buf(self);
+-    buf_T *savebuf = curbuf;
+-    long n = NUM2LONG(num);
++    buf_T	*buf = get_buf(self);
++    long	n = NUM2LONG(num);
++    aco_save_T	aco;
++
++    if (n > 0 && n <= buf->b_ml.ml_line_count)
++    {
++	/* set curwin/curbuf for "buf" and save some things */
++	aucmd_prepbuf(&aco, buf);
+ 
+-    if (n > 0 && n <= buf->b_ml.ml_line_count) {
+-	curbuf = buf;
+ 	if (u_savedel(n, 1) == OK) {
+ 	    ml_delete(n, 0);
+ 
+@@ -691,10 +702,15 @@
+ 
+ 	    changed();
+ 	}
+-	curbuf = savebuf;
++
++	/* restore curwin/curbuf and a few other things */
++	aucmd_restbuf(&aco);
++	/* Careful: autocommands may have made "buf" invalid! */
++
+ 	update_curbuf(NOT_VALID);
+     }
+-    else {
++    else
++    {
+ 	rb_raise(rb_eIndexError, "index %d out of buffer", n);
+     }
+     return Qnil;
+@@ -702,13 +718,16 @@
+ 
+ static VALUE buffer_append(VALUE self, VALUE num, VALUE str)
+ {
+-    buf_T *buf = get_buf(self);
+-    buf_T *savebuf = curbuf;
+-    char *line = STR2CSTR(str);
+-    long n = NUM2LONG(num);
++    buf_T	*buf = get_buf(self);
++    char	*line = STR2CSTR(str);
++    long	n = NUM2LONG(num);
++    aco_save_T	aco;
++
++    if (n >= 0 && n <= buf->b_ml.ml_line_count && line != NULL)
++    {
++	/* set curwin/curbuf for "buf" and save some things */
++	aucmd_prepbuf(&aco, buf);
+ 
+-    if (n >= 0 && n <= buf->b_ml.ml_line_count && line != NULL) {
+-	curbuf = buf;
+ 	if (u_inssub(n + 1) == OK) {
+ 	    ml_append(n, (char_u *) line, (colnr_T) 0, FALSE);
+ 
+@@ -718,7 +737,11 @@
+ 
+ 	    changed();
+ 	}
+-	curbuf = savebuf;
++
++	/* restore curwin/curbuf and a few other things */
++	aucmd_restbuf(&aco);
++	/* Careful: autocommands may have made "buf" invalid! */
++
+ 	update_curbuf(NOT_VALID);
+     }
+     else {
+diff -Naur vim70.orig/src/macros.h vim70/src/macros.h
+--- vim70.orig/src/macros.h	2006-03-01 04:01:10.000000000 -0800
++++ vim70/src/macros.h	2006-09-11 09:01:59.000000000 -0700
+@@ -276,3 +276,9 @@
+ # define MB_CHARLEN(p)		STRLEN(p)
+ # define PTR2CHAR(p)		((int)*(p))
+ #endif
++
++#ifdef FEAT_AUTOCHDIR
++# define DO_AUTOCHDIR if (p_acd) do_autochdir();
++#else
++# define DO_AUTOCHDIR
++#endif
+diff -Naur vim70.orig/src/main.c vim70/src/main.c
+--- vim70.orig/src/main.c	2006-05-03 10:36:44.000000000 -0700
++++ vim70/src/main.c	2006-09-11 09:00:04.000000000 -0700
+@@ -564,7 +564,11 @@
+      */
+     if (p_lpl)
+     {
++# ifdef VMS	/* Somehow VMS doesn't handle the "**". */
++	source_runtime((char_u *)"plugin/*.vim", TRUE);
++# else
+ 	source_runtime((char_u *)"plugin/**/*.vim", TRUE);
++# endif
+ 	TIME_MSG("loading plugins");
+     }
+ #endif
+@@ -1126,6 +1130,16 @@
+ 	 */
+ 	update_curswant();
+ 
++#ifdef FEAT_EVAL
++	/*
++	 * May perform garbage collection when waiting for a character, but
++	 * only at the very toplevel.  Otherwise we may be using a List or
++	 * Dict internally somewhere.
++	 * "may_garbage_collect" is reset in vgetc() which is invoked through
++	 * do_exmode() and normal_cmd().
++	 */
++	may_garbage_collect = (!cmdwin && !noexmode);
++#endif
+ 	/*
+ 	 * If we're invoked as ex, do a round of ex commands.
+ 	 * Otherwise, get and execute a normal mode command.
+@@ -2281,7 +2295,7 @@
+     mparm_T	*parmp;
+ {
+ #ifdef FEAT_WINDOWS
+-    int		rewind;
++    int		dorewind;
+     int		done = 0;
+ 
+     /*
+@@ -2338,10 +2352,10 @@
+ 	++autocmd_no_leave;
+ #endif
+ #ifdef FEAT_WINDOWS
+-	rewind = TRUE;
++	dorewind = TRUE;
+ 	while (done++ < 1000)
+ 	{
+-	    if (rewind)
++	    if (dorewind)
+ 	    {
+ 		if (parmp->window_layout == WIN_TABS)
+ 		    goto_tabpage(1);
+@@ -2360,7 +2374,7 @@
+ 		    break;
+ 		curwin = curwin->w_next;
+ 	    }
+-	    rewind = FALSE;
++	    dorewind = FALSE;
+ #endif
+ 	    curbuf = curwin->w_buffer;
+ 	    if (curbuf->b_ml.ml_mfp == NULL)
+@@ -2381,7 +2395,7 @@
+ 		check_swap_exists_action();
+ #endif
+ #ifdef FEAT_AUTOCMD
+-		rewind = TRUE;		/* start again */
++		dorewind = TRUE;		/* start again */
+ #endif
+ 	    }
+ #ifdef FEAT_WINDOWS
+@@ -3208,10 +3222,15 @@
+      * Register for remote command execution with :serversend and --remote
+      * unless there was a -X or a --servername '' on the command line.
+      * Only register nongui-vim's with an explicit --servername argument.
++     * When running as root --servername is also required.
+      */
+     if (X_DISPLAY != NULL && parmp->servername != NULL && (
+ #  ifdef FEAT_GUI
+-		gui.in_use ||
++		(gui.in_use
++#   ifdef UNIX
++		 && getuid() != 0
++#   endif
++		) ||
+ #  endif
+ 		parmp->serverName_arg != NULL))
+     {
+diff -Naur vim70.orig/src/Makefile vim70/src/Makefile
+--- vim70.orig/src/Makefile	2006-05-07 06:25:27.000000000 -0700
++++ vim70/src/Makefile	2006-09-11 08:57:41.000000000 -0700
+@@ -2177,6 +2177,7 @@
+ 	cd $(SHADOWDIR)/xxd; ln -s ../../xxd/*.[ch] ../../xxd/Make* .
+ 	if test -d $(RSRC_DIR); then \
+ 		cd $(SHADOWDIR); \
++		ln -s ../infplist.xml .; \
+ 		ln -s ../$(RSRC_DIR) ../os_mac.rsr.hqx ../dehqx.py .; \
+ 	fi
+ 	mkdir $(SHADOWDIR)/testdir
+@@ -2260,7 +2261,7 @@
+ auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in
+ 	CC="$(CC) $(OSDEF_CFLAGS)" srcdir=$(srcdir) sh $(srcdir)/osdef.sh
+ 
+-QUOTESED = sed -e 's/"/\\"/g' -e 's/\\"/"/' -e 's/\\";$$/";/'
++QUOTESED = sed -e 's/[\\"]/\\&/g' -e 's/\\"/"/' -e 's/\\";$$/";/'
+ auto/pathdef.c: Makefile auto/config.mk
+ 	-@echo creating $@
+ 	-@echo '/* pathdef.c */' > $@
+diff -Naur vim70.orig/src/mbyte.c vim70/src/mbyte.c
+--- vim70.orig/src/mbyte.c	2006-04-30 04:51:01.000000000 -0700
++++ vim70/src/mbyte.c	2006-09-11 08:23:16.000000000 -0700
+@@ -311,7 +311,11 @@
+ 
+ #define IDX_MACROMAN	57
+     {"macroman",	ENC_8BIT + ENC_MACROMAN, 0},	/* Mac OS */
+-#define IDX_COUNT	58
++#define IDX_DECMCS	58
++    {"dec-mcs",		ENC_8BIT,		0},	/* DEC MCS */
++#define IDX_HPROMAN8	59
++    {"hp-roman8",	ENC_8BIT,		0},	/* HP Roman8 */
++#define IDX_COUNT	60
+ };
+ 
+ /*
+@@ -359,6 +363,8 @@
+     {"932",		IDX_CP932},
+     {"949",		IDX_CP949},
+     {"936",		IDX_CP936},
++    {"gbk",		IDX_CP936},
++    {"gb18030",		IDX_CP936},	/* only 99% the same */
+     {"950",		IDX_CP950},
+     {"eucjp",		IDX_EUC_JP},
+     {"unix-jis",	IDX_EUC_JP},
+@@ -386,6 +392,7 @@
+     {"950",		IDX_BIG5},
+ #endif
+     {"mac",		IDX_MACROMAN},
++    {"mac-roman",	IDX_MACROMAN},
+     {NULL,		0}
+ };
+ 
+@@ -3507,6 +3514,11 @@
+ 	add_to_input_buf(delkey, (int)sizeof(delkey));
+ }
+ 
++/*
++ * Move the cursor left by "num_move_back" characters.
++ * Note that ins_left() checks im_is_preediting() to avoid breaking undo for
++ * these K_LEFT keys.
++ */
+     static void
+ im_correct_cursor(int num_move_back)
+ {
+@@ -3734,8 +3746,7 @@
+     }
+     else if (cursor_index == 0 && preedit_string[0] == '\0')
+     {
+-	if (preedit_start_col == MAXCOL)
+-	    xim_has_preediting = FALSE;
++	xim_has_preediting = FALSE;
+ 
+ 	/* If at the start position (after typing backspace)
+ 	 * preedit_start_col must be reset. */
+@@ -3850,13 +3861,13 @@
+ 
+     if (preedit_string != NULL && attr_list != NULL)
+     {
+-	int index;
++	int idx;
+ 
+ 	/* Get the byte index as used by PangoAttrIterator */
+-	for (index = 0; col > 0 && preedit_string[index] != '\0'; --col)
+-	    index += utfc_ptr2len((char_u *)preedit_string + index);
++	for (idx = 0; col > 0 && preedit_string[idx] != '\0'; --col)
++	    idx += utfc_ptr2len((char_u *)preedit_string + idx);
+ 
+-	if (preedit_string[index] != '\0')
++	if (preedit_string[idx] != '\0')
+ 	{
+ 	    PangoAttrIterator	*iter;
+ 	    int			start, end;
+@@ -3869,7 +3880,7 @@
+ 	    {
+ 		pango_attr_iterator_range(iter, &start, &end);
+ 
+-		if (index >= start && index < end)
++		if (idx >= start && idx < end)
+ 		    char_attr |= translate_pango_attributes(iter);
+ 	    }
+ 	    while (pango_attr_iterator_next(iter));
+diff -Naur vim70.orig/src/memline.c vim70/src/memline.c
+--- vim70.orig/src/memline.c	2006-04-20 14:00:21.000000000 -0700
++++ vim70/src/memline.c	2006-09-11 08:23:16.000000000 -0700
+@@ -215,7 +215,7 @@
+ #define ML_FLUSH	0x02	    /* flush locked block */
+ #define ML_SIMPLE(x)	(x & 0x10)  /* DEL, INS or FIND */
+ 
+-static void ml_upd_block0 __ARGS((buf_T *buf, int setfname));
++static void ml_upd_block0 __ARGS((buf_T *buf, int set_fname));
+ static void set_b0_fname __ARGS((ZERO_BL *, buf_T *buf));
+ static void set_b0_dir_flag __ARGS((ZERO_BL *b0p, buf_T *buf));
+ #ifdef FEAT_MBYTE
+@@ -679,9 +679,9 @@
+  * Update the timestamp or the B0_SAME_DIR flag of the .swp file.
+  */
+     static void
+-ml_upd_block0(buf, setfname)
++ml_upd_block0(buf, set_fname)
+     buf_T	*buf;
+-    int		setfname;
++    int		set_fname;
+ {
+     memfile_T	*mfp;
+     bhdr_T	*hp;
+@@ -695,7 +695,7 @@
+ 	EMSG(_("E304: ml_upd_block0(): Didn't get block 0??"));
+     else
+     {
+-	if (setfname)
++	if (set_fname)
+ 	    set_b0_fname(b0p, buf);
+ 	else
+ 	    set_b0_dir_flag(b0p, buf);
+diff -Naur vim70.orig/src/menu.c vim70/src/menu.c
+--- vim70.orig/src/menu.c	2006-05-03 10:30:48.000000000 -0700
++++ vim70/src/menu.c	2006-08-19 16:40:11.000000000 -0700
+@@ -511,6 +511,14 @@
+ 	 * name (without mnemonic and accelerator text). */
+ 	next_name = menu_name_skip(name);
+ 	dname = menu_text(name, NULL, NULL);
++	if (dname == NULL)
++	    goto erret;
++	if (*dname == NUL)
++	{
++	    /* Only a mnemonic or accelerator is not valid. */
++	    EMSG(_("E792: Empty menu name"));
++	    goto erret;
++	}
+ 
+ 	/* See if it's already there */
+ 	lower_pri = menup;
+@@ -704,6 +712,7 @@
+ 	parent = menu;
+ 	name = next_name;
+ 	vim_free(dname);
++	dname = NULL;
+ 	if (pri_tab[pri_idx + 1] != -1)
+ 	    ++pri_idx;
+     }
+@@ -793,6 +802,22 @@
+ erret:
+     vim_free(path_name);
+     vim_free(dname);
++
++    /* Delete any empty submenu we added before discovering the error.  Repeat
++     * for higher levels. */
++    while (parent != NULL && parent->children == NULL)
++    {
++	if (parent->parent == NULL)
++	    menup = &root_menu;
++	else
++	    menup = &parent->parent->children;
++	for ( ; *menup != NULL && *menup != parent; menup = &((*menup)->next))
++	    ;
++	if (*menup == NULL) /* safety check */
++	    break;
++	parent = parent->parent;
++	free_menu(menup);
++    }
+     return FAIL;
+ }
+ 
+@@ -1753,6 +1778,27 @@
+ }
+ 
+ /*
++ * Check that a pointer appears in the menu tree.  Used to protect from using
++ * a menu that was deleted after it was selected but before the event was
++ * handled.
++ * Return OK or FAIL.  Used recursively.
++ */
++    int
++check_menu_pointer(root, menu_to_check)
++    vimmenu_T *root;
++    vimmenu_T *menu_to_check;
++{
++    vimmenu_T	*p;
++
++    for (p = root; p != NULL; p = p->next)
++	if (p == menu_to_check
++		|| (p->children != NULL
++		    && check_menu_pointer(p->children, menu_to_check) == OK))
++	    return OK;
++    return FAIL;
++}
++
++/*
+  * After we have started the GUI, then we can create any menus that have been
+  * defined.  This is done once here.  add_menu_path() may have already been
+  * called to define these menus, and may be called again.  This function calls
+diff -Naur vim70.orig/src/message.c vim70/src/message.c
+--- vim70.orig/src/message.c	2006-05-06 13:07:37.000000000 -0700
++++ vim70/src/message.c	2006-09-11 08:59:06.000000000 -0700
+@@ -1925,7 +1925,8 @@
+ 	     * If screen is completely filled and 'more' is set then wait
+ 	     * for a character.
+ 	     */
+-	    if (p_more && --lines_left == 0 && State != HITRETURN
++	    --lines_left;
++	    if (p_more && lines_left == 0 && State != HITRETURN
+ 					    && !msg_no_more && !exmode_active)
+ 	    {
+ #ifdef FEAT_CON_DIALOG
+@@ -4175,15 +4176,16 @@
+ 			str_arg_l = 0;
+ 		    else
+ 		    {
+-			/* memchr on HP does not like n > 2^31  !!! */
+-			char *q = memchr(str_arg, '\0',
++			/* Don't put the #if inside memchr(), it can be a
++			 * macro. */
+ #if SIZEOF_INT <= 2
+-				precision
++			char *q = memchr(str_arg, '\0', precision);
+ #else
+-				precision <= (size_t)0x7fffffffL ? precision
+-						       : (size_t)0x7fffffffL
++			/* memchr on HP does not like n > 2^31  !!! */
++			char *q = memchr(str_arg, '\0',
++				  precision <= (size_t)0x7fffffffL ? precision
++						       : (size_t)0x7fffffffL);
+ #endif
+-						       );
+ 			str_arg_l = (q == NULL) ? precision : q - str_arg;
+ 		    }
+ 		    break;
+diff -Naur vim70.orig/src/misc1.c vim70/src/misc1.c
+--- vim70.orig/src/misc1.c	2006-04-30 08:30:02.000000000 -0700
++++ vim70/src/misc1.c	2006-09-11 09:03:25.000000000 -0700
+@@ -3016,6 +3016,7 @@
+     int		len = 0;
+     int		n;
+     int		save_mapped_ctrl_c = mapped_ctrl_c;
++    int		waited = 0;
+ 
+     mapped_ctrl_c = FALSE;	/* mappings are not used here */
+     for (;;)
+@@ -3034,11 +3035,16 @@
+ 	    /* Replace zero and CSI by a special key code. */
+ 	    n = fix_input_buffer(buf + len, n, FALSE);
+ 	    len += n;
++	    waited = 0;
+ 	}
++	else if (len > 0)
++	    ++waited;	    /* keep track of the waiting time */
+ 
+-	/* incomplete termcode: get more characters */
+-	if ((n = check_termcode(1, buf, len)) < 0)
++	/* Incomplete termcode and not timed out yet: get more characters */
++	if ((n = check_termcode(1, buf, len)) < 0
++	       && (!p_ttimeout || waited * 100L < (p_ttm < 0 ? p_tm : p_ttm)))
+ 	    continue;
++
+ 	/* found a termcode: adjust length */
+ 	if (n > 0)
+ 	    len = n;
+@@ -3196,14 +3202,12 @@
+     else
+ 	MSG_PUTS(_("Choice number (<Enter> cancels): "));
+ 
+-    /* Set the state such that text can be selected/copied/pasted. */
++    /* Set the state such that text can be selected/copied/pasted and we still
++     * get mouse events. */
+     save_cmdline_row = cmdline_row;
+-    cmdline_row = Rows - 1;
++    cmdline_row = 0;
+     save_State = State;
+-    if (mouse_used == NULL)
+-	State = CMDLINE;
+-    else
+-	State = NORMAL;
++    State = CMDLINE;
+ 
+     i = get_number(TRUE, mouse_used);
+     if (KeyTyped)
+@@ -4492,7 +4496,7 @@
+ 		int l = mb_ptr2len(s);
+ 
+ 		while (--l > 0)
+-		    *d++ = *s++;
++		    *d++ = *++s;
+ 	    }
+ # endif
+ 	}
+diff -Naur vim70.orig/src/netbeans.c vim70/src/netbeans.c
+--- vim70.orig/src/netbeans.c	2006-04-22 11:00:05.000000000 -0700
++++ vim70/src/netbeans.c	2006-09-11 08:23:16.000000000 -0700
+@@ -103,7 +103,7 @@
+ static int  inputHandler = -1;		/* simply ret.value of WSAAsyncSelect() */
+ extern HWND s_hwnd;			/* Gvim's Window handle */
+ #endif
+-static int cmdno;			/* current command number for reply */
++static int r_cmdno;			/* current command number for reply */
+ static int haveConnection = FALSE;	/* socket is connected and
+ 					   initialization is done */
+ #ifdef FEAT_GUI_MOTIF
+@@ -832,11 +832,11 @@
+ 	return;
+     }
+ 
+-    cmdno = strtol(q, &q, 10);
++    r_cmdno = strtol(q, &q, 10);
+ 
+     q = (char *)skipwhite((char_u *)q);
+ 
+-    if (nb_do_cmd(bufno, (char_u *)verb, isfunc, cmdno, (char_u *)q) == FAIL)
++    if (nb_do_cmd(bufno, (char_u *)verb, isfunc, r_cmdno, (char_u *)q) == FAIL)
+     {
+ #ifdef NBDEBUG
+ 	/*
+@@ -1008,11 +1008,11 @@
+ 	if (netbeansForcedQuit)
+ 	{
+ 	    /* mark as unmodified so NetBeans won't put up dialog on "killed" */
+-	    sprintf(buf, "%d:unmodified=%d\n", i, cmdno);
++	    sprintf(buf, "%d:unmodified=%d\n", i, r_cmdno);
+ 	    nbdebug(("EVT: %s", buf));
+ 	    nb_send(buf, "netbeans_end");
+ 	}
+-	sprintf(buf, "%d:killed=%d\n", i, cmdno);
++	sprintf(buf, "%d:killed=%d\n", i, r_cmdno);
+ 	nbdebug(("EVT: %s", buf));
+ /*	nb_send(buf, "netbeans_end");    avoid "write failed" messages */
+ 	if (sd >= 0)
+@@ -1986,6 +1986,8 @@
+ 	    if (buf->bufp != NULL)
+ 		do_buffer(DOBUF_WIPE, DOBUF_FIRST, FORWARD,
+ 						     buf->bufp->b_fnum, TRUE);
++	    buf->bufp = NULL;
++	    buf->initDone = FALSE;
+ 	    doupdate = 1;
+ /* =====================================================================*/
+ 	}
+@@ -2561,7 +2563,7 @@
+ 	    if (p != NULL)
+ 	    {
+ 		vim_snprintf(buf, sizeof(buf),
+-				       "0:balloonText=%d \"%s\"\n", cmdno, p);
++				       "0:balloonText=%d \"%s\"\n", r_cmdno, p);
+ 		vim_free(p);
+ 	    }
+ 	    nbdebug(("EVT: %s", buf));
+@@ -2615,7 +2617,7 @@
+ 
+     if (haveConnection)
+     {
+-	sprintf(buf, "0:disconnect=%d\n", cmdno);
++	sprintf(buf, "0:disconnect=%d\n", r_cmdno);
+ 	nbdebug(("EVT: %s", buf));
+ 	nb_send(buf, "netbeans_disconnect");
+     }
+@@ -2634,7 +2636,7 @@
+ 	return;
+ 
+     sprintf(buf, "0:geometry=%d %d %d %d %d\n",
+-		    cmdno, (int)Columns, (int)Rows, new_x, new_y);
++		    r_cmdno, (int)Columns, (int)Rows, new_x, new_y);
+     /*nbdebug(("EVT: %s", buf)); happens too many times during a move */
+     nb_send(buf, "netbeans_frame_moved");
+ }
+@@ -2743,7 +2745,7 @@
+     if (bufno <= 0)
+ 	return;
+ 
+-    sprintf(buffer, "%d:killed=%d\n", bufno, cmdno);
++    sprintf(buffer, "%d:killed=%d\n", bufno, r_cmdno);
+ 
+     nbdebug(("EVT: %s", buffer));
+ 
+@@ -2817,7 +2819,8 @@
+     if (p != NULL)
+     {
+ 	buf = alloc(128 + 2*newlen);
+-	sprintf((char *)buf, "%d:insert=%d %ld \"%s\"\n", bufno, cmdno, off, p);
++	sprintf((char *)buf, "%d:insert=%d %ld \"%s\"\n",
++						      bufno, r_cmdno, off, p);
+ 	nbdebug(("EVT: %s", buf));
+ 	nb_send((char *)buf, "netbeans_inserted");
+ 	vim_free(p);
+@@ -2859,7 +2862,7 @@
+ 
+     off = pos2off(bufp, &pos);
+ 
+-    sprintf((char *)buf, "%d:remove=%d %ld %ld\n", bufno, cmdno, off, len);
++    sprintf((char *)buf, "%d:remove=%d %ld %ld\n", bufno, r_cmdno, off, len);
+     nbdebug(("EVT: %s", buf));
+     nb_send((char *)buf, "netbeans_removed");
+ }
+@@ -2884,7 +2887,7 @@
+ 
+     nbbuf->modified = 0;
+ 
+-    sprintf((char *)buf, "%d:unmodified=%d\n", bufno, cmdno);
++    sprintf((char *)buf, "%d:unmodified=%d\n", bufno, r_cmdno);
+     nbdebug(("EVT: %s", buf));
+     nb_send((char *)buf, "netbeans_unmodified");
+ #endif
+@@ -2908,11 +2911,11 @@
+ 	long off = pos2off(curbuf, &curwin->w_cursor);
+ 
+ 	/* sync the cursor position */
+-	sprintf(buf, "%d:newDotAndMark=%d %ld %ld\n", bufno, cmdno, off, off);
++	sprintf(buf, "%d:newDotAndMark=%d %ld %ld\n", bufno, r_cmdno, off, off);
+ 	nbdebug(("EVT: %s", buf));
+ 	nb_send(buf, "netbeans_button_release[newDotAndMark]");
+ 
+-	sprintf(buf, "%d:buttonRelease=%d %d %ld %d\n", bufno, cmdno,
++	sprintf(buf, "%d:buttonRelease=%d %d %ld %d\n", bufno, r_cmdno,
+ 				    button, (long)curwin->w_cursor.lnum, col);
+ 	nbdebug(("EVT: %s", buf));
+ 	nb_send(buf, "netbeans_button_release");
+@@ -2973,7 +2976,7 @@
+ 
+     /* sync the cursor position */
+     off = pos2off(curbuf, &curwin->w_cursor);
+-    sprintf(buf, "%d:newDotAndMark=%d %ld %ld\n", bufno, cmdno, off, off);
++    sprintf(buf, "%d:newDotAndMark=%d %ld %ld\n", bufno, r_cmdno, off, off);
+     nbdebug(("EVT: %s", buf));
+     nb_send(buf, "netbeans_keycommand");
+ 
+@@ -2984,13 +2987,13 @@
+ 
+     /* now send keyCommand event */
+     vim_snprintf(buf, sizeof(buf), "%d:keyCommand=%d \"%s\"\n",
+-						       bufno, cmdno, keyName);
++						     bufno, r_cmdno, keyName);
+     nbdebug(("EVT: %s", buf));
+     nb_send(buf, "netbeans_keycommand");
+ 
+     /* New: do both at once and include the lnum/col. */
+     vim_snprintf(buf, sizeof(buf), "%d:keyAtPos=%d \"%s\" %ld %ld/%ld\n",
+-	    bufno, cmdno, keyName,
++	    bufno, r_cmdno, keyName,
+ 		off, (long)curwin->w_cursor.lnum, (long)curwin->w_cursor.col);
+     nbdebug(("EVT: %s", buf));
+     nb_send(buf, "netbeans_keycommand");
+@@ -3013,7 +3016,7 @@
+ 
+     nbbuf->modified = 0;
+ 
+-    sprintf((char *)buf, "%d:save=%d\n", bufno, cmdno);
++    sprintf((char *)buf, "%d:save=%d\n", bufno, r_cmdno);
+     nbdebug(("EVT: %s", buf));
+     nb_send((char *)buf, "netbeans_save_buffer");
+ }
+@@ -3037,7 +3040,7 @@
+     if (nbbuf->insertDone)
+ 	nbbuf->modified = 1;
+ 
+-    sprintf((char *)buf, "%d:remove=%d 0 -1\n", bufno, cmdno);
++    sprintf((char *)buf, "%d:remove=%d 0 -1\n", bufno, r_cmdno);
+     nbdebug(("EVT(suppressed): %s", buf));
+ /*     nb_send(buf, "netbeans_deleted_all_lines"); */
+ }
+diff -Naur vim70.orig/src/normal.c vim70/src/normal.c
+--- vim70.orig/src/normal.c	2006-04-29 06:11:18.000000000 -0700
++++ vim70/src/normal.c	2006-09-11 08:23:16.000000000 -0700
+@@ -2504,7 +2504,8 @@
+ 	     * NOTE: Ignore right button down and drag mouse events.
+ 	     * Windows only shows the popup menu on the button up event.
+ 	     */
+-#if defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_PHOTON)
++#if defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_GTK) \
++			  || defined(FEAT_GUI_PHOTON) || defined(FEAT_GUI_MAC)
+ 	    if (!is_click)
+ 		return FALSE;
+ #endif
+@@ -4126,7 +4127,7 @@
+     int		save_p_ws;
+     int		save_p_scs;
+     int		retval = OK;
+-    int		incl;
++    int		incll;
+ 
+     if ((pat = alloc(len + 7)) == NULL)
+ 	return FAIL;
+@@ -4146,7 +4147,7 @@
+      * With "gd" Search back for the start of the current function, then go
+      * back until a blank line.  If this fails go to line 1.
+      */
+-    if (!locally || !findpar(&incl, BACKWARD, 1L, '{', FALSE))
++    if (!locally || !findpar(&incll, BACKWARD, 1L, '{', FALSE))
+     {
+ 	setpcmark();			/* Set in findpar() otherwise */
+ 	curwin->w_cursor.lnum = 1;
+diff -Naur vim70.orig/src/ops.c vim70/src/ops.c
+--- vim70.orig/src/ops.c	2006-04-30 08:13:44.000000000 -0700
++++ vim70/src/ops.c	2006-08-09 08:33:53.000000000 -0700
+@@ -2413,6 +2413,7 @@
+ 	else
+ 	{
+ 	    curwin->w_cursor = oap->end;
++	    check_cursor_col();
+ 
+ 	    /* Works just like an 'i'nsert on the next character. */
+ 	    if (!lineempty(curwin->w_cursor.lnum)
+@@ -3492,8 +3493,15 @@
+ # endif
+ 	if (flags & PUT_CURSEND)
+ 	{
++	    colnr_T len;
++
+ 	    curwin->w_cursor = curbuf->b_op_end;
+ 	    curwin->w_cursor.col++;
++
++	    /* in Insert mode we might be after the NUL, correct for that */
++	    len = (colnr_T)STRLEN(ml_get_curline());
++	    if (curwin->w_cursor.col > len)
++		curwin->w_cursor.col = len;
+ 	}
+ 	else
+ 	    curwin->w_cursor.lnum = lnum;
+diff -Naur vim70.orig/src/option.c vim70/src/option.c
+--- vim70.orig/src/option.c	2006-05-03 10:32:28.000000000 -0700
++++ vim70/src/option.c	2006-09-11 09:01:59.000000000 -0700
+@@ -2294,7 +2294,7 @@
+ 			    {(char_u *)0L, (char_u *)0L}
+ #endif
+ 			    },
+-    {"spellsuggest", "sps", P_STRING|P_VI_DEF|P_EXPAND|P_SECURE,
++    {"spellsuggest", "sps", P_STRING|P_VI_DEF|P_EXPAND|P_SECURE|P_COMMA,
+ #ifdef FEAT_SPELL
+ 			    (char_u *)&p_sps, PV_NONE,
+ 			    {(char_u *)"best", (char_u *)0L}
+@@ -5227,13 +5227,13 @@
+ 	    case PV_STL:	return &curwin->w_p_stl_flags;
+ #endif
+ #ifdef FEAT_EVAL
++# ifdef FEAT_FOLDING
+ 	    case PV_FDE:	return &curwin->w_p_fde_flags;
+ 	    case PV_FDT:	return &curwin->w_p_fdt_flags;
++# endif
+ # ifdef FEAT_BEVAL
+ 	    case PV_BEXPR:	return &curbuf->b_p_bexpr_flags;
+ # endif
+-#endif
+-#if defined(FEAT_EVAL)
+ # if defined(FEAT_CINDENT)
+ 	    case PV_INDE:	return &curbuf->b_p_inde_flags;
+ # endif
+@@ -5268,45 +5268,46 @@
+     char_u	*s;
+     char_u	**varp;
+     int		both = (opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0;
++    int		idx = opt_idx;
+ 
+-    if (opt_idx == -1)		/* use name */
++    if (idx == -1)		/* use name */
+     {
+-	opt_idx = findoption(name);
+-	if (opt_idx < 0)	/* not found (should not happen) */
++	idx = findoption(name);
++	if (idx < 0)	/* not found (should not happen) */
+ 	{
+ 	    EMSG2(_(e_intern2), "set_string_option_direct()");
+ 	    return;
+ 	}
+     }
+ 
+-    if (options[opt_idx].var == NULL)	/* can't set hidden option */
++    if (options[idx].var == NULL)	/* can't set hidden option */
+ 	return;
+ 
+     s = vim_strsave(val);
+     if (s != NULL)
+     {
+-	varp = (char_u **)get_varp_scope(&(options[opt_idx]),
++	varp = (char_u **)get_varp_scope(&(options[idx]),
+ 					       both ? OPT_LOCAL : opt_flags);
+-	if ((opt_flags & OPT_FREE) && (options[opt_idx].flags & P_ALLOCED))
++	if ((opt_flags & OPT_FREE) && (options[idx].flags & P_ALLOCED))
+ 	    free_string_option(*varp);
+ 	*varp = s;
+ 
+ 	/* For buffer/window local option may also set the global value. */
+ 	if (both)
+-	    set_string_option_global(opt_idx, varp);
++	    set_string_option_global(idx, varp);
+ 
+-	options[opt_idx].flags |= P_ALLOCED;
++	options[idx].flags |= P_ALLOCED;
+ 
+ 	/* When setting both values of a global option with a local value,
+ 	 * make the local value empty, so that the global value is used. */
+-	if (((int)options[opt_idx].indir & PV_BOTH) && both)
++	if (((int)options[idx].indir & PV_BOTH) && both)
+ 	{
+ 	    free_string_option(*varp);
+ 	    *varp = empty_option;
+ 	}
+ # ifdef FEAT_EVAL
+ 	if (set_sid != SID_NONE)
+-	    set_option_scriptID_idx(opt_idx, opt_flags,
++	    set_option_scriptID_idx(idx, opt_flags,
+ 					set_sid == 0 ? current_SID : set_sid);
+ # endif
+     }
+@@ -6325,7 +6326,8 @@
+ 	    else
+ 		errmsg = check_stl_option(p_ruf);
+ 	}
+-	else
++	/* check 'statusline' only if it doesn't start with "%!" */
++	else if (varp != &p_stl || s[0] != '%' || s[1] != '!')
+ 	    errmsg = check_stl_option(s);
+ 	if (varp == &p_ruf && errmsg == NULL)
+ 	    comp_col();
+@@ -7324,9 +7326,8 @@
+ #ifdef FEAT_AUTOCHDIR
+     else if ((int *)varp == &p_acd)
+     {
+-	if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	    shorten_fnames(TRUE);
++	/* Change directories when the 'acd' option is set now. */
++	DO_AUTOCHDIR
+     }
+ #endif
+ 
+diff -Naur vim70.orig/src/os_unix.c vim70/src/os_unix.c
+--- vim70.orig/src/os_unix.c	2006-05-01 01:13:15.000000000 -0700
++++ vim70/src/os_unix.c	2006-09-11 08:23:16.000000000 -0700
+@@ -3934,7 +3934,7 @@
+ 		    {
+ 			linenr_T    lnum = curbuf->b_op_start.lnum;
+ 			int	    written = 0;
+-			char_u	    *p = ml_get(lnum);
++			char_u	    *lp = ml_get(lnum);
+ 			char_u	    *s;
+ 			size_t	    l;
+ 
+@@ -3942,17 +3942,17 @@
+ 			close(fromshell_fd);
+ 			for (;;)
+ 			{
+-			    l = STRLEN(p + written);
++			    l = STRLEN(lp + written);
+ 			    if (l == 0)
+ 				len = 0;
+-			    else if (p[written] == NL)
++			    else if (lp[written] == NL)
+ 				/* NL -> NUL translation */
+ 				len = write(toshell_fd, "", (size_t)1);
+ 			    else
+ 			    {
+-				s = vim_strchr(p + written, NL);
+-				len = write(toshell_fd, (char *)p + written,
+-					   s == NULL ? l : s - (p + written));
++				s = vim_strchr(lp + written, NL);
++				len = write(toshell_fd, (char *)lp + written,
++					   s == NULL ? l : s - (lp + written));
+ 			    }
+ 			    if (len == l)
+ 			    {
+@@ -3973,7 +3973,7 @@
+ 				    toshell_fd = -1;
+ 				    break;
+ 				}
+-				p = ml_get(lnum);
++				lp = ml_get(lnum);
+ 				written = 0;
+ 			    }
+ 			    else if (len > 0)
+@@ -4971,7 +4971,8 @@
+ 		    if (((*file)[*num_file] = alloc(len + 2)) != NULL)
+ 		    {
+ 			STRCPY((*file)[*num_file], p);
+-			if (!after_pathsep((*file)[*num_file] + len))
++			if (!after_pathsep((*file)[*num_file],
++						    (*file)[*num_file] + len))
+ 			{
+ 			    (*file)[*num_file][len] = psepc;
+ 			    (*file)[*num_file][len + 1] = NUL;
+@@ -5757,8 +5758,13 @@
+     int		retval_int = 0;
+     int		success = FALSE;
+ 
+-    /* Get a handle to the DLL module. */
++    /*
++     * Get a handle to the DLL module.
++     */
+ # if defined(USE_DLOPEN)
++    /* First clear any error, it's not cleared by the dlopen() call. */
++    (void)dlerror();
++
+     hinstLib = dlopen((char *)libname, RTLD_LAZY
+ #  ifdef RTLD_LOCAL
+ 	    | RTLD_LOCAL
+diff -Naur vim70.orig/src/popupmnu.c vim70/src/popupmnu.c
+--- vim70.orig/src/popupmnu.c	2006-04-20 13:18:37.000000000 -0700
++++ vim70/src/popupmnu.c	2006-08-27 12:48:28.000000000 -0700
+@@ -552,6 +552,9 @@
+ {
+     pum_array = NULL;
+     redraw_all_later(SOME_VALID);
++#ifdef FEAT_WINDOWS
++    redraw_tabline = TRUE;
++#endif
+     status_redraw_all();
+ }
+ 
+diff -Naur vim70.orig/src/proto/buffer.pro vim70/src/proto/buffer.pro
+--- vim70.orig/src/proto/buffer.pro	2006-05-07 06:08:29.000000000 -0700
++++ vim70/src/proto/buffer.pro	2006-09-11 09:01:59.000000000 -0700
+@@ -10,6 +10,7 @@
+ extern int do_buffer __ARGS((int action, int start, int dir, int count, int forceit));
+ extern void set_curbuf __ARGS((buf_T *buf, int action));
+ extern void enter_buffer __ARGS((buf_T *buf));
++extern void do_autochdir __ARGS((void));
+ extern buf_T *buflist_new __ARGS((char_u *ffname, char_u *sfname, linenr_T lnum, int flags));
+ extern void free_buf_options __ARGS((buf_T *buf, int free_p_ff));
+ extern int buflist_getfile __ARGS((int n, linenr_T lnum, int options, int forceit));
+diff -Naur vim70.orig/src/proto/menu.pro vim70/src/proto/menu.pro
+--- vim70.orig/src/proto/menu.pro	2006-05-07 06:08:51.000000000 -0700
++++ vim70/src/proto/menu.pro	2006-08-19 16:40:11.000000000 -0700
+@@ -10,6 +10,7 @@
+ extern int menu_is_child_of_popup __ARGS((vimmenu_T *menu));
+ extern int menu_is_toolbar __ARGS((char_u *name));
+ extern int menu_is_separator __ARGS((char_u *name));
++extern int check_menu_pointer __ARGS((vimmenu_T *root, vimmenu_T *menu_to_check));
+ extern void gui_create_initial_menus __ARGS((vimmenu_T *menu));
+ extern void gui_update_menus __ARGS((int modes));
+ extern int gui_is_menu_shortcut __ARGS((int key));
+diff -Naur vim70.orig/src/proto/undo.pro vim70/src/proto/undo.pro
+--- vim70.orig/src/proto/undo.pro	2006-05-07 06:09:11.000000000 -0700
++++ vim70/src/proto/undo.pro	2006-07-14 10:51:11.000000000 -0700
+@@ -4,6 +4,7 @@
+ extern int u_savesub __ARGS((linenr_T lnum));
+ extern int u_inssub __ARGS((linenr_T lnum));
+ extern int u_savedel __ARGS((linenr_T lnum, long nlines));
++extern int undo_allowed __ARGS((void));
+ extern void u_undo __ARGS((int count));
+ extern void u_redo __ARGS((int count));
+ extern void undo_time __ARGS((long step, int sec, int absolute));
+diff -Naur vim70.orig/src/quickfix.c vim70/src/quickfix.c
+--- vim70.orig/src/quickfix.c	2006-05-03 00:47:42.000000000 -0700
++++ vim70/src/quickfix.c	2006-09-11 09:00:46.000000000 -0700
+@@ -500,8 +500,6 @@
+ 	{
+ 	    if (tv != NULL)
+ 	    {
+-		int len;
+-
+ 		if (tv->v_type == VAR_STRING)
+ 		{
+ 		    /* Get the next line from the supplied string */
+@@ -602,13 +600,19 @@
+ 		else
+ 		    type = 0;
+ 		/*
+-		 * Extract error message data from matched line
++		 * Extract error message data from matched line.
++		 * We check for an actual submatch, because "\[" and "\]" in
++		 * the 'errorformat' may cause the wrong submatch to be used.
+ 		 */
+ 		if ((i = (int)fmt_ptr->addr[0]) > 0)		/* %f */
+ 		{
+-		    int c = *regmatch.endp[i];
++		    int c;
++
++		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
++			continue;
+ 
+ 		    /* Expand ~/file and $HOME/file to full path. */
++		    c = *regmatch.endp[i];
+ 		    *regmatch.endp[i] = NUL;
+ 		    expand_env(regmatch.startp[i], namebuf, CMDBUFFSIZE);
+ 		    *regmatch.endp[i] = c;
+@@ -618,35 +622,63 @@
+ 			continue;
+ 		}
+ 		if ((i = (int)fmt_ptr->addr[1]) > 0)		/* %n */
++		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    enr = (int)atol((char *)regmatch.startp[i]);
++		}
+ 		if ((i = (int)fmt_ptr->addr[2]) > 0)		/* %l */
++		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    lnum = atol((char *)regmatch.startp[i]);
++		}
+ 		if ((i = (int)fmt_ptr->addr[3]) > 0)		/* %c */
++		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    col = (int)atol((char *)regmatch.startp[i]);
++		}
+ 		if ((i = (int)fmt_ptr->addr[4]) > 0)		/* %t */
++		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    type = *regmatch.startp[i];
++		}
+ 		if (fmt_ptr->flags == '+' && !multiscan)	/* %+ */
+ 		    STRCPY(errmsg, IObuff);
+ 		else if ((i = (int)fmt_ptr->addr[5]) > 0)	/* %m */
+ 		{
++		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
++			continue;
+ 		    len = (int)(regmatch.endp[i] - regmatch.startp[i]);
+ 		    vim_strncpy(errmsg, regmatch.startp[i], len);
+ 		}
+ 		if ((i = (int)fmt_ptr->addr[6]) > 0)		/* %r */
++		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    tail = regmatch.startp[i];
++		}
+ 		if ((i = (int)fmt_ptr->addr[7]) > 0)		/* %p */
+ 		{
++		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
++			continue;
+ 		    col = (int)(regmatch.endp[i] - regmatch.startp[i] + 1);
+ 		    if (*((char_u *)regmatch.startp[i]) != TAB)
+ 			use_viscol = TRUE;
+ 		}
+ 		if ((i = (int)fmt_ptr->addr[8]) > 0)		/* %v */
+ 		{
++		    if (regmatch.startp[i] == NULL)
++			continue;
+ 		    col = (int)atol((char *)regmatch.startp[i]);
+ 		    use_viscol = TRUE;
+ 		}
+ 		if ((i = (int)fmt_ptr->addr[9]) > 0)		/* %s */
+ 		{
++		    if (regmatch.startp[i] == NULL || regmatch.endp[i] == NULL)
++			continue;
+ 		    len = (int)(regmatch.endp[i] - regmatch.startp[i]);
+ 		    if (len > CMDBUFFSIZE - 5)
+ 			len = CMDBUFFSIZE - 5;
+@@ -2429,32 +2461,19 @@
+     qf_info_T	*qi;
+ {
+     buf_T	*buf;
+-#ifdef FEAT_AUTOCMD
+     aco_save_T	aco;
+-#else
+-    buf_T	*save_curbuf;
+-#endif
+ 
+     /* Check if a buffer for the quickfix list exists.  Update it. */
+     buf = qf_find_buf(qi);
+     if (buf != NULL)
+     {
+-#ifdef FEAT_AUTOCMD
+ 	/* set curwin/curbuf to buf and save a few things */
+ 	aucmd_prepbuf(&aco, buf);
+-#else
+-	save_curbuf = curbuf;
+-	curbuf = buf;
+-#endif
+ 
+ 	qf_fill_buffer(qi);
+ 
+-#ifdef FEAT_AUTOCMD
+ 	/* restore curwin/curbuf and a few other things */
+ 	aucmd_restbuf(&aco);
+-#else
+-	curbuf = save_curbuf;
+-#endif
+ 
+ 	(void)qf_win_pos_update(qi, 0);
+     }
+@@ -2943,10 +2962,8 @@
+ #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL)
+     char_u	*save_ei = NULL;
+ #endif
+-#ifndef FEAT_AUTOCMD
+-    buf_T	*save_curbuf;
+-#else
+     aco_save_T	aco;
++#ifdef FEAT_AUTOCMD
+     char_u	*au_name =  NULL;
+     int		flags = 0;
+     colnr_T	col;
+@@ -3167,24 +3184,13 @@
+ 		     * need to be done now, in that buffer.  And the modelines
+ 		     * need to be done (again).  But not the window-local
+ 		     * options! */
+-#if defined(FEAT_AUTOCMD)
+ 		    aucmd_prepbuf(&aco, buf);
+-#else
+-		    save_curbuf = curbuf;
+-		    curbuf = buf;
+-		    curwin->w_buffer = curbuf;
+-#endif
+ #if defined(FEAT_AUTOCMD) && defined(FEAT_SYN_HL)
+ 		    apply_autocmds(EVENT_FILETYPE, buf->b_p_ft,
+ 						     buf->b_fname, TRUE, buf);
+ #endif
+ 		    do_modelines(OPT_NOWIN);
+-#if defined(FEAT_AUTOCMD)
+ 		    aucmd_restbuf(&aco);
+-#else
+-		    curbuf = save_curbuf;
+-		    curwin->w_buffer = curbuf;
+-#endif
+ 		}
+ 	    }
+ 	}
+@@ -3285,11 +3291,7 @@
+ {
+     buf_T	*newbuf;
+     int		failed = TRUE;
+-#ifdef FEAT_AUTOCMD
+     aco_save_T	aco;
+-#else
+-    buf_T	*old_curbuf = curbuf;
+-#endif
+ 
+     /* Allocate a buffer without putting it in the buffer list. */
+     newbuf = buflist_new(NULL, NULL, (linenr_T)1, BLN_DUMMY);
+@@ -3299,13 +3301,8 @@
+     /* Init the options. */
+     buf_copy_options(newbuf, BCO_ENTER | BCO_NOHELP);
+ 
+-#ifdef FEAT_AUTOCMD
+     /* set curwin/curbuf to buf and save a few things */
+     aucmd_prepbuf(&aco, newbuf);
+-#else
+-    curbuf = newbuf;
+-    curwin->w_buffer = newbuf;
+-#endif
+ 
+     /* Need to set the filename for autocommands. */
+     (void)setfname(curbuf, fname, NULL, FALSE);
+@@ -3336,13 +3333,8 @@
+ 	}
+     }
+ 
+-#ifdef FEAT_AUTOCMD
+     /* restore curwin/curbuf and a few other things */
+     aucmd_restbuf(&aco);
+-#else
+-    curbuf = old_curbuf;
+-    curwin->w_buffer = old_curbuf;
+-#endif
+ 
+     if (!buf_valid(newbuf))
+ 	return NULL;
+@@ -3434,8 +3426,10 @@
+ 	  || dict_add_nr_str(dict, "col",   (long)qfp->qf_col, NULL) == FAIL
+ 	  || dict_add_nr_str(dict, "vcol",  (long)qfp->qf_viscol, NULL) == FAIL
+ 	  || dict_add_nr_str(dict, "nr",    (long)qfp->qf_nr, NULL) == FAIL
+-	  || dict_add_nr_str(dict, "pattern",  0L, qfp->qf_pattern) == FAIL
+-	  || dict_add_nr_str(dict, "text",  0L, qfp->qf_text) == FAIL
++	  || dict_add_nr_str(dict, "pattern",  0L,
++	     qfp->qf_pattern == NULL ? (char_u *)"" : qfp->qf_pattern) == FAIL
++	  || dict_add_nr_str(dict, "text",  0L,
++		   qfp->qf_text == NULL ? (char_u *)"" : qfp->qf_text) == FAIL
+ 	  || dict_add_nr_str(dict, "type",  0L, buf) == FAIL
+ 	  || dict_add_nr_str(dict, "valid", (long)qfp->qf_valid, NULL) == FAIL)
+ 	    return FAIL;
+diff -Naur vim70.orig/src/regexp.c vim70/src/regexp.c
+--- vim70.orig/src/regexp.c	2006-04-30 08:31:50.000000000 -0700
++++ vim70/src/regexp.c	2006-09-11 08:23:16.000000000 -0700
+@@ -3912,7 +3912,7 @@
+ 		{
+ 		    colnr_T	    start, end;
+ 		    colnr_T	    start2, end2;
+-		    colnr_T	    col;
++		    colnr_T	    cols;
+ 
+ 		    getvvcol(wp, &top, &start, NULL, &end);
+ 		    getvvcol(wp, &bot, &start2, NULL, &end2);
+@@ -3922,9 +3922,9 @@
+ 			end = end2;
+ 		    if (top.col == MAXCOL || bot.col == MAXCOL)
+ 			end = MAXCOL;
+-		    col = win_linetabsize(wp,
++		    cols = win_linetabsize(wp,
+ 				      regline, (colnr_T)(reginput - regline));
+-		    if (col < start || col > end - (*p_sel == 'e'))
++		    if (cols < start || cols > end - (*p_sel == 'e'))
+ 			status = RA_NOMATCH;
+ 		}
+ 	    }
+@@ -4253,7 +4253,7 @@
+ 	    {
+ 		int	i, len;
+ 		char_u	*opnd;
+-		int	opndc, inpc;
++		int	opndc = 0, inpc;
+ 
+ 		opnd = OPERAND(scan);
+ 		/* Safety check (just in case 'encoding' was changed since
+diff -Naur vim70.orig/src/screen.c vim70/src/screen.c
+--- vim70.orig/src/screen.c	2006-05-05 03:13:55.000000000 -0700
++++ vim70/src/screen.c	2006-09-11 08:23:16.000000000 -0700
+@@ -2612,7 +2612,8 @@
+ #ifdef FEAT_LINEBREAK
+     int		need_showbreak = FALSE;
+ #endif
+-#if defined(FEAT_SIGNS) || (defined(FEAT_QUICKFIX) && defined(FEAT_WINDOWS))
++#if defined(FEAT_SIGNS) || (defined(FEAT_QUICKFIX) && defined(FEAT_WINDOWS)) \
++	|| defined(FEAT_SYN_HL) || defined(FEAT_DIFF)
+ # define LINE_ATTR
+     int		line_attr = 0;		/* atrribute for the whole line */
+ #endif
+@@ -2626,7 +2627,7 @@
+     int		prev_c = 0;		/* previous Arabic character */
+     int		prev_c1 = 0;		/* first composing char for prev_c */
+ #endif
+-#if defined(FEAT_DIFF) || defined(LINE_ATTR)
++#if defined(LINE_ATTR)
+     int		did_line_attr = 0;
+ #endif
+ 
+@@ -4116,17 +4117,12 @@
+ 		    --ptr;	    /* put it back at the NUL */
+ 		}
+ #endif
+-#if defined(FEAT_DIFF) || defined(LINE_ATTR)
++#if defined(LINE_ATTR)
+ 		else if ((
+ # ifdef FEAT_DIFF
+-			    diff_hlf != (hlf_T)0
+-#  ifdef LINE_ATTR
+-			    ||
+-#  endif
++			    diff_hlf != (hlf_T)0 ||
+ # endif
+-# ifdef LINE_ATTR
+ 			    line_attr != 0
+-# endif
+ 			) && (
+ # ifdef FEAT_RIGHTLEFT
+ 			    wp->w_p_rl ? (col >= 0) :
+@@ -4237,7 +4233,7 @@
+ 	 * At end of the text line or just after the last character.
+ 	 */
+ 	if (c == NUL
+-#if defined(FEAT_DIFF) || defined(LINE_ATTR)
++#if defined(LINE_ATTR)
+ 		|| did_line_attr == 1
+ #endif
+ 		)
+@@ -4258,7 +4254,7 @@
+ 				|| prevcol == (long)match_hl[0].startcol
+ 				|| prevcol == (long)match_hl[1].startcol
+ 				|| prevcol == (long)match_hl[2].startcol)
+-# if defined(FEAT_DIFF) || defined(LINE_ATTR)
++# if defined(LINE_ATTR)
+ 			    && did_line_attr <= 1
+ # endif
+ 			   )
+@@ -7103,7 +7099,7 @@
+     tabpage_T	    *tp;
+ #endif
+     static int	    entered = FALSE;		/* avoid recursiveness */
+-    static int	    did_outofmem_msg = FALSE;	/* did outofmem message */
++    static int	    done_outofmem_msg = FALSE;	/* did outofmem message */
+ 
+     /*
+      * Allocation of the screen buffers is done only when the size changes and
+@@ -7133,6 +7129,12 @@
+ 	return;
+     entered = TRUE;
+ 
++    /*
++     * Note that the window sizes are updated before reallocating the arrays,
++     * thus we must not redraw here!
++     */
++    ++RedrawingDisabled;
++
+     win_new_shellsize();    /* fit the windows in the new sized shell */
+ 
+     comp_col();		/* recompute columns for shown command and ruler */
+@@ -7205,14 +7207,14 @@
+ #endif
+ 	    || outofmem)
+     {
+-	if (ScreenLines != NULL || !did_outofmem_msg)
++	if (ScreenLines != NULL || !done_outofmem_msg)
+ 	{
+ 	    /* guess the size */
+ 	    do_outofmem_msg((long_u)((Rows + 1) * Columns));
+ 
+ 	    /* Remember we did this to avoid getting outofmem messages over
+ 	     * and over again. */
+-	    did_outofmem_msg = TRUE;
++	    done_outofmem_msg = TRUE;
+ 	}
+ 	vim_free(new_ScreenLines);
+ 	new_ScreenLines = NULL;
+@@ -7240,7 +7242,7 @@
+     }
+     else
+     {
+-	did_outofmem_msg = FALSE;
++	done_outofmem_msg = FALSE;
+ 
+ 	for (new_row = 0; new_row < Rows; ++new_row)
+ 	{
+@@ -7367,6 +7369,7 @@
+ #endif
+ 
+     entered = FALSE;
++    --RedrawingDisabled;
+ 
+ #ifdef FEAT_AUTOCMD
+     if (starting == 0)
+diff -Naur vim70.orig/src/search.c vim70/src/search.c
+--- vim70.orig/src/search.c	2006-05-05 05:12:13.000000000 -0700
++++ vim70/src/search.c	2006-09-11 08:23:39.000000000 -0700
+@@ -1259,7 +1259,7 @@
+ 	/*
+ 	 * Add character and/or line offset
+ 	 */
+-	if (!(options & SEARCH_NOOF) || *pat == ';')
++	if (!(options & SEARCH_NOOF) || (pat != NULL && *pat == ';'))
+ 	{
+ 	    if (spats[0].off.line)	/* Add the offset to the line number. */
+ 	    {
+@@ -4826,15 +4826,20 @@
+ 
+ 		if ((compl_cont_status & CONT_ADDING) && i == compl_length)
+ 		{
+-		    /* get the next line */
+ 		    /* IOSIZE > compl_length, so the STRNCPY works */
+ 		    STRNCPY(IObuff, aux, i);
+-		    if (!(     depth < 0
+-			    && lnum < end_lnum
+-			    && (line = ml_get(++lnum)) != NULL)
+-			&& !(	depth >= 0
+-			    && !vim_fgets(line = file_line,
+-						     LSIZE, files[depth].fp)))
++
++		    /* Get the next line: when "depth" < 0  from the current
++		     * buffer, otherwise from the included file.  Jump to
++		     * exit_matched when past the last line. */
++		    if (depth < 0)
++		    {
++			if (lnum >= end_lnum)
++			    goto exit_matched;
++			line = ml_get(++lnum);
++		    }
++		    else if (vim_fgets(line = file_line,
++						      LSIZE, files[depth].fp))
+ 			goto exit_matched;
+ 
+ 		    /* we read a line, set "already" to check this "line" later
+@@ -4871,7 +4876,7 @@
+ 			goto exit_matched;
+ 		}
+ 
+-		add_r = ins_compl_add_infercase(aux, i, FALSE,
++		add_r = ins_compl_add_infercase(aux, i, p_ic,
+ 			curr_fname == curbuf->b_fname ? NULL : curr_fname,
+ 			dir, reuse);
+ 		if (add_r == OK)
+diff -Naur vim70.orig/src/spell.c vim70/src/spell.c
+--- vim70.orig/src/spell.c	2006-05-05 00:49:58.000000000 -0700
++++ vim70/src/spell.c	2006-09-11 08:23:16.000000000 -0700
+@@ -2043,8 +2043,8 @@
+     int		len;
+ # ifdef FEAT_SYN_HL
+     int		has_syntax = syntax_present(wp->w_buffer);
+-    int		col;
+ # endif
++    int		col;
+     int		can_spell;
+     char_u	*buf = NULL;
+     int		buflen = 0;
+@@ -2093,9 +2093,8 @@
+ 	    capcol = (int)(skipwhite(line) - line);
+ 	else if (curline && wp == curwin)
+ 	{
+-	    int	    col = (int)(skipwhite(line) - line);
+-
+ 	    /* For spellbadword(): check if first word needs a capital. */
++	    col = (int)(skipwhite(line) - line);
+ 	    if (check_need_cap(lnum, col))
+ 		capcol = col;
+ 
+@@ -2108,7 +2107,8 @@
+ 	 * possible. */
+ 	STRCPY(buf, line);
+ 	if (lnum < wp->w_buffer->b_ml.ml_line_count)
+-	    spell_cat_line(buf + STRLEN(buf), ml_get(lnum + 1), MAXWLEN);
++	    spell_cat_line(buf + STRLEN(buf),
++			  ml_get_buf(wp->w_buffer, lnum + 1, FALSE), MAXWLEN);
+ 
+ 	p = buf + skip;
+ 	endp = buf + len;
+@@ -5060,7 +5060,7 @@
+     int		do_rep;
+     int		do_repsal;
+     int		do_sal;
+-    int		do_map;
++    int		do_mapline;
+     int		found_map = FALSE;
+     hashitem_T	*hi;
+     int		l;
+@@ -5098,7 +5098,7 @@
+     do_sal = spin->si_sal.ga_len == 0;
+ 
+     /* Only do MAP lines when not done in another .aff file already. */
+-    do_map = spin->si_map.ga_len == 0;
++    do_mapline = spin->si_map.ga_len == 0;
+ 
+     /*
+      * Allocate and init the afffile_T structure.
+@@ -5780,7 +5780,7 @@
+ 			smsg((char_u *)_("Expected MAP count in %s line %d"),
+ 								 fname, lnum);
+ 		}
+-		else if (do_map)
++		else if (do_mapline)
+ 		{
+ 		    int		c;
+ 
+@@ -7507,7 +7507,7 @@
+ {
+     char_u	*p = p_msm;
+     long	start = 0;
+-    long	inc = 0;
++    long	incr = 0;
+     long	added = 0;
+ 
+     if (!VIM_ISDIGIT(*p))
+@@ -7519,7 +7519,7 @@
+     ++p;
+     if (!VIM_ISDIGIT(*p))
+ 	return FAIL;
+-    inc = (getdigits(&p) * 102) / (SBLOCKSIZE / 10);
++    incr = (getdigits(&p) * 102) / (SBLOCKSIZE / 10);
+     if (*p != ',')
+ 	return FAIL;
+     ++p;
+@@ -7529,11 +7529,11 @@
+     if (*p != NUL)
+ 	return FAIL;
+ 
+-    if (start == 0 || inc == 0 || added == 0 || inc > start)
++    if (start == 0 || incr == 0 || added == 0 || incr > start)
+ 	return FAIL;
+ 
+     compress_start = start;
+-    compress_inc = inc;
++    compress_inc = incr;
+     compress_added = added;
+     return OK;
+ }
+@@ -8291,14 +8291,14 @@
+  * Returns the number of nodes used.
+  */
+     static int
+-put_node(fd, node, index, regionmask, prefixtree)
++put_node(fd, node, idx, regionmask, prefixtree)
+     FILE	*fd;		/* NULL when only counting */
+     wordnode_T	*node;
+-    int		index;
++    int		idx;
+     int		regionmask;
+     int		prefixtree;	/* TRUE for PREFIXTREE */
+ {
+-    int		newindex = index;
++    int		newindex = idx;
+     int		siblingcount = 0;
+     wordnode_T	*np;
+     int		flags;
+@@ -8308,7 +8308,7 @@
+ 	return 0;
+ 
+     /* Store the index where this node is written. */
+-    node->wn_u1.index = index;
++    node->wn_u1.index = idx;
+ 
+     /* Count the number of siblings. */
+     for (np = node; np != NULL; np = np->wn_sibling)
+@@ -9243,11 +9243,11 @@
+  * Add "word[len]" to 'spellfile' as a good or bad word.
+  */
+     void
+-spell_add_word(word, len, bad, index, undo)
++spell_add_word(word, len, bad, idx, undo)
+     char_u	*word;
+     int		len;
+     int		bad;
+-    int		index;	    /* "zG" and "zW": zero, otherwise index in
++    int		idx;	    /* "zG" and "zW": zero, otherwise index in
+ 			       'spellfile' */
+     int		undo;	    /* TRUE for "zug", "zuG", "zuw" and "zuW" */
+ {
+@@ -9261,7 +9261,7 @@
+     int		i;
+     char_u	*spf;
+ 
+-    if (index == 0)	    /* use internal wordlist */
++    if (idx == 0)	    /* use internal wordlist */
+     {
+ 	if (int_wordlist == NULL)
+ 	{
+@@ -9289,11 +9289,11 @@
+ 	for (spf = curbuf->b_p_spf, i = 1; *spf != NUL; ++i)
+ 	{
+ 	    copy_option_part(&spf, fnamebuf, MAXPATHL, ",");
+-	    if (i == index)
++	    if (i == idx)
+ 		break;
+ 	    if (*spf == NUL)
+ 	    {
+-		EMSGN(_("E765: 'spellfile' does not have %ld entries"), index);
++		EMSGN(_("E765: 'spellfile' does not have %ld entries"), idx);
+ 		return;
+ 	    }
+ 	}
+@@ -10070,6 +10070,7 @@
+ 
+ 	/* List the suggestions. */
+ 	msg_start();
++	msg_row = Rows - 1;	/* for when 'cmdheight' > 1 */
+ 	lines_left = Rows;	/* avoid more prompt */
+ 	vim_snprintf((char *)IObuff, IOSIZE, _("Change \"%.*s\" to:"),
+ 						sug.su_badlen, sug.su_badptr);
+@@ -13579,53 +13580,58 @@
+ 	 * the first "the" to itself. */
+ 	return;
+ 
+-    /* Check if the word is already there.  Also check the length that is
+-     * being replaced "thes," -> "these" is a different suggestion from
+-     * "thes" -> "these". */
+-    stp = &SUG(*gap, 0);
+-    for (i = gap->ga_len; --i >= 0; ++stp)
+-	if (stp->st_wordlen == goodlen
+-		&& stp->st_orglen == badlen
+-		&& STRNCMP(stp->st_word, goodword, goodlen) == 0)
+-	{
+-	    /*
+-	     * Found it.  Remember the word with the lowest score.
+-	     */
+-	    if (stp->st_slang == NULL)
+-		stp->st_slang = slang;
++    if (gap->ga_len == 0)
++	i = -1;
++    else
++    {
++	/* Check if the word is already there.  Also check the length that is
++	 * being replaced "thes," -> "these" is a different suggestion from
++	 * "thes" -> "these". */
++	stp = &SUG(*gap, 0);
++	for (i = gap->ga_len; --i >= 0; ++stp)
++	    if (stp->st_wordlen == goodlen
++		    && stp->st_orglen == badlen
++		    && STRNCMP(stp->st_word, goodword, goodlen) == 0)
++	    {
++		/*
++		 * Found it.  Remember the word with the lowest score.
++		 */
++		if (stp->st_slang == NULL)
++		    stp->st_slang = slang;
+ 
+-	    new_sug.st_score = score;
+-	    new_sug.st_altscore = altscore;
+-	    new_sug.st_had_bonus = had_bonus;
++		new_sug.st_score = score;
++		new_sug.st_altscore = altscore;
++		new_sug.st_had_bonus = had_bonus;
++
++		if (stp->st_had_bonus != had_bonus)
++		{
++		    /* Only one of the two had the soundalike score computed.
++		     * Need to do that for the other one now, otherwise the
++		     * scores can't be compared.  This happens because
++		     * suggest_try_change() doesn't compute the soundalike
++		     * word to keep it fast, while some special methods set
++		     * the soundalike score to zero. */
++		    if (had_bonus)
++			rescore_one(su, stp);
++		    else
++		    {
++			new_sug.st_word = stp->st_word;
++			new_sug.st_wordlen = stp->st_wordlen;
++			new_sug.st_slang = stp->st_slang;
++			new_sug.st_orglen = badlen;
++			rescore_one(su, &new_sug);
++		    }
++		}
+ 
+-	    if (stp->st_had_bonus != had_bonus)
+-	    {
+-		/* Only one of the two had the soundalike score computed.
+-		 * Need to do that for the other one now, otherwise the
+-		 * scores can't be compared.  This happens because
+-		 * suggest_try_change() doesn't compute the soundalike
+-		 * word to keep it fast, while some special methods set
+-		 * the soundalike score to zero. */
+-		if (had_bonus)
+-		    rescore_one(su, stp);
+-		else
++		if (stp->st_score > new_sug.st_score)
+ 		{
+-		    new_sug.st_word = stp->st_word;
+-		    new_sug.st_wordlen = stp->st_wordlen;
+-		    new_sug.st_slang = stp->st_slang;
+-		    new_sug.st_orglen = badlen;
+-		    rescore_one(su, &new_sug);
++		    stp->st_score = new_sug.st_score;
++		    stp->st_altscore = new_sug.st_altscore;
++		    stp->st_had_bonus = new_sug.st_had_bonus;
+ 		}
++		break;
+ 	    }
+-
+-	    if (stp->st_score > new_sug.st_score)
+-	    {
+-		stp->st_score = new_sug.st_score;
+-		stp->st_altscore = new_sug.st_altscore;
+-		stp->st_had_bonus = new_sug.st_had_bonus;
+-	    }
+-	    break;
+-	}
++    }
+ 
+     if (i < 0 && ga_grow(gap, 1) == OK)
+     {
+@@ -15656,7 +15662,7 @@
+ 		    ? MB_STRNICMP(p, pat, STRLEN(pat)) == 0
+ 		    : STRNCMP(p, pat, STRLEN(pat)) == 0)
+ 		&& ins_compl_add_infercase(p, (int)STRLEN(p),
+-					  FALSE, NULL, *dir, 0) == OK)
++					  p_ic, NULL, *dir, 0) == OK)
+ 	/* if dir was BACKWARD then honor it just once */
+ 	*dir = FORWARD;
+ }
+diff -Naur vim70.orig/src/structs.h vim70/src/structs.h
+--- vim70.orig/src/structs.h	2006-04-09 10:57:46.000000000 -0700
++++ vim70/src/structs.h	2006-08-19 16:39:02.000000000 -0700
+@@ -2213,18 +2213,20 @@
+ 
+ /*
+  * Struct to save values in before executing autocommands for a buffer that is
+- * not the current buffer.
++ * not the current buffer.  Without FEAT_AUTOCMD only "curbuf" is remembered.
+  */
+ typedef struct
+ {
+     buf_T	*save_buf;	/* saved curbuf */
++#ifdef FEAT_AUTOCMD
+     buf_T	*new_curbuf;	/* buffer to be used */
+     win_T	*save_curwin;	/* saved curwin, NULL if it didn't change */
+     win_T	*new_curwin;	/* new curwin if save_curwin != NULL */
+     pos_T	save_cursor;	/* saved cursor pos of save_curwin */
+     linenr_T	save_topline;	/* saved topline of save_curwin */
+-#ifdef FEAT_DIFF
++# ifdef FEAT_DIFF
+     int		save_topfill;	/* saved topfill of save_curwin */
++# endif
+ #endif
+ } aco_save_T;
+ 
+diff -Naur vim70.orig/src/tag.c vim70/src/tag.c
+--- vim70.orig/src/tag.c	2006-04-27 06:11:21.000000000 -0700
++++ vim70/src/tag.c	2006-09-11 09:26:46.000000000 -0700
+@@ -3787,6 +3787,7 @@
+ {
+     int		num_matches, i, ret;
+     char_u	**matches, *p;
++    char_u	*full_fname;
+     dict_T	*dict;
+     tagptrs_T	tp;
+     long	is_static;
+@@ -3809,9 +3810,10 @@
+ 	    if (list_append_dict(list, dict) == FAIL)
+ 		ret = FAIL;
+ 
++	    full_fname = tag_full_fname(&tp);
+ 	    if (add_tag_field(dict, "name", tp.tagname, tp.tagname_end) == FAIL
+-		    || add_tag_field(dict, "filename", tp.fname,
+-							 tp.fname_end) == FAIL
++		    || add_tag_field(dict, "filename", full_fname,
++							 NULL) == FAIL
+ 		    || add_tag_field(dict, "cmd", tp.command,
+ 						       tp.command_end) == FAIL
+ 		    || add_tag_field(dict, "kind", tp.tagkind,
+@@ -3819,6 +3821,8 @@
+ 		    || dict_add_nr_str(dict, "static", is_static, NULL) == FAIL)
+ 		ret = FAIL;
+ 
++	    vim_free(full_fname);
++
+ 	    if (tp.command_end != NULL)
+ 	    {
+ 		for (p = tp.command_end + 3;
+diff -Naur vim70.orig/src/term.c vim70/src/term.c
+--- vim70.orig/src/term.c	2006-05-03 10:34:57.000000000 -0700
++++ vim70/src/term.c	2006-08-19 16:40:11.000000000 -0700
+@@ -4783,6 +4783,14 @@
+ 		return -1;
+ 	    current_menu = (vimmenu_T *)val;
+ 	    slen += num_bytes;
++
++	    /* The menu may have been deleted right after it was used, check
++	     * for that. */
++	    if (check_menu_pointer(root_menu, current_menu) == FAIL)
++	    {
++		key_name[0] = KS_EXTRA;
++		key_name[1] = (int)KE_IGNORE;
++	    }
+ 	}
+ # endif
+ # ifdef FEAT_GUI_TABLINE
+diff -Naur vim70.orig/src/testdir/test56.in vim70/src/testdir/test56.in
+--- vim70.orig/src/testdir/test56.in	2005-05-18 08:37:37.000000000 -0700
++++ vim70/src/testdir/test56.in	2006-09-11 09:00:23.000000000 -0700
+@@ -3,7 +3,7 @@
+ STARTTEST
+ :so small.vim
+ :"
+-:set nocp
++:set nocp viminfo+=nviminfo
+ :/^start:/+1,/^end:/-1w! Xtest.vim
+ :source Xtest.vim
+ _x
+diff -Naur vim70.orig/src/ui.c vim70/src/ui.c
+--- vim70.orig/src/ui.c	2006-03-27 11:15:09.000000000 -0800
++++ vim70/src/ui.c	2006-09-11 08:23:16.000000000 -0700
+@@ -1137,7 +1137,6 @@
+     int		len;
+ #ifdef FEAT_MBYTE
+     char_u	*p;
+-    int		i;
+ #endif
+     int		row1 = clip_star.start.lnum;
+     int		col1 = clip_star.start.col;
+@@ -1218,6 +1217,8 @@
+ #ifdef FEAT_MBYTE
+ 	    if (enc_dbcs != 0)
+ 	    {
++		int	i;
++
+ 		p = ScreenLines + LineOffset[row];
+ 		for (i = start_col; i < end_col; ++i)
+ 		    if (enc_dbcs == DBCS_JPNU && p[i] == 0x8e)
+diff -Naur vim70.orig/src/undo.c vim70/src/undo.c
+--- vim70.orig/src/undo.c	2006-04-21 02:30:59.000000000 -0700
++++ vim70/src/undo.c	2006-09-11 08:23:16.000000000 -0700
+@@ -84,7 +84,6 @@
+ static void u_unch_branch __ARGS((u_header_T *uhp));
+ static u_entry_T *u_get_headentry __ARGS((void));
+ static void u_getbot __ARGS((void));
+-static int undo_allowed __ARGS((void));
+ static int u_savecommon __ARGS((linenr_T, linenr_T, linenr_T));
+ static void u_doit __ARGS((int count));
+ static void u_undoredo __ARGS((int undo));
+@@ -196,7 +195,7 @@
+  * Return TRUE when undo is allowed.  Otherwise give an error message and
+  * return FALSE.
+  */
+-    static int
++    int
+ undo_allowed()
+ {
+     /* Don't allow changes when 'modifiable' is off.  */
+@@ -1188,7 +1187,7 @@
+     int		did_undo;	/* just did an undo */
+     int		absolute;	/* used ":undo N" */
+ {
+-    char	*msg;
++    char	*msgstr;
+     u_header_T	*uhp;
+     char_u	msgbuf[80];
+ 
+@@ -1206,20 +1205,20 @@
+ 
+     u_oldcount -= u_newcount;
+     if (u_oldcount == -1)
+-	msg = N_("more line");
++	msgstr = N_("more line");
+     else if (u_oldcount < 0)
+-	msg = N_("more lines");
++	msgstr = N_("more lines");
+     else if (u_oldcount == 1)
+-	msg = N_("line less");
++	msgstr = N_("line less");
+     else if (u_oldcount > 1)
+-	msg = N_("fewer lines");
++	msgstr = N_("fewer lines");
+     else
+     {
+ 	u_oldcount = u_newcount;
+ 	if (u_newcount == 1)
+-	    msg = N_("change");
++	    msgstr = N_("change");
+ 	else
+-	    msg = N_("changes");
++	    msgstr = N_("changes");
+     }
+ 
+     if (curbuf->b_u_curhead != NULL)
+@@ -1245,7 +1244,7 @@
+ 
+     smsg((char_u *)_("%ld %s; %s #%ld  %s"),
+ 	    u_oldcount < 0 ? -u_oldcount : u_oldcount,
+-	    _(msg),
++	    _(msgstr),
+ 	    did_undo ? _("before") : _("after"),
+ 	    uhp == NULL ? 0L : uhp->uh_seq,
+ 	    msgbuf);
+diff -Naur vim70.orig/src/version.c vim70/src/version.c
+--- vim70.orig/src/version.c	2006-05-03 00:50:42.000000000 -0700
++++ vim70/src/version.c	2006-09-11 09:28:13.000000000 -0700
+@@ -667,6 +667,190 @@
+ static int included_patches[] =
+ {   /* Add new patch number below this line */
+ /**/
++    99,
++/**/
++    98,
++/**/
++    97,
++/**/
++    96,
++/**/
++    95,
++/**/
++    94,
++/**/
++    93,
++/**/
++    92,
++/**/
++    91,
++/**/
++    90,
++/**/
++    89,
++/**/
++    88,
++/**/
++    87,
++/**/
++    86,
++/**/
++    85,
++/**/
++    84,
++/**/
++    83,
++/**/
++    82,
++/**/
++    81,
++/**/
++    80,
++/**/
++    79,
++/**/
++    78,
++/**/
++    77,
++/**/
++    76,
++/**/
++    75,
++/**/
++    73,
++/**/
++    72,
++/**/
++    71,
++/**/
++    70,
++/**/
++    69,
++/**/
++    68,
++/**/
++    67,
++/**/
++    66,
++/**/
++    64,
++/**/
++    63,
++/**/
++    62,
++/**/
++    61,
++/**/
++    60,
++/**/
++    59,
++/**/
++    58,
++/**/
++    56,
++/**/
++    55,
++/**/
++    54,
++/**/
++    53,
++/**/
++    52,
++/**/
++    51,
++/**/
++    50,
++/**/
++    49,
++/**/
++    48,
++/**/
++    47,
++/**/
++    46,
++/**/
++    44,
++/**/
++    43,
++/**/
++    42,
++/**/
++    41,
++/**/
++    40,
++/**/
++    39,
++/**/
++    38,
++/**/
++    37,
++/**/
++    36,
++/**/
++    35,
++/**/
++    34,
++/**/
++    33,
++/**/
++    31,
++/**/
++    30,
++/**/
++    29,
++/**/
++    28,
++/**/
++    26,
++/**/
++    25,
++/**/
++    24,
++/**/
++    23,
++/**/
++    22,
++/**/
++    21,
++/**/
++    20,
++/**/
++    19,
++/**/
++    18,
++/**/
++    17,
++/**/
++    16,
++/**/
++    15,
++/**/
++    14,
++/**/
++    13,
++/**/
++    12,
++/**/
++    11,
++/**/
++    10,
++/**/
++    9,
++/**/
++    8,
++/**/
++    7,
++/**/
++    6,
++/**/
++    4,
++/**/
++    3,
++/**/
++    2,
++/**/
++    1,
++/**/
+     0
+ };
+ 
+diff -Naur vim70.orig/src/vim.h vim70/src/vim.h
+--- vim70.orig/src/vim.h	2006-04-30 08:32:38.000000000 -0700
++++ vim70/src/vim.h	2006-09-11 08:24:09.000000000 -0700
+@@ -585,7 +585,6 @@
+ #define INSERT		0x10	/* Insert mode */
+ #define LANGMAP		0x20	/* Language mapping, can be combined with
+ 				   INSERT and CMDLINE */
+-#define MAP_ALL_MODES	0x3f	/* all mode bits used for mapping */
+ 
+ #define REPLACE_FLAG	0x40	/* Replace mode flag */
+ #define REPLACE		(REPLACE_FLAG + INSERT)
+@@ -605,6 +604,9 @@
+ #define CONFIRM		0x800	/* ":confirm" prompt */
+ #define SELECTMODE	0x1000	/* Select mode, only for mappings */
+ 
++#define MAP_ALL_MODES	(0x3f | SELECTMODE)	/* all mode bits used for
++						 * mapping */
++
+ /* directions */
+ #define FORWARD			1
+ #define BACKWARD		(-1)
+@@ -1118,6 +1120,7 @@
+     EVENT_FOCUSGAINED,		/* got the focus */
+     EVENT_FOCUSLOST,		/* lost the focus to another app */
+     EVENT_GUIENTER,		/* after starting the GUI */
++    EVENT_GUIFAILED,		/* after starting the GUI failed */
+     EVENT_INSERTCHANGE,		/* when changing Insert/Replace mode */
+     EVENT_INSERTENTER,		/* when entering Insert mode */
+     EVENT_INSERTLEAVE,		/* when leaving Insert mode */
+@@ -1983,7 +1986,7 @@
+ /* values for vim_handle_signal() that are not a signal */
+ #define SIGNAL_BLOCK	-1
+ #define SIGNAL_UNBLOCK  -2
+-#if !defined(UNIX) && !defined(VMS)
++#if !defined(UNIX) && !defined(VMS) && !defined(OS2)
+ # define vim_handle_signal(x) 0
+ #endif
+ 
+diff -Naur vim70.orig/src/window.c vim70/src/window.c
+--- vim70.orig/src/window.c	2006-05-06 03:54:51.000000000 -0700
++++ vim70/src/window.c	2006-09-11 09:01:59.000000000 -0700
+@@ -340,10 +340,10 @@
+ 		{
+ 		    tabpage_T	*oldtab = curtab;
+ 		    tabpage_T	*newtab;
+-		    win_T	*wp = curwin;
+ 
+ 		    /* First create a new tab with the window, then go back to
+ 		     * the old tab and close the window there. */
++		    wp = curwin;
+ 		    if (win_new_tabpage((int)Prenum) == OK
+ 						     && valid_tabpage(oldtab))
+ 		    {
+@@ -3954,13 +3954,8 @@
+     setmouse();			/* in case jumped to/from help buffer */
+ #endif
+ 
+-#ifdef FEAT_AUTOCHDIR
+-    /* Change directories when the 'acd' option is set on and after
+-     * switching windows. */
+-    if (p_acd && curbuf->b_ffname != NULL
+-				     && vim_chdirfile(curbuf->b_ffname) == OK)
+-	shorten_fnames(TRUE);
+-#endif
++    /* Change directories when the 'acd' option is set. */
++    DO_AUTOCHDIR
+ }
+ 
+ #endif /* FEAT_WINDOWS */
+
