From 70590be8d24da33ce243e35b5f78c36b670a939f Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sun, 1 Aug 2010 21:15:45 +0200 Subject: [PATCH 01/24] Fix: the MS-Windows uninstaller did not delete registry keys on 64 bit systems. --HG-- branch : vim73 --- src/uninstal.c | 39 ++++++++++++++++++++++++++------------- 1 file changed, 26 insertions(+), 13 deletions(-) diff --git a/src/uninstal.c b/src/uninstal.c index 4b4b6f26f1..13138aafbc 100644 --- a/src/uninstal.c +++ b/src/uninstal.c @@ -89,11 +89,14 @@ remove_popup(void) int fail = 0; HKEY kh; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}\\InProcServer32") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}\\InProcServer32", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "*\\shellex\\ContextMenuHandlers\\gvim") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "*\\shellex\\ContextMenuHandlers\\gvim", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Shell Extensions\\Approved", 0, KEY_WOW64_64KEY | KEY_ALL_ACCESS, &kh) != ERROR_SUCCESS) @@ -104,9 +107,11 @@ remove_popup(void) ++fail; RegCloseKey(kh); } - if (RegDeleteKey(HKEY_LOCAL_MACHINE, "Software\\Vim\\Gvim") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Vim\\Gvim", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_LOCAL_MACHINE, "Software\\Vim") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Vim", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; if (fail == 6) @@ -122,19 +127,26 @@ remove_openwith(void) { int fail = 0; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit\\command") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit\\command", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "Applications\\gvim.exe") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, ".htm\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, ".htm\\OpenWithList\\gvim.exe", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, ".vim\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, ".vim\\OpenWithList\\gvim.exe", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; - if (RegDeleteKey(HKEY_CLASSES_ROOT, "*\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) + if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "*\\OpenWithList\\gvim.exe", + KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) ++fail; if (fail == 7) @@ -290,7 +302,8 @@ win95(void) delete_uninstall_key(void) { #ifdef WIN3264 - RegDeleteKey(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\Vim " VIM_VERSION_SHORT); + RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\Vim " VIM_VERSION_SHORT, + KEY_WOW64_64KEY, 0); #else FILE *fd; char buf[BUFSIZE]; From 650770be1e421c28a62ea27b6d6c8c483cb5d512 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sun, 1 Aug 2010 21:48:21 +0200 Subject: [PATCH 02/24] Add Datascript syntax file. (Dominique Pelle) --HG-- branch : vim73 --- runtime/doc/todo.txt | 2 - runtime/doc/version7.txt | 1 + runtime/filetype.vim | 3 ++ runtime/syntax/datascript.vim | 90 +++++++++++++++++++++++++++++++++++ 4 files changed, 94 insertions(+), 2 deletions(-) create mode 100644 runtime/syntax/datascript.vim diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index 0d37f5c9dd..b98b0018ba 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -30,8 +30,6 @@ be worked on, but only if you sponsor Vim development. See |sponsor|. *known-bugs* -------------------- Known bugs and current work ----------------------- -Windows installer doesn't delete the uninstall key on 64 bit systems. - Before release 7.3: - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) diff --git a/runtime/doc/version7.txt b/runtime/doc/version7.txt index 7bf2e81cdc..307868469d 100644 --- a/runtime/doc/version7.txt +++ b/runtime/doc/version7.txt @@ -7337,6 +7337,7 @@ New syntax files: ~ Haskell Cabal build file (Vincent Berthoux) ChaiScript (Jason Turner) Cucumber (Tim Pope) +Datascript (Dominique Pelle) Fantom (Kamil Toman) Liquid (Tim Pope) Markdown (Tim Pope) diff --git a/runtime/filetype.vim b/runtime/filetype.vim index 62652f52bd..98785b39b6 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -617,6 +617,9 @@ au BufNewFile,BufRead *.def setf def " Dracula au BufNewFile,BufRead *.drac,*.drc,*lvs,*lpe setf dracula +" Datascript +au BufNewFile,BufRead *.ds setf datascript + " dsl au BufNewFile,BufRead *.dsl setf dsl diff --git a/runtime/syntax/datascript.vim b/runtime/syntax/datascript.vim new file mode 100644 index 0000000000..b51f41877f --- /dev/null +++ b/runtime/syntax/datascript.vim @@ -0,0 +1,90 @@ +" Vim syntax file +" Language: Datascript +" Maintainer: Dominique Pelle +" Last Change: 2010-08-01 +" +" DataScript is a formal language for modelling binary datatypes, +" bitstreams or file formats. For more information, see: +" http://datascript.berlios.de/DataScriptLanguageOverview.html + +if version < 600 + syntax clear +elseif exists("b:current_syntax") + finish +endif + +syn keyword dsPackage import package +syn keyword dsType bit string +syn keyword dsType int8 int16 int32 int64 +syn keyword dsType uint8 uint16 uint32 uint64 +syn keyword dsType leint16 leint32 leint64 +syn keyword dsType leuint16 leuint32 leuint64 +syn keyword dsEndian little big +syn keyword dsAlign align +syn keyword dsLabel case default +syn keyword dsConditional if condition +syn keyword dsCompound union choice on enum bitmask subtype +syn keyword dsKeyword function return +syn keyword dsOperator sizeof bitsizeof lengthof is sum forall in +syn keyword dsStorageClass const +syn keyword dsTodo contained TODO FIXME XXX +syn keyword dsSql sql sql_table sql_database sql_pragma +syn keyword dsSql sql_integer sql_metadata sql_key + +" dsCommentGroup allows adding matches for special things in comments. +syn cluster dsCommentGroup contains=dsTodo + +syn match dsOffset display "^\s*[a-zA-Z_:\.][a-zA-Z0-9_:\.]*\s*:" + +syn match dsNumber display "\<\d\+\>" +syn match dsNumberHex display "\<0[xX]\x\+\>" +syn match dsNumberBin display "\<[01]\+[bB]\>" contains=dsBinaryB +syn match dsBinaryB display contained "[bB]\>" +syn match dsOctal display "\<0\o\+\>" contains=dsOctalZero +syn match dsOctalZero display contained "\<0" + +syn match dsOctalError display "\<0\o*[89]\d*\>" + +syn match dsCommentError display "\*/" +syn match dsCommentStartError display "/\*"me=e-1 contained + +syn region dsCommentL + \ start="//" skip="\\$" end="$" keepend + \ contains=@dsCommentGroup,@Spell +syn region dsComment + \ matchgroup=dsCommentStart start="/\*" end="\*/" + \ contains=@dsCommentGroup,dsCommentStartError,@Spell extend + +syn region dsString + \ start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell + +" Define the default highlighting. +hi def link dsType Type +hi def link dsEndian StorageClass +hi def link dsStorageClass StorageClass +hi def link dsAlign Label +hi def link dsLabel Label +hi def link dsOffset Label +hi def link dsSql PreProc +hi def link dsCompound Structure +hi def link dsConditional Conditional +hi def link dsKeyword Statement +hi def link dsString String +hi def link dsNumber Number +hi def link dsNumberBin Number +hi def link dsBinaryB Special +hi def link dsOctal Number +hi def link dsOctalZero Special +hi def link dsOctalError Error +hi def link dsNumberHex Number +hi def link dsTodo Todo +hi def link dsOperator Operator +hi def link dsPackage Include +hi def link dsCommentError Error +hi def link dsCommentStartError Error +hi def link dsCommentStart dsComment +hi def link dsCommentL dsComment +hi def link cCommentL dsComment +hi def link dsComment Comment + +let b:current_syntax = "datascript" From cdd47af97a9c08a4decbdf3e8cb09146feaa26cf Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sun, 1 Aug 2010 22:35:43 +0200 Subject: [PATCH 03/24] Update version.h for 7.3c -> 7.3d. --HG-- branch : vim73 --- nsis/gvim.nsi | 2 +- src/version.h | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/nsis/gvim.nsi b/nsis/gvim.nsi index 2af03d245b..0c88645933 100644 --- a/nsis/gvim.nsi +++ b/nsis/gvim.nsi @@ -449,7 +449,7 @@ Section Uninstall AskRemove: MessageBox MB_YESNO|MB_ICONQUESTION \ - "Remove all files in your $1\vimfiles directory? \ + "Remove all files in your $1\vimfiles directory?$\n \ $\nCAREFUL: If you have created something there that you want to keep, click No" IDNO Fin RMDir /r $1\vimfiles NoRemove: diff --git a/src/version.h b/src/version.h index a6e9110340..13208d6a01 100644 --- a/src/version.h +++ b/src/version.h @@ -19,9 +19,9 @@ #define VIM_VERSION_MINOR_STR "3" #define VIM_VERSION_100 (VIM_VERSION_MAJOR * 100 + VIM_VERSION_MINOR) -#define VIM_VERSION_BUILD 272 -#define VIM_VERSION_BUILD_BCD 0x110 -#define VIM_VERSION_BUILD_STR "272" +#define VIM_VERSION_BUILD 273 +#define VIM_VERSION_BUILD_BCD 0x111 +#define VIM_VERSION_BUILD_STR "273" #define VIM_VERSION_PATCHLEVEL 0 #define VIM_VERSION_PATCHLEVEL_STR "0" /* Used by MacOS port should be one of: development, alpha, beta, final */ @@ -33,8 +33,8 @@ * VIM_VERSION_MEDIUM is used for the startup-screen. * VIM_VERSION_LONG is used for the ":version" command and "Vim -h". */ -#define VIM_VERSION_NODOT "vim73c" -#define VIM_VERSION_SHORT "7.3c" -#define VIM_VERSION_MEDIUM "7.3c BETA" -#define VIM_VERSION_LONG "VIM - Vi IMproved 7.3c BETA (2010 Aug 1)" -#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3c BETA (2010 Aug 1, compiled " +#define VIM_VERSION_NODOT "vim73d" +#define VIM_VERSION_SHORT "7.3d" +#define VIM_VERSION_MEDIUM "7.3d BETA" +#define VIM_VERSION_LONG "VIM - Vi IMproved 7.3d BETA (2010 Aug 1)" +#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3d BETA (2010 Aug 1, compiled " From a958040a47a3cac45c09e555d762a209336f50d4 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 20:26:43 +0200 Subject: [PATCH 04/24] Workaround for missing RegDeleteKeyEx() method. --HG-- branch : vim73 --- src/dosinst.h | 1 + src/if_ole.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/src/dosinst.h b/src/dosinst.h index b33426ad78..444af45b2a 100644 --- a/src/dosinst.h +++ b/src/dosinst.h @@ -89,6 +89,7 @@ char *searchpath(char *name); */ # ifndef KEY_WOW64_64KEY # define KEY_WOW64_64KEY 0x0100 +# define RegDeleteKeyEx(a, b, c, d) RegDeleteKey(a, b) # endif #define VIM_STARTMENU "Programs\\Vim " VIM_VERSION_SHORT diff --git a/src/if_ole.cpp b/src/if_ole.cpp index ca82182136..ff9e371a70 100644 --- a/src/if_ole.cpp +++ b/src/if_ole.cpp @@ -91,6 +91,7 @@ static CVim *app = 0; */ # ifndef KEY_WOW64_64KEY # define KEY_WOW64_64KEY 0x0100 +# define RegDeleteKeyEx(a, b, c, d) RegDeleteKey(a, b) # endif /***************************************************************************** From ce53e73573b3e6e8d19e8e43d974c66e7bba3c0a Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 20:45:27 +0200 Subject: [PATCH 05/24] Put quotes around the gvim.exe path for the "Open with" menu entry. --HG-- branch : vim73 --- runtime/doc/todo.txt | 5 ++++- src/dosinst.c | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index b98b0018ba..7b9c977db9 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -1,4 +1,4 @@ -*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 01 +*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 02 VIM REFERENCE MANUAL by Bram Moolenaar @@ -30,6 +30,9 @@ be worked on, but only if you sponsor Vim development. See |sponsor|. *known-bugs* -------------------- Known bugs and current work ----------------------- +Using uninitialized memory when crypting an empty file. (Dominique Pelle, 2010 +Aug 2) + Before release 7.3: - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) diff --git a/src/dosinst.c b/src/dosinst.c index 979d6fe879..84d171baf9 100644 --- a/src/dosinst.c +++ b/src/dosinst.c @@ -1463,7 +1463,7 @@ register_openwith( char exe_cmd[BUFSIZE]; LONG lRet; - sprintf(exe_cmd, "%s \"%%1\"", exe_path); + sprintf(exe_cmd, "\"%s\" \"%%1\"", exe_path); lRet = reg_create_key_and_value( hRootKey, "Applications\\gvim.exe\\shell\\edit\\command", From b0caec19f2a2d477b5a30cc2f6027f00cd61f64e Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 21:33:37 +0200 Subject: [PATCH 06/24] Improvements for :find completion. (Nazri Ramliy) --HG-- branch : vim73 --- src/misc1.c | 66 +++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 51 insertions(+), 15 deletions(-) diff --git a/src/misc1.c b/src/misc1.c index 11c2b1b5ab..e564c5cec3 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -9317,6 +9317,7 @@ expand_path_option(curdir, gap) char_u *path_option = *curbuf->b_p_path == NUL ? p_path : curbuf->b_p_path; char_u *buf; + char_u *p; ga_init2(gap, (int)sizeof(char_u *), 1); @@ -9350,7 +9351,12 @@ expand_path_option(curdir, gap) STRMOVE(buf + curdir_len, buf + curdir_len + 1); } - addfile(gap, buf, EW_NOTFOUND|EW_DIR|EW_FILE); + if (ga_grow(gap, 1) == FAIL) + break; + p = vim_strsave(buf); + if (p == NULL) + break; + ((char_u **)gap->ga_data)[gap->ga_len++] = p; } vim_free(buf); @@ -9378,8 +9384,11 @@ get_path_cutoff(fname, gap) { int j = 0; - while (fname[j] == path_part[i][j] && fname[j] != NUL - && path_part[i][j] != NUL) + while ((fname[j] == path_part[i][j] +#if defined(WIN3264) + || (vim_ispathsep(fname[j]) && vim_ispathsep(path_part[i][j])) +#endif + ) && fname[j] != NUL && path_part[i][j] != NUL) j++; if (j > maxlen) { @@ -9389,8 +9398,15 @@ get_path_cutoff(fname, gap) } /* Skip to the file or directory name */ - while (cutoff != NULL && vim_ispathsep(*cutoff) && *cutoff != NUL) - mb_ptr_adv(cutoff); + if (cutoff != NULL) + while ( +#if defined(WIN3264) + *cutoff == '/' +#else + vim_ispathsep(*cutoff) +#endif + ) + mb_ptr_adv(cutoff); return cutoff; } @@ -9454,7 +9470,13 @@ uniquefy_paths(gap, pattern) char_u *dir_end = gettail(path); len = (int)STRLEN(path); - while (dir_end > path && !vim_ispathsep(*dir_end)) + while (dir_end > path && +#if defined(WIN3264) + *dir_end != '/' +#else + !vim_ispathsep(*dir_end) +#endif + ) mb_ptr_back(path, dir_end); is_in_curdir = STRNCMP(curdir, path, dir_end - path) == 0 && curdir[dir_end - path] == NUL; @@ -9537,8 +9559,8 @@ theend: } /* - * Calls globpath with 'path' values for the given pattern and stores - * the result in gap. + * Calls globpath() or mch_expandpath() with 'path' values for the given + * pattern and stores the result in gap. * Returns the total number of matches. */ static int @@ -9547,15 +9569,18 @@ expand_in_path(gap, pattern, flags) char_u *pattern; int flags; /* EW_* flags */ { - int c = 0; - char_u *files = NULL; - char_u *s; /* start */ - char_u *e; /* end */ - char_u *paths = NULL; char_u **path_list; char_u *curdir; garray_T path_ga; int i; +# ifdef WIN3264 + char_u *file_pattern; +# else + char_u *files = NULL; + char_u *s; /* start */ + char_u *e; /* end */ + char_u *paths = NULL; +# endif if ((curdir = alloc((int)(MAXPATHL))) == NULL) return 0; @@ -9564,6 +9589,17 @@ expand_in_path(gap, pattern, flags) expand_path_option(curdir, &path_ga); vim_free(curdir); path_list = (char_u **)(path_ga.ga_data); +# ifdef WIN3264 + for (i = 0; i < path_ga.ga_len; i++) + { + if (STRLEN(path_list[i]) + STRLEN(pattern) + 2 > MAXPATHL) + continue; + STRCPY(file_pattern, path_list[i]); + STRCAT(file_pattern, "/"); + STRCAT(file_pattern, pattern); + mch_expandpath(gap, file_pattern, EW_DIR|EW_ADDSLASH|EW_FILE); + } +# else for (i = 0; i < path_ga.ga_len; i++) { if (paths == NULL) @@ -9609,10 +9645,10 @@ expand_in_path(gap, pattern, flags) } } - c = gap->ga_len; vim_free(files); +# endif - return c; + return gap->ga_len; } #endif From 26d733c022fe6c89358c1b9a91a2f5226a2cfebd Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 21:43:29 +0200 Subject: [PATCH 07/24] Updated version of gettext for use with MVC. (Mike Williams) --HG-- branch : vim73 --- src/po/Make_mvc.mak | 4 ++-- src/po/README_mvc.txt | 16 ++++++++++++---- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/src/po/Make_mvc.mak b/src/po/Make_mvc.mak index 7f37a86c03..32eecfe00a 100644 --- a/src/po/Make_mvc.mak +++ b/src/po/Make_mvc.mak @@ -62,8 +62,8 @@ MOFILES = \ PACKAGE = vim -# Correct the following line for the installation directory of gettext -GETTEXT_PATH = H:\gettext.win32.msvcrt\bin +# Correct the following line for the directory where gettext et al is installed +GETTEXT_PATH = H:\gettext.0.14.4\bin MSGFMT = $(GETTEXT_PATH)\msgfmt XGETTEXT = $(GETTEXT_PATH)\xgettext diff --git a/src/po/README_mvc.txt b/src/po/README_mvc.txt index 293edf2d4f..3a47213f31 100644 --- a/src/po/README_mvc.txt +++ b/src/po/README_mvc.txt @@ -1,10 +1,18 @@ TRANSLATING VIM MESSAGES -This file explains how to create and maintain po files using -gnu-gettext.win32, a Windows port of gettext by Franco Bez -. You can find it at: +This file explains how to create and maintain po files using a number of +GnuWin packages. You will need gettext, libiconv and libexpat. As of +August 2010 the versions known to work are gettext 0.14.4, libiconv 1.9.2-1 +and expat 2.0.1. gettext and libiconv can be found at: - http://people.freenet.de/franco.bez/gettext/gettext_win32_en.html + http://gnuwin32.sourceforge.net/ + +expat can be found at: + + http://sourceforge.net/projects/expat/ + +expat will install into its own directory. You should copy libexpat.dll into +the bin directory created from the gettext/libiconv packages. First read the README.txt file in this directory for general remarks on translating Vim messages. From 29caec46a7784a7409d8d80b21a70ea1141bb1db Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 22:12:46 +0200 Subject: [PATCH 08/24] Syntax file updates. (Charles Campbell) --HG-- branch : vim73 --- runtime/syntax/sh.vim | 44 ++-- runtime/syntax/tex.vim | 510 ++++++++++++++++++++++++---------------- runtime/syntax/vim.vim | 30 ++- runtime/syntax/yacc.vim | 12 +- 4 files changed, 361 insertions(+), 235 deletions(-) diff --git a/runtime/syntax/sh.vim b/runtime/syntax/sh.vim index ef057c93e4..681ca3a45f 100644 --- a/runtime/syntax/sh.vim +++ b/runtime/syntax/sh.vim @@ -2,11 +2,11 @@ " Language: shell (sh) Korn shell (ksh) bash (sh) " Maintainer: Dr. Charles E. Campbell, Jr. " Previous Maintainer: Lennart Schultz -" Last Change: Apr 12, 2010 -" Version: 112 +" Last Change: Jul 29, 2010 +" Version: 113 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax " For options and settings, please use: :help ft-sh-syntax -" This file includes many ideas from ric Brunet (eric.brunet@ens.fr) +" This file includes many ideas from ?ric Brunet (eric.brunet@ens.fr) " For version 5.x: Clear all syntax items {{{1 " For version 6.x: Quit when a syntax file was already loaded @@ -100,12 +100,12 @@ syn cluster shTestList contains=shCharClass,shComment,shCommandSub,shDeref,shDer " Echo: {{{1 " ==== " This one is needed INSIDE a CommandSub, so that `echo bla` be correct -syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shOperator end="$" matchgroup=NONE end="[<>;&|()]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment -syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shOperator end="$" matchgroup=NONE end="[<>;&|()]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment +syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|()]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment +syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|()]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment syn match shEchoQuote contained '\%(\\\\\)*\\["`'()]' " This must be after the strings, so that ... \" will be correct -syn region shEmbeddedEcho contained matchgroup=shStatement start="\" skip="\\$" matchgroup=shOperator end="$" matchgroup=NONE end="[<>;&|`)]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=shNumber,shExSingleQuote,shSingleQuote,shDeref,shDerefSimple,shSpecialVar,shOperator,shDoubleQuote,shCharClass,shCtrlSeq +syn region shEmbeddedEcho contained matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|`)]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=shNumber,shExSingleQuote,shSingleQuote,shDeref,shDerefSimple,shSpecialVar,shOperator,shDoubleQuote,shCharClass,shCtrlSeq " Alias: {{{1 " ===== @@ -211,12 +211,12 @@ else endif syn keyword shCaseIn contained skipwhite skipnl in nextgroup=shCase,shCaseStart,shCaseBar,shComment,shCaseExSingleQuote,shCaseSingleQuote,shCaseDoubleQuote if exists("b:is_bash") - syn region shCaseExSingleQuote matchgroup=shOperator start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial,shSpecial skipwhite skipnl nextgroup=shCaseBar contained + syn region shCaseExSingleQuote matchgroup=shQuote start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial,shSpecial skipwhite skipnl nextgroup=shCaseBar contained else syn region shCaseExSingleQuote matchgroup=Error start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial skipwhite skipnl nextgroup=shCaseBar contained endif -syn region shCaseSingleQuote matchgroup=shOperator start=+'+ end=+'+ contains=shStringSpecial skipwhite skipnl nextgroup=shCaseBar contained -syn region shCaseDoubleQuote matchgroup=shOperator start=+"+ skip=+\\\\\|\\.+ end=+"+ contains=@shDblQuoteList,shStringSpecial skipwhite skipnl nextgroup=shCaseBar contained +syn region shCaseSingleQuote matchgroup=shQuote start=+'+ end=+'+ contains=shStringSpecial skipwhite skipnl nextgroup=shCaseBar contained +syn region shCaseDoubleQuote matchgroup=shQuote start=+"+ skip=+\\\\\|\\.+ end=+"+ contains=@shDblQuoteList,shStringSpecial skipwhite skipnl nextgroup=shCaseBar contained syn region shCaseCommandSub start=+`+ skip=+\\\\\|\\.+ end=+`+ contains=@shCommandSubList skipwhite skipnl nextgroup=shCaseBar contained syn region shCaseRange matchgroup=Delimiter start=+\[+ skip=+\\\\+ end=+]+ contained @@ -268,12 +268,12 @@ if exists("b:is_bash") syn match shSpecial "\\\o\o\o\|\\x\x\x\|\\c[^"]\|\\[abefnrtv]" contained endif if exists("b:is_bash") - syn region shExSingleQuote matchgroup=shOperator start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial,shSpecial + syn region shExSingleQuote matchgroup=shQuote start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial,shSpecial else syn region shExSingleQuote matchGroup=Error start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial endif -syn region shSingleQuote matchgroup=shOperator start=+'+ end=+'+ contains=@Spell -syn region shDoubleQuote matchgroup=shOperator start=+"+ skip=+\\"+ end=+"+ contains=@shDblQuoteList,shStringSpecial,@Spell +syn region shSingleQuote matchgroup=shQuote start=+'+ end=+'+ contains=@Spell +syn region shDoubleQuote matchgroup=shQuote start=+"+ skip=+\\"+ end=+"+ contains=@shDblQuoteList,shStringSpecial,@Spell syn match shStringSpecial "[^[:print:] \t]" contained syn match shStringSpecial "\%(\\\\\)*\\[\\"'`$()#]" syn match shSpecial "[^\\]\zs\%(\\\\\)*\\[\\"'`$()#]" nextgroup=shMoreSpecial @@ -341,13 +341,13 @@ syn match shSetOption "\s\zs[-+][a-zA-Z0-9]\+\>" contained syn match shVariable "\<\([bwglsav]:\)\=[a-zA-Z0-9.!@_%+,]*\ze=" nextgroup=shSetIdentifier syn match shSetIdentifier "=" contained nextgroup=shPattern,shDeref,shDerefSimple,shDoubleQuote,shSingleQuote,shExSingleQuote if exists("b:is_bash") - syn region shSetList oneline matchgroup=shSet start="\<\(declare\|typeset\|local\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shOperator end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+#\|=" contains=@shIdList - syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="\ze[;|)]\|$" matchgroup=shOperator end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\<\(declare\|typeset\|local\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+#\|=" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="\ze[;|)]\|$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList elseif exists("b:is_kornshell") - syn region shSetList oneline matchgroup=shSet start="\<\(typeset\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shOperator end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList - syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="$" matchgroup=shOperator end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\<\(typeset\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList else - syn region shSetList oneline matchgroup=shSet start="\<\(set\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shOperator end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\<\(set\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList endif " Functions: {{{1 @@ -419,8 +419,8 @@ if exists("b:is_bash") || exists("b:is_kornshell") syn region shDerefPattern contained start="{" end="}" contains=shDeref,shDerefSimple,shDerefString,shCommandSub nextgroup=shDerefPattern syn match shDerefEscape contained '\%(\\\\\)*\\.' endif -syn region shDerefString contained matchgroup=shOperator start=+\%(\\\)\@ " Last Change: Jul 28, 2010 -" Version: 51 +" Version: 52 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax " " Notes: {{{1 @@ -37,6 +37,7 @@ if version < 600 elseif exists("b:current_syntax") finish endif +scriptencoding utf-8 " Define the default highlighting. {{{1 " For version 5.7 and earlier: only when not done already @@ -53,6 +54,14 @@ if exists("g:tex_tex") && !exists("g:tex_no_error") let g:tex_no_error= 1 endif +" let user determine which classes of concealment will be supported +" a=accents/ligatures m=math symbols g=Greek s=superscripts/subscripts +if !exists("g:tex_conceal") + let s:tex_conceal= 'amgs' +else + let s:tex_conceal= g:tex_conceal +endif + " Determine whether or not to use "*.sty" mode {{{1 " The user may override the normal determination by setting " g:tex_stylish to 1 (for "*.sty" mode) @@ -358,7 +367,13 @@ if !exists("tex_no_math") " \left..something.. and \right..something.. support: {{{2 syn match texMathDelimBad contained "\S" - syn match texMathDelim contained "\\\(left\|right\|[bB]igg\=[lr]\)\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad + if has("conceal") && &enc == 'utf-8' && s:tex_conceal =~ 'm' + syn match texMathDelim contained "\\left\\{\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad contains=texMathSymbol cchar={ + syn match texMathDelim contained "\\right\\}\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad contains=texMathSymbol cchar=} + else + syn match texMathDelim contained "\\\(left\|right\)\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad + endif + syn match texMathDelim contained "\\\([bB]igg\=[lr]\)\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad syn match texMathDelim contained "\\\(left\|right\)arrow\>\|\<\([aA]rrow\|brace\)\=vert\>" syn match texMathDelim contained "\\lefteqn\>" syn match texMathDelimSet2 contained "\\" nextgroup=texMathDelimKey,texMathDelimBad @@ -480,220 +495,297 @@ endif if has("conceal") && &enc == 'utf-8' " Math Symbols {{{2 - syn match texMathSymbol '\\left(' contained conceal cchar=( - syn match texMathSymbol '\\right)' contained conceal cchar=) - syn match texMathSymbol '\\left{' contained conceal cchar={ - syn match texMathSymbol '\\right}' contained conceal cchar=} - syn match texMathSymbol '\\cdot\>' contained conceal cchar=· - syn match texMathSymbol '\\leq\>' contained conceal cchar=≤ - syn match texMathSymbol '\\geq\>' contained conceal cchar=≥ - syn match texMathSymbol '\\cdot\>' contained conceal cchar=· - syn match texMathSymbol '\\times\>' contained conceal cchar=× - syn match texMathSymbol '\\div\>' contained conceal cchar=÷ - syn match texMathSymbol '\\pm\>' contained conceal cchar=± - syn match texMathSymbol '\\neq\>' contained conceal cchar=≠ - syn match texMathSymbol '\\cong\>' contained conceal cchar=≅ + if s:tex_conceal =~ 'm' + syn match texMathSymbol '\\approx\>' contained conceal cchar=≈ + syn match texMathSymbol '\\ast\>' contained conceal cchar=∗ + syn match texMathSymbol '\\bigtriangledown\>' contained conceal cchar=∇ + syn match texMathSymbol '\\bigvee\>' contained conceal cchar=⋁ + syn match texMathSymbol '\\bigwedge\>' contained conceal cchar=⋀ + syn match texMathSymbol '\\blacksquare\>' contained conceal cchar=∎ + syn match texMathSymbol '\\cap\>' contained conceal cchar=∩ + syn match texMathSymbol '\\cdot\>' contained conceal cchar=· + syn match texMathSymbol '\\circ\>' contained conceal cchar=∘ + syn match texMathSymbol '\\circledcirc\>' contained conceal cchar=⊚ + syn match texMathSymbol '\\cong\>' contained conceal cchar=≅ + syn match texMathSymbol '\\cup\>' contained conceal cchar=∪ + syn match texMathSymbol '\\diamond\>' contained conceal cchar=⋄ + syn match texMathSymbol '\\div\>' contained conceal cchar=÷ + syn match texMathSymbol '\\doteq\>' contained conceal cchar=≐ + syn match texMathSymbol '\\dotsb\>' contained conceal cchar=⋯ + syn match texMathSymbol '\\emptyset\>' contained conceal cchar=∅ + syn match texMathSymbol '\\equiv\>' contained conceal cchar=≡ + syn match texMathSymbol '\\forall\>' contained conceal cchar=∀ + syn match texMathSymbol '\\geq\>' contained conceal cchar=≥ + syn match texMathSymbol '\\geq\>' contained conceal cchar=≥ + syn match texMathSymbol '\\gg\>' contained conceal cchar=⟫ + syn match texMathSymbol '\\gtreqless\>' contained conceal cchar=⋛ + syn match texMathSymbol '\\gtrless\>' contained conceal cchar=≷ + syn match texMathSymbol '\\Im\>' contained conceal cchar=ℑ + syn match texMathSymbol '\\in\>' contained conceal cchar=∈ + syn match texMathSymbol '\\infty\>' contained conceal cchar=∞ + syn match texMathSymbol '\\lceil\>' contained conceal cchar=⌈ + syn match texMathSymbol '\\leftarrow\>' contained conceal cchar=⟶ + syn match texMathSymbol '\\Leftarrow\>' contained conceal cchar=⟹ + syn match texMathSymbol '\\left(' contained conceal cchar=( + syn match texMathSymbol '\\left\[' contained conceal cchar=[ + syn match texMathSymbol '\\left\\{' contained conceal cchar={ + syn match texMathSymbol '\\leq\>' contained conceal cchar=≤ + syn match texMathSymbol '\\leq\>' contained conceal cchar=≤ + syn match texMathSymbol '\\lesseqgtr\>' contained conceal cchar=⋚ + syn match texMathSymbol '\\lfloor\>' contained conceal cchar=⌊ + syn match texMathSymbol '\\ll\>' contained conceal cchar=⟪ + syn match texMathSymbol '\\mapsto\>' contained conceal cchar=↦ + syn match texMathSymbol '\\mp\>' contained conceal cchar=∓ + syn match texMathSymbol '\\neq\>' contained conceal cchar=≠ + syn match texMathSymbol '\\ngeq\>' contained conceal cchar=≱ + syn match texMathSymbol '\\ngtr\>' contained conceal cchar=≯ + syn match texMathSymbol '\\nleq\>' contained conceal cchar=≰ + syn match texMathSymbol '\\nless\>' contained conceal cchar=≮ + syn match texMathSymbol '\\notin\>' contained conceal cchar=∉ + syn match texMathSymbol '\\odot\>' contained conceal cchar=⊙ + syn match texMathSymbol '\\oint\>' contained conceal cchar=∮ + syn match texMathSymbol '\\oplus\>' contained conceal cchar=⊕ + syn match texMathSymbol '\\oslash\>' contained conceal cchar=⊘ + syn match texMathSymbol '\\otimes\>' contained conceal cchar=⊗ + syn match texMathSymbol '\\partial\>' contained conceal cchar=∂ + syn match texMathSymbol '\\perp\>' contained conceal cchar=⊥ + syn match texMathSymbol '\\pm\>' contained conceal cchar=± + syn match texMathSymbol '\\prec\>' contained conceal cchar=≺ + syn match texMathSymbol '\\prod\>' contained conceal cchar=∏ + syn match texMathSymbol '\\propto\>' contained conceal cchar=∝ + syn match texMathSymbol '\\rceil\>' contained conceal cchar=⌉ + syn match texMathSymbol '\\Re\>' contained conceal cchar=ℜ + syn match texMathSymbol '\\rfloor\>' contained conceal cchar=⌋ + syn match texMathSymbol '\\rightarrow\>' contained conceal cchar=⟵ + syn match texMathSymbol '\\Rightarrow\>' contained conceal cchar=⟸ + syn match texMathSymbol '\\right)' contained conceal cchar=) + syn match texMathSymbol '\\right]' contained conceal cchar=] + syn match texMathSymbol '\\right\\}' contained conceal cchar=} + syn match texMathSymbol '\\sqcap\>' contained conceal cchar=⊓ + syn match texMathSymbol '\\sqcup\>' contained conceal cchar=⊔ + syn match texMathSymbol '\\subset\>' contained conceal cchar=⊂ + syn match texMathSymbol '\\subseteq\>' contained conceal cchar=⊆ + syn match texMathSymbol '\\subsetneq\>' contained conceal cchar=⊊ + syn match texMathSymbol '\\succ\>' contained conceal cchar=≻ + syn match texMathSymbol '\\sum\>' contained conceal cchar=∑ + syn match texMathSymbol '\\supseteq\>' contained conceal cchar=⊇ + syn match texMathSymbol '\\supsetneq\>' contained conceal cchar=⊋ + syn match texMathSymbol '\\surd\>' contained conceal cchar=√ + syn match texMathSymbol '\\therefore\>' contained conceal cchar=∴ + syn match texMathSymbol '\\times\>' contained conceal cchar=× + syn match texMathSymbol '\\to\>' contained conceal cchar=→ + syn match texMathSymbol '\\trianglelefteq\>' contained conceal cchar=⊴ + syn match texMathSymbol '\\trianglerighteq\>' contained conceal cchar=⊵ + syn match texMathSymbol '\\vartriangle\>' contained conceal cchar=∆ + syn match texMathSymbol '\\vdots\>' contained conceal cchar=⋮ + endif " Greek {{{2 - fun! s:Greek(group,pat,cchar) - exe 'syn match '.a:group." '".a:pat."' contained conceal cchar=".a:cchar - endfun - call s:Greek('texGreek','\\alpha\>' ,'α') - call s:Greek('texGreek','\\beta\>' ,'β') - call s:Greek('texGreek','\\gamma\>' ,'γ') - call s:Greek('texGreek','\\delta\>' ,'δ') - call s:Greek('texGreek','\\epsilon\>' ,'ϵ') - call s:Greek('texGreek','\\varepsilon\>' ,'ε') - call s:Greek('texGreek','\\zeta\>' ,'ζ') - call s:Greek('texGreek','\\eta\>' ,'η') - call s:Greek('texGreek','\\theta\>' ,'θ') - call s:Greek('texGreek','\\vartheta\>' ,'ϑ') - call s:Greek('texGreek','\\kappa\>' ,'κ') - call s:Greek('texGreek','\\lambda\>' ,'λ') - call s:Greek('texGreek','\\mu\>' ,'μ') - call s:Greek('texGreek','\\nu\>' ,'ν') - call s:Greek('texGreek','\\xi\>' ,'ξ') - call s:Greek('texGreek','\\pi\>' ,'π') - call s:Greek('texGreek','\\varpi\>' ,'ϖ') - call s:Greek('texGreek','\\rho\>' ,'ρ') - call s:Greek('texGreek','\\varrho\>' ,'ϱ') - call s:Greek('texGreek','\\sigma\>' ,'σ') - call s:Greek('texGreek','\\varsigma\>' ,'ς') - call s:Greek('texGreek','\\tau\>' ,'τ') - call s:Greek('texGreek','\\upsilon\>' ,'υ') - call s:Greek('texGreek','\\phi\>' ,'φ') - call s:Greek('texGreek','\\varphi\>' ,'ϕ') - call s:Greek('texGreek','\\chi\>' ,'χ') - call s:Greek('texGreek','\\psi\>' ,'ψ') - call s:Greek('texGreek','\\omega\>' ,'ω') - call s:Greek('texGreek','\\Gamma\>' ,'Γ') - call s:Greek('texGreek','\\Delta\>' ,'Δ') - call s:Greek('texGreek','\\Theta\>' ,'Θ') - call s:Greek('texGreek','\\Lambda\>' ,'Λ') - call s:Greek('texGreek','\\Xi\>' ,'Χ') - call s:Greek('texGreek','\\Pi\>' ,'Π') - call s:Greek('texGreek','\\Sigma\>' ,'Σ') - call s:Greek('texGreek','\\Upsilon\>' ,'Υ') - call s:Greek('texGreek','\\Phi\>' ,'Φ') - call s:Greek('texGreek','\\Psi\>' ,'Ψ') - call s:Greek('texGreek','\\Omega\>' ,'Ω') - delfun s:Greek + if s:tex_conceal =~ 'g' + fun! s:Greek(group,pat,cchar) + exe 'syn match '.a:group." '".a:pat."' contained conceal cchar=".a:cchar + endfun + call s:Greek('texGreek','\\alpha\>' ,'α') + call s:Greek('texGreek','\\beta\>' ,'β') + call s:Greek('texGreek','\\gamma\>' ,'γ') + call s:Greek('texGreek','\\delta\>' ,'δ') + call s:Greek('texGreek','\\epsilon\>' ,'ϵ') + call s:Greek('texGreek','\\varepsilon\>' ,'ε') + call s:Greek('texGreek','\\zeta\>' ,'ζ') + call s:Greek('texGreek','\\eta\>' ,'η') + call s:Greek('texGreek','\\theta\>' ,'θ') + call s:Greek('texGreek','\\vartheta\>' ,'ϑ') + call s:Greek('texGreek','\\kappa\>' ,'κ') + call s:Greek('texGreek','\\lambda\>' ,'λ') + call s:Greek('texGreek','\\mu\>' ,'μ') + call s:Greek('texGreek','\\nu\>' ,'ν') + call s:Greek('texGreek','\\xi\>' ,'ξ') + call s:Greek('texGreek','\\pi\>' ,'π') + call s:Greek('texGreek','\\varpi\>' ,'ϖ') + call s:Greek('texGreek','\\rho\>' ,'ρ') + call s:Greek('texGreek','\\varrho\>' ,'ϱ') + call s:Greek('texGreek','\\sigma\>' ,'σ') + call s:Greek('texGreek','\\varsigma\>' ,'ς') + call s:Greek('texGreek','\\tau\>' ,'τ') + call s:Greek('texGreek','\\upsilon\>' ,'υ') + call s:Greek('texGreek','\\phi\>' ,'φ') + call s:Greek('texGreek','\\varphi\>' ,'ϕ') + call s:Greek('texGreek','\\chi\>' ,'χ') + call s:Greek('texGreek','\\psi\>' ,'ψ') + call s:Greek('texGreek','\\omega\>' ,'ω') + call s:Greek('texGreek','\\Gamma\>' ,'Γ') + call s:Greek('texGreek','\\Delta\>' ,'Δ') + call s:Greek('texGreek','\\Theta\>' ,'Θ') + call s:Greek('texGreek','\\Lambda\>' ,'Λ') + call s:Greek('texGreek','\\Xi\>' ,'Χ') + call s:Greek('texGreek','\\Pi\>' ,'Π') + call s:Greek('texGreek','\\Sigma\>' ,'Σ') + call s:Greek('texGreek','\\Upsilon\>' ,'Υ') + call s:Greek('texGreek','\\Phi\>' ,'Φ') + call s:Greek('texGreek','\\Psi\>' ,'Ψ') + call s:Greek('texGreek','\\Omega\>' ,'Ω') + delfun s:Greek + endif " Superscripts/Subscripts {{{2 - syn region texSuperscript matchgroup=Delimiter start='\^{' end='}' contained concealends contains=texSuperscripts - syn region texSubscript matchgroup=Delimiter start='_{' end='}' contained concealends contains=texSubscripts - fun! s:SuperSub(group,leader,pat,cchar) - exe 'syn match '.a:group." '".a:leader.a:pat."' contained conceal cchar=".a:cchar - exe 'syn match '.a:group."s '".a:pat."' contained conceal cchar=".a:cchar.' nextgroup='.a:group.'s' - endfun - call s:SuperSub('texSuperscript','\^','0','⁰') - call s:SuperSub('texSuperscript','\^','1','¹') - call s:SuperSub('texSuperscript','\^','2','²') - call s:SuperSub('texSuperscript','\^','3','³') - call s:SuperSub('texSuperscript','\^','4','⁴') - call s:SuperSub('texSuperscript','\^','5','⁵') - call s:SuperSub('texSuperscript','\^','6','⁶') - call s:SuperSub('texSuperscript','\^','7','⁷') - call s:SuperSub('texSuperscript','\^','8','⁸') - call s:SuperSub('texSuperscript','\^','9','⁹') - call s:SuperSub('texSuperscript','\^','a','ᵃ') - call s:SuperSub('texSuperscript','\^','b','ᵇ') - call s:SuperSub('texSuperscript','\^','c','ᶜ') - call s:SuperSub('texSuperscript','\^','d','ᵈ') - call s:SuperSub('texSuperscript','\^','e','ᵉ') - call s:SuperSub('texSuperscript','\^','f','ᶠ') - call s:SuperSub('texSuperscript','\^','g','ᵍ') - call s:SuperSub('texSuperscript','\^','h','ʰ') - call s:SuperSub('texSuperscript','\^','i','ⁱ') - call s:SuperSub('texSuperscript','\^','j','ʲ') - call s:SuperSub('texSuperscript','\^','k','ᵏ') - call s:SuperSub('texSuperscript','\^','l','ˡ') - call s:SuperSub('texSuperscript','\^','m','ᵐ') - call s:SuperSub('texSuperscript','\^','n','ⁿ') - call s:SuperSub('texSuperscript','\^','o','ᵒ') - call s:SuperSub('texSuperscript','\^','p','ᵖ') - call s:SuperSub('texSuperscript','\^','r','ʳ') - call s:SuperSub('texSuperscript','\^','s','ˢ') - call s:SuperSub('texSuperscript','\^','t','ᵗ') - call s:SuperSub('texSuperscript','\^','u','ᵘ') - call s:SuperSub('texSuperscript','\^','v','ᵛ') - call s:SuperSub('texSuperscript','\^','w','ʷ') - call s:SuperSub('texSuperscript','\^','x','ˣ') - call s:SuperSub('texSuperscript','\^','y','ʸ') - call s:SuperSub('texSuperscript','\^','z','ᶻ') - call s:SuperSub('texSuperscript','\^','A','ᴬ') - call s:SuperSub('texSuperscript','\^','B','ᴮ') - call s:SuperSub('texSuperscript','\^','D','ᴰ') - call s:SuperSub('texSuperscript','\^','E','ᴱ') - call s:SuperSub('texSuperscript','\^','G','ᴳ') - call s:SuperSub('texSuperscript','\^','H','ᴴ') - call s:SuperSub('texSuperscript','\^','I','ᴵ') - call s:SuperSub('texSuperscript','\^','J','ᴶ') - call s:SuperSub('texSuperscript','\^','K','ᴷ') - call s:SuperSub('texSuperscript','\^','L','ᴸ') - call s:SuperSub('texSuperscript','\^','M','ᴹ') - call s:SuperSub('texSuperscript','\^','N','ᴺ') - call s:SuperSub('texSuperscript','\^','O','ᴼ') - call s:SuperSub('texSuperscript','\^','P','ᴾ') - call s:SuperSub('texSuperscript','\^','R','ᴿ') - call s:SuperSub('texSuperscript','\^','T','ᵀ') - call s:SuperSub('texSuperscript','\^','U','ᵁ') - call s:SuperSub('texSuperscript','\^','W','ᵂ') - call s:SuperSub('texSuperscript','\^','+','⁺') - call s:SuperSub('texSuperscript','\^','-','⁻') - call s:SuperSub('texSuperscript','\^','<','˂') - call s:SuperSub('texSuperscript','\^','>','˃') - call s:SuperSub('texSuperscript','\^','/','ˊ') - call s:SuperSub('texSuperscript','\^','(','⁽') - call s:SuperSub('texSuperscript','\^',')','⁾') - call s:SuperSub('texSuperscript','\^','\.','˙') - call s:SuperSub('texSuperscript','\^','=','˭') - call s:SuperSub('texSubscript','_','0','₀') - call s:SuperSub('texSubscript','_','1','₁') - call s:SuperSub('texSubscript','_','2','₂') - call s:SuperSub('texSubscript','_','3','₃') - call s:SuperSub('texSubscript','_','4','₄') - call s:SuperSub('texSubscript','_','5','₅') - call s:SuperSub('texSubscript','_','6','₆') - call s:SuperSub('texSubscript','_','7','₇') - call s:SuperSub('texSubscript','_','8','₈') - call s:SuperSub('texSubscript','_','9','₉') - call s:SuperSub('texSubscript','_','a','ₐ') - call s:SuperSub('texSubscript','_','e','ₑ') - call s:SuperSub('texSubscript','_','i','ᵢ') - call s:SuperSub('texSubscript','_','o','ₒ') - call s:SuperSub('texSubscript','_','u','ᵤ') - call s:SuperSub('texSubscript','_','+','₊') - call s:SuperSub('texSubscript','_','-','₋') - call s:SuperSub('texSubscript','_','/','ˏ') - call s:SuperSub('texSubscript','_','(','₍') - call s:SuperSub('texSubscript','_',')','₎') - call s:SuperSub('texSubscript','_','\.','‸') - call s:SuperSub('texSubscript','_','r','ᵣ') - call s:SuperSub('texSubscript','_','v','ᵥ') - call s:SuperSub('texSubscript','_','x','ₓ') - call s:SuperSub('texSubscript','_','\\beta\>' ,'ᵦ') - call s:SuperSub('texSubscript','_','\\delta\>','ᵨ') - call s:SuperSub('texSubscript','_','\\phi\>' ,'ᵩ') - call s:SuperSub('texSubscript','_','\\gamma\>','ᵧ') - call s:SuperSub('texSubscript','_','\\chi\>' ,'ᵪ') - delfun s:SuperSub + if s:tex_conceal =~ 's' + syn region texSuperscript matchgroup=Delimiter start='\^{' end='}' contained concealends contains=texSuperscripts,texStatement + syn region texSubscript matchgroup=Delimiter start='_{' end='}' contained concealends contains=texSubscripts,texStatement + fun! s:SuperSub(group,leader,pat,cchar) + exe 'syn match '.a:group." '".a:leader.a:pat."' contained conceal cchar=".a:cchar + exe 'syn match '.a:group."s '".a:pat."' contained conceal cchar=".a:cchar.' nextgroup='.a:group.'s' + endfun + call s:SuperSub('texSuperscript','\^','0','⁰') + call s:SuperSub('texSuperscript','\^','1','¹') + call s:SuperSub('texSuperscript','\^','2','²') + call s:SuperSub('texSuperscript','\^','3','³') + call s:SuperSub('texSuperscript','\^','4','⁴') + call s:SuperSub('texSuperscript','\^','5','⁵') + call s:SuperSub('texSuperscript','\^','6','⁶') + call s:SuperSub('texSuperscript','\^','7','⁷') + call s:SuperSub('texSuperscript','\^','8','⁸') + call s:SuperSub('texSuperscript','\^','9','⁹') + call s:SuperSub('texSuperscript','\^','a','ᵃ') + call s:SuperSub('texSuperscript','\^','b','ᵇ') + call s:SuperSub('texSuperscript','\^','c','ᶜ') + call s:SuperSub('texSuperscript','\^','d','ᵈ') + call s:SuperSub('texSuperscript','\^','e','ᵉ') + call s:SuperSub('texSuperscript','\^','f','ᶠ') + call s:SuperSub('texSuperscript','\^','g','ᵍ') + call s:SuperSub('texSuperscript','\^','h','ʰ') + call s:SuperSub('texSuperscript','\^','i','ⁱ') + call s:SuperSub('texSuperscript','\^','j','ʲ') + call s:SuperSub('texSuperscript','\^','k','ᵏ') + call s:SuperSub('texSuperscript','\^','l','ˡ') + call s:SuperSub('texSuperscript','\^','m','ᵐ') + call s:SuperSub('texSuperscript','\^','n','ⁿ') + call s:SuperSub('texSuperscript','\^','o','ᵒ') + call s:SuperSub('texSuperscript','\^','p','ᵖ') + call s:SuperSub('texSuperscript','\^','r','ʳ') + call s:SuperSub('texSuperscript','\^','s','ˢ') + call s:SuperSub('texSuperscript','\^','t','ᵗ') + call s:SuperSub('texSuperscript','\^','u','ᵘ') + call s:SuperSub('texSuperscript','\^','v','ᵛ') + call s:SuperSub('texSuperscript','\^','w','ʷ') + call s:SuperSub('texSuperscript','\^','x','ˣ') + call s:SuperSub('texSuperscript','\^','y','ʸ') + call s:SuperSub('texSuperscript','\^','z','ᶻ') + call s:SuperSub('texSuperscript','\^','A','ᴬ') + call s:SuperSub('texSuperscript','\^','B','ᴮ') + call s:SuperSub('texSuperscript','\^','D','ᴰ') + call s:SuperSub('texSuperscript','\^','E','ᴱ') + call s:SuperSub('texSuperscript','\^','G','ᴳ') + call s:SuperSub('texSuperscript','\^','H','ᴴ') + call s:SuperSub('texSuperscript','\^','I','ᴵ') + call s:SuperSub('texSuperscript','\^','J','ᴶ') + call s:SuperSub('texSuperscript','\^','K','ᴷ') + call s:SuperSub('texSuperscript','\^','L','ᴸ') + call s:SuperSub('texSuperscript','\^','M','ᴹ') + call s:SuperSub('texSuperscript','\^','N','ᴺ') + call s:SuperSub('texSuperscript','\^','O','ᴼ') + call s:SuperSub('texSuperscript','\^','P','ᴾ') + call s:SuperSub('texSuperscript','\^','R','ᴿ') + call s:SuperSub('texSuperscript','\^','T','ᵀ') + call s:SuperSub('texSuperscript','\^','U','ᵁ') + call s:SuperSub('texSuperscript','\^','W','ᵂ') + call s:SuperSub('texSuperscript','\^','+','⁺') + call s:SuperSub('texSuperscript','\^','-','⁻') + call s:SuperSub('texSuperscript','\^','<','˂') + call s:SuperSub('texSuperscript','\^','>','˃') + call s:SuperSub('texSuperscript','\^','/','ˊ') + call s:SuperSub('texSuperscript','\^','(','⁽') + call s:SuperSub('texSuperscript','\^',')','⁾') + call s:SuperSub('texSuperscript','\^','\.','˙') + call s:SuperSub('texSuperscript','\^','=','˭') + call s:SuperSub('texSubscript','_','0','₀') + call s:SuperSub('texSubscript','_','1','₁') + call s:SuperSub('texSubscript','_','2','₂') + call s:SuperSub('texSubscript','_','3','₃') + call s:SuperSub('texSubscript','_','4','₄') + call s:SuperSub('texSubscript','_','5','₅') + call s:SuperSub('texSubscript','_','6','₆') + call s:SuperSub('texSubscript','_','7','₇') + call s:SuperSub('texSubscript','_','8','₈') + call s:SuperSub('texSubscript','_','9','₉') + call s:SuperSub('texSubscript','_','a','ₐ') + call s:SuperSub('texSubscript','_','e','ₑ') + call s:SuperSub('texSubscript','_','i','ᵢ') + call s:SuperSub('texSubscript','_','o','ₒ') + call s:SuperSub('texSubscript','_','u','ᵤ') + call s:SuperSub('texSubscript','_','+','₊') + call s:SuperSub('texSubscript','_','-','₋') + call s:SuperSub('texSubscript','_','/','ˏ') + call s:SuperSub('texSubscript','_','(','₍') + call s:SuperSub('texSubscript','_',')','₎') + call s:SuperSub('texSubscript','_','\.','‸') + call s:SuperSub('texSubscript','_','r','ᵣ') + call s:SuperSub('texSubscript','_','v','ᵥ') + call s:SuperSub('texSubscript','_','x','ₓ') + call s:SuperSub('texSubscript','_','\\beta\>' ,'ᵦ') + call s:SuperSub('texSubscript','_','\\delta\>','ᵨ') + call s:SuperSub('texSubscript','_','\\phi\>' ,'ᵩ') + call s:SuperSub('texSubscript','_','\\gamma\>','ᵧ') + call s:SuperSub('texSubscript','_','\\chi\>' ,'ᵪ') + delfun s:SuperSub + endif " Accented characters: {{{2 - if b:tex_stylish - syn match texAccent "\\[bcdvuH][^a-zA-Z@]"me=e-1 - syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)[^a-zA-Z@]"me=e-1 - else - fun! s:Accents(chr,...) - let i= 1 - for accent in ["`","\\'","^",'"','\~',"r","v"] - if i > a:0 - break - endif - if strlen(a:{i}) == 0 + if s:tex_conceal =~ 'a' + if b:tex_stylish + syn match texAccent "\\[bcdvuH][^a-zA-Z@]"me=e-1 + syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)[^a-zA-Z@]"me=e-1 + else + fun! s:Accents(chr,...) + let i= 1 + for accent in ["`","\\'","^",'"','\~',"r","v"] + if i > a:0 + break + endif + if strlen(a:{i}) == 0 + let i= i + 1 + continue + endif + exe "syn match texAccent '\\\\".accent."{".a:chr."}' conceal cchar=".a:{i} let i= i + 1 - continue - endif - exe "syn match texAccent '\\\\".accent."{".a:chr."}' conceal cchar=".a:{i} - let i= i + 1 - endfor - endfun - call s:Accents('a','à','á','â','ä','ã','å','ă') - call s:Accents('A','À','Á','Â','Ä','Ã','Å','Ă') - call s:Accents('C',"" ,'Ć','Ĉ',"" ,"" ,"" ,'Ć') - call s:Accents('e','è','é','ê','ë','ẽ',"" ,'ĕ') - call s:Accents('E','È','É','Ê','Ë','Ẽ',"" ,'Ė') - call s:Accents('i','ì','í','î','ï','ĩ',"" ,"ĭ") - call s:Accents('I','Ì','Í','Î','Ï','Ĩ',"" ,'Ĭ') - call s:Accents('o','ò','ó','ô','ö','õ',"" ,'ŏ') - call s:Accents('O','Ò','Ó','Ô','Ö','Õ',"" ,'Ŏ') - call s:Accents('r',"" ,'ŕ',"" ,"" ,"" ,"" ,'ř') - call s:Accents('R',"" ,'Ŕ',"" ,"" ,"" ,"" ,'Ř') - call s:Accents('s',"" ,'ś','ŝ',"" ,"" ,"" ,'š') - call s:Accents('S',"" ,'Ś','Ŝ',"" ,"" ,"" ,'Š') - call s:Accents('u','ù','ú','û','ü','ũ',"" ,'ŭ') - call s:Accents('U','Ù','Ú','Û','Ü','Ũ',"" ,'Ŭ') - call s:Accents('y','ỳ','ý','ŷ','ÿ','ỹ',"" ,"" ) - call s:Accents('Y','Ỳ','Ý','Ŷ','Ÿ','Ỹ',"" ,"" ) - delfun s:Accents - syn match texAccent '\\aa\>' conceal cchar=å - syn match texAccent '\\AA\>' conceal cchar=Å - syn match texAccent '\\k{a}' conceal cchar=ą - syn match texAccent '\\k{A}' conceal cchar=Ą - syn match texAccent '\\c{C}' conceal cchar=Ç - syn match texAccent '\\c{c}' conceal cchar=ç - syn match texAccent '\\\~{n}' conceal cchar=ñ - syn match texAccent '\\\~{N}' conceal cchar=Ñ - syn match texAccent '\\o\>' conceal cchar=ø - syn match texAccent '\\O\>' conceal cchar=Ø - syn match texAccent '\\H{o}' conceal cchar=ő - syn match texAccent '\\H{O}' conceal cchar=Ő - syn match texAccent '\\c{r}' conceal cchar=ŗ - syn match texLigature '\\AE\>' conceal cchar=Æ - syn match texLigature '\\ae\>' conceal cchar=æ - syn match texLigature '\\oe\>' conceal cchar=œ - syn match texLigature '\\OE\>' conceal cchar=Œ - syn match texLigature '\\ss\>' conceal cchar=ß + endfor + endfun + call s:Accents('a','à','á','â','ä','ã','å','ă') + call s:Accents('A','À','Á','Â','Ä','Ã','Å','Ă') + call s:Accents('C',"" ,'Ć','Ĉ',"" ,"" ,"" ,'Ć') + call s:Accents('e','è','é','ê','ë','ẽ',"" ,'ĕ') + call s:Accents('E','È','É','Ê','Ë','Ẽ',"" ,'Ė') + call s:Accents('i','ì','í','î','ï','ĩ',"" ,"ĭ") + call s:Accents('I','Ì','Í','Î','Ï','Ĩ',"" ,'Ĭ') + call s:Accents('o','ò','ó','ô','ö','õ',"" ,'ŏ') + call s:Accents('O','Ò','Ó','Ô','Ö','Õ',"" ,'Ŏ') + call s:Accents('r',"" ,'ŕ',"" ,"" ,"" ,"" ,'ř') + call s:Accents('R',"" ,'Ŕ',"" ,"" ,"" ,"" ,'Ř') + call s:Accents('s',"" ,'ś','ŝ',"" ,"" ,"" ,'š') + call s:Accents('S',"" ,'Ś','Ŝ',"" ,"" ,"" ,'Š') + call s:Accents('u','ù','ú','û','ü','ũ',"" ,'ŭ') + call s:Accents('U','Ù','Ú','Û','Ü','Ũ',"" ,'Ŭ') + call s:Accents('y','ỳ','ý','ŷ','ÿ','ỹ',"" ,"" ) + call s:Accents('Y','Ỳ','Ý','Ŷ','Ÿ','Ỹ',"" ,"" ) + delfun s:Accents + syn match texAccent '\\aa\>' conceal cchar=å + syn match texAccent '\\AA\>' conceal cchar=Å + syn match texAccent '\\k{a}' conceal cchar=ą + syn match texAccent '\\k{A}' conceal cchar=Ą + syn match texAccent '\\c{C}' conceal cchar=Ç + syn match texAccent '\\c{c}' conceal cchar=ç + syn match texAccent '\\\~{n}' conceal cchar=ñ + syn match texAccent '\\\~{N}' conceal cchar=Ñ + syn match texAccent '\\o\>' conceal cchar=ø + syn match texAccent '\\O\>' conceal cchar=Ø + syn match texAccent '\\H{o}' conceal cchar=ő + syn match texAccent '\\H{O}' conceal cchar=Ő + syn match texAccent '\\c{r}' conceal cchar=ŗ + syn match texLigature '\\AE\>' conceal cchar=Æ + syn match texLigature '\\ae\>' conceal cchar=æ + syn match texLigature '\\oe\>' conceal cchar=œ + syn match texLigature '\\OE\>' conceal cchar=Œ + syn match texLigature '\\ss\>' conceal cchar=ß + endif endif endif diff --git a/runtime/syntax/vim.vim b/runtime/syntax/vim.vim index edfe878719..a205d9c8a9 100644 --- a/runtime/syntax/vim.vim +++ b/runtime/syntax/vim.vim @@ -1,8 +1,8 @@ " Vim syntax file " Language: Vim 7.3 script " Maintainer: Dr. Charles E. Campbell, Jr. -" Last Change: Jul 19, 2010 -" Version: 7.3-02 +" Last Change: Jul 28, 2010 +" Version: 7.3-03 " Automatically generated keyword lists: {{{1 " Quit when a syntax file was already loaded {{{2 @@ -532,19 +532,43 @@ syn region vimGlobal matchgroup=Statement start='\:p:h")."/lua.vim" +if !filereadable(s:luapath) + let s:luapath= globpath(&rtp,"syntax/lua.vim") +endif +if (g:vimsyn_embed =~ 'p' && has("lua")) && filereadable(s:luapath) + unlet! b:current_syntax + exe "syn include @vimLuaScript ".s:luapath + if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'l' + syn region vimLuaRegion fold matchgroup=vimScriptDelim start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimLuaScript + syn region vimLuaRegion fold matchgroup=vimScriptDelim start=+lua\s*<<\s*$+ end=+\.$+ contains=@vimLuaScript + else + syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimLuaScript + syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*$+ end=+\.$+ contains=@vimLuaScript + endif + syn cluster vimFuncBodyList add=vimLuaRegion +else + syn region vimEmbedError start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+lua\s*<<\s*$+ end=+\.$+ +endif +unlet s:luapath + " [-- perl --] {{{3 let s:perlpath= expand(":p:h")."/perl.vim" if !filereadable(s:perlpath) diff --git a/runtime/syntax/yacc.vim b/runtime/syntax/yacc.vim index 1797b7a643..c3916d0e53 100644 --- a/runtime/syntax/yacc.vim +++ b/runtime/syntax/yacc.vim @@ -1,8 +1,8 @@ " Vim syntax file " Language: Yacc " Maintainer: Charles E. Campbell, Jr. -" Last Change: Oct 21, 2008 -" Version: 7 +" Last Change: Aug 2, 2010 +" Version: 8 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax " " Options: {{{1 @@ -35,7 +35,7 @@ endif " --------------------------------------------------------------------- " Yacc Clusters: {{{1 -syn cluster yaccInitCluster contains=yaccKey,yaccKeyActn,yaccBrkt,yaccType,yaccString,yaccUnionStart,yaccHeader2,yaccComment +syn cluster yaccInitCluster contains=yaccKey,yaccKeyActn,yaccBrkt,yaccType,yaccString,yaccUnionStart,yaccHeader2,yaccComment,yaccDefines,yaccParseParam syn cluster yaccRulesCluster contains=yaccNonterminal,yaccString " --------------------------------------------------------------------- @@ -49,6 +49,10 @@ HiFold syn region yaccEndCode matchgroup=yaccSectionSep start='^%%$' end='\%$' " --------------------------------------------------------------------- " Yacc Commands: {{{1 +syn match yaccDefines '^%define\s\+.*$' +syn match yaccParseParam '%parse-param\>' skipwhite nextgroup=yaccParseParamStr +syn region yaccParseParamStr contained matchgroup=Delimiter start='{' end='}' contains=cStructure + syn match yaccDelim "[:|]" contained syn match yaccOper "@\d\+" contained @@ -91,6 +95,8 @@ if !exists("did_yacc_syn_inits") HiLink yaccComment Comment HiLink yaccCurly Delimiter HiLink yaccCurlyError Error + HiLink yaccDefines cDefine + HiLink yaccParseParam cDefine HiLink yaccNonterminal Function HiLink yaccDelim Delimiter HiLink yaccKeyActn Special From 1e68b02c5bde0d27a7ea577735ae7f4fb39318e3 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 22:13:25 +0200 Subject: [PATCH 09/24] Take OLE registration back to 32 bit registry, the unregister wasn't working for the 64 registry. --HG-- branch : vim73 --- src/if_ole.cpp | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/src/if_ole.cpp b/src/if_ole.cpp index ff9e371a70..4c01f51d8b 100644 --- a/src/if_ole.cpp +++ b/src/if_ole.cpp @@ -85,15 +85,6 @@ static CVim *app = 0; #define MAX_CLSID_LEN 100 -/* - * Modern way of creating registry entries, also works on 64 bit windows when - * compiled as a 32 bit program. - */ -# ifndef KEY_WOW64_64KEY -# define KEY_WOW64_64KEY 0x0100 -# define RegDeleteKeyEx(a, b, c, d) RegDeleteKey(a, b) -# endif - /***************************************************************************** 2. The application object *****************************************************************************/ @@ -167,7 +158,7 @@ CVim *CVim::Create(int *pbDoRestart) // RegCreateKeyEx succeeds even if key exists. W.Briscoe W2K 20021011 if (RegCreateKeyEx(HKEY_CLASSES_ROOT, MYVIPROGID, 0, NULL, REG_OPTION_NON_VOLATILE, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, NULL, &hKey, NULL)) + KEY_ALL_ACCESS, NULL, &hKey, NULL)) { delete me; return NULL; // Unable to write to registry. Quietly fail. @@ -660,7 +651,7 @@ static void RecursiveDeleteKey(HKEY hKeyParent, const char *child) // Open the child HKEY hKeyChild; LONG result = RegOpenKeyEx(hKeyParent, child, 0, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, &hKeyChild); + KEY_ALL_ACCESS, &hKeyChild); if (result != ERROR_SUCCESS) return; @@ -703,7 +694,7 @@ static void SetKeyAndValue(const char *key, const char *subkey, const char *valu long result = RegCreateKeyEx(HKEY_CLASSES_ROOT, buffer, 0, NULL, REG_OPTION_NON_VOLATILE, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, NULL, + KEY_ALL_ACCESS, NULL, &hKey, NULL); if (result != ERROR_SUCCESS) return; From 315cc1108f10d79807578ae83ba45ab07ab1aa92 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 2 Aug 2010 23:06:46 +0200 Subject: [PATCH 10/24] Windows uninstaller: Instead of calling RegDeleteKeyEx() directly load it dynamically from the .dll. Should work everywhere. --HG-- branch : vim73 --- runtime/doc/todo.txt | 4 +++ src/dosinst.h | 1 - src/uninstal.c | 63 ++++++++++++++++++++++++++------------------ 3 files changed, 41 insertions(+), 27 deletions(-) diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index 7b9c977db9..2db0ae250c 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -33,6 +33,10 @@ be worked on, but only if you sponsor Vim development. See |sponsor|. Using uninitialized memory when crypting an empty file. (Dominique Pelle, 2010 Aug 2) +Go back to MSVC 2008, so that Windows 2000 is supported? + +For 'undoreload': put the cursor on the first line that is different. + Before release 7.3: - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) diff --git a/src/dosinst.h b/src/dosinst.h index 444af45b2a..b33426ad78 100644 --- a/src/dosinst.h +++ b/src/dosinst.h @@ -89,7 +89,6 @@ char *searchpath(char *name); */ # ifndef KEY_WOW64_64KEY # define KEY_WOW64_64KEY 0x0100 -# define RegDeleteKeyEx(a, b, c, d) RegDeleteKey(a, b) # endif #define VIM_STARTMENU "Programs\\Vim " VIM_VERSION_SHORT diff --git a/src/uninstal.c b/src/uninstal.c index 13138aafbc..99cdc679cc 100644 --- a/src/uninstal.c +++ b/src/uninstal.c @@ -33,6 +33,30 @@ confirm(void) } #ifdef WIN3264 + + static int +reg_delete_key(HKEY hRootKey, const char *key) +{ + static int did_load = FALSE; + static HANDLE advapi_lib = NULL; + static LONG (WINAPI *delete_key_ex)(HKEY, LPCTSTR, REGSAM, DWORD) = NULL; + + if (!did_load) + { + /* The RegDeleteKeyEx() function is only available on new systems. It + * is required for 64-bit registry access. For other systems fall + * back to RegDeleteKey(). */ + did_load = TRUE; + advapi_lib = LoadLibrary("ADVAPI32.DLL"); + if (advapi_lib != NULL) + delete_key_ex = (LONG (WINAPI *)(HKEY, LPCTSTR, REGSAM, DWORD))GetProcAddress(advapi_lib, "RegDeleteKeyExA"); + } + if (delete_key_ex != NULL) { + return (*delete_key_ex)(hRootKey, key, KEY_WOW64_64KEY, 0); + } + return RegDeleteKey(hRootKey, key); +} + /* * Check if the popup menu entry exists and what gvim it refers to. * Returns non-zero when it's found. @@ -89,14 +113,11 @@ remove_popup(void) int fail = 0; HKEY kh; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}\\InProcServer32", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}\\InProcServer32") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "CLSID\\{51EEE242-AD87-11d3-9C1E-0090278BBD99}") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "*\\shellex\\ContextMenuHandlers\\gvim", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "*\\shellex\\ContextMenuHandlers\\gvim") != ERROR_SUCCESS) ++fail; if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Shell Extensions\\Approved", 0, KEY_WOW64_64KEY | KEY_ALL_ACCESS, &kh) != ERROR_SUCCESS) @@ -107,11 +128,9 @@ remove_popup(void) ++fail; RegCloseKey(kh); } - if (RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Vim\\Gvim", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_LOCAL_MACHINE, "Software\\Vim\\Gvim") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Vim", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_LOCAL_MACHINE, "Software\\Vim") != ERROR_SUCCESS) ++fail; if (fail == 6) @@ -127,26 +146,19 @@ remove_openwith(void) { int fail = 0; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit\\command", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit\\command") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell\\edit") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "Applications\\gvim.exe\\shell") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "Applications\\gvim.exe", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "Applications\\gvim.exe") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, ".htm\\OpenWithList\\gvim.exe", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, ".htm\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, ".vim\\OpenWithList\\gvim.exe", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, ".vim\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) ++fail; - if (RegDeleteKeyEx(HKEY_CLASSES_ROOT, "*\\OpenWithList\\gvim.exe", - KEY_WOW64_64KEY, 0) != ERROR_SUCCESS) + if (reg_delete_key(HKEY_CLASSES_ROOT, "*\\OpenWithList\\gvim.exe") != ERROR_SUCCESS) ++fail; if (fail == 7) @@ -302,8 +314,7 @@ win95(void) delete_uninstall_key(void) { #ifdef WIN3264 - RegDeleteKeyEx(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\Vim " VIM_VERSION_SHORT, - KEY_WOW64_64KEY, 0); + reg_delete_key(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\Vim " VIM_VERSION_SHORT); #else FILE *fd; char buf[BUFSIZE]; From 0c8c0341a06172b6adfc886efeec9e2e98e4a9d9 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 3 Aug 2010 22:11:29 +0200 Subject: [PATCH 11/24] Fix: With 'path' set to relative directory ":find" completion didn't work. (Nazri Ramliy) --HG-- branch : vim73 --- src/misc1.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/misc1.c b/src/misc1.c index e564c5cec3..bcf4ce7f83 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -9347,8 +9347,13 @@ expand_path_option(curdir, gap) continue; STRMOVE(buf + curdir_len + 1, buf); STRCPY(buf, curdir); - add_pathsep(buf); - STRMOVE(buf + curdir_len, buf + curdir_len + 1); + buf[curdir_len] = PATHSEP; + /* + * 'path' may have "./baz" as one of the items. + * If curdir is "/foo/bar", p will end up being "/foo/bar/./baz". + * Simplify it. + */ + simplify_filename(buf); } if (ga_grow(gap, 1) == FAIL) From 38356ae07e51dea6b6119be77738ed9b6cded412 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 3 Aug 2010 22:21:00 +0200 Subject: [PATCH 12/24] Fix crash in :find completion. (Nazri Ramliy) --HG-- branch : vim73 --- src/misc1.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/misc1.c b/src/misc1.c index bcf4ce7f83..b0f7e91fcc 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -9587,7 +9587,7 @@ expand_in_path(gap, pattern, flags) char_u *paths = NULL; # endif - if ((curdir = alloc((int)(MAXPATHL))) == NULL) + if ((curdir = alloc((unsigned)MAXPATHL)) == NULL) return 0; mch_dirname(curdir, MAXPATHL); @@ -9595,6 +9595,8 @@ expand_in_path(gap, pattern, flags) vim_free(curdir); path_list = (char_u **)(path_ga.ga_data); # ifdef WIN3264 + if ((file_pattern = alloc((unsigned)MAXPATHL)) == NULL) + return 0; for (i = 0; i < path_ga.ga_len; i++) { if (STRLEN(path_list[i]) + STRLEN(pattern) + 2 > MAXPATHL) @@ -9604,12 +9606,13 @@ expand_in_path(gap, pattern, flags) STRCAT(file_pattern, pattern); mch_expandpath(gap, file_pattern, EW_DIR|EW_ADDSLASH|EW_FILE); } + vim_free(file_pattern); # else for (i = 0; i < path_ga.ga_len; i++) { if (paths == NULL) { - if ((paths = alloc((int)(STRLEN(path_list[i]) + 1))) == NULL) + if ((paths = alloc((unsigned)(STRLEN(path_list[i]) + 1))) == NULL) return 0; STRCPY(paths, path_list[i]); } From 06bc20c9060b81ad6f78b6d636e908eba8c1e538 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 3 Aug 2010 22:45:06 +0200 Subject: [PATCH 13/24] Recognize .f03 and .f08 as Fortran files. (Ajit Thakkar) --HG-- branch : vim73 --- runtime/filetype.vim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/filetype.vim b/runtime/filetype.vim index 98785b39b6..afc0740b1c 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -705,9 +705,9 @@ au BufNewFile,BufRead *.frt setf reva " Fortran if has("fname_case") - au BufNewFile,BufRead *.F,*.FOR,*.FPP,*.FTN,*.F77,*.F90,*.F95 setf fortran + au BufNewFile,BufRead *.F,*.FOR,*.FPP,*.FTN,*.F77,*.F90,*.F95,*.F03,*.F08 setf fortran endif -au BufNewFile,BufRead *.f,*.for,*.fortran,*.fpp,*.ftn,*.f77,*.f90,*.f95 setf fortran +au BufNewFile,BufRead *.f,*.for,*.fortran,*.fpp,*.ftn,*.f77,*.f90,*.f95,*.f03,*.f08 setf fortran " Framescript au BufNewFile,BufRead *.fsl setf framescript From d8ac2e3d0fc1376c3d024958262a278542b569a6 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 3 Aug 2010 23:00:38 +0200 Subject: [PATCH 14/24] Runtime file updates. --HG-- branch : vim73 --- README.txt | 35 +++----------------------- runtime/doc/todo.txt | 4 +-- runtime/syntax/diff.vim | 6 ++++- runtime/syntax/tex.vim | 55 +++++++++++++++++++++++++++++++++-------- 4 files changed, 56 insertions(+), 44 deletions(-) diff --git a/README.txt b/README.txt index 55e25e2169..ccd7d83ff6 100644 --- a/README.txt +++ b/README.txt @@ -14,9 +14,9 @@ All commands are given with normal keyboard characters, so those who can type with ten fingers can work very fast. Additionally, function keys can be defined by the user, and the mouse can be used. -Vim currently runs under Amiga DOS, MS-DOS, MS-Windows 95/98/Me/NT/2000/XP, -Atari MiNT, Macintosh, BeOS, VMS, RISC OS, OS/2 and almost all flavours of -UNIX. Porting to other systems should not be very difficult. +Vim currently runs under Amiga DOS, MS-DOS, MS-Windows (95, 98, Me, NT, 2000, +XP, Vista, 7), Atari MiNT, Macintosh, BeOS, VMS, RISC OS, OS/2 and almost all +flavours of UNIX. Porting to other systems should not be very difficult. DISTRIBUTION @@ -98,34 +98,7 @@ If you have problems, have a look at the Vim FAQ: Send bug reports to: Bram Moolenaar -There are five mailing lists for Vim: - - For discussions about using existing versions of Vim: Useful mappings, - questions, answers, where to get a specific version, etc. - - For discussions about changing Vim: New features, porting, beta-test - versions, etc. - - Announcements about new versions of Vim; also beta-test versions and - ports to different systems. - - For discussions about using and improving the multi-byte aspects of - Vim: XIM, Hangul, fontset, etc. - - For discussions about using and improving Vim on the Macintosh. - -For more info and URLs of the archives see "http://www.vim.org/maillist.php". - -NOTE: -- You can only send messages to these lists if you have subscribed! -- You need to send the messages from the same location as where you subscribed - from (to avoid spam mail). -- Maximum message size is 40000 characters. - -If you want to join a maillist, send a message to - -Make sure that your "From:" address is correct. Then the list server will -send you a help message. +There are several mailing lists for Vim, see http://www.vim.org/maillist.php. MAIN AUTHOR diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index 2db0ae250c..b8f4d4ab03 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -1,4 +1,4 @@ -*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 02 +*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -1135,7 +1135,7 @@ More patches: New version received 2008 Jan 6. No maintenance in two years... - Patch to access screen under Python. (Marko Mahni, 2010 Jul 18) - +- Patch to open dropped files in new tabs. (Michael Trim, 2010 Aug 3) Awaiting updated patches: 9 Mac unicode patch (Da Woon Jung, Eckehard Berns): diff --git a/runtime/syntax/diff.vim b/runtime/syntax/diff.vim index 8ec6880da2..7bb67afd02 100644 --- a/runtime/syntax/diff.vim +++ b/runtime/syntax/diff.vim @@ -1,7 +1,7 @@ " Vim syntax file " Language: Diff (context or unified) " Maintainer: Bram Moolenaar -" Last Change: 2005 Jun 20 +" Last Change: 2010 Aug 03 " Quit when a (custom) syntax file was already loaded if exists("b:current_syntax") @@ -16,6 +16,9 @@ syn match diffIsA "^File .* is a .* while file .* is a .*" syn match diffNoEOL "^No newline at end of file .*" syn match diffCommon "^Common subdirectories: .*" +" German +syn match diffOnly "^Nur in .*" + syn match diffRemoved "^-.*" syn match diffRemoved "^<.*" syn match diffAdded "^+.*" @@ -26,6 +29,7 @@ syn match diffSubname " @@..*"ms=s+3 contained syn match diffLine "^@.*" contains=diffSubname syn match diffLine "^\<\d\+\>.*" syn match diffLine "^\*\*\*\*.*" +syn match diffLine "^---$" "Some versions of diff have lines like "#c#" and "#d#" (where # is a number) syn match diffLine "^\d\+\(,\d\+\)\=[cda]\d\+\>.*" diff --git a/runtime/syntax/tex.vim b/runtime/syntax/tex.vim index e1753d8205..8f34b1a6fe 100644 --- a/runtime/syntax/tex.vim +++ b/runtime/syntax/tex.vim @@ -1,8 +1,8 @@ " Vim syntax file " Language: TeX " Maintainer: Dr. Charles E. Campbell, Jr. -" Last Change: Jul 28, 2010 -" Version: 52 +" Last Change: Aug 03, 2010 +" Version: 54 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax " " Notes: {{{1 @@ -498,34 +498,56 @@ if has("conceal") && &enc == 'utf-8' if s:tex_conceal =~ 'm' syn match texMathSymbol '\\approx\>' contained conceal cchar=≈ syn match texMathSymbol '\\ast\>' contained conceal cchar=∗ + syn match texMathSymbol '\\because\>' contained conceal cchar=∵ + syn match texMathSymbol '\\bigcap\>' contained conceal cchar=∩ + syn match texMathSymbol '\\bigcup\>' contained conceal cchar=∪ + syn match texMathSymbol '\\bigodot\>' contained conceal cchar=⊙ + syn match texMathSymbol '\\bigoplus\>' contained conceal cchar=⊕ + syn match texMathSymbol '\\bigotimes\>' contained conceal cchar=⊗ + syn match texMathSymbol '\\bigsqcup\>' contained conceal cchar=⊔ syn match texMathSymbol '\\bigtriangledown\>' contained conceal cchar=∇ syn match texMathSymbol '\\bigvee\>' contained conceal cchar=⋁ syn match texMathSymbol '\\bigwedge\>' contained conceal cchar=⋀ syn match texMathSymbol '\\blacksquare\>' contained conceal cchar=∎ + syn match texMathSymbol '\\bot\>' contained conceal cchar=⊥ syn match texMathSymbol '\\cap\>' contained conceal cchar=∩ syn match texMathSymbol '\\cdot\>' contained conceal cchar=· + syn match texMathSymbol '\\cdots\>' contained conceal cchar=⋯ syn match texMathSymbol '\\circ\>' contained conceal cchar=∘ syn match texMathSymbol '\\circledcirc\>' contained conceal cchar=⊚ syn match texMathSymbol '\\cong\>' contained conceal cchar=≅ + syn match texMathSymbol '\\coprod\>' contained conceal cchar=∐ syn match texMathSymbol '\\cup\>' contained conceal cchar=∪ syn match texMathSymbol '\\diamond\>' contained conceal cchar=⋄ syn match texMathSymbol '\\div\>' contained conceal cchar=÷ syn match texMathSymbol '\\doteq\>' contained conceal cchar=≐ syn match texMathSymbol '\\dotsb\>' contained conceal cchar=⋯ + syn match texMathSymbol '\\dotsc\>' contained conceal cchar=… + syn match texMathSymbol '\\dots\>' contained conceal cchar=… + syn match texMathSymbol '\\dotsi\>' contained conceal cchar=⋯ + syn match texMathSymbol '\\dotso\>' contained conceal cchar=… syn match texMathSymbol '\\emptyset\>' contained conceal cchar=∅ syn match texMathSymbol '\\equiv\>' contained conceal cchar=≡ + syn match texMathSymbol '\\exists\>' contained conceal cchar=∃ syn match texMathSymbol '\\forall\>' contained conceal cchar=∀ syn match texMathSymbol '\\geq\>' contained conceal cchar=≥ - syn match texMathSymbol '\\geq\>' contained conceal cchar=≥ - syn match texMathSymbol '\\gg\>' contained conceal cchar=⟫ + if &ambw == "double" + syn match texMathSymbol '\\gg\>' contained conceal cchar=≫ + else + syn match texMathSymbol '\\gg\>' contained conceal cchar=⟫ + endif syn match texMathSymbol '\\gtreqless\>' contained conceal cchar=⋛ syn match texMathSymbol '\\gtrless\>' contained conceal cchar=≷ + syn match texMathSymbol '\\iiint\>' contained conceal cchar=∭ + syn match texMathSymbol '\\iint\>' contained conceal cchar=∬ syn match texMathSymbol '\\Im\>' contained conceal cchar=ℑ syn match texMathSymbol '\\in\>' contained conceal cchar=∈ syn match texMathSymbol '\\infty\>' contained conceal cchar=∞ + syn match texMathSymbol '\\int\>' contained conceal cchar=∫ syn match texMathSymbol '\\lceil\>' contained conceal cchar=⌈ - syn match texMathSymbol '\\leftarrow\>' contained conceal cchar=⟶ - syn match texMathSymbol '\\Leftarrow\>' contained conceal cchar=⟹ + syn match texMathSymbol '\\ldots\>' contained conceal cchar=… + syn match texMathSymbol '\\leftarrow\>' contained conceal cchar=⟵ + syn match texMathSymbol '\\Leftarrow\>' contained conceal cchar=⟸ syn match texMathSymbol '\\left(' contained conceal cchar=( syn match texMathSymbol '\\left\[' contained conceal cchar=[ syn match texMathSymbol '\\left\\{' contained conceal cchar={ @@ -533,15 +555,24 @@ if has("conceal") && &enc == 'utf-8' syn match texMathSymbol '\\leq\>' contained conceal cchar=≤ syn match texMathSymbol '\\lesseqgtr\>' contained conceal cchar=⋚ syn match texMathSymbol '\\lfloor\>' contained conceal cchar=⌊ - syn match texMathSymbol '\\ll\>' contained conceal cchar=⟪ + if &ambw == "double" + syn match texMathSymbol '\\ll\>' contained conceal cchar=≪ + else + syn match texMathSymbol '\\ll\>' contained conceal cchar=⟪ + endif syn match texMathSymbol '\\mapsto\>' contained conceal cchar=↦ + syn match texMathSymbol '\\mid\>' contained conceal cchar=∣ syn match texMathSymbol '\\mp\>' contained conceal cchar=∓ + syn match texMathSymbol '\\nabla\>' contained conceal cchar=∇ syn match texMathSymbol '\\neq\>' contained conceal cchar=≠ + syn match texMathSymbol '\\nexists\>' contained conceal cchar=∄ syn match texMathSymbol '\\ngeq\>' contained conceal cchar=≱ syn match texMathSymbol '\\ngtr\>' contained conceal cchar=≯ syn match texMathSymbol '\\nleq\>' contained conceal cchar=≰ syn match texMathSymbol '\\nless\>' contained conceal cchar=≮ + syn match texMathSymbol '\\nmid\>' contained conceal cchar=∤ syn match texMathSymbol '\\notin\>' contained conceal cchar=∉ + syn match texMathSymbol '\\nsim\>' contained conceal cchar=≁ syn match texMathSymbol '\\odot\>' contained conceal cchar=⊙ syn match texMathSymbol '\\oint\>' contained conceal cchar=∮ syn match texMathSymbol '\\oplus\>' contained conceal cchar=⊕ @@ -556,11 +587,13 @@ if has("conceal") && &enc == 'utf-8' syn match texMathSymbol '\\rceil\>' contained conceal cchar=⌉ syn match texMathSymbol '\\Re\>' contained conceal cchar=ℜ syn match texMathSymbol '\\rfloor\>' contained conceal cchar=⌋ - syn match texMathSymbol '\\rightarrow\>' contained conceal cchar=⟵ - syn match texMathSymbol '\\Rightarrow\>' contained conceal cchar=⟸ + syn match texMathSymbol '\\rightarrow\>' contained conceal cchar=⟶ + syn match texMathSymbol '\\Rightarrow\>' contained conceal cchar=⟹ syn match texMathSymbol '\\right)' contained conceal cchar=) syn match texMathSymbol '\\right]' contained conceal cchar=] syn match texMathSymbol '\\right\\}' contained conceal cchar=} + syn match texMathSymbol '\\setminus\>' contained conceal cchar=∖ + syn match texMathSymbol '\\sim\>' contained conceal cchar=∼ syn match texMathSymbol '\\sqcap\>' contained conceal cchar=⊓ syn match texMathSymbol '\\sqcup\>' contained conceal cchar=⊔ syn match texMathSymbol '\\subset\>' contained conceal cchar=⊂ @@ -578,6 +611,8 @@ if has("conceal") && &enc == 'utf-8' syn match texMathSymbol '\\trianglerighteq\>' contained conceal cchar=⊵ syn match texMathSymbol '\\vartriangle\>' contained conceal cchar=∆ syn match texMathSymbol '\\vdots\>' contained conceal cchar=⋮ + syn match texMathSymbol '\\vee\>' contained conceal cchar=∨ + syn match texMathSymbol '\\wedge\>' contained conceal cchar=∧ endif " Greek {{{2 @@ -888,4 +923,4 @@ endif " Current Syntax: {{{1 unlet b:extfname let b:current_syntax = "tex" -" vim: ts=8 fdm=marker +" vim: ts=8 fdm=marker ambw=double From 4778cee7c36b2f97485f3559fc471ce22446f46f Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 12:05:40 +0200 Subject: [PATCH 15/24] Rename quickfix plugin to match the filetype set in the code. --HG-- branch : vim73 rename : runtime/ftplugin/quickfix.vim => runtime/ftplugin/qf.vim --- runtime/ftplugin/{quickfix.vim => qf.vim} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename runtime/ftplugin/{quickfix.vim => qf.vim} (100%) diff --git a/runtime/ftplugin/quickfix.vim b/runtime/ftplugin/qf.vim similarity index 100% rename from runtime/ftplugin/quickfix.vim rename to runtime/ftplugin/qf.vim From 3bc8f1b4b1fbe860562ede55edec42fcdb8bd663 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 12:39:44 +0200 Subject: [PATCH 16/24] Fix crash when no item in 'path' is used for :find completion. --HG-- branch : vim73 --- src/misc1.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/misc1.c b/src/misc1.c index b0f7e91fcc..6f197f22bf 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -9593,6 +9593,8 @@ expand_in_path(gap, pattern, flags) expand_path_option(curdir, &path_ga); vim_free(curdir); + if (path_ga.ga_len == 0) + return 0; path_list = (char_u **)(path_ga.ga_data); # ifdef WIN3264 if ((file_pattern = alloc((unsigned)MAXPATHL)) == NULL) From 06be8496ce7a0ab14710646d71290ce4226ae3e2 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 14:29:54 +0200 Subject: [PATCH 17/24] When undoing a reload, move the cursor to the first changed line. --HG-- branch : vim73 --- src/fileio.c | 9 ++++++++- src/proto/undo.pro | 1 + src/undo.c | 36 ++++++++++++++++++++++++++++++++++++ 3 files changed, 45 insertions(+), 1 deletion(-) diff --git a/src/fileio.c b/src/fileio.c index c7a2b749e5..2881cbc88b 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -2605,6 +2605,11 @@ failed: */ write_no_eol_lnum = read_no_eol_lnum; + /* When reloading a buffer put the cursor at the first line that is + * different. */ + if (flags & READ_KEEP_UNDO) + u_find_first_changed(); + #ifdef FEAT_PERSISTENT_UNDO /* * When opening a new file locate undo info and read it. @@ -7095,7 +7100,7 @@ buf_reload(buf, orig_mode) old_cursor = curwin->w_cursor; old_topline = curwin->w_topline; - if (saved == OK && (p_ur < 0 || curbuf->b_ml.ml_line_count <= p_ur)) + if (p_ur < 0 || curbuf->b_ml.ml_line_count <= p_ur) { /* Save all the text, so that the reload can be undone. * Sync first so that this is a separate undo-able action. */ @@ -7169,8 +7174,10 @@ buf_reload(buf, orig_mode) u_clearall(buf); } else + { /* Mark all undo states as changed. */ u_unchanged(curbuf); + } } } vim_free(ea.cmd); diff --git a/src/proto/undo.pro b/src/proto/undo.pro index 2cb149f42f..f6741c6bc1 100644 --- a/src/proto/undo.pro +++ b/src/proto/undo.pro @@ -17,6 +17,7 @@ void u_sync __ARGS((int force)); void ex_undolist __ARGS((exarg_T *eap)); void ex_undojoin __ARGS((exarg_T *eap)); void u_unchanged __ARGS((buf_T *buf)); +void u_find_first_changed __ARGS((void)); void u_update_save_nr __ARGS((buf_T *buf)); void u_clearall __ARGS((buf_T *buf)); void u_saveline __ARGS((linenr_T lnum)); diff --git a/src/undo.c b/src/undo.c index eb887d8b7f..1b7419725b 100644 --- a/src/undo.c +++ b/src/undo.c @@ -2922,6 +2922,42 @@ u_unchanged(buf) buf->b_did_warn = FALSE; } +/* + * After reloading a buffer which was saved for 'undoreload': Find the first + * line that was changed and set the cursor there. + */ + void +u_find_first_changed() +{ + u_header_T *uhp = curbuf->b_u_newhead; + u_entry_T *uep; + linenr_T lnum; + + if (curbuf->b_u_curhead != NULL || uhp == NULL) + return; /* undid something in an autocmd? */ + + /* Check that the last undo block was for the whole file. */ + uep = uhp->uh_entry; + if (uep->ue_top != 0 || uep->ue_bot != 0) + return; + + for (lnum = 1; lnum < curbuf->b_ml.ml_line_count + && lnum <= uep->ue_size; ++lnum) + if (STRCMP(ml_get_buf(curbuf, lnum, FALSE), + uep->ue_array[lnum - 1]) != 0) + { + clearpos(&(uhp->uh_cursor)); + uhp->uh_cursor.lnum = lnum; + return; + } + if (curbuf->b_ml.ml_line_count != uep->ue_size) + { + /* lines added or deleted at the end, put the cursor there */ + clearpos(&(uhp->uh_cursor)); + uhp->uh_cursor.lnum = lnum; + } +} + /* * Increase the write count, store it in the last undo header, what would be * used for "u". From c08f721564a748791f94c0f5f6adf8e4e33e7a70 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 15:32:46 +0200 Subject: [PATCH 18/24] Fix: when setting crypt key seed was not updated when the swap file wasn't created yet. --HG-- branch : vim73 --- src/memline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/memline.c b/src/memline.c index ce1592637b..16b3b3561b 100644 --- a/src/memline.c +++ b/src/memline.c @@ -478,7 +478,7 @@ ml_set_crypt_key(buf, old_key, old_cm) blocknr_T bnum; int top; - if (mfp == NULL || mfp->mf_fd < 0) + if (mfp == NULL) return; /* no memfile yet, nothing to do */ /* Set the key, method and seed to be used for reading, these must be the From f422abef95e4e4945858deb67c9cc4ea51682efb Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 15:47:08 +0200 Subject: [PATCH 19/24] Set 'wrapscan' when checking the .po files. (Mike Williams) --HG-- branch : vim73 --- src/po/check.vim | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/po/check.vim b/src/po/check.vim index b4d50f187e..5a3a0e3f46 100644 --- a/src/po/check.vim +++ b/src/po/check.vim @@ -30,6 +30,10 @@ func! GetMline() return substitute(idline, '[^%]*\(%[-+ #''.0-9*]*l\=[dsuxXpoc%]\)\=', '\1', 'g') endfunc +" This only works when 'wrapscan' is set. +let s:save_wrapscan = &wrapscan +set wrapscan + " Start at the first "msgid" line. 1 /^msgid @@ -78,4 +82,7 @@ if error == 0 echo "OK" endif +let &wrapscan = s:save_wrapscan +unlet s:save_wrapscan + endif From 0e05a4a18ab638f39134e0f07a5c9b852c59cb55 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 16:10:19 +0200 Subject: [PATCH 20/24] Small changes to the test files. (John Beckett) --HG-- branch : vim73 --- src/testdir/test1.in | 3 ++- src/testdir/test17.ok | 2 +- src/testdir/test17a.in | 2 +- src/testdir/test30.in | 5 +++++ 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/testdir/test1.in b/src/testdir/test1.in index bdcc01d08c..a3b58418a4 100644 --- a/src/testdir/test1.in +++ b/src/testdir/test1.in @@ -11,7 +11,8 @@ If Vim was not compiled with the +windows feature, the tiny.vim script will be set like small.vim above. tiny.vim is sourced by tests that require the +windows feature or other features that are missing in the tiny version. -If Vim was not compiled with the +multi_byte feature, the mbyte.vim script will be set like small.vim above. mbyte.vim is sourced by tests that require the +If Vim was not compiled with the +multi_byte feature, the mbyte.vim script will +be set like small.vim above. mbyte.vim is sourced by tests that require the +multi_byte feature. Similar logic is applied to the +mzscheme feature, using mzscheme.vim. diff --git a/src/testdir/test17.ok b/src/testdir/test17.ok index 58c3504adc..7e89364797 100644 --- a/src/testdir/test17.ok +++ b/src/testdir/test17.ok @@ -1,3 +1,3 @@ This file is just to test "gf" in test 17. -The contents is not importent. +The contents is not important. Just testing! diff --git a/src/testdir/test17a.in b/src/testdir/test17a.in index 58c3504adc..7e89364797 100644 --- a/src/testdir/test17a.in +++ b/src/testdir/test17a.in @@ -1,3 +1,3 @@ This file is just to test "gf" in test 17. -The contents is not importent. +The contents is not important. Just testing! diff --git a/src/testdir/test30.in b/src/testdir/test30.in index c2ee2f06df..4a8778d2de 100644 --- a/src/testdir/test30.in +++ b/src/testdir/test30.in @@ -29,6 +29,11 @@ STARTTEST : !copy XXUnix,XXMac XXUxMac. : !copy XXDos,XXMac XXDosMac. : !copy XXUnix,XXDos,XXMac XXUxDsMc. +:elseif has("win32") +: !copy /b XXUnix+XXDos XXUxDs +: !copy /b XXUnix+XXMac XXUxMac +: !copy /b XXDos+XXMac XXDosMac +: !copy /b XXUnix+XXDos+XXMac XXUxDsMc :else : !cat XXUnix XXDos >XXUxDs : !cat XXUnix XXMac >XXUxMac From 6aca8a785d649618a76fbabc2e1525296dc50545 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 16:11:50 +0200 Subject: [PATCH 21/24] Add translations in diff syntax. (Jakson A. Aquino) --HG-- branch : vim73 --- runtime/syntax/diff.vim | 271 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 269 insertions(+), 2 deletions(-) diff --git a/runtime/syntax/diff.vim b/runtime/syntax/diff.vim index 7bb67afd02..62a70bfc02 100644 --- a/runtime/syntax/diff.vim +++ b/runtime/syntax/diff.vim @@ -7,6 +7,7 @@ if exists("b:current_syntax") finish endif +scriptencoding utf-8 syn match diffOnly "^Only in .*" syn match diffIdentical "^Files .* and .* are identical$" @@ -16,8 +17,274 @@ syn match diffIsA "^File .* is a .* while file .* is a .*" syn match diffNoEOL "^No newline at end of file .*" syn match diffCommon "^Common subdirectories: .*" -" German -syn match diffOnly "^Nur in .*" +" ca +syn match diffOnly "^Només a .*: .*$" +syn match diffIdentical "^Els fitxers .* i .* són idèntics$" +syn match diffDiffer "^Els fitxers .* i .* difereixen$" +syn match diffBDiffer "^Els fitxers .* i .* difereixen$" +syn match diffIsA "^El fitxer .* és un .* mentre que el fitxer .* és un .*$" +syn match diffNoEOL "^No hi ha cap caràcter de salt de línia al final del fitxer" +syn match diffCommon "^Subdirectoris comuns: .* i .*$" + +" cs +syn match diffOnly "^Pouze v .*: .*$" +syn match diffIdentical "^Soubory .* a .* jsou identické$" +syn match diffDiffer "^Soubory .* a .* jsou různé$" +syn match diffBDiffer "^Soubory .* a .* jsou různé$" +syn match diffIsA "^Soubor .* je .* pokud soubor .* je .*$" +syn match diffNoEOL "^Chybí znak konce řádku na konci souboru" +syn match diffCommon "^Společné podadresáře: .* a .*$" + +" da +syn match diffOnly "^Kun i .*: .*$" +syn match diffIdentical "^Filerne .* og .* er identiske$" +syn match diffDiffer "^Filerne .* og .* er forskellige$" +syn match diffBDiffer "^Binære filer .* og .* er forskellige$" +syn match diffIsA "^Filen .* er en .* mens filen .* er en .*$" +syn match diffNoEOL "^Intet linjeskift ved filafslutning" +syn match diffCommon "^Identiske underkataloger: .* og .*$" + +" de +syn match diffOnly "^Nur in .*: .*.$" +syn match diffIdentical "^Dateien .* und .* sind identisch.$" +syn match diffDiffer "^Dateien .* und .* sind verschieden.$" +syn match diffBDiffer "^Binärdateien .* and .* sind verschieden.$" +syn match diffIsA "^Datei .* ist ein .* während Datei .* ein .* ist.$" +syn match diffNoEOL "^Kein Zeilenumbruch am Dateiende." +syn match diffCommon "^Gemeinsame Unterverzeichnisse: .* und .*.$" + +" el +syn match diffOnly "^Μόνο στο .*: .*$" +syn match diffIdentical "^Τα αρχεία .* καί .* είναι πανομοιότυπα$" +syn match diffDiffer "^Τα αρχεία .* και .* διαφέρουν$" +syn match diffBDiffer "^Τα αρχεία .* και .* διαφέρουν$" +syn match diffIsA "^Το αρχείο .* είναι .* ενώ το αρχείο .* είναι .*$" +syn match diffNoEOL "^Δεν υπάρχει χαρακτήρας νέας γραμμής στο τέλος του αρχείου" +syn match diffCommon "^Οι υποκατάλογοι .* και .* είναι ταυτόσημοι$" + +" eo +syn match diffOnly "^Nur en .*: .*$" +syn match diffIdentical "^Dosieroj .* kaj .* estas samaj$" +syn match diffDiffer "^Dosieroj .* kaj .* estas malsamaj$" +syn match diffBDiffer "^Dosieroj .* kaj .* estas malsamaj$" +syn match diffIsA "^Dosiero .* estas .*, dum dosiero .* estas .*$" +syn match diffNoEOL "^Mankas linifino ĉe fino de dosiero" +syn match diffCommon "^Komunaj subdosierujoj: .* kaj .*$" + +" es +syn match diffOnly "^Sólo en .*: .*$" +syn match diffIdentical "^Los ficheros .* y .* son idénticos$" +syn match diffDiffer "^Los ficheros .* y .* son distintos$" +syn match diffBDiffer "^Los ficheros binarios .* y .* son distintos$" +syn match diffIsA "^El fichero .* es un .* mientras que el .* es un .*$" +syn match diffNoEOL "^No hay ningún carácter de nueva línea al final del fichero" +syn match diffCommon "^Subdirectorios comunes: .* y .*$" + +" fi +syn match diffOnly "^Vain hakemistossa .*: .*$" +syn match diffIdentical "^Tiedostot .* ja .* ovat identtiset$" +syn match diffDiffer "^Tiedostot .* ja .* eroavat$" +syn match diffBDiffer "^Binääritiedostot .* ja .* eroavat$" +syn match diffIsA "^Tiedosto .* on .*, kun taas tiedosto .* on .*$" +syn match diffNoEOL "^Ei rivinvaihtoa tiedoston lopussa" +syn match diffCommon "^Yhteiset alihakemistot: .* ja .*$" + +" fr +syn match diffOnly "^Seulement dans .*: .*$" +syn match diffIdentical "^Les fichiers .* et .* sont identiques.$" +syn match diffDiffer "^Les fichiers .* et .* sont différents.$" +syn match diffBDiffer "^Les fichiers binaires .* et .* sont différents.$" +syn match diffIsA "^Le fichier .* est un .* alors que le fichier .* est un .*$" +syn match diffNoEOL "^Pas de fin de ligne à la fin du fichier." +syn match diffCommon "^Les sous-répertoires .* et .* sont identiques.$" + +" ga +syn match diffOnly "^I .* amháin: .*$" +syn match diffIdentical "^Is comhionann iad na comhaid .* agus .*$" +syn match diffDiffer "^Tá difríocht idir na comhaid .* agus .*$" +syn match diffBDiffer "^Tá difríocht idir na comhaid .* agus .*$" +syn match diffIsA "^Tá comhad .* ina .* ach tá comhad .* ina .*$" +syn match diffNoEOL "^Gan líne nua ag an chomhadchríoch" +syn match diffCommon "^Fochomhadlanna i gcoitianta: .* agus .*$" + +" gl +syn match diffOnly "^Só en .*: .*$" +syn match diffIdentical "^Os ficheiros .* e .* son idénticos$" +syn match diffDiffer "^Os ficheiros .* e .* son diferentes$" +syn match diffBDiffer "^Os ficheiros binarios .* e .* son diferentes$" +syn match diffIsA "^O ficheiro .* é un .* mentres que o ficheiro .* é un .*$" +syn match diffNoEOL "^Non hai un salto de liña na fin da liña" +syn match diffCommon "^Subdirectorios comúns: .* e .*$" + +" he +syn match diffOnly "^.*-ב קר אצמנ .*$" +syn match diffIdentical "^םיהז םניה .*-ו .* םיצבקה$" +syn match diffDiffer "^הזמ הז םינוש `.*'-ו `.*' םיצבקה$" +syn match diffBDiffer "^הזמ הז םינוש `.*'-ו `.*' םיירניב םיצבק$" +syn match diffIsA "^.* .*-ל .* .* תוושהל ןתינ אל$" +syn match diffNoEOL "^ץבוקה ףוסב השדח-הרוש ות רסח" +syn match diffCommon "^.*-ו .* :תוהז תויקית-תת$" + +" hu +syn match diffOnly "^Csak .* -ben: .*$" +syn match diffIdentical "^.* és .* fájlok azonosak$" +syn match diffDiffer "^A(z) .* és a(z) .* fájlok különböznek$" +syn match diffBDiffer "^A(z) .* és a(z) .* fájlok különböznek$" +syn match diffIsA "^A(z) .* fájl egy .*, viszont a(z) .* fájl egy .*$" +syn match diffNoEOL "^Nincs újsor a fájl végén" +syn match diffCommon "^Közös alkönyvtárak: .* és .*$" + +" id +syn match diffOnly "^Hanya dalam .*: .*$" +syn match diffIdentical "^File .* dan .* identik$" +syn match diffDiffer "^Berkas .* dan .* berbeda$" +syn match diffBDiffer "^File biner .* dan .* berbeda$" +syn match diffIsA "^File .* adalah .* sementara file .* adalah .*$" +syn match diffNoEOL "^Tidak ada baris-baru di akhir dari berkas" +syn match diffCommon "^Subdirektori sama: .* dan .*$" + +" it +syn match diffOnly "^Solo in .*: .*$" +syn match diffIdentical "^I file .* e .* sono identici$" +syn match diffDiffer "^I file .* e .* sono diversi$" +syn match diffBDiffer "^I file .* e .* sono diversi$" +syn match diffIsA "^File .* è un .* mentre file .* è un .*$" +syn match diffNoEOL "^Manca newline alla fine del file" +syn match diffCommon "^Sottodirectory in comune: .* e .*$" + +" ja +syn match diffOnly "^.*だけに発見: .*$" +syn match diffIdentical "^ファイル.*と.*は同一$" +syn match diffDiffer "^ファイル.*と.*は違います$" +syn match diffBDiffer "^バイナリー・ファイル.*と.*は違います$" +syn match diffIsA "^ファイル.*は.*、ファイル.*は.*$" +syn match diffNoEOL "^ファイル末尾に改行がありません" +syn match diffCommon "^共通の下位ディレクトリー: .*と.*$" + +" lv +syn match diffOnly "^Tikai iekš .*: .*$" +syn match diffIdentical "^Fails .* un .* ir identiski$" +syn match diffDiffer "^Faili .* un .* atšķiras$" +syn match diffBDiffer "^Faili .* un .* atšķiras$" +syn match diffIsA "^Fails .* ir .* kamēr fails .* ir .*$" +syn match diffNoEOL "^Nav jaunu rindu faila beigās" +syn match diffCommon "^Kopējās apakšdirektorijas: .* un .*$" + +" ms +syn match diffIdentical "^Fail .* dan .* adalah serupa$" +syn match diffDiffer "^Fail .* dan .* berbeza$" +syn match diffBDiffer "^Fail .* dan .* berbeza$" +syn match diffIsA "^Fail .* adalah .* manakala fail .* adalah .*$" +syn match diffNoEOL "^Tiada baris baru pada penghujung fail" +syn match diffCommon "^Subdirektori umum: .* dan .*$" + +" nl +syn match diffOnly "^Alleen in .*: .*$" +syn match diffIdentical "^Bestanden .* en .* zijn identiek$" +syn match diffDiffer "^Bestanden .* en .* zijn verschillend$" +syn match diffBDiffer "^Bestanden .* en .* zijn verschillend$" +syn match diffIsA "^Bestand .* is een .* terwijl bestand .* een .* is$" +syn match diffNoEOL "^Geen regeleindeteken (LF) aan einde van bestand" +syn match diffCommon "^Gemeenschappelijke submappen: .* en .*$" + +" pl +syn match diffOnly "^Tylko w .*: .*$" +syn match diffIdentical "^Pliki .* i .* są identyczne$" +syn match diffDiffer "^Pliki .* i .* różnią się$" +syn match diffBDiffer "^Pliki .* i .* różnią się$" +syn match diffIsA "^Plik .* jest .*, podczas gdy plik .* jest .*$" +syn match diffNoEOL "^Brak znaku nowej linii na końcu pliku" +syn match diffCommon "^Wspólne podkatalogi: .* i .*$" + +" pt_BR +syn match diffOnly "^Somente em .*: .*$" +syn match diffOnly "^Apenas em .*: .*$" +syn match diffIdentical "^Os aquivos .* e .* são idênticos$" +syn match diffDiffer "^Os arquivos .* e .* são diferentes$" +syn match diffBDiffer "^Os arquivos binários .* e .* são diferentes$" +syn match diffIsA "^O arquivo .* é .* enquanto o arquivo .* é .*$" +syn match diffNoEOL "^Falta o caracter nova linha no final do arquivo" +syn match diffCommon "^Subdiretórios idênticos: .* e .*$" + +" ro +syn match diffOnly "^Doar în .*: .*$" +syn match diffIdentical "^Fişierele .* şi .* sunt identice$" +syn match diffDiffer "^Fişierele .* şi .* diferă$" +syn match diffBDiffer "^Fişierele binare .* şi .* diferă$" +syn match diffIsA "^Fişierul .* este un .* pe când fişierul .* este un .*.$" +syn match diffNoEOL "^Nici un element de linie nouă la sfârşitul fişierului" +syn match diffCommon "^Subdirectoare comune: .* şi .*.$" + +" ru +syn match diffOnly "^Только в .*: .*$" +syn match diffIdentical "^Файлы .* и .* идентичны$" +syn match diffDiffer "^Файлы .* и .* различаются$" +syn match diffBDiffer "^Файлы .* и .* различаются$" +syn match diffIsA "^Файл .* это .*, тогда как файл .* -- .*$" +syn match diffNoEOL "^В конце файла нет новой строки" +syn match diffCommon "^Общие подкаталоги: .* и .*$" + +" sr +syn match diffOnly "^Само у .*: .*$" +syn match diffIdentical "^Датотеке „.*“ и „.*“ се подударају$" +syn match diffDiffer "^Датотеке .* и .* различите$" +syn match diffBDiffer "^Бинарне датотеке .* и .* различите$" +syn match diffIsA "^Датотека „.*“ је „.*“ док је датотека „.*“ „.*“$" +syn match diffNoEOL "^Без новог реда на крају датотеке" +syn match diffCommon "^Заједнички поддиректоријуми: .* и .*$" + +" sv +syn match diffOnly "^Endast i .*: .*$" +syn match diffIdentical "^Filerna .* och .* är lika$" +syn match diffDiffer "^Filerna .* och .* skiljer$" +syn match diffBDiffer "^Filerna .* och .* skiljer$" +syn match diffIsA "^Fil .* är en .* medan fil .* är en .*$" +syn match diffNoEOL "^Ingen nyrad vid filslut" +syn match diffCommon "^Lika underkataloger: .* och .*$" + +" tr +syn match diffOnly "^Yalnızca .*'da: .*$" +syn match diffIdentical "^.* ve .* dosyaları birbirinin aynı$" +syn match diffDiffer "^.* ve .* dosyaları birbirinden farklı$" +syn match diffBDiffer "^.* ve .* dosyaları birbirinden farklı$" +syn match diffIsA "^.* dosyası, bir .*, halbuki .* dosyası bir .*$" +syn match diffNoEOL "^Dosya sonunda yenisatır yok." +syn match diffCommon "^Ortak alt dizinler: .* ve .*$" + +" uk +syn match diffOnly "^Лише у .*: .*$" +syn match diffIdentical "^Файли .* та .* ідентичні$" +syn match diffDiffer "^Файли .* та .* відрізняються$" +syn match diffBDiffer "^Файли .* та .* відрізняються$" +syn match diffIsA "^Файл .* це .*, тоді як файл .* -- .*$" +syn match diffNoEOL "^Наприкінці файлу немає нового рядка" +syn match diffCommon "^Спільні підкаталоги: .* та .*$" + +" vi +syn match diffOnly "^Chỉ trong .*: .*$" +syn match diffIdentical "^Hai tập tin .* và .* là bằng nhau.$" +syn match diffDiffer "^Hai tập tin .* và .* là khác nhau.$" +syn match diffBDiffer "^Hai tập tin .* và .* là khác nhau.$" +syn match diffIsA "^Tập tin .* là một .* còn tập tin .* là một .*.$" +syn match diffNoEOL "^Không có ký tự dòng mới tại kêt thức tập tin." +syn match diffCommon "^Thư mục con chung: .* và .*$" + +" zh_CN +syn match diffOnly "^只在 .* 存在:.*$" +syn match diffIdentical "^檔案 .* 和 .* 相同$" +syn match diffDiffer "^文件 .* 和 .* 不同$" +syn match diffBDiffer "^文件 .* 和 .* 不同$" +syn match diffIsA "^文件 .* 是.*而文件 .* 是.*$" +syn match diffNoEOL "^文件尾没有 newline 字符" +syn match diffCommon "^.* 和 .* 有共同的子目录$" + +" zh_TW +syn match diffDiffer "^檔案 .* 與 .* 不同$" +syn match diffBDiffer "^二元碼檔 .* 與 .* 不同$" +syn match diffIsA "^檔案 .* 是.*而檔案 .* 是.*$" +syn match diffNoEOL "^檔案末沒有 newline 字元" +syn match diffCommon "^.* 和 .* 有共同的副目錄$" + syn match diffRemoved "^-.*" syn match diffRemoved "^<.*" From bd3d778efd4039af642f44280006c4939ea6f052 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 17:07:20 +0200 Subject: [PATCH 22/24] Make :find completion consistent between Unix and MS-Windows. Add a test. (Nazri Ramliy) --HG-- branch : vim73 --- src/misc1.c | 55 +++++++++----------------------------- src/misc2.c | 30 +++++++++++++++++++++ src/proto/misc2.pro | 1 + src/testdir/Make_amiga.mak | 3 ++- src/testdir/Make_dos.mak | 2 +- src/testdir/Make_ming.mak | 2 +- src/testdir/Make_os2.mak | 2 +- src/testdir/Make_vms.mms | 4 +-- src/testdir/Makefile | 2 +- src/testdir/test73.in | 21 +++++++++++++++ src/testdir/test73.ok | 3 +++ 11 files changed, 75 insertions(+), 50 deletions(-) create mode 100644 src/testdir/test73.in create mode 100644 src/testdir/test73.ok diff --git a/src/misc1.c b/src/misc1.c index 6f197f22bf..c8fb8eb3fa 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -9321,7 +9321,7 @@ expand_path_option(curdir, gap) ga_init2(gap, (int)sizeof(char_u *), 1); - if ((buf = alloc((int)(MAXPATHL))) == NULL) + if ((buf = alloc((int)MAXPATHL)) == NULL) return; while (*path_option != NUL) @@ -9564,8 +9564,8 @@ theend: } /* - * Calls globpath() or mch_expandpath() with 'path' values for the given - * pattern and stores the result in gap. + * Calls globpath() with 'path' values for the given pattern and stores the + * result in "gap". * Returns the total number of matches. */ static int @@ -9574,18 +9574,12 @@ expand_in_path(gap, pattern, flags) char_u *pattern; int flags; /* EW_* flags */ { - char_u **path_list; char_u *curdir; garray_T path_ga; - int i; -# ifdef WIN3264 - char_u *file_pattern; -# else char_u *files = NULL; char_u *s; /* start */ char_u *e; /* end */ char_u *paths = NULL; -# endif if ((curdir = alloc((unsigned)MAXPATHL)) == NULL) return 0; @@ -9595,42 +9589,14 @@ expand_in_path(gap, pattern, flags) vim_free(curdir); if (path_ga.ga_len == 0) return 0; - path_list = (char_u **)(path_ga.ga_data); -# ifdef WIN3264 - if ((file_pattern = alloc((unsigned)MAXPATHL)) == NULL) + + paths = ga_concat_strings(&path_ga); + ga_clear_strings(&path_ga); + if (paths == NULL) return 0; - for (i = 0; i < path_ga.ga_len; i++) - { - if (STRLEN(path_list[i]) + STRLEN(pattern) + 2 > MAXPATHL) - continue; - STRCPY(file_pattern, path_list[i]); - STRCAT(file_pattern, "/"); - STRCAT(file_pattern, pattern); - mch_expandpath(gap, file_pattern, EW_DIR|EW_ADDSLASH|EW_FILE); - } - vim_free(file_pattern); -# else - for (i = 0; i < path_ga.ga_len; i++) - { - if (paths == NULL) - { - if ((paths = alloc((unsigned)(STRLEN(path_list[i]) + 1))) == NULL) - return 0; - STRCPY(paths, path_list[i]); - } - else - { - if ((paths = realloc(paths, (int)(STRLEN(paths) - + STRLEN(path_list[i]) + 2))) == NULL) - return 0; - STRCAT(paths, ","); - STRCAT(paths, path_list[i]); - } - } files = globpath(paths, pattern, 0); vim_free(paths); - if (files == NULL) return 0; @@ -9654,9 +9620,7 @@ expand_in_path(gap, pattern, flags) s = e; } } - vim_free(files); -# endif return gap->ga_len; } @@ -9797,7 +9761,12 @@ gen_expand_wildcards(num_pat, pat, num_file, file, flags) { #if defined(FEAT_SEARCHPATH) if (*p != '.' && !vim_ispathsep(*p) && (flags & EW_PATH)) + { + /* recursiveness is OK here */ + recursive = FALSE; add_pat = expand_in_path(&ga, p, flags); + recursive = TRUE; + } else #endif add_pat = mch_expandpath(&ga, p, flags); diff --git a/src/misc2.c b/src/misc2.c index 96813a4841..3c25a1f087 100644 --- a/src/misc2.c +++ b/src/misc2.c @@ -2067,6 +2067,36 @@ ga_grow(gap, n) return OK; } +/* + * For a growing array that contains a list of strings: concatenate all the + * strings with a separating comma. + * Returns NULL when out of memory. + */ + char_u * +ga_concat_strings(gap) + garray_T *gap; +{ + int i; + int len = 0; + char_u *s; + + for (i = 0; i < gap->ga_len; ++i) + len += (int)STRLEN(((char_u **)(gap->ga_data))[i]) + 1; + + s = alloc(len + 1); + if (s != NULL) + { + *s = NUL; + for (i = 0; i < gap->ga_len; ++i) + { + if (*s != NUL) + STRCAT(s, ","); + STRCAT(s, ((char_u **)(gap->ga_data))[i]); + } + } + return s; +} + /* * Concatenate a string to a growarray which contains characters. * Note: Does NOT copy the NUL at the end! diff --git a/src/proto/misc2.pro b/src/proto/misc2.pro index 3fa0c9b3b8..671bd9fdf9 100644 --- a/src/proto/misc2.pro +++ b/src/proto/misc2.pro @@ -53,6 +53,7 @@ void ga_clear_strings __ARGS((garray_T *gap)); void ga_init __ARGS((garray_T *gap)); void ga_init2 __ARGS((garray_T *gap, int itemsize, int growsize)); int ga_grow __ARGS((garray_T *gap, int n)); +char_u *ga_concat_strings __ARGS((garray_T *gap)); void ga_concat __ARGS((garray_T *gap, char_u *s)); void ga_append __ARGS((garray_T *gap, int c)); int name_to_mod_mask __ARGS((int c)); diff --git a/src/testdir/Make_amiga.mak b/src/testdir/Make_amiga.mak index 59c616de39..a2644cd950 100644 --- a/src/testdir/Make_amiga.mak +++ b/src/testdir/Make_amiga.mak @@ -27,7 +27,7 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ test56.out test57.out test58.out test59.out test60.out \ test61.out test62.out test63.out test64.out test65.out \ test66.out test67.out test68.out test69.out test70.out \ - test71.out test72.out + test71.out test72.out test73.out .SUFFIXES: .in .out @@ -119,3 +119,4 @@ test69.out: test69.in test70.out: test70.in test71.out: test71.in test72.out: test72.in +test73.out: test73.in diff --git a/src/testdir/Make_dos.mak b/src/testdir/Make_dos.mak index 063fd85646..94b44c2423 100644 --- a/src/testdir/Make_dos.mak +++ b/src/testdir/Make_dos.mak @@ -27,7 +27,7 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \ test30.out test31.out test32.out test33.out test34.out \ test37.out test38.out test39.out test40.out test41.out \ test42.out test52.out test65.out test66.out test67.out \ - test68.out test69.out test71.out test72.out + test68.out test69.out test71.out test72.out test73.out SCRIPTS32 = test50.out test70.out diff --git a/src/testdir/Make_ming.mak b/src/testdir/Make_ming.mak index 9029d98c95..2d40ab5c7c 100644 --- a/src/testdir/Make_ming.mak +++ b/src/testdir/Make_ming.mak @@ -47,7 +47,7 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \ test30.out test31.out test32.out test33.out test34.out \ test37.out test38.out test39.out test40.out test41.out \ test42.out test52.out test65.out test66.out test67.out \ - test68.out test69.out test71.out test72.out + test68.out test69.out test71.out test72.out test72.out SCRIPTS32 = test50.out test70.out diff --git a/src/testdir/Make_os2.mak b/src/testdir/Make_os2.mak index f5262e21ea..46e9b6c164 100644 --- a/src/testdir/Make_os2.mak +++ b/src/testdir/Make_os2.mak @@ -27,7 +27,7 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \ test56.out test57.out test58.out test59.out test60.out \ test61.out test62.out test63.out test64.out test65.out \ test66.out test67.out test68.out test69.out test70.out \ - test71.out test72.out + test71.out test72.out test73.out .SUFFIXES: .in .out diff --git a/src/testdir/Make_vms.mms b/src/testdir/Make_vms.mms index 6ea02de1ee..4e2c096e00 100644 --- a/src/testdir/Make_vms.mms +++ b/src/testdir/Make_vms.mms @@ -4,7 +4,7 @@ # Authors: Zoltan Arpadffy, # Sandor Kopanyi, # -# Last change: 2010 Jul 30 +# Last change: 2010 Aug 04 # # This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64. # Edit the lines in the Configuration section below to select. @@ -94,7 +94,7 @@ GUI_OPTION = -g .ENDIF .IFDEF WANT_UNIX -SCRIPT_UNIX = test10.out test12.out test25.out test27.out test49.out +SCRIPT_UNIX = test10.out test12.out test25.out test27.out test49.out test73.out .ENDIF .IFDEF WANT_WIN diff --git a/src/testdir/Makefile b/src/testdir/Makefile index f970b26b82..4951dc2fa1 100644 --- a/src/testdir/Makefile +++ b/src/testdir/Makefile @@ -23,7 +23,7 @@ SCRIPTS = test1.out test2.out test3.out test4.out test5.out test6.out \ test54.out test55.out test56.out test57.out test58.out \ test59.out test60.out test61.out test62.out test63.out \ test64.out test65.out test66.out test67.out test68.out \ - test69.out test70.out test71.out test72.out + test69.out test70.out test71.out test72.out test73.out SCRIPTS_GUI = test16.out diff --git a/src/testdir/test73.in b/src/testdir/test73.in new file mode 100644 index 0000000000..822dde3f5a --- /dev/null +++ b/src/testdir/test73.in @@ -0,0 +1,21 @@ +Tests for find completion. + +STARTTEST +:!mkdir -p Xfind/in/path +:e Xfind/file.txt +aHoly Grail:w +:e Xfind/in/file.txt +aJimmy Hoffa:w +:e Xfind/in/path/file.txt +aE.T.:w +:set path=Xfind/** +:set nocp +:find file +:w! test.out +:find file +:w >>test.out +:find file +:w >>test.out +:qa! +ENDTEST + diff --git a/src/testdir/test73.ok b/src/testdir/test73.ok new file mode 100644 index 0000000000..bf1d43359c --- /dev/null +++ b/src/testdir/test73.ok @@ -0,0 +1,3 @@ +Holy Grail +Jimmy Hoffa +E.T. From 97583c42f0caacb829ede6dd52d720929ad98336 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 17:49:30 +0200 Subject: [PATCH 23/24] Preparations for 7.3d release. --HG-- branch : vim73 --- Makefile | 9 ++--- runtime/doc/eval.txt | 6 ++- runtime/doc/todo.txt | 11 ++--- runtime/doc/version7.txt | 8 +++- runtime/makemenu.vim | 3 +- runtime/synmenu.vim | 87 ++++++++++++++++++++-------------------- src/version.h | 4 +- 7 files changed, 66 insertions(+), 62 deletions(-) diff --git a/Makefile b/Makefile index d1308a5c67..5137994865 100644 --- a/Makefile +++ b/Makefile @@ -136,11 +136,10 @@ DOSBIN_S = dosbin_s # - Rename the executables to "vimd32.exe", "xxdd32.exe", "installd32.exe" and # "uninstald32.exe". # Win32 console version: -# - Set environment for Visual C++ 2010, e.g.: -# "E:\Microsoft Visual Studio 10.0\VC\bin\vcvars32.bat". Or, for Visual -# C++ 2008 Express Edition: "msvc2008.bat". Or, when using the Visual C++ -# Toolkit 2003: "msvcsetup.bat" (adjust the paths when necessary). For -# Windows 98/ME the 2003 version is required. +# - Set environment for Visual C++ 2008, e.g.: +# "E:\Microsoft Visual Studio 9.0\VC\bin\vcvars32.bat". Or, when using the +# Visual C++ Toolkit 2003: "msvcsetup.bat" (adjust the paths when necessary). +# For Windows 98/ME the 2003 version is required. # - "nmake -f Make_mvc.mak" # - "rm testdir/*.out", "nmake -f Make_mvc.mak test" and check the output. # - Rename the executables to "vimw32.exe", "xxdw32.exe". diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index bbb8a173f1..8048a54d8c 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt* For Vim version 7.3d. Last change: 2010 Jul 28 +*eval.txt* For Vim version 7.3d. Last change: 2010 Aug 04 VIM REFERENCE MANUAL by Bram Moolenaar @@ -535,6 +535,10 @@ remaining that refers to it. It is not necessary to use the "dict" attribute for a numbered function. +If you get an error for a numbered function, you can find out what it is with +a trick. Assuming the function is 42, the command is: > + :function {42} + Functions for Dictionaries ~ *E715* diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index b8f4d4ab03..1880014a95 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -1,4 +1,4 @@ -*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 03 +*todo.txt* For Vim version 7.3d. Last change: 2010 Aug 04 VIM REFERENCE MANUAL by Bram Moolenaar @@ -30,13 +30,6 @@ be worked on, but only if you sponsor Vim development. See |sponsor|. *known-bugs* -------------------- Known bugs and current work ----------------------- -Using uninitialized memory when crypting an empty file. (Dominique Pelle, 2010 -Aug 2) - -Go back to MSVC 2008, so that Windows 2000 is supported? - -For 'undoreload': put the cursor on the first line that is different. - Before release 7.3: - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) @@ -44,6 +37,8 @@ test72 causes a beep for using "u" when it doesn't work. Cursor positioning wrong with 0x200e character. (John Becket, 2010 May 6) +Patch to make more characters work in dialogs. (Yankwei Jia, 2010 Aug 4) + Should readfile() ignore BOM when not in binary mode? Bug: searching for tags file uses 'suffixesadd', should not happen. (Dominique diff --git a/runtime/doc/version7.txt b/runtime/doc/version7.txt index 307868469d..8fad6ff594 100644 --- a/runtime/doc/version7.txt +++ b/runtime/doc/version7.txt @@ -1,4 +1,4 @@ -*version7.txt* For Vim version 7.3d. Last change: 2010 Aug 01 +*version7.txt* For Vim version 7.3d. Last change: 2010 Aug 04 VIM REFERENCE MANUAL by Bram Moolenaar @@ -7301,7 +7301,7 @@ In Visual mode with 'showcmd' display the number of bytes and characters. Allow synIDattr() getting GUI attributes when build without GUI. (Matt Wozniski) -Support completion for ":find". (Nazri Ramliy) +Support completion for ":find". Add test 73. (Nazri Ramliy) Command line completion for :ownsyntax and :setfiletype. (Dominique Pelle) @@ -10094,5 +10094,9 @@ memory access error. Fix: terminal title not properly restored when there are multi-byte characters. (partly by James Vega) +Set 'wrapscan' when checking the .po files. (Mike Williams) + +Win32: Put quotes around the gvim.exe path for the "Open with" menu entry. + vim:tw=78:ts=8:ft=help:norl: diff --git a/runtime/makemenu.vim b/runtime/makemenu.vim index 5b6f6d379f..c4d8bc204b 100644 --- a/runtime/makemenu.vim +++ b/runtime/makemenu.vim @@ -1,6 +1,6 @@ " Script to define the syntax menu in synmenu.vim " Maintainer: Bram Moolenaar -" Last Change: 2010 Jul 26 +" Last Change: 2010 Aug 04 " This is used by "make menu" in the src directory. edit :p:h/synmenu.vim @@ -151,6 +151,7 @@ SynMenu C.Cyn++:cynpp SynMenu C.Cynlib:cynlib SynMenu DE.D:d +SynMenu DE.Datascript:datascript SynMenu DE.Debian.Debian\ ChangeLog:debchangelog SynMenu DE.Debian.Debian\ Control:debcontrol SynMenu DE.Debian.Debian\ Sources\.list:debsources diff --git a/runtime/synmenu.vim b/runtime/synmenu.vim index 6c42ba4058..92678d149c 100644 --- a/runtime/synmenu.vim +++ b/runtime/synmenu.vim @@ -135,49 +135,50 @@ an 50.20.470 &Syntax.C.CVS.cvsrc :cal SetSyn("cvsrc") an 50.20.480 &Syntax.C.Cyn++ :cal SetSyn("cynpp") an 50.20.490 &Syntax.C.Cynlib :cal SetSyn("cynlib") an 50.30.100 &Syntax.DE.D :cal SetSyn("d") -an 50.30.110 &Syntax.DE.Debian.Debian\ ChangeLog :cal SetSyn("debchangelog") -an 50.30.120 &Syntax.DE.Debian.Debian\ Control :cal SetSyn("debcontrol") -an 50.30.130 &Syntax.DE.Debian.Debian\ Sources\.list :cal SetSyn("debsources") -an 50.30.140 &Syntax.DE.Denyhosts :cal SetSyn("denyhosts") -an 50.30.150 &Syntax.DE.Desktop :cal SetSyn("desktop") -an 50.30.160 &Syntax.DE.Dict\ config :cal SetSyn("dictconf") -an 50.30.170 &Syntax.DE.Dictd\ config :cal SetSyn("dictdconf") -an 50.30.180 &Syntax.DE.Diff :cal SetSyn("diff") -an 50.30.190 &Syntax.DE.Digital\ Command\ Lang :cal SetSyn("dcl") -an 50.30.200 &Syntax.DE.Dircolors :cal SetSyn("dircolors") -an 50.30.210 &Syntax.DE.Django\ template :cal SetSyn("django") -an 50.30.220 &Syntax.DE.DNS/BIND\ zone :cal SetSyn("bindzone") -an 50.30.230 &Syntax.DE.DocBook.auto-detect :cal SetSyn("docbk") -an 50.30.240 &Syntax.DE.DocBook.SGML :cal SetSyn("docbksgml") -an 50.30.250 &Syntax.DE.DocBook.XML :cal SetSyn("docbkxml") -an 50.30.260 &Syntax.DE.Dot :cal SetSyn("dot") -an 50.30.270 &Syntax.DE.Doxygen.C\ with\ doxygen :cal SetSyn("c.doxygen") -an 50.30.280 &Syntax.DE.Doxygen.C++\ with\ doxygen :cal SetSyn("cpp.doxygen") -an 50.30.290 &Syntax.DE.Doxygen.IDL\ with\ doxygen :cal SetSyn("idl.doxygen") -an 50.30.300 &Syntax.DE.Doxygen.Java\ with\ doxygen :cal SetSyn("java.doxygen") -an 50.30.310 &Syntax.DE.Dracula :cal SetSyn("dracula") -an 50.30.320 &Syntax.DE.DSSSL :cal SetSyn("dsl") -an 50.30.330 &Syntax.DE.DTD :cal SetSyn("dtd") -an 50.30.340 &Syntax.DE.DTML\ (Zope) :cal SetSyn("dtml") -an 50.30.350 &Syntax.DE.DTrace :cal SetSyn("dtrace") -an 50.30.360 &Syntax.DE.Dylan.Dylan :cal SetSyn("dylan") -an 50.30.370 &Syntax.DE.Dylan.Dylan\ interface :cal SetSyn("dylanintr") -an 50.30.380 &Syntax.DE.Dylan.Dylan\ lid :cal SetSyn("dylanlid") -an 50.30.400 &Syntax.DE.EDIF :cal SetSyn("edif") -an 50.30.410 &Syntax.DE.Eiffel :cal SetSyn("eiffel") -an 50.30.420 &Syntax.DE.Elinks\ config :cal SetSyn("elinks") -an 50.30.430 &Syntax.DE.Elm\ filter\ rules :cal SetSyn("elmfilt") -an 50.30.440 &Syntax.DE.Embedix\ Component\ Description :cal SetSyn("ecd") -an 50.30.450 &Syntax.DE.ERicsson\ LANGuage :cal SetSyn("erlang") -an 50.30.460 &Syntax.DE.ESMTP\ rc :cal SetSyn("esmtprc") -an 50.30.470 &Syntax.DE.ESQL-C :cal SetSyn("esqlc") -an 50.30.480 &Syntax.DE.Essbase\ script :cal SetSyn("csc") -an 50.30.490 &Syntax.DE.Esterel :cal SetSyn("esterel") -an 50.30.500 &Syntax.DE.Eterm\ config :cal SetSyn("eterm") -an 50.30.510 &Syntax.DE.Eviews :cal SetSyn("eviews") -an 50.30.520 &Syntax.DE.Exim\ conf :cal SetSyn("exim") -an 50.30.530 &Syntax.DE.Expect :cal SetSyn("expect") -an 50.30.540 &Syntax.DE.Exports :cal SetSyn("exports") +an 50.30.110 &Syntax.DE.Datascript :cal SetSyn("datascript") +an 50.30.120 &Syntax.DE.Debian.Debian\ ChangeLog :cal SetSyn("debchangelog") +an 50.30.130 &Syntax.DE.Debian.Debian\ Control :cal SetSyn("debcontrol") +an 50.30.140 &Syntax.DE.Debian.Debian\ Sources\.list :cal SetSyn("debsources") +an 50.30.150 &Syntax.DE.Denyhosts :cal SetSyn("denyhosts") +an 50.30.160 &Syntax.DE.Desktop :cal SetSyn("desktop") +an 50.30.170 &Syntax.DE.Dict\ config :cal SetSyn("dictconf") +an 50.30.180 &Syntax.DE.Dictd\ config :cal SetSyn("dictdconf") +an 50.30.190 &Syntax.DE.Diff :cal SetSyn("diff") +an 50.30.200 &Syntax.DE.Digital\ Command\ Lang :cal SetSyn("dcl") +an 50.30.210 &Syntax.DE.Dircolors :cal SetSyn("dircolors") +an 50.30.220 &Syntax.DE.Django\ template :cal SetSyn("django") +an 50.30.230 &Syntax.DE.DNS/BIND\ zone :cal SetSyn("bindzone") +an 50.30.240 &Syntax.DE.DocBook.auto-detect :cal SetSyn("docbk") +an 50.30.250 &Syntax.DE.DocBook.SGML :cal SetSyn("docbksgml") +an 50.30.260 &Syntax.DE.DocBook.XML :cal SetSyn("docbkxml") +an 50.30.270 &Syntax.DE.Dot :cal SetSyn("dot") +an 50.30.280 &Syntax.DE.Doxygen.C\ with\ doxygen :cal SetSyn("c.doxygen") +an 50.30.290 &Syntax.DE.Doxygen.C++\ with\ doxygen :cal SetSyn("cpp.doxygen") +an 50.30.300 &Syntax.DE.Doxygen.IDL\ with\ doxygen :cal SetSyn("idl.doxygen") +an 50.30.310 &Syntax.DE.Doxygen.Java\ with\ doxygen :cal SetSyn("java.doxygen") +an 50.30.320 &Syntax.DE.Dracula :cal SetSyn("dracula") +an 50.30.330 &Syntax.DE.DSSSL :cal SetSyn("dsl") +an 50.30.340 &Syntax.DE.DTD :cal SetSyn("dtd") +an 50.30.350 &Syntax.DE.DTML\ (Zope) :cal SetSyn("dtml") +an 50.30.360 &Syntax.DE.DTrace :cal SetSyn("dtrace") +an 50.30.370 &Syntax.DE.Dylan.Dylan :cal SetSyn("dylan") +an 50.30.380 &Syntax.DE.Dylan.Dylan\ interface :cal SetSyn("dylanintr") +an 50.30.390 &Syntax.DE.Dylan.Dylan\ lid :cal SetSyn("dylanlid") +an 50.30.410 &Syntax.DE.EDIF :cal SetSyn("edif") +an 50.30.420 &Syntax.DE.Eiffel :cal SetSyn("eiffel") +an 50.30.430 &Syntax.DE.Elinks\ config :cal SetSyn("elinks") +an 50.30.440 &Syntax.DE.Elm\ filter\ rules :cal SetSyn("elmfilt") +an 50.30.450 &Syntax.DE.Embedix\ Component\ Description :cal SetSyn("ecd") +an 50.30.460 &Syntax.DE.ERicsson\ LANGuage :cal SetSyn("erlang") +an 50.30.470 &Syntax.DE.ESMTP\ rc :cal SetSyn("esmtprc") +an 50.30.480 &Syntax.DE.ESQL-C :cal SetSyn("esqlc") +an 50.30.490 &Syntax.DE.Essbase\ script :cal SetSyn("csc") +an 50.30.500 &Syntax.DE.Esterel :cal SetSyn("esterel") +an 50.30.510 &Syntax.DE.Eterm\ config :cal SetSyn("eterm") +an 50.30.520 &Syntax.DE.Eviews :cal SetSyn("eviews") +an 50.30.530 &Syntax.DE.Exim\ conf :cal SetSyn("exim") +an 50.30.540 &Syntax.DE.Expect :cal SetSyn("expect") +an 50.30.550 &Syntax.DE.Exports :cal SetSyn("exports") an 50.40.100 &Syntax.FG.Fantom :cal SetSyn("fan") an 50.40.110 &Syntax.FG.Fetchmail :cal SetSyn("fetchmail") an 50.40.120 &Syntax.FG.FlexWiki :cal SetSyn("flexwiki") diff --git a/src/version.h b/src/version.h index 13208d6a01..867ce8c4d1 100644 --- a/src/version.h +++ b/src/version.h @@ -36,5 +36,5 @@ #define VIM_VERSION_NODOT "vim73d" #define VIM_VERSION_SHORT "7.3d" #define VIM_VERSION_MEDIUM "7.3d BETA" -#define VIM_VERSION_LONG "VIM - Vi IMproved 7.3d BETA (2010 Aug 1)" -#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3d BETA (2010 Aug 1, compiled " +#define VIM_VERSION_LONG "VIM - Vi IMproved 7.3d BETA (2010 Aug 4)" +#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3d BETA (2010 Aug 4, compiled " From 47b042e29416a7766ee9e57d355f3ac81bffb9d8 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 4 Aug 2010 18:27:57 +0200 Subject: [PATCH 24/24] Make test 73 a bit more portable. --HG-- branch : vim73 --- runtime/doc/todo.txt | 2 ++ src/testdir/Make_dos.mak | 1 + src/testdir/test73.in | 10 ++++++---- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index 1880014a95..c3f436170b 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -33,6 +33,8 @@ be worked on, but only if you sponsor Vim development. See |sponsor|. Before release 7.3: - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) +test73 doesn't work on MS-Windows. + test72 causes a beep for using "u" when it doesn't work. Cursor positioning wrong with 0x200e character. (John Becket, 2010 May 6) diff --git a/src/testdir/Make_dos.mak b/src/testdir/Make_dos.mak index 94b44c2423..be253c9b7b 100644 --- a/src/testdir/Make_dos.mak +++ b/src/testdir/Make_dos.mak @@ -59,6 +59,7 @@ clean: -if exist mbyte.vim del mbyte.vim -if exist mzscheme.vim del mzscheme.vim -del X* + -del X*.* -if exist viminfo del viminfo .in.out: diff --git a/src/testdir/test73.in b/src/testdir/test73.in index 822dde3f5a..8928aeb2d6 100644 --- a/src/testdir/test73.in +++ b/src/testdir/test73.in @@ -1,13 +1,15 @@ Tests for find completion. STARTTEST -:!mkdir -p Xfind/in/path +:!mkdir Xfind +:!mkdir Xfind/in +:!mkdir Xfind/in/path :e Xfind/file.txt -aHoly Grail:w +SHoly Grail:w :e Xfind/in/file.txt -aJimmy Hoffa:w +SJimmy Hoffa:w :e Xfind/in/path/file.txt -aE.T.:w +SE.T.:w :set path=Xfind/** :set nocp :find file