changeset 477:f8b75b8f1988

updated for version 7.0128
author vimboss
date Thu, 11 Aug 2005 20:09:58 +0000
parents a6c13cc11da9
children 87ac4be38952
files Filelist runtime/doc/eval.txt runtime/doc/insert.txt runtime/doc/options.txt runtime/doc/pi_netrw.txt runtime/doc/spell.txt runtime/doc/syntax.txt runtime/doc/tags runtime/doc/todo.txt runtime/doc/version7.txt runtime/plugin/netrw.vim runtime/spell/yi/!yi.diff runtime/spell/yi/README.txt runtime/spell/yi/yi.diff runtime/syntax/tex.vim src/edit.c src/option.c src/proto/spell.pro src/version.h
diffstat 19 files changed, 524 insertions(+), 221 deletions(-) [+]
line wrap: on
line diff
--- a/Filelist
+++ b/Filelist
@@ -688,6 +688,7 @@ LANG_GEN = \
 		runtime/spell/README.txt \
 		runtime/spell/??/*.diff \
 		runtime/spell/??/main.aap \
+		runtime/spell/yi/README.txt \
 		runtime/spell/main.aap \
 
 # generic language files, binary
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -1,4 +1,4 @@
-*eval.txt*      For Vim version 7.0aa.  Last change: 2005 Aug 05
+*eval.txt*      For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -3983,7 +3983,7 @@ soundfold({word})
 
 							*spellbadword()*
 spellbadword()	Return the badly spelled word under or after the cursor.
-		The cursor is advanced to the start of the bad word.
+		The cursor is moved to the start of the bad word.
 		When no bad word is found in the cursor line an empty String
 		is returned and the cursor doesn't move.
 
--- a/runtime/doc/insert.txt
+++ b/runtime/doc/insert.txt
@@ -1,4 +1,4 @@
-*insert.txt*    For Vim version 7.0aa.  Last change: 2005 Aug 01
+*insert.txt*    For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -354,6 +354,8 @@ CTRL-G CTRL-J	cursor one line down, inse
 <MouseUp>	scroll three lines up			     *i_<MouseUp>*
 <S-MouseUp>	scroll a full page up			     *i_<S-MouseUp>*
 CTRL-O		execute one command, return to Insert mode   *i_CTRL-O*
+CTRL-\ CTRL-O   like CTRL-O but don't move the cursor        *i_CTRL-\_CTRL-O*
+CTRL-L		when 'insertmode' is set: go to Normal mode  *i_CTRL-L*
 CTRL-G u	break undo sequence, start new change	     *i_CTRL-G_u*
 -----------------------------------------------------------------------
 
@@ -363,7 +365,8 @@ option.
 The CTRL-O command sometimes has a side effect: If the cursor was beyond the
 end of the line, it will be put on the last character in the line.  In
 mappings it's often better to use <Esc> (first put an "x" in the text, <Esc>
-will then always put the cursor on it).
+will then always put the cursor on it).  Or use CTRL-\ CTRL-O, but then
+beware of the cursor possibly being beyond the end of the line.
 
 The shifted cursor keys are not available on all terminals.
 
@@ -567,7 +570,8 @@ 8. definitions or macros				|i_CTRL-X_CT
 9. Vim command-line					|i_CTRL-X_CTRL-V|
 10. User defined completion				|i_CTRL-X_CTRL-U|
 11. Occult completion					|i_CTRL-X_CTRL-O|
-12. keywords in 'complete'				|i_CTRL-N|
+12. Spelling suggestions				|i_CTRL-X_s|
+13. keywords in 'complete'				|i_CTRL-N|
 
 All these (except 2) are done in CTRL-X mode.  This is a sub-mode of Insert
 and Replace modes.  You enter CTRL-X mode by typing CTRL-X and one of the
@@ -893,6 +897,25 @@ CTRL-X CTRL-O		Guess what kind of item i
 			previous one.
 
 
+Spelling suggestions					*compl-spelling*
+
+The word in front of the cursor is located and correctly spelled words are
+suggested to replace it.  The word doesn't actually have to be badly spelled.
+NOTE: CTRL-S suspends display in many Unix terminals.  Use 's' instead.  Type
+CTRL-Q to resume displaying.
+
+						*i_CTRL-X_CTRL-S* *i_CTRL-X_s*
+CTRL-X CTRL-S   or
+CTRL-X s		Locate the word in front of the cursor and find the
+			first spell suggestion for it.
+	CTRL-S	or
+	CTRL-N		Use the next suggestion.  This replaces the previous
+			one.  Note that you can't use 's' here.
+
+	CTRL-P		Use the previous suggestion.  This replaces the
+			previous one.
+
+
 Completing keywords from different sources		*compl-generic*
 
 							*i_CTRL-N*
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -1,4 +1,4 @@
-*options.txt*	For Vim version 7.0aa.  Last change: 2005 Aug 05
+*options.txt*	For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL	  by Bram Moolenaar
@@ -3732,9 +3732,9 @@ A jump table for the options with a shor
 	- Use CTRL-O to execute one Normal mode command |i_CTRL-O|).  When
 	  this is a mapping, it is executed as if 'insertmode' was off.
 	  Normal mode remains active until the mapping is finished.
-								*i_CTRL-L*
 	- Use CTRL-L to execute a number of Normal mode commands, then use
-	  <Esc> to get back to Insert mode.
+	  <Esc> to get back to Insert mode.  Note that CTRL-L moves the cursor
+	  left, like <Esc> does when 'insertmode' isn't set.  |i_CTRL-L|
 
 	These items change when 'insertmode' is set:
 	- when starting to edit of a file, Vim goes to Insert mode.
--- a/runtime/doc/pi_netrw.txt
+++ b/runtime/doc/pi_netrw.txt
@@ -1,4 +1,4 @@
-*pi_netrw.txt*  For Vim version 7.0.  Last change: Aug 08, 2005
+*pi_netrw.txt*  For Vim version 7.0.  Last change: Aug 09, 2005
 
 
 		VIM REFERENCE MANUAL    by Charles E. Campbell, Jr.
@@ -580,12 +580,12 @@ MAPS   								*netrw-maps*
      x................Customizing Browsing.......................|netrw-x|
 
     COMMANDS						*netrw-explore-cmds*
-     :Explore[!]  [dir].Explore directory of current file........|netrw-explore|
-     :Sexplore[!] [dir].Split & Explore directory of current file|netrw-explore|
-     :Hexplore[!] [dir].Horizontal Split & Explore...............|netrw-explore|
-     :Vexplore[!] [dir].Vertical Split & Explore.................|netrw-explore|
-     :Pexplore[!] [dir].Vertical Split & Explore.................|netrw-explore|
-     :Nexplore[!] [dir].Vertical Split & Explore.................|netrw-explore|
+     :Explore[!]  [dir] Explore directory of current file........|netrw-explore|
+     :Sexplore[!] [dir] Split & Explore directory ...............|netrw-explore|
+     :Hexplore[!] [dir] Horizontal Split & Explore...............|netrw-explore|
+     :Vexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
+     :Pexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
+     :Nexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
 
 QUICK REFERENCE COMMANDS TABLE     			*netrw-browse-cmds*
 >
@@ -745,28 +745,32 @@ ssh interaction, etc, see |netrw-list-ha
 				*netrw-hexplore* *netrw-sexplore*
 DIRECTORY EXPLORING COMMANDS	*netrw-nexplore* *netrw-vexplore*
 
-     :Explore[!]   [dir]... Explore directory of current file
-     :Sexplore[!]  [dir]... Split & Explore directory of current file
-     :Hexplore[!]  [dir]... Horizontal Split & Explore
-     :Vexplore[!]  [dir]... Vertical Split & Explore
-     :Nexplore............. used with **/patterns; go to next matching file
-     :Pexplore............. used with **/patterns; go to previous matching file
+     :Explore[!]   [dir]... Explore directory of current file       *:Explore*
+     :Sexplore[!]  [dir]... Split&Explore directory of current file *:Sexplore*
+     :Hexplore[!]  [dir]... Horizontal Split & Explore              *:Hexplore*
+     :Vexplore[!]  [dir]... Vertical   Split & Explore              *:Vexplore*
+
+     Used with :Explore **/pattern :
+     :Nexplore............. go to next matching file                *:Nexplore*
+     :Pexplore............. go to previous matching file            *:Pexplore*
 
-The Explore command will open the local-directory browser on the current
-file's directory (or on directory [dir] if specified).  The window will be
-split only if the file has been modified, otherwise the browsing window will
-take over that window.  Normally the splitting is taken horizontally; the
-optional ! will use vertical splitting.
+:Explore  will open the local-directory browser on the current file's
+          directory (or on directory [dir] if specified).  The window will be
+	  split only if the file has been modified, otherwise the browsing
+	  window will take over that window.  Normally the splitting is taken
+	  horizontally.
+:Explore! is like :Explore, but will use vertical splitting.
+:Sexplore will always split the window before invoking the local-directory
+          browser.  As with Explore, the splitting is normally done
+	  horizontally.
+:Sexplore! [dir] is like :Sexplore, but the splitting will be done vertically.
+:Hexplore  [dir] does an :Explore with |:belowright| horizontal splitting.
+:Hexplore! [dir] does an :Explore with |:aboveleft|  horizontal splitting.
+:Vexplore  [dir] does an :Explore with |:leftabove|  vertical splitting.
+:Vexplore! [dir] does an :Explore with |:rightbelow| vertical splitting.
 
-Sexplore will always split the window before invoking the local-directory
-browser.  As with Explore, the splitting is normally done horizontally, but
-with the optional ! the splitting will be done vertically.
-
-Hexplore does an Explore with |belowright| horizontal splitting; the
-optional ! does the Explore with |aboveleft| horizontal splitting.
-
-Vexplore does an Explore with |leftabove| vertical splitting; the
-optional "!" does an Explore with |topleft| vertical splitting.
+By default, these commands use the current file's directory.  However, one
+may explicitly provide a directory (path) to use.
 
 (Following needs v7.0 or later)			*netrw-starstar*
 When Explore, Sexplore, Hexplore, or Vexplore are used like
@@ -941,7 +945,7 @@ the "p" key when the cursor is atop the 
 SELECTING SORTING STYLE				*netrw-s* *netrw-sort*
 
 One may select the sorting style by name, time, or (file) size.  The
-"s" map allows one to circulate among the three choices; the directory
+"s" map allows one to circulate amongst the three choices; the directory
 listing will automatically be refreshed to reflect the selected style.
 
 
@@ -952,7 +956,7 @@ sequence (g:netrw_sort_sequence).  The s
 prioritizes the name-listing by suffix, although any pattern will do.
 Patterns are delimited by commas.  The default sorting sequence is:
 >
-	/$,*,\.bak$,\.o$,\.h$,\.info$,\.swp$,\.obj$
+	[\/]$,*,\.bak$,\.o$,\.h$,\.info$,\.swp$,\.obj$
 <
 The lone * is where all filenames not covered by one of the other
 patterns will end up.  One may change the sorting sequence by modifying
@@ -1072,7 +1076,7 @@ 8. Problems and Fixes						*netrw-proble
 
 	(This section is likely to grow as I get feedback)
 	(also see |netrw-debug|)
-
+								*netrw-p1*
 	P1. I use windows 95, and my ftp dumps four blank lines at the
 	    end of every read.
 
@@ -1081,8 +1085,7 @@ 8. Problems and Fixes						*netrw-proble
 
 			let g:netrw_win95ftp= 1
 
-
-
+								*netrw-p2*
 	P2. I use windows, and my network browsing with ftp doesn't sort by
 	    time or size
 
@@ -1100,6 +1103,7 @@ 8. Problems and Fixes						*netrw-proble
 
 			let g:netrw_cygwin= 1
 
+								*netrw-p3*
 	P3. I tried rcp://user@host/ (or protocol other than ftp) and netrw
 	    used ssh!  That wasn't what I asked for...
 
@@ -1108,6 +1112,7 @@ 8. Problems and Fixes						*netrw-proble
 		When it comes time to do download a file (not just a directory
 		listing), netrw will use the given protocol to do so.
 
+								*netrw-p4*
 	P4. I would like long listings to be the default.
 
 			let g:netrw_longlist=1
@@ -1115,6 +1120,7 @@ 8. Problems and Fixes						*netrw-proble
 		Check out |netrw-browse-var| for more customizations that
 		you can set.
 
+								*netrw-p5*
 	P5. My times come up oddly in local browsing
 
 		Does your system's strftime() accept the "%c" to yield dates
@@ -1123,6 +1129,7 @@ 8. Problems and Fixes						*netrw-proble
 		your <.vimrc>:
 			let g:netrw_timefmt= "%X"  (where X is the option)
 
+								*netrw-p6*
 	P6. I want my current directory to track my browsing.
 	    How do I do that?
 
@@ -1133,9 +1140,11 @@ 8. Problems and Fixes						*netrw-proble
 9. Debugging						*netrw-debug*
 
 The <netrw.vim> script is typically available as:
-
+>
 	/usr/local/share/vim/vim6x/plugin/netrw.vim
-
+< -or- >
+	/usr/local/share/vim/vim7x/plugin/netrw.vim
+<
 which is loaded automatically at startup (assuming :set nocp).
 
 	1. Get the <Decho.vim> script, available as:
@@ -1179,6 +1188,12 @@ which is loaded automatically at startup
 ==============================================================================
 10. History						*netrw-history*
 
+	v60: * when using the i map to switch between long and short listings,
+	       netrw will now keep cursor on same line
+	     * "Match # of #" now uses status line
+	     * :Explore **/*.c  will now work from a non-netrw-browser window
+	     * :Explore **/patterns can now be run in separate browser windows
+	     * active banner (hit <cr> will cause various things to happen)
 	v59: * bugfix -- another keepalt work-around installed (for vim6.3)
 	     * "Match # of #" for Explore **/pattern matches
 	v58: * Explore and relatives can now handle **/somefilepattern (v7)
--- a/runtime/doc/spell.txt
+++ b/runtime/doc/spell.txt
@@ -1,4 +1,4 @@
-*spell.txt*	For Vim version 7.0aa.  Last change: 2005 Jul 31
+*spell.txt*	For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL	  by Bram Moolenaar
@@ -145,6 +145,10 @@ z?			For the word under/after the cursor
 :spellr[epall]		Repeat the replacement done by |z?| for all matches
 			with the replaced word in the current window.
 
+In Insert mode, when the cursor is after a badly spelled word, you can use
+CTRL-X s to find suggestions.  This works like Insert mode completion.  Use
+CTRL-N to use the next suggestion, CTRL-P to go back. |i_CTRL-X_s|
+
 The 'spellsuggest' option influences how the list of suggestions is generated
 and sorted.  See |'spellsuggest'|.
 
--- a/runtime/doc/syntax.txt
+++ b/runtime/doc/syntax.txt
@@ -1,4 +1,4 @@
-*syntax.txt*	For Vim version 7.0aa.  Last change: 2005 Jul 29
+*syntax.txt*	For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL	  by Bram Moolenaar
@@ -399,7 +399,7 @@ Go back to the default to use 'number' b
    :unlet html_number_lines
 
 Closed folds are put in the HTML as they are displayed.  If you don't want
-this, use the "zR" command before invoking 2html, or use: >
+this, use the |zR| command before invoking 2html, or use: >
    :let html_ignore_folding = 1
 
 By default, HTML optimized for old browsers is generated.  If you prefer using
@@ -426,16 +426,13 @@ To go back to the automatic mechanism, d
 variable: >
    :unlet html_use_encoding
 <
-Closed folds are kept as they are displayed.  If you don't want closed folds
-in the HTML use the |zR| command before converting.
-
 For diff mode a sequence of more than 3 filler lines is displayed as three
 lines with the middle line mentioning the total number of inserted lines.  If
 you prefer to see all the inserted lines use: >
     :let html_whole_filler = 1
 And to go back to displaying up to three lines again: >
     :unlet html_whole_filler
-
+<
 					    *convert-to-XML* *convert-to-XHTML*
 An alternative is to have the script generate XHTML (XML compliant HTML).  To
 do this set the "use_xhtml" variable: >
@@ -2355,18 +2352,30 @@ number is that redrawing can become slow
 
 TEX						*tex.vim* *tex-syntax*
 
+*tex-folding*
+Want Syntax Folding? ~
+
+As of version 28 of <syntax/tex.vim>, syntax-based folding of parts, chapters,
+sections, subsections, etc are supported.  Put >
+	let g:tex_fold_enabled=1
+in your <.vimrc>, and :set fdm=syntax.  I suggest doing the latter via a
+modeline at the end of your LaTeX file: >
+	% vim: fdm=syntax
+<
+*tex-runon*
 Run-on Comments/Math? ~
 
-The tex highlighting supports TeX, LaTeX, and some AmsTeX.  The
-highlighting supports three primary zones: normal, texZone, and texMathZone.
-Although a considerable effort has been made to have these zones terminate
-properly, zones delineated by $..$ and $$..$$ cannot be synchronized as
-there's no difference between start and end patterns.  Consequently, a
+The <syntax/tex.vim> highlighting supports TeX, LaTeX, and some AmsTeX.  The
+highlighting supports three primary zones/regions: normal, texZone, and
+texMathZone.  Although considerable effort has been made to have these zones
+terminate properly, zones delineated by $..$ and $$..$$ cannot be synchronized
+as there's no difference between start and end patterns.  Consequently, a
 special "TeX comment" has been provided >
 	%stopzone
 which will forcibly terminate the highlighting of either a texZone or a
 texMathZone.
 
+*tex-slow*
 Slow Syntax Highlighting? ~
 
 If you have a slow computer, you may wish to reduce the values for >
@@ -2376,6 +2385,7 @@ If you have a slow computer, you may wis
 increase them.	This primarily affects synchronizing (i.e. just what group,
 if any, is the text at the top of the screen supposed to be in?).
 
+*tex-error*
 Excessive Error Highlighting? ~
 
 The <tex.vim> supports lexical error checking of various sorts.  Thus,
@@ -2383,28 +2393,24 @@ although the error checking is ofttimes 
 errors where none actually are.  If this proves to be a problem for you,
 you may put in your <.vimrc> the following statement: >
 	let tex_no_error=1
-and all error checking by <tex.vim> will be suppressed.
-
+and all error checking by <syntax/tex.vim> will be suppressed.
+
+*tex-math*
 Need a new Math Group? ~
 
 If you want to include a new math group in your LaTeX, the following
 code shows you an example as to how you might do so: >
-
-    syn cluster texMathZones add=texMathZoneLOCAL
-    syn region texMathZoneLOCAL start="\\begin\s*{\s*LOCALMATH\s*}"
-       \ end="\\end\s*{\s*LOCALMATH\s*}" keepend
-       \ contains=@texMathZoneGroup
-    if !exists("tex_no_math")
-     syn sync match texSyncMathZoneLOCAL grouphere texMathZoneLOCAL
-       \ "\\begin\s*{\s*LOCALMATH\*\s*}"
-     syn sync match texSyncMathZoneLOCAL groupthere NONE
-       \ "\\end\s*{\s*LOCALMATH\*\s*}"
-    endif
-    hi link texMathZoneLOCAL texMath
-<
-You'll need to change LOCALMATH to the name of your new math group,
-and then to put it into .vim/after/syntax/tex.vim.
-
+	call TexNewMathZone(sfx,mathzone,starform)
+You'll want to provide the new math group with a unique suffix
+(currently, A-L and V-Z are taken by <syntax/tex.vim> itself).
+As an example, consider how eqnarray is set up by <syntax/tex.vim>: >
+	call TexNewMathZone("D","eqnarray",1)
+You'll need to change "mathzone" to the name of your new math group,
+and then to the call to it in .vim/after/syntax/tex.vim.
+The "starform" variable, if true, implies that your new math group
+has a starred form (ie. eqnarray*).
+
+*tex-style*
 Starting a New Style? ~
 
 One may use "\makeatletter" in *.tex files, thereby making the use of "@" in
--- a/runtime/doc/tags
+++ b/runtime/doc/tags
@@ -4453,6 +4453,7 @@ compl-function	insert.txt	/*compl-functi
 compl-generic	insert.txt	/*compl-generic*
 compl-keyword	insert.txt	/*compl-keyword*
 compl-occult	insert.txt	/*compl-occult*
+compl-spelling	insert.txt	/*compl-spelling*
 compl-tag	insert.txt	/*compl-tag*
 compl-vim	insert.txt	/*compl-vim*
 compl-whole-line	insert.txt	/*compl-whole-line*
@@ -5317,7 +5318,7 @@ i_CTRL-H	insert.txt	/*i_CTRL-H*
 i_CTRL-I	insert.txt	/*i_CTRL-I*
 i_CTRL-J	insert.txt	/*i_CTRL-J*
 i_CTRL-K	insert.txt	/*i_CTRL-K*
-i_CTRL-L	options.txt	/*i_CTRL-L*
+i_CTRL-L	insert.txt	/*i_CTRL-L*
 i_CTRL-M	insert.txt	/*i_CTRL-M*
 i_CTRL-N	insert.txt	/*i_CTRL-N*
 i_CTRL-O	insert.txt	/*i_CTRL-O*
@@ -5342,17 +5343,20 @@ i_CTRL-X_CTRL-L	insert.txt	/*i_CTRL-X_CT
 i_CTRL-X_CTRL-N	insert.txt	/*i_CTRL-X_CTRL-N*
 i_CTRL-X_CTRL-O	insert.txt	/*i_CTRL-X_CTRL-O*
 i_CTRL-X_CTRL-P	insert.txt	/*i_CTRL-X_CTRL-P*
+i_CTRL-X_CTRL-S	insert.txt	/*i_CTRL-X_CTRL-S*
 i_CTRL-X_CTRL-T	insert.txt	/*i_CTRL-X_CTRL-T*
 i_CTRL-X_CTRL-U	insert.txt	/*i_CTRL-X_CTRL-U*
 i_CTRL-X_CTRL-V	insert.txt	/*i_CTRL-X_CTRL-V*
 i_CTRL-X_CTRL-Y	insert.txt	/*i_CTRL-X_CTRL-Y*
 i_CTRL-X_CTRL-]	insert.txt	/*i_CTRL-X_CTRL-]*
 i_CTRL-X_index	index.txt	/*i_CTRL-X_index*
+i_CTRL-X_s	insert.txt	/*i_CTRL-X_s*
 i_CTRL-Y	insert.txt	/*i_CTRL-Y*
 i_CTRL-Z	options.txt	/*i_CTRL-Z*
 i_CTRL-[	insert.txt	/*i_CTRL-[*
 i_CTRL-\_CTRL-G	intro.txt	/*i_CTRL-\\_CTRL-G*
 i_CTRL-\_CTRL-N	intro.txt	/*i_CTRL-\\_CTRL-N*
+i_CTRL-\_CTRL-O	insert.txt	/*i_CTRL-\\_CTRL-O*
 i_CTRL-]	insert.txt	/*i_CTRL-]*
 i_CTRL-^	insert.txt	/*i_CTRL-^*
 i_CTRL-_	insert.txt	/*i_CTRL-_*
@@ -5764,6 +5768,7 @@ netrw-ftp	pi_netrw.txt	/*netrw-ftp*
 netrw-h	pi_netrw.txt	/*netrw-h*
 netrw-handler	pi_netrw.txt	/*netrw-handler*
 netrw-help	pi_netrw.txt	/*netrw-help*
+netrw-hexplore	pi_netrw.txt	/*netrw-hexplore*
 netrw-history	pi_netrw.txt	/*netrw-history*
 netrw-horiz	pi_netrw.txt	/*netrw-horiz*
 netrw-i	pi_netrw.txt	/*netrw-i*
@@ -5773,6 +5778,7 @@ netrw-listhack	pi_netrw.txt	/*netrw-list
 netrw-maps	pi_netrw.txt	/*netrw-maps*
 netrw-move	pi_netrw.txt	/*netrw-move*
 netrw-netrc	pi_netrw.txt	/*netrw-netrc*
+netrw-nexplore	pi_netrw.txt	/*netrw-nexplore*
 netrw-nread	pi_netrw.txt	/*netrw-nread*
 netrw-nwrite	pi_netrw.txt	/*netrw-nwrite*
 netrw-o	pi_netrw.txt	/*netrw-o*
@@ -5780,6 +5786,7 @@ netrw-options	pi_netrw.txt	/*netrw-optio
 netrw-p	pi_netrw.txt	/*netrw-p*
 netrw-passwd	pi_netrw.txt	/*netrw-passwd*
 netrw-path	pi_netrw.txt	/*netrw-path*
+netrw-pexplore	pi_netrw.txt	/*netrw-pexplore*
 netrw-preview	pi_netrw.txt	/*netrw-preview*
 netrw-problems	pi_netrw.txt	/*netrw-problems*
 netrw-protocol	pi_netrw.txt	/*netrw-protocol*
@@ -5790,8 +5797,10 @@ netrw-ref	pi_netrw.txt	/*netrw-ref*
 netrw-rename	pi_netrw.txt	/*netrw-rename*
 netrw-reverse	pi_netrw.txt	/*netrw-reverse*
 netrw-s	pi_netrw.txt	/*netrw-s*
+netrw-sexplore	pi_netrw.txt	/*netrw-sexplore*
 netrw-sort	pi_netrw.txt	/*netrw-sort*
 netrw-sortsequence	pi_netrw.txt	/*netrw-sortsequence*
+netrw-starstar	pi_netrw.txt	/*netrw-starstar*
 netrw-transparent	pi_netrw.txt	/*netrw-transparent*
 netrw-u	pi_netrw.txt	/*netrw-u*
 netrw-uidpass	pi_netrw.txt	/*netrw-uidpass*
@@ -5800,6 +5809,7 @@ netrw-urls	pi_netrw.txt	/*netrw-urls*
 netrw-v	pi_netrw.txt	/*netrw-v*
 netrw-var	pi_netrw.txt	/*netrw-var*
 netrw-variables	pi_netrw.txt	/*netrw-variables*
+netrw-vexplore	pi_netrw.txt	/*netrw-vexplore*
 netrw-write	pi_netrw.txt	/*netrw-write*
 netrw-x	pi_netrw.txt	/*netrw-x*
 netrw-xfer	pi_netrw.txt	/*netrw-xfer*
--- a/runtime/doc/todo.txt
+++ b/runtime/doc/todo.txt
@@ -1,4 +1,4 @@
-*todo.txt*      For Vim version 7.0aa.  Last change: 2005 Aug 10
+*todo.txt*      For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL	  by Bram Moolenaar
@@ -33,9 +33,6 @@ be worked on, but only if you sponsor Vi
 Spell checking: default value for 'spellcapcheck' in spell file?
 For Hebrew and Yiddish it should be empty.
 
-When 'insertmode' is set, CTRL-L no longer moves the cursor left.  What
-compatibility problems does this cause?
-
 Using "@:" has two problems (Tim Chase, 2005 Aug 9)
 
 Mac unicode patch (Da Woon Jung):
--- a/runtime/doc/version7.txt
+++ b/runtime/doc/version7.txt
@@ -1,4 +1,4 @@
-*version7.txt*  For Vim version 7.0aa.  Last change: 2005 Aug 09
+*version7.txt*  For Vim version 7.0aa.  Last change: 2005 Aug 11
 
 
 		  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -331,6 +331,11 @@ CTRL-W <Enter>		In the quickfix window: 
 |at| and |it| text objects select a block of text between HTML or XML tags.
 
 
+Insert mode commands: ~
+
+CTRL-\ CTRL-O		Execute a Normal mode command.  Like CTRL-O but
+			without moving the cursor.
+
 Options: ~
 
 'completefunc'		The name of a function used for user-specified Insert
@@ -1274,7 +1279,4 @@ were not set.
 
 Win32: Could not use "**/" in 'path', it had to be "**\".
 
-When 'insertmode' is set CTRL-L would move the cursor.  That wasn't supposed
-to happen, CTRL-O doesn't do it either.
-
  vim:tw=78:ts=8:ft=help:norl:
--- a/runtime/plugin/netrw.vim
+++ b/runtime/plugin/netrw.vim
@@ -1,7 +1,7 @@
 " netrw.vim: Handles file transfer and remote directory listing across a network
-" Last Change:	Aug 08, 2005
+" Last Change:	Aug 10, 2005
 " Maintainer:	Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
-" Version:	59
+" Version:	60
 " License:	Vim License  (see vim's :help license)
 " Copyright:    Copyright (C) 1999-2005 Charles E. Campbell, Jr.
 "               Permission is hereby granted to use and distribute this code,
@@ -22,9 +22,11 @@
 if exists("g:loaded_netrw") || &cp
   finish
 endif
-let g:loaded_netrw  = "v59"
-let loaded_explorer = 1
-let s:keepcpo       = &cpo
+let g:loaded_netrw  = "v60"
+if v:version < 700
+ let loaded_explorer = 1
+endif
+let s:keepcpo= &cpo
 set cpo&vim
 
 " ---------------------------------------------------------------------
@@ -255,28 +257,28 @@ com! -nargs=? -bar -bang   		Pexplore	ca
 fun! s:NetSavePosn()
 "  call Dfunc("NetSavePosn()")
   " Save current line and column
-  let s:netrw_winnr= winnr()
-  let s:netrw_line = line(".")
-  let s:netrw_col  = virtcol(".")
+  let w:netrw_winnr= winnr()
+  let w:netrw_line = line(".")
+  let w:netrw_col  = virtcol(".")
 
   " Save top-of-screen line
   norm! H0
-  let s:netrw_hline= line(".")
+  let w:netrw_hline= line(".")
 
   call s:NetRestorePosn()
-"  call Dret("NetSavePosn : winnr=".s:netrw_winnr." line=".s:netrw_line." col=".s:netrw_col." hline=".s:netrw_hline)
+"  call Dret("NetSavePosn : winnr=".w:netrw_winnr." line=".w:netrw_line." col=".w:netrw_col." hline=".w:netrw_hline)
 endfun
 
 " ------------------------------------------------------------------------
 " NetRestorePosn: restores the cursor and file position as saved by NetSavePosn() {{{1
 fun! <SID>NetRestorePosn()
-"  call Dfunc("NetRestorePosn() winnr=".s:netrw_winnr." line=".s:netrw_line." col=".s:netrw_col." hline=".s:netrw_hline)
+"  call Dfunc("NetRestorePosn() winnr=".w:netrw_winnr." line=".w:netrw_line." col=".w:netrw_col." hline=".w:netrw_hline)
   let eikeep= &ei
   set ei=all
 
   " restore window
-"  call Decho("restore window: exe silent! ".s:netrw_winnr."wincmd w")
-  exe "silent! ".s:netrw_winnr."wincmd w"
+"  call Decho("restore window: exe silent! ".w:netrw_winnr."wincmd w")
+  exe "silent! ".w:netrw_winnr."wincmd w"
 "  if v:shell_error == 0
 "   " as suggested by Bram M: redraw on no error
 "   " allows protocol error messages to remain visible
@@ -284,12 +286,12 @@ fun! <SID>NetRestorePosn()
 "  endif
 
   " restore top-of-screen line
-"  call Decho("restore topofscreen: exe norm! ".s:netrw_hline."G0z")
-  exe "norm! ".s:netrw_hline."G0z\<CR>"
+"  call Decho("restore topofscreen: exe norm! ".w:netrw_hline."G0z")
+  exe "norm! ".w:netrw_hline."G0z\<CR>"
 
   " restore position
-"  call Decho("restore posn: exe norm! ".s:netrw_line."G0".s:netrw_col."|")
-  exe "norm! ".s:netrw_line."G0".s:netrw_col."\<bar>"
+"  call Decho("restore posn: exe norm! ".w:netrw_line."G0".w:netrw_col."|")
+  exe "norm! ".w:netrw_line."G0".w:netrw_col."\<bar>"
 
   let &ei= eikeep
 "  call Dret("NetRestorePosn")
@@ -1050,6 +1052,12 @@ endfun
 fun! <SID>NetBrowse(dirname)
 "  call Dfunc("NetBrowse(dirname<".a:dirname.">) longlist=".g:netrw_longlist)
 
+  if exists("s:netrw_skipbrowse")
+   unlet s:netrw_skipbrowse
+"   call Dret("NetBrowse")
+   return
+  endif
+
   " sanity check
   if exists("b:netrw_method") && b:netrw_method =~ '[235]'
 "   call Decho("b:netrw_method=".b:netrw_method)
@@ -1106,8 +1114,8 @@ fun! <SID>NetBrowse(dirname)
   endif
 
   if exists("b:netrw_method")
-"   call Decho("setting s:netrw_method<".b:netrw_method.">")
-   let s:netrw_method= b:netrw_method
+"   call Decho("setting w:netrw_method<".b:netrw_method.">")
+   let w:netrw_method= b:netrw_method
   endif
 
   " optionally sort by time (-t) or by size (-S)
@@ -1200,14 +1208,14 @@ fun! <SID>NetBrowse(dirname)
   nnoremap <buffer> <silent> B		:<c-u>call <SID>NetBookmarkDir(1,expand("%"))<cr>
   nnoremap <buffer> <silent> <c-h>	:call <SID>NetHideEdit(0)<cr>
   nnoremap <buffer> <silent> i		:call <SID>NetLongList(0)<cr>
-  nnoremap <buffer> <silent> o		:exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"<bar>exe "norm! 0"<bar>call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()))<cr>
+  nnoremap <buffer> <silent> o		:call <SID>NetSplit(0)<cr>
   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetBookmarkDir(2,expand("%"))<cr>
   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),'./'))<cr>
   nnoremap <buffer> <silent> s		:call <SID>NetSaveWordPosn()<bar>let g:netrw_sort_by= (g:netrw_sort_by =~ 'n')? 'time' : (g:netrw_sort_by =~ 't')? 'size' : 'name'<bar>exe "norm! 0"<bar>call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),'./'))<bar>call <SID>NetRestoreWordPosn()<cr>
   nnoremap <buffer> <silent> S		:call <SID>NetSortSequence(0)<cr>
   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetBookmarkDir(4,expand("%"))<cr>
   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetBookmarkDir(5,expand("%"))<cr>
-  nnoremap <buffer> <silent> v		:exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"<bar>exe "norm! 0"<bar>call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()))<cr>
+  nnoremap <buffer> <silent> v		:call <SID>NetSplit(1)<cr>
   nnoremap <buffer> <silent> x		:exe "norm! 0"<bar>call <SID>NetBrowseX(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()),1)<cr>
   nnoremap <buffer> <silent> <2-leftmouse> :exe "norm! 0"<bar>call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()))<cr>
   exe 'nnoremap <buffer> <silent> <del>	:exe "norm! 0"<bar>call <SID>NetBrowseRm("'.user.machine.'","'.path.'")<cr>'
@@ -1225,15 +1233,15 @@ fun! <SID>NetBrowse(dirname)
   keepjumps put ='\" ==========================================================================='
   keepjumps put ='\" Netrw Remote Directory Listing'
   keepjumps put ='\"   '.bufname
-  let s:netrw_bannercnt= 7
-  let sortby= g:netrw_sort_by
+  let w:netrw_bannercnt = 7
+  let sortby            = g:netrw_sort_by
   if g:netrw_sort_direction =~ "^r"
-   let sortby= sortby." reversed"
+   let sortby           = sortby." reversed"
   endif
 
   if g:netrw_sort_by =~ "^n"
    " sorted by name
-   let s:netrw_bannercnt= s:netrw_bannercnt + 1
+   let w:netrw_bannercnt= w:netrw_bannercnt + 1
    keepjumps put ='\"   Sorted by      '.sortby
    keepjumps put ='\"   Sort sequence: '.g:netrw_sort_sequence
   else
@@ -1246,7 +1254,7 @@ fun! <SID>NetBrowse(dirname)
    else
     keepjumps put ='\"   Showing:       '.g:netrw_list_hide
    endif
-   let s:netrw_bannercnt= s:netrw_bannercnt + 1
+   let w:netrw_bannercnt= w:netrw_bannercnt + 1
   endif
   keepjumps put ='\"   Quick Help:    ?:help  -:go up dir  D:delete  R:rename  s:sort-by  x:exec'
   keepjumps put ='\" ==========================================================================='
@@ -1263,7 +1271,7 @@ fun! <SID>NetBrowse(dirname)
    if !g:netrw_longlist
     " shorten the listing
 "    call Decho("generate short listing")
-    exe "keepjumps ".s:netrw_bannercnt
+    exe "keepjumps ".w:netrw_bannercnt
 
     " cleanup
     if g:netrw_ftp_browse_reject != ""
@@ -1283,9 +1291,9 @@ fun! <SID>NetBrowse(dirname)
     keepjumps norm! 0
 
     " more cleanup
-    exe 'keepjumps silent! '.s:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2/e'
-    exe "keepjumps silent! ".s:netrw_bannercnt.',$g/ -> /s# -> .*/$#/#e'
-    exe "keepjumps silent! ".s:netrw_bannercnt.',$g/ -> /s# -> .*$#/#e'
+    exe 'keepjumps silent! '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2/e'
+    exe "keepjumps silent! ".w:netrw_bannercnt.',$g/ -> /s# -> .*/$#/#e'
+    exe "keepjumps silent! ".w:netrw_bannercnt.',$g/ -> /s# -> .*$#/#e'
    endif
 
   else
@@ -1315,7 +1323,7 @@ fun! <SID>NetBrowse(dirname)
   endif
 
   " manipulate the directory listing (hide, sort)
-  if line("$") >= s:netrw_bannercnt
+  if line("$") >= w:netrw_bannercnt
    if g:netrw_hide && g:netrw_list_hide != ""
     call s:NetrwListHide()
    endif
@@ -1326,7 +1334,7 @@ fun! <SID>NetBrowse(dirname)
 
     if method == "ftp"
      " cleanup
-     exe "keepjumps ".s:netrw_bannercnt
+     exe "keepjumps ".w:netrw_bannercnt
      while getline(".") =~ g:netrw_ftp_browse_reject
       keepjumps d
      endwhile
@@ -1336,37 +1344,37 @@ fun! <SID>NetBrowse(dirname)
      silent keepjumps call search('^\.\.\/\%(\s\|$\)','W')
      let line2= line(".")
      if line2 == 0
-      exe 'keepjumps '.s:netrw_bannercnt."put='./'"
-      exe 'keepjumps '.s:netrw_bannercnt."put='../'"
+      exe 'keepjumps '.w:netrw_bannercnt."put='./'"
+      exe 'keepjumps '.w:netrw_bannercnt."put='../'"
      endif
     exe "keepjumps ".line1
     keepjumps norm! 0
     endif
 
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$s/ -> .*$//e'
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2\t\1/e'
-    exe s:netrw_bannercnt
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$s/ -> .*$//e'
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2\t\1/e'
+    exe w:netrw_bannercnt
    endif
 
-   if line("$") >= s:netrw_bannercnt
+   if line("$") >= w:netrw_bannercnt
     if g:netrw_sort_by =~ "^n"
      call s:SetSort()
      if v:version < 700
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$call s:NetSort()'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$call s:NetSort()'
      elseif g:netrw_sort_direction =~ 'n'
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort'
      else
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort!'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort!'
      endif
-     exe 'keepjumps silent '.s:netrw_bannercnt.',$s/^\d\{3}\///e'
+     exe 'keepjumps silent '.w:netrw_bannercnt.',$s/^\d\{3}\///e'
     endif
     if g:netrw_longlist
      " shorten the list to keep its width <= 80 characters
-     exe "keepjumps silent ".s:netrw_bannercnt.',$s/\t[-dstrwx]\+/\t/e'
+     exe "keepjumps silent ".w:netrw_bannercnt.',$s/\t[-dstrwx]\+/\t/e'
     endif
    endif
   endif
-  exe "keepjumps ".s:netrw_bannercnt
+  exe "keepjumps ".w:netrw_bannercnt
 
   setlocal nomod noma nonu
 
@@ -1421,8 +1429,27 @@ endfun
 "  NetGetWord: it gets the directory named under the cursor
 fun! <SID>NetGetWord()
 "  call Dfunc("NetGetWord() line#".line("."))
-  if line(".") < s:netrw_bannercnt
+  if exists("w:netrw_bannercnt") && line(".") < w:netrw_bannercnt
    let dirname= "./"
+   let curline= getline(".")
+   if curline =~ '"\s*Sorted by\s'
+    norm s
+    let s:netrw_skipbrowse= 1
+    echo 'Pressing "s" also works'
+   elseif curline =~ '"\s*Sort sequence:'
+    let s:netrw_skipbrowse= 1
+    echo 'Press "S" to edit sorting sequence'
+   elseif curline =~ '"\s*Quick Help:'
+    norm ?
+    let s:netrw_skipbrowse= 1
+    echo 'Pressing "?" also works'
+   elseif curline =~ '"\s*\%(Hiding\|Showing\):'
+    norm a
+    let s:netrw_skipbrowse= 1
+    echo 'Pressing "a" also works'
+   elseif line("$") > w:netrw_bannercnt
+    exe w:netrw_bannercnt
+   endif
   else
    let dirname= getline(".")
    if dirname =~ '\t'
@@ -1466,7 +1493,7 @@ fun! <SID>NetBrowseRm(usrhost,path) rang
     endif
 
     if all || ok =~ 'y\%[es]' || ok == ""
-     if exists("s:netrw_method") && (s:netrw_method == 2 || s:netrw_method == 3)
+     if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
       silent! keepjumps .,$d
       call NetBrowseFtpCmd(a:path,"delete ".rmfile)
      else
@@ -1492,7 +1519,7 @@ fun! <SID>NetBrowseRm(usrhost,path) rang
     endif
 
     if all || ok =~ 'y\%[es]' || ok == ""
-     if exists("s:netrw_method") && (s:netrw_method == 2 || s:netrw_method == 3)
+     if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
       call NetBrowseFtpCmd(a:path,"rmdir ".rmfile)
      else
       let rmfile         = a:path.rmfile
@@ -1552,7 +1579,7 @@ fun! <SID>NetBrowseRename(usrhost,path) 
    let newname= input("Moving ".oldname." to : ",oldname)
    call inputrestore()
 
-   if exists("s:netrw_method") && (s:netrw_method == 2 || s:netrw_method == 3)
+   if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
     call NetBrowseFtpCmd(a:path,"rename ".oldname." ".newname)
    else
     let oldname= a:path.oldname
@@ -1583,6 +1610,41 @@ fun! <SID>NetRefresh(dirname)
 endfun
 
 " ---------------------------------------------------------------------
+" NetSplit: mode {{{2
+"           =0 : net   and o
+"           =1 : net   and v
+"           =2 : local and o
+"           =3 : local and v
+fun! s:NetSplit(mode)
+"  call Dfunc("NetSplit(mode=".a:mode.")")
+
+  call s:SaveWinVars()
+  if a:mode == 0
+   exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
+   call s:CopyWinVars()
+   exe "norm! 0"
+   call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()))
+  elseif a:mode ==1
+   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
+   call s:CopyWinVars()
+   exe "norm! 0"
+   call <SID>NetBrowse(<SID>NetBrowseChgDir(expand("%"),<SID>NetGetWord()))
+  elseif a:mode ==2
+   exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
+   call s:CopyWinVars()
+   exe "norm! 0"
+   call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord()))
+  else
+   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
+   call s:CopyWinVars()
+   exe "norm! 0"
+   call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord()))
+  endif
+
+"  call Dret("NetSplit")
+endfun
+
+" ---------------------------------------------------------------------
 " NetBrowseX:  allows users to write custom functions to operate on {{{2
 "              files given their extension.  Passes 0=local, 1=remote
 fun! <SID>NetBrowseX(fname,remote)
@@ -1661,7 +1723,7 @@ endfun
 "  and reverse sorts will be requested of the server but not otherwise
 "  enforced here.
 fun! NetBrowseFtpCmd(path,cmd)
-"  call Dfunc("NetBrowseFtpCmd(path<".a:path."> cmd<".a:cmd.">) netrw_method=".s:netrw_method)
+"  call Dfunc("NetBrowseFtpCmd(path<".a:path."> cmd<".a:cmd.">) netrw_method=".w:netrw_method)
 
   " because WinXX ftp uses unix style input
   " curline is one more than the bannercnt in order to account
@@ -1669,11 +1731,11 @@ fun! NetBrowseFtpCmd(path,cmd)
   " buffer yields a blank first line)
   let ffkeep= &ff
   setlocal ma ff=unix
-  let curline= s:netrw_bannercnt+1
+  let curline= w:netrw_bannercnt+1
   exe "silent! keepjumps ".curline.",$d"
 
    ".........................................
-  if s:netrw_method == 2 || s:netrw_method == 5
+  if w:netrw_method == 2 || w:netrw_method == 5
    " ftp + <.netrc>:  Method #2
    if a:path != ""
     put ='cd '.a:path
@@ -1689,7 +1751,7 @@ fun! NetBrowseFtpCmd(path,cmd)
    endif
 
    ".........................................
-  elseif s:netrw_method == 3
+  elseif w:netrw_method == 3
    " ftp + machine,id,passwd,filename:  Method #3
     setlocal ff=unix
     if exists("g:netrw_port") && g:netrw_port != ""
@@ -1759,9 +1821,9 @@ fun! <SID>NetrwListHide()
    " Prune the list by hiding any files which match
 "   call Decho("pruning <".hide."> listhide<".listhide.">")
    if g:netrw_hide == 1
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$g~'.hide.'~d'
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$g~'.hide.'~d'
    elseif g:netrw_hide == 2
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$v~'.hide.'~d'
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$v~'.hide.'~d'
    endif
   endwhile
 
@@ -1838,7 +1900,8 @@ fun! <SID>NetLongList(mode)
    silent call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,"./"))
   endif
 
-"  call s:NetRestorePosn()
+  call s:NetRestorePosn()
+
 "  call Dret("NetLongList : g:netrw_longlist=".g:netrw_longlist)
 endfun
 
@@ -1964,6 +2027,15 @@ endfun
 "    5: (user: <U>)   go down (next)     bookmark
 fun! <SID>NetBookmarkDir(chg,curdir)
 "  call Dfunc("NetBookmarkDir(chg=".a:chg." curdir<".a:curdir.">) cnt=".v:count)
+  if exists("w:netrw_bannercnt") && line(".") <= w:netrw_bannercnt
+   " looks like a "b" was pressed while in the banner region
+   if line("$") > w:netrw_bannercnt
+    exe w:netrw_bannercnt
+   endif
+   echo ""
+"  call Dret("NetBookmarkDir - ignoring")
+   return
+  endif
 
   if a:chg == 0
    " bookmark the current directory
@@ -1973,6 +2045,7 @@ fun! <SID>NetBookmarkDir(chg,curdir)
    elseif v:count > g:NETRW_BOOKMARKMAX
     let g:NETRW_BOOKMARKMAX= v:count
    endif
+   echo "bookmarked the current directory"
 
   elseif a:chg == 1
    " change to the bookmarked directory
@@ -2072,6 +2145,12 @@ fun! <SID>LocalBrowse(dirname)
 "  call Dfunc("LocalBrowse(dirname<".a:dirname.">) buf#".bufnr("%")." winnr=".winnr()." sortby=".g:netrw_sort_by)
 "  call Dredir("ls!")
 
+  if exists("s:netrw_skipbrowse")
+   unlet s:netrw_skipbrowse
+"   call Dret("NetBrowse")
+   return
+  endif
+
   if v:version < 603
    if !exists("g:netrw_quiet")
     echohl Error | echo "***netrw*** vim version<".v:version."> too old for browsing with netrw" | echohl None
@@ -2142,7 +2221,18 @@ fun! <SID>LocalBrowse(dirname)
   " make netrw's idea of the current directory vim's if the user wishes
   if !g:netrw_keepdir
 "   call Decho("change directory: cd ".b:netrw_curdir)
-   exe 'cd '.b:netrw_curdir
+   try
+    exe 'cd '.b:netrw_curdir
+   catch /^Vim\%((\a\+)\)\=:E472/
+    echohl Error | echo "***netrw*** unable to change directory to <".b:netrw_curdir."> (permissions?)" | echohl None
+    call inputsave()|call input("Press <cr> to continue")|call inputrestore()
+    if exists("w:netrw_prvdir")
+     let b:netrw_curdir= w:netrw_prvdir
+    else
+"     call Dret("LocalBrowse : reusing buffer#".bufnum."<".a:dirname.">")
+     return
+    endif
+   endtry
   endif
 
   " change the name of the buffer to reflect the b:netrw_curdir
@@ -2174,7 +2264,7 @@ fun! <SID>LocalBrowse(dirname)
   nnoremap <buffer> <silent> d		:call <SID>NetMakeDir("")<cr>
   nnoremap <buffer> <silent> <c-h>	:call <SID>NetHideEdit(1)<cr>
   nnoremap <buffer> <silent> i		:call <SID>NetLongList(1)<cr>
-  nnoremap <buffer> <silent> o		:exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"<bar>exe "norm! 0"<bar>call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord()))<cr>
+  nnoremap <buffer> <silent> o		:call <SID>NetSplit(2)<cr>
   nnoremap <buffer> <silent> p		:exe "norm! 0"<bar>call <SID>LocalPreview(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord(),1))<cr>
   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetBookmarkDir(2,b:netrw_curdir)<cr>
   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,'./'))<cr>
@@ -2182,7 +2272,7 @@ fun! <SID>LocalBrowse(dirname)
   nnoremap <buffer> <silent> S		:call <SID>NetSortSequence(1)<cr>
   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetBookmarkDir(4,expand("%"))<cr>
   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetBookmarkDir(5,expand("%"))<cr>
-  nnoremap <buffer> <silent> v		:exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"<bar>exe "norm! 0"<bar>call <SID>LocalBrowse(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord()))<cr>
+  nnoremap <buffer> <silent> v		:call <SID>NetSplit(3)<cr>
   nnoremap <buffer> <silent> x		:exe "norm! 0"<bar>call <SID>NetBrowseX(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord(),0),0)<cr>
   nnoremap <buffer> <silent> <2-leftmouse> :exe "norm! 0"<bar>call <SID>LocalRefresh(<SID>LocalBrowseChgDir(b:netrw_curdir,<SID>NetGetWord()))<cr>
   nnoremap <buffer> <silent> <s-up>	:Pexplore<cr>
@@ -2202,7 +2292,7 @@ fun! <SID>LocalBrowse(dirname)
   keepjumps 1d
   keepjumps put ='\" Directory Listing                                              (netrw '.g:loaded_netrw.')'
   keepjumps put ='\"   '.b:netrw_curdir
-  let s:netrw_bannercnt= 3
+  let w:netrw_bannercnt= 3
 
   let sortby= g:netrw_sort_by
   if g:netrw_sort_direction =~ "^r"
@@ -2215,12 +2305,12 @@ fun! <SID>LocalBrowse(dirname)
    " sorted by name
    keepjumps put ='\"   Sorted by      '.sortby
    keepjumps put ='\"   Sort sequence: '.g:netrw_sort_sequence
-   let s:netrw_bannercnt= s:netrw_bannercnt + 2
+   let w:netrw_bannercnt= w:netrw_bannercnt + 2
   else
 "   call Decho("directories will be sorted by size or date")
    " sorted by size or date
    keepjumps put ='\"   Sorted by '.sortby
-   let s:netrw_bannercnt= s:netrw_bannercnt + 1
+   let w:netrw_bannercnt= w:netrw_bannercnt + 1
   endif
 
   " Hiding...  -or-  Showing...
@@ -2230,15 +2320,15 @@ fun! <SID>LocalBrowse(dirname)
    else
     keepjumps put ='\"   Showing:       '.g:netrw_list_hide
    endif
-   let s:netrw_bannercnt= s:netrw_bannercnt + 1
+   let w:netrw_bannercnt= w:netrw_bannercnt + 1
   endif
   keepjumps put ='\"   Quick Help:    ?:help  -:go up dir  D:delete  R:rename  s:sort-by  x:exec'
   keepjumps put ='\" ============================================================================'
-  let s:netrw_bannercnt= s:netrw_bannercnt + 2
+  let w:netrw_bannercnt= w:netrw_bannercnt + 2
 
   " bannercnt should index the line just after the banner
-  let s:netrw_bannercnt= s:netrw_bannercnt + 1
-"  call Decho("bannercnt=".s:netrw_bannercnt)
+  let w:netrw_bannercnt= w:netrw_bannercnt + 1
+"  call Decho("bannercnt=".w:netrw_bannercnt)
 
   " generate the requested directory listing
   call LocalBrowseList()
@@ -2252,38 +2342,43 @@ fun! <SID>LocalBrowse(dirname)
   endif
 
   " manipulate the directory listing (hide, sort)
-  if line("$") >= s:netrw_bannercnt
+  if line("$") >= w:netrw_bannercnt
    if g:netrw_hide && g:netrw_list_hide != ""
     call s:NetrwListHide()
    endif
-   if line("$") >= s:netrw_bannercnt
+   if line("$") >= w:netrw_bannercnt
 
     if g:netrw_sort_by =~ "^n"
      call s:SetSort()
 
      if v:version < 700
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$call s:NetSort()'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$call s:NetSort()'
      elseif g:netrw_sort_direction =~ 'n'
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort'
      else
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort!'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort!'
      endif
-     exe 'keepjumps silent '.s:netrw_bannercnt.',$s/^\d\{3}\///e'
+     exe 'keepjumps silent '.w:netrw_bannercnt.',$s/^\d\{3}\///e'
 
     else
      if v:version < 700
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$call s:NetSort()'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$call s:NetSort()'
      elseif g:netrw_sort_direction =~ 'n'
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort'
      else
-      exe 'keepjumps silent '.s:netrw_bannercnt.',$sort!'
+      exe 'keepjumps silent '.w:netrw_bannercnt.',$sort!'
      endif
-     exe 'keepjumps silent '.s:netrw_bannercnt.',$s/^\d\{-}\///e'
+     exe 'keepjumps silent '.w:netrw_bannercnt.',$s/^\d\{-}\///e'
     endif
 
    endif
   endif
-  exe s:netrw_bannercnt
+  if exists("w:netrw_bannercnt") && line("$") > w:netrw_bannercnt
+   exe w:netrw_bannercnt
+  endif
+
+  " record previous current directory
+  let w:netrw_prvdir= b:netrw_curdir
 
   setlocal noma nomod nonu bh=hide nobl
   if has("netbeans_intg") || has("sun_workshop")
@@ -2454,7 +2549,7 @@ fun! <SID>LocalBrowseRm(path) range
    exe "keepjumps ".ctr
 
    " sanity checks
-   if line(".") < s:netrw_bannercnt
+   if line(".") < w:netrw_bannercnt
     let ctr= ctr + 1
     continue
    endif
@@ -2558,7 +2653,7 @@ fun! <SID>LocalBrowseRename(path) range
    exe "keepjumps ".ctr
 
    " sanity checks
-   if line(".") < s:netrw_bannercnt
+   if line(".") < w:netrw_bannercnt
     let ctr= ctr + 1
     continue
    endif
@@ -2630,46 +2725,67 @@ fun! s:Explore(indx,dosplit,style,...)
 
   " if dosplit or file has been modified
   if a:dosplit || &modified
+   call <SID>SaveWinVars()
+
    if a:style == 0      " Explore, Sexplore
     exe g:netrw_winsize."wincmd s"
+"    call Decho("style=0: Explore or Sexplore")
+
    elseif a:style == 1  "Explore!, Sexplore!
     exe g:netrw_winsize."wincmd v"
+"    call Decho("style=1: Explore! or Sexplore!")
+
    elseif a:style == 2  " Hexplore
     exe "bel ".g:netrw_winsize."wincmd s"
+"    call Decho("style=2: Hexplore")
+
    elseif a:style == 3  " Hexplore!
     exe "abo ".g:netrw_winsize."wincmd s"
+"    call Decho("style=3: Hexplore!")
+
    elseif a:style == 4  " Vexplore
     exe "lefta ".g:netrw_winsize."wincmd v"
+"    call Decho("style=4: Vexplore")
+
    elseif a:style == 5  " Vexplore!
     exe "rightb ".g:netrw_winsize."wincmd v"
+"    call Decho("style=5: Vexplore!")
    endif
+   call s:CopyWinVars()
   endif
   norm! 0
 
   if a:1 == "" && a:indx >= 0
-   let newdir= substitute(expand("%:p"),'^\(.*\)[/\\][^/\\]*$','\1','e')
-"   call Decho("calling LocalBrowse(newdir<".newdir.">)")
-   call s:LocalBrowse(newdir)
+   " Explore Hexplore Vexplore Sexplore
+   let newdir= substitute(expand("%:p"),'^\(.*[/\\]\)[^/\\]*$','\1','e')
+   if newdir =~ '^scp:' || newdir =~ '^ftp:'
+"    call Decho("calling NetBrowse(newdir<".newdir.">)")
+    call s:NetBrowse(newdir)
+   else
+"    call Decho("calling LocalBrowse(newdir<".newdir.">)")
+    call s:LocalBrowse(newdir)
+   endif
 
   elseif a:1 =~ '\*\*/' || a:indx < 0
+   " Nexplore Pexplore -or-  Explore **/...
 
-   if has("path_extra")
-    if !exists("s:explore_indx")
-     let s:explore_indx= 0
+   if has("path_extra") && v:version >= 700
+    if !exists("w:netrw_explore_indx")
+     let w:netrw_explore_indx= 0
     endif
     let indx = a:indx
     if indx == -1
-     let indx= s:explore_indx + 1
+     let indx= w:netrw_explore_indx + 1
     elseif indx == -2
-     let indx= s:explore_indx - 1
+     let indx= w:netrw_explore_indx - 1
     else
-     let s:explore_indx    = 0
+     let w:netrw_explore_indx    = 0
      if !exists("b:netrw_curdir")
-       let b:netrw_curdir = "."
+      let b:netrw_curdir= getcwd()
      endif
-     let s:explorelist     = split(expand(b:netrw_curdir."/".a:1),'\n')
-     let s:explore_listlen = len(s:explorelist)
-     if s:explore_listlen == 1 && s:explorelist[0] =~ '\*\*\/'
+     let w:netrw_explore_list    = split(expand(b:netrw_curdir."/".a:1),'\n')
+     let w:netrw_explore_listlen = len(w:netrw_explore_list)
+     if w:netrw_explore_listlen == 1 && w:netrw_explore_list[0] =~ '\*\*\/'
       echohl WarningMsg | echo "***netrw*** no files matched" | echohl None
       call inputsave()|call input("Press <cr> to continue")|call inputrestore()
 "      call Dret("Explore")
@@ -2678,32 +2794,33 @@ fun! s:Explore(indx,dosplit,style,...)
     endif
 
     " NetrwStatusLine support
-    let s:explore_indx  = indx
+    let w:netrw_explore_indx= indx
     if !exists("s:netrw_explore_stl")
      let s:netrw_explore_stl= &stl
     endif
     set stl=%f\ %h%m%r%=%{NetrwStatusLine()}
-"    call Decho("explorelist<".join(s:explorelist,',')."> len=".s:explore_listlen)
+"    call Decho("explorelist<".join(w:netrw_explore_list,',')."> len=".w:netrw_explore_listlen)
 
     " sanity check
-    if indx >= s:explore_listlen || indx < 0
-     let indx= (indx < 0)? 0 : ( s:explore_listlen - 1 )
+    if indx >= w:netrw_explore_listlen || indx < 0
+     let indx= (indx < 0)? 0 : ( w:netrw_explore_listlen - 1 )
      echohl WarningMsg | echo "***netrw*** no more files match Explore pattern" | echohl None
      call inputsave()|call input("Press <cr> to continue")|call inputrestore()
 "     call Dret("Explore")
      return
     endif
 
-    exe "let dirfile= s:explorelist[".indx."]"
+    exe "let dirfile= w:netrw_explore_list[".indx."]"
 "    call Decho("dirfile<".dirfile."> indx=".indx)
     let newdir= substitute(dirfile,'/[^/]*$','','e')
 "    call Decho("newdir<".newdir.">")
 "    call Decho("calling LocalBrowse(newdir<".newdir.">)")
     call s:LocalBrowse(newdir)
     call search(substitute(dirfile,"^.*/","",""),"W")
-    let s:explore_mtchcnt = indx + 1
-    let s:explore_bufnr   = bufnr(".")
-    let s:explore_line    = line(".")
+    let w:netrw_explore_mtchcnt = indx + 1
+    let w:netrw_explore_bufnr   = bufnr(".")
+    let w:netrw_explore_line    = line(".")
+"    call Decho("explore: mtchcnt=".w:netrw_explore_mtchcnt." bufnr=".w:netrw_explore_bufnr." line#".w:netrw_explore_line)
 
    else
     if v:version < 700
@@ -2726,13 +2843,14 @@ endfun
 " ---------------------------------------------------------------------
 " NetrwStatusLine: {{{2
 fun! NetrwStatusLine()
-  let g:explore_bufnr= s:explore_bufnr
-  let g:explore_line= s:explore_line
-  if !exists("s:explore_bufnr") || s:explore_bufnr != bufnr(".") || !exists("s:explore_line") || s:explore_line != line(".")
+"  let g:stlmsg= "Xbufnr=".w:netrw_explore_bufnr." bufnr=".bufnr(".")." Xline#".w:netrw_explore_line." line#".line(".")
+  if !exists("w:netrw_explore_bufnr") || w:netrw_explore_bufnr != bufnr(".") || !exists("w:netrw_explore_line") || w:netrw_explore_line != line(".") || !exists("w:netrw_explore_list")
    let &stl= s:netrw_explore_stl
+   if exists("w:netrw_explore_bufnr")|unlet w:netrw_explore_bufnr|endif
+   if exists("w:netrw_explore_line")|unlet w:netrw_explore_line|endif
    return ""
   else
-   return "Match ".s:explore_mtchcnt." of ".s:explore_listlen
+   return "Match ".w:netrw_explore_mtchcnt." of ".w:netrw_explore_listlen
   endif
 endfun
 
@@ -3119,7 +3237,7 @@ endif
 "          "files" that satisfy each pattern, putting the priority / in
 "          front.  An "*" pattern handles the default priority.
 fun! <SID>SetSort()
-"  call Dfunc("SetSort() bannercnt=".s:netrw_bannercnt)
+"  call Dfunc("SetSort() bannercnt=".w:netrw_bannercnt)
   if g:netrw_longlist
    let seqlist  = substitute(g:netrw_sort_sequence,'\$','\\%(\t\\|\$\\)','ge')
   else
@@ -3151,24 +3269,54 @@ fun! <SID>SetSort()
 "   call Decho("priority=".priority." spriority<".spriority."> seq<".seq."> seqlist<".seqlist.">")
 
    " sanity check
-   if s:netrw_bannercnt > line("$")
+   if w:netrw_bannercnt > line("$")
     " apparently no files were left after a Hiding pattern was used
 "    call Dret("SetSort : no files left after hiding")
     return
    endif
    if seq == '*'
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$v/^\d\{3}\//s/^/'.spriority.'/'
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$v/^\d\{3}\//s/^/'.spriority.'/'
    else
-    exe 'keepjumps silent '.s:netrw_bannercnt.',$g/'.eseq.'/s/^/'.spriority.'/'
+    exe 'keepjumps silent '.w:netrw_bannercnt.',$g/'.eseq.'/s/^/'.spriority.'/'
    endif
    let priority = priority + 1
   endwhile
 
-  exe 'keepjumps silent '.s:netrw_bannercnt.',$s/^\(\d\{3}\/\)\%(\d\{3}\/\)\+/\1/e'
+  exe 'keepjumps silent '.w:netrw_bannercnt.',$s/^\(\d\{3}\/\)\%(\d\{3}\/\)\+/\1/e'
 
 "  call Dret("SetSort")
 endfun
 
+" ---------------------------------------------------------------------
+" SaveWinVars: (used by Explore()) {{{1
+fun! s:SaveWinVars()
+"  call Dfunc("SaveWinVars()")
+  if exists("w:netrw_bannercnt")      |let s:bannercnt       = w:netrw_bannercnt      |endif
+  if exists("w:netrw_method")         |let s:method          = w:netrw_method         |endif
+  if exists("w:netrw_prvdir")         |let s:prvdir          = w:netrw_prvdir         |endif
+  if exists("w:netrw_explore_indx")   |let s:explore_indx    = w:netrw_explore_indx   |endif
+  if exists("w:netrw_explore_listlen")|let s:explore_listlen = w:netrw_explore_listlen|endif
+  if exists("w:netrw_explore_mtchcnt")|let s:explore_mtchcnt = w:netrw_explore_mtchcnt|endif
+  if exists("w:netrw_explore_bufnr")  |let s:explore_bufnr   = w:netrw_explore_bufnr  |endif
+  if exists("w:netrw_explore_line")   |let s:explore_line    = w:netrw_explore_line   |endif
+"  call Dret("SaveWinVars")
+endfun
+
+" ---------------------------------------------------------------------
+" CopyWinVars: (used by Explore()) {{{1
+fun! s:CopyWinVars()
+"  call Dfunc("CopyWinVars()")
+  if exists("s:bannercnt")      |let w:netrw_bannercnt       = s:bannercnt      |unlet s:bannercnt      |endif
+  if exists("s:method")         |let w:netrw_method          = s:method         |unlet s:method         |endif
+  if exists("s:prvdir")         |let w:netrw_prvdir          = s:prvdir         |unlet s:prvdir         |endif
+  if exists("s:explore_indx")   |let w:netrw_explore_indx    = s:explore_indx   |unlet s:explore_indx   |endif
+  if exists("s:explore_listlen")|let w:netrw_explore_listlen = s:explore_listlen|unlet s:explore_listlen|endif
+  if exists("s:explore_mtchcnt")|let w:netrw_explore_mtchcnt = s:explore_mtchcnt|unlet s:explore_mtchcnt|endif
+  if exists("s:explore_bufnr")  |let w:netrw_explore_bufnr   = s:explore_bufnr  |unlet s:explore_bufnr  |endif
+  if exists("s:explore_line")   |let w:netrw_explore_line    = s:explore_line   |unlet s:explore_line   |endif
+"  call Dret("CopyWinVars")
+endfun
+
 let &cpo= s:keepcpo
 unlet s:keepcpo
 " ------------------------------------------------------------------------
new file mode 100644
--- /dev/null
+++ b/runtime/spell/yi/!yi.diff
@@ -0,0 +1,7 @@
+*** wordlist.utf8.txt	Thu Aug 11 17:55:15 2005
+--- yi.dic	Thu Aug 11 17:56:28 2005
+***************
+*** 1 ****
+--- 1,2 ----
++ 99999
+  גרונטעלעמענט
new file mode 100644
--- /dev/null
+++ b/runtime/spell/yi/README.txt
@@ -0,0 +1,6 @@
+README file for the Yiddish spell file.
+
+The word list was provided by Raphael Finkel.  It is the same one that is used
+by uspell.
+
+Copyright Raphael Finkel.  Included with permission in Vim.
new file mode 100644
--- /dev/null
+++ b/runtime/spell/yi/yi.diff
@@ -0,0 +1,18 @@
+*** wordlist.utf8.txt	Thu Aug 11 18:40:11 2005
+--- yi.dic	Thu Aug 11 19:48:53 2005
+***************
+*** 1,2 ****
+--- 1,3 ----
++ 999999
+  גרונטעלעמענט
+  דזשאָבענדיקס
+*** /dev/null	Thu Aug 11 19:48:23 2005
+--- yi.aff	Thu Aug 11 18:50:45 2005
+***************
+*** 0 ****
+--- 1,5 ----
++ SET UTF-8
++ 
++ REP 2
++ REP וו װ
++ REP יי ײ
--- a/runtime/syntax/tex.vim
+++ b/runtime/syntax/tex.vim
@@ -1,9 +1,9 @@
 " Vim syntax file
 " Language:	TeX
-" Maintainer:	Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
-" Last Change:	Mar 02, 2005
-" Version:	27
-" URL:		http://www.erols.com/astronaut/vim/index.html#vimlinks_syntax
+" Maintainer:	Dr. Charles E. Campbell, Jr. <NdrchipO@ScampbellPfamily.AbizM>
+" Last Change:	Aug 11, 2005
+" Version:	28
+" URL:		http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
 "
 " Notes: {{{1
 "
@@ -80,7 +80,6 @@ if g:tex_fold_enabled && &fdm == "manual
  set fdm=syntax
 endif
 
-
 " (La)TeX keywords: only use the letters a-zA-Z {{{1
 " but _ is the only one that causes problems.
 if version < 600
@@ -102,6 +101,7 @@ if !exists("g:tex_no_error")
  syn cluster texCmdGroup	add=texMathError
 endif
 syn cluster texEnvGroup		contains=texMatcher,texMathDelim,texSpecialChar,texStatement
+syn cluster texFoldGroup	contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texSectionMarker,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract
 syn cluster texMatchGroup	contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcher,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption
 syn cluster texRefGroup		contains=texMatcher,texComment,texDelimiter
 if !exists("tex_no_math")
@@ -246,12 +246,29 @@ syn match texSpaceCodeChar    "`\\\=.\(\
 
 " Sections, subsections, etc: {{{1
 if g:tex_fold_enabled && has("folding")
- syn region texSectionZone	matchgroup=texSection start="\\\(sub\)*\(section\|author\|part\|chapter\|paragraph\)\*\=\>"	end="\ze\\\(sub\)*\(section\|author\|part\|chapter\|paragraph\)\*\=\>" end="%\s*stopzone\>"	contains=TOP fold
- syn region texSectionZone	matchgroup=texSection start="\\begin\s*{\s*abstract\s*}"	end="\\end\s*{\s*abstract\s*}"  contains=TOP fold
+ syn cluster texDocGroup		contains=texPartZone,@texPartGroup
+ syn cluster texPartGroup		contains=texChapterZone,texSectionZone,texParaZone
+ syn cluster texChapterGroup		contains=texSectionZone,texParaZone
+ syn cluster texSectionGroup		contains=texSubSectionZone,texParaZone
+ syn cluster texSubSectionGroup		contains=texSubSubSectionZone,texParaZone
+ syn cluster texSubSubSectionGroup	contains=texParaZone
+ syn cluster texParaGroup		contains=texSubParaZone
+
+ syn region texDocZone			matchgroup=texSection start='\\begin\s*{\s*document\s*}' end='\\end\s*{\s*document\s*}'	fold keepend contains=@texFoldGroup,@texDocGroup
+ syn region texPartZone			matchgroup=texSection start='\\part\>'		end='\n\ze\s*\\part\>'		fold keepend contains=@texFoldGroup,@texPartGroup
+ syn region texChapterZone		matchgroup=texSection start='\\chapter\>'	end='\n\ze\s*\\chapter\>'	fold keepend contains=@texFoldGroup,@texChapterGroup
+ syn region texSectionZone		matchgroup=texSection start='\\section\>'	end='\n\ze\s*\\section\>'	fold keepend contains=@texFoldGroup,@texSectionGroup
+ syn region texSubSectionZone		matchgroup=texSection start='\\subsection\>'	end='\n\ze\s*\\subsection\>'	fold keepend contains=@texFoldGroup,@texSubSectionGroup
+ syn region texSubSubSectionZone	matchgroup=texSection start='\\subsubsection\>'	end='\n\ze\s*\\subsubsection\>'	fold keepend contains=@texFoldGroup,@texSubSubSectionGroup
+ syn region texParaZone			matchgroup=texSection start='\\paragraph\>'	end='\n\ze\s*\\paragraph\>'	fold keepend contains=@texFoldGroup,@texParaGroup
+ syn region texSubParaZone		matchgroup=texSection start='\\subparagraph\>'	end='\n\ze\s*\\subparagraph\>'	fold keepend contains=@texFoldGroup
+ syn region texTitle			matchgroup=texSection start='\\\%(author\|title\)\>\s*{' end='}'		fold contains=@texFoldGroup
+ syn region texAbstract			matchgroup=texSection start='\\begin\s*{\s*abstract\s*}' end='\\end\s*{\s*abstract\s*}'	fold contains=@texFoldGroup
 else
- syn match texSection		"\\\(sub\)*section\*\=\>"
- syn match texSection		"\\\(title\|author\|part\|chapter\|paragraph\|subparagraph\)\>"
- syn match texSection		"\\begin\s*{\s*abstract\s*}\|\\end\s*{\s*abstract\s*}"
+ syn match texSection			"\\\(sub\)*section\*\=\>"
+ syn match texSection			"\\\(part\|chapter\|paragraph\|subparagraph\)\>"
+ syn region texTitle			matchgroup=texSection start='\\\%(author\|title\)\>\s*\ze{' end='}'		contains=@texFoldGroup
+ syn match texSection			"\\begin\s*{\s*abstract\s*}\|\\end\s*{\s*abstract\s*}"
 endif
 
 " Bad Math (mismatched): {{{1
@@ -263,7 +280,7 @@ endif
 
 " Math Zones: {{{1
 if !exists("tex_no_math")
- " TexNewMathZone: creates a mathzone with the given suffix and mathzone name. {{{2
+ " TexNewMathZone: function creates a mathzone with the given suffix and mathzone name. {{{2
  "                 Starred forms are created if starform is true.  Starred
  "                 forms have syntax group and synchronization groups with a
  "                 "S" appended.  Handles: cluster, syntax, sync, and HiLink.
--- a/src/edit.c
+++ b/src/edit.c
@@ -32,14 +32,15 @@
 #define CTRL_X_CMDLINE		11
 #define CTRL_X_FUNCTION		12
 #define CTRL_X_OCCULT		13
-#define CTRL_X_LOCAL_MSG	14	/* only used in "ctrl_x_msgs" */
+#define CTRL_X_SPELL		14
+#define CTRL_X_LOCAL_MSG	15	/* only used in "ctrl_x_msgs" */
 
 #define CTRL_X_MSG(i) ctrl_x_msgs[(i) & ~CTRL_X_WANT_IDENT]
 
 static char *ctrl_x_msgs[] =
 {
     N_(" Keyword completion (^N^P)"), /* ctrl_x_mode == 0, ^P/^N compl. */
-    N_(" ^X mode (^E^Y^L^]^F^I^K^D^U^V^N^P)"),
+    N_(" ^X mode (^]^D^E^F^I^K^L^N^O^P^S^U^V^Y)"),
     NULL,
     N_(" Whole line completion (^L^N^P)"),
     N_(" File name completion (^F^N^P)"),
@@ -52,6 +53,7 @@ static char *ctrl_x_msgs[] =
     N_(" Command-line completion (^V^N^P)"),
     N_(" User defined completion (^U^N^P)"),
     N_(" Occult completion (^O^N^P)"),
+    N_(" Spelling suggestion (^S^N^P)"),
     N_(" Keyword Local completion (^N^P)"),
 };
 
@@ -152,7 +154,7 @@ static int cindent_on __ARGS((void));
 static void ins_reg __ARGS((void));
 static void ins_ctrl_g __ARGS((void));
 static void ins_ctrl_hat __ARGS((void));
-static int  ins_esc __ARGS((long *count, int cmdchar, int c));
+static int  ins_esc __ARGS((long *count, int cmdchar, int nomove));
 #ifdef FEAT_RIGHTLEFT
 static void ins_ctrl_ __ARGS((void));
 #endif
@@ -266,6 +268,7 @@ edit(cmdchar, startln, count)
     int		inserted_space = FALSE;     /* just inserted a space */
     int		replaceState = REPLACE;
     int		did_restart_edit = restart_edit;
+    int		nomove = FALSE;		    /* don't move cursor on return */
 
     /* sleep before redrawing, needed for "CTRL-O :" that results in an
      * error message */
@@ -658,8 +661,9 @@ edit(cmdchar, startln, count)
 	    ins_compl_prep(c);
 #endif
 
-	/* CTRL-\ CTRL-N goes to Normal mode, CTRL-\ CTRL-G goes to mode
-	 * selected with 'insertmode'.  */
+	/* CTRL-\ CTRL-N goes to Normal mode,
+	 * CTRL-\ CTRL-G goes to mode selected with 'insertmode',
+	 * CTRL-\ CTRL-O is like CTRL-O but without moving the cursor.  */
 	if (c == Ctrl_BSL)
 	{
 	    /* may need to redraw when no more chars available now */
@@ -669,8 +673,9 @@ edit(cmdchar, startln, count)
 	    c = safe_vgetc();
 	    --no_mapping;
 	    --allow_keys;
-	    if (c != Ctrl_N && c != Ctrl_G)	/* it's something else */
+	    if (c != Ctrl_N && c != Ctrl_G && c != Ctrl_O)
 	    {
+		/* it's something else */
 		vungetc(c);
 		c = Ctrl_BSL;
 	    }
@@ -678,6 +683,12 @@ edit(cmdchar, startln, count)
 		continue;
 	    else
 	    {
+		if (c == Ctrl_O)
+		{
+		    ins_ctrl_o();
+		    ins_at_eol = FALSE;	/* cursor keeps its column */
+		    nomove = TRUE;
+		}
 		count = 0;
 		goto doESCkey;
 	    }
@@ -787,7 +798,7 @@ doESCkey:
 	    if (ins_at_eol && gchar_cursor() == NUL)
 		o_lnum = curwin->w_cursor.lnum;
 
-	    if (ins_esc(&count, cmdchar, c))
+	    if (ins_esc(&count, cmdchar, nomove))
 	    {
 #ifdef FEAT_AUTOCMD
 		if (cmdchar != 'r' && cmdchar != 'v')
@@ -1117,6 +1128,12 @@ doESCkey:
 	    if (ctrl_x_mode != CTRL_X_FILES)
 		goto normalchar;
 	    goto docomplete;
+
+	case 's':	/* Spelling completion after ^X */
+	case Ctrl_S:
+	    if (ctrl_x_mode != CTRL_X_SPELL)
+		goto normalchar;
+	    goto docomplete;
 #endif
 
 	case Ctrl_L:	/* Whole line completion after ^X */
@@ -1799,7 +1816,8 @@ vim_is_ctrl_x_key(c)
 		    || c == Ctrl_L || c == Ctrl_F || c == Ctrl_RSB
 		    || c == Ctrl_I || c == Ctrl_D || c == Ctrl_P
 		    || c == Ctrl_N || c == Ctrl_T || c == Ctrl_V
-		    || c == Ctrl_Q || c == Ctrl_U || c == Ctrl_O);
+		    || c == Ctrl_Q || c == Ctrl_U || c == Ctrl_O
+		    || c == Ctrl_S || c == 's');
 	case CTRL_X_SCROLL:
 	    return (c == Ctrl_Y || c == Ctrl_E);
 	case CTRL_X_WHOLE_LINE:
@@ -1827,6 +1845,8 @@ vim_is_ctrl_x_key(c)
 #endif
 	case CTRL_X_OCCULT:
 	    return (c == Ctrl_O || c == Ctrl_P || c == Ctrl_N);
+	case CTRL_X_SPELL:
+	    return (c == Ctrl_S || c == Ctrl_P || c == Ctrl_N);
     }
     EMSG(_(e_internal));
     return FALSE;
@@ -2342,6 +2362,10 @@ ins_compl_prep(c)
 	    case Ctrl_O:
 		ctrl_x_mode = CTRL_X_OCCULT;
 		break;
+	    case 's':
+	    case Ctrl_S:
+		ctrl_x_mode = CTRL_X_SPELL;
+		break;
 	    case Ctrl_RSB:
 		ctrl_x_mode = CTRL_X_TAGS;
 		break;
@@ -2855,6 +2879,15 @@ ins_compl_get_exp(ini, dir)
 		ins_compl_add_matches(num_matches, matches, dir);
 	    break;
 
+	case CTRL_X_SPELL:
+#ifdef FEAT_SYN_HL
+	    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, dir);
+#endif
+	    break;
+
 	default:	/* normal ^P/^N and ^X^L */
 	    /*
 	     * If 'infercase' is set, don't use 'smartcase' here
@@ -3496,6 +3529,18 @@ ins_complete(c)
 	    if (compl_pattern == NULL)
 		return FAIL;
 	}
+	else if (ctrl_x_mode == CTRL_X_SPELL)
+	{
+#ifdef FEAT_SYN_HL
+	    compl_col = spell_word_start(startcol);
+	    if (compl_col == startcol)
+		return FAIL;
+	    compl_length = (int)curs_col - compl_col;
+	    compl_pattern = vim_strnsave(line + compl_col, compl_length);
+	    if (compl_pattern == NULL)
+#endif
+		return FAIL;
+	}
 	else
 	{
 	    EMSG2(_(e_intern2), "ins_complete()");
@@ -6272,10 +6317,10 @@ ins_ctrl_hat()
  * insert.
  */
     static int
-ins_esc(count, cmdchar, c)
+ins_esc(count, cmdchar, nomove)
     long	*count;
     int		cmdchar;
-    int		c;	    /* typed character */
+    int		nomove;	    /* don't move cursor */
 {
     int		temp;
     static int	disabled_redraw = FALSE;
@@ -6353,18 +6398,20 @@ ins_esc(count, cmdchar, c)
 
     /*
      * The cursor should end up on the last inserted character.
-     * Don't do it for CTRL-O or CTRL-L.
+     * Don't do it for CTRL-O, unless past the end of the line.
      */
-    if ((curwin->w_cursor.col != 0
+    if (!nomove
+	    && (curwin->w_cursor.col != 0
 #ifdef FEAT_VIRTUALEDIT
 		|| curwin->w_cursor.coladd > 0
 #endif
-	) && ((restart_edit == NUL && c != Ctrl_L)
-		|| (gchar_cursor() == NUL
+	       )
+	    && (restart_edit == NUL
+		   || (gchar_cursor() == NUL
 #ifdef FEAT_VISUAL
-		    && !VIsual_active
-#endif
-		    ))
+		       && !VIsual_active
+#endif
+		      ))
 #ifdef FEAT_RIGHTLEFT
 	    && !revins_on
 #endif
--- a/src/option.c
+++ b/src/option.c
@@ -2035,7 +2035,7 @@ static struct vimoption
 			    (char_u *)NULL, PV_NONE,
 #endif
 			    {(char_u *)FALSE, (char_u *)0L}},
-    {"spellcapcheck", "spc", P_STRING|P_ALLOCED|P_VI_DEF|P_SECURE|P_RBUF,
+    {"spellcapcheck", "spc", P_STRING|P_ALLOCED|P_VI_DEF|P_RBUF,
 #ifdef FEAT_SYN_HL
 			    (char_u *)&p_spc, PV_SPC,
 			    {(char_u *)"[.?!]\\_[\\])'\"	 ]\\+", (char_u *)0L}
--- a/src/proto/spell.pro
+++ b/src/proto/spell.pro
@@ -13,7 +13,9 @@ void init_spell_chartab __ARGS((void));
 int spell_check_sps __ARGS((void));
 void spell_suggest __ARGS((void));
 void ex_spellrepall __ARGS((exarg_T *eap));
-void spell_suggest_list __ARGS((garray_T *gap, char_u *word, int maxcount));
+void spell_suggest_list __ARGS((garray_T *gap, char_u *word, int maxcount, int need_cap));
 char_u *eval_soundfold __ARGS((char_u *word));
 void ex_spelldump __ARGS((exarg_T *eap));
+int spell_word_start __ARGS((int startcol));
+int expand_spelling __ARGS((linenr_T lnum, int col, char_u *pat, char_u ***matchp));
 /* vim: set ft=c : */
--- a/src/version.h
+++ b/src/version.h
@@ -36,5 +36,5 @@
 #define VIM_VERSION_NODOT	"vim70aa"
 #define VIM_VERSION_SHORT	"7.0aa"
 #define VIM_VERSION_MEDIUM	"7.0aa ALPHA"
-#define VIM_VERSION_LONG	"VIM - Vi IMproved 7.0aa ALPHA (2005 Aug 10)"
-#define VIM_VERSION_LONG_DATE	"VIM - Vi IMproved 7.0aa ALPHA (2005 Aug 10, compiled "
+#define VIM_VERSION_LONG	"VIM - Vi IMproved 7.0aa ALPHA (2005 Aug 11)"
+#define VIM_VERSION_LONG_DATE	"VIM - Vi IMproved 7.0aa ALPHA (2005 Aug 11, compiled "