To: vim-dev@vim.org Subject: Patch 6.0.001 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.001 Problem: Loading the sh.vim syntax file causes error messages . (Corinna Vinschen) Solution: Add an "if". (Charles Campbell) Files: runtime/syntax/sh.vim *** ../vim60/runtime/syntax/sh.vim Thu Sep 20 17:29:50 2001 --- runtime/syntax/sh.vim Thu Sep 27 22:00:30 2001 *************** *** 2,9 **** " Language: shell (sh) Korn shell (ksh) bash (sh) " Maintainer: Dr. Charles E. Campbell, Jr. " Previous Maintainer: Lennart Schultz ! " Last Change: September 18, 2001 ! " Version: 26 " " Using the following VIM variables: " b:is_kornshell if defined, enhance with kornshell syntax --- 2,9 ---- " Language: shell (sh) Korn shell (ksh) bash (sh) " Maintainer: Dr. Charles E. Campbell, Jr. " Previous Maintainer: Lennart Schultz ! " Last Change: September 26, 2001 ! " Version: 27 " " Using the following VIM variables: " b:is_kornshell if defined, enhance with kornshell syntax *************** *** 318,325 **** syn sync match shForSync groupthere shFor "\" syn sync match shIfSync grouphere shIf "\" syn sync match shIfSync groupthere shIf "\" ! syn sync match shUntilSync grouphere shRepeat "\" ! syn sync match shWhileSync grouphere shRepeat "\" " The default highlighting. hi def link shArithRegion shShellVariables --- 318,327 ---- syn sync match shForSync groupthere shFor "\" syn sync match shIfSync grouphere shIf "\" syn sync match shIfSync groupthere shIf "\" ! if exists("b:is_kornshell") || exists("b:is_bash") ! syn sync match shUntilSync grouphere shRepeat "\" ! syn sync match shWhileSync grouphere shRepeat "\" ! endif " The default highlighting. hi def link shArithRegion shShellVariables *************** *** 382,388 **** hi def link shFunctionName Function hi def link shNumber Number hi def link shOperator Operator ! hi def link shRepeat Repeat hi def link shSetList Identifier hi def link shShellVariables PreProc hi def link shSpecial Special --- 384,392 ---- hi def link shFunctionName Function hi def link shNumber Number hi def link shOperator Operator ! if exists("b:is_kornshell") || exists("b:is_bash") ! hi def link shRepeat Repeat ! endif hi def link shSetList Identifier hi def link shShellVariables PreProc hi def link shSpecial Special *** ../vim60/src/version.c Tue Sep 25 21:43:37 2001 --- src/version.c Thu Sep 27 22:07:59 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 1, /**/ -- This planet has -- or rather had -- a problem, which was this: most of the people living on it were unhappy for pretty much of the time. Many solutions were suggested for this problem, but most of these were largely concerned with the movements of small green pieces of paper, which is odd because on the whole it wasn't the small green pieces of paper that were unhappy. -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.002 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.002 Problem: Using a '@' item in 'viminfo' doesn't work. (Marko Leipert) Solution: Add '@' to the list of accepted items. Files: src/option.c *** ../vim60.1/src/option.c Wed Sep 26 16:25:52 2001 --- src/option.c Thu Sep 27 09:44:40 2001 *************** *** 4626,4632 **** for (s = p_viminfo; *s;) { /* Check it's a valid character */ ! if (vim_strchr((char_u *)"!\"%'/:cfhnr", *s) == NULL) { errmsg = illegal_char(errbuf, *s); break; --- 4626,4632 ---- for (s = p_viminfo; *s;) { /* Check it's a valid character */ ! if (vim_strchr((char_u *)"!\"%'/:@cfhnr", *s) == NULL) { errmsg = illegal_char(errbuf, *s); break; *** ../vim60.1/src/version.c Thu Sep 27 22:11:50 2001 --- src/version.c Thu Sep 27 22:15:47 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 2, /**/ -- Time is an illusion. Lunchtime doubly so. -- Ford Prefect, in Douglas Adams' "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.003 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.003 Problem: The configure check for ACLs on AIX doesn't work. Solution: Fix the test program so that it compiles. (Tomas Ogren) Files: src/configure.in, src/auto/configure *** ../vim60.1/src/configure.in Mon Sep 10 11:39:13 2001 --- src/configure.in Thu Sep 27 22:19:52 2001 *************** *** 1760,1771 **** # include #endif #define _ALL_SOURCE ! #ifdef HAVE_SYS_STAT_H ! # include ! #endif int aclsize; struct acl *aclent;], [aclsize = sizeof(struct acl); ! aclent = malloc(aclsize); statacl("foo", STX_NORMAL, aclent, aclsize); ], AC_MSG_RESULT(yes); AC_DEFINE(HAVE_AIX_ACL), --- 1760,1771 ---- # include #endif #define _ALL_SOURCE ! ! #include ! int aclsize; struct acl *aclent;], [aclsize = sizeof(struct acl); ! aclent = (void *)malloc(aclsize); statacl("foo", STX_NORMAL, aclent, aclsize); ], AC_MSG_RESULT(yes); AC_DEFINE(HAVE_AIX_ACL), *** ../vim60.1/src/auto/configure Mon Sep 10 11:39:17 2001 --- src/auto/configure Thu Sep 27 22:20:19 2001 *************** *** 6085,6098 **** # include #endif #define _ALL_SOURCE ! #ifdef HAVE_SYS_STAT_H ! # include ! #endif int aclsize; struct acl *aclent; int main() { aclsize = sizeof(struct acl); ! aclent = malloc(aclsize); statacl("foo", STX_NORMAL, aclent, aclsize); ; return 0; } --- 6085,6098 ---- # include #endif #define _ALL_SOURCE ! ! #include ! int aclsize; struct acl *aclent; int main() { aclsize = sizeof(struct acl); ! aclent = (void *)malloc(aclsize); statacl("foo", STX_NORMAL, aclent, aclsize); ; return 0; } *** ../vim60.1/src/version.c Thu Sep 27 22:16:49 2001 --- src/version.c Thu Sep 27 22:17:59 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 3, /**/ -- Tips for aliens in New York: Land anywhere. Central Park, anywhere. No one will care or indeed even notice. -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.004 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.004 Problem: The find/replace dialog doesn't reuse a previous argument properly. Solution: After removing a "\V" terminate the string. (Zwane Mwaikambo) Files: src/gui.c *** ../vim60.3/src/gui.c Tue Sep 25 11:38:35 2001 --- src/gui.c Fri Sep 28 17:29:55 2001 *************** *** 3993,3999 **** /* Remove "\V" */ if (len >= 2 && STRNCMP(text, "\\V", 2) == 0) ! mch_memmove(text, text + 2, (size_t)(len - 2)); /* Recognize "\" and remove. */ if (len >= 4 --- 3993,3999 ---- /* Remove "\V" */ if (len >= 2 && STRNCMP(text, "\\V", 2) == 0) ! mch_memmove(text, text + 2, (size_t)(len - 1)); /* Recognize "\" and remove. */ if (len >= 4 *** ../vim60.3/src/version.c Fri Sep 28 17:39:10 2001 --- src/version.c Fri Sep 28 17:35:47 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 4, /**/ -- Latest survey shows that 3 out of 4 people make up 75% of the world's population. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.005 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.005 Problem: In Insert mode, "CTRL-O :ls" has a delay before redrawing. Solution: Don't delay just after wait_return() was called. Added the did_wait_return flag. Files: src/globals.h, src/messsage.c, src/normal.c, src/screen.c *** ../vim60.4/src/globals.h Sun Sep 16 17:25:35 2001 --- src/globals.h Fri Sep 28 21:55:27 2001 *************** *** 149,154 **** --- 149,156 ---- EXTERN int no_wait_return INIT(= 0); /* don't wait for return for now */ EXTERN int need_wait_return INIT(= 0); /* need to wait for return later */ + EXTERN int did_wait_return INIT(= FALSE); /* wait_return() was used and + nothing written since then */ #ifdef FEAT_TITLE EXTERN int need_maketitle INIT(= TRUE); /* call maketitle() soon */ #endif *** ../vim60.4/src/message.c Tue Aug 28 20:04:53 2001 --- src/message.c Fri Sep 28 21:51:05 2001 *************** *** 846,851 **** --- 846,852 ---- #endif need_wait_return = FALSE; + did_wait_return = TRUE; emsg_on_display = FALSE; /* can delete error message now */ lines_left = -1; /* reset lines_left at next msg_start() */ reset_last_sourcing(); *************** *** 1564,1569 **** --- 1565,1571 ---- } msg_didany = TRUE; /* remember that something was outputted */ + did_wait_return = FALSE; while (*s) { /* *** ../vim60.4/src/normal.c Wed Sep 26 16:21:24 2001 --- src/normal.c Fri Sep 28 21:59:34 2001 *************** *** 1086,1091 **** --- 1086,1092 ---- && stuff_empty() && typebuf_typed() && emsg_silent == 0 + && !did_wait_return && oap->op_type == OP_NOP) { int save_State = State; *** ../vim60.4/src/screen.c Wed Sep 26 09:57:36 2001 --- src/screen.c Fri Sep 28 21:50:43 2001 *************** *** 5851,5856 **** --- 5851,5857 ---- int check_msg_scroll; { if ((emsg_on_display || (check_msg_scroll && msg_scroll)) + && !did_wait_return && emsg_silent == 0) { out_flush(); *** ../vim60.4/src/version.c Fri Sep 28 17:48:07 2001 --- src/version.c Fri Sep 28 22:06:12 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 5, /**/ -- hundred-and-one symptoms of being an internet addict: 40. You tell the cab driver you live at http://123.elm.street/house/bluetrim.html 41. You actually try that 123.elm.street address. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.006 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.006 Problem: With a vertical split, 'number' set and 'scrolloff' non-zero, making the window width very small causes a crash. (Niklas Lindstrom) Solution: Check for a zero width. Files: src/move.c *** ../vim60.5/src/move.c Tue Sep 25 11:23:37 2001 --- src/move.c Sat Sep 29 09:41:40 2001 *************** *** 1085,1090 **** --- 1085,1091 ---- - 1 >= curwin->w_height)) && curwin->w_height != 0 && curwin->w_cursor.lnum == curwin->w_topline + && width > 0 #ifdef FEAT_VERTSPLIT && curwin->w_width != 0 #endif *** ../vim60.5/src/version.c Fri Sep 28 22:19:57 2001 --- src/version.c Sat Sep 29 09:47:34 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 6, /**/ -- hundred-and-one symptoms of being an internet addict: 47. You are so familiar with the WWW that you find the search engines useless. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.007 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.007 Problem: When setting 'filetype' while there is no FileType autocommand, a following ":setfiletype" would set 'filetype' again. (Kobus Retief) Solution: Set did_filetype always when 'filetype' has been set. Files: src/option.c *** ../vim60.6/src/option.c Thu Sep 27 22:16:49 2001 --- src/option.c Sat Sep 29 10:16:11 2001 *************** *** 4920,4925 **** --- 4920,4926 ---- /* When 'filetype' is set, trigger the FileType autocommands of that name */ else if (varp == &(curbuf->b_p_ft)) { + did_filetype = TRUE; apply_autocmds(EVENT_FILETYPE, curbuf->b_p_ft, curbuf->b_fname, TRUE, curbuf); } *** ../vim60.6/src/version.c Sat Sep 29 10:11:29 2001 --- src/version.c Sat Sep 29 10:11:04 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 7, /**/ -- hundred-and-one symptoms of being an internet addict: 49. You never have to deal with busy signals when calling your ISP...because you never log off. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.008 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.008 Problem: 'imdisable' is missing from the options window. (Michael Naumann) Solution: Add an entry for it. Files: runtime/optwin.vim *** ../vim60.7/runtime/optwin.vim Sun Sep 2 14:36:59 2001 --- runtime/optwin.vim Sat Sep 29 15:19:31 2001 *************** *** 1,7 **** " These commands create the option window. " " Maintainer: Bram Moolenaar ! " Last Change: 2001 Sep 02 " If there already is an option window, jump to that one. if bufwinnr("option-window") > 0 --- 1,7 ---- " These commands create the option window. " " Maintainer: Bram Moolenaar ! " Last Change: 2001 Sep 29 " If there already is an option window, jump to that one. if bufwinnr("option-window") > 0 *************** *** 1003,1008 **** --- 1003,1012 ---- if has("langmap") call append("$", "langmap\ttranslate characters for Normal mode") call OptionG("lmap", &lmap) + endif + if has("xim") + call append("$", "imdisable\twhen set never use IM; overrules following IM options") + call BinOptionG("imd", &imd) endif call append("$", "iminsert\tin Insert mode: 1: use :lmap; 2: use IM; 0: neither") call append("$", "\t(local to window)") *** ../vim60.7/src/version.c Sat Sep 29 10:20:07 2001 --- src/version.c Sat Sep 29 15:22:54 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 8, /**/ -- Never go to the toilet in a paperless office. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.009 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.009 Problem: Nextstep doesn't have S_ISBLK. (John Beppu) Solution: Define S_ISBLK using S_IFBLK. Files: src/os_unix.h *** ../vim60.8/src/os_unix.h Mon Aug 27 17:29:01 2001 --- src/os_unix.h Fri Sep 28 20:21:12 2001 *************** *** 486,491 **** --- 486,494 ---- #if !defined(S_ISREG) && defined(S_IFREG) # define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) #endif + #if !defined(S_ISBLK) && defined(S_IFBLK) + # define S_ISBLK(m) (((m) & S_IFMT) == S_IFBLK) + #endif #if !defined(S_ISSOCK) && defined(S_IFSOCK) # define S_ISSOCK(m) (((m) & S_IFMT) == S_IFSOCK) #endif *** ../vim60.8/src/version.c Sat Sep 29 18:26:29 2001 --- src/version.c Sat Sep 29 18:25:22 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 9, /**/ -- Q: What is a patch 22? A: A patch you need to include to make it possible to include patches. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.010 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.010 Problem: Using "gf" on a file name starting with "./" or "../" in a buffer without a name causes a crash. (Roy Lewis) Solution: Check for a NULL file name. Files: src/misc2.c *** ../vim60.9/src/misc2.c Wed Sep 26 16:20:26 2001 --- src/misc2.c Sun Sep 30 10:47:02 2001 *************** *** 4805,4812 **** for (run = 1; run <= 2; ++run) { l = (int)STRLEN(file_to_find); ! if (run == 1 && rel_to_curdir && (options & FNAME_REL) ! && STRLEN(rel_fname) + l < MAXPATHL) { STRCPY(NameBuff, rel_fname); STRCPY(gettail(NameBuff), file_to_find); --- 4805,4815 ---- for (run = 1; run <= 2; ++run) { l = (int)STRLEN(file_to_find); ! if (run == 1 ! && rel_to_curdir ! && (options & FNAME_REL) ! && rel_fname != NULL ! && STRLEN(rel_fname) + l < MAXPATHL) { STRCPY(NameBuff, rel_fname); STRCPY(gettail(NameBuff), file_to_find); *** ../vim60.9/src/version.c Sun Sep 30 10:50:44 2001 --- src/version.c Sun Sep 30 10:49:23 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 10, /**/ -- Q: How to decide if I should clean my house or work on improving Vim? A: Depends on which has more bugs. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.011 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.011 Problem: Python: After replacing or deleting lines get an ml_get error. (Leo Lipelis) Solution: Adjust the cursor position for deleted or added lines. Files: src/if_python.c *** ../vim60.10/src/if_python.c Fri Aug 24 21:30:54 2001 --- src/if_python.c Sat Sep 29 20:40:30 2001 *************** *** 2116,2121 **** --- 2116,2148 ---- return list; } + /* + * Check if deleting lines made the cursor position invalid. + * Changed the lines from "lo" to "hi" and added "extra" lines (negative if + * deleted). + */ + static void + py_fix_cursor(int lo, int hi, int extra) + { + if (curwin->w_cursor.lnum >= lo) + { + /* Adjust the cursor position if it's in/after the changed + * lines. */ + if (curwin->w_cursor.lnum >= hi) + { + curwin->w_cursor.lnum += extra; + check_cursor_col(); + } + else if (extra < 0) + { + curwin->w_cursor.lnum = lo; + check_cursor(); + } + changed_cline_bef_curs(); + } + invalidate_botline(); + } + /* Replace a line in the specified buffer. The line number is * in Vim format (1-based). The replacement line is given as * a Python string object. The object is checked for validity *************** *** 2145,2151 **** --- 2172,2182 ---- else if (ml_delete((linenr_T)n, FALSE) == FAIL) PyErr_SetVim(_("cannot delete line")); else + { deleted_lines_mark((linenr_T)n, 1L); + if (buf == curwin->w_buffer) + py_fix_cursor(n, n + 1, -1); + } curbuf = savebuf; *************** *** 2234,2239 **** --- 2265,2273 ---- } } deleted_lines_mark((linenr_T)lo, (long)i); + + if (buf == curwin->w_buffer) + py_fix_cursor(lo, hi, -n); } curbuf = savebuf; *************** *** 2353,2358 **** --- 2387,2395 ---- mark_adjust((linenr_T)lo, (linenr_T)(hi - 1), (long)MAXLNUM, (long)extra); changed_lines((linenr_T)lo, 0, (linenr_T)hi, (long)extra); + + if (buf == curwin->w_buffer) + py_fix_cursor(lo, hi, extra); curbuf = savebuf; *** ../vim60.10/src/version.c Sun Sep 30 10:53:07 2001 --- src/version.c Sun Sep 30 10:54:20 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 11, /**/ -- Time is money. Especially if you make clocks. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.013 Fcc: outbox From: Bram Moolenaar ------------ Patch 6.0.013 Problem: Using ":silent! cmd" still gives some error messages, like for an invalid range. (Salman Halim) Solution: Reset emsg_silent after calling emsg() in do_one_cmd(). Files: src/ex_docmd.c *** ../vim60.12/src/ex_docmd.c Fri Sep 14 21:48:28 2001 --- src/ex_docmd.c Thu Oct 18 17:53:53 2001 *************** *** 1880,1885 **** --- 1880,1900 ---- if (curwin->w_cursor.lnum == 0) /* can happen with zero line number */ curwin->w_cursor.lnum = 1; + if (errormsg != NULL && *errormsg != NUL && !did_emsg) + { + if (sourcing) + { + if (errormsg != IObuff) + { + STRCPY(IObuff, errormsg); + errormsg = IObuff; + } + STRCAT(errormsg, ": "); + STRNCAT(errormsg, *cmdlinep, IOSIZE - STRLEN(IObuff)); + } + emsg(errormsg); + } + if (verbose_save >= 0) p_verbose = verbose_save; *************** *** 1900,1919 **** msg_scroll = save_msg_scroll; } - if (errormsg != NULL && *errormsg != NUL && !did_emsg) - { - if (sourcing) - { - if (errormsg != IObuff) - { - STRCPY(IObuff, errormsg); - errormsg = IObuff; - } - STRCAT(errormsg, ": "); - STRNCAT(errormsg, *cmdlinep, IOSIZE - STRLEN(IObuff)); - } - emsg(errormsg); - } if (ea.nextcmd && *ea.nextcmd == NUL) /* not really a next command */ ea.nextcmd = NULL; --- 1915,1920 ---- *** ../vim60.12/src/version.c Thu Oct 18 18:02:49 2001 --- src/version.c Thu Oct 18 17:54:02 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 13, /**/ -- From "know your smileys": ~#:-( I just washed my hair, and I can't do nuthin' with it. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.014 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.014 Problem: When 'modifiable' is off and 'virtualedit' is "all", "rx" on a TAB still changes the buffer. (Muraoka Taro) Solution: Check if saving the line for undo fails. Files: src/normal.c *** ../vim60.13/src/normal.c Fri Sep 28 22:19:57 2001 --- src/normal.c Fri Oct 19 11:18:05 2001 *************** *** 5764,5770 **** /* Break tabs, etc. */ if (virtual_active()) { ! u_save_cursor(); if (gchar_cursor() == NUL) { /* Add extra space and put the cursor on the first one. */ --- 5764,5771 ---- /* Break tabs, etc. */ if (virtual_active()) { ! if (u_save_cursor() == FAIL) ! return; if (gchar_cursor() == NUL) { /* Add extra space and put the cursor on the first one. */ *** ../vim60.13/src/version.c Fri Oct 19 11:18:45 2001 --- src/version.c Fri Oct 19 11:17:35 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 14, /**/ -- From "know your smileys": % Bike accident (a bit far-fetched, I suppose) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.015 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.015 Problem: When 'cpoptions' includes "S" and "filetype plugin on" has been used, can get an error for deleting the b:did_ftplugin variable. (Ralph Henderson) Solution: Only delete the variable when it exists. Files: runtime/ftplugin.vim *** ../vim60.14/runtime/ftplugin.vim Tue Sep 18 18:35:13 2001 --- runtime/ftplugin.vim Fri Oct 19 15:21:05 2001 *************** *** 1,7 **** " Vim support file to switch on loading plugins for file types " " Maintainer: Bram Moolenaar ! " Last change: 2001 Sep 18 if exists("did_load_ftplugin") finish --- 1,7 ---- " Vim support file to switch on loading plugins for file types " " Maintainer: Bram Moolenaar ! " Last change: 2001 Oct 19 if exists("did_load_ftplugin") finish *************** *** 12,18 **** au FileType * call s:LoadFTPlugin() func! s:LoadFTPlugin() if expand("") != "" ! if &cpo =~# "S" " In compatible mode options are reset to the global values, need to " set the local values also when a plugin was already used. unlet b:did_ftplugin --- 12,18 ---- au FileType * call s:LoadFTPlugin() func! s:LoadFTPlugin() if expand("") != "" ! if &cpo =~# "S" && exists("b:did_ftplugin") " In compatible mode options are reset to the global values, need to " set the local values also when a plugin was already used. unlet b:did_ftplugin *** ../vim60.14/src/version.c Fri Oct 19 15:24:44 2001 --- src/version.c Fri Oct 19 15:24:33 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 15, /**/ -- hundred-and-one symptoms of being an internet addict: 97. Your mother tells you to remember something, and you look for a File/Save command. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.016 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.016 Problem: bufnr(), bufname() and bufwinnr() don't find unlisted buffers when the argument is a string. (Hari Krishna Dara) Also for setbufvar() and getbufvar(). Solution: Also find unlisted buffers. Files: src/eval.c *** ../vim60.15/src/eval.c Mon Sep 24 20:56:45 2001 --- src/eval.c Fri Oct 19 17:20:49 2001 *************** *** 2908,2914 **** p_cpo = (char_u *)""; buf = buflist_findnr(buflist_findpat(name, name + STRLEN(name), ! FALSE, FALSE)); p_magic = save_magic; p_cpo = save_cpo; --- 2908,2914 ---- p_cpo = (char_u *)""; buf = buflist_findnr(buflist_findpat(name, name + STRLEN(name), ! TRUE, FALSE)); p_magic = save_magic; p_cpo = save_cpo; *** ../vim60.15/src/version.c Fri Oct 19 17:27:43 2001 --- src/version.c Fri Oct 19 17:23:09 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 16, /**/ -- hundred-and-one symptoms of being an internet addict: 104. When people ask about the Presidential Election you ask "Which country?" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.017 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.017 Problem: When 'ttybuiltin' is set and a builtin termcap entry defines t_Co and the external one doesn't, it gets reset to empty. (David Harrison) Solution: Only set t_Co when it wasn't set yet. Files: src/term.c *** ../vim60.16/src/term.c Thu Sep 20 21:31:38 2001 --- src/term.c Fri Oct 19 19:38:08 2001 *************** *** 1665,1673 **** width = tgetnum("co"); /* ! * Get number of colors. */ ! set_color_count(tgetnum("Co")); # ifndef hpux BC = (char *)TGETSTR("bc", &tp); --- 1665,1675 ---- width = tgetnum("co"); /* ! * Get number of colors (if not done already). */ ! if (term_str(KS_CCO) == NULL ! || term_str(KS_CCO) == empty_option) ! set_color_count(tgetnum("Co")); # ifndef hpux BC = (char *)TGETSTR("bc", &tp); *** ../vim60.16/src/version.c Fri Oct 19 19:36:36 2001 --- src/version.c Fri Oct 19 19:35:14 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 17, /**/ -- hundred-and-one symptoms of being an internet addict: 106. When told to "go to your room" you inform your parents that you can't...because you were kicked out and banned. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.018 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.018 Problem: Initializing 'encoding' may cause a crash when setlocale() is not used. (Dany St-Amant) Solution: Check for a NULL pointer. Files: src/mbyte.c *** ../vim60.17/src/mbyte.c Wed Sep 26 16:18:24 2001 --- src/mbyte.c Sun Oct 21 12:39:21 2001 *************** *** 2317,2324 **** #endif /* ! * Return the default value for 'encoding' in an allocated string. ! * Returns NULL when out of memory or no usable default could be found. */ int enc_default() --- 2317,2324 ---- #endif /* ! * Set the default value for 'encoding' (p_enc). ! * Returns OK when successful, FAIL when not. */ int enc_default() *************** *** 2349,2354 **** --- 2349,2357 ---- if ((s = getenv("LC_ALL")) == NULL || *s == NUL) if ((s = getenv("LC_CTYPE")) == NULL || *s == NUL) s = getenv("LANG"); + + if (s == NULL || *s == NUL) + return FAIL; /* The most generic locale format is: * language[_territory][.codeset][@modifier][+special][,[sponsor][_revision]] *** ../vim60.17/src/version.c Sun Oct 21 12:38:02 2001 --- src/version.c Sun Oct 21 12:35:28 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 18, /**/ -- hundred-and-one symptoms of being an internet addict: 139. You down your lunch in five minutes, at your desk, so you can spend the rest of the hour surfing the Net. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.019 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.019 Problem: Converting a string with multi-byte characters to a printable string, e.g., with strtrans(), may cause a crash. (Tomas Zellerin) Solution: Correctly compute the length of the result in transstr(). Files: src/charset.c *** ../vim60.18/src/charset.c Wed Sep 19 17:28:08 2001 --- src/charset.c Mon Oct 22 12:43:03 2001 *************** *** 327,351 **** char_u *s; { char_u *res; #ifdef FEAT_MBYTE ! int l; #endif ! res = alloc((unsigned)(vim_strsize(s) + 1)); if (res != NULL) { *res = NUL; ! while (*s != NUL) { #ifdef FEAT_MBYTE ! if (has_mbyte && (l = (*mb_ptr2len_check)(s)) > 1) { ! STRNCAT(res, s, l); ! s += l; } else #endif ! STRCAT(res, transchar(*s++)); } } return res; --- 327,374 ---- char_u *s; { char_u *res; + char_u *p; #ifdef FEAT_MBYTE ! int l, len; #endif ! #ifdef FEAT_MBYTE ! if (has_mbyte) ! { ! /* Compute the length of the result, taking into account that ! * multi-byte characters are copied unchanged. */ ! len = 0; ! p = s; ! while (*p != NUL) ! { ! if ((l = (*mb_ptr2len_check)(p)) > 1) ! { ! len += l; ! p += l; ! } ! else ! len += byte2cells(*p++); ! } ! res = alloc((unsigned)(len + 1)); ! } ! else ! #endif ! res = alloc((unsigned)(vim_strsize(s) + 1)); if (res != NULL) { *res = NUL; ! p = s; ! while (*p != NUL) { #ifdef FEAT_MBYTE ! if (has_mbyte && (l = (*mb_ptr2len_check)(p)) > 1) { ! STRNCAT(res, p, l); ! p += l; } else #endif ! STRCAT(res, transchar(*p++)); } } return res; *** ../vim60.18/src/version.c Mon Oct 22 12:47:09 2001 --- src/version.c Mon Oct 22 12:46:56 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 19, /**/ -- "Hit any key to continue" is very confusing when you have two keyboards. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.020 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.020 Problem: When obtaining the value of a global variable internally, could get the function-local value instead. Applies to using and and resetting highlighting in a function. Solution: Prepend "g:" to the variable name. (Aric Blumer) Files: src/syntax.c, src/term.c *** ../vim60.19/src/syntax.c Wed Sep 26 16:12:52 2001 --- src/syntax.c Mon Oct 22 18:36:33 2001 *************** *** 5871,5877 **** * Try finding the color scheme file. Used when a color file was loaded * and 'background' or 't_Co' is changed. */ ! p = get_var_value((char_u *)"colors_name"); if (p != NULL && load_colors(p) == OK) return; #endif --- 5871,5877 ---- * Try finding the color scheme file. Used when a color file was loaded * and 'background' or 't_Co' is changed. */ ! p = get_var_value((char_u *)"g:colors_name"); if (p != NULL && load_colors(p) == OK) return; #endif *************** *** 5903,5909 **** /* * If syntax highlighting is enabled load the highlighting for it. */ ! if (get_var_value((char_u *)"syntax_on") != NULL) (void)cmd_runtime((char_u *)"syntax/syncolor.vim", TRUE); #endif } --- 5903,5909 ---- /* * If syntax highlighting is enabled load the highlighting for it. */ ! if (get_var_value((char_u *)"g:syntax_on") != NULL) (void)cmd_runtime((char_u *)"syntax/syncolor.vim", TRUE); #endif } *** ../vim60.19/src/term.c Sun Oct 21 12:38:02 2001 --- src/term.c Mon Oct 22 18:37:53 2001 *************** *** 4714,4725 **** if (STRNICMP(src, "", 8) == 0) { len = 8; ! p = get_var_value((char_u *)"mapleader"); } else if (STRNICMP(src, "", 13) == 0) { len = 13; ! p = get_var_value((char_u *)"maplocalleader"); } else { --- 4714,4725 ---- if (STRNICMP(src, "", 8) == 0) { len = 8; ! p = get_var_value((char_u *)"g:mapleader"); } else if (STRNICMP(src, "", 13) == 0) { len = 13; ! p = get_var_value((char_u *)"g:maplocalleader"); } else { *** ../vim60.19/src/version.c Mon Oct 22 12:52:35 2001 --- src/version.c Mon Oct 22 18:38:09 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 20, /**/ -- Rule #1: Don't give somebody a tool that he's going to hurt himself with. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.021 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.021 Problem: The 'cscopepathcomp' option didn't work. Solution: Change USE_CSCOPE to FEAT_CSCOPE. (Mark Feng) Files: src/option.c *** ../vim60.20/src/option.c Sat Sep 29 10:20:07 2001 --- src/option.c Mon Oct 22 21:15:50 2001 *************** *** 589,595 **** (char_u *)&p_cpo, PV_NONE, {(char_u *)CPO_ALL, (char_u *)CPO_DEFAULT}}, {"cscopepathcomp", "cspc", P_NUM|P_VI_DEF|P_VIM, ! #ifdef USE_CSCOPE (char_u *)&p_cspc, PV_NONE, #else (char_u *)NULL, PV_NONE, --- 589,595 ---- (char_u *)&p_cpo, PV_NONE, {(char_u *)CPO_ALL, (char_u *)CPO_DEFAULT}}, {"cscopepathcomp", "cspc", P_NUM|P_VI_DEF|P_VIM, ! #ifdef FEAT_CSCOPE (char_u *)&p_cspc, PV_NONE, #else (char_u *)NULL, PV_NONE, *** ../vim60.20/src/version.c Mon Oct 22 18:52:01 2001 --- src/version.c Mon Oct 22 21:17:35 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 21, /**/ -- hundred-and-one symptoms of being an internet addict: 189. You put your e-mail address in the upper left-hand corner of envelopes. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.022 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.022 Problem: When using the 'langmap' option, the second character of a command starting with "g" isn't adjusted. Solution: Apply 'langmap' to the second character. (Alex Kapranoff) Files: src/normal.c *** ../vim60.21/src/normal.c Fri Oct 19 15:24:44 2001 --- src/normal.c Tue Oct 23 16:50:50 2001 *************** *** 842,847 **** --- 842,850 ---- * "gr", "g'" and "g`". */ ca.nchar = safe_vgetc(); + #ifdef FEAT_LANGMAP + LANGMAP_ADJUST(ca.nchar, TRUE); + #endif #ifdef FEAT_CMDL_INFO need_flushbuf |= add_to_showcmd(ca.nchar); #endif *** ../vim60.21/src/version.c Mon Oct 22 21:19:00 2001 --- src/version.c Tue Oct 23 16:53:44 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 22, /**/ -- hundred-and-one symptoms of being an internet addict: 221. Your wife melts your keyboard in the oven. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.023 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.023 Problem: Loading the lhaskell syntax doesn't work. (Thore B. Karlsen) Solution: Use ":runtime" instead of "source" to load haskell.vim. Files: runtime/syntax/lhaskell.vim *** ../vim60.22/runtime/syntax/lhaskell.vim Wed May 9 20:19:38 2001 --- runtime/syntax/lhaskell.vim Tue Oct 23 20:54:06 2001 *************** *** 1,7 **** " Vim syntax file " Language: Haskell with literate comments " Maintainer: John Williams ! " Last Change: 2001 May 09 " Enable literate comments let b:hs_literate_comments=1 --- 1,7 ---- " Vim syntax file " Language: Haskell with literate comments " Maintainer: John Williams ! " Last Change: 2001 Oct 23 " Enable literate comments let b:hs_literate_comments=1 *************** *** 10,16 **** if version < 600 source :p:h/haskell.vim else ! source syntax/haskell.vim endif " vim: ts=8 --- 10,16 ---- if version < 600 source :p:h/haskell.vim else ! runtime! syntax/haskell.vim endif " vim: ts=8 *** ../vim60.22/src/version.c Tue Oct 23 16:54:23 2001 --- src/version.c Tue Oct 23 20:56:16 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 23, /**/ -- hundred-and-one symptoms of being an internet addict: 232. You start conversations with, "Have you gotten an ISDN line?" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.024 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.024 Problem: Using "CTRL-V u 9900" in Insert mode may cause a crash. (Noah Levitt) Solution: Don't insert a NUL byte in the text, use a newline. Files: src/misc1.c *** ../vim60.23/src/misc1.c Wed Sep 26 16:19:00 2001 --- src/misc1.c Wed Oct 24 13:15:20 2001 *************** *** 1536,1541 **** --- 1536,1547 ---- int n; n = (*mb_char2bytes)(c, buf); + + /* When "c" is 0x100, 0x200, etc. we don't want to insert a NUL byte. + * Happens for CTRL-Vu9900. */ + if (buf[0] == 0) + buf[0] = '\n'; + ins_char_bytes(buf, n); } *** ../vim60.23/src/version.c Tue Oct 23 20:57:50 2001 --- src/version.c Wed Oct 24 13:19:45 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 24, /**/ -- Women are probably the main cause of free software starvation. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.025 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.025 Problem: The pattern "\vx(.|$)" doesn't match "x" at the end of a line. (Preben Peppe Guldberg) Solution: Always see a "$" as end-of-line after "\v". Do the same for "^". Files: src/regexp.c *** ../vim60.24/src/regexp.c Fri Sep 7 13:19:00 2001 --- src/regexp.c Wed Oct 24 19:33:23 2001 *************** *** 2262,2267 **** --- 2262,2268 ---- * "\(", "\|", "\&' or "\n" */ if (reg_magic >= MAGIC_OFF && (at_start + || reg_magic == MAGIC_ALL || prevchr == Magic('(') || prevchr == Magic('|') || prevchr == Magic('&') *************** *** 2288,2294 **** if (p[0] == NUL || (p[0] == '\\' && (p[1] == '|' || p[1] == '&' || p[1] == ')' ! || p[1] == 'n'))) curchr = Magic('$'); } break; --- 2289,2296 ---- if (p[0] == NUL || (p[0] == '\\' && (p[1] == '|' || p[1] == '&' || p[1] == ')' ! || p[1] == 'n')) ! || reg_magic == MAGIC_ALL) curchr = Magic('$'); } break; *** ../vim60.24/src/version.c Wed Oct 24 13:22:11 2001 --- src/version.c Wed Oct 24 19:40:42 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 25, /**/ -- He was not in the least bit scared to be mashed into a pulp Or to have his eyes gouged out and his elbows broken; To have his kneecaps split and his body burned away And his limbs all hacked and mangled, brave Sir Robin. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.026 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.026 Problem: GTK: When using arrow keys to navigate through the menus, the separators are selected. Solution: Set the separators "insensitive". (Pavel Kankovsky) Files: src/gui_gtk.c, src/gui_gtk_x11.c *** ../vim60.25/src/gui_gtk.c Sat Sep 15 18:30:39 2001 --- src/gui_gtk.c Thu Oct 25 10:15:55 2001 *************** *** 453,458 **** --- 453,459 ---- { /* Separator: Just add it */ menu->id = gtk_menu_item_new(); + gtk_widget_set_sensitive(menu->id, FALSE); gtk_widget_show(menu->id); gtk_menu_insert(GTK_MENU(parent->submenu_id), menu->id, idx); *** ../vim60.25/src/gui_gtk_x11.c Wed Sep 19 16:28:57 2001 --- src/gui_gtk_x11.c Thu Oct 25 10:16:39 2001 *************** *** 3571,3576 **** --- 3571,3579 ---- if (menu->id == 0) return; + if (menu_is_separator(menu->name)) + grey = 1; + gui_mch_menu_hidden(menu, FALSE); /* Be clever about bitfields versus true booleans here! */ if (!GTK_WIDGET_SENSITIVE(menu->id) == !grey) *** ../vim60.25/src/version.c Wed Oct 24 19:41:55 2001 --- src/version.c Thu Oct 25 10:19:40 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 26, /**/ -- Eight Megabytes And Continually Swapping. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.027 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.027 Problem: VMS: Printing doesn't work, the file is deleted too quickly. No longer need the VMS specific printing menu. gethostname() is not available with VAXC. The makefile was lacking selection of the tiny-huge feature set. Solution: Adjust the 'printexpr' option default. Fix the other problems and update the documentation. (Zoltan Arpadffy) Files: runtime/doc/os_vms.txt, runtime/menu.vim, src/INSTALLvms.txt, src/Make_vms.mms, src/option.c, src/os_unix.c, src/os_vms_conf.h *** ../vim60.26/runtime/doc/os_vms.txt Tue Sep 25 21:40:37 2001 --- runtime/doc/os_vms.txt Thu Oct 25 16:16:53 2001 *************** *** 1,4 **** ! *os_vms.txt* For Vim version 6.0. Last change: 2001 Sep 03 VIM REFERENCE MANUAL --- 1,4 ---- ! *os_vms.txt* For Vim version 6.0. Last change: 2001 Oct 23 VIM REFERENCE MANUAL *************** *** 43,54 **** You can download precompiled executables from: http://www.polarfox.com/vim/ ============================================================================== 3. Compiling *vms-compiling* ! See the file src/INSTALLvms.txt. ============================================================================== --- 43,55 ---- You can download precompiled executables from: http://www.polarfox.com/vim/ + ftp://ftp.polarhome.com/pub/vim/ ============================================================================== 3. Compiling *vms-compiling* ! See the file [.SRC]INSTALLVMS.TXT. ============================================================================== *************** *** 57,63 **** The code has been tested under Open VMS 6.2 - 7.2 on Alpha and VAX platforms with the DECC compiler. It should work without bigger problems. If it happened that your system does not have some include libraries you can ! tune up in OS_VMS_CONF.H or GUI_VMS_CONF.H files. If you decided to build Vim with +perl, +python, etc. options, first you need to download OpenVMS distributions of Perl and Python. Build and deploy the --- 58,64 ---- The code has been tested under Open VMS 6.2 - 7.2 on Alpha and VAX platforms with the DECC compiler. It should work without bigger problems. If it happened that your system does not have some include libraries you can ! tune up in OS_VMS_CONF.H file. If you decided to build Vim with +perl, +python, etc. options, first you need to download OpenVMS distributions of Perl and Python. Build and deploy the *************** *** 74,79 **** --- 75,83 ---- separately. You have to be prepared that the CTAGS and XXD make files are not always up to date. + CTAGS is not part of Vim source distribution any more, however the OpenVMS + specific source might contain CTAGS source files as it is described above. + Advanced users may try some acrobatics in FEATURE.H file also. It is possible to compile with +xfontset +xim options too, but then you have *************** *** 189,195 **** VMS is not a native X window environment, so you can not start Vim in GUI mode "just like that". But anyhow it is not too complicate to get a running Vim. ! 1) If you are working on the VMS X console: Start Vim with the command: > $ mc device:VIM.EXE -g --- 193,199 ---- VMS is not a native X window environment, so you can not start Vim in GUI mode "just like that". But anyhow it is not too complicate to get a running Vim. ! 1) If you are working on the VMS X/Motif console: Start Vim with the command: > $ mc device:VIM.EXE -g *************** *** 425,430 **** --- 429,435 ---- $define SYS$PRINT HP5ANSI You can print out whole buffer or just the marked area. + More info under :help hardcopy (Zoltan Arpadffy, Vim 6.0c) *************** *** 441,471 **** Without the -GEOMETRY, the GVIM window size will be minimal and the menu will be confused after a window-resize. ! (Coen Engelbarts, <@hotmail.com> Vim 6.0ac) ============================================================================== 9. VMS related changes *vms-changes* ! Version 6.0 (2001 May 29) ! - Unix and VMS code has been merged ! - separated "really" VMS related code ! - included all possible Unix functionality ! - simplified or deleted the configuration files ! - makefile MAKE_VMS.MMS reviewed ! - menu changes (fixed printing, CTAGS and XXD usage) ! - created OS_VMS_FILTER.COM - DECC->VAXC pre-processor directive convert ! script. ! - changed quickfix parameters: ! - errormessage format to suite DECC ! - search, make and other commands to suite VMS system ! - updated and renamed MMS make files for Vim and CTAGS. ! - CTAGS has been removed from source distribution of Vim but it will remain ! in OpenVMS binary distributions. ! - created INSTALLvms.txt - detailed compiling instructions under VMS. ! - updated test scrips. ! - OS_VMS.TXT updated with new features. ! - other minor fixes. Version 5.7 (2000 Jun 24) --- 446,488 ---- Without the -GEOMETRY, the GVIM window size will be minimal and the menu will be confused after a window-resize. ! (Carlo Mekenkamp, Coen Engelbarts, Vim 6.0ac) ============================================================================== 9. VMS related changes *vms-changes* ! Version 6.0 (2001 Sep 28) ! - Unix and VMS code has been merged ! - separated "really" VMS related code ! - included all possible Unix functionality ! - simplified or deleted the configuration files ! - makefile MAKE_VMS.MMS reviewed ! - menu changes (fixed printing, CTAGS and XXD usage) ! - fixed variable RMS record format handling anomaly ! - corrected syntax, ftplugin etc files load ! - changed expand_wildcards and expandpath functions to work more general ! - created OS_VMS_FILTER.COM - DECC->VAXC pre-processor directive convert ! script. ! - Improved code's VAXC and new DECC compilers compatibility ! - changed quickfix parameters: ! - errormessage format to suite DECC ! - search, make and other commands to suite VMS system ! - updated and renamed MMS make files for Vim and CTAGS. ! - CTAGS has been removed from source distribution of Vim but it will remain ! in OpenVMS binary distributions. ! - simplified build/configuration procedure ! - created INSTALLvms.txt - detailed compiling instructions under VMS. ! - updated test scrips. ! - OS_VMS.TXT updated with new features. ! - other minor fixes. ! - documentation updated ! - this version had been tested much more than any other OpenVMS version ! earlier ! ! Version 5.8 (2001 Jun 1) ! - New CTAGS v5.0 in disribution ! - Documentation updated Version 5.7 (2000 Jun 24) *** ../vim60.26/runtime/menu.vim Wed Sep 26 15:24:36 2001 --- runtime/menu.vim Thu Oct 25 16:06:26 2001 *************** *** 2,8 **** " Note that ":amenu" is often used to make a menu work in all modes. " " Maintainer: Bram Moolenaar ! " Last Change: 2001 Sep 21 " Make sure the '<' and 'C' flags are not included in 'cpoptions', otherwise " would not be recognized. See ":help 'cpoptions'". --- 2,8 ---- " Note that ":amenu" is often used to make a menu work in all modes. " " Maintainer: Bram Moolenaar ! " Last Change: 2001 Oct 25 " Make sure the '<' and 'C' flags are not included in 'cpoptions', otherwise " would not be recognized. See ":help 'cpoptions'". *************** *** 106,133 **** amenu 10.510 &File.&Print :w !lpr vunmenu &File.&Print vmenu &File.&Print :w !lpr - elseif has("vms") - amenu 10.500 &File.-SEP3- : - amenu 10.510 &File.&Print :call VMSPrint(":") - vunmenu &File.&Print - vmenu &File.&Print :call VMSPrint(":'<,'>") endif amenu 10.600 &File.-SEP4- : amenu 10.610 &File.Sa&ve-Exit:wqa :confirm wqa amenu 10.620 &File.E&xit:qa :confirm qa - if has("vms") - if !exists("*VMSPrint") - fun VMSPrint(range) - let mod_save = &mod - let ttt = tempname() - exec a:range . "w! " . ttt - let &mod = mod_save - exec "!print/delete " . ttt - endfun - endif - endif - " Tricky stuff to make pasting work as expected. nnoremap Paste "=@+.'xy'gPFx"_2x:echo --- 106,116 ---- *************** *** 730,739 **** amenu 1.40 ToolBar.Print :w !lpr vunmenu ToolBar.Print vmenu ToolBar.Print :w !lpr - elseif has("vms") - amenu 1.40 ToolBar.Print :call VMSPrint(":") - vunmenu ToolBar.Print - vmenu ToolBar.Print :call VMSPrint(":'<,'>") endif amenu 1.45 ToolBar.-sep1- --- 713,718 ---- *** ../vim60.26/src/INSTALLvms.txt Sat Jul 28 14:07:56 2001 --- src/INSTALLvms.txt Thu Oct 25 12:26:38 2001 *************** *** 1,5 **** INSTALLvms.txt - Installation of Vim on OpenVMS ! Last change: 2001 Jul 28 This file contains instructions for compiling Vim. If you already have an executable version of Vim, you don't need this. --- 1,5 ---- INSTALLvms.txt - Installation of Vim on OpenVMS ! Last change: 2001 Oct 12 This file contains instructions for compiling Vim. If you already have an executable version of Vim, you don't need this. *************** *** 45,50 **** --- 45,54 ---- 1.5. If you want to have Perl, Python or Tcl support in Vim you will need VMS distributions for them as well. + NOTE: procedure in chapter 1 describes source code preparation from multi OS code, + however it is available OpenVMS oprimized (and tested) source code from: + ftp://ftp.polarhome.com/pub/vim/source/vms/ + 2. Configuration 2.1. Edit vim-X.X/src/feature.h for your preference. (You can skip *************** *** 56,61 **** --- 60,75 ---- 2.2 Edit vim-X.X/src/Make_vms.mms to customise your Vim. Options are: + Parameter name : MODEL + Description : Build model selection + Options: : TINY - Almost no features enabled, not even multiple windows + SMALL - Few features enabled, as basic as possible + NORMAL - A default selection of features enabled + BIG - Many features enabled, as rich as possible. (OpenVMS default) + HUGE - All possible featues enabled. + Uncommented - will default to BIG + Default : MODEL = BIG + Parameter name : GUI Description : GUI or terminal mode executable Options: : YES - GUI executable *************** *** 98,103 **** --- 112,139 ---- Uncommented - build without support. Default : Uncommented + + Parameter name : VIM_XIM + Description : X Input Method. For entering special languages like chinese and + Japanese. Please define just one: VIM_XIM or VIM_HANGULIN + Options: : YES - Build with support + Uncommented - build without support. + Default : Uncommented + + Parameter name : VIM_HANGULIN + Description : Internal Hangul input method. GUI only. + Please define just one: VIM_XIM or VIM_HANGULIN + Options: : YES - Build with support + Uncommented - build without support. + Default : Uncommented + + Parameter name : VIM_TAG_ANYWHITE + Description : Allow any white space to separate the fields in a tags file + When not defined, only a TAB is allowed. + Options: : YES - Build with support + Uncommented - build without support. + Default : Uncommented + You can edit the *_INC and *_LIB qualifiers, but it is really not recommended for beginners. *************** *** 128,133 **** --- 164,173 ---- @os_vms_fix.com *.c *.h <.proto>*.pro more information can be found in os_vms_fix.com file itself. + + NOTE: even if os_vms_fix.com will fix all pre-processor directives it will + leave singe (long) line directives. You have to fix them manually. + Known problematic files are option.h and option.c 4.2. After the conversion you can continue building as it has been described above. *** ../vim60.26/src/Make_vms.mms Sun Sep 16 16:18:13 2001 --- src/Make_vms.mms Wed Oct 24 17:06:38 2001 *************** *** 2,8 **** # Makefile for Vim on OpenVMS # # Maintainer: Zoltan Arpadffy ! # Last change: 2001 Sep 16 # # This has script been tested on VMS 6.2 to 7.2 on DEC Alpha and VAX # with MMS and MMK --- 2,8 ---- # Makefile for Vim on OpenVMS # # Maintainer: Zoltan Arpadffy ! # Last change: 2001 Oct 12 # # This has script been tested on VMS 6.2 to 7.2 on DEC Alpha and VAX # with MMS and MMK *************** *** 16,25 **** --- 16,36 ---- # To build: mms/descrip=Make_vms.mms # To clean up: mms/descrip=Make_vms.mms clean # + # Hints and detailed description could be found in INSTALLVMS.TXT file. + # ###################################################################### # Configuration section. ###################################################################### + # Build model selection + # TINY - Almost no features enabled, not even multiple windows + # SMALL - Few features enabled, as basic as possible + # NORMAL - A default selection of features enabled + # BIG - Many features enabled, as rich as possible. (default) + # HUGE - All possible featues enabled. + # Please select one of these alternatives above. + MODEL = BIG + # GUI or terminal mode executable. # Comment out if you want just the character terminal mode only. GUI = YES *************** *** 56,61 **** --- 67,76 ---- # If you don't need it really, leave it behind the comment. # VIM_HANGULIN = YES + # Allow any white space to separate the fields in a tags file + # When not defined, only a TAB is allowed. + # VIM_TAG_ANYWHITE = YES + ###################################################################### # Directory, library and include files configuration section. # Normally you need not to change anything below. ! *************** *** 145,150 **** --- 160,170 ---- .ENDIF .ENDIF + .IFDEF VIM_TAG_ANYWHITE + # TAG_ANYWHITE related setup. + TAG_DEF = ,"FEAT_TAG_ANYWHITE" + .ENDIF + ###################################################################### # End of configuration section. # Please, do not change anything below without programming experience. *************** *** 174,186 **** LDFLAGS = .ENDIF # These go into pathdef.c VIMUSER = "''f$extract(f$locate(",",f$user())+1,f$length(f$user())-f$locate(",",f$user())-2,f$user())'" VIMHOST = "''f$trnlnm("sys$node")'''f$trnlnm("ucx$inet_host")'.''f$trnlnm("ucx$inet_domain")'" .SUFFIXES : .obj .c ! ALL_CFLAGS = /def=($(DEFS) $(DEBUG_DEF) $(PERL_DEF) $(PYTHON_DEF) $(TCL_DEF) $(SNIFF_DEF) $(RUBY_DEF) $(XIM_DEF) $(HANGULIN_DEF)) $(CFLAGS) ALL_LIBS = $(LIBS) $(GUI_LIB_DIR) $(X_LIB_DIR) $(GUI_LIB) $(X_LIB) $(EXTRA_LIB)\ $(PERL_LIB) $(PYTHON_LIB) $(TCL_LIB) $(SNIFF_LIB) $(RUBY_LIB) --- 194,208 ---- LDFLAGS = .ENDIF + MODEL_DEF = "FEAT_$(MODEL)", + # These go into pathdef.c VIMUSER = "''f$extract(f$locate(",",f$user())+1,f$length(f$user())-f$locate(",",f$user())-2,f$user())'" VIMHOST = "''f$trnlnm("sys$node")'''f$trnlnm("ucx$inet_host")'.''f$trnlnm("ucx$inet_domain")'" .SUFFIXES : .obj .c ! ALL_CFLAGS = /def=($(MODEL_DEF)$(DEFS)$(DEBUG_DEF)$(PERL_DEF)$(PYTHON_DEF)$(TCL_DEF)$(SNIFF_DEF)$(RUBY_DEF)$(XIM_DEF)$(HANGULIN_DEF)$(TAG_DEF)) $(CFLAGS) ALL_LIBS = $(LIBS) $(GUI_LIB_DIR) $(X_LIB_DIR) $(GUI_LIB) $(X_LIB) $(EXTRA_LIB)\ $(PERL_LIB) $(PYTHON_LIB) $(TCL_LIB) $(SNIFF_LIB) $(RUBY_LIB) *** ../vim60.26/src/option.c Mon Oct 22 21:19:00 2001 --- src/option.c Thu Oct 25 15:59:13 2001 *************** *** 2515,2521 **** (char_u *)"system('copy' . ' ' . v:fname_in . ' ' . &printdevice) . delete(v:fname_in)" # else # ifdef VMS ! (char_u *)"system('print' . (&printdevice == '' ? '' : ' /queue=' . &printdevice) . ' ' . v:fname_in) . delete(v:fname_in)" # else (char_u *)"system('lpr' . (&printdevice == '' ? '' : ' -P' . &printdevice) . ' ' . v:fname_in) . delete(v:fname_in) + v:shell_error" --- 2515,2521 ---- (char_u *)"system('copy' . ' ' . v:fname_in . ' ' . &printdevice) . delete(v:fname_in)" # else # ifdef VMS ! (char_u *)"system('print/delete' . (&printdevice == '' ? '' : ' /queue=' . &printdevice) . ' ' . v:fname_in)" # else (char_u *)"system('lpr' . (&printdevice == '' ? '' : ' -P' . &printdevice) . ' ' . v:fname_in) . delete(v:fname_in) + v:shell_error" *** ../vim60.26/src/os_unix.c Fri Sep 21 20:08:36 2001 --- src/os_unix.c Thu Oct 25 16:09:46 2001 *************** *** 1793,1799 **** --- 1793,1803 ---- char_u *s; int len; { + # ifdef VAXC + vaxc$gethostname((char *)s, len); + # else gethostname((char *)s, len); + # endif } #endif /* HAVE_SYS_UTSNAME_H */ *** ../vim60.26/src/os_vms_conf.h Mon Aug 27 17:29:49 2001 --- src/os_vms_conf.h Thu Oct 25 11:43:42 2001 *************** *** 86,93 **** /* Define if struct sigcontext is present */ #define HAVE_SIGCONTEXT ! /* Define if touuper/tolower only work on lower/upercase characters */ ! /* #undef BROKEN_TOUPPER */ /* Define if tgetstr() has a second argument that is (char *) */ /* #undef TGETSTR_CHAR_P */ --- 86,93 ---- /* Define if struct sigcontext is present */ #define HAVE_SIGCONTEXT ! /* Define if toupper/tolower only work on lower/upercase characters */ ! /* #define BROKEN_TOUPPER */ /* Define if tgetstr() has a second argument that is (char *) */ /* #undef TGETSTR_CHAR_P */ *************** *** 105,111 **** /* #undef HAVE_SIGSET */ #define HAVE_GETCWD - #define HAVE_SELECT #define HAVE_STRCSPN #define HAVE_STRTOL #define HAVE_TGETENT --- 105,110 ---- *************** *** 118,124 **** #define HAVE_FSYNC #define HAVE_GETPWUID #define HAVE_GETPWNAM - #define HAVE_SELECT #define HAVE_STDLIB_H #define HAVE_STRING_H #define HAVE_ERRNO_H --- 117,122 ---- *************** *** 134,146 **** #undef HAVE_UNION_WAIT #undef HAVE_SYS_SELECT_H #undef HAVE_SYS_UTSNAME_H #undef HAVE_TERMCAP_H #undef HAVE_SGTTY_H #undef HAVE_SYS_IOCTL_H #undef HAVE_TERMIO_H #undef HAVE_STROPTS_H - #undef HAVE_STRINGS_H - #undef HAVE_SYS_SYSTEMINFO_H #undef HAVE_SYS_STREAM_H #undef HAVE_SYS_PTEM_H #undef HAVE_TERMIOS_H --- 132,143 ---- #undef HAVE_UNION_WAIT #undef HAVE_SYS_SELECT_H #undef HAVE_SYS_UTSNAME_H + #undef HAVE_SYS_SYSTEMINFO_H #undef HAVE_TERMCAP_H #undef HAVE_SGTTY_H #undef HAVE_SYS_IOCTL_H #undef HAVE_TERMIO_H #undef HAVE_STROPTS_H #undef HAVE_SYS_STREAM_H #undef HAVE_SYS_PTEM_H #undef HAVE_TERMIOS_H *************** *** 150,185 **** #undef HAVE_PWD_H #undef HAVE_FCHDIR ! #ifdef VAX #undef HAVE_GETTIMEOFDAY #undef HAVE_USLEEP #undef HAVE_STRCASECMP #else #define HAVE_GETTIMEOFDAY #define HAVE_USLEEP ! #undef HAVE_STRCASECMP #endif #ifdef VAXC #undef HAVE_FCNTL_H #undef HAVE_UNISTD_H #undef HAVE_SYS_TIME_H #undef HAVE_LOCALE_H #define BROKEN_LOCALE #else #define HAVE_FCNTL_H #define HAVE_UNISTD_H 1 #define HAVE_SYS_TIME_H #define HAVE_LOCALE_H #endif ! #ifdef FEAT_GUI_MOTIF ! /* Define unless no X support found */ #define HAVE_X11 - - /* Define if you want to include fontset support. */ #define USE_FONTSET ! ! /* Define if your X has own locale library */ ! /* #undef X_LOCALE */ #endif --- 147,191 ---- #undef HAVE_PWD_H #undef HAVE_FCHDIR ! /* Hardware specific */ ! #ifdef VAX #undef HAVE_GETTIMEOFDAY #undef HAVE_USLEEP #undef HAVE_STRCASECMP + #undef HAVE_STRINGS_H #else #define HAVE_GETTIMEOFDAY #define HAVE_USLEEP ! #define HAVE_STRCASECMP ! #define HAVE_STRINGS_H #endif + /* Compiler specific */ #ifdef VAXC + #undef HAVE_SELECT #undef HAVE_FCNTL_H #undef HAVE_UNISTD_H #undef HAVE_SYS_TIME_H #undef HAVE_LOCALE_H #define BROKEN_LOCALE + #undef HAVE_ICONV_H + #undef HAVE_ICONV + #undef DYNAMIC_ICONV #else + #define HAVE_SELECT #define HAVE_FCNTL_H #define HAVE_UNISTD_H 1 #define HAVE_SYS_TIME_H #define HAVE_LOCALE_H + #define BROKEN_LOCALE + #undef HAVE_ICONV_H + #undef HAVE_ICONV + #undef DYNAMIC_ICONV #endif ! /* GUI support defines */ ! #ifdef FEAT_GUI_MOTIF #define HAVE_X11 #define USE_FONTSET ! #undef X_LOCALE #endif *** ../vim60.26/src/version.c Thu Oct 25 10:20:46 2001 --- src/version.c Thu Oct 25 16:30:38 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 27, /**/ -- Just think of all the things we haven't thought of yet. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.028 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.028 Problem: Can't compile without +virtualedit and with +visualextra. (Geza Lakner) Solution: Add an #ifdef for +virtualedit. Files: src/ops.c *** ../vim60.27/src/ops.c Wed Sep 19 12:39:06 2001 --- src/ops.c Sun Oct 28 16:38:35 2001 *************** *** 2134,2140 **** if (oap->op_type == OP_APPEND) { ! if (oap->block_mode && curwin->w_cursor.coladd == 0) { /* this lil bit if code adapted from nv_append() */ curwin->w_set_curswant = TRUE; --- 2135,2145 ---- if (oap->op_type == OP_APPEND) { ! if (oap->block_mode ! #ifdef FEAT_VIRTUALEDIT ! && curwin->w_cursor.coladd == 0 ! #endif ! ) { /* this lil bit if code adapted from nv_append() */ curwin->w_set_curswant = TRUE; *** ../vim60.27/src/version.c Thu Oct 25 16:34:24 2001 --- src/version.c Sun Oct 28 16:40:22 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 28, /**/ -- ARTHUR: You fight with the strength of many men, Sir knight. I am Arthur, King of the Britons. [pause] I seek the finest and the bravest knights in the land to join me in my Court of Camelot. [pause] You have proved yourself worthy; will you join me? [pause] You make me sad. So be it. Come, Patsy. BLACK KNIGHT: None shall pass. The Quest for the Holy Grail (Monty Python) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.029 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.029 Problem: When making a change in line 1, then in line 2 and then deleting line 1, undo info could be wrong. Only when the changes are undone at once. (Gerhard Hochholzer) Solution: When not saving a line for undo because it was already done before, remember for which entry the last line must be computed. Added ue_getbot_entry pointer for this. When the number of lines changes, adjust the position of newer undo entries. Files: src/structs.h, src/undo.c *** ../vim60.28/src/structs.h Sun Sep 16 14:45:18 2001 --- src/structs.h Sun Oct 28 20:08:24 2001 *************** *** 232,237 **** --- 232,238 ---- u_header_T *uh_next; /* pointer to next header in list */ u_header_T *uh_prev; /* pointer to previous header in list */ u_entry_T *uh_entry; /* pointer to first entry */ + u_entry_T *uh_getbot_entry; /* pointer to where ue_bot must be set */ pos_T uh_cursor; /* cursor position before saving */ #ifdef FEAT_VIRTUALEDIT long uh_cursor_vcol; *** ../vim60.28/src/undo.c Fri Aug 24 09:57:23 2001 --- src/undo.c Sun Oct 28 21:03:26 2001 *************** *** 224,229 **** --- 224,230 ---- if (curbuf->b_u_newhead != NULL) curbuf->b_u_newhead->uh_prev = uhp; uhp->uh_entry = NULL; + uhp->uh_getbot_entry = NULL; uhp->uh_cursor = curwin->w_cursor; /* save cursor pos. for undo */ #ifdef FEAT_VIRTUALEDIT if (virtual_active() && curwin->w_cursor.coladd > 0) *************** *** 263,269 **** break; /* If lines have been inserted/deleted we give up. */ ! if (uep->ue_lcount == 0 ? (uep->ue_top + uep->ue_size + 1 != (uep->ue_bot == 0 ? curbuf->b_ml.ml_line_count + 1 --- 264,270 ---- break; /* If lines have been inserted/deleted we give up. */ ! if (curbuf->b_u_newhead->uh_getbot_entry != uep ? (uep->ue_top + uep->ue_size + 1 != (uep->ue_bot == 0 ? curbuf->b_ml.ml_line_count + 1 *************** *** 274,287 **** /* If it's the same line we can skip saving it again. */ if (uep->ue_size == 1 && uep->ue_top == top) { ! /* The line count might change. */ ! uep->ue_lcount = 0; if (newbot != 0) uep->ue_bot = newbot; else if (bot > curbuf->b_ml.ml_line_count) uep->ue_bot = 0; else uep->ue_lcount = curbuf->b_ml.ml_line_count; return OK; } uep = uep->ue_next; --- 275,313 ---- /* If it's the same line we can skip saving it again. */ if (uep->ue_size == 1 && uep->ue_top == top) { ! /* If it's not the last entry, get ue_bot for the last ! * entry now. Following deleted/inserted lines go to the ! * re-used entry. */ ! if (i > 0) ! u_getbot(); ! ! /* The line count might change afterwards. */ if (newbot != 0) + { + /* When changing the line count and it's not the + * newest entry, must adjust the line numbers of older + * entries. */ + if (uep != curbuf->b_u_newhead->uh_entry + && uep->ue_bot != newbot) + { + u_entry_T *p; + + for (p = curbuf->b_u_newhead->uh_entry; + p != uep; p = p->ue_next) + { + p->ue_bot -= uep->ue_bot - newbot; + p->ue_top -= uep->ue_bot - newbot; + } + } uep->ue_bot = newbot; + } else if (bot > curbuf->b_ml.ml_line_count) uep->ue_bot = 0; else + { uep->ue_lcount = curbuf->b_ml.ml_line_count; + curbuf->b_u_newhead->uh_getbot_entry = uep; + } return OK; } uep = uep->ue_next; *************** *** 310,316 **** uep->ue_size = size; uep->ue_top = top; - uep->ue_lcount = 0; if (newbot) uep->ue_bot = newbot; /* --- 336,341 ---- *************** *** 320,326 **** --- 345,354 ---- else if (bot > curbuf->b_ml.ml_line_count) uep->ue_bot = 0; else + { uep->ue_lcount = curbuf->b_ml.ml_line_count; + curbuf->b_u_newhead->uh_getbot_entry = uep; + } if (size) { *************** *** 732,751 **** u_getbot() { u_entry_T *uep; ! uep = u_get_headentry(); if (uep == NULL) return; ! if (uep->ue_lcount != 0) { /* * the new ue_bot is computed from the number of lines that has been * inserted (0 - deleted) since calling u_save. This is equal to the old * line count subtracted from the current line count. */ ! uep->ue_bot = uep->ue_top + uep->ue_size + 1 + ! (curbuf->b_ml.ml_line_count - uep->ue_lcount); if (uep->ue_bot < 1 || uep->ue_bot > curbuf->b_ml.ml_line_count) { EMSG(_("E440: undo line missing")); --- 760,781 ---- u_getbot() { u_entry_T *uep; + linenr_T extra; ! uep = u_get_headentry(); /* check for corrupt undo list */ if (uep == NULL) return; ! uep = curbuf->b_u_newhead->uh_getbot_entry; ! if (uep != NULL) { /* * the new ue_bot is computed from the number of lines that has been * inserted (0 - deleted) since calling u_save. This is equal to the old * line count subtracted from the current line count. */ ! extra = curbuf->b_ml.ml_line_count - uep->ue_lcount; ! uep->ue_bot = uep->ue_top + uep->ue_size + 1 + extra; if (uep->ue_bot < 1 || uep->ue_bot > curbuf->b_ml.ml_line_count) { EMSG(_("E440: undo line missing")); *************** *** 754,760 **** * without deleting the current * ones */ } ! uep->ue_lcount = 0; } curbuf->b_u_synced = TRUE; --- 784,802 ---- * without deleting the current * ones */ } ! ! /* If not the newest entry and lines have been inserted or deleted, ! * newer entries must have their line numbers adjusted. */ ! if (extra != 0) ! for (uep = curbuf->b_u_newhead->uh_entry; ! uep != curbuf->b_u_newhead->uh_getbot_entry; ! uep = uep->ue_next) ! { ! uep->ue_bot -= extra; ! uep->ue_top -= extra; ! } ! ! curbuf->b_u_newhead->uh_getbot_entry = NULL; } curbuf->b_u_synced = TRUE; *** ../vim60.28/src/version.c Sun Oct 28 16:41:29 2001 --- src/version.c Sun Oct 28 21:11:52 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 29, /**/ -- f y cn rd ths thn y cn hv grt jb n cmptr prgrmmng /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.030 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.030 Problem: Using ":source! file" doesn't work inside a loop or after ":argdo". (Pavol Juhas) Solution: Execute the commands in the file right away, do not let the main loop do it. Files: src/ex_cmds2.c, src/ex_docmd.c, src/getchar.c, src/globals.h, src/proto/ex_docmd.pro, src/proto/getchar.pro *** ../vim60.29/src/ex_cmds2.c Tue Sep 25 14:18:04 2001 --- src/ex_cmds2.c Thu Oct 25 10:08:24 2001 *************** *** 14,20 **** #include "vim.h" #include "version.h" ! static void cmd_source __ARGS((char_u *fname, int forceit)); #if defined(FEAT_EVAL) || defined(PROTO) --- 14,20 ---- #include "vim.h" #include "version.h" ! static void cmd_source __ARGS((char_u *fname, exarg_T *eap)); #if defined(FEAT_EVAL) || defined(PROTO) *************** *** 1454,1461 **** --- 1454,1463 ---- #endif /* execute the command */ + listcmd_busy = TRUE; do_cmdline(eap->arg, eap->getline, eap->cookie, DOCMD_VERBOSE + DOCMD_NOWAIT); + listcmd_busy = FALSE; if (eap->cmdidx == CMD_bufdo) { *************** *** 1693,1699 **** ex_options(eap) exarg_T *eap; { ! cmd_source((char_u *)SYS_OPTWIN_FILE, FALSE); } #endif --- 1695,1701 ---- ex_options(eap) exarg_T *eap; { ! cmd_source((char_u *)SYS_OPTWIN_FILE, NULL); } #endif *************** *** 1713,1737 **** NULL, NULL, eap->arg, BROWSE_FILTER_MACROS, curbuf); if (fname != NULL) { ! cmd_source(fname, eap->forceit); vim_free(fname); } } else #endif ! cmd_source(eap->arg, eap->forceit); } static void ! cmd_source(fname, forceit) char_u *fname; ! int forceit; { if (*fname == NUL) EMSG(_(e_argreq)); ! else if (forceit) /* :so! read vi commands */ ! (void)openscript(fname); ! /* :so read ex commands */ else if (do_source(fname, FALSE, FALSE) == FAIL) EMSG2(_(e_notopen), fname); } --- 1715,1752 ---- NULL, NULL, eap->arg, BROWSE_FILTER_MACROS, curbuf); if (fname != NULL) { ! cmd_source(fname, eap); vim_free(fname); } } else #endif ! cmd_source(eap->arg, eap); } static void ! cmd_source(fname, eap) char_u *fname; ! exarg_T *eap; { if (*fname == NUL) EMSG(_(e_argreq)); ! ! /* ":source!" read vi commands */ ! else if (eap != NULL && eap->forceit) ! /* Need to execute the commands directly when: ! * - ":g" command busy ! * - after ":argdo", ":windo" or ":bufdo" ! * - another command follows ! * - inside a loop ! */ ! openscript(fname, global_busy || listcmd_busy || eap->nextcmd != NULL ! #ifdef FEAT_EVAL ! || eap->cstack->cs_idx >= 0 ! #endif ! ); ! ! /* ":source" read ex commands */ else if (do_source(fname, FALSE, FALSE) == FAIL) EMSG2(_(e_notopen), fname); } *** ../vim60.29/src/ex_docmd.c Fri Oct 19 11:18:45 2001 --- src/ex_docmd.c Sat Oct 20 16:53:27 2001 *************** *** 276,282 **** #endif #ifdef FEAT_EX_EXTRA static void ex_normal __ARGS((exarg_T *eap)); - static void update_topline_cursor __ARGS((void)); static void ex_startinsert __ARGS((exarg_T *eap)); #else # define ex_normal ex_ni --- 276,281 ---- *************** *** 6777,6782 **** --- 6776,6794 ---- } } + /* + * Update w_topline, w_leftcol and the cursor position. + */ + void + update_topline_cursor() + { + check_cursor(); /* put cursor on valid line */ + update_topline(); + if (!curwin->w_p_wrap) + validate_cursor(); + update_curswant(); + } + #ifdef FEAT_EX_EXTRA /* * ":normal[!] {commands}": Execute normal mode commands. *************** *** 6937,6955 **** #ifdef FEAT_MBYTE vim_free(arg); #endif - } - - /* - * Update w_topline, w_leftcol and the cursor position. - */ - static void - update_topline_cursor() - { - check_cursor(); /* put cursor on valid line */ - update_topline(); - if (!curwin->w_p_wrap) - validate_cursor(); - update_curswant(); } /* --- 6949,6954 ---- *** ../vim60.29/src/getchar.c Sun Sep 16 14:38:55 2001 --- src/getchar.c Sat Oct 20 18:07:04 2001 *************** *** 1224,1244 **** } /* ! * open new script file for ":so!" command ! * return OK on success, FAIL on error */ ! int ! openscript(name) ! char_u *name; { - int oldcurscript; - oparg_T oa; - int save_State; - if (curscript + 1 == NSCRIPT) { EMSG(_(e_nesting)); ! return FAIL; } if (scriptin[curscript] != NULL) /* already reading script */ --- 1224,1240 ---- } /* ! * Open a new script file for the ":source!" command. */ ! void ! openscript(name, directly) ! char_u *name; ! int directly; /* when TRUE execute directly */ { if (curscript + 1 == NSCRIPT) { EMSG(_(e_nesting)); ! return; } if (scriptin[curscript] != NULL) /* already reading script */ *************** *** 1250,1281 **** EMSG2(_(e_notopen), name); if (curscript) --curscript; ! return FAIL; } if (save_typebuf() == FAIL) ! return FAIL; /* ! * With command ":g/pat/so! file" we have to execute the ! * commands from the file now. */ ! if (global_busy) { ! clear_oparg(&oa); ! save_State = State; State = NORMAL; oldcurscript = curscript; do { ! check_cursor(); /* put cursor on an existing line */ ! normal_cmd(&oa, FALSE); ! vpeekc(); /* check for end of file */ } while (scriptin[oldcurscript] != NULL); State = save_State; } - - return OK; } /* --- 1246,1294 ---- EMSG2(_(e_notopen), name); if (curscript) --curscript; ! return; } if (save_typebuf() == FAIL) ! return; /* ! * Execute the commands from the file right now when using ":source!" ! * after ":global" or ":argdo" or in a loop. Also when another command ! * follows. This means the display won't be updated. Don't do this ! * always, "make test" would fail. */ ! if (directly) { ! oparg_T oa; ! int oldcurscript; ! int save_State = State; ! int save_restart_edit = restart_edit; ! int save_insertmode = p_im; ! int save_finish_op = finish_op; ! int save_msg_scroll = msg_scroll; ! State = NORMAL; + msg_scroll = FALSE; /* no msg scrolling in Normal mode */ + restart_edit = 0; /* don't go to Insert mode */ + p_im = FALSE; /* don't use 'insertmode' */ + clear_oparg(&oa); + finish_op = FALSE; + oldcurscript = curscript; do { ! update_topline_cursor(); /* update cursor position and topline */ ! normal_cmd(&oa, FALSE); /* execute one command */ ! vpeekc(); /* check for end of file */ } while (scriptin[oldcurscript] != NULL); + State = save_State; + msg_scroll = save_msg_scroll; + restart_edit = save_restart_edit; + p_im = save_insertmode; + finish_op = save_finish_op; } } /* *** ../vim60.29/src/globals.h Fri Sep 28 22:19:57 2001 --- src/globals.h Sat Oct 20 17:49:38 2001 *************** *** 752,757 **** --- 752,759 ---- /* set after swap write error msg */ EXTERN int undo_off INIT(= FALSE); /* undo switched off for now */ EXTERN int global_busy INIT(= 0); /* set when :global is executing */ + EXTERN int listcmd_busy INIT(= FALSE); /* set when :argdo, :windo or + :bufdo is executing */ EXTERN int need_start_insertmode INIT(= FALSE); /* start insert mode soon */ EXTERN char_u *last_cmdline INIT(= NULL); /* last command line (for ":) */ *** ../vim60.29/src/proto/ex_docmd.pro Tue Sep 25 21:49:13 2001 --- src/proto/ex_docmd.pro Sat Oct 20 16:55:04 2001 *************** *** 29,34 **** --- 29,35 ---- void do_exedit __ARGS((exarg_T *eap, win_T *old_curwin)); void do_sleep __ARGS((long msec)); FILE *open_exfile __ARGS((char_u *fname, int forceit, char *mode)); + void update_topline_cursor __ARGS((void)); char_u *eval_vars __ARGS((char_u *src, int *usedlen, linenr_T *lnump, char_u **errormsg, char_u *srcstart)); char_u *expand_sfile __ARGS((char_u *arg)); int put_eol __ARGS((FILE *fd)); *** ../vim60.29/src/proto/getchar.pro Tue Sep 25 21:49:15 2001 --- src/proto/getchar.pro Sat Oct 20 17:23:58 2001 *************** *** 26,32 **** int alloc_typebuf __ARGS((void)); void free_typebuf __ARGS((void)); int save_typebuf __ARGS((void)); ! int openscript __ARGS((char_u *name)); int using_script __ARGS((void)); void updatescript __ARGS((int c)); int vgetc __ARGS((void)); --- 26,32 ---- int alloc_typebuf __ARGS((void)); void free_typebuf __ARGS((void)); int save_typebuf __ARGS((void)); ! void openscript __ARGS((char_u *name, int directly)); int using_script __ARGS((void)); void updatescript __ARGS((int c)); int vgetc __ARGS((void)); *** ../vim60.29/src/version.c Sun Oct 28 21:15:32 2001 --- src/version.c Sun Oct 28 21:17:56 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 30, /**/ -- BLACK KNIGHT: I move for no man. ARTHUR: So be it! [hah] [parry thrust] [ARTHUR chops the BLACK KNIGHT's left arm off] ARTHUR: Now stand aside, worthy adversary. BLACK KNIGHT: 'Tis but a scratch. The Quest for the Holy Grail (Monty Python) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.031 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.031 Problem: Nextstep doesn't have setenv() or putenv(). (John Beppu) Solution: Move putenv() from pty.c to misc2.c Files: src/misc2.c, src/pty.c *** ../vim60.30/src/misc2.c Sun Sep 30 10:53:07 2001 --- src/misc2.c Sun Oct 28 21:49:00 2001 *************** *** 5186,5188 **** --- 5187,5364 ---- #endif /*FEAT_PRINTER*/ + + /* + * The putenv() implementation below comes from the "screen" program. + * Included with permission from Juergen Weigert. + * See pty.c for the copyright notice. + */ + + /* + * putenv -- put value into environment + * + * Usage: i = putenv (string) + * int i; + * char *string; + * + * where string is of the form =. + * Putenv returns 0 normally, -1 on error (not enough core for malloc). + * + * Putenv may need to add a new name into the environment, or to + * associate a value longer than the current value with a particular + * name. So, to make life simpler, putenv() copies your entire + * environment into the heap (i.e. malloc()) from the stack + * (i.e. where it resides when your process is initiated) the first + * time you call it. + * + * (history removed, not very interesting. See the "screen" sources.) + */ + + #if !defined(HAVE_SETENV) && !defined(HAVE_PUTENV) + + #define EXTRASIZE 5 /* increment to add to env. size */ + + static int envsize = -1; /* current size of environment */ + #ifndef MACOS + extern + #endif + char **environ; /* the global which is your env. */ + + static int findenv __ARGS((char *name)); /* look for a name in the env. */ + static int newenv __ARGS((void)); /* copy env. from stack to heap */ + static int moreenv __ARGS((void)); /* incr. size of env. */ + + int + putenv(string) + const char *string; + { + int i; + char *p; + + if (envsize < 0) + { /* first time putenv called */ + if (newenv() < 0) /* copy env. to heap */ + return -1; + } + + i = findenv((char *)string); /* look for name in environment */ + + if (i < 0) + { /* name must be added */ + for (i = 0; environ[i]; i++); + if (i >= (envsize - 1)) + { /* need new slot */ + if (moreenv() < 0) + return -1; + } + p = (char *)alloc((unsigned)(strlen(string) + 1)); + if (p == NULL) /* not enough core */ + return -1; + environ[i + 1] = 0; /* new end of env. */ + } + else + { /* name already in env. */ + p = vim_realloc(environ[i], strlen(string) + 1); + if (p == NULL) + return -1; + } + sprintf(p, "%s", string); /* copy into env. */ + environ[i] = p; + + return 0; + } + + static int + findenv(name) + char *name; + { + char *namechar, *envchar; + int i, found; + + found = 0; + for (i = 0; environ[i] && !found; i++) + { + envchar = environ[i]; + namechar = name; + while (*namechar && *namechar != '=' && (*namechar == *envchar)) + { + namechar++; + envchar++; + } + found = ((*namechar == '\0' || *namechar == '=') && *envchar == '='); + } + return found ? i - 1 : -1; + } + + static int + newenv() + { + char **env, *elem; + int i, esize; + + #ifdef MACOS + /* for Mac a new, empty environment is created */ + i = 0; + #else + for (i = 0; environ[i]; i++) + ; + #endif + esize = i + EXTRASIZE + 1; + env = (char **)alloc((unsigned)(esize * sizeof (elem))); + if (env == NULL) + return -1; + + #ifndef MACOS + for (i = 0; environ[i]; i++) + { + elem = (char *)alloc((unsigned)(strlen(environ[i]) + 1)); + if (elem == NULL) + return -1; + env[i] = elem; + strcpy(elem, environ[i]); + } + #endif + + env[i] = 0; + environ = env; + envsize = esize; + return 0; + } + + static int + moreenv() + { + int esize; + char **env; + + esize = envsize + EXTRASIZE; + env = (char **)vim_realloc((char *)environ, esize * sizeof (*env)); + if (env == 0) + return -1; + environ = env; + envsize = esize; + return 0; + } + + # ifdef USE_VIMPTY_GETENV + char_u * + vimpty_getenv(string) + const char_u *string; + { + int i; + char_u *p; + + if (envsize < 0) + return NULL; + + i = findenv((char *)string); + + if (i < 0) + return NULL; + + p = vim_strchr((char_u *)environ[i], '='); + return (p + 1); + } + # endif + + #endif /* !defined(HAVE_SETENV) && !defined(HAVE_PUTENV) */ *** ../vim60.30/src/pty.c Sat Jul 28 12:34:41 2001 --- src/pty.c Sun Oct 28 21:46:44 2001 *************** *** 9,15 **** /* * The stuff in this file mostly comes from the "screen" program. * Included with permission from Juergen Weigert. ! * Copied from "pty.c" and "putenv.c". * * It has been modified to work better with Vim. * The parts that are not used in Vim have been deleted. --- 9,15 ---- /* * The stuff in this file mostly comes from the "screen" program. * Included with permission from Juergen Weigert. ! * Copied from "pty.c". "putenv.c" was used for putenv() in misc2.c. * * It has been modified to work better with Vim. * The parts that are not used in Vim have been deleted. *************** *** 423,597 **** return -1; } #endif - - /* putenv.c */ - - /* - * putenv -- put value into environment - * - * Usage: i = putenv (string) - * int i; - * char *string; - * - * where string is of the form =. - * Putenv returns 0 normally, -1 on error (not enough core for malloc). - * - * Putenv may need to add a new name into the environment, or to - * associate a value longer than the current value with a particular - * name. So, to make life simpler, putenv() copies your entire - * environment into the heap (i.e. malloc()) from the stack - * (i.e. where it resides when your process is initiated) the first - * time you call it. - * - * (history removed, not very interesting. See the "screen" sources.) - */ - /* RCS_ID("$Id: pty.c,v 1.2 1999/09/19 19:50:51 mool Exp $ FAU") */ - - #if !defined(HAVE_SETENV) && !defined(HAVE_PUTENV) - - #define EXTRASIZE 5 /* increment to add to env. size */ - - static int envsize = -1; /* current size of environment */ - #ifndef MACOS - extern - #endif - char **environ; /* the global which is your env. */ - - static int findenv __ARGS((char *name)); /* look for a name in the env. */ - static int newenv __ARGS((void)); /* copy env. from stack to heap */ - static int moreenv __ARGS((void)); /* incr. size of env. */ - - int - putenv(string) - const char *string; - { - int i; - char *p; - - if (envsize < 0) - { /* first time putenv called */ - if (newenv() < 0) /* copy env. to heap */ - return -1; - } - - i = findenv((char *)string); /* look for name in environment */ - - if (i < 0) - { /* name must be added */ - for (i = 0; environ[i]; i++); - if (i >= (envsize - 1)) - { /* need new slot */ - if (moreenv() < 0) - return -1; - } - p = (char *)alloc((unsigned)(strlen(string) + 1)); - if (p == NULL) /* not enough core */ - return -1; - environ[i + 1] = 0; /* new end of env. */ - } - else - { /* name already in env. */ - p = vim_realloc(environ[i], strlen(string) + 1); - if (p == NULL) - return -1; - } - sprintf(p, "%s", string); /* copy into env. */ - environ[i] = p; - - return 0; - } - - static int - findenv(name) - char *name; - { - char *namechar, *envchar; - int i, found; - - found = 0; - for (i = 0; environ[i] && !found; i++) - { - envchar = environ[i]; - namechar = name; - while (*namechar && *namechar != '=' && (*namechar == *envchar)) - { - namechar++; - envchar++; - } - found = ((*namechar == '\0' || *namechar == '=') && *envchar == '='); - } - return found ? i - 1 : -1; - } - - static int - newenv() - { - char **env, *elem; - int i, esize; - - #ifdef MACOS - /* for Mac a new, empty environment is created */ - i = 0; - #else - for (i = 0; environ[i]; i++) - ; - #endif - esize = i + EXTRASIZE + 1; - env = (char **)alloc((unsigned)(esize * sizeof (elem))); - if (env == NULL) - return -1; - - #ifndef MACOS - for (i = 0; environ[i]; i++) - { - elem = (char *)alloc((unsigned)(strlen(environ[i]) + 1)); - if (elem == NULL) - return -1; - env[i] = elem; - strcpy(elem, environ[i]); - } - #endif - - env[i] = 0; - environ = env; - envsize = esize; - return 0; - } - - static int - moreenv() - { - int esize; - char **env; - - esize = envsize + EXTRASIZE; - env = (char **)vim_realloc((char *)environ, esize * sizeof (*env)); - if (env == 0) - return -1; - environ = env; - envsize = esize; - return 0; - } - - # ifdef USE_VIMPTY_GETENV - char_u * - vimpty_getenv(string) - const char_u *string; - { - int i; - char_u *p; - - if (envsize < 0) - return NULL; - - i = findenv((char *)string); - - if (i < 0) - return NULL; - - p = vim_strchr((char_u *)environ[i], '='); - return (p + 1); - } - # endif - - #endif /* !defined(HAVE_SETENV) && !defined(HAVE_PUTENV) */ --- 423,425 ---- *** ../vim60.30/src/version.c Sun Oct 28 21:23:45 2001 --- src/version.c Sun Oct 28 21:51:26 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 31, /**/ -- -rwxr-xr-x 1 root 24 Oct 29 1929 /bin/ed -rwxr-xr-t 4 root 131720 Jan 1 1970 /usr/ucb/vi -rwxr-xr-x 1 root 5.89824e37 Oct 22 1990 /usr/bin/emacs /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.032 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.032 Problem: When changing a setting that affects all folds, they are not displayed immediately. Solution: Set the redraw flag in foldUpdateAll(). Files: src/fold.c *** ../vim60.31/src/fold.c Wed Sep 26 12:36:14 2001 --- src/fold.c Mon Oct 29 09:27:51 2001 *************** *** 836,841 **** --- 836,842 ---- win_T *win; { win->w_foldinvalid = TRUE; + redraw_later(NOT_VALID); } /* foldMoveTo() {{{2 */ *** ../vim60.31/src/version.c Sun Oct 28 21:57:01 2001 --- src/version.c Mon Oct 29 09:32:32 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 32, /**/ -- FATHER: You only killed the bride's father - that's all - LAUNCELOT: Oh dear, I didn't really mean to... FATHER: Didn't mean to? You put your sword right through his head! LAUNCELOT: Gosh - Is he all right? "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.033 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.033 Problem: Using 'wildmenu' on MS-Windows, file names that include a space are only displayed starting with that space. (Xie Yuheng) Solution: Don't recognize a backslash before a space as a path separator. Files: src/screen.c *** ../vim60.32/src/screen.c Fri Sep 28 22:19:57 2001 --- src/screen.c Mon Oct 29 14:36:57 2001 *************** *** 4324,4330 **** for (p = s; *p != NUL; ) { ! if (vim_ispathsep(*p)) had_sep = TRUE; else if (had_sep) { --- 4329,4339 ---- for (p = s; *p != NUL; ) { ! if (vim_ispathsep(*p) ! #ifdef BACKSLASH_IN_FILENAME ! && !rem_backslash(p) ! #endif ! ) had_sep = TRUE; else if (had_sep) { *** ../vim60.32/src/version.c Mon Oct 29 09:34:01 2001 --- src/version.c Mon Oct 29 14:39:33 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 33, /**/ -- CRONE: Who sent you? ARTHUR: The Knights Who Say Ni! CRONE: Aaaagh! (she looks around in rear) No! We have no shrubberies here. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.034 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.034 Problem: Calling searchpair() with three arguments could result in a crash or strange error message. (Kalle Bjorklid) Solution: Don't use the fifth argument when there is no fourth argument. Files: src/eval.c *** ../vim60.33/src/eval.c Fri Oct 19 19:36:36 2001 --- src/eval.c Mon Oct 29 15:09:18 2001 *************** *** 5201,5207 **** dir = get_search_arg(&argvars[3], &flags); /* may set p_ws */ /* Optional fifth argument: skip expresion */ ! if (argvars[4].var_type == VAR_UNKNOWN) skip = (char_u *)""; else skip = get_var_string_buf(&argvars[4], nbuf3); --- 5201,5208 ---- dir = get_search_arg(&argvars[3], &flags); /* may set p_ws */ /* Optional fifth argument: skip expresion */ ! if (argvars[3].var_type == VAR_UNKNOWN ! || argvars[4].var_type == VAR_UNKNOWN) skip = (char_u *)""; else skip = get_var_string_buf(&argvars[4], nbuf3); *** ../vim60.33/src/version.c Mon Oct 29 14:40:42 2001 --- src/version.c Mon Oct 29 15:10:33 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 34, /**/ -- There are three kinds of people: Those who can count & those who can't. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.035 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.035 Problem: The menu item Edit/Global_Settings/Toggle_Toolbar doesn't work when 'ignorecase' is set. (Allen Castaban) Solution: Always match case when checking if a flag is already present in 'guioptions'. Files: runtime/menu.vim *** ../vim60.34/runtime/menu.vim Thu Oct 25 16:34:24 2001 --- runtime/menu.vim Mon Oct 29 15:20:33 2001 *************** *** 203,209 **** fun! s:ToggleGuiOption(option) " If a:option is already set in guioptions, then we want to remove it ! if match(&guioptions, a:option) > -1 exec "set go-=" . a:option else exec "set go+=" . a:option --- 203,209 ---- fun! s:ToggleGuiOption(option) " If a:option is already set in guioptions, then we want to remove it ! if match(&guioptions, "\\C" . a:option) > -1 exec "set go-=" . a:option else exec "set go+=" . a:option *** ../vim60.34/src/version.c Mon Oct 29 15:15:20 2001 --- src/version.c Mon Oct 29 15:23:31 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 35, /**/ -- Mental Floss prevents moral decay! /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.036 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.036 Problem: OS/2, MS-DOS and MS-Windows: Using a path that starts with a slash in 'tags' doesn't work as expected. (Mathias Koehrer Solution: Only use the drive, not the whole path to the current directory. Also make it work for "c:dir/file". Files: src/misc2.c *** ../vim60.35/src/misc2.c Sun Oct 28 21:57:01 2001 --- src/misc2.c Mon Oct 29 17:14:44 2001 *************** *** 3532,3542 **** } else if (*path == NUL || !vim_isAbsName(path)) { ! if (mch_dirname(ff_expand_buffer, MAXPATHL) == OK) ! ff_search_ctx->ffsc_start_dir = vim_strsave(ff_expand_buffer); if (ff_search_ctx->ffsc_start_dir == NULL) goto error_return; } #ifdef FEAT_PATH_EXTRA --- 3533,3568 ---- } else if (*path == NUL || !vim_isAbsName(path)) { ! #ifdef BACKSLASH_IN_FILENAME ! /* "c:dir" needs "c:" to be expanded, otherwise use current dir */ ! if (path[1] == ':') ! { ! char_u drive[3]; ! ! drive[0] = path[0]; ! drive[1] = ':'; ! drive[2] = NUL; ! if (vim_FullName(drive, ff_expand_buffer, MAXPATHL, TRUE) == FAIL) ! goto error_return; ! path += 2; ! } ! else ! #endif ! if (mch_dirname(ff_expand_buffer, MAXPATHL) == FAIL) ! goto error_return; + ff_search_ctx->ffsc_start_dir = vim_strsave(ff_expand_buffer); if (ff_search_ctx->ffsc_start_dir == NULL) goto error_return; + + #ifdef BACKSLASH_IN_FILENAME + /* A path that starts with "/dir" is relative to the drive, not to the + * directory (but not for "//machine/dir"). Only use the drive name. */ + if ((*path == '/' || *path == '\\') + && path[1] != path[0] + && ff_search_ctx->ffsc_start_dir[1] == ':') + ff_search_ctx->ffsc_start_dir[2] = NUL; + #endif } #ifdef FEAT_PATH_EXTRA *** ../vim60.35/src/version.c Mon Oct 29 15:24:28 2001 --- src/version.c Mon Oct 29 16:38:23 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 36, /**/ -- Did you ever stop to think... and forget to start again? -- Steven Wright /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.037 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.037 Problem: When the user has set "did_install_syntax_menu" to avoid the default Syntax menu it still appears. (Virgilio) Solution: Don't add the three default items when "did_install_syntax_menu" is set. Files: runtime/menu.vim *** ../vim60.36/runtime/menu.vim Mon Oct 29 15:24:28 2001 --- runtime/menu.vim Mon Oct 29 21:06:23 2001 *************** *** 831,850 **** endif " !exists("did_install_default_menus") " Define these items always, so that syntax can be switched on when it wasn't. ! am 50.212 &Syntax.&Manual :syn manual ! am 50.214 &Syntax.A&utomatic :syn on ! am 50.216 &Syntax.on/off\ for\ &This\ file :call SynOnOff() ! if !exists("*s:SynOnOff") ! fun s:SynOnOff() ! if has("syntax_items") ! syn clear ! else ! if !exists("g:syntax_on") ! syn manual endif ! set syn=ON ! endif ! endfun endif --- 831,853 ---- endif " !exists("did_install_default_menus") " Define these items always, so that syntax can be switched on when it wasn't. ! " But skip them when the Syntax menu was disabled by the user. ! if !exists("did_install_syntax_menu") ! am 50.212 &Syntax.&Manual :syn manual ! am 50.214 &Syntax.A&utomatic :syn on ! am 50.216 &Syntax.on/off\ for\ &This\ file :call SynOnOff() ! if !exists("*s:SynOnOff") ! fun s:SynOnOff() ! if has("syntax_items") ! syn clear ! else ! if !exists("g:syntax_on") ! syn manual ! endif ! set syn=ON endif ! endfun ! endif endif *** ../vim60.36/src/version.c Mon Oct 29 17:19:02 2001 --- src/version.c Mon Oct 29 21:10:10 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 37, /**/ -- [Autumn changed into Winter ... Winter changed into Spring ... Spring changed back into Autumn and Autumn gave Winter and Spring a miss and went straight on into Summer ... Until one day ...] "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.038 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.038 Problem: When 'selection' is "exclusive", deleting a block of text at the end of a line can leave the cursor beyond the end of the line. Solution: Correct the cursor position. Files: src/ops.c *** ../vim60.37/src/ops.c Sun Oct 28 16:41:29 2001 --- src/ops.c Tue Oct 30 11:14:22 2001 *************** *** 1575,1581 **** ml_replace(lnum, newp, FALSE); } ! /* Put cursor back at start of changed block */ changed_lines(curwin->w_cursor.lnum, curwin->w_cursor.col, oap->end.lnum + 1, 0L); oap->line_count = 0; /* no lines deleted */ --- 1575,1581 ---- ml_replace(lnum, newp, FALSE); } ! check_cursor_col(); changed_lines(curwin->w_cursor.lnum, curwin->w_cursor.col, oap->end.lnum + 1, 0L); oap->line_count = 0; /* no lines deleted */ *** ../vim60.37/src/version.c Tue Oct 30 11:17:56 2001 --- src/version.c Tue Oct 30 11:17:22 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 38, /**/ -- ROBIN: The what? ARTHUR: The Holy Hand Grenade of Antioch. 'Tis one of the sacred relics Brother Maynard always carries with him. ALL: Yes. Of course. ARTHUR: (shouting) Bring up the Holy Hand Grenade! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.039 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.039 Problem: "gP" leaves the cursor in the wrong position when 'virtualedit' is used. Using "c" in blockwise Visual mode leaves the cursor in a strange position. Solution: For "gP" reset the "coladd" field for the '] mark. For "c" leave the cursor on the last inserted character. Files: src/ops.c *** ../vim60.38/src/ops.c Tue Oct 30 11:19:49 2001 --- src/ops.c Tue Oct 30 14:33:31 2001 *************** *** 2304,2314 **** */ if ((ins_len = (long)STRLEN(firstline) - pre_textlen) > 0) { ! if ((ins_text = alloc_check((unsigned)(ins_len + 1))) != 0) { - /* put cursor at end of changed text */ - curwin->w_cursor = oap->end; - STRNCPY(ins_text, firstline + bd.textcol, ins_len); *(ins_text + ins_len) = NUL; for (linenr = oap->start.lnum + 1; linenr <= oap->end.lnum; --- 2305,2312 ---- */ if ((ins_len = (long)STRLEN(firstline) - pre_textlen) > 0) { ! if ((ins_text = alloc_check((unsigned)(ins_len + 1))) != NULL) { STRNCPY(ins_text, firstline + bd.textcol, ins_len); *(ins_text + ins_len) = NUL; for (linenr = oap->start.lnum + 1; linenr <= oap->end.lnum; *************** *** 2331,2341 **** mch_memmove(newp + bd.textcol + offset, oldp, STRLEN(oldp) + 1); ml_replace(linenr, newp, FALSE); - if (linenr == oap->end.lnum) - curwin->w_cursor.col = bd.textcol + ins_len - 1; } } - curwin->w_cursor.col = oap->start.col; check_cursor(); changed_lines(oap->start.lnum + 1, 0, oap->end.lnum + 1, 0L); --- 2329,2336 ---- *************** *** 3135,3140 **** --- 3130,3138 ---- /* adjust '] mark */ curbuf->b_op_end.lnum = curwin->w_cursor.lnum - 1; curbuf->b_op_end.col = bd.textcol + totlen - 1; + #ifdef FEAT_VIRTUALEDIT + curbuf->b_op_end.coladd = 0; + #endif if (flags & PUT_CURSEND) { curwin->w_cursor = curbuf->b_op_end; *************** *** 3375,3381 **** --- 3373,3385 ---- && gchar_cursor() == NUL && curwin->w_cursor.col && !(restart_edit || (State & INSERT))) + { --curwin->w_cursor.col; + #ifdef FEAT_VIRTUALEDIT + if (ve_flags == VE_ALL) + ++curwin->w_cursor.coladd; + #endif + } } #if defined(FEAT_SMARTINDENT) || defined(FEAT_CINDENT) || defined(PROTO) *** ../vim60.38/src/version.c Tue Oct 30 11:19:49 2001 --- src/version.c Tue Oct 30 14:43:04 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 39, /**/ -- BROTHER MAYNARD: Armaments Chapter Two Verses Nine to Twenty One. ANOTHER MONK: And St. Attila raised his hand grenade up on high saying "O Lord bless this thy hand grenade that with it thou mayest blow thine enemies to tiny bits, in thy mercy. "and the Lord did grin and people did feast upon the lambs and sloths and carp and anchovies and orang-utans and breakfast cereals and fruit bats and... BROTHER MAYNARD: Skip a bit brother ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.040 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.040 Problem: When 'fileencoding' is invalid and writing fails because of this, the original file is gone. (Eric Carlier) Solution: Restore the original file from the backup. Files: src/fileio.c *** ../vim60.39/src/fileio.c Thu Sep 20 18:09:15 2001 --- src/fileio.c Tue Oct 30 19:59:18 2001 *************** *** 2183,2189 **** int backup_copy = FALSE; /* copy the original file? */ int dobackup; char_u *ffname; ! char_u *wfname; /* name of file to write to */ char_u *s; char_u *ptr; char_u c; --- 2183,2189 ---- int backup_copy = FALSE; /* copy the original file? */ int dobackup; char_u *ffname; ! char_u *wfname = NULL; /* name of file to write to */ char_u *s; char_u *ptr; char_u c; *************** *** 3016,3022 **** if (got_int) { errmsg = (char_u *)_(e_interr); ! goto fail; } } --- 3016,3022 ---- if (got_int) { errmsg = (char_u *)_(e_interr); ! goto restore_backup; } } *************** *** 3030,3036 **** if (mch_has_resource_fork(fname)) { errmsg = (char_u *)_("The resource fork will be lost (use ! to override)"); ! goto fail; } #endif --- 3030,3036 ---- if (mch_has_resource_fork(fname)) { errmsg = (char_u *)_("The resource fork will be lost (use ! to override)"); ! goto restore_backup; } #endif *************** *** 3119,3125 **** if (wfname == NULL) /* Can't write without a tempfile! */ { errmsg = (char_u *)_("E214: Can't find temp file for writing"); ! goto fail; } } # endif --- 3119,3125 ---- if (wfname == NULL) /* Can't write without a tempfile! */ { errmsg = (char_u *)_("E214: Can't find temp file for writing"); ! goto restore_backup; } } # endif *************** *** 3137,3143 **** if (!forceit) { errmsg = (char_u *)_("E213: Cannot convert (use ! to write without conversion)"); ! goto fail; } notconverted = TRUE; } --- 3137,3143 ---- if (!forceit) { errmsg = (char_u *)_("E213: Cannot convert (use ! to write without conversion)"); ! goto restore_backup; } notconverted = TRUE; } *************** *** 3156,3163 **** : (O_CREAT | O_TRUNC)) , 0666)) < 0) { - struct stat st; - /* * A forced write will try to create a new file if the old one is * still readonly. This may also happen when the directory is --- 3156,3161 ---- *************** *** 3196,3233 **** } } } ! /* ! * If we failed to open the file, we don't need a backup. Throw it ! * away. If we moved or removed the original file try to put the ! * backup in its place. ! */ ! if (backup != NULL && wfname == fname) { ! if (backup_copy) { ! /* ! * There is a small chance that we removed the original, try ! * to move the copy in its place. ! * This may not work if the vim_rename() fails. ! * In that case we leave the copy around. ! */ ! /* If file does not exist, put the copy in its place */ ! if (mch_stat((char *)fname, &st) < 0) vim_rename(backup, fname); ! /* if original file does exist throw away the copy */ ! if (mch_stat((char *)fname, &st) >= 0) ! mch_remove(backup); ! } ! else ! { ! /* try to put the original file back */ ! vim_rename(backup, fname); } - } ! /* if original file no longer exists give an extra warning */ ! if (!newfile && mch_stat((char *)fname, &st) < 0) ! end = 0; #ifdef FEAT_MBYTE if (wfname != fname) --- 3194,3237 ---- } } } ! ! restore_backup: { ! struct stat st; ! ! /* ! * If we failed to open the file, we don't need a backup. Throw it ! * away. If we moved or removed the original file try to put the ! * backup in its place. ! */ ! if (backup != NULL && wfname == fname) { ! if (backup_copy) ! { ! /* ! * There is a small chance that we removed the original, ! * try to move the copy in its place. ! * This may not work if the vim_rename() fails. ! * In that case we leave the copy around. ! */ ! /* If file does not exist, put the copy in its place */ ! if (mch_stat((char *)fname, &st) < 0) ! vim_rename(backup, fname); ! /* if original file does exist throw away the copy */ ! if (mch_stat((char *)fname, &st) >= 0) ! mch_remove(backup); ! } ! else ! { ! /* try to put the original file back */ vim_rename(backup, fname); ! } } ! /* if original file no longer exists give an extra warning */ ! if (!newfile && mch_stat((char *)fname, &st) < 0) ! end = 0; ! } #ifdef FEAT_MBYTE if (wfname != fname) *** ../vim60.39/src/version.c Tue Oct 30 14:52:27 2001 --- src/version.c Tue Oct 30 20:01:33 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 40, /**/ -- VOICE OVER: As the horrendous Black Beast lunged forward, escape for Arthur and his knights seemed hopeless, when, suddenly ... the animator suffered a fatal heart attack. ANIMATOR: Aaaaagh! VOICE OVER: The cartoon peril was no more ... The Quest for Holy Grail could continue. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.041 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.041 Problem: Using ":language messages en" when LC_MESSAGES is undefined results in setting LC_CTYPE. (Eric Carlier) Solution: Set $LC_MESSAGES instead. Files: src/ex_cmds2.c *** ../vim60.40/src/ex_cmds2.c Sun Oct 28 21:23:45 2001 --- src/ex_cmds2.c Tue Oct 30 20:32:04 2001 *************** *** 4628,4633 **** --- 4628,4638 ---- char_u *name; int what = LC_ALL; char *whatstr = ""; + #ifdef LC_MESSAGES + # define VIM_LC_MESSAGES LC_MESSAGES + #else + # define VIM_LC_MESSAGES 6789 + #endif name = eap->arg; *************** *** 4639,4649 **** { if (STRNICMP(eap->arg, "messages", p - eap->arg) == 0) { ! #ifdef LC_MESSAGES ! what = LC_MESSAGES; ! #else ! what = LC_CTYPE; ! #endif name = skipwhite(p); whatstr = "messages "; } --- 4644,4650 ---- { if (STRNICMP(eap->arg, "messages", p - eap->arg) == 0) { ! what = VIM_LC_MESSAGES; name = skipwhite(p); whatstr = "messages "; } *************** *** 4663,4674 **** if (*name == NUL) { ! smsg((char_u *)_("Current %slanguage: \"%s\""), ! whatstr, setlocale(what, NULL)); } else { ! loc = setlocale(what, (char *)name); if (loc == NULL) EMSG2(_("E197: Cannot set language to \"%s\""), name); else --- 4664,4695 ---- if (*name == NUL) { ! #ifndef LC_MESSAGES ! if (what == VIM_LC_MESSAGES) ! { ! p = vim_getenv("LC_ALL"); ! if (p == NULL || *p == NUL) ! { ! p = vim_getenv("LC_MESSAGES"); ! if (p == NULL || *p == NUL) ! p = vim_getenv("LANG"); ! } ! } ! else ! #endif ! p = setlocale(what, NULL); ! if (p == NULL || *p == NUL) ! p = "Unknown"; ! smsg((char_u *)_("Current %slanguage: \"%s\""), whatstr, p); } else { ! #ifndef LC_MESSAGES ! if (what == VIM_LC_MESSAGES) ! loc = ""; ! else ! #endif ! loc = setlocale(what, (char *)name); if (loc == NULL) EMSG2(_("E197: Cannot set language to \"%s\""), name); else *************** *** 4697,4705 **** /* Set $LC_CTYPE, because it overrules $LANG, and * gtk_set_locale() calls setlocale() again. gnome_init() * sets $LC_CTYPE to "en_US" (that's a bug!). */ ! #ifdef LC_MESSAGES ! if (what != LC_MESSAGES) ! #endif vim_setenv((char_u *)"LC_CTYPE", name); # ifdef FEAT_GUI_GTK /* Let GTK know what locale we're using. Not sure this is --- 4718,4724 ---- /* Set $LC_CTYPE, because it overrules $LANG, and * gtk_set_locale() calls setlocale() again. gnome_init() * sets $LC_CTYPE to "en_US" (that's a bug!). */ ! if (what != VIM_LC_MESSAGES) vim_setenv((char_u *)"LC_CTYPE", name); # ifdef FEAT_GUI_GTK /* Let GTK know what locale we're using. Not sure this is *** ../vim60.40/src/version.c Tue Oct 30 20:35:08 2001 --- src/version.c Tue Oct 30 20:34:45 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 41, /**/ -- BEDEVERE: Look! It's the old man from scene 24 - what's he Doing here? ARTHUR: He is the keeper of the Bridge. He asks each traveler five questions ... GALAHAD: Three questions. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.042 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.042 Problem: ":mksession" can't handle file names with a space. Solution: Escape special characters in file names with a backslash. Files: src/ex_docmd.c *** ../vim60.41/src/ex_docmd.c Sun Oct 28 21:23:45 2001 --- src/ex_docmd.c Tue Oct 30 21:16:12 2001 *************** *** 8417,8423 **** /* * Write a file name to the session file. ! * Takes care of the "slash" option in 'sessionoptions'. * Returns FAIL if writing fails. */ static int --- 8417,8424 ---- /* * Write a file name to the session file. ! * Takes care of the "slash" option in 'sessionoptions' and escapes special ! * characters. * Returns FAIL if writing fails. */ static int *************** *** 8433,8451 **** sname = home_replace_save(NULL, name); if (sname != NULL) name = sname; ! if (*flagp & SSOP_SLASH) { ! while (*name) { ! c = *name++; ! if (c == '\\') ! c = '/'; ! if (putc(c, fd) != c) retval = FAIL; } } - else if (fputs((char *)name, fd) < 0) - retval = FAIL; vim_free(sname); return retval; } --- 8434,8475 ---- sname = home_replace_save(NULL, name); if (sname != NULL) name = sname; ! while (*name != NUL) { ! #ifdef FEAT_MBYTE { ! int l; ! ! if (has_mbyte && (l = (*mb_ptr2len_check)(name)) > 1) ! { ! /* copy a multibyte char */ ! while (--l >= 0) ! { ! if (putc(*name, fd) != *name) ! retval = FAIL; ! ++name; ! } ! continue; ! } ! } ! #endif ! c = *name++; ! if (c == '\\' && (*flagp & SSOP_SLASH)) ! /* change a backslash to a forward slash */ ! c = '/'; ! else if (vim_strchr(escape_chars, c) != NULL ! #ifdef BACKSLASH_IN_FILENAME ! && c != '\\' ! #endif ! ) ! { ! /* escape a special character with a backslash */ ! if (putc('\\', fd) != '\\') retval = FAIL; } + if (putc(c, fd) != c) + retval = FAIL; } vim_free(sname); return retval; } *** ../vim60.41/src/version.c Tue Oct 30 20:43:43 2001 --- src/version.c Tue Oct 30 20:59:56 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 42, /**/ -- ARTHUR: No, hang on! Just answer the five questions ... GALAHAD: Three questions ... ARTHUR: Three questions ... And we shall watch ... and pray. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.043 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.043 Problem: Patch 6.0.041 was wrong. Solution: Use mch_getenv() instead of vim_getenv(). Files: src/ex_cmds2.c *** ../vim60.42/src/ex_cmds2.c Tue Oct 30 20:43:43 2001 --- src/ex_cmds2.c Wed Oct 31 10:10:45 2001 *************** *** 4667,4685 **** #ifndef LC_MESSAGES if (what == VIM_LC_MESSAGES) { ! p = vim_getenv("LC_ALL"); if (p == NULL || *p == NUL) { ! p = vim_getenv("LC_MESSAGES"); if (p == NULL || *p == NUL) ! p = vim_getenv("LANG"); } } else #endif ! p = setlocale(what, NULL); if (p == NULL || *p == NUL) ! p = "Unknown"; smsg((char_u *)_("Current %slanguage: \"%s\""), whatstr, p); } else --- 4667,4685 ---- #ifndef LC_MESSAGES if (what == VIM_LC_MESSAGES) { ! p = mch_getenv((char_u *)"LC_ALL"); if (p == NULL || *p == NUL) { ! p = mch_getenv((char_u *)"LC_MESSAGES"); if (p == NULL || *p == NUL) ! p = mch_getenv((char_u *)"LANG"); } } else #endif ! p = (char_u *)setlocale(what, NULL); if (p == NULL || *p == NUL) ! p = (char_u *)"Unknown"; smsg((char_u *)_("Current %slanguage: \"%s\""), whatstr, p); } else *** ../vim60.42/src/version.c Tue Oct 30 21:18:36 2001 --- src/version.c Wed Oct 31 10:08:33 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 43, /**/ -- It is illegal for anyone to give lighted cigars to dogs, cats, and other domesticated animal kept as pets. [real standing law in Illinois, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.044 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.044 Problem: Using a "containedin" list for a syntax item doesn't work for an item that doesn't have a "contains" argument. Also, "containedin" doesn't ignore a transparent item. (Timo Frenay) Solution: When there is a "containedin" argument somewhere, always check for contained items. Don't check for the transparent item but the item it's contained in. Files: src/structs.h, src/syntax.c *** ../vim60.43/src/structs.h Sun Oct 28 21:15:32 2001 --- src/structs.h Wed Oct 31 10:34:45 2001 *************** *** 1018,1023 **** --- 1018,1025 ---- int b_syn_ic; /* ignore case for :syn cmds */ garray_T b_syn_patterns; /* table for syntax patterns */ garray_T b_syn_clusters; /* table for syntax clusters */ + int b_syn_containedin; /* TRUE when there is an item with a + "containedin" argument */ int b_syn_sync_flags; /* flags about how to sync */ short b_syn_sync_id; /* group to sync on */ long b_syn_sync_minlines; /* minimal sync lines offset */ *** ../vim60.43/src/syntax.c Mon Oct 22 18:52:01 2001 --- src/syntax.c Wed Oct 31 11:11:24 2001 *************** *** 174,179 **** --- 174,180 ---- #define HL_FOLD 0x2000 /* define fold */ #define HL_EXTEND 0x4000 /* ignore a keepend */ #define HL_MATCHCONT 0x8000 /* match continued from previous line */ + #define HL_TRANS_CONT 0x10000 /* transparent item without contains arg */ #define SYN_ITEMS(buf) ((synpat_T *)((buf)->b_syn_patterns.ga_data)) *************** *** 1772,1784 **** * 1. Check for a current state. * Only when there is no current state, or if the current state may * contain other things, we need to check for keywords and patterns. */ if (current_state.ga_len) cur_si = &CUR_STATE(current_state.ga_len - 1); else cur_si = NULL; ! if (cur_si == NULL || cur_si->si_cont_list != NULL) { /* * 2. Check for keywords, if on a keyword char after a non-keyword --- 1773,1788 ---- * 1. Check for a current state. * Only when there is no current state, or if the current state may * contain other things, we need to check for keywords and patterns. + * Always need to check for contained items if some item has the + * "containedin" argument (takes extra time!). */ if (current_state.ga_len) cur_si = &CUR_STATE(current_state.ga_len - 1); else cur_si = NULL; ! if (curbuf->b_syn_containedin || cur_si == NULL ! || cur_si->si_cont_list != NULL) { /* * 2. Check for keywords, if on a keyword char after a non-keyword *************** *** 2387,2393 **** --- 2391,2400 ---- sip->si_attr = CUR_STATE(idx - 1).si_attr; sip->si_trans_id = CUR_STATE(idx - 1).si_trans_id; if (sip->si_cont_list == NULL) + { + sip->si_flags |= HL_TRANS_CONT; sip->si_cont_list = CUR_STATE(idx - 1).si_cont_list; + } } } } *************** *** 3001,3006 **** --- 3008,3014 ---- int i; curbuf->b_syn_ic = FALSE; /* Use case, by default */ + curbuf->b_syn_containedin = FALSE; /* free the keywords */ free_keywtab(buf->b_keywtab); *************** *** 3884,3889 **** --- 3892,3899 ---- ktab->k_syn.inc_tag = current_syn_inc_tag; ktab->flags = flags; ktab->k_syn.cont_in_list = copy_id_list(cont_in_list); + if (cont_in_list != NULL) + curbuf->b_syn_containedin = TRUE; ktab->next_list = copy_id_list(next_list); if (curbuf->b_syn_ic) *************** *** 4397,4402 **** --- 4407,4414 ---- SYN_ITEMS(curbuf)[idx].sp_sync_idx = sync_idx; SYN_ITEMS(curbuf)[idx].sp_cont_list = cont_list; SYN_ITEMS(curbuf)[idx].sp_syn.cont_in_list = cont_in_list; + if (cont_in_list != NULL) + curbuf->b_syn_containedin = TRUE; SYN_ITEMS(curbuf)[idx].sp_next_list = next_list; ++curbuf->b_syn_patterns.ga_len; --curbuf->b_syn_patterns.ga_room; *************** *** 4637,4642 **** --- 4649,4656 ---- SYN_ITEMS(curbuf)[idx].sp_cont_list = cont_list; SYN_ITEMS(curbuf)[idx].sp_syn.cont_in_list = cont_in_list; + if (cont_in_list != NULL) + curbuf->b_syn_containedin = TRUE; SYN_ITEMS(curbuf)[idx].sp_next_list = next_list; } ++curbuf->b_syn_patterns.ga_len; *************** *** 5516,5527 **** int r; /* If spp has a "containedin" list and "cur_si" is in it, return TRUE. */ ! if (cur_si != NULL ! && ssp->cont_in_list != NULL ! && in_id_list(NULL, ssp->cont_in_list, &(SYN_ITEMS(syn_buf)[cur_si->si_idx].sp_syn), SYN_ITEMS(syn_buf)[cur_si->si_idx].sp_flags & HL_CONTAINED)) return TRUE; /* * If list is ID_LIST_ALL, we are in a transparent item that isn't --- 5530,5548 ---- int r; /* If spp has a "containedin" list and "cur_si" is in it, return TRUE. */ ! if (cur_si != NULL && ssp->cont_in_list != NULL) ! { ! /* Ignore transparent items without a contains argument. */ ! while (cur_si->si_flags & HL_TRANS_CONT) ! --cur_si; ! if (in_id_list(NULL, ssp->cont_in_list, &(SYN_ITEMS(syn_buf)[cur_si->si_idx].sp_syn), SYN_ITEMS(syn_buf)[cur_si->si_idx].sp_flags & HL_CONTAINED)) return TRUE; + } + + if (list == NULL) + return FALSE; /* * If list is ID_LIST_ALL, we are in a transparent item that isn't *** ../vim60.43/src/version.c Wed Oct 31 10:12:03 2001 --- src/version.c Wed Oct 31 11:14:14 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 44, /**/ -- Citizens are not allowed to attend a movie house or theater nor ride in a public streetcar within at least four hours after eating garlic. [real standing law in Indiana, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.045 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.045 Problem: After creating a fold with a Visual selection, another window with the same buffer still has inverted text. (Sami Salonen) Solution: Redraw the inverted text. Files: src/normal.c *** ../vim60.44/src/normal.c Tue Oct 23 16:54:23 2001 --- src/normal.c Wed Oct 31 11:51:54 2001 *************** *** 1633,1641 **** && vim_strchr(p_cpo, CPO_EMPTYREGION) != NULL); #ifdef FEAT_VISUAL ! /* Force a redraw when operating on an empty Visual region or when ! * 'modifiable is off. */ ! if (oap->is_VIsual && (oap->empty || !curbuf->b_p_ma)) redraw_curbuf_later(INVERTED); #endif --- 1632,1644 ---- && vim_strchr(p_cpo, CPO_EMPTYREGION) != NULL); #ifdef FEAT_VISUAL ! /* Force a redraw when operating on an empty Visual region, when ! * 'modifiable is off or creating a fold. */ ! if (oap->is_VIsual && (oap->empty || !curbuf->b_p_ma ! # ifdef FEAT_FOLDING ! || oap->op_type == OP_FOLD ! # endif ! )) redraw_curbuf_later(INVERTED); #endif *** ../vim60.44/src/version.c Wed Oct 31 11:17:27 2001 --- src/version.c Wed Oct 31 11:54:20 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 45, /**/ -- Why don't cannibals eat clowns? Because they taste funny. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.046 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.046 Problem: When getrlimit() returns an 8 byte number the check for running out of stack may fail. (Anthony Meijer) Solution: Skip the stack check if the limit doesn't fit in a long. Files: src/auto/configure, src/config.h.in, src/configure.in, src/os_unix.c *** ../vim60.45/src/auto/configure Fri Sep 28 17:39:10 2001 --- src/auto/configure Wed Oct 31 13:52:02 2001 *************** *** 5145,5158 **** fi echo $ac_n "checking for stack_t""... $ac_c" 1>&6 ! echo "configure:5151: checking for stack_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then echo "$ac_t""(cached) $ac_cv_type_stack_t" 1>&6 else cat > conftest.$ac_ext <&6 + echo "configure:5150: checking for rlim_t" >&5 + if eval "test \"`echo '$''{'ac_cv_type_rlim_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #if STDC_HEADERS + #include + #include + #endif + EOF + if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "(^|[^a-zA-Z_0-9])rlim_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_type_rlim_t=yes + else + rm -rf conftest* + ac_cv_type_rlim_t=no + fi + rm -f conftest* + + fi + echo "$ac_t""$ac_cv_type_rlim_t" 1>&6 + if test $ac_cv_type_rlim_t = no; then + cat >> confdefs.h <<\EOF + #define rlim_t unsigned long + EOF + + fi + echo $ac_n "checking for stack_t""... $ac_c" 1>&6 ! echo "configure:5184: checking for stack_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then echo "$ac_t""(cached) $ac_cv_type_stack_t" 1>&6 else cat > conftest.$ac_ext < doesn't define. */ #undef dev_t + /* Define to `unsigned long' if doesn't define. */ + #undef rlim_t + /* Define to `struct sigaltstack' if doesn't define. */ #undef stack_t *** ../vim60.45/src/configure.in Fri Sep 28 17:39:10 2001 --- src/configure.in Wed Oct 31 13:49:25 2001 *************** *** 1405,1410 **** --- 1405,1411 ---- AC_HEADER_TIME AC_CHECK_TYPE(ino_t, long) AC_CHECK_TYPE(dev_t, unsigned) + AC_CHECK_TYPE(rlim_t, unsigned long) AC_MSG_CHECKING(for stack_t) if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then *** ../vim60.45/src/os_unix.c Thu Oct 25 16:34:24 2001 --- src/os_unix.c Wed Oct 31 13:46:36 2001 *************** *** 428,433 **** --- 428,434 ---- struct rlimit rlp; if (getrlimit(RLIMIT_DATA, &rlp) == 0 + && rlp.rlim_cur < ((rlim_t)1 << (sizeof(long_u) * 8 - 1)) # ifdef RLIM_INFINITY && rlp.rlim_cur != RLIM_INFINITY # endif *************** *** 544,551 **** struct rlimit rlp; int i; ! /* Set the stack limit to 15/16 of the allowable size. */ if (getrlimit(RLIMIT_STACK, &rlp) == 0 # ifdef RLIM_INFINITY && rlp.rlim_cur != RLIM_INFINITY # endif --- 545,554 ---- struct rlimit rlp; int i; ! /* Set the stack limit to 15/16 of the allowable size. Skip this when the ! * limit doesn't fit in a long (rlim_cur might be "long long"). */ if (getrlimit(RLIMIT_STACK, &rlp) == 0 + && rlp.rlim_cur < ((rlim_t)1 << (sizeof(long_u) * 8 - 1)) # ifdef RLIM_INFINITY && rlp.rlim_cur != RLIM_INFINITY # endif *** ../vim60.45/src/version.c Wed Oct 31 11:56:35 2001 --- src/version.c Wed Oct 31 14:12:00 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 46, /**/ -- No man may purchase alcohol without written consent from his wife. [real standing law in Pennsylvania, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.047 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.047 Problem: Using a regexp with "\(\)" inside a "\%[]" item causes a crash. (Samuel Lacas) Solution: Don't allow nested atoms inside "\%[]". Files: src/regexp.c *** ../vim60.46/src/regexp.c Wed Oct 24 19:41:55 2001 --- src/regexp.c Wed Oct 31 14:49:48 2001 *************** *** 316,321 **** --- 316,322 ---- #define EMSG_RET_NULL(m) { EMSG(_(m)); rc_did_emsg = TRUE; return NULL; } #define EMSG_M_RET_NULL(m, c) { EMSG2(_(m), c ? "" : "\\"); rc_did_emsg = TRUE; return NULL; } #define EMSG_RET_FAIL(m) { EMSG(_(m)); rc_did_emsg = TRUE; return FAIL; } + #define EMSG_ONE_RET_NULL EMSG_M_RET_NULL("E369: invalid item in %s%%[]", reg_magic == MAGIC_ALL) #define MAX_LIMIT (32767L << 16L) *************** *** 1444,1449 **** --- 1445,1452 ---- break; case Magic('('): + if (one_exactly) + EMSG_ONE_RET_NULL; ret = reg(REG_PAREN, &flags); if (ret == NULL) return NULL; *************** *** 1526,1531 **** --- 1529,1536 ---- { case '(': if (reg_do_extmatch != REX_SET) EMSG_RET_NULL("E66: \\z( not allowed here"); + if (one_exactly) + EMSG_ONE_RET_NULL; ret = reg(REG_ZPAREN, &flags); if (ret == NULL) return NULL; *************** *** 1565,1570 **** --- 1570,1577 ---- { /* () without a back reference */ case '(': + if (one_exactly) + EMSG_ONE_RET_NULL; ret = reg(REG_NPAREN, &flags); if (ret == NULL) return NULL; *************** *** 1588,1593 **** --- 1595,1602 ---- /* \%[abc]: Emit as a list of branches, all ending at the last * branch which matches nothing. */ case '[': + if (one_exactly) /* doesn't nest */ + EMSG_ONE_RET_NULL; { char_u *lastbranch; char_u *lastnode = NULL; *** ../vim60.46/src/version.c Wed Oct 31 14:21:02 2001 --- src/version.c Wed Oct 31 14:52:47 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 47, /**/ -- It is illegal to take more than three sips of beer at a time while standing. [real standing law in Texas, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.048 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.048 Problem: Win32: In the console the mouse doesn't always work correctly. Sometimes after getting focus a mouse movement is interpreted like a button click. Solution: Use a different function to obtain the number of mouse buttons. Avoid recognizing a button press from undefined bits. (Vince Negri) Files: src/os_win32.c *** ../vim60.47/src/os_win32.c Fri Sep 21 11:46:49 2001 --- src/os_win32.c Wed Oct 31 15:19:44 2001 *************** *** 768,773 **** --- 768,775 ---- static s_dwLastClickTime = 0; static BOOL s_fNextIsMiddle = FALSE; + static int cButtons = 0; /* number of buttons supported */ + const DWORD LEFT = FROM_LEFT_1ST_BUTTON_PRESSED; const DWORD MIDDLE = FROM_LEFT_2ND_BUTTON_PRESSED; const DWORD RIGHT = RIGHTMOST_BUTTON_PRESSED; *************** *** 775,780 **** --- 777,785 ---- int nButton; + if (cButtons == 0 && !GetNumberOfConsoleMouseButtons(&cButtons)) + cButtons = 2; + if (!g_fMouseAvail || !g_fMouseActive) { g_nMouseClick = -1; *************** *** 805,811 **** } /* If no buttons are pressed... */ ! if (pmer->dwButtonState == 0) { /* If the last thing returned was MOUSE_RELEASE, ignore this */ if (s_fReleased) --- 810,816 ---- } /* If no buttons are pressed... */ ! if ((pmer->dwButtonState & ((1 << cButtons) - 1)) == 0) { /* If the last thing returned was MOUSE_RELEASE, ignore this */ if (s_fReleased) *************** *** 816,823 **** } else /* one or more buttons pressed */ { - const int cButtons = GetSystemMetrics(SM_CMOUSEBUTTONS); - /* on a 2-button mouse, hold down left and right buttons * simultaneously to get MIDDLE. */ --- 821,826 ---- *************** *** 1198,1204 **** #ifdef FEAT_CLIENTSERVER (void)WaitForChar(-1L); ! if (!vim_is_input_buf_empty()) return 0; #endif if (ReadConsoleInput(g_hConIn, &ir, 1, &cRecords) == 0) --- 1201,1207 ---- #ifdef FEAT_CLIENTSERVER (void)WaitForChar(-1L); ! if (!vim_is_input_buf_empty() || g_nMouseClick != -1) return 0; #endif if (ReadConsoleInput(g_hConIn, &ir, 1, &cRecords) == 0) *************** *** 1266,1272 **** want_sniff_request = 0; return len; } ! else if(time < 0 || time > 250) { /* don't wait too long, a request might be pending */ time = 250; --- 1269,1275 ---- want_sniff_request = 0; return len; } ! else if (time < 0 || time > 250) { /* don't wait too long, a request might be pending */ time = 250; *** ../vim60.47/src/version.c Wed Oct 31 15:17:54 2001 --- src/version.c Wed Oct 31 15:17:29 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 48, /**/ -- A law to reduce crime states: "It is mandatory for a motorist with criminal intentions to stop at the city limits and telephone the chief of police as he is entering the town. [real standing law in Washington, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.049 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.049 Problem: When using evim the intro screen is misleading. (Adrian Nagle) Solution: Mention whether 'insertmode' is set and the menus to be used. Files: runtime/menu.vim, src/version.c *** ../vim60.48/runtime/menu.vim Tue Oct 30 21:41:46 2001 --- runtime/menu.vim Wed Oct 31 16:47:20 2001 *************** *** 54,64 **** amenu 9999.10 &Help.&Overview :help amenu 9999.20 &Help.&User\ Manual :help usr_toc amenu 9999.30 &Help.&How-to\ links :help how-to ! amenu 9999.40 &Help.&GUI :help gui amenu 9999.50 &Help.&Credits :help credits ! amenu 9999.60 &Help.Co&pying :help uganda ! amenu 9999.70 &Help.&Find\.\.\. :call Helpfind() ! amenu 9999.75 &Help.-sep- amenu 9999.80 &Help.&Version :version amenu 9999.90 &Help.&About :intro --- 54,65 ---- amenu 9999.10 &Help.&Overview :help amenu 9999.20 &Help.&User\ Manual :help usr_toc amenu 9999.30 &Help.&How-to\ links :help how-to ! amenu 9999.40 &Help.&Find\.\.\. :call Helpfind() ! amenu 9999.45 &Help.-sep1- amenu 9999.50 &Help.&Credits :help credits ! amenu 9999.60 &Help.Co&pying :help copying ! amenu 9999.70 &Help.O&rphans :help iccf ! amenu 9999.75 &Help.-sep2- amenu 9999.80 &Help.&Version :version amenu 9999.90 &Help.&About :intro *************** *** 171,176 **** --- 189,195 ---- amenu 20.440.130.70 &Edit.&Global\ Settings.&Virtual\ Edit.Block\ and\ Insert :set ve=block,insert amenu 20.440.130.80 &Edit.&Global\ Settings.&Virtual\ Edit.Always :set ve=all amenu 20.440.140 &Edit.&Global\ Settings.Toggle\ Insert\ &Mode:set\ im! :set im! + amenu 20.440.145 &Edit.&Global\ Settings.Toggle\ Vi\ C&ompatible:set\ cp! :set cp! amenu 20.440.150 &Edit.&Global\ Settings.Search\ &Path\.\.\. :call SearchP() amenu 20.440.160 &Edit.&Global\ Settings.Ta&g\ Files\.\.\. :call TagFiles() " *** ../vim60.48/src/version.c Wed Oct 31 15:20:56 2001 --- src/version.c Wed Oct 31 17:43:13 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 49, /**/ *************** *** 1025,1030 **** --- 1027,1033 ---- int i; int row; int blanklines; + char_u *p; static char *(lines[]) = { N_("VIM - Vi IMproved"), *************** *** 1045,1050 **** --- 1048,1075 ---- N_("type :set nocp for Vim defaults"), N_("type :help cp-default for info on this"), }; + #ifdef FEAT_GUI + static char *(gui_lines[]) = + { + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + N_("menu Help->Orphans for information "), + NULL, + N_("Running modeless, typed text is inserted"), + N_("menu Edit->Global Settings->Toggle Insert Mode "), + N_(" for two modes "), + NULL, + NULL, + NULL, + N_("menu Edit->Global Settings->Toggle Vi Compatible"), + N_(" for Vim defaults "), + }; + #endif /* blanklines = screen height - # message lines */ blanklines = (int)Rows - ((sizeof(lines) / sizeof(char *)) - 1); *************** *** 1069,1082 **** { for (i = 0; i < (int)(sizeof(lines) / sizeof(char *)); ++i) { ! if (lines[i] == NULL) { if (!p_cp) break; continue; } ! if (*lines[i] != NUL) ! do_intro_line(row, (char_u *)_(lines[i]), i == 2, 0); ++row; } #if defined(WIN3264) && !defined(FEAT_GUI_W32) --- 1094,1112 ---- { for (i = 0; i < (int)(sizeof(lines) / sizeof(char *)); ++i) { ! p = lines[i]; ! #ifdef FEAT_GUI ! if (p_im && gui.in_use && gui_lines[i] != NULL) ! p = gui_lines[i]; ! #endif ! if (p == NULL) { if (!p_cp) break; continue; } ! if (*p != NUL) ! do_intro_line(row, (char_u *)_(p), i == 2, 0); ++row; } #if defined(WIN3264) && !defined(FEAT_GUI_W32) -- Living on Earth includes an annual free trip around the Sun. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.050 (corrected version) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.050 Problem: UTF-8: "viw" doesn't include non-ASCII characters before the cursor. (Bertilo Wennergren) Solution: Use dec_cursor() instead of decrementing the column number. Files: src/search.c *** ../vim60.49/src/search.c Fri Sep 14 22:26:10 2001 --- src/search.c Wed Oct 31 20:13:15 2001 *************** *** 2604,2613 **** { if (curwin->w_cursor.col == 0) /* stop at start of line */ break; ! --curwin->w_cursor.col; if (cls() != sclass) /* stop at start of word */ { ! ++curwin->w_cursor.col; break; } } --- 2604,2613 ---- { if (curwin->w_cursor.col == 0) /* stop at start of line */ break; ! dec_cursor(); if (cls() != sclass) /* stop at start of word */ { ! inc_cursor(); break; } } *** ../vim60.49/src/version.c Wed Oct 31 17:50:48 2001 --- src/version.c Wed Oct 31 20:14:29 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 50, /**/ -- Why is "abbreviation" such a long word? /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.051 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.051 Problem: UTF-8: Using CTRL-R on the command line doesn't insert composing characters. (Ron Aaron) Solution: Also include the composing characters and fix redrawing them. Files: src/ex_getln.c, src/ops.c *** ../vim60.50/src/ex_getln.c Wed Sep 19 20:02:13 2001 --- src/ex_getln.c Wed Oct 31 20:41:56 2001 *************** *** 2003,2009 **** if (c != 0) { /* Also backup the cursor position. */ ! c -= ptr2cells(ccline.cmdbuff + ccline.cmdpos); ccline.cmdspos -= c; msg_col -= c; if (msg_col < 0) --- 2003,2009 ---- if (c != 0) { /* Also backup the cursor position. */ ! c = ptr2cells(ccline.cmdbuff + ccline.cmdpos); ccline.cmdspos -= c; msg_col -= c; if (msg_col < 0) *** ../vim60.50/src/ops.c Tue Oct 30 14:52:27 2001 --- src/ops.c Wed Oct 31 20:25:02 2001 *************** *** 1372,1378 **** ++s; #ifdef FEAT_MBYTE if (has_mbyte) ! c = mb_ptr2char_adv(&s); else #endif c = *s++; --- 1372,1381 ---- ++s; #ifdef FEAT_MBYTE if (has_mbyte) ! { ! c = mb_ptr2char(s); ! s += mb_char2len(c); ! } else #endif c = *s++; *** ../vim60.50/src/version.c Wed Oct 31 20:19:20 2001 --- src/version.c Wed Oct 31 20:28:54 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 51, /**/ -- ARTHUR: CHARGE! [The mighty ARMY charges. Thundering noise of feet. Clatter of coconuts. Shouts etc. Suddenly there is a wail of a siren and a couple of police cars roar round in front of the charging ARMY and the POLICE leap out and stop them. TWO POLICEMAN and the HISTORIAN'S WIFE. Black Marias skid up behind them.] HISTORIAN'S WIFE: They're the ones, I'm sure. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.052 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.052 Problem: The check for rlim_t in patch 6.0.046 does not work on some systems. (Zdenek Sekera) Solution: Also look in sys/resource.h for rlim_t. Files: src/auto/configure, src/configure.in *** ../vim60.51/src/auto/configure Wed Oct 31 14:21:02 2001 --- src/auto/configure Wed Oct 31 21:57:52 2001 *************** *** 5145,5163 **** fi echo $ac_n "checking for rlim_t""... $ac_c" 1>&6 ! echo "configure:5150: checking for rlim_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_rlim_t'+set}'`\" = set"; then ! echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS #include #include #endif EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | egrep "(^|[^a-zA-Z_0-9])rlim_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then --- 5145,5169 ---- fi + echo $ac_n "checking for rlim_t""... $ac_c" 1>&6 ! echo "configure:5151: checking for rlim_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_rlim_t'+set}'`\" = set"; then ! echo "$ac_t""(cached) $ac_cv_type_rlim_t" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS #include #include #endif + #ifdef HAVE_SYS_RESOURCE_H + #include + #endif + EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | egrep "(^|[^a-zA-Z_0-9])rlim_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then *************** *** 5169,5194 **** fi rm -f conftest* fi - echo "$ac_t""$ac_cv_type_rlim_t" 1>&6 if test $ac_cv_type_rlim_t = no; then cat >> confdefs.h <<\EOF #define rlim_t unsigned long EOF - fi - echo $ac_n "checking for stack_t""... $ac_c" 1>&6 ! echo "configure:5184: checking for stack_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then echo "$ac_t""(cached) $ac_cv_type_stack_t" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS #include --- 5175,5197 ---- fi rm -f conftest* + echo "$ac_t""$ac_cv_type_rlim_t" 1>&6 fi if test $ac_cv_type_rlim_t = no; then cat >> confdefs.h <<\EOF #define rlim_t unsigned long EOF fi echo $ac_n "checking for stack_t""... $ac_c" 1>&6 ! echo "configure:5188: checking for stack_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then echo "$ac_t""(cached) $ac_cv_type_stack_t" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS #include *** ../vim60.51/src/configure.in Wed Oct 31 14:21:02 2001 --- src/configure.in Wed Oct 31 21:57:50 2001 *************** *** 1405,1411 **** AC_HEADER_TIME AC_CHECK_TYPE(ino_t, long) AC_CHECK_TYPE(dev_t, unsigned) ! AC_CHECK_TYPE(rlim_t, unsigned long) AC_MSG_CHECKING(for stack_t) if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then --- 1405,1436 ---- AC_HEADER_TIME AC_CHECK_TYPE(ino_t, long) AC_CHECK_TYPE(dev_t, unsigned) ! ! AC_MSG_CHECKING(for rlim_t) ! if eval "test \"`echo '$''{'ac_cv_type_rlim_t'+set}'`\" = set"; then ! AC_MSG_RESULT([(cached) $ac_cv_type_rlim_t]) ! else ! AC_EGREP_CPP(dnl ! changequote(<<,>>)dnl ! <<(^|[^a-zA-Z_0-9])rlim_t[^a-zA-Z_0-9]>>dnl ! changequote([,]), ! [ ! #include ! #if STDC_HEADERS ! #include ! #include ! #endif ! #ifdef HAVE_SYS_RESOURCE_H ! #include ! #endif ! ], ac_cv_type_rlim_t=yes, ac_cv_type_rlim_t=no) ! AC_MSG_RESULT($ac_cv_type_rlim_t) ! fi ! if test $ac_cv_type_rlim_t = no; then ! cat >> confdefs.h <<\EOF ! #define rlim_t unsigned long ! EOF ! fi AC_MSG_CHECKING(for stack_t) if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then *************** *** 1413,1419 **** else AC_EGREP_CPP(stack_t, [ - #include "confdefs.h" #include #if STDC_HEADERS #include --- 1438,1443 ---- *** ../vim60.51/src/version.c Wed Oct 31 20:51:33 2001 --- src/version.c Thu Nov 1 12:02:13 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 52, /**/ -- Mushrooms always grow in damp places and so they look like umbrellas. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.053 (extra) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.053 (extra) Problem: Various problems with QNX. Solution: Minor fix for configure. Switch on terminal clipboard support in main.c. Fix "pterm" mouse support. os_qnx.c didn't build without photon. (Julian Kinraid) Files: src/auto/configure, src/configure.in, src/gui_photon.c, src/main.c, src/misc2.c, src/option.h, src/os_qnx.c, src/os_qnx.h, src/syntax.c *** ../vim60.52/src/auto/configure Thu Nov 1 12:04:29 2001 --- src/auto/configure Wed Oct 31 21:57:52 2001 *************** *** 3241,3247 **** case "$enable_gui" in no|No|NO) echo "$ac_t""no GUI support" 1>&6 ! SKIP_QNX=YES ;; yes|Yes|YES|"") echo "$ac_t""yes - automatic GUI support" 1>&6 ;; auto|Auto|AUTO|"") echo "$ac_t""auto - automatic GUI support" 1>&6 ;; photon|Photon|PHOTON) echo "$ac_t""Photon GUI support" 1>&6 ;; --- 3241,3247 ---- case "$enable_gui" in no|No|NO) echo "$ac_t""no GUI support" 1>&6 ! SKIP_PHOTON=YES ;; yes|Yes|YES|"") echo "$ac_t""yes - automatic GUI support" 1>&6 ;; auto|Auto|AUTO|"") echo "$ac_t""auto - automatic GUI support" 1>&6 ;; photon|Photon|PHOTON) echo "$ac_t""Photon GUI support" 1>&6 ;; *** ../vim60.52/src/configure.in Thu Nov 1 12:04:29 2001 --- src/configure.in Wed Oct 31 21:57:50 2001 *************** *** 738,744 **** case "$enable_gui" in no|No|NO) AC_MSG_RESULT(no GUI support) ! SKIP_QNX=YES ;; yes|Yes|YES|"") AC_MSG_RESULT(yes - automatic GUI support) ;; auto|Auto|AUTO|"") AC_MSG_RESULT(auto - automatic GUI support) ;; photon|Photon|PHOTON) AC_MSG_RESULT(Photon GUI support) ;; --- 738,744 ---- case "$enable_gui" in no|No|NO) AC_MSG_RESULT(no GUI support) ! SKIP_PHOTON=YES ;; yes|Yes|YES|"") AC_MSG_RESULT(yes - automatic GUI support) ;; auto|Auto|AUTO|"") AC_MSG_RESULT(auto - automatic GUI support) ;; photon|Photon|PHOTON) AC_MSG_RESULT(Photon GUI support) ;; *** ../vim60.52/src/gui_photon.c Sun Sep 2 14:29:10 2001 --- src/gui_photon.c Tue Oct 23 17:30:22 2001 *************** *** 137,145 **** {Pk_F30, 'F', 'K'}, {Pk_F31, 'F', 'L'}, {Pk_F32, 'F', 'M'}, ! {Pk_F33, 'F', 'O'}, ! {Pk_F34, 'F', 'P'}, ! {Pk_F35, 'F', 'Q'}, {Pk_Help, '%', '1'}, {Pk_BackSpace, 'k', 'b'}, --- 137,145 ---- {Pk_F30, 'F', 'K'}, {Pk_F31, 'F', 'L'}, {Pk_F32, 'F', 'M'}, ! {Pk_F33, 'F', 'N'}, ! {Pk_F34, 'F', 'O'}, ! {Pk_F35, 'F', 'P'}, {Pk_Help, '%', '1'}, {Pk_BackSpace, 'k', 'b'}, *************** *** 488,497 **** { /* Detect if a keypad number key has been pressed * and change the key if Num Lock is on */ ! if( key->key_cap >= Pk_KP_0 && key->key_cap <= Pk_KP_9 && ( key->key_mods & Pk_KM_Num_Lock ) ) { ! ch = TO_SPECIAL( 'K', key->key_cap - Pk_KP_0 + 'C' ); } else ch = TO_SPECIAL( special_keys[i].vim_code0, --- 488,499 ---- { /* Detect if a keypad number key has been pressed * and change the key if Num Lock is on */ ! if( key->key_cap >= Pk_KP_Enter && key->key_cap <= Pk_KP_9 && ( key->key_mods & Pk_KM_Num_Lock ) ) { ! /* FIXME: For now, just map the key to a ascii value ! * (see ) */ ! ch = key->key_cap - 0xf080; } else ch = TO_SPECIAL( special_keys[i].vim_code0, *************** *** 924,933 **** } static void ! gui_ph_get_panelgroup_margins( short *top, short *bottom, short *left, short *right ) { unsigned short abs_raw_x, abs_raw_y, abs_panel_x, abs_panel_y; ! const unsigned short *margin_top, *margin_bottom, *margin_left, *margin_right; PtGetAbsPosition( gui.vimTextArea, &abs_raw_x, &abs_raw_y ); PtGetAbsPosition( gui.vimPanelGroup, &abs_panel_x, &abs_panel_y ); --- 926,940 ---- } static void ! gui_ph_get_panelgroup_margins( ! short *top, ! short *bottom, ! short *left, ! short *right ) { unsigned short abs_raw_x, abs_raw_y, abs_panel_x, abs_panel_y; ! const unsigned short *margin_top, *margin_bottom; ! const unsigned short *margin_left, *margin_right; PtGetAbsPosition( gui.vimTextArea, &abs_raw_x, &abs_raw_y ); PtGetAbsPosition( gui.vimPanelGroup, &abs_panel_x, &abs_panel_y ); *************** *** 1318,1349 **** /****************************************************************************/ /* events */ void gui_mch_update(void) { ! int working = -1; ! while( working && !vim_is_input_buf_full()) { ! switch( PhEventPeek( gui.event_buffer, EVENT_BUFFER_SIZE ) ) ! { ! case 0: /* No messages */ ! working = 0; ! break; ! ! case Ph_EVENT_MSG: ! PtEventHandler( gui.event_buffer ); ! break; ! ! case -1: ! perror( "gui_mch_update: PhEventPeek failed" ); ! working = 0; ! break; ! default: ! perror( "PhEventPeek default reached" ); ! working = 0; ! break; ! } } } --- 1325,1348 ---- /****************************************************************************/ /* events */ + /* When no events are available, photon will call this function, working is + * set to FALSE, and the gui_mch_update loop will exit. */ + static int + exit_gui_mch_update( void *data ) + { + *(int *)data = FALSE; + return( Pt_END ); + } + void gui_mch_update(void) { ! int working = TRUE; ! PtAppAddWorkProc( NULL, exit_gui_mch_update, &working ); ! while( ( working == TRUE ) && !vim_is_input_buf_full()) { ! PtProcessEvent(); } } *************** *** 1357,1385 **** while( 1 ) { ! switch( PhEventNext( gui.event_buffer, EVENT_BUFFER_SIZE ) ) { ! case Ph_EVENT_MSG: ! PtEventHandler( gui.event_buffer ); ! if( !vim_is_input_buf_empty() ) ! { ! PtSetResource( gui_ph_timer_timeout, Pt_ARG_TIMER_INITIAL, 0, 0 ); ! return( OK ); ! } ! else if( is_timeout == TRUE ) ! return( FAIL ); ! ! break; ! ! case Ph_RESIZE_MSG: ! /* FIXME */ ! return( FAIL ); ! break; ! ! case -1: ! perror( "PhEventNext" ); ! return( FAIL ); } } } --- 1356,1369 ---- while( 1 ) { ! PtProcessEvent(); ! if( !vim_is_input_buf_empty() ) { ! PtSetResource( gui_ph_timer_timeout, Pt_ARG_TIMER_INITIAL, 0, 0 ); ! return( OK ); } + else if( is_timeout == TRUE ) + return( FAIL ); } } *************** *** 1577,1585 **** button_count, (const char **) button_array, NULL, default_button, 0, Pt_MODAL ); #else ! /* PtPrompt doesn't work if you're not using PtMainLoop(), so create the dialog directly. ! * It does give us the option ofadding extra features, like trapping the escape key and ! * returning 0 to vim */ { int n; PtArg_t args[5]; --- 1561,1568 ---- button_count, (const char **) button_array, NULL, default_button, 0, Pt_MODAL ); #else ! /* Writing the dialog ourselves lets us add extra features, like ! * trapping the escape key and returning 0 to vim */ { int n; PtArg_t args[5]; *************** *** 2384,2390 **** /* Only turn on the timer on if none of the times are zero */ if( blink_waittime && blink_ontime && blink_offtime && gui.in_focus) { ! PtSetResource( gui_ph_timer_cursor, Pt_ARG_TIMER_INITIAL, blink_waittime, 0 ); blink_state = BLINK_ON; gui_update_cursor(TRUE, FALSE); } --- 2367,2374 ---- /* Only turn on the timer on if none of the times are zero */ if( blink_waittime && blink_ontime && blink_offtime && gui.in_focus) { ! PtSetResource( gui_ph_timer_cursor, Pt_ARG_TIMER_INITIAL, ! blink_waittime, 0 ); blink_state = BLINK_ON; gui_update_cursor(TRUE, FALSE); } *************** *** 2792,2798 **** PtWidgetIsClass( PtWidgetParent( menu->id ), PtMenu ) ) { fields = Pt_FALSE; ! mask = Pt_SELECTABLE; } else { --- 2776,2782 ---- PtWidgetIsClass( PtWidgetParent( menu->id ), PtMenu ) ) { fields = Pt_FALSE; ! mask = Pt_SELECTABLE | Pt_HIGHLIGHTED; } else { *** ../vim60.52/src/main.c Fri Sep 21 20:27:36 2001 --- src/main.c Tue Oct 23 17:30:22 2001 *************** *** 167,174 **** (void)mb_init(); /* init mb_bytelen_tab[] to ones */ #endif ! #ifdef __QNX__ ! qnx_init(); /* PhAttach() for clipboard, mouse (and gui) */ #endif #ifdef FEAT_GUI_MAC --- 167,174 ---- (void)mb_init(); /* init mb_bytelen_tab[] to ones */ #endif ! #ifdef __QNXNTO__ ! qnx_init(); /* PhAttach() for clipboard, (and gui) */ #endif #ifdef FEAT_GUI_MAC *************** *** 1424,1429 **** --- 1424,1433 ---- gui_wait_for_chars(50L); TIME_MSG("GUI delay"); } + #endif + + #if defined(FEAT_GUI_PHOTON) && defined(FEAT_CLIPBOARD) + qnx_clip_init(); #endif #ifdef FEAT_XCLIPBOARD *** ../vim60.52/src/misc2.c Mon Oct 29 17:19:02 2001 --- src/misc2.c Mon Oct 29 17:14:44 2001 *************** *** 1829,1834 **** --- 1829,1835 ---- {K_NETTERM_MOUSE, (char_u *)"NetMouse"}, {K_DEC_MOUSE, (char_u *)"DecMouse"}, {K_JSBTERM_MOUSE, (char_u *)"JsbMouse"}, + {K_PTERM_MOUSE, (char_u *)"PtermMouse"}, {K_LEFTMOUSE, (char_u *)"LeftMouse"}, {K_LEFTMOUSE_NM, (char_u *)"LeftMouseNM"}, {K_LEFTDRAG, (char_u *)"LeftDrag"}, *** ../vim60.52/src/option.h Sun Sep 16 15:03:16 2001 --- src/option.h Tue Oct 23 17:30:22 2001 *************** *** 661,667 **** EXTERN char_u *p_ttym; /* 'ttymouse' */ EXTERN unsigned ttym_flags; # ifdef IN_OPTION_C ! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", NULL}; # endif # define TTYM_XTERM 0x01 # define TTYM_XTERM2 0x02 --- 661,667 ---- EXTERN char_u *p_ttym; /* 'ttymouse' */ EXTERN unsigned ttym_flags; # ifdef IN_OPTION_C ! static char *(p_ttym_values[]) = {"xterm", "xterm2", "dec", "netterm", "jsbterm", "pterm", NULL}; # endif # define TTYM_XTERM 0x01 # define TTYM_XTERM2 0x02 *** ../vim60.52/src/os_qnx.c Thu Apr 5 12:13:43 2001 --- src/os_qnx.c Tue Oct 23 17:30:22 2001 *************** *** 15,41 **** #include "vim.h" int is_photon_available; ! void qnx_init() { ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) ! is_photon_available = (PhAttach( NULL, NULL ) != NULL) ? TRUE : FALSE; #endif } ! #if defined(FEAT_CLIPBOARD) || defined(PROTO) ! #define CLIP_TYPE_VIM "TEXTVIM" #define CLIP_TYPE_TEXT "TEXT" void qnx_clip_init() { ! if( is_photon_available == TRUE ) ! { clip_init( TRUE ); - } } /*****************************************************************************/ --- 15,46 ---- #include "vim.h" + #if defined(FEAT_GUI_PHOTON) int is_photon_available; ! #endif void qnx_init() { ! #if defined(FEAT_GUI_PHOTON) ! PhChannelParms_t parms; ! ! memset( &parms, 0, sizeof( parms ) ); ! parms.flags = Ph_DYNAMIC_BUFFER; ! ! is_photon_available = (PhAttach( NULL, &parms ) != NULL) ? TRUE : FALSE; #endif } ! #if (defined(FEAT_GUI_PHOTON) && defined(FEAT_CLIPBOARD)) || defined(PROTO) ! #define CLIP_TYPE_VIM "VIMTYPE" #define CLIP_TYPE_TEXT "TEXT" + /* Turn on the clipboard for a console vim when photon is running */ void qnx_clip_init() { ! if( is_photon_available == TRUE && !gui.in_use) clip_init( TRUE ); } /*****************************************************************************/ *************** *** 56,62 **** void clip_mch_request_selection( VimClipboard *cbd ) { ! int type = MLINE, clip_length = 0; void *cbdata; PhClipHeader *clip_header; char_u *clip_text = NULL; --- 61,67 ---- void clip_mch_request_selection( VimClipboard *cbd ) { ! int type = MLINE, clip_length = 0, is_type_set = FALSE; void *cbdata; PhClipHeader *clip_header; char_u *clip_text = NULL; *************** *** 66,101 **** { /* Look for the vim specific clip first */ clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_VIM ); ! if( clip_header != NULL ) { ! clip_text = clip_header->data; ! /* Skip past the initial type specifier */ ! /* clip_header->length also includes the trailing NUL */ ! clip_length = clip_header->length - 2; ! ! if( clip_text != NULL ) { ! switch( *clip_text++ ) ! { ! default: /* fallthrough to line type */ ! case 'L': type = MLINE; break; ! case 'C': type = MCHAR; break; ! case 'B': type = MBLOCK; break; ! } } } ! else { ! /* Try for just normal text */ ! clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_TEXT ); ! if( clip_header != NULL ) ! { ! clip_text = clip_header->data; ! clip_length = clip_header->length - 1; ! if( clip_text != NULL ) ! type = (strchr( clip_text, '\r' ) != NULL) ? MLINE : MCHAR; ! } } if( (clip_text != NULL) && (clip_length > 0) ) --- 71,97 ---- { /* Look for the vim specific clip first */ clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_VIM ); ! if( clip_header != NULL && clip_header->data != NULL ) { ! switch( *(char *) clip_header->data ) { ! default: /* fallthrough to line type */ ! case 'L': type = MLINE; break; ! case 'C': type = MCHAR; break; ! case 'B': type = MBLOCK; break; } + is_type_set = TRUE; } ! ! /* Try for just normal text */ ! clip_header = PhClipboardPasteType( cbdata, CLIP_TYPE_TEXT ); ! if( clip_header != NULL ) { ! clip_text = clip_header->data; ! clip_length = clip_header->length - 1; ! if( clip_text != NULL && is_type_set == FALSE ) ! type = (strchr( clip_text, '\r' ) != NULL) ? MLINE : MCHAR; } if( (clip_text != NULL) && (clip_length > 0) ) *************** *** 112,118 **** { int type; long_u len; ! char_u *text_clip, *vim_clip, *str = NULL; cbd->owned = TRUE; clip_get_selection( cbd ); --- 108,119 ---- { int type; long_u len; ! char_u *text_clip, vim_clip[2], *str = NULL; ! PhClipHeader clip_header[2]; ! ! /* Prevent recursion from clip_get_selection() */ ! if( cbd->owned == TRUE ) ! return; cbd->owned = TRUE; clip_get_selection( cbd ); *************** *** 122,135 **** if( type >= 0 ) { text_clip = lalloc( len + 1, TRUE ); /* Normal text */ - vim_clip = lalloc( len + 2, TRUE ); /* vim specific info + text */ if( text_clip && vim_clip ) { ! PhClipHeader clip_header[2]; STRNCPY( clip_header[0].type, CLIP_TYPE_VIM, 8 ); ! clip_header[0].length = len + 2; clip_header[0].data = vim_clip; STRNCPY( clip_header[1].type, CLIP_TYPE_TEXT, 8 ); --- 123,135 ---- if( type >= 0 ) { text_clip = lalloc( len + 1, TRUE ); /* Normal text */ if( text_clip && vim_clip ) { ! memset( clip_header, 0, sizeof( clip_header ) ); STRNCPY( clip_header[0].type, CLIP_TYPE_VIM, 8 ); ! clip_header[0].length = sizeof( vim_clip ); clip_header[0].data = vim_clip; STRNCPY( clip_header[1].type, CLIP_TYPE_TEXT, 8 ); *************** *** 147,159 **** STRNCPY( text_clip, str, len ); text_clip[ len ] = NUL; ! STRNCPY( vim_clip + 1, str, len ); ! vim_clip[ len + 1 ] = NUL; PhClipboardCopy( PhInputGroup( NULL ), 2, clip_header); } vim_free( text_clip ); - vim_free( vim_clip ); } vim_free( str ); } --- 147,157 ---- STRNCPY( text_clip, str, len ); text_clip[ len ] = NUL; ! vim_clip[ 1 ] = NUL; PhClipboardCopy( PhInputGroup( NULL ), 2, clip_header); } vim_free( text_clip ); } vim_free( str ); } *** ../vim60.52/src/os_qnx.h Tue Aug 28 17:42:00 2001 --- src/os_qnx.h Tue Oct 23 17:30:22 2001 *************** *** 14,19 **** #define POSIX /* Used by pty.c */ ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) extern int is_photon_available; #endif --- 14,19 ---- #define POSIX /* Used by pty.c */ ! #if defined(FEAT_GUI_PHOTON) extern int is_photon_available; #endif *** ../vim60.52/src/syntax.c Wed Oct 31 11:17:27 2001 --- src/syntax.c Wed Oct 31 11:11:24 2001 *************** *** 6493,6498 **** --- 6493,6504 ---- 4+8, 4+8, 2+8, 2+8, 6+8, 6+8, 1+8, 1+8, 5+8, 5+8, 3+8, 3+8, 7+8, -1}; + #if defined(__QNXNTO__) + static int *color_numbers_8_qansi = color_numbers_8; + /* On qnx, the 8 & 16 color arrays are the same */ + if (STRNCMP(T_NAME, "qansi", 5) == 0) + color_numbers_8_qansi = color_numbers_16; + #endif /* reduce calls to STRICMP a bit, it can be slow */ off = TO_UPPER(*arg); *************** *** 6514,6520 **** --- 6520,6530 ---- if (t_colors == 8) { /* t_Co is 8: use the 8 colors table */ + #if defined(__QNXNTO__) + color = color_numbers_8_qansi[i]; + #else color = color_numbers_8[i]; + #endif if (key[5] == 'F') { /* set/reset bold attribute to get light foreground *** ../vim60.52/src/version.c Thu Nov 1 12:04:29 2001 --- src/version.c Thu Nov 1 12:18:27 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 53, /**/ -- A M00se once bit my sister ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.054 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.054 Problem: When using mswin.vim, CTRL-V pastes a block of text like it is normal text. Using CTRL-V in blockwise Visual mode leaves "x" characters behind. Solution: Make CTRL-V work as it should. Do the same for the Paste menu entries. Files: runtime/menu.vim, runtime/mswin.vim *** ../vim60.53/runtime/menu.vim Wed Oct 31 17:50:48 2001 --- runtime/menu.vim Wed Oct 31 16:47:20 2001 *************** *** 112,119 **** amenu 10.610 &File.Sa&ve-Exit:wqa :confirm wqa amenu 10.620 &File.E&xit:qa :confirm qa ! " Tricky stuff to make pasting work as expected. ! nnoremap Paste "=@+.'xy'gPFx"_2x:echo " Edit menu amenu 20.310 &Edit.&Undou u --- 112,131 ---- amenu 10.610 &File.Sa&ve-Exit:wqa :confirm wqa amenu 10.620 &File.E&xit:qa :confirm qa ! " Pasting blockwise and linewise selections is not possible in Insert and ! " Visual mode without the +virtualedit feature. They are pasted as if they ! " were characterwise instead. ! if has("virtualedit") ! nnoremap Paste :call Paste() ! func! Paste() ! let ove = &ve ! set ve=all ! normal `^"+gPi ! let &ve = ove ! endfunc ! else ! nnoremap Paste "=@+.'xy'gPFx"_2x ! endif " Edit menu amenu 20.310 &Edit.&Undou u *************** *** 123,132 **** vmenu 20.340 &Edit.Cu&t"+x "+x vmenu 20.350 &Edit.&Copy"+y "+y cmenu 20.350 &Edit.&Copy"+y ! nmenu 20.360 &Edit.&Paste"+P Paste ! vmenu &Edit.&Paste"+P "-cxPaste"_x ! imenu &Edit.&Paste"+P xPaste"_s cmenu &Edit.&Paste"+P + nmenu 20.370 &Edit.Put\ &Before[p [p imenu &Edit.Put\ &Before[p [p nmenu 20.380 &Edit.Put\ &After]p ]p --- 135,149 ---- vmenu 20.340 &Edit.Cu&t"+x "+x vmenu 20.350 &Edit.&Copy"+y "+y cmenu 20.350 &Edit.&Copy"+y ! nmenu 20.360 &Edit.&Paste"+P "+gP cmenu &Edit.&Paste"+P + + if has("virtualedit") + vmenu &Edit.&Paste"+P "-cPaste + imenu &Edit.&Paste"+P Pastegi + else + vmenu &Edit.&Paste"+P "-cgixPaste"_x + imenu &Edit.&Paste"+P xPaste"_s + endif nmenu 20.370 &Edit.Put\ &Before[p [p imenu &Edit.Put\ &Before[p [p nmenu 20.380 &Edit.Put\ &After]p ]p *************** *** 689,704 **** vmenu 1.20 PopUp.Cu&t "+x vmenu 1.30 PopUp.&Copy "+y cmenu 1.30 PopUp.&Copy ! nmenu 1.40 PopUp.&Paste Paste ! vmenu 1.40 PopUp.&Paste "-cxPaste"_x ! imenu 1.40 PopUp.&Paste xPaste"_s cmenu 1.40 PopUp.&Paste + vmenu 1.50 PopUp.&Delete x amenu 1.55 PopUp.-SEP2- : ! vnoremenu 1.60 PopUp.Select\ Blockwise anoremenu 1.70 PopUp.Select\ &Word vaw anoremenu 1.80 PopUp.Select\ &Line V ! anoremenu 1.90 PopUp.Select\ &Block anoremenu 1.100 PopUp.Select\ &All ggVG " The GUI toolbar (for MS-Windows and GTK) --- 706,726 ---- vmenu 1.20 PopUp.Cu&t "+x vmenu 1.30 PopUp.&Copy "+y cmenu 1.30 PopUp.&Copy ! nmenu 1.40 PopUp.&Paste "+gP cmenu 1.40 PopUp.&Paste + + if has("virtualedit") + vmenu 1.40 PopUp.&Paste "-cPaste + imenu 1.40 PopUp.&Paste Pastegi + else + vmenu 1.40 PopUp.&Paste "-cgixPaste"_x + imenu 1.40 PopUp.&Paste xPaste"_s + endif vmenu 1.50 PopUp.&Delete x amenu 1.55 PopUp.-SEP2- : ! vnoremenu 1.60 PopUp.Select\ Blockwise anoremenu 1.70 PopUp.Select\ &Word vaw anoremenu 1.80 PopUp.Select\ &Line V ! anoremenu 1.90 PopUp.Select\ &Block anoremenu 1.100 PopUp.Select\ &All ggVG " The GUI toolbar (for MS-Windows and GTK) *************** *** 725,734 **** vmenu 1.70 ToolBar.Cut "+x vmenu 1.80 ToolBar.Copy "+y cmenu 1.80 ToolBar.Copy ! nmenu 1.90 ToolBar.Paste Paste ! vmenu ToolBar.Paste "-cxPaste"_x ! imenu ToolBar.Paste xPaste"_s cmenu ToolBar.Paste + if !has("gui_athena") amenu 1.95 ToolBar.-sep3- --- 747,761 ---- vmenu 1.70 ToolBar.Cut "+x vmenu 1.80 ToolBar.Copy "+y cmenu 1.80 ToolBar.Copy ! nmenu 1.90 ToolBar.Paste "+gP cmenu ToolBar.Paste + + if has("virtualedit") + vmenu ToolBar.Paste "-cPaste + imenu ToolBar.Paste Pastegi + else + vmenu ToolBar.Paste "-cgixPaste"_x + imenu ToolBar.Paste xPaste"_s + endif if !has("gui_athena") amenu 1.95 ToolBar.-sep3- *** ../vim60.53/runtime/mswin.vim Thu Aug 23 13:50:05 2001 --- runtime/mswin.vim Tue Oct 30 14:41:41 2001 *************** *** 1,7 **** " Set options and add mapping such that Vim behaves a lot like MS-Windows " " Maintainer: Bram Moolenaar ! " Last change: 2001 Aug 23 " set the 'cpoptions' to its Vim default if 1 " only do this when compiled with expression evaluation --- 1,7 ---- " Set options and add mapping such that Vim behaves a lot like MS-Windows " " Maintainer: Bram Moolenaar ! " Last change: 2001 Oct 30 " set the 'cpoptions' to its Vim default if 1 " only do this when compiled with expression evaluation *************** *** 27,44 **** vnoremap "+y " CTRL-V and SHIFT-Insert are Paste ! nnoremap Paste "=@+.'xy'gPFx"_2x ! map Paste ! map Paste ! ! imap xPaste"_s ! imap xPaste"_s cmap + cmap + ! vmap "-cxPaste"_x ! vmap "-cxPaste"_x " Use CTRL-Q to do what CTRL-V used to do noremap --- 27,58 ---- vnoremap "+y " CTRL-V and SHIFT-Insert are Paste ! map "+gP ! map "+gP cmap + cmap + ! " Pasting blockwise and linewise selections is not possible in Insert and ! " Visual mode without the +virtualedit feature. They are pasted as if they ! " were characterwise instead. ! if has("virtualedit") ! nnoremap Paste :call Paste() ! func! Paste() ! let ove = &ve ! set ve=all ! normal `^"+gPi ! let &ve = ove ! endfunc ! imap Pastegi ! vmap "-cPaste ! else ! nnoremap Paste "=@+.'xy'gPFx"_2x ! imap xPaste"_s ! vmap "-cgixPaste"_x ! endif ! imap ! vmap " Use CTRL-Q to do what CTRL-V used to do noremap *** ../vim60.53/src/version.c Thu Nov 1 12:22:41 2001 --- src/version.c Thu Nov 1 14:29:48 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 54, /**/ -- SUPERIMPOSE "England AD 787". After a few more seconds we hear hoofbeats in the distance. They come slowly closer. Then out of the mist comes KING ARTHUR followed by a SERVANT who is banging two half coconuts together. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.055 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.055 Problem: GTK: The selection isn't copied the first time. Solution: Own the selection at the right moment. Files: src/gui_gtk_x11.c *** ../vim60.54/src/gui_gtk_x11.c Thu Oct 25 10:20:46 2001 --- src/gui_gtk_x11.c Thu Nov 1 14:14:30 2001 *************** *** 871,877 **** * Selection handlers: */ - /*ARGSUSED*/ static gint selection_clear_event(GtkWidget * widget, GdkEventSelection * event) --- 871,876 ---- *************** *** 3521,3563 **** } } void clip_mch_lose_selection(cbd) VimClipboard *cbd; { ! gtk_selection_owner_set(gui.drawarea, cbd->gtk_sel_atom, ! (guint32)GDK_CURRENT_TIME); gui_mch_update(); } /* ! * Check whatever we allready own the selection. */ int clip_mch_own_selection(cbd) VimClipboard *cbd; { ! if (cbd == &clip_star) ! { ! /* At this point we always already own the selection - apparently */ return OK; ! } ! else ! { ! return gdk_selection_owner_get(clip_plus.gtk_sel_atom) == gui.drawarea->window; ! } } /* ! * Send the current selection to the clipboard. */ void clip_mch_set_selection(cbd) VimClipboard* cbd; { - gtk_selection_owner_set(gui.drawarea, cbd->gtk_sel_atom, - (guint32)GDK_CURRENT_TIME); - gui_mch_update(); } --- 3520,3565 ---- } } + /* + * Disown the selection. + */ void clip_mch_lose_selection(cbd) VimClipboard *cbd; { ! /* WEIRD: when using NULL to actually disown the selection, we lose the ! * selection the first time we own it. */ ! /* ! gtk_selection_owner_set(NULL, cbd->gtk_sel_atom, (guint32)GDK_CURRENT_TIME); gui_mch_update(); + */ } /* ! * Own the selection and return OK if it worked. */ int clip_mch_own_selection(cbd) VimClipboard *cbd; { ! int r; ! ! r = gtk_selection_owner_set(gui.drawarea, cbd->gtk_sel_atom, ! (guint32)GDK_CURRENT_TIME); ! gui_mch_update(); ! if (r) return OK; ! return FAIL; } /* ! * Send the current selection to the clipboard. Do nothing for X because we ! * will fill in the selection only when requested by another app. */ void clip_mch_set_selection(cbd) VimClipboard* cbd; { } *** ../vim60.54/src/version.c Thu Nov 1 14:37:02 2001 --- src/version.c Thu Nov 1 14:38:27 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 55, /**/ -- ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of Camelot. King of all Britons, defeator of the Saxons, sovereign of all England! [Pause] SOLDIER: Get away! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.056 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.056 Problem: Using "CTRL-O cw" in Insert mode results in a nested Insert mode. doesn't leave Insert mode then. Solution: Only use nested Insert mode when 'insertmode' is set or when a mapping is used. Files: src/normal.c *** ../vim60.55/src/normal.c Wed Oct 31 11:56:35 2001 --- src/normal.c Wed Oct 31 11:51:54 2001 *************** *** 1730,1737 **** { /* This is a new edit command, not a restart. Need to * remember it to make 'insertmode' work with mappings for ! * Visual mode. But do this only once. */ ! restart_edit_save = restart_edit; restart_edit = 0; if (op_change(oap)) /* will call edit() */ cap->retval |= CA_COMMAND_BUSY; --- 1729,1740 ---- { /* This is a new edit command, not a restart. Need to * remember it to make 'insertmode' work with mappings for ! * Visual mode. But do this only once and not when typed and ! * 'insertmode' isn't set. */ ! if (p_im || !KeyTyped) ! restart_edit_save = restart_edit; ! else ! restart_edit_save = 0; restart_edit = 0; if (op_change(oap)) /* will call edit() */ cap->retval |= CA_COMMAND_BUSY; *** ../vim60.55/src/version.c Thu Nov 1 14:41:29 2001 --- src/version.c Thu Nov 1 14:43:11 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 56, /**/ -- The problem with political jokes is that they get elected. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.057 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.057 Problem: Using ":wincmd g}" in a function doesn't work. (Gary Holloway) Solution: Execute the command directly, instead of putting it in the typeahead buffer. Files: src/normal.c, src/proto/normal.pro, src/window.c *** ../vim60.56/src/normal.c Thu Nov 1 14:44:27 2001 --- src/normal.c Wed Oct 31 11:51:54 2001 *************** *** 80,86 **** static void nv_ctrlo __ARGS((cmdarg_T *cap)); static void nv_hat __ARGS((cmdarg_T *cap)); static void nv_Zet __ARGS((cmdarg_T *cap)); - static void nv_ident __ARGS((cmdarg_T *cap)); #ifdef FEAT_VISUAL static int get_visual_text __ARGS((cmdarg_T *cap, char_u **pp, int *lenp)); #endif --- 80,85 ---- *************** *** 4546,4552 **** * [g] '#' ? to current identifier or string * g ']' :tselect for current identifier */ ! static void nv_ident(cap) cmdarg_T *cap; { --- 4545,4551 ---- * [g] '#' ? to current identifier or string * g ']' :tselect for current identifier */ ! void nv_ident(cap) cmdarg_T *cap; { *** ../vim60.56/src/proto/normal.pro Tue Sep 25 21:49:21 2001 --- src/proto/normal.pro Tue Oct 23 21:19:27 2001 *************** *** 16,21 **** --- 16,22 ---- void do_check_scrollbind __ARGS((int check)); void check_scrollbind __ARGS((linenr_T topline_diff, long leftcol_diff)); void scroll_redraw __ARGS((int up, long count)); + void nv_ident __ARGS((cmdarg_T *cap)); void start_selection __ARGS((void)); void may_start_select __ARGS((int c)); /* vim: set ft=c : */ *** ../vim60.56/src/window.c Fri Sep 14 21:55:06 2001 --- src/window.c Tue Oct 23 21:17:35 2001 *************** *** 526,533 **** postponed_split = Prenum; else postponed_split = -1; ! stuffcharReadbuff('g'); ! stuffcharReadbuff(xchar); break; default: --- 526,545 ---- postponed_split = Prenum; else postponed_split = -1; ! ! /* Execute the command right here, required when ! * "wincmd g}" was used in a function. */ ! { ! oparg_T oa; ! cmdarg_T ca; ! ! clear_oparg(&oa); ! vim_memset(&ca, 0, sizeof(ca)); ! ca.oap = &oa; ! ca.cmdchar = 'g'; ! ca.nchar = xchar; ! nv_ident(&ca); ! } break; default: *** ../vim60.56/src/version.c Thu Nov 1 14:44:27 2001 --- src/version.c Thu Nov 1 14:49:56 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 57, /**/ -- SOLDIER: What? Ridden on a horse? ARTHUR: Yes! SOLDIER: You're using coconuts! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.058 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.058 Problem: When a Cursorhold autocommand moved the cursor, the ruler wasn't updated. (Bohdan Vlasyuk) Solution: Update the ruler after executing the autocommands. Files: src/gui.c *** ../vim60.57/src/gui.c Fri Sep 28 17:48:07 2001 --- src/gui.c Sat Sep 29 17:17:40 2001 *************** *** 2374,2379 **** --- 2374,2381 ---- { apply_autocmds(EVENT_CURSORHOLD, NULL, NULL, FALSE, curbuf); update_screen(VALID); + showruler(FALSE); + setcursor(); once_already = 1; retval = 0; *** ../vim60.57/src/version.c Thu Nov 1 14:51:27 2001 --- src/version.c Thu Nov 1 14:55:18 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 58, /**/ -- SOLDIER: Where did you get the coconuts? ARTHUR: Through ... We found them. SOLDIER: Found them? In Mercea. The coconut's tropical! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.059 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.059 Problem: Highlighting for 'hlsearch' isn't visible in lines that are highlighted for diff highlighting. (Gary Holloway) Solution: Let 'hlsearch' highlighting overrule diff highlighting. Files: src/screen.c *** ../vim60.58/src/screen.c Mon Oct 29 14:40:42 2001 --- src/screen.c Mon Oct 29 14:36:57 2001 *************** *** 3072,3078 **** if (attr == 0 || area_attr != attr) area_attr = diff_attr; if (attr == 0 || char_attr != attr) ! char_attr = diff_attr; } #endif } --- 3072,3083 ---- if (attr == 0 || area_attr != attr) area_attr = diff_attr; if (attr == 0 || char_attr != attr) ! { ! if (search_attr != 0) ! char_attr = search_attr; ! else ! char_attr = diff_attr; ! } } #endif } *** ../vim60.58/src/version.c Thu Nov 1 14:56:27 2001 --- src/version.c Thu Nov 1 14:58:21 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 59, /**/ -- ARTHUR: The swallow may fly south with the sun, or the house martin or the plover seek warmer hot lands in winter, yet these are not strangers to our land. SOLDIER: Are you suggesting coconuts migrate? "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.060 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.060 Problem: Motif: When the tooltip is to be popped up, Vim crashes. (Gary Holloway) Solution: Check for a NULL return value from gui_motif_fontset2fontlist(). Files: src/gui_beval.c *** ../vim60.59/src/gui_beval.c Thu Sep 13 21:09:25 2001 --- src/gui_beval.c Wed Oct 24 14:12:09 2001 *************** *** 148,154 **** { win_T *wp; int row, col; - int i; char_u *lbuf; linenr_T lnum; --- 148,153 ---- *************** *** 431,438 **** XmFontList fl; fl = gui_motif_fontset2fontlist(&gui.tooltip_fontset); ! XmStringExtent(fl, s, &w, &h); ! XmFontListFree(fl); } w += gui.border_offset << 1; h += gui.border_offset << 1; --- 430,440 ---- XmFontList fl; fl = gui_motif_fontset2fontlist(&gui.tooltip_fontset); ! if (fl != NULL) ! { ! XmStringExtent(fl, s, &w, &h); ! XmFontListFree(fl); ! } } w += gui.border_offset << 1; h += gui.border_offset << 1; *** ../vim60.59/src/version.c Thu Nov 1 14:59:19 2001 --- src/version.c Thu Nov 1 15:02:52 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 60, /**/ -- SOLDIER: What? A swallow carrying a coconut? ARTHUR: It could grip it by the husk ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.061 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.061 Problem: The toolbar buttons to load and save a session do not correctly use v:this_session. Solution: Check for v:this_session to be empty instead of existing. Files: runtime/menu.vim *** ../vim60.60/runtime/menu.vim Thu Nov 1 14:37:02 2001 --- runtime/menu.vim Wed Oct 31 16:47:20 2001 *************** *** 839,858 **** " Select a session to load; default to current session name if present fun! s:LoadVimSesn() ! if exists("this_session") ! let name = this_session else ! let name = "session.vim" endif execute "browse so " . name endfun " Select a session to save; default to current session name if present fun! s:SaveVimSesn() ! if !exists("this_session") ! let this_session = "session.vim" endif ! execute "browse mksession! " . this_session endfun endif --- 839,858 ---- " Select a session to load; default to current session name if present fun! s:LoadVimSesn() ! if strlen(v:this_session) > 0 ! let name = v:this_session else ! let name = "Session.vim" endif execute "browse so " . name endfun " Select a session to save; default to current session name if present fun! s:SaveVimSesn() ! if strlen(v:this_session) == 0 ! let v:this_session = "Session.vim" endif ! execute "browse mksession! " . v:this_session endfun endif *** ../vim60.60/src/version.c Thu Nov 1 15:03:42 2001 --- src/version.c Thu Nov 1 15:21:01 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 61, /**/ -- SECOND SOLDIER: It could be carried by an African swallow! FIRST SOLDIER: Oh yes! An African swallow maybe ... but not a European swallow. that's my point. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.062 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.062 Problem: Crash when 'verbose' is > 3 and using ":shell". (Yegappan Lakshmanan) Solution: Avoid giving a NULL pointer to printf(). Also output a newline and switch the cursor on. Files: src/misc2.c *** ../vim60.61/src/misc2.c Thu Nov 1 12:22:41 2001 --- src/misc2.c Thu Nov 1 20:22:01 2001 *************** *** 2509,2515 **** int retval; if (p_verbose > 3) ! smsg((char_u *)_("Calling shell to execute: \"%s\""), cmd); if (*p_sh == NUL) { --- 2509,2520 ---- int retval; if (p_verbose > 3) ! { ! smsg((char_u *)_("Calling shell to execute: \"%s\""), ! cmd == NULL ? p_sh : cmd); ! out_char('\n'); ! cursor_on(); ! } if (*p_sh == NUL) { *** ../vim60.61/src/version.c Thu Nov 1 15:22:32 2001 --- src/version.c Thu Nov 1 20:24:23 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 62, /**/ -- ARTHUR: I've said I'm sorry about the old woman, but from the behind you looked ... DENNIS: What I object to is that you automatically treat me like an inferior... ARTHUR: Well ... I AM king. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.063 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.063 Problem: When 'cpoptions' includes "$", using "cw" to type a ')' on top of the "$" doesn't update syntax highlighting after it. Solution: Stop displaying the "$" when typing a ')' in its position. Files: src/search.c *** ../vim60.62/src/search.c Wed Oct 31 20:17:35 2001 --- src/search.c Thu Nov 1 21:20:39 2001 *************** *** 1987,1994 **** mpos = *lpos; /* save the pos, update_screen() may change it */ save_cursor = curwin->w_cursor; save_so = p_so; ! ++curwin->w_virtcol; /* for when 'cpo' contains '$': do ! redraw the ')' */ update_screen(VALID); /* show the new char first */ #ifdef CURSOR_SHAPE --- 1987,1997 ---- mpos = *lpos; /* save the pos, update_screen() may change it */ save_cursor = curwin->w_cursor; save_so = p_so; ! /* Handle "$" in 'cpo': If the ')' is typed on top of the "$", ! * stop displaying the "$". */ ! if (dollar_vcol > 0 && dollar_vcol == curwin->w_virtcol) ! dollar_vcol = 0; ! ++curwin->w_virtcol; /* do display ')' just before "$" */ update_screen(VALID); /* show the new char first */ #ifdef CURSOR_SHAPE *** ../vim60.62/src/version.c Thu Nov 1 21:25:14 2001 --- src/version.c Thu Nov 1 21:23:28 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 63, /**/ -- OLD WOMAN: King of the WHO? ARTHUR: The Britons. OLD WOMAN: Who are the Britons? "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.064 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.064 (extra) Problem: The NSIS install script doesn't work with newer versions of NSIS. The diff feature doesn't work when there isn't a good diff.exe on the system. Solution: Replace the GetParentDir instruction by a user function. Fix a few cosmetic problems. Use defined constants for the version number, so that it's defined in one place only. Only accept the install directory when it ends in "vim". (Eduardo Fernandez) Add a diff.exe and use it from the default _vimrc. Files: nsis/gvim.nsi, nsis/README.txt, src/dosinst.c *** ../vim60.63/nsis/gvim.nsi Tue Sep 25 21:40:44 2001 --- nsis/gvim.nsi Thu Nov 1 22:20:59 2001 *************** *** 1,5 **** # NSIS file to create a self-installing exe for Vim. ! # Last modification: 2001 Jul 21 # WARNING: if you make changes to this script, look out for $0 to be valid, # because this line is very dangerous: RMDir /r $0 --- 1,6 ---- # NSIS file to create a self-installing exe for Vim. ! # It needs NSIS version 1.59 or later. ! # Last modification: 2001 Oct 31 # WARNING: if you make changes to this script, look out for $0 to be valid, # because this line is very dangerous: RMDir /r $0 *************** *** 11,25 **** # comment the next line if you do not want to add Native Language Support !define HAVE_NLS ! Name "Vim 6.0" ! OutFile gVim60.exe CRCCheck on ! ComponentText "This will install Vim 6.0 on your computer." ! DirText "Choose a directory to install Vim (should end in 'vim')" SetDatablockOptimize on Icon icons\vim_16c.ico ! UninstallText "This will uninstall Vim 6.0 from your system." ! UninstallExeName vim60\uninstall-gui.exe UninstallIcon icons\vim_uninst_16c.ico BGGradient 004000 008200 ffffff LicenseText "You should read the following before installing:" --- 12,29 ---- # comment the next line if you do not want to add Native Language Support !define HAVE_NLS ! !define VER_MINOR 0 ! !define VER_MAJOR 6 ! ! Name "Vim ${VER_MAJOR}.${VER_MINOR}" ! OutFile gvim${VER_MAJOR}${VER_MINOR}.exe CRCCheck on ! ComponentText "This will install Vim ${VER_MAJOR}.${VER_MINOR} on your computer." ! DirText "Choose a directory to install Vim (must end in 'vim')" SetDatablockOptimize on Icon icons\vim_16c.ico ! UninstallText "This will uninstall Vim ${VER_MAJOR}.${VER_MINOR} from your system." ! UninstallExeName vim${VER_MAJOR}${VER_MINOR}\uninstall-gui.exe UninstallIcon icons\vim_uninst_16c.ico BGGradient 004000 008200 ffffff LicenseText "You should read the following before installing:" *************** *** 28,33 **** --- 32,39 ---- !ifdef HAVE_UPX !packhdr temp.dat "upx --best --compress-icons=1 temp.dat" !endif + # This add '\vim' to the user choice automagically. + InstallDir "C:\vim" # Types of installs we can perform: InstType Typical *************** *** 41,47 **** Function .onInit MessageBox MB_YESNO|MB_ICONQUESTION \ ! "This will install Vim 6.0 on your computer.$\n Continue?" IDYES NoAbort Abort ; causes installer to quit. NoAbort: --- 47,54 ---- Function .onInit MessageBox MB_YESNO|MB_ICONQUESTION \ ! "This will install Vim ${VER_MAJOR}.${VER_MINOR} on your computer.$\n Continue?" \ ! IDYES NoAbort Abort ; causes installer to quit. NoAbort: *************** *** 77,83 **** # $1 - holds the parameters to be passed to install.exe. Starts with OLE # registration (since a non-OLE gvim will not complain, and we want to # always register an OLE gvim). ! StrCpy $0 "$INSTDIR\vim60" StrCpy $1 "-register-OLE" FunctionEnd --- 84,90 ---- # $1 - holds the parameters to be passed to install.exe. Starts with OLE # registration (since a non-OLE gvim will not complain, and we want to # always register an OLE gvim). ! StrCpy $0 "$INSTDIR\vim${VER_MAJOR}${VER_MINOR}" StrCpy $1 "-register-OLE" FunctionEnd *************** *** 88,98 **** NoCancelAbort: FunctionEnd ! # Only enable the "Next" button if the install directory is OK. Function .onVerifyInstDir ! StrCmp $INSTDIR $PROGRAMFILES PathBad 0 ! StrCmp $INSTDIR $WINDIR PathBad PathGood ! PathBad: Abort PathGood: --- 95,104 ---- NoCancelAbort: FunctionEnd ! # Only enable the "Install" button if the install directory ends in "vim". Function .onVerifyInstDir ! StrCpy $0 $INSTDIR 3 -3 ! StrCmp $0 "vim" PathGood Abort PathGood: *************** *** 111,117 **** FunctionEnd Function un.onUnInstSuccess ! MessageBox MB_OK|MB_ICONINFORMATION "Vim 6.0 has been (partly) removed from your system" FunctionEnd ########################################################## --- 117,142 ---- FunctionEnd Function un.onUnInstSuccess ! MessageBox MB_OK|MB_ICONINFORMATION \ ! "Vim ${VER_MAJOR}.${VER_MINOR} has been (partly) removed from your system" ! FunctionEnd ! ! Function un.GetParent ! Exch $0 ; old $0 is on top of stack ! Push $1 ! Push $2 ! StrCpy $1 -1 ! loop: ! StrCpy $2 $0 1 $1 ! StrCmp $2 "" exit ! StrCmp $2 "\" exit ! IntOp $1 $1 - 1 ! Goto loop ! exit: ! StrCpy $0 $0 $1 ! Pop $2 ! Pop $1 ! Exch $0 ; put $0 on top of stack, restore $0 to original value FunctionEnd ########################################################## *************** *** 119,125 **** SectionIn 1,2,3 # we need also this here if the user changes the instdir ! StrCpy $0 "$INSTDIR\vim60" SetOutPath $0 File ..\src\gvim.exe --- 144,150 ---- SectionIn 1,2,3 # we need also this here if the user changes the instdir ! StrCpy $0 "$INSTDIR\vim${VER_MAJOR}${VER_MINOR}" SetOutPath $0 File ..\src\gvim.exe *************** *** 127,132 **** --- 152,158 ---- File ..\src\uninstal.exe File ..\src\vimrun.exe File ..\src\xxd\xxd.exe + File ..\..\diff.exe File ..\vimtutor.bat File ..\README.txt File ..\uninstal.txt *************** *** 295,313 **** IfErrors ErrorMess NoErrorMess ErrorMess: MessageBox MB_OK|MB_ICONEXCLAMATION \ ! "Some files in $0 have not been deleted! You must do it manually." NoErrorMess: NoRemoveExes: ! GetParentDir $0 $INSTDIR # if a plugin dir was created at installation ask the user to remove it ! IfFileExists $0\vimfiles 0 NoRemove MessageBox MB_YESNO|MB_ICONQUESTION \ ! "Remove all files in your $0\vimfiles directory? \ $\nIf you have created something there that you want to keep, click No" IDNO Fin ! RMDir /r $0\vimfiles NoRemove: # ask the user if the Vim root dir must be removed --- 321,351 ---- IfErrors ErrorMess NoErrorMess ErrorMess: MessageBox MB_OK|MB_ICONEXCLAMATION \ ! "Some files in $0 have not been deleted!$\nYou must do it manually." NoErrorMess: NoRemoveExes: ! # get the parent dir of the installation ! Push $INSTDIR ! Call un.GetParent ! Pop $0 ! ! StrCpy $1 $0 # if a plugin dir was created at installation ask the user to remove it ! # first look in the root of the installation then in HOME ! IfFileExists $1\vimfiles AskRemove 0 ! ReadEnvStr $1 "HOME" ! StrCmp $1 "" NoRemove 0 ! ! IfFileExists $1\vimfiles 0 NoRemove ! ! AskRemove: MessageBox MB_YESNO|MB_ICONQUESTION \ ! "Remove all files in your $1\vimfiles directory? \ $\nIf you have created something there that you want to keep, click No" IDNO Fin ! RMDir /r $1\vimfiles NoRemove: # ask the user if the Vim root dir must be removed *** ../vim60.63/nsis/README.txt Sat Sep 15 23:34:07 2001 --- nsis/README.txt Thu Nov 1 22:23:45 2001 *************** *** 26,32 **** 5. Go to the OleVim directory and build OpenWithVim.exe and SendToVim.exe (or get them from a binary archive). ! 6. Do "make uganda.nsis.txt" in runtime/doc. This requires sed, you may have to do this on Unix. Make sure the file is in DOS file format! Install NSIS if you didn't do that already. --- 26,37 ---- 5. Go to the OleVim directory and build OpenWithVim.exe and SendToVim.exe (or get them from a binary archive). ! 6. Get a "diff.exe" program and put it in the "../.." directory (above the ! "vim60" directory, it's the same for all Vim versions). ! You can find one in previous Vim versions or in this archive: ! http://www.mossbayeng.com/~ron/vim/diffutils.tar.gz ! ! 7. Do "make uganda.nsis.txt" in runtime/doc. This requires sed, you may have to do this on Unix. Make sure the file is in DOS file format! Install NSIS if you didn't do that already. *** ../vim60.63/src/dosinst.c Mon Aug 27 17:16:45 2001 --- src/dosinst.c Thu Nov 1 22:41:43 2001 *************** *** 1047,1053 **** static void install_vimrc(int idx) { ! FILE *fd; char *fname; /* If an old vimrc file exists, overwrite it. --- 1047,1053 ---- static void install_vimrc(int idx) { ! FILE *fd, *tfd; char *fname; /* If an old vimrc file exists, overwrite it. *************** *** 1092,1097 **** --- 1092,1111 ---- case mouse_mswin: fprintf(fd, "behave mswin\n"); break; + } + if ((tfd = fopen("diff.exe", "r")) != NULL) + { + /* Use the diff.exe that comes with the self-extracting gvim.exe. */ + fclose(tfd); + fprintf(fd, "\n"); + fprintf(fd, "set diffexpr=MyDiff()\n"); + fprintf(fd, "function MyDiff()\n"); + fprintf(fd, " let opt = ''\n"); + fprintf(fd, " if &diffopt =~ 'icase' | let opt = opt . '-i ' | endif\n"); + fprintf(fd, " if &diffopt =~ 'iwhite' | let opt = opt . '-b ' | endif\n"); + fprintf(fd, " silent execute '!%s\\diff -a ' . opt . v:fname_in . ' ' . v:fname_new . ' > ' . v:fname_out\n", installdir); + fprintf(fd, "endfunction\n"); + fprintf(fd, "\n"); } fclose(fd); printf("%s has been written\n", fname); *** ../vim60.63/src/version.c Thu Nov 1 21:26:45 2001 --- src/version.c Thu Nov 1 22:47:02 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 64, /**/ -- OLD WOMAN: Well, how did you become king, then? ARTHUR: The Lady of the Lake, her arm clad in the purest shimmering samite, held Excalibur aloft from the bosom of the water to signify by Divine Providence ... that I, Arthur, was to carry Excalibur ... That is why I am your king! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.065 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.065 Problem: When using ":normal" in 'indentexpr' it may use redo characters before its argument. (Neil Bird) Solution: Save and restore the stuff buffer in ex_normal(). Files: src/ex_docmd.c, src/getchar.c, src/globals.h, src/structs.h *** ../vim60.64/src/ex_docmd.c Tue Oct 30 21:18:36 2001 --- src/ex_docmd.c Fri Nov 2 16:14:07 2001 *************** *** 6805,6810 **** --- 6805,6811 ---- typebuf_T saved_typebuf; int save_insertmode = p_im; int save_finish_op = finish_op; + struct buffheader save_stuffbuff; #ifdef FEAT_MBYTE char_u *arg = NULL; int l; *************** *** 6894,6899 **** --- 6895,6904 ---- saved_typebuf = typebuf; if (alloc_typebuf() == OK) { + /* Also save the stuff buffer and make it empty. */ + save_stuffbuff = stuffbuff; + stuffbuff.bh_first.b_next = NULL; + /* * Repeat the :normal command for each line in the range. When no * range given, execute it just once, without positioning the cursor *************** *** 6927,6932 **** --- 6932,6939 ---- } } while (eap->addr_count > 0 && eap->line1 <= eap->line2 && !got_int); + + stuffbuff = save_stuffbuff; } /* Might not return to the main loop when in an event handler. */ *** ../vim60.64/src/getchar.c Sun Oct 28 21:23:45 2001 --- src/getchar.c Fri Nov 2 16:23:29 2001 *************** *** 38,66 **** * Un-escaping is done by vgetc(). */ - /* - * structure used to store one block of the stuff/redo/recording buffers - */ - struct buffblock - { - struct buffblock *b_next; /* pointer to next buffblock */ - char_u b_str[1]; /* contents (actually longer) */ - }; - #define MINIMAL_SIZE 20 /* minimal size for b_str */ - /* - * header used for the stuff buffer and the redo buffer - */ - struct buffheader - { - struct buffblock bh_first; /* first (dummy) block of list */ - struct buffblock *bh_curr; /* buffblock for appending */ - int bh_index; /* index for reading */ - int bh_space; /* space in bh_curr for appending */ - }; - - static struct buffheader stuffbuff = {{NULL, {NUL}}, NULL, 0, 0}; static struct buffheader redobuff = {{NULL, {NUL}}, NULL, 0, 0}; static struct buffheader old_redobuff = {{NULL, {NUL}}, NULL, 0, 0}; #if defined(FEAT_AUTOCMD) || defined(FEAT_EVAL) || defined(PROTO) --- 38,45 ---- *** ../vim60.64/src/globals.h Sun Oct 28 21:23:45 2001 --- src/globals.h Fri Nov 2 16:07:27 2001 *************** *** 693,702 **** EXTERN int readonlymode INIT(= FALSE); /* Set to TRUE for "view" */ EXTERN int recoverymode INIT(= FALSE); /* Set to TRUE for "-r" option */ EXTERN typebuf_T typebuf /* typeahead buffer */ ! # ifdef DO_INIT = {NULL, NULL} ! # endif ; #ifdef FEAT_EX_EXTRA EXTERN int ex_normal_busy INIT(= 0); /* recursivenes of ex_normal() */ --- 693,707 ---- EXTERN int readonlymode INIT(= FALSE); /* Set to TRUE for "view" */ EXTERN int recoverymode INIT(= FALSE); /* Set to TRUE for "-r" option */ + EXTERN struct buffheader stuffbuff /* stuff buffer */ + #ifdef DO_INIT + = {{NULL, {NUL}}, NULL, 0, 0} + #endif + ; EXTERN typebuf_T typebuf /* typeahead buffer */ ! #ifdef DO_INIT = {NULL, NULL} ! #endif ; #ifdef FEAT_EX_EXTRA EXTERN int ex_normal_busy INIT(= 0); /* recursivenes of ex_normal() */ *** ../vim60.64/src/structs.h Wed Oct 31 11:17:27 2001 --- src/structs.h Fri Nov 2 16:23:11 2001 *************** *** 338,343 **** --- 338,363 ---- }; /* + * structure used to store one block of the stuff/redo/recording buffers + */ + struct buffblock + { + struct buffblock *b_next; /* pointer to next buffblock */ + char_u b_str[1]; /* contents (actually longer) */ + }; + + /* + * header used for the stuff buffer and the redo buffer + */ + struct buffheader + { + struct buffblock bh_first; /* first (dummy) block of list */ + struct buffblock *bh_curr; /* buffblock for appending */ + int bh_index; /* index for reading */ + int bh_space; /* space in bh_curr for appending */ + }; + + /* * used for completion on the command line */ typedef struct expand *** ../vim60.64/src/version.c Fri Nov 2 16:20:26 2001 --- src/version.c Fri Nov 2 16:19:23 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 65, /**/ -- FIRST VILLAGER: We have found a witch. May we burn her? "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.066 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.066 Problem: Sometimes undo for one command is split into two undo actions. (Halim Salman) Solution: Don't set the undo-synced flag when reusing a line that was already saved for undo. Files: src/undo.c *** ../vim60.65/src/undo.c Sun Oct 28 21:15:32 2001 --- src/undo.c Sat Nov 3 13:37:08 2001 *************** *** 279,285 **** --- 279,288 ---- * entry now. Following deleted/inserted lines go to the * re-used entry. */ if (i > 0) + { u_getbot(); + curbuf->b_u_synced = FALSE; + } /* The line count might change afterwards. */ if (newbot != 0) *** ../vim60.65/src/version.c Fri Nov 2 16:29:44 2001 --- src/version.c Sat Nov 3 13:40:49 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 66, /**/ -- The acknowledged parents of reengineering are Michael Hammer and James Champy. When I say they're the "parents" I don't mean they had sex - and I apologize for making you think about it. I mean they wrote the best-selling business book _Reengineering the Corporation_, which was published in 1993. Businesses flocked to reengineering like frat boys to a drunken cheerleader. (This analogy wasn't necessary, but I'm trying to get my mind off that Hammer and Champy thing.) (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.067 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.067 Problem: if_xcmdsrv.c doesn't compile on systems where fd_set isn't defined in the usual header file (e.g., AIX). (Mark Waggoner) Solution: Include sys/select.h in if_xcmdsrv.c for systems that have it. Files: src/if_xcmdsrv.c *** ../vim60.66/src/if_xcmdsrv.c Mon Sep 24 12:02:29 2001 --- src/if_xcmdsrv.c Sat Nov 3 13:56:56 2001 *************** *** 21,26 **** --- 21,31 ---- # include # endif + # if defined(HAVE_SYS_SELECT_H) && \ + (!defined(HAVE_SYS_TIME_H) || defined(SYS_SELECT_WITH_SYS_TIME)) + # include + # endif + /* * This file provides procedures that implement the command server functionality * of Vim when in contact with an X11 server. *** ../vim60.66/src/version.c Sat Nov 3 14:01:26 2001 --- src/version.c Sat Nov 3 14:01:06 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 67, /**/ -- An easy way to determine if you have enough teamwork to be doomed is simply to measure how long it takes from the time you decide to go to lunch together until the time you actually eat. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.068 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.068 Problem: When formatting a Visually selected area with "gq" and the number of lines increases the last line may not be redrawn correctly. (Yegappan Lakshmanan) Solution: Correct the area to be redrawn for inserted/deleted lines. Files: src/ops.c *** ../vim60.67/src/ops.c Wed Oct 31 20:51:33 2001 --- src/ops.c Sat Nov 3 21:25:47 2001 *************** *** 4034,4043 **** if (oap->end_adjusted && curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count) ++curwin->w_cursor.lnum; beginline(BL_WHITE | BL_FIX); ! msgmore(curbuf->b_ml.ml_line_count - old_line_count); /* put '] mark on the end of the formatted area */ curbuf->b_op_end = curwin->w_cursor; } /* --- 4035,4065 ---- if (oap->end_adjusted && curwin->w_cursor.lnum < curbuf->b_ml.ml_line_count) ++curwin->w_cursor.lnum; beginline(BL_WHITE | BL_FIX); ! old_line_count = curbuf->b_ml.ml_line_count - old_line_count; ! msgmore(old_line_count); /* put '] mark on the end of the formatted area */ curbuf->b_op_end = curwin->w_cursor; + + #ifdef FEAT_VISUAL + if (oap->is_VIsual) + { + win_T *wp; + + FOR_ALL_WINDOWS(wp) + { + if (wp->w_old_cursor_lnum != 0) + { + /* When lines have been inserted or deleted, adjust the end of + * the Visual area to be redrawn. */ + if (wp->w_old_cursor_lnum > wp->w_old_visual_lnum) + wp->w_old_cursor_lnum += old_line_count; + else + wp->w_old_visual_lnum += old_line_count; + } + } + } + #endif } /* *** ../vim60.67/src/version.c Sat Nov 3 14:16:30 2001 --- src/version.c Sat Nov 3 21:28:49 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 68, /**/ -- At some point in the project somebody will start whining about the need to determine the project "requirements". This involves interviewing people who don't know what they want but, curiously, know exactly when they need it. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.069 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.069 Problem: Using "K" on a word that includes a "!" causes a "No previous command" error, because the "!" is expanded. (Craig Jeffries) Solution: Put a backslash before the "!". Files: src/normal.c *** ../vim60.68/src/normal.c Thu Nov 1 14:51:27 2001 --- src/normal.c Sun Nov 4 13:07:22 2001 *************** *** 4669,4675 **** if (cmdchar == '*' || cmdchar == '#') aux_ptr = (char_u *)(p_magic ? "/?.*~[^$\\" : "/?^$\\"); else if (cmdchar == 'K' && *p_kp != NUL) ! aux_ptr = escape_chars; else /* Don't escape spaces and Tabs in a tag with a backslash */ aux_ptr = (char_u *)"\\|\""; --- 4669,4675 ---- if (cmdchar == '*' || cmdchar == '#') aux_ptr = (char_u *)(p_magic ? "/?.*~[^$\\" : "/?^$\\"); else if (cmdchar == 'K' && *p_kp != NUL) ! aux_ptr = (char_u *)" \t\\\"|!"; else /* Don't escape spaces and Tabs in a tag with a backslash */ aux_ptr = (char_u *)"\\|\""; *** ../vim60.68/src/version.c Sun Nov 4 13:15:58 2001 --- src/version.c Sun Nov 4 13:13:41 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 69, /**/ -- The budget process was invented by an alien race of sadistic beings who resemble large cats. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.070 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.070 Problem: Win32: The error message for a failed dynamic linking of a Perl, Ruby, Tcl and Python library is unclear about what went wrong. Solution: Give the name of the library or function that could not be loaded. Also for the iconv and gettext libraries when 'verbose' is set. Files: src/eval.c, src/if_perl.xs, src/if_python.c, src/if_ruby.c, src/if_tcl.c, src/mbyte.c, src/os_win32.c, src/proto/if_perl.pro, src/proto/if_python.pro, src/proto/if_ruby.pro, src/proto/if_tcl.pro, src/proto/mbyte.pro *** ../vim60.69/src/eval.c Mon Oct 29 15:15:20 2001 --- src/eval.c Sun Nov 4 13:57:39 2001 *************** *** 4337,4359 **** n = (starting != 0); #ifdef DYNAMIC_TCL else if (STRICMP(name, "tcl") == 0) ! n = tcl_enabled() ? TRUE : FALSE; #endif #if defined(USE_ICONV) && defined(DYNAMIC_ICONV) else if (STRICMP(name, "iconv") == 0) ! n = iconv_enabled(); #endif #ifdef DYNAMIC_RUBY else if (STRICMP(name, "ruby") == 0) ! n = ruby_enabled() ? TRUE : FALSE; #endif #ifdef DYNAMIC_PYTHON else if (STRICMP(name, "python") == 0) ! n = python_enabled() ? TRUE : FALSE; #endif #ifdef DYNAMIC_PERL else if (STRICMP(name, "perl") == 0) ! n = perl_enabled() ? TRUE : FALSE; #endif #ifdef FEAT_GUI else if (STRICMP(name, "gui_running") == 0) --- 4337,4359 ---- n = (starting != 0); #ifdef DYNAMIC_TCL else if (STRICMP(name, "tcl") == 0) ! n = tcl_enabled(FALSE); #endif #if defined(USE_ICONV) && defined(DYNAMIC_ICONV) else if (STRICMP(name, "iconv") == 0) ! n = iconv_enabled(FALSE); #endif #ifdef DYNAMIC_RUBY else if (STRICMP(name, "ruby") == 0) ! n = ruby_enabled(FALSE); #endif #ifdef DYNAMIC_PYTHON else if (STRICMP(name, "python") == 0) ! n = python_enabled(FALSE); #endif #ifdef DYNAMIC_PERL else if (STRICMP(name, "perl") == 0) ! n = perl_enabled(FALSE); #endif #ifdef FEAT_GUI else if (STRICMP(name, "gui_running") == 0) *** ../vim60.69/src/if_perl.xs Sun Jul 29 14:47:04 2001 --- src/if_perl.xs Sun Nov 4 13:40:40 2001 *************** *** 307,323 **** * 3. Repeat 2, until get all functions will be used. * * Parameter 'libname' provides name of DLL. ! * Succeeded in load, return 1. Failed, return zero. */ static int ! perl_runtime_link_init(char *libname) { int i; ! if (hPerlLib) ! return 1; if (!(hPerlLib = LoadLibraryEx(libname, NULL, 0))) ! return 0; for (i = 0; perl_funcname_table[i].ptr; ++i) { if (!(*perl_funcname_table[i].ptr = GetProcAddress(hPerlLib, --- 307,327 ---- * 3. Repeat 2, until get all functions will be used. * * Parameter 'libname' provides name of DLL. ! * Return OK or FAIL. */ static int ! perl_runtime_link_init(char *libname, int verbose) { int i; ! if (hPerlLib != NULL) ! return OK; if (!(hPerlLib = LoadLibraryEx(libname, NULL, 0))) ! { ! if (verbose) ! EMSG2(_("E370: Could not load library %s"), libname); ! return FAIL; ! } for (i = 0; perl_funcname_table[i].ptr; ++i) { if (!(*perl_funcname_table[i].ptr = GetProcAddress(hPerlLib, *************** *** 325,344 **** { FreeLibrary(hPerlLib); hPerlLib = NULL; ! return 0; } } ! return 1; } /* ! * If runtime-link-perl(DLL) was loaded successfully, return 1. ! * There were no DLL loaded, return 0. */ int ! perl_enabled() { ! return perl_runtime_link_init(DYNAMIC_PERL_DLL); } #endif /* DYNAMIC_PERL */ --- 329,352 ---- { FreeLibrary(hPerlLib); hPerlLib = NULL; ! if (verbose) ! EMSG2(_("E448: Could not load library function %s"), ! perl_funcname_table[i].name); ! return FAIL; } } ! return OK; } /* ! * If runtime-link-perl(DLL) was loaded successfully, return TRUE. ! * There were no DLL loaded, return FALSE. */ int ! perl_enabled(verbose) ! int verbose; { ! return perl_runtime_link_init(DYNAMIC_PERL_DLL, verbose) == OK; } #endif /* DYNAMIC_PERL */ *************** *** 548,557 **** SV *sv; SV *safe; ! if (!perl_interp) { #ifdef DYNAMIC_PERL ! if (!perl_enabled()) { EMSG(_(e_noperl)); return; --- 556,565 ---- SV *sv; SV *safe; ! if (perl_interp == NULL) { #ifdef DYNAMIC_PERL ! if (!perl_enabled(TRUE)) { EMSG(_(e_noperl)); return; *************** *** 644,653 **** if (bufempty()) return; ! if (!perl_interp) { #ifdef DYNAMIC_PERL ! if (!perl_enabled()) { EMSG(_(e_noperl)); return; --- 652,661 ---- if (bufempty()) return; ! if (perl_interp == NULL) { #ifdef DYNAMIC_PERL ! if (!perl_enabled(TRUE)) { EMSG(_(e_noperl)); return; *** ../vim60.69/src/if_python.c Thu Oct 18 13:28:47 2001 --- src/if_python.c Sun Nov 4 13:41:47 2001 *************** *** 228,248 **** } /* ! * Load library and get all pointers. If failed, function returns 0. ! * Succeeded 1. ! * * Parameter 'libname' provides name of DLL. */ static int ! python_runtime_link_init(char* libname) { int i; if (hinstPython) ! return 1; hinstPython = LoadLibrary(libname); if (!hinstPython) ! return 0; for (i = 0; python_funcname_table[i].ptr; ++i) { --- 228,251 ---- } /* ! * Load library and get all pointers. * Parameter 'libname' provides name of DLL. + * Return OK or FAIL. */ static int ! python_runtime_link_init(char *libname, int verbose) { int i; if (hinstPython) ! return OK; hinstPython = LoadLibrary(libname); if (!hinstPython) ! { ! if (verbose) ! EMSG2(_("E370: Could not load library %s"), libname); ! return FAIL; ! } for (i = 0; python_funcname_table[i].ptr; ++i) { *************** *** 251,270 **** { FreeLibrary(hinstPython); hinstPython = 0; ! return 0; } } ! return 1; } /* * If python is enabled (there is installed python on Windows system) return ! * 1, else 0. */ int ! python_enabled() { ! return python_runtime_link_init(DYNAMIC_PYTHON_DLL); } /* Load the standard Python exceptions - don't import the symbols from the --- 254,277 ---- { FreeLibrary(hinstPython); hinstPython = 0; ! if (verbose) ! EMSG2(_("E448: Could not load library function %s"), ! python_funcname_table[i].name); ! return FAIL; } } ! return OK; } /* * If python is enabled (there is installed python on Windows system) return ! * TRUE, else FALSE. */ int ! python_enabled(verbose) ! int verbose; { ! return python_runtime_link_init(DYNAMIC_PYTHON_DLL, verbose) == OK; } /* Load the standard Python exceptions - don't import the symbols from the *************** *** 371,377 **** if (!initialised) { #ifdef DYNAMIC_PYTHON ! if (!python_enabled()) { EMSG(_("E263: Sorry, this command is disabled, the Python library could not be loaded.")); goto fail; --- 378,384 ---- if (!initialised) { #ifdef DYNAMIC_PYTHON ! if (!python_enabled(TRUE)) { EMSG(_("E263: Sorry, this command is disabled, the Python library could not be loaded.")); goto fail; *** ../vim60.69/src/if_ruby.c Thu Aug 16 18:45:32 2001 --- src/if_ruby.c Sun Nov 4 13:44:01 2001 *************** *** 242,262 **** } /* ! * Load library and get all pointers. If failed, function returns 0. ! * Succeeded 1. ! * * Parameter 'libname' provides name of DLL. */ static int ! ruby_runtime_link_init(char* libname) { int i; if (hinstRuby) ! return 1; hinstRuby = LoadLibrary(libname); if (!hinstRuby) ! return 0; for (i = 0; ruby_funcname_table[i].ptr; ++i) { --- 242,265 ---- } /* ! * Load library and get all pointers. * Parameter 'libname' provides name of DLL. + * Return OK or FAIL. */ static int ! ruby_runtime_link_init(char *libname, int verbose) { int i; if (hinstRuby) ! return OK; hinstRuby = LoadLibrary(libname); if (!hinstRuby) ! { ! if (verbose) ! EMSG2(_("E370: Could not load library %s"), libname); ! return FAIL; ! } for (i = 0; ruby_funcname_table[i].ptr; ++i) { *************** *** 265,284 **** { FreeLibrary(hinstRuby); hinstRuby = 0; ! return 0; } } ! return 1; } /* ! * If ruby is enabled (there is installed ruby on Windows system) return 1, ! * else 0. */ int ! ruby_enabled() { ! return ruby_runtime_link_init(DYNAMIC_RUBY_DLL); } #endif /* defined(DYNAMIC_RUBY) || defined(PROTO) */ --- 268,291 ---- { FreeLibrary(hinstRuby); hinstRuby = 0; ! if (verbose) ! EMSG2(_("E448: Could not load library function %s"), ! ruby_funcname_table[i].name); ! return FAIL; } } ! return OK; } /* ! * If ruby is enabled (there is installed ruby on Windows system) return TRUE, ! * else FALSE. */ int ! ruby_enabled(verbose) ! int verbose; { ! return ruby_runtime_link_init(DYNAMIC_RUBY_DLL, verbose) == OK; } #endif /* defined(DYNAMIC_RUBY) || defined(PROTO) */ *************** *** 379,385 **** if (!ruby_initialized) { #ifdef DYNAMIC_RUBY ! if (ruby_enabled()) { #endif ruby_init(); --- 386,392 ---- if (!ruby_initialized) { #ifdef DYNAMIC_RUBY ! if (ruby_enabled(TRUE)) { #endif ruby_init(); *** ../vim60.69/src/if_tcl.c Thu Aug 16 18:46:10 2001 --- src/if_tcl.c Sun Nov 4 13:55:02 2001 *************** *** 180,196 **** * 3. Repeat 2, until get all functions will be used. * * Parameter 'libname' provides name of DLL. ! * Succeeded in load, return 1. Failed, return zero. */ static int ! tcl_runtime_link_init(char *libname) { int i; if (hTclLib) ! return 1; if (!(hTclLib = LoadLibraryEx(libname, NULL, 0))) ! return 0; for (i = 0; tcl_funcname_table[i].ptr; ++i) { if (!(*tcl_funcname_table[i].ptr = GetProcAddress(hTclLib, --- 180,200 ---- * 3. Repeat 2, until get all functions will be used. * * Parameter 'libname' provides name of DLL. ! * Return OK or FAIL. */ static int ! tcl_runtime_link_init(char *libname, int verbose) { int i; if (hTclLib) ! return OK; if (!(hTclLib = LoadLibraryEx(libname, NULL, 0))) ! { ! if (verbose) ! EMSG2(_("E370: Could not load library %s"), libname); ! return FAIL; ! } for (i = 0; tcl_funcname_table[i].ptr; ++i) { if (!(*tcl_funcname_table[i].ptr = GetProcAddress(hTclLib, *************** *** 198,207 **** { FreeLibrary(hTclLib); hTclLib = NULL; ! return 0; } } ! return 1; } #endif /* defined(DYNAMIC_TCL) || defined(PROTO) */ --- 202,214 ---- { FreeLibrary(hTclLib); hTclLib = NULL; ! if (verbose) ! EMSG2(_("E448: Could not load library function %s"), ! tcl_funcname_table[i].name); ! return FAIL; } } ! return OK; } #endif /* defined(DYNAMIC_TCL) || defined(PROTO) */ *************** *** 221,233 **** } #if defined(DYNAMIC_TCL) || defined(PROTO) int ! tcl_enabled() { ! static int stubs_initialized = 0; ! if (!stubs_initialized && find_executable_arg ! && tcl_runtime_link_init(DYNAMIC_TCL_DLL)) { Tcl_Interp *interp; --- 228,244 ---- } #if defined(DYNAMIC_TCL) || defined(PROTO) + /* + * Return TRUE if the TCL interface can be used. + */ int ! tcl_enabled(verbose) ! int verbose; { ! static int stubs_initialized = FALSE; ! if (!stubs_initialized && find_executable_arg != NULL ! && tcl_runtime_link_init(DYNAMIC_TCL_DLL, verbose) == OK) { Tcl_Interp *interp; *************** *** 237,243 **** { Tcl_FindExecutable(find_executable_arg); Tcl_DeleteInterp(interp); ! stubs_initialized = 1; } /* FIXME: When Tcl_InitStubs() was failed, how delete interp? */ } --- 248,254 ---- { Tcl_FindExecutable(find_executable_arg); Tcl_DeleteInterp(interp); ! stubs_initialized = TRUE; } /* FIXME: When Tcl_InitStubs() was failed, how delete interp? */ } *************** *** 1708,1714 **** char *name; #ifdef DYNAMIC_TCL ! if (!tcl_enabled()) { EMSG(_("Sorry, this command is disabled: the Tcl library could not be loaded.")); return FAIL; --- 1719,1725 ---- char *name; #ifdef DYNAMIC_TCL ! if (!tcl_enabled(TRUE)) { EMSG(_("Sorry, this command is disabled: the Tcl library could not be loaded.")); return FAIL; *************** *** 2068,2074 **** struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled()) return; #endif --- 2079,2085 ---- struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled(TRUE)) return; #endif *************** *** 2089,2095 **** struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled()) return; #endif --- 2100,2106 ---- struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled(TRUE)) return; #endif *** ../vim60.69/src/mbyte.c Mon Oct 22 12:47:09 2001 --- src/mbyte.c Sun Nov 4 14:07:01 2001 *************** *** 2429,2435 **** #ifdef DYNAMIC_ICONV /* Check if the iconv.dll can be found. */ ! if (!iconv_enabled()) return (void *)-1; #endif --- 2429,2435 ---- #ifdef DYNAMIC_ICONV /* Check if the iconv.dll can be found. */ ! if (!iconv_enabled(TRUE)) return (void *)-1; #endif *************** *** 2553,2559 **** * Try opening the iconv.dll and return TRUE if iconv() can be used. */ int ! iconv_enabled() { if (hIconvDLL != 0 && hMsvcrtDLL != 0) return TRUE; --- 2553,2560 ---- * Try opening the iconv.dll and return TRUE if iconv() can be used. */ int ! iconv_enabled(verbose) ! int verbose; { if (hIconvDLL != 0 && hMsvcrtDLL != 0) return TRUE; *************** *** 2561,2566 **** --- 2562,2572 ---- hMsvcrtDLL = LoadLibrary(DYNAMIC_MSVCRT_DLL); if (hIconvDLL == 0 || hMsvcrtDLL == 0) { + /* Only give the message when 'verbose' is set, otherwise it might be + * done whenever a conversion is attempted. */ + if (verbose && p_verbose > 0) + EMSG2(_("E370: Could not load library %s"), + hIconvDLL == 0 ? DYNAMIC_ICONV_DLL : DYNAMIC_MSVCRT_DLL); iconv_end(); return FALSE; } *************** *** 2574,2579 **** --- 2580,2588 ---- || iconvctl == NULL || iconv_errno == NULL) { iconv_end(); + if (verbose && p_verbose > 0) + EMSG2(_("E448: Could not load library function %s"), + "for libiconv"); return FALSE; } return TRUE; *************** *** 2607,2612 **** --- 2616,2624 ---- #if defined(FEAT_GUI_GTK) || defined(PROTO) static int xim_preediting INIT(= FALSE); /* XIM in showmode() */ static int xim_input_style; + #ifndef FEAT_GUI_GTK + # define gboolean int + #endif static gboolean use_status_area = 0; static int im_xim_str2keycode __ARGS((unsigned int *code, unsigned int *state)); *** ../vim60.69/src/os_win32.c Wed Oct 31 15:20:56 2001 --- src/os_win32.c Sun Nov 4 14:17:10 2001 *************** *** 255,261 **** --- 255,265 ---- STRCPY(gettail(dirname), GETTEXT_DLL); hLibintlDLL = LoadLibrary((char *)dirname); if (!hLibintlDLL) + { + if (p_verbose > 0) + EMSG2(_("E370: Could not load library %s"), GETTEXT_DLL); return 0; + } } for (i = 0; libintl_entry[i].name != NULL && libintl_entry[i].ptr != NULL; ++i) *************** *** 264,269 **** --- 268,276 ---- libintl_entry[i].name))) { dyn_libintl_end(); + if (p_verbose > 0) + EMSG2(_("E448: Could not load library function %s"), + libintl_entry[i].name); return 0; } } *** ../vim60.69/src/proto/if_perl.pro Tue Sep 25 21:49:36 2001 --- src/proto/if_perl.pro Sun Nov 4 13:32:23 2001 *************** *** 1,5 **** /* auto/if_perl.c */ ! int perl_enabled __ARGS((void)); void perl_end __ARGS((void)); void msg_split __ARGS((char_u *s, int attr)); void perl_win_free __ARGS((win_T *wp)); --- 1,5 ---- /* auto/if_perl.c */ ! int perl_enabled __ARGS((int verbose)); void perl_end __ARGS((void)); void msg_split __ARGS((char_u *s, int attr)); void perl_win_free __ARGS((win_T *wp)); *** ../vim60.69/src/proto/if_python.pro Tue Sep 25 21:49:16 2001 --- src/proto/if_python.pro Sun Nov 4 13:56:44 2001 *************** *** 1,5 **** /* if_python.c */ ! int python_enabled __ARGS((void)); void python_end __ARGS((void)); void ex_python __ARGS((exarg_T *eap)); void ex_pyfile __ARGS((exarg_T *eap)); --- 1,5 ---- /* if_python.c */ ! int python_enabled __ARGS((int verbose)); void python_end __ARGS((void)); void ex_python __ARGS((exarg_T *eap)); void ex_pyfile __ARGS((exarg_T *eap)); *** ../vim60.69/src/proto/if_ruby.pro Tue Sep 25 21:49:17 2001 --- src/proto/if_ruby.pro Sun Nov 4 13:56:49 2001 *************** *** 1,5 **** /* if_ruby.c */ ! int ruby_enabled __ARGS((void)); void ruby_end __ARGS((void)); void ex_ruby __ARGS((exarg_T *eap)); void ex_rubydo __ARGS((exarg_T *eap)); --- 1,5 ---- /* if_ruby.c */ ! int ruby_enabled __ARGS((int verbose)); void ruby_end __ARGS((void)); void ex_ruby __ARGS((exarg_T *eap)); void ex_rubydo __ARGS((exarg_T *eap)); *** ../vim60.69/src/proto/if_tcl.pro Tue Sep 25 21:49:33 2001 --- src/proto/if_tcl.pro Sun Nov 4 13:56:40 2001 *************** *** 1,6 **** /* if_tcl.c */ void tcl_init __ARGS((char *arg)); ! int tcl_enabled __ARGS((void)); void tcl_end __ARGS((void)); void ex_tcl __ARGS((exarg_T *eap)); void ex_tclfile __ARGS((exarg_T *eap)); --- 1,6 ---- /* if_tcl.c */ void tcl_init __ARGS((char *arg)); ! int tcl_enabled __ARGS((int verbose)); void tcl_end __ARGS((void)); void ex_tcl __ARGS((exarg_T *eap)); void ex_tclfile __ARGS((exarg_T *eap)); *** ../vim60.69/src/proto/mbyte.pro Tue Sep 25 21:49:21 2001 --- src/proto/mbyte.pro Sun Nov 4 14:07:02 2001 *************** *** 55,61 **** char_u *enc_canonize __ARGS((char_u *enc)); int enc_default __ARGS((void)); void *my_iconv_open __ARGS((char_u *to, char_u *from)); ! int iconv_enabled __ARGS((void)); void iconv_end __ARGS((void)); int im_xim_isvalid_imactivate __ARGS((void)); void im_set_active __ARGS((int active)); --- 55,61 ---- char_u *enc_canonize __ARGS((char_u *enc)); int enc_default __ARGS((void)); void *my_iconv_open __ARGS((char_u *to, char_u *from)); ! int iconv_enabled __ARGS((int verbose)); void iconv_end __ARGS((void)); int im_xim_isvalid_imactivate __ARGS((void)); void im_set_active __ARGS((int active)); *** ../vim60.69/src/version.c Sun Nov 4 13:19:04 2001 --- src/version.c Sun Nov 4 14:22:24 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 70, /**/ -- Engineers will go without food and hygiene for days to solve a problem. (Other times just because they forgot.) (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.071 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.071 Problem: The "iris-ansi" builtin termcap isn't very good. Solution: Fix the wrong entries. (David Harrison) Files: src/term.c *** ../vim60.70/src/term.c Mon Oct 22 18:52:01 2001 --- src/term.c Sun Nov 4 18:42:53 2001 *************** *** 1074,1098 **** # endif #endif {(int)KS_CL, "\033[H\033[2J"}, ! {(int)KS_VE, "\033[9/y\033[12/y"}, ! {(int)KS_VS, "\033[10/y\033[=1h\033[=2l"}, {(int)KS_TI, "\033[=6h"}, {(int)KS_TE, "\033[=6l"}, ! {(int)KS_SE, "\033[m"}, {(int)KS_SO, "\033[1;7m"}, {(int)KS_ME, "\033[m"}, {(int)KS_MR, "\033[7m"}, {(int)KS_MD, "\033[1m"}, - {(int)KS_UE, "\033[m"}, {(int)KS_CCO, "8"}, /* allow 8 colors */ # ifdef TERMINFO ! {(int)KS_CAB, "\033[4%p1%dm"}, /* set background color */ ! {(int)KS_CAF, "\033[3%p1%dm"}, /* set foreground color */ # else ! {(int)KS_CAB, "\033[4%dm"}, /* set background color */ ! {(int)KS_CAF, "\033[3%dm"}, /* set foreground color */ # endif - {(int)KS_US, "\033[4m"}, {(int)KS_MS, "y"}, /* guessed */ {(int)KS_UT, "y"}, /* guessed */ {(int)KS_LE, "\010"}, --- 1074,1104 ---- # endif #endif {(int)KS_CL, "\033[H\033[2J"}, ! {(int)KS_VE, "\033[9/y\033[12/y"}, /* These aren't documented */ ! {(int)KS_VS, "\033[10/y\033[=1h\033[=2l"}, /* These aren't documented */ {(int)KS_TI, "\033[=6h"}, {(int)KS_TE, "\033[=6l"}, ! {(int)KS_SE, "\033[21;27m"}, {(int)KS_SO, "\033[1;7m"}, {(int)KS_ME, "\033[m"}, {(int)KS_MR, "\033[7m"}, {(int)KS_MD, "\033[1m"}, {(int)KS_CCO, "8"}, /* allow 8 colors */ + {(int)KS_CZH, "\033[3m"}, /* italic mode on */ + {(int)KS_CZR, "\033[23m"}, /* italic mode off */ + {(int)KS_US, "\033[4m"}, /* underline on */ + {(int)KS_UE, "\033[24m"}, /* underline off */ # ifdef TERMINFO ! {(int)KS_CAB, "\033[4%p1%dm"}, /* set background color (ANSI) */ ! {(int)KS_CAF, "\033[3%p1%dm"}, /* set foreground color (ANSI) */ ! {(int)KS_CSB, "\033[102;%p1%dm"}, /* set screen background color */ ! {(int)KS_CSF, "\033[101;%p1%dm"}, /* set screen foreground color */ # else ! {(int)KS_CAB, "\033[4%dm"}, /* set background color (ANSI) */ ! {(int)KS_CAF, "\033[3%dm"}, /* set foreground color (ANSI) */ ! {(int)KS_CSB, "\033[102;%dm"}, /* set screen background color */ ! {(int)KS_CSF, "\033[101;%dm"}, /* set screen foreground color */ # endif {(int)KS_MS, "y"}, /* guessed */ {(int)KS_UT, "y"}, /* guessed */ {(int)KS_LE, "\010"}, *************** *** 1108,1120 **** {(int)KS_CRI, "\033[%dC"}, # endif {(int)KS_CIS, "\033P3.y"}, ! {(int)KS_CIE, "\234"}, {(int)KS_TS, "\033P1.y"}, ! {(int)KS_FS, "\234"}, # ifdef TERMINFO {(int)KS_CWS, "\033[203;%p1%d;%p2%d/y"}, # else {(int)KS_CWS, "\033[203;%d;%d/y"}, # endif {K_UP, "\033[A"}, {K_DOWN, "\033[B"}, --- 1114,1128 ---- {(int)KS_CRI, "\033[%dC"}, # endif {(int)KS_CIS, "\033P3.y"}, ! {(int)KS_CIE, "\234"}, /* ST "String Terminator" */ {(int)KS_TS, "\033P1.y"}, ! {(int)KS_FS, "\234"}, /* ST "String Terminator" */ # ifdef TERMINFO {(int)KS_CWS, "\033[203;%p1%d;%p2%d/y"}, + {(int)KS_CWP, "\033[205;%p1%d;%p2%d/y"}, # else {(int)KS_CWS, "\033[203;%d;%d/y"}, + {(int)KS_CWP, "\033[205;%d;%d/y"}, # endif {K_UP, "\033[A"}, {K_DOWN, "\033[B"}, *** ../vim60.70/src/version.c Sun Nov 4 14:31:23 2001 --- src/version.c Sun Nov 4 18:44:46 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 71, /**/ -- Engineers are always delighted to share wisdom, even in areas in which they have no experience whatsoever. Their logic provides them with inherent insight into any field of expertise. This can be a problem when dealing with the illogical people who believe that knowledge can only be derived through experience. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.072 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.072 Problem: When 'lazyredraw' is set, a mapping that stops Visual mode, moves the cursor and starts Visual mode again causes a redraw problem. (Brian Silverman) Solution: Redraw both the old and the new Visual area when necessary. Files: src/normal.c, src/screen.c *** ../vim60.71/src/normal.c Sun Nov 4 13:19:04 2001 --- src/normal.c Sun Nov 4 19:03:27 2001 *************** *** 6491,6499 **** clip_star.vmode = NUL; #endif ! /* Only need to redraw this line. */ ! curwin->w_old_cursor_lnum = curwin->w_cursor.lnum; ! curwin->w_old_visual_lnum = curwin->w_cursor.lnum; } #endif /* FEAT_VISUAL */ --- 6491,6503 ---- clip_star.vmode = NUL; #endif ! /* Only need to redraw this line, unless still need to redraw an old ! * Visual area (when 'lazyredraw' is set). */ ! if (curwin->w_redr_type < INVERTED) ! { ! curwin->w_old_cursor_lnum = curwin->w_cursor.lnum; ! curwin->w_old_visual_lnum = curwin->w_cursor.lnum; ! } } #endif /* FEAT_VISUAL */ *** ../vim60.71/src/screen.c Thu Nov 1 14:59:19 2001 --- src/screen.c Sun Nov 4 19:06:14 2001 *************** *** 1171,1176 **** --- 1171,1180 ---- from = wp->w_old_cursor_lnum; if (wp->w_old_cursor_lnum > to) to = wp->w_old_cursor_lnum; + if (wp->w_old_visual_lnum < from) + from = wp->w_old_visual_lnum; + if (wp->w_old_visual_lnum > to) + to = wp->w_old_visual_lnum; } else { *** ../vim60.71/src/version.c Sun Nov 4 18:45:17 2001 --- src/version.c Sun Nov 4 19:08:13 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 72, /**/ -- For humans, honesty is a matter of degree. Engineers are always honest in matters of technology and human relationships. That's why it's a good idea to keep engineers away from customers, romantic interests, and other people who can't handle the thruth. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.073 (extra) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.073 (extra) Problem: DJGPP: When using CTRL-Z to start a shell, the prompt is halfway the text. (Volker Kiefel) Solution: Position the system cursor before starting the shell. Files: src/os_msdos.c *** ../vim60.72/src/os_msdos.c Sun Sep 16 17:17:36 2001 --- src/os_msdos.c Sun Nov 4 19:28:43 2001 *************** *** 115,126 **** --- 115,148 ---- int S_iBufferColumn; static void + myflush(void) + { + if (S_linebufferpos != S_linebuffer) + { + _dosmemputw(S_linebuffer, (S_linebufferpos - S_linebuffer), + S_ulScreenBase + + S_iBufferRow * (Columns << 1) + (S_iBufferColumn << 1)); + S_linebufferpos = S_linebuffer; + } + } + + static void mygotoxy(int x, int y) { S_iCurrentRow = y - 1; S_iCurrentColumn = x - 1; } + /* + * Set the system cursor to our cursor position. + */ + static void + set_sys_cursor(void) + { + myflush(); + gotoxy(S_iCurrentColumn + 1, S_iCurrentRow + 1); + } + static void setblankbuffer(unsigned short uiValue) { *************** *** 222,239 **** + (S_iBottom - 1) * (Columns << 1) + iColumn); } - static void - myflush(void) - { - if (S_linebufferpos != S_linebuffer) - { - _dosmemputw(S_linebuffer, (S_linebufferpos - S_linebuffer), - S_ulScreenBase - + S_iBufferRow * (Columns << 1) + (S_iBufferColumn << 1)); - S_linebufferpos = S_linebuffer; - } - } - static int myputch(int iChar) { --- 244,249 ---- *************** *** 1007,1014 **** show_mouse(TRUE); #endif #ifdef DJGPP ! myflush(); ! gotoxy(S_iCurrentColumn + 1, S_iCurrentRow + 1); #endif if (time >= 0) { --- 1017,1023 ---- show_mouse(TRUE); #endif #ifdef DJGPP ! set_sys_cursor(); #endif if (time >= 0) { *************** *** 1895,1903 **** stoptermcap(); set_interrupts(FALSE); /* restore interrupts */ #ifdef DJGPP ! /* Let the system know where our cursor is. */ ! myflush(); ! gotoxy(S_iCurrentColumn + 1, S_iCurrentRow + 1); #endif /* Somehow outputting CR-NL causes the original colors to be restored */ out_char('\r'); --- 1904,1910 ---- stoptermcap(); set_interrupts(FALSE); /* restore interrupts */ #ifdef DJGPP ! set_sys_cursor(); #endif /* Somehow outputting CR-NL causes the original colors to be restored */ out_char('\r'); *************** *** 2102,2107 **** --- 2109,2117 ---- #endif out_flush(); + #ifdef DJGPP + set_sys_cursor(); + #endif if (options & SHELL_COOKED) settmode(TMODE_COOK); /* set to normal mode */ *** ../vim60.72/src/version.c Sun Nov 4 19:10:16 2001 --- src/version.c Sun Nov 4 19:32:16 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 73, /**/ -- Engineers are widely recognized as superior marriage material: intelligent, dependable, employed, honest, and handy around the house. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.074 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.074 Problem: When using "&" in a substitute string a multi-byte character with a trailbyte 0x5c is not handled correctly. Solution: Recognize multi-byte characters inside the "&" part. (Muraoka Taro) Files: src/regexp.c *** ../vim60.73/src/regexp.c Wed Oct 31 15:17:54 2001 --- src/regexp.c Mon Nov 5 08:46:11 2001 *************** *** 5403,5408 **** --- 5403,5412 ---- #ifdef FEAT_EVAL static char_u *eval_result = NULL; #endif + #ifdef FEAT_MBYTE + int l; + #endif + /* Be paranoid... */ if (source == NULL || dest == NULL) *************** *** 5482,5491 **** } if (no < 0) /* Ordinary character. */ { - #ifdef FEAT_MBYTE - int l; - #endif - if (c == '\\' && *src != NUL) { /* Check for abbreviations -- webb */ --- 5486,5491 ---- *************** *** 5606,5611 **** --- 5606,5622 ---- } dst += 2; } + #ifdef FEAT_MBYTE + else if (has_mbyte && (l = (*mb_ptr2len_check)(s)) > 1) + { + /* TODO: should use "func" here. */ + if (copy) + mch_memmove(dst, s, l); + dst += l; + s += l - 1; + len -= l - 1; + } + #endif else { if (copy) *** ../vim60.73/src/version.c Mon Nov 5 08:51:05 2001 --- src/version.c Mon Nov 5 08:50:40 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 74, /**/ -- Engineers understand that their appearance only bothers other people and therefore it is not worth optimizing. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.075 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.075 Problem: When closing a horizontally split window while 'eadirection' is "hor" another horizontally split window is still resized. (Aron Griffis) Solution: Only resize windows in the same top frame as the window that is split or closed. Files: src/main.c, src/proto/window.pro, src/window.c *** ../vim60.74/src/main.c Thu Nov 1 12:22:41 2001 --- src/main.c Mon Nov 5 09:29:34 2001 *************** *** 1716,1722 **** # endif TIME_MSG("editing files in windows"); if (window_count > 1) ! win_equal(curwin, 'b'); /* adjust heights */ #endif /* FEAT_WINDOWS */ #ifdef FEAT_DIFF --- 1716,1722 ---- # endif TIME_MSG("editing files in windows"); if (window_count > 1) ! win_equal(curwin, FALSE, 'b'); /* adjust heights */ #endif /* FEAT_WINDOWS */ #ifdef FEAT_DIFF *** ../vim60.74/src/proto/window.pro Tue Sep 25 21:49:27 2001 --- src/proto/window.pro Mon Nov 5 09:29:09 2001 *************** *** 5,11 **** int win_count __ARGS((void)); int make_windows __ARGS((int count, int vertical)); void win_move_after __ARGS((win_T *win1, win_T *win2)); ! void win_equal __ARGS((win_T *next_curwin, int dir)); void close_windows __ARGS((buf_T *buf)); void win_close __ARGS((win_T *win, int free_buf)); void close_others __ARGS((int message, int forceit)); --- 5,11 ---- int win_count __ARGS((void)); int make_windows __ARGS((int count, int vertical)); void win_move_after __ARGS((win_T *win1, win_T *win2)); ! void win_equal __ARGS((win_T *next_curwin, int current, int dir)); void close_windows __ARGS((buf_T *buf)); void win_close __ARGS((win_T *win, int free_buf)); void close_others __ARGS((int message, int forceit)); *** ../vim60.74/src/window.c Thu Nov 1 14:51:27 2001 --- src/window.c Mon Nov 5 09:49:44 2001 *************** *** 25,31 **** static void win_exchange __ARGS((long)); static void win_rotate __ARGS((int, int)); static void win_totop __ARGS((int size, int flags)); ! static void win_equal_rec __ARGS((win_T *next_curwin, frame_T *topfr, int dir, int col, int row, int width, int height)); static win_T *winframe_remove __ARGS((win_T *win, int *dirp)); static frame_T *win_altframe __ARGS((win_T *win)); static win_T *frame2win __ARGS((frame_T *frp)); --- 25,31 ---- static void win_exchange __ARGS((long)); static void win_rotate __ARGS((int, int)); static void win_totop __ARGS((int size, int flags)); ! static void win_equal_rec __ARGS((win_T *next_curwin, int current, frame_T *topfr, int dir, int col, int row, int width, int height)); static win_T *winframe_remove __ARGS((win_T *win, int *dirp)); static frame_T *win_altframe __ARGS((win_T *win)); static win_T *frame2win __ARGS((frame_T *frp)); *************** *** 367,373 **** #ifdef FEAT_GUI need_mouse_correct = TRUE; #endif ! win_equal(NULL, 0); break; /* increase current window height */ --- 367,373 ---- #ifdef FEAT_GUI need_mouse_correct = TRUE; #endif ! win_equal(NULL, FALSE, 0); break; /* increase current window height */ *************** *** 1015,1021 **** * make the new window the current window and redraw */ if (do_equal || dir != 0) ! win_equal(wp, #ifdef FEAT_VERTSPLIT (flags & WSP_VERT) ? (dir == 'v' ? 'b' : 'h') : dir == 'h' ? 'b' : --- 1015,1021 ---- * make the new window the current window and redraw */ if (do_equal || dir != 0) ! win_equal(wp, TRUE, #ifdef FEAT_VERTSPLIT (flags & WSP_VERT) ? (dir == 'v' ? 'b' : 'h') : dir == 'h' ? 'b' : *************** *** 1485,1492 **** * rows. */ void ! win_equal(next_curwin, dir) win_T *next_curwin; /* pointer to current window to be or NULL */ int dir; /* 'v' for vertically, 'h' for horizontally, 'b' for both, 0 for using p_ead */ { --- 1485,1493 ---- * rows. */ void ! win_equal(next_curwin, current, dir) win_T *next_curwin; /* pointer to current window to be or NULL */ + int current; /* do only frame with current window */ int dir; /* 'v' for vertically, 'h' for horizontally, 'b' for both, 0 for using p_ead */ { *************** *** 1496,1503 **** #else dir = 'b'; #endif ! win_equal_rec(next_curwin == NULL ? curwin : next_curwin, topframe, dir, ! 0, 0, (int)Columns, topframe->fr_height); } /* --- 1497,1504 ---- #else dir = 'b'; #endif ! win_equal_rec(next_curwin == NULL ? curwin : next_curwin, current, ! topframe, dir, 0, 0, (int)Columns, topframe->fr_height); } /* *************** *** 1507,1514 **** * 'winheight' and 'winwidth' if possible. */ static void ! win_equal_rec(next_curwin, topfr, dir, col, row, width, height) win_T *next_curwin; /* pointer to current window to be or NULL */ frame_T *topfr; /* frame to set size off */ int dir; /* 'v', 'h' or 'b', see win_equal() */ int col; /* horizontal position for frame */ --- 1508,1516 ---- * 'winheight' and 'winwidth' if possible. */ static void ! win_equal_rec(next_curwin, current, topfr, dir, col, row, width, height) win_T *next_curwin; /* pointer to current window to be or NULL */ + int current; /* do only frame with current window */ frame_T *topfr; /* frame to set size off */ int dir; /* 'v', 'h' or 'b', see win_equal() */ int col; /* horizontal position for frame */ *************** *** 1616,1622 **** new_size += next_curwin_size; } } ! win_equal_rec(next_curwin, fr, dir, col, row, new_size + n, height); col += new_size + n; width -= new_size + n; if (n != m) /* contains curwin */ --- 1618,1631 ---- new_size += next_curwin_size; } } ! ! /* Skip frame that is full height when splitting or closing a ! * window, unless equalizing all frames. */ ! if (!current || dir != 'v' || topfr->fr_parent != NULL ! || (new_size != fr->fr_width) ! || frame_has_win(fr, next_curwin)) ! win_equal_rec(next_curwin, current, fr, dir, col, row, ! new_size + n, height); col += new_size + n; width -= new_size + n; if (n != m) /* contains curwin */ *************** *** 1766,1772 **** room -= new_size; new_size += n; } ! win_equal_rec(next_curwin, fr, dir, col, row, width, new_size); row += new_size; height -= new_size; totwincount -= wincount; --- 1775,1787 ---- room -= new_size; new_size += n; } ! /* Skip frame that is full width when splitting or closing a ! * window, unless equalizing all frames. */ ! if (!current || dir != 'h' || topfr->fr_parent != NULL ! || (new_size != fr->fr_height) ! || frame_has_win(fr, next_curwin)) ! win_equal_rec(next_curwin, current, fr, dir, col, row, ! width, new_size); row += new_size; height -= new_size; totwincount -= wincount; *************** *** 1906,1912 **** close_curwin = TRUE; } if (p_ea) ! win_equal(curwin, #ifdef FEAT_VERTSPLIT dir #else --- 1921,1927 ---- close_curwin = TRUE; } if (p_ea) ! win_equal(curwin, TRUE, #ifdef FEAT_VERTSPLIT dir #else *************** *** 3199,3205 **** #if 0 /* Disabled: don't want making the screen smaller make a window larger. */ if (p_ea) ! win_equal(curwin, 'v'); #endif } --- 3214,3220 ---- #if 0 /* Disabled: don't want making the screen smaller make a window larger. */ if (p_ea) ! win_equal(curwin, FALSE, 'v'); #endif } *************** *** 3217,3223 **** #if 0 /* Disabled: don't want making the screen smaller make a window larger. */ if (p_ea) ! win_equal(curwin, 'h'); #endif } #endif --- 3232,3238 ---- #if 0 /* Disabled: don't want making the screen smaller make a window larger. */ if (p_ea) ! win_equal(curwin, FALSE, 'h'); #endif } #endif *** ../vim60.74/src/version.c Mon Nov 5 09:00:25 2001 --- src/version.c Mon Nov 5 09:41:37 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 75, /**/ -- Imagine a world without hypothetical situations. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.076 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.076 Problem: Warning for wrong pointer type when compiling. Solution: Use char instead of char_u pointer. Files: src/version.c *** ../vim60.75/src/version.c Mon Nov 5 09:52:01 2001 --- src/version.c Mon Nov 5 11:14:45 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 76, /**/ *************** *** 1080,1084 **** int row; int blanklines; ! char_u *p; static char *(lines[]) = { --- 1082,1086 ---- int row; int blanklines; ! char *p; static char *(lines[]) = { -- It doesn't really matter what you can do if you don't do it. (Bram Moolenaar) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.077 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.077 Problem: Patch 6.0.075 was incomplete. Solution: Fix another call to win_equal(). Files: src/option.c *** ../vim60.76/src/option.c Thu Oct 25 16:34:24 2001 --- src/option.c Mon Nov 5 09:29:47 2001 *************** *** 5709,5715 **** else if ((int *)varp == &p_ea) { if (p_ea && !old_value) ! win_equal(curwin, 0); } #endif --- 5709,5715 ---- else if ((int *)varp == &p_ea) { if (p_ea && !old_value) ! win_equal(curwin, FALSE, 0); } #endif *** ../vim60.76/src/version.c Mon Nov 5 11:15:34 2001 --- src/version.c Mon Nov 5 12:50:14 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 77, /**/ -- No engineer can take a shower without wondering if some sort of Teflon coating would make showering unnecessary. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.078 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.078 Problem: Using "daw" at the end of a line on a single-character word didn't include the white space before it. At the end of the file it didn't work at all. (Gavin Sinclair) Solution: Include the white space before the word. Files: src/search.c *** ../vim60.77/src/search.c Thu Nov 1 21:26:45 2001 --- src/search.c Mon Nov 5 12:48:43 2001 *************** *** 2703,2718 **** * If the start is not on white space, and white space should be * included ("word "), or start is on white space and white * space should not be included (" "), find start of word. */ ! if (fwd_word(1L, bigword, TRUE) == FAIL) ! return FAIL; ! /* ! * If end is just past a new-line, we don't want to include the ! * first character on the line ! */ ! if (oneleft() == FAIL) /* put cursor on last char of area */ ! inclusive = FALSE; ! else if (include) { /* * If we don't include white space at the end, move the start --- 2703,2718 ---- * If the start is not on white space, and white space should be * included ("word "), or start is on white space and white * space should not be included (" "), find start of word. + * If we end up in the first column of the next line (single char + * word) back up to end of the line. */ ! fwd_word(1L, bigword, TRUE); ! if (curwin->w_cursor.col == 0) ! decl(&curwin->w_cursor); ! else ! oneleft(); ! ! if (include) { /* * If we don't include white space at the end, move the start *** ../vim60.77/src/version.c Mon Nov 5 12:51:06 2001 --- src/version.c Mon Nov 5 13:11:50 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 78, /**/ -- The process for understanding customers primarily involves sitting around with other marketing people and talking about what you would to if you were dumb enough to be a customer. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.079 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.079 Problem: When "W" is in 'cpoptions' and 'backupcopy' is "no" or "auto", can still overwrite a read-only file, because it's renamed. (Gary Holloway) Solution: Add a check for a read-only file before renaming the file to become the backup. Files: src/fileio.c *** ../vim60.78/src/fileio.c Tue Oct 30 20:35:08 2001 --- src/fileio.c Mon Nov 5 19:37:58 2001 *************** *** 2204,2209 **** --- 2204,2211 ---- int device = FALSE; /* writing to a device */ struct stat st_old; int prev_got_int = got_int; + int file_readonly = FALSE; /* overwritten file is read-only */ + static char *err_readonly = "is read-only (cannot override: \"W\" in 'cpoptions')"; #if defined(UNIX) || defined(__EMX__XX) /*XXX fix me sometime? */ int made_writable = FALSE; /* 'w' bit has been set */ #endif *************** *** 2540,2546 **** * Check if the file is really writable (when renaming the file to * make a backup we won't discover it later). */ ! if (!forceit && ( # ifdef USE_MCH_ACCESS # ifdef UNIX (perm & 0222) == 0 || --- 2542,2548 ---- * Check if the file is really writable (when renaming the file to * make a backup we won't discover it later). */ ! file_readonly = ( # ifdef USE_MCH_ACCESS # ifdef UNIX (perm & 0222) == 0 || *************** *** 2548,2558 **** mch_access((char *)fname, W_OK) # else (fd = mch_open((char *)fname, O_RDWR | O_EXTRA, 0)) < 0 ! ? TRUE : (close(fd), FALSE) # endif ! )) { ! errmsg = (char_u *)_("is read-only (use ! to override)"); goto fail; } --- 2550,2564 ---- mch_access((char *)fname, W_OK) # else (fd = mch_open((char *)fname, O_RDWR | O_EXTRA, 0)) < 0 ! ? TRUE : (close(fd), FALSE) # endif ! ); ! if (!forceit && file_readonly) { ! if (vim_strchr(p_cpo, CPO_FWRITE) != NULL) ! errmsg = (char_u *)_(err_readonly); ! else ! errmsg = (char_u *)_("is read-only (use ! to override)"); goto fail; } *************** *** 2895,2900 **** --- 2901,2919 ---- /* * Make a backup by renaming the original file. + */ + /* + * If 'cpoptions' includes the "W" flag, we don't want to + * overwrite a read-only file. But rename may be possible + * anyway, thus we need an extra check here. + */ + if (file_readonly && vim_strchr(p_cpo, CPO_FWRITE) != NULL) + { + errmsg = (char_u *)_(err_readonly); + goto fail; + } + + /* * * Form the backup file name - change path/fo.o.h to * path/fo.o.h.bak Try all directories in 'backupdir', first one *** ../vim60.78/src/version.c Mon Nov 5 13:16:21 2001 --- src/version.c Mon Nov 5 20:31:42 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 79, /**/ -- hundred-and-one symptoms of being an internet addict: 1. You actually wore a blue ribbon to protest the Communications Decency Act. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.080 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.080 Problem: When using a session file that has the same file in two windows, the fileinfo() call in do_ecmd() causes a scroll and a hit-enter prompt. (Robert Webb) Solution: Don't scroll this message when 'shortmess' contains 'O'. Files: src/ex_cmds.c *** ../vim60.79/src/ex_cmds.c Fri Sep 21 20:05:35 2001 --- src/ex_cmds.c Mon Nov 5 20:55:36 2001 *************** *** 2972,2978 **** --- 2972,2994 ---- && !auto_buf #endif ) + { + int msg_scroll_save = msg_scroll; + + /* Obey the 'O' flag in 'cpoptions': overwrite any previous file + * message. */ + if (shortmess(SHM_OVERALL) && !exiting && p_verbose == 0) + msg_scroll = FALSE; + if (!msg_scroll) /* wait a bit when overwriting an error msg */ + check_for_delay(FALSE); + msg_start(); + msg_scroll = msg_scroll_save; + msg_scrolled_ign = TRUE; + fileinfo(FALSE, TRUE, FALSE); + + msg_scrolled_ign = FALSE; + } if (command != NULL) do_cmdline(command, NULL, NULL, DOCMD_VERBOSE); *** ../vim60.79/src/version.c Mon Nov 5 21:01:58 2001 --- src/version.c Mon Nov 5 20:57:03 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 80, /**/ -- hundred-and-one symptoms of being an internet addict: 4. Your eyeglasses have a web site burned in on them. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.081 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.081 Problem: After using ":saveas" the new buffer name is added to the Buffers menu with a wrong number. (Chauk-Mean Proum) Solution: Trigger BufFilePre and BufFilePost events for the renamed buffer and BufAdd for the old name (which is with a new buffer). Files: src/ex_cmds.c *** ../vim60.80/src/ex_cmds.c Mon Nov 5 21:04:40 2001 --- src/ex_cmds.c Mon Nov 5 21:16:41 2001 *************** *** 2142,2147 **** --- 2142,2158 ---- if (eap->cmdidx == CMD_saveas && alt_buf != NULL) { + #ifdef FEAT_AUTOCMD + buf_T *was_curbuf = curbuf; + + apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, curbuf); + if (curbuf != was_curbuf) + { + /* buffer changed, don't change name now */ + retval = FAIL; + goto theend; + } + #endif /* Exchange the file names for the current and the alternate buffer. * This makes it look like we are now editing the buffer under the new * name. Must be done before buf_write(), because if there is no file *************** *** 2157,2166 **** curbuf->b_sfname = fname; buf_name_changed(); #ifdef FEAT_AUTOCMD if (!alt_buf->b_p_bl) { alt_buf->b_p_bl = TRUE; ! apply_autocmds(EVENT_BUFADD, NULL, NULL, FALSE, curbuf); } #endif } --- 2168,2184 ---- curbuf->b_sfname = fname; buf_name_changed(); #ifdef FEAT_AUTOCMD + apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf); if (!alt_buf->b_p_bl) { alt_buf->b_p_bl = TRUE; ! apply_autocmds(EVENT_BUFADD, NULL, NULL, FALSE, alt_buf); ! } ! if (curbuf != was_curbuf) ! { ! /* buffer changed, don't write the file */ ! retval = FAIL; ! goto theend; } #endif } *** ../vim60.80/src/version.c Mon Nov 5 21:04:40 2001 --- src/version.c Mon Nov 5 21:23:51 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 81, /**/ -- hundred-and-one symptoms of being an internet addict: 5. You find yourself brainstorming for new subjects to search. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.082 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.082 Problem: When swapping screens in an xterm and there is an (error) message from the vimrc script, the shell prompt is after the message. Solution: Output a newline when there was output on the alternate screen. Also when starting the GUI. Files: src/main.c *** ../vim60.81/src/main.c Mon Nov 5 09:52:01 2001 --- src/main.c Mon Nov 5 22:04:39 2001 *************** *** 1362,1367 **** --- 1362,1374 ---- #ifdef FEAT_GUI if (gui.starting) { + #if defined(UNIX) || defined(VMS) + /* When something caused a message from a vimrc script, need to output + * an extra newline before the shell prompt. */ + if (did_emsg || msg_didout) + putchar('\n'); + #endif + gui_start(); /* will set full_screen to TRUE */ TIME_MSG("starting GUI"); } *************** *** 1502,1507 **** --- 1509,1521 ---- dup(2); #endif } + + #if defined(UNIX) || defined(VMS) + /* When switching screens and something caused a message from a vimrc + * script, need to output an extra newline on exit. */ + if ((did_emsg || msg_didout) && *T_TI != NUL) + newline_on_exit = TRUE; + #endif /* * When done something that is not allowed or error message call *** ../vim60.81/src/version.c Mon Nov 5 21:24:46 2001 --- src/version.c Mon Nov 5 22:06:01 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 82, /**/ -- hundred-and-one symptoms of being an internet addict: 6. You refuse to go to a vacation spot with no electricity and no phone lines. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.083 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.083 Problem: GTK: When compiled without menu support the buttons in a dialog don't have any text. (Erik Edelmann) Solution: Add the text also when GTK_USE_ACCEL isn't defined. And define GTK_USE_ACCEL also when not using menus. Files: src/gui_gtk.c *** ../vim60.82/src/gui_gtk.c Thu Oct 25 10:20:46 2001 --- src/gui_gtk.c Tue Nov 6 11:52:21 2001 *************** *** 119,126 **** static void exact_match_cb(GtkWidget *widget, gpointer data); static void repl_dir_cb(GtkWidget * widget, gpointer data); - #if defined(FEAT_MENU) || defined(PROTO) - /* * Only use accelerators when gtk_menu_ensure_uline_accel_group() is * available, which is in version 1.2.1. That was the first version where --- 119,124 ---- *************** *** 132,137 **** --- 130,137 ---- # endif #endif + #if defined(FEAT_MENU) || defined(PROTO) + /* * Create a highly customized menu item by hand instead of by using: * *************** *** 1337,1342 **** --- 1337,1344 ---- accel_key, 0, 0); } + # else + (void)gtk_label_parse_uline(GTK_LABEL(label), (const gchar *)p); # endif gtk_container_add(GTK_CONTAINER(button[butcount]), label); *** ../vim60.82/src/version.c Mon Nov 5 22:06:57 2001 --- src/version.c Tue Nov 6 11:56:49 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 83, /**/ -- hundred-and-one symptoms of being an internet addict: 22. You've already visited all the links at Yahoo and you're halfway through Lycos. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.084 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.084 Problem: UTF-8: a "r" command with an argument that is a keymap for a character with a composing character can't be repeated with ".". (Raphael Finkel) Solution: Add the composing characters to the redo buffer. Files: src/normal.c *** ../vim60.83/src/normal.c Sun Nov 4 19:10:16 2001 --- src/normal.c Tue Nov 6 14:19:12 2001 *************** *** 5854,5859 **** --- 5854,5864 ---- { int old_State = State; + if (cap->ncharC1 != 0) + AppendCharToRedobuff(cap->ncharC1); + if (cap->ncharC2 != 0) + AppendCharToRedobuff(cap->ncharC2); + /* This is slow, but it handles replacing a single-byte with a * multi-byte and the other way around. Also handles adding * composing characters for utf-8. */ *** ../vim60.83/src/version.c Tue Nov 6 11:58:54 2001 --- src/version.c Tue Nov 6 14:24:11 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 84, /**/ -- Q: What is the difference betwee open-source and commercial software? A: If you have a problem with commercial software you can call a phone number and they will tell you it might be solved in a future version. For open-source sofware there isn't a phone number to call, but you get the solution within a day. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.085 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.085 Problem: When 'mousefocus' is set, using "s" to go to Insert mode and then moving the mouse pointer to another window stops Insert mode, while this doesn't happen with "a" or "i". (Robert Webb) Solution: Reset finish_op before calling edit(). Files: src/normal.c *** ../vim60.84/src/normal.c Tue Nov 6 14:25:46 2001 --- src/normal.c Tue Nov 6 14:34:26 2001 *************** *** 1736,1741 **** --- 1736,1743 ---- else restart_edit_save = 0; restart_edit = 0; + /* Reset finish_op now, don't want it set inside edit(). */ + finish_op = FALSE; if (op_change(oap)) /* will call edit() */ cap->retval |= CA_COMMAND_BUSY; if (restart_edit == 0) *** ../vim60.84/src/version.c Tue Nov 6 14:25:46 2001 --- src/version.c Tue Nov 6 14:38:23 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 85, /**/ -- If all you have is a hammer, everything looks like a nail. When your hammer is C++, everything begins to look like a thumb. -- Steve Hoflich, comp.lang.c++ /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.086 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.086 Problem: When using "gu" the message says "~ed". Solution: Make the message say "changed". Files: src/ops.c *** ../vim60.85/src/ops.c Sun Nov 4 13:15:58 2001 --- src/ops.c Sat Nov 3 21:25:47 2001 *************** *** 1948,1954 **** #endif /* ! * Handle the (non-standard vi) tilde operator. Also for "gu" and "gU". */ void op_tilde(oap) --- 1948,1954 ---- #endif /* ! * Handle the (non-standard vi) tilde operator. Also for "gu", "gU" and "g?". */ void op_tilde(oap) *************** *** 2018,2032 **** if (oap->line_count > p_report) { if (oap->line_count == 1) ! MSG(_("1 line ~ed")); else ! smsg((char_u *)_("%ld lines ~ed"), oap->line_count); } } /* * If op_type == OP_UPPER: make uppercase, * if op_type == OP_LOWER: make lowercase, * else swap case of character at 'pos' * returns TRUE when something actually changed. */ --- 2018,2033 ---- if (oap->line_count > p_report) { if (oap->line_count == 1) ! MSG(_("1 line changed")); else ! smsg((char_u *)_("%ld lines changed"), oap->line_count); } } /* * If op_type == OP_UPPER: make uppercase, * if op_type == OP_LOWER: make lowercase, + * if op_type == OP_ROT13: do rot13 encoding, * else swap case of character at 'pos' * returns TRUE when something actually changed. */ *** ../vim60.85/src/version.c Tue Nov 6 14:39:24 2001 --- src/version.c Tue Nov 6 15:51:38 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 86, /**/ -- Anyone who is capable of getting themselves made President should on no account be allowed to do the job. -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.088 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.088 Problem: "." doesn't work after using "rx" in Visual mode. (Charles Campbell) Solution: Also store the replacement character in the redo buffer. Files: src/normal.c *** ../vim60.87/src/normal.c Tue Nov 6 14:39:24 2001 --- src/normal.c Tue Nov 6 16:47:09 2001 *************** *** 1515,1523 **** && oap->motion_force == NUL ) { ! prep_redo(oap->regname, 0L, NUL, 'v', NUL, ! get_op_char(oap->op_type), ! get_extra_op_char(oap->op_type)); redo_VIsual_mode = resel_VIsual_mode; redo_VIsual_col = resel_VIsual_col; redo_VIsual_line_count = resel_VIsual_line_count; --- 1515,1522 ---- && oap->motion_force == NUL ) { ! prep_redo(oap->regname, 0L, NUL, 'v', get_op_char(oap->op_type), ! get_extra_op_char(oap->op_type), cap->nchar); redo_VIsual_mode = resel_VIsual_mode; redo_VIsual_col = resel_VIsual_col; redo_VIsual_line_count = resel_VIsual_line_count; *** ../vim60.87/src/version.c Tue Nov 6 16:30:59 2001 --- src/version.c Tue Nov 6 16:55:15 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 88, /**/ -- Don't Panic! -- The Hitchhiker's Guide to the Galaxy /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.089 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.089 Problem: In a C file, using "==" to align a line starting with "* " after a line with "* -" indents one space too few. (Piet Delport) Solution: Align with the previous line if the comment-start-string matches there. Files: src/misc1.c *** ../vim60.88/src/misc1.c Wed Oct 24 13:22:11 2001 --- src/misc1.c Tue Nov 6 19:33:32 2001 *************** *** 4792,4797 **** --- 4792,4799 ---- && (trypos = find_start_comment(ind_maxcomment)) != NULL) /* XXX */ { int lead_start_len = 2; + int lead_middle_len = 1; + char_u lead_start[COM_MAX_LEN]; /* start-comment string */ char_u lead_middle[COM_MAX_LEN]; /* middle-comment string */ char_u lead_end[COM_MAX_LEN]; /* end-comment string */ char_u *p; *************** *** 4827,4858 **** (void)copy_option_part(&p, lead_end, COM_MAX_LEN, ","); if (what == COM_START) { ! lead_start_len = (int)STRLEN(lead_end); start_off = off; start_align = align; } else if (what == COM_MIDDLE) { STRCPY(lead_middle, lead_end); } else if (what == COM_END) { /* If our line starts with the middle comment string, line it * up with the comment opener per the 'comments' option. */ ! if (STRNCMP(theline, lead_middle, STRLEN(lead_middle)) == 0 && STRNCMP(theline, lead_end, STRLEN(lead_end)) != 0) { if (start_off != 0) amount += start_off; else if (start_align == COM_RIGHT) ! amount += lead_start_len - (int)STRLEN(lead_middle); ! done = TRUE; break; } /* If our line starts with the end comment string, line it up * with the middle comment */ ! if (STRNCMP(theline, lead_middle, STRLEN(lead_middle)) != 0 && STRNCMP(theline, lead_end, STRLEN(lead_end)) == 0) { amount = get_indent_lnum(curwin->w_cursor.lnum - 1); --- 4829,4878 ---- (void)copy_option_part(&p, lead_end, COM_MAX_LEN, ","); if (what == COM_START) { ! STRCPY(lead_start, lead_end); ! lead_start_len = (int)STRLEN(lead_start); start_off = off; start_align = align; } else if (what == COM_MIDDLE) { STRCPY(lead_middle, lead_end); + lead_middle_len = (int)STRLEN(lead_middle); } else if (what == COM_END) { /* If our line starts with the middle comment string, line it * up with the comment opener per the 'comments' option. */ ! if (STRNCMP(theline, lead_middle, lead_middle_len) == 0 && STRNCMP(theline, lead_end, STRLEN(lead_end)) != 0) { + done = TRUE; + if (curwin->w_cursor.lnum > 1) + { + /* If the start comment string matches in the previous + * line, use the indent of that line pluss offset. If + * the middle comment string matches in the previous + * line, use the indent of that line. XXX */ + look = skipwhite(ml_get(curwin->w_cursor.lnum - 1)); + if (STRNCMP(look, lead_start, lead_start_len) == 0) + amount = get_indent_lnum(curwin->w_cursor.lnum - 1); + else if (STRNCMP(look, lead_middle, + lead_middle_len) == 0) + { + amount = get_indent_lnum(curwin->w_cursor.lnum - 1); + break; + } + } if (start_off != 0) amount += start_off; else if (start_align == COM_RIGHT) ! amount += lead_start_len - lead_middle_len; break; } /* If our line starts with the end comment string, line it up * with the middle comment */ ! if (STRNCMP(theline, lead_middle, lead_middle_len) != 0 && STRNCMP(theline, lead_end, STRLEN(lead_end)) == 0) { amount = get_indent_lnum(curwin->w_cursor.lnum - 1); *************** *** 4860,4866 **** if (off != 0) amount += off; else if (align == COM_RIGHT) ! amount += lead_start_len - (int)STRLEN(lead_middle); done = TRUE; break; } --- 4880,4886 ---- if (off != 0) amount += off; else if (align == COM_RIGHT) ! amount += lead_start_len - lead_middle_len; done = TRUE; break; } *** ../vim60.88/src/version.c Tue Nov 6 19:38:36 2001 --- src/version.c Tue Nov 6 19:29:12 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 89, /**/ -- If they don't keep on exercising their lips, he thought, their brains start working. -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.090 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.090 Problem: When a wrapping line does not fit in a window and 'scrolloff' is bigger than half the window height, moving the cursor left or right causes the screen to flash badly. (Lubomir Host) Solution: When there is not enough room to show 'scrolloff' screen lines and near the end of the line, show the end of the line. Files: src/move.c *** ../vim60.89/src/move.c Sat Sep 29 10:11:29 2001 --- src/move.c Tue Nov 6 21:38:50 2001 *************** *** 931,936 **** --- 931,937 ---- int extra; /* offset for first screen line */ int off; int n; + int p_lines; int width = 0; int textwidth; int new_leftcol; *************** *** 1071,1081 **** prev_skipcol = curwin->w_skipcol; ! n = 0; if ((curwin->w_wrow >= curwin->w_height || ((prev_skipcol > 0 || curwin->w_wrow + p_so >= curwin->w_height) ! && (n = #ifdef FEAT_DIFF plines_win_nofill #else --- 1072,1082 ---- prev_skipcol = curwin->w_skipcol; ! p_lines = 0; if ((curwin->w_wrow >= curwin->w_height || ((prev_skipcol > 0 || curwin->w_wrow + p_so >= curwin->w_height) ! && (p_lines = #ifdef FEAT_DIFF plines_win_nofill #else *************** *** 1102,1116 **** extra = 1; /* Compute last display line of the buffer line that we want at the * bottom of the window. */ ! if (n == 0) ! n = plines_win(curwin, curwin->w_cursor.lnum, FALSE); ! --n; ! if (curwin->w_wrow + p_so < n) n = curwin->w_wrow + p_so; if ((colnr_T)n >= curwin->w_height + curwin->w_skipcol / width) extra += 2; ! if (extra == 3) { /* not enough room for 'scrolloff', put cursor in the middle */ n = curwin->w_virtcol / width; --- 1103,1119 ---- extra = 1; /* Compute last display line of the buffer line that we want at the * bottom of the window. */ ! if (p_lines == 0) ! p_lines = plines_win(curwin, curwin->w_cursor.lnum, FALSE); ! --p_lines; ! if (p_lines > curwin->w_wrow + p_so) n = curwin->w_wrow + p_so; + else + n = p_lines; if ((colnr_T)n >= curwin->w_height + curwin->w_skipcol / width) extra += 2; ! if (extra == 3 || p_lines < p_so * 2) { /* not enough room for 'scrolloff', put cursor in the middle */ n = curwin->w_virtcol / width; *************** *** 1118,1123 **** --- 1121,1129 ---- n -= curwin->w_height / 2; else n = 0; + /* don't skip more than necessary */ + if (n > p_lines - curwin->w_height + 1) + n = p_lines - curwin->w_height + 1; curwin->w_skipcol = n * width; } else if (extra == 1) *************** *** 1149,1160 **** curwin->w_wrow -= extra; } ! extra = (curwin->w_skipcol - prev_skipcol) / width; if (extra > 0) win_ins_lines(curwin, 0, extra, FALSE, FALSE); else if (extra < 0) win_del_lines(curwin, 0, -extra, FALSE, FALSE); - } else curwin->w_skipcol = 0; --- 1155,1165 ---- curwin->w_wrow -= extra; } ! extra = ((int)prev_skipcol - (int)curwin->w_skipcol) / width; if (extra > 0) win_ins_lines(curwin, 0, extra, FALSE, FALSE); else if (extra < 0) win_del_lines(curwin, 0, -extra, FALSE, FALSE); } else curwin->w_skipcol = 0; *** ../vim60.89/src/version.c Tue Nov 6 19:43:29 2001 --- src/version.c Tue Nov 6 21:42:02 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 90, /**/ -- How To Keep A Healthy Level Of Insanity: 2. Page yourself over the intercom. Don't disguise your voice. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.091 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.091 Problem: Using CTRL-O in Insert mode, while 'virtualedit' is "all" and the cursor is after the end-of-line, moves the cursor left. (Yegappan Lakshmanan) Solution: Keep the cursor in the same position. Files: src/edit.c *** ../vim60.90/src/edit.c Sun Sep 23 21:34:28 2001 --- src/edit.c Tue Nov 6 09:10:57 2001 *************** *** 742,748 **** else restart_edit = 'I'; o_lnum = curwin->w_cursor.lnum; ! o_eol = (gchar_cursor() == NUL); goto doESCkey; #ifdef FEAT_SNIFF --- 742,753 ---- else restart_edit = 'I'; o_lnum = curwin->w_cursor.lnum; ! #ifdef FEAT_VIRTUALEDIT ! if (virtual_active()) ! o_eol = FALSE; /* cursor always keeps its column */ ! else ! #endif ! o_eol = (gchar_cursor() == NUL); goto doESCkey; #ifdef FEAT_SNIFF *************** *** 5631,5637 **** --- 5636,5646 ---- { #ifdef FEAT_VIRTUALEDIT if (curwin->w_cursor.coladd > 0 || ve_flags == VE_ALL) + { oneleft(); + if (restart_edit != NUL) + ++curwin->w_cursor.coladd; + } else #endif --curwin->w_cursor.col; *** ../vim60.90/src/version.c Tue Nov 6 21:48:06 2001 --- src/version.c Tue Nov 6 21:54:31 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 91, /**/ -- How To Keep A Healthy Level Of Insanity: 4. Put your garbage can on your desk and label it "in". /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.092 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.092 Problem: The explorer plugin doesn't ignore case of 'suffixes' on MS-Windows. (Mike Williams) Solution: Match or ignore case as appropriate for the OS. Files: runtime/plugin/explorer.vim *** ../vim60.91/runtime/plugin/explorer.vim Wed Sep 26 10:49:58 2001 --- runtime/plugin/explorer.vim Tue Nov 6 14:08:54 2001 *************** *** 323,329 **** nnoremap i :call ToggleLongList() nnoremap s :call SortSelect() nnoremap r :call SortReverse() ! nnoremap c :exec ("cd ".b:completePathEsc) nnoremap <2-leftmouse> :call DoubleClick() let &cpo = cpo_save --- 323,329 ---- nnoremap i :call ToggleLongList() nnoremap s :call SortSelect() nnoremap r :call SortReverse() ! nnoremap c :exec "cd ".b:completePathEsc nnoremap <2-leftmouse> :call DoubleClick() let &cpo = cpo_save *************** *** 536,541 **** --- 536,548 ---- function! s:SetSuffixesLast() let b:suffixesRegexp = '\(' . substitute(escape(&suffixes,s:escregexp),',','\\|','g') . '\)$' let b:suffixesHighlight = '^[^"].*\(' . substitute(escape(&suffixes,s:escregexp),',','\\|','g') . '\)\( \|$\)' + if has("fname_case") + let b:suffixesRegexp = '\C' . b:suffixesRegexp + let b:suffixesHighlight = '\C' . b:suffixesHighlight + else + let b:suffixesRegexp = '\c' . b:suffixesRegexp + let b:suffixesHighlight = '\c' . b:suffixesHighlight + endif if g:explSuffixesLast > 0 && &suffixes != "" let b:suffixeslast=" (" . &suffixes . " at end of list)" elseif g:explSuffixesLast < 0 && &suffixes != "" *************** *** 943,951 **** function! s:GetSection() let fn=s:GetFileName() let section="file" ! if (fn =~ '/$') let section="directory" ! elseif (fn =~ b:suffixesRegexp) let section="suffixes" endif return section --- 950,958 ---- function! s:GetSection() let fn=s:GetFileName() let section="file" ! if fn =~ '/$' let section="directory" ! elseif fn =~ b:suffixesRegexp let section="suffixes" endif return section *** ../vim60.91/src/version.c Tue Nov 6 21:57:04 2001 --- src/version.c Tue Nov 6 22:00:50 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 92, /**/ -- How To Keep A Healthy Level Of Insanity: 5. Put decaf in the coffee maker for 3 weeks. Once everyone has gotten over their caffeine addictions, switch to expresso. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.093 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.093 Problem: When the Tcl library couldn't be loaded dynamically, get an error message when closing a buffer or window. (Muraoka Taro) Solution: Only free structures if already using the Tcl interpreter. Files: src/if_tcl.c *** ../vim60.92/src/if_tcl.c Sun Nov 4 14:31:23 2001 --- src/if_tcl.c Tue Nov 6 11:39:23 2001 *************** *** 228,233 **** --- 228,236 ---- } #if defined(DYNAMIC_TCL) || defined(PROTO) + + static int stubs_initialized = FALSE; + /* * Return TRUE if the TCL interface can be used. */ *************** *** 235,242 **** tcl_enabled(verbose) int verbose; { - static int stubs_initialized = FALSE; - if (!stubs_initialized && find_executable_arg != NULL && tcl_runtime_link_init(DYNAMIC_TCL_DLL, verbose) == OK) { --- 238,243 ---- *************** *** 2079,2085 **** struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled(TRUE)) return; #endif --- 2080,2086 ---- struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!stubs_initialized) /* Not using Tcl, nothing to do. */ return; #endif *************** *** 2100,2106 **** struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!tcl_enabled(TRUE)) return; #endif --- 2101,2107 ---- struct ref *reflist; #ifdef DYNAMIC_TCL ! if (!stubs_initialized) /* Not using Tcl, nothing to do. */ return; #endif *** ../vim60.92/src/version.c Tue Nov 6 22:02:12 2001 --- src/version.c Tue Nov 6 22:03:56 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 93, /**/ -- How To Keep A Healthy Level Of Insanity: 6. In the memo field of all your checks, write "for sexual favors". /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.094 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.094 Problem: Athena: When clicking in the horizontal scrollbar Vim crashes. (Paul Ackersviller) Solution: Use the thumb size instead of the window pointer of the scrollbar (which is NULL). (David Harrison) Also avoid that scolling goes the wrong way in a narrow window. Files: src/gui_athena.c *** ../vim60.93/src/gui_athena.c Tue Sep 11 20:46:25 2001 --- src/gui_athena.c Wed Dec 12 20:29:52 2001 *************** *** 148,156 **** { sb_info = sb; if (data < -1) /* page-width left */ ! data = -(W_WIDTH(sb->wp) - 5); else if (data > 1) /* page-width right */ ! data = (W_WIDTH(sb->wp) - 5); } value = sb_info->value + data; --- 148,166 ---- { sb_info = sb; if (data < -1) /* page-width left */ ! { ! if (sb->size > 8) ! data = -(sb->size - 5); ! else ! data = -sb->size; ! } else if (data > 1) /* page-width right */ ! { ! if (sb->size > 8) ! data = (sb->size - 5); ! else ! data = sb->size; ! } } value = sb_info->value + data; *** ../vim60.93/src/version.c Tue Nov 6 22:08:40 2001 --- src/version.c Wed Dec 12 20:31:57 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 94, /**/ -- hundred-and-one symptoms of being an internet addict: 44. Your friends no longer send you e-mail...they just log on to your IRC channel. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.095 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.095 Problem: Perl: Deleting lines may leave the cursor beyond the end of the file. Solution: Check the cursor position after deleting a line. (Serguei) Files: src/if_perl.xs *** ../vim60.94/src/if_perl.xs Sun Nov 4 14:31:23 2001 --- src/if_perl.xs Wed Dec 12 20:59:21 2001 *************** *** 1086,1091 **** --- 1086,1092 ---- { ml_delete(lnum, 0); deleted_lines_mark(lnum, 1L); + check_cursor(); } curbuf = savebuf; update_curbuf(VALID); *** ../vim60.94/src/version.c Wed Dec 12 20:36:34 2001 --- src/version.c Wed Dec 12 21:03:16 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 95, /**/ -- hundred-and-one symptoms of being an internet addict: 48. You get a tatoo that says "This body best viewed with Netscape 3.1 or higher." /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.096 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.096 Problem: When ":saveas fname" fails because the file already exists, the file name is changed anyway and a following ":w" will overwrite the file. (Eric Carlier) Solution: Don't change the file name if the file already exists. Files: src/ex_cmds.c *** ../vim60.95/src/ex_cmds.c Mon Nov 5 21:24:46 2001 --- src/ex_cmds.c Wed Dec 12 21:32:55 2001 *************** *** 2140,2191 **** } } ! if (eap->cmdidx == CMD_saveas && alt_buf != NULL) { #ifdef FEAT_AUTOCMD ! buf_T *was_curbuf = curbuf; ! apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, curbuf); ! if (curbuf != was_curbuf) ! { ! /* buffer changed, don't change name now */ ! retval = FAIL; ! goto theend; ! } #endif ! /* Exchange the file names for the current and the alternate buffer. ! * This makes it look like we are now editing the buffer under the new ! * name. Must be done before buf_write(), because if there is no file ! * name and 'cpo' contains 'F', it will set the file name. */ ! fname = alt_buf->b_fname; ! alt_buf->b_fname = curbuf->b_fname; ! curbuf->b_fname = fname; ! fname = alt_buf->b_ffname; ! alt_buf->b_ffname = curbuf->b_ffname; ! curbuf->b_ffname = fname; ! fname = alt_buf->b_sfname; ! alt_buf->b_sfname = curbuf->b_sfname; ! curbuf->b_sfname = fname; ! buf_name_changed(); #ifdef FEAT_AUTOCMD ! apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf); ! if (!alt_buf->b_p_bl) ! { ! alt_buf->b_p_bl = TRUE; ! apply_autocmds(EVENT_BUFADD, NULL, NULL, FALSE, alt_buf); ! } ! if (curbuf != was_curbuf) ! { ! /* buffer changed, don't write the file */ ! retval = FAIL; ! goto theend; ! } #endif ! } - if (check_overwrite(eap, curbuf, fname, ffname, other) == OK) retval = buf_write(curbuf, ffname, fname, eap->line1, eap->line2, eap, eap->append, eap->forceit, TRUE, FALSE); theend: #ifdef FEAT_BROWSE --- 2140,2194 ---- } } ! if (check_overwrite(eap, curbuf, fname, ffname, other) == OK) { + if (eap->cmdidx == CMD_saveas && alt_buf != NULL) + { #ifdef FEAT_AUTOCMD ! buf_T *was_curbuf = curbuf; ! apply_autocmds(EVENT_BUFFILEPRE, NULL, NULL, FALSE, curbuf); ! if (curbuf != was_curbuf) ! { ! /* buffer changed, don't change name now */ ! retval = FAIL; ! goto theend; ! } #endif ! /* Exchange the file names for the current and the alternate ! * buffer. This makes it look like we are now editing the buffer ! * under the new name. Must be done before buf_write(), because ! * if there is no file name and 'cpo' contains 'F', it will set ! * the file name. */ ! fname = alt_buf->b_fname; ! alt_buf->b_fname = curbuf->b_fname; ! curbuf->b_fname = fname; ! fname = alt_buf->b_ffname; ! alt_buf->b_ffname = curbuf->b_ffname; ! curbuf->b_ffname = fname; ! fname = alt_buf->b_sfname; ! alt_buf->b_sfname = curbuf->b_sfname; ! curbuf->b_sfname = fname; ! buf_name_changed(); #ifdef FEAT_AUTOCMD ! apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf); ! if (!alt_buf->b_p_bl) ! { ! alt_buf->b_p_bl = TRUE; ! apply_autocmds(EVENT_BUFADD, NULL, NULL, FALSE, alt_buf); ! } ! if (curbuf != was_curbuf) ! { ! /* buffer changed, don't write the file */ ! retval = FAIL; ! goto theend; ! } #endif ! } retval = buf_write(curbuf, ffname, fname, eap->line1, eap->line2, eap, eap->append, eap->forceit, TRUE, FALSE); + } theend: #ifdef FEAT_BROWSE *** ../vim60.95/src/version.c Wed Dec 12 21:05:43 2001 --- src/version.c Wed Dec 12 21:37:50 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 96, /**/ -- hundred-and-one symptoms of being an internet addict: 51. You put a pillow case over your laptop so your lover doesn't see it while you are pretending to catch your breath. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.097 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.097 Problem: Re-indenting in Insert mode with CTRL-F may cause a crash with a multi-byte encoding. Solution: Avoid using a character before the start of a line. (Sergey Vlasov) Files: src/edit.c *** ../vim60.96/src/edit.c Tue Nov 6 21:57:04 2001 --- src/edit.c Thu Dec 13 18:51:50 2001 *************** *** 1510,1516 **** { last_vcol = vcol; #ifdef FEAT_MBYTE ! if (has_mbyte) new_cursor_col += (*mb_ptr2len_check)(ptr + new_cursor_col); else #endif --- 1510,1516 ---- { last_vcol = vcol; #ifdef FEAT_MBYTE ! if (has_mbyte && new_cursor_col >= 0) new_cursor_col += (*mb_ptr2len_check)(ptr + new_cursor_col); else #endif *** ../vim60.96/src/version.c Wed Dec 12 21:42:23 2001 --- src/version.c Thu Dec 13 19:13:10 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 97, /**/ -- hundred-and-one symptoms of being an internet addict: 78. You find yourself dialing IP numbers on the phone. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.098 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.098 Problem: GTK: When using Gnome the "Search" and "Search and Replace" dialog boxes are not translated. Solution: Define ENABLE_NLS before including gnome.h. (Eduardo Fernandez) Files: src/gui_gtk.c, src/gui_gtk_x11.c *** ../vim60.97/src/gui_gtk.c Tue Nov 6 11:58:54 2001 --- src/gui_gtk.c Fri Dec 14 20:09:40 2001 *************** *** 43,48 **** --- 43,51 ---- # ifdef bindtextdomain # undef bindtextdomain # endif + # if defined(FEAT_GETTEXT) && !defined(ENABLE_NLS) + # define ENABLE_NLS /* so the texts in the dialog boxes are translated */ + # endif # include #endif *** ../vim60.97/src/gui_gtk_x11.c Thu Nov 1 14:41:29 2001 --- src/gui_gtk_x11.c Fri Dec 14 20:10:23 2001 *************** *** 31,36 **** --- 31,39 ---- # ifdef bindtextdomain # undef bindtextdomain # endif + # if defined(FEAT_GETTEXT) && !defined(ENABLE_NLS) + # define ENABLE_NLS /* so the texts in the dialog boxes are translated */ + # endif # include # include "version.h" #endif *** ../vim60.97/src/version.c Thu Dec 13 19:15:02 2001 --- src/version.c Fri Dec 14 20:07:55 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 98, /**/ -- hundred-and-one symptoms of being an internet addict: 93. New mail alarm on your palmtop annoys other churchgoers. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.099 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.099 Problem: Cygwin: When running Vi compatible MS-DOS line endings cause trouble. Solution: Make the default for 'fileformats' "unix,dos" in Vi compatible mode. (Michael Schaap) Files: src/option.h *** ../vim60.98/src/option.h Thu Nov 1 12:22:41 2001 --- src/option.h Fri Dec 14 20:23:52 2001 *************** *** 67,74 **** # else # define DFLT_FF "unix" # define DFLT_FFS_VIM "unix,dos" ! # define DFLT_FFS_VI "" ! # define DFLT_TEXTAUTO FALSE # endif #endif --- 67,79 ---- # else # define DFLT_FF "unix" # define DFLT_FFS_VIM "unix,dos" ! # ifdef __CYGWIN__ ! # define DFLT_FFS_VI "unix,dos" /* Cygwin always needs file detection */ ! # define DFLT_TEXTAUTO TRUE ! # else ! # define DFLT_FFS_VI "" ! # define DFLT_TEXTAUTO FALSE ! # endif # endif #endif *** ../vim60.98/src/version.c Fri Dec 14 20:19:45 2001 --- src/version.c Fri Dec 14 20:27:35 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 99, /**/ -- hundred-and-one symptoms of being an internet addict: 95. Only communication in your household is through email. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.100 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.100 Problem: ":badd +0 test%file" causes a crash. Solution: Take into account that the "+0" is NUL terminated when allocating room for replacing the "%". Files: src/ex_docmd.c *** ../vim60.99/src/ex_docmd.c Fri Nov 2 16:29:44 2001 --- src/ex_docmd.c Sat Dec 15 21:34:01 2001 *************** *** 3330,3336 **** /* * Replace part of the command line, keeping eap->cmd, eap->arg and * eap->nextcmd correct. ! * "src" points to the part that is to be replaced, of lenght "srclen". * "repl" is the replacement string. * Returns a pointer to the character after the replaced string. * Returns NULL for failure. --- 3330,3336 ---- /* * Replace part of the command line, keeping eap->cmd, eap->arg and * eap->nextcmd correct. ! * "src" points to the part that is to be replaced, of length "srclen". * "repl" is the replacement string. * Returns a pointer to the character after the replaced string. * Returns NULL for failure. *************** *** 3350,3358 **** /* * The new command line is build in new_cmdline[]. * First allocate it. */ len = (int)STRLEN(repl); ! i = (int)STRLEN(*cmdlinep) + len + 3; if (eap->nextcmd) i += (int)STRLEN(eap->nextcmd);/* add space for next command */ if ((new_cmdline = alloc((unsigned)i)) == NULL) --- 3350,3359 ---- /* * The new command line is build in new_cmdline[]. * First allocate it. + * Careful: a "+cmd" argument may have been NUL terminated. */ len = (int)STRLEN(repl); ! i = (int)(src - *cmdlinep) + (int)STRLEN(src + srclen) + len + 3; if (eap->nextcmd) i += (int)STRLEN(eap->nextcmd);/* add space for next command */ if ((new_cmdline = alloc((unsigned)i)) == NULL) *** ../vim60.99/src/version.c Sat Dec 15 21:39:19 2001 --- src/version.c Sat Dec 15 21:05:08 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 100, /**/ -- hundred-and-one symptoms of being an internet addict: 116. You are living with your boyfriend who networks your respective computers so you can sit in separate rooms and email each other /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.101 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.101 Problem: ":mksession" doesn't restore editing a file that has a '#' or '%' in its name. (Wolfgang Blankenburg) Solution: Put a backslash before the '#' and '%'. Files: src/ex_docmd.c *** ../vim60.100/src/ex_docmd.c Sat Dec 15 21:40:46 2001 --- src/ex_docmd.c Sat Dec 15 21:34:01 2001 *************** *** 8469,8474 **** --- 8469,8476 ---- #ifdef BACKSLASH_IN_FILENAME && c != '\\' #endif + || c == '#' + || c == '%' ) { /* escape a special character with a backslash */ *** ../vim60.100/src/version.c Sat Dec 15 21:40:46 2001 --- src/version.c Sat Dec 15 21:41:44 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 101, /**/ -- hundred-and-one symptoms of being an internet addict: 117. You are more comfortable typing in html. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.102 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.102 Problem: When changing folds the cursor may appear halfway a closed fold. (Nam SungHyun) Solution: Set w_cline_folded correctly. (Yasuhiro Matsumoto) Files: src/move.c *** ../vim60.101/src/move.c Tue Nov 6 21:48:06 2001 --- src/move.c Thu Dec 27 17:19:17 2001 *************** *** 775,781 **** /* a line that is too long to fit on the last screen line */ wp->w_cline_height = 0; #ifdef FEAT_FOLDING ! wp->w_cline_folded = FALSE; #endif } else --- 775,782 ---- /* a line that is too long to fit on the last screen line */ wp->w_cline_height = 0; #ifdef FEAT_FOLDING ! wp->w_cline_folded = hasFoldingWin(wp, wp->w_cursor.lnum, ! NULL, NULL, TRUE, NULL); #endif } else *** ../vim60.101/src/version.c Sat Dec 15 21:56:10 2001 --- src/version.c Sun Dec 30 17:24:29 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 102, /**/ -- Women are probably the main cause of free software starvation. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.103 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.103 Problem: When using 'scrollbind' a large value of 'scrolloff' will make the scroll binding stop near the end of the file. (Coen Engelbarts) Solution: Don't use 'scrolloff' when limiting the topline for scroll binding. (Dany StAmant) Files: src/normal.c *** ../vim60.102/src/normal.c Tue Nov 6 19:38:36 2001 --- src/normal.c Thu Dec 13 10:16:13 2001 *************** *** 3497,3504 **** { curwin->w_scbind_pos += topline_diff; topline = curwin->w_scbind_pos; ! if (topline > curbuf->b_ml.ml_line_count - p_so) ! topline = curbuf->b_ml.ml_line_count - p_so; if (topline < 1) topline = 1; --- 3497,3504 ---- { curwin->w_scbind_pos += topline_diff; topline = curwin->w_scbind_pos; ! if (topline > curbuf->b_ml.ml_line_count) ! topline = curbuf->b_ml.ml_line_count; if (topline < 1) topline = 1; *** ../vim60.102/src/version.c Sun Dec 30 17:25:33 2001 --- src/version.c Sun Dec 30 17:43:11 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 103, /**/ -- This sentence is not sure that it exists, but if it does, it will certainly consider the possibility that other sentences exist. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.104 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.104 Problem: Multi-byte: When '$' is in 'cpoptions', typing a double-wide character that overwrites the left halve of an old double-wide character causes a redraw problem and the cursor stops blinking. Solution: Clear the right half of the old character. (Yasuhiro Matsumoto) Files: src/edit.c, src/screen.c *** ../vim60.103/src/edit.c Thu Dec 13 19:15:02 2001 --- src/edit.c Sun Dec 30 21:00:46 2001 *************** *** 329,334 **** --- 329,340 ---- else State = INSERT; + /* + * Need to recompute the cursor position, it might move when the cursor is + * on a TAB or special character. + */ + curs_columns(TRUE); + if (curbuf->b_p_iminsert == B_IMODE_LMAP) State |= LANGMAP; #ifdef USE_IM_CONTROL *************** *** 338,349 **** #if defined(FEAT_MBYTE) && defined(MACOS) KeyScript(previous_script); #endif - - /* - * Need to recompute the cursor position, it might move when the cursor is - * on a TAB or special character. - */ - curs_columns(TRUE); #ifdef FEAT_MOUSE setmouse(); --- 344,349 ---- *** ../vim60.103/src/screen.c Sun Nov 4 19:10:16 2001 --- src/screen.c Sun Dec 30 21:16:39 2001 *************** *** 4062,4070 **** } /* When writing a single-width character over a double-width * character and at the end of the redrawn text, need to clear out ! * the right halve of the old character. */ ! if (has_mbyte && char_cells == 1 && col + 1 == endcol ! && (*mb_off2cells)(off_to) > 1) clear_next = TRUE; #endif --- 4062,4076 ---- } /* When writing a single-width character over a double-width * character and at the end of the redrawn text, need to clear out ! * the right halve of the old character. ! * Also required when writing the right halve of a double-width ! * char over the left halve of an existing one. */ ! if (has_mbyte && col + char_cells == endcol ! && ((char_cells == 1 ! && (*mb_off2cells)(off_to) > 1) ! || (char_cells == 2 ! && (*mb_off2cells)(off_to) == 1 ! && (*mb_off2cells)(off_to + 1) > 1))) clear_next = TRUE; #endif *************** *** 4355,4361 **** } /* ! * Get the lenght of an item as it will be shown in that status line. */ static int status_match_len(xp, s) --- 4361,4367 ---- } /* ! * Get the lenght of an item as it will be shown in the status line. */ static int status_match_len(xp, s) *************** *** 5106,5114 **** #ifdef FEAT_MBYTE /* When at the end of the text and overwriting a two-cell * character with a one-cell character, need to clear the next ! * cell. */ ! if (has_mbyte && mbyte_cells == 1 && ptr[mbyte_blen] == NUL ! && (*mb_off2cells)(off) > 1) clear_next_cell = TRUE; #endif ScreenLines[off] = *ptr; --- 5112,5124 ---- #ifdef FEAT_MBYTE /* When at the end of the text and overwriting a two-cell * character with a one-cell character, need to clear the next ! * cell. Also when overwriting the left halve of a two-cell ! * char with the right halve of a two-cell char. */ ! if (has_mbyte && ptr[mbyte_blen] == NUL ! && ((mbyte_cells == 1 && (*mb_off2cells)(off) > 1) ! || (mbyte_cells == 2 ! && (*mb_off2cells)(off) == 1 ! && (*mb_off2cells)(off + 1) > 1))) clear_next_cell = TRUE; #endif ScreenLines[off] = *ptr; *** ../vim60.103/src/version.c Sun Dec 30 17:47:16 2001 --- src/version.c Sun Dec 30 21:19:40 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 104, /**/ -- GALAHAD: Camelot ... LAUNCELOT: Camelot ... GAWAIN: It's only a model. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.105 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.105 Problem: Multi-byte: In a window of one column wide, with syntax highlighting enabled a crash might happen. Solution: Skip getting the syntax attribute when the character doesn't fit anyway. (Yasuhiro Matsumoto) Files: src/screen.c *** ../vim60.104/src/screen.c Sun Dec 30 21:23:29 2001 --- src/screen.c Sun Dec 30 21:36:58 2001 *************** *** 3290,3303 **** if (extra_check) { #ifdef FEAT_SYN_HL ! if (has_syntax) { /* Get the syntax attribute for the character. If there * is an error, disable syntax highlighting. */ save_did_emsg = did_emsg; did_emsg = FALSE; - v = (long)(ptr - line); syntax_attr = get_syntax_attr((colnr_T)v - 1); if (did_emsg) --- 3290,3304 ---- if (extra_check) { #ifdef FEAT_SYN_HL ! /* Get syntax attribute, unless still at the start of the line ! * (double-wide char that doesn't fit). */ ! if (has_syntax && (v = (long)(ptr - line)) > 0) { /* Get the syntax attribute for the character. If there * is an error, disable syntax highlighting. */ save_did_emsg = did_emsg; did_emsg = FALSE; syntax_attr = get_syntax_attr((colnr_T)v - 1); if (did_emsg) *** ../vim60.104/src/version.c Sun Dec 30 21:23:29 2001 --- src/version.c Sun Dec 30 21:39:21 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 105, /**/ -- We're knights of the round table We dance whene'er we're able We do routines and chorus scenes With footwork impeccable. We dine well here in Camelot We eat ham and jam and spam a lot. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.106 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.106 (extra) Problem: Win32: When the printer font is wrong, there is no error message. Solution: Give an appropriate error message. (Yasuhiro Matsumoto) Files: src/os_mswin.c *** ../vim60.105/src/os_mswin.c Thu Sep 20 18:14:20 2001 --- src/os_mswin.c Sun Dec 30 21:47:34 2001 *************** *** 1399,1405 **** --- 1399,1409 ---- */ memset(&fLogFont, 0, sizeof(fLogFont)); if (!get_logfont(&fLogFont, p_pfn, prt_dlg.hDC)) + { + EMSG2(_("E448: Unknown font: %s"), p_pfn); + mch_print_cleanup(); return FALSE; + } for (pifBold = 0; pifBold <= 1; pifBold++) for (pifItalic = 0; pifItalic <= 1; pifItalic++) *** ../vim60.105/src/version.c Sun Dec 30 21:41:24 2001 --- src/version.c Sun Dec 30 21:49:55 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 106, /**/ -- We're knights of the Round Table Our shows are formidable But many times We're given rhymes That are quite unsingable We're opera mad in Camelot We sing from the diaphragm a lot. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.107 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.107 (extra) Problem: VisVim: When editing another file, a modified file may be written unexpectedly and without warning. Solution: Split the window if a file was modified. Files: VisVim/Commands.cpp *** ../vim60.106/VisVim/Commands.cpp Mon Jul 23 22:19:17 2001 --- VisVim/Commands.cpp Sun Dec 30 21:58:33 2001 *************** *** 521,528 **** --- 521,533 ---- VimCmd[1] = 0x0e; VimCmdStart = VimCmd + 2; + #ifdef SINGLE_WINDOW // Update the current file in Vim if it has been modified sprintf (VimCmdStart, ":up\n"); + #else + // Split the window if the current file has been modified + sprintf (VimCmdStart, ":if &mod | split | endif\n"); + #endif if (! VimOle.Method (DispatchId, "s", TO_OLE_STR_BUF (VimCmd, Buf))) goto OleError; *** ../vim60.106/src/version.c Sun Dec 30 21:52:17 2001 --- src/version.c Sun Dec 30 22:26:25 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 107, /**/ -- In war we're tough and able. Quite indefatigable Between our quests We sequin vests And impersonate Clark Gable It's a busy life in Camelot. I have to push the pram a lot. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.108 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.108 Problem: When using folding could try displaying line zero, resulting in an error for a NULL pointer. Solution: Stop decrementing w_topline when the first line of a window is in a closed fold. Files: src/window.c *** ../vim60.107/src/window.c Mon Nov 5 09:52:01 2001 --- src/window.c Sun Dec 30 22:23:22 2001 *************** *** 4072,4077 **** --- 4072,4084 ---- { #ifdef FEAT_FOLDING hasFoldingWin(wp, lnum, &lnum, NULL, TRUE, NULL); + if (lnum == 1) + { + /* first line in buffer is folded */ + line_size = 1; + --sline; + break; + } #endif --lnum; #ifdef FEAT_DIFF *** ../vim60.107/src/version.c Sun Dec 30 22:28:38 2001 --- src/version.c Sun Dec 30 22:31:03 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 108, /**/ -- GOD: That is your purpose Arthur ... the Quest for the Holy Grail ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.109 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.109 Problem: XIM: When the input method is enabled, repeating an insertion with "." disables it. (Marcel Svitalsky) Solution: Don't store the input method status when a command comes from the stuff buffer. Files: src/ui.c *** ../vim60.108/src/ui.c Tue Sep 25 19:25:37 2001 --- src/ui.c Mon Dec 31 14:50:37 2001 *************** *** 2753,2760 **** /* Don't save when 'imdisable' is set or "xic" is NULL, IM is always * disabled then (but might start later). * Also don't save when inside a mapping, vgetc_im_active has not been set ! * then. */ ! if (!p_imdisable && KeyTyped # ifdef FEAT_XIM && xic != NULL # endif --- 2753,2761 ---- /* Don't save when 'imdisable' is set or "xic" is NULL, IM is always * disabled then (but might start later). * Also don't save when inside a mapping, vgetc_im_active has not been set ! * then. ! * And don't save when the keys were stuffed (e.g., for a "." command). */ ! if (!p_imdisable && KeyTyped && !KeyStuffed # ifdef FEAT_XIM && xic != NULL # endif *** ../vim60.108/src/version.c Sun Dec 30 22:32:00 2001 --- src/version.c Mon Dec 31 14:54:05 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 109, /**/ -- ARTHUR: (as the MAN next to him is squashed by a sheep) Knights! Run away! Midst echoing shouts of "run away" the KNIGHTS retreat to cover with the odd cow or goose hitting them still. The KNIGHTS crouch down under cover. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.110 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.110 Problem: Using undo after executing "OxjAxkdd" from a register in an empty buffer gives an error message. (Gerhard Hochholzer) Solution: Don't adjust the bottom line number of an undo block when it's zero. Add a test for this problem. Files: src/undo.c, src/testdir/test20.in, src/testdir/test20.ok *** ../vim60.109/src/undo.c Sat Nov 3 14:01:26 2001 --- src/undo.c Mon Dec 31 15:32:57 2001 *************** *** 298,304 **** for (p = curbuf->b_u_newhead->uh_entry; p != uep; p = p->ue_next) { ! p->ue_bot -= uep->ue_bot - newbot; p->ue_top -= uep->ue_bot - newbot; } } --- 298,305 ---- for (p = curbuf->b_u_newhead->uh_entry; p != uep; p = p->ue_next) { ! if (p->ue_bot != 0) ! p->ue_bot -= uep->ue_bot - newbot; p->ue_top -= uep->ue_bot - newbot; } } *** ../vim60.109/src/testdir/test20.in Sun Dec 3 22:01:15 2000 --- src/testdir/test20.in Mon Dec 31 15:29:09 2001 *************** *** 1,9 **** Tests Blockwise Visual when there are TABs before the text. STARTTEST :so tiny.vim ! /start ! jjlld:.,$w! test.out :qa! ENDTEST --- 1,16 ---- Tests Blockwise Visual when there are TABs before the text. + First test for undo working properly when executing commands from a register. + Also test this in an empty buffer. STARTTEST :so tiny.vim ! G0"ay$k@au ! :new ! @auY:quit! ! GP ! /start here$ ! jjlld ! :/here$/,$-1w! test.out :qa! ENDTEST *************** *** 11,13 **** --- 18,22 ---- some text test text test text + + OxjAykdd *** ../vim60.109/src/testdir/test20.ok Sun Aug 1 14:01:14 1999 --- src/testdir/test20.ok Mon Dec 31 15:29:34 2001 *************** *** 2,4 **** --- 2,6 ---- somext tesext test text + + *** ../vim60.109/src/version.c Mon Dec 31 15:35:23 2001 --- src/version.c Mon Dec 31 15:34:29 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 110, /**/ -- A KNIGHT rides into shot and hacks him to the ground. He rides off. We stay for a moment on the glade. A MIDDLE-AGED LADY in a C. & A. twin-set emerges from the trees and looks in horror at the body of her HUSBAND. MRS HISTORIAN: FRANK! "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.111 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.111 Problem: The virtcol() function doesn't take care of 'virtualedit'. Solution: Add the column offset when needed. (Yegappan Lakshmanan) Files: src/eval.c *** ../vim60.110/src/eval.c Sun Nov 4 14:31:23 2001 --- src/eval.c Wed Dec 12 22:01:33 2001 *************** *** 6242,6248 **** fp = var2fpos(&argvars[0], FALSE); if (fp != NULL && fp->lnum <= curbuf->b_ml.ml_line_count) { ! getvcol(curwin, fp, NULL, NULL, &vcol); ++vcol; } --- 6242,6248 ---- fp = var2fpos(&argvars[0], FALSE); if (fp != NULL && fp->lnum <= curbuf->b_ml.ml_line_count) { ! getvvcol(curwin, fp, NULL, NULL, &vcol); ++vcol; } *** ../vim60.110/src/version.c Mon Dec 31 16:32:36 2001 --- src/version.c Mon Dec 31 16:37:06 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 111, /**/ -- Error:015 - Unable to exit Windows. Try the door. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.112 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.112 Problem: The explorer plugin doesn't sort directories with a space or special character after a directory with a shorter name. Solution: Ignore the trailing slash when comparing directory names. (Mike Williams) Files: runtime/plugin/explorer.vim *** ../vim60.111/runtime/plugin/explorer.vim Tue Nov 6 22:02:12 2001 --- runtime/plugin/explorer.vim Wed Nov 7 19:05:46 2001 *************** *** 1024,1030 **** elseif (g:explSuffixesLast != 0) && (f1 !~ b:suffixesRegexp) && (f2 =~ b:suffixesRegexp) return -g:explSuffixesLast else ! return s:StrCmp(f1,f2,a:direction) endif endfunction --- 1024,1030 ---- elseif (g:explSuffixesLast != 0) && (f1 !~ b:suffixesRegexp) && (f2 =~ b:suffixesRegexp) return -g:explSuffixesLast else ! return s:StrCmp(substitute(f1, "/$", "", ""), substitute(f2, "/$", "", ""), a:direction) endif endfunction *************** *** 1054,1060 **** elseif t1 < t2 return a:direction else ! return s:StrCmp(f1,f2,1) endif endfunction --- 1054,1060 ---- elseif t1 < t2 return a:direction else ! return s:StrCmp(substitute(f1, "/$", "", ""), substitute(f2, "/$", "", ""), 1) endif endfunction *************** *** 1082,1088 **** elseif s1 < s2 return a:direction else ! return s:StrCmp(f1,f2,1) endif endfunction --- 1082,1088 ---- elseif s1 < s2 return a:direction else ! return s:StrCmp(substitute(f1, "/$", "", ""), substitute(f2, "/$", "", ""), 1) endif endfunction *** ../vim60.111/src/version.c Mon Dec 31 16:39:26 2001 --- src/version.c Mon Dec 31 16:46:48 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 112, /**/ -- press CTRL-ALT-DEL for more information /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.113 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.113 Problem: ":edit ~/fname" doesn't work if $HOME includes a space. Also, expanding wildcards with the shell may fail. (John Daniel) Solution: Escape spaces with a backslash when needed. Files: src/ex_docmd.c, src/misc1.c, src/proto/misc1.pro, src/os_unix.c *** ../vim60.112/src/ex_docmd.c Sat Dec 15 21:56:10 2001 --- src/ex_docmd.c Mon Dec 31 17:28:09 2001 *************** *** 3297,3303 **** if (vim_strchr(eap->arg, '$') != NULL || vim_strchr(eap->arg, '~') != NULL) { ! expand_env(eap->arg, NameBuff, MAXPATHL); has_wildcards = mch_has_wildcard(NameBuff); p = NameBuff; } --- 3297,3303 ---- if (vim_strchr(eap->arg, '$') != NULL || vim_strchr(eap->arg, '~') != NULL) { ! expand_env_esc(eap->arg, NameBuff, MAXPATHL, TRUE); has_wildcards = mch_has_wildcard(NameBuff); p = NameBuff; } *** ../vim60.112/src/misc1.c Tue Nov 6 19:43:29 2001 --- src/misc1.c Mon Dec 31 17:46:07 2001 *************** *** 2834,2839 **** --- 2834,2849 ---- char_u *dst; /* where to put the result */ int dstlen; /* maximum length of the result */ { + expand_env_esc(src, dst, dstlen, FALSE); + } + + void + expand_env_esc(src, dst, dstlen, esc) + char_u *src; /* input string e.g. "$HOME/vim.hlp" */ + char_u *dst; /* where to put the result */ + int dstlen; /* maximum length of the result */ + int esc; /* escape spaces in expanded variables */ + { char_u *tail; int c; char_u *var; *************** *** 2999,3004 **** --- 3009,3029 ---- var = NULL; tail = (char_u *)""; /* for gcc */ #endif /* UNIX || VMS */ + } + + /* If "var" contains white space, escape it with a backslash. + * Required for ":e ~/tt" $HOME includes a space. */ + if (esc && var != NULL && vim_strpbrk(var, (char_u *)" \t") != NULL) + { + char_u *p = vim_strsave_escaped(var, (char_u *)" \t"); + + if (p != NULL) + { + if (mustfree) + vim_free(var); + var = p; + mustfree = TRUE; + } } if (var != NULL && *var != NUL *** ../vim60.112/src/proto/misc1.pro Tue Sep 25 21:49:20 2001 --- src/proto/misc1.pro Mon Dec 31 17:26:25 2001 *************** *** 46,51 **** --- 46,52 ---- void vim_beep __ARGS((void)); void init_homedir __ARGS((void)); void expand_env __ARGS((char_u *src, char_u *dst, int dstlen)); + void expand_env_esc __ARGS((char_u *src, char_u *dst, int dstlen, int esc)); char_u *vim_getenv __ARGS((char_u *name, int *mustfree)); char_u *expand_env_save __ARGS((char_u *src)); void vim_setenv __ARGS((char_u *name, char_u *val)); *** ../vim60.112/src/os_unix.c Wed Oct 31 14:21:02 2001 --- src/os_unix.c Mon Dec 31 17:41:29 2001 *************** *** 4277,4289 **** if (shell_style != STYLE_BT) for (i = 0; i < num_pat; ++i) { ! #ifdef USE_SYSTEM ! STRCAT(command, " \""); /* need extra quotes because we */ ! STRCAT(command, pat[i]); /* start the shell twice */ ! STRCAT(command, "\""); ! #else ! STRCAT(command, " "); ! STRCAT(command, pat[i]); #endif } if (flags & EW_SILENT) --- 4277,4299 ---- if (shell_style != STYLE_BT) for (i = 0; i < num_pat; ++i) { ! /* When using system() always add extra quotes, because the shell ! * is started twice. Otherwise it's only needed when the pattern ! * includes spaces or single quotes. */ ! #ifndef USE_SYSTEM ! if (vim_strpbrk(pat[i], " '") != NULL) ! #endif ! { ! STRCAT(command, " \""); ! STRCAT(command, pat[i]); ! STRCAT(command, "\""); ! } ! #ifndef USE_SYSTEM ! else ! { ! STRCAT(command, " "); ! STRCAT(command, pat[i]); ! } #endif } if (flags & EW_SILENT) *** ../vim60.112/src/version.c Mon Dec 31 16:49:06 2001 --- src/version.c Mon Dec 31 17:43:12 2001 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 113, /**/ -- Microsoft: "Windows NT 4.0 now has the same user-interface as Windows 95" Windows 95: "Press CTRL-ALT-DEL to reboot" Windows NT 4.0: "Press CTRL-ALT-DEL to login" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.114 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.114 Problem: Using ":p" with fnamemodify() didn't expand "~/" or "~user/" to a full path. For Win32 the current directory was prepended. (Michael Geddes) Solution: Expand the home directory. Files: src/eval.c *** ../vim60.113/src/eval.c Mon Dec 31 16:39:26 2001 --- src/eval.c Tue Jan 1 15:09:37 2002 *************** *** 8564,8571 **** { valid |= VALID_PATH; *usedlen += 2; /* FullName_save() is slow, don't use it when not needed. */ ! if (!vim_isAbsName(*fnamep)) { *fnamep = FullName_save(*fnamep, FALSE); vim_free(*bufp); /* free any allocated file name */ --- 8564,8590 ---- { valid |= VALID_PATH; *usedlen += 2; + + /* Expand "~/path" for all systems and "~user/path" for Unix and VMS */ + if ((*fnamep)[0] == '~' + #if !defined(UNIX) && !(defined(VMS) && defined(USER_HOME)) + && ((*fnamep)[1] == '/' + # ifdef BACKSLASH_IN_FILENAME + || (*fnamep)[1] == '\\' + # endif + || (*fnamep)[1] == NUL) + + #endif + ) + { + *fnamep = expand_env_save(*fnamep); + vim_free(*bufp); /* free any allocated file name */ + *bufp = *fnamep; + if (*fnamep == NULL) + return -1; + } /* FullName_save() is slow, don't use it when not needed. */ ! else if (!vim_isAbsName(*fnamep)) { *fnamep = FullName_save(*fnamep, FALSE); vim_free(*bufp); /* free any allocated file name */ *** ../vim60.113/src/version.c Mon Dec 31 17:47:49 2001 --- src/version.c Tue Jan 1 15:14:01 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 114, /**/ -- Microsoft's definition of a boolean: TRUE, FALSE, MAYBE "Embrace and extend"...? /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.115 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.115 (extra) Problem: Win32: When using a dialog with a textfield it cannot scroll the text. Solution: Add ES_AUTOHSCROLL to the textfield style. (Pedro Gomes) Files: src/gui_w32.c *** ../vim60.114/src/gui_w32.c Wed Sep 19 14:43:49 2001 --- src/gui_w32.c Tue Jan 1 19:23:08 2002 *************** *** 2626,2632 **** /* Edit box */ if (textfield != NULL) { ! p = add_dialog_element(p, ES_LEFT | WS_TABSTOP | WS_BORDER, PixelToDialogX(2 * dlgPaddingX), PixelToDialogY(2 * dlgPaddingY + msgheight), PixelToDialogX(dlgwidth - 4 * dlgPaddingX), --- 2626,2632 ---- /* Edit box */ if (textfield != NULL) { ! p = add_dialog_element(p, ES_LEFT|ES_AUTOHSCROLL|WS_TABSTOP|WS_BORDER, PixelToDialogX(2 * dlgPaddingX), PixelToDialogY(2 * dlgPaddingY + msgheight), PixelToDialogX(dlgwidth - 4 * dlgPaddingX), *** ../vim60.114/src/version.c Tue Jan 1 15:16:42 2002 --- src/version.c Tue Jan 1 19:24:13 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 115, /**/ -- When danger reared its ugly head, He bravely turned his tail and fled Yes, Brave Sir Robin turned about And gallantly he chickened out Bravely taking to his feet He beat a very brave retreat Bravest of the brave Sir Robin Petrified of being dead Soiled his pants then brave Sir Robin Turned away and fled. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.116 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.116 (extra) Problem: MS-Windows NT/2000/XP: filewritable() doesn't work correctly for filesystems that use ACLs. Solution: Use ACL functions to check if a file is writable. (Mike Williams) Files: src/eval.c, src/macros.h, src/os_win32.c, src/proto/os_win32.pro *** ../vim60.115/src/eval.c Tue Jan 1 15:16:42 2002 --- src/eval.c Tue Jan 1 20:50:07 2002 *************** *** 3412,3432 **** #endif p = get_var_string(&argvars[0]); ! #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ ! #ifdef WIN3264 ! if (mch_writable(p)) ! #else ! # ifdef UNIX perm = mch_getperm(p); ! # endif if ( ! # ifdef UNIX ! (perm & 0222) && # endif ! mch_access((char *)p, W_OK) == 0 ) #endif - #endif { ++retval; if (mch_isdir(p)) --- 3412,3432 ---- #endif p = get_var_string(&argvars[0]); ! #ifdef UNIX perm = mch_getperm(p); ! #endif ! #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ if ( ! # ifdef WIN3264 ! mch_writable(p) ! # else ! # ifdef UNIX ! (perm & 0222) ! # endif # endif ! && mch_access((char *)p, W_OK) == 0 ) #endif { ++retval; if (mch_isdir(p)) *** ../vim60.115/src/macros.h Sat Jul 28 22:50:57 2001 --- src/macros.h Tue Jan 1 20:52:19 2002 *************** *** 136,142 **** /* VMS does not have lstat() */ # define mch_stat(n, p) stat(vms_fixfilename(n), (p)) #else ! # define mch_access(n, p) access((n), (p)) # define mch_fopen(n, p) fopen((n), (p)) # define mch_fstat(n, p) fstat((n), (p)) # define mch_lstat(n, p) lstat((n), (p)) --- 136,144 ---- /* VMS does not have lstat() */ # define mch_stat(n, p) stat(vms_fixfilename(n), (p)) #else ! # ifndef WIN32 ! # define mch_access(n, p) access((n), (p)) ! # endif # define mch_fopen(n, p) fopen((n), (p)) # define mch_fstat(n, p) fstat((n), (p)) # define mch_lstat(n, p) lstat((n), (p)) *** ../vim60.115/src/os_win32.c Sun Nov 4 14:31:23 2001 --- src/os_win32.c Tue Jan 1 21:06:01 2002 *************** *** 90,103 **** --- 90,109 ---- */ #ifdef PROTO # define HANDLE int + # define PHANDLE int # define SMALL_RECT int # define COORD int # define SHORT int # define WORD int # define DWORD int + # define PDWORD int # define BOOL int + # define LPBOOL int # define LPSTR int # define LPTSTR int + # define LPCTSTR int + # define LPDWORD int + # define LPVOID int # define KEY_EVENT_RECORD int # define MOUSE_EVENT_RECORD int # define WINAPI *************** *** 119,124 **** --- 125,133 ---- # define COLORREF int # define HDC int # define LOGFONT int + # define TOKEN_INFORMATION_CLASS int + # define TRUSTEE int + # define ACCESS_MASK int #endif #ifndef FEAT_GUI_W32 *************** *** 317,322 **** --- 326,332 ---- DWORD g_PlatformId; #ifdef HAVE_ACL + # include /* * These are needed to dynamically load the ADVAPI DLL, which is not * implemented under Windows 95 (and causes VIM to crash) *************** *** 326,334 **** --- 336,358 ---- typedef DWORD (WINAPI *PGNSECINFO) (LPSTR, enum SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID *, PSID *, PACL *, PACL *, PSECURITY_DESCRIPTOR *); + typedef BOOL (WINAPI *PGFILESEC) (LPCTSTR, SECURITY_INFORMATION, + PSECURITY_DESCRIPTOR, DWORD, LPDWORD); + typedef BOOL (WINAPI *PGSECDESCDACL) (PSECURITY_DESCRIPTOR, + LPBOOL, PACL *, LPBOOL); + typedef BOOL (WINAPI *POPENPROCTOK) (HANDLE, DWORD, PHANDLE); + typedef BOOL (WINAPI *PGTOKINFO) (HANDLE, TOKEN_INFORMATION_CLASS, + LPVOID, DWORD, PDWORD); + typedef DWORD (WINAPI *PGEFFRIGHTACL) (PACL, TRUSTEE *, ACCESS_MASK *); + static HANDLE advapi_lib = NULL; /* Handle for ADVAPI library */ static PSNSECINFO pSetNamedSecurityInfo; static PGNSECINFO pGetNamedSecurityInfo; + static PGFILESEC pGetFileSecurity; + static PGSECDESCDACL pGetSecurityDescriptorDacl; + static POPENPROCTOK pOpenProcessToken; + static PGTOKINFO pGetTokenInformation; + static PGEFFRIGHTACL pGetEffectiveRightsFromAcl; #endif /* *************** *** 370,377 **** "SetNamedSecurityInfoA"); pGetNamedSecurityInfo = (PGNSECINFO)GetProcAddress(advapi_lib, "GetNamedSecurityInfoA"); if (pSetNamedSecurityInfo == NULL ! || pGetNamedSecurityInfo == NULL) { /* If we can't get the function addresses, set advapi_lib * to NULL so that we don't use them. */ --- 394,415 ---- "SetNamedSecurityInfoA"); pGetNamedSecurityInfo = (PGNSECINFO)GetProcAddress(advapi_lib, "GetNamedSecurityInfoA"); + pGetFileSecurity = (PGFILESEC)GetProcAddress(advapi_lib, + "GetFileSecurityA"); + pGetSecurityDescriptorDacl = (PGSECDESCDACL)GetProcAddress(advapi_lib, + "GetSecurityDescriptorDacl"); + pOpenProcessToken = (POPENPROCTOK)GetProcAddress(advapi_lib, + "OpenProcessToken"); + pGetTokenInformation = (PGTOKINFO)GetProcAddress(advapi_lib, + "GetTokenInformation"); + pGetEffectiveRightsFromAcl = (PGEFFRIGHTACL)GetProcAddress(advapi_lib, + "GetEffectiveRightsFromAclA"); if (pSetNamedSecurityInfo == NULL ! || pGetNamedSecurityInfo == NULL ! || pGetFileSecurity == NULL ! || pGetSecurityDescriptorDacl == NULL ! || pOpenProcessToken == NULL ! || pGetTokenInformation == NULL) { /* If we can't get the function addresses, set advapi_lib * to NULL so that we don't use them. */ *************** *** 2368,2375 **** } #ifdef HAVE_ACL - # include - struct my_acl { PSECURITY_DESCRIPTOR pSecurityDescriptor; --- 2406,2411 ---- *************** *** 4000,4003 **** --- 4036,4134 ---- psz = "command.com"; return psz; + } + + /* NB: Not SACL_SECURITY_INFORMATION since we don't have enough privilege */ + #define MCH_ACCESS_SEC (OWNER_SECURITY_INFORMATION \ + |GROUP_SECURITY_INFORMATION \ + |DACL_SECURITY_INFORMATION) + + /* + * mch_access() extends access() to support ACLs under Windows NT/2K/XP(?) + * Does not support ACLs on NT 3.1/5 since the key function + * GetEffectiveRightsFromAcl() does not exist and implementing its + * functionality is a pain. + * Written by Mike Williams. + * Returns 0 if file "n" has access rights according to "p", -1 otherwise. + */ + int + mch_access(char *n, int p) + { + BOOL aclpresent; + BOOL aclDefault; + HANDLE hToken; + DWORD bytes; + TRUSTEE t; + ACCESS_MASK am; + ACCESS_MASK cm; + PACL pacl; + static DWORD sd_bytes = 0; + static SECURITY_DESCRIPTOR* psd = NULL; + static DWORD tu_bytes = 0; + static TOKEN_USER* ptu = NULL; + + #ifdef HAVE_ACL + /* Only check ACLs if on WinNT 4.0 or later - GetEffectiveRightsFromAcl() + * does not exist on NT before 4.0 */ + if (!mch_windows95() + && advapi_lib != NULL + && pGetEffectiveRightsFromAcl != NULL) + { + /* Get file ACL info */ + if (!pGetFileSecurity(n, MCH_ACCESS_SEC, psd, sd_bytes, &bytes)) + { + if (GetLastError() != ERROR_INSUFFICIENT_BUFFER) + return -1; + vim_free(psd); + psd = (SECURITY_DESCRIPTOR *)alloc(bytes); + if (psd == NULL) + { + sd_bytes = 0; + return -1; + } + sd_bytes = bytes; + if (!pGetFileSecurity(n, MCH_ACCESS_SEC, psd, sd_bytes, &bytes)) + return -1; + } + if (!pGetSecurityDescriptorDacl(psd, &aclpresent, &pacl, &aclDefault)) + return -1; + + /* Get user security info */ + if (!pOpenProcessToken(GetCurrentProcess(), TOKEN_QUERY, &hToken)) + return -1; + if (!pGetTokenInformation(hToken, TokenUser, ptu, tu_bytes, &bytes)) + { + if (GetLastError() != ERROR_INSUFFICIENT_BUFFER) + return -1; + vim_free(ptu); + ptu = (TOKEN_USER *)alloc(bytes); + if (ptu == NULL) + { + tu_bytes = 0; + return -1; + } + tu_bytes = bytes; + if (!pGetTokenInformation(hToken, TokenUser, ptu, tu_bytes, &bytes)) + return -1; + } + + /* Lets see what user can do based on ACL */ + t.pMultipleTrustee = NULL; + t.MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE; + t.TrusteeForm = TRUSTEE_IS_SID; + t.TrusteeType = TRUSTEE_IS_USER; + t.ptstrName = ptu->User.Sid; + if (pGetEffectiveRightsFromAcl(pacl, &t, &am) != ERROR_SUCCESS) + return -1; + + cm = 0; + cm |= (p & W_OK) ? FILE_WRITE_DATA : 0; + cm |= (p & R_OK) ? FILE_READ_DATA : 0; + + /* Check access mask against modes requested */ + if ((am & cm) != cm) + return -1; + } + #endif /* HAVE_ACL */ + return access(n, p); } *** ../vim60.115/src/proto/os_win32.pro Tue Sep 25 21:49:34 2001 --- src/proto/os_win32.pro Tue Jan 1 21:03:23 2002 *************** *** 42,45 **** --- 42,46 ---- long_u mch_avail_mem __ARGS((int special)); int mch_rename __ARGS((const char *pszOldFile, const char *pszNewFile)); char *default_shell __ARGS((void)); + int mch_access __ARGS((char *n, int p)); /* vim: set ft=c : */ *** ../vim60.115/src/version.c Tue Jan 1 20:29:44 2002 --- src/version.c Tue Jan 1 21:07:53 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 116, /**/ -- ZOOT: I'm afraid our life must seem very dull and quiet compared to yours. We are but eightscore young blondes, all between sixteen and nineteen-and-a-half, cut off in this castle, with no one to protect us. Oooh. It is a lonely life ... bathing ... dressing ... undressing ... making exciting underwear.... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.117 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.117 (extra) Problem: Win32: when disabling the menu, "set lines=999" doesn't use all the available screen space. Solution: Don't subtract the fixed caption height but the real menu height from the available screen space. Also: Avoid recursion in gui_mswin_get_menu_height(). Files: src/gui_w32.c, src/gui_w48.c *** ../vim60.116/src/gui_w32.c Tue Jan 1 20:29:44 2002 --- src/gui_w32.c Tue Jan 1 22:24:54 2002 *************** *** 330,338 **** } if (fix_window && menu_height != old_menu_height) gui_set_shellsize(FALSE, FALSE); - old_menu_height = menu_height; return menu_height; } #endif /*FEAT_MENU*/ --- 330,340 ---- } if (fix_window && menu_height != old_menu_height) + { + old_menu_height = menu_height; gui_set_shellsize(FALSE, FALSE); + } return menu_height; } #endif /*FEAT_MENU*/ *** ../vim60.116/src/gui_w48.c Wed Sep 19 19:37:40 2001 --- src/gui_w48.c Tue Jan 1 22:59:35 2002 *************** *** 2368,2376 **** *screen_w = GetSystemMetrics(SM_CXSCREEN) - GetSystemMetrics(SM_CXFRAME) * 2; *screen_h = GetSystemMetrics(SM_CYFULLSCREEN) - GetSystemMetrics(SM_CYFRAME) * 2 ! - GetSystemMetrics(SM_CYCAPTION); } void --- 2368,2382 ---- *screen_w = GetSystemMetrics(SM_CXSCREEN) - GetSystemMetrics(SM_CXFRAME) * 2; + /* FIXME: dirty trick: Because the gui_get_base_height() doesn't include + * the menubar for MSwin, we subtract it from the screen height, so that + * the window size can be made to fit on the screen. */ *screen_h = GetSystemMetrics(SM_CYFULLSCREEN) - GetSystemMetrics(SM_CYFRAME) * 2 ! #ifdef FEAT_MENU ! - gui_mswin_get_menu_height(FALSE) ! #endif ! ; } void *** ../vim60.116/src/version.c Tue Jan 1 21:13:14 2002 --- src/version.c Tue Jan 1 23:05:01 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 117, /**/ -- GALAHAD hurries to the door and pushes through it. As he leaves the room we CUT TO the reverse to show that he is now in a room full of bathing and romping GIRLIES, all innocent, wide-eyed and beautiful. They smile enchantingly at him as he tries to keep walking without being diverted by the lovely sights assaulting his eyeballs. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.118 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.118 Problem: When $TMPDIR is a relative path, the temp directory is missing a trailing slash and isn't deleted when Vim exits. (Peter Holm) Solution: Add the slash after expanding the directory to an absolute path. Files: src/fileio.c *** ../vim60.117/src/fileio.c Mon Nov 5 21:01:58 2001 --- src/fileio.c Wed Jan 2 17:03:40 2002 *************** *** 5371,5386 **** #endif if (r == 0) { ! /* Directory was created, use this name. */ # ifdef __EMX__ ! if (vim_strchr(itmp, '/') != NULL) ! STRCAT(itmp, "/"); ! else # endif ! add_pathsep(itmp); ! /* Use the full path; When using the current directory ! * a ":cd" would confuse us. */ ! vim_tempdir = FullName_save(itmp, FALSE); break; } # ifdef EEXIST --- 5371,5396 ---- #endif if (r == 0) { ! char_u *buf; ! ! /* Directory was created, use this name. ! * Expand to full path; When using the current ! * directory a ":cd" would confuse us. */ ! buf = alloc((unsigned)MAXPATHL + 1); ! if (buf != NULL) ! { ! if (vim_FullName(itmp, buf, MAXPATHL, FALSE) ! == FAIL) ! STRCPY(buf, itmp); # ifdef __EMX__ ! if (vim_strchr(buf, '/') != NULL) ! STRCAT(buf, "/"); ! else # endif ! add_pathsep(buf); ! vim_tempdir = vim_strsave(buf); ! vim_free(buf); ! } break; } # ifdef EEXIST *** ../vim60.117/src/version.c Tue Jan 1 23:08:31 2002 --- src/version.c Wed Jan 2 17:07:07 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 118, /**/ -- "My particular problem is with registry entries, which seem to just accumulate like plastic coffee cups..." -- Paul Moore /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.119 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.119 (depends on patch 6.0.116) Problem: VMS: filewritable() doesn't work properly. Solution: Use the same method as for Unix. (Zoltan Arpadffy) Files: src/eval.c *** ../vim60.118/src/eval.c Tue Jan 1 21:13:14 2002 --- src/eval.c Mon Jan 7 14:04:48 2002 *************** *** 3407,3418 **** { char_u *p; int retval = 0; ! #ifdef UNIX int perm = 0; #endif p = get_var_string(&argvars[0]); ! #ifdef UNIX perm = mch_getperm(p); #endif #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ --- 3407,3418 ---- { char_u *p; int retval = 0; ! #if defined(UNIX) || defined(VMS) int perm = 0; #endif p = get_var_string(&argvars[0]); ! #if defined(UNIX) || defined(VMS) perm = mch_getperm(p); #endif #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ *************** *** 3420,3426 **** # ifdef WIN3264 mch_writable(p) # else ! # ifdef UNIX (perm & 0222) # endif # endif --- 3420,3426 ---- # ifdef WIN3264 mch_writable(p) # else ! # if defined(UNIX) || defined(VMS) (perm & 0222) # endif # endif *** ../vim60.118/src/version.c Wed Jan 2 17:10:11 2002 --- src/version.c Mon Jan 7 14:04:55 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 119, /**/ -- [Autumn changed into Winter ... Winter changed into Spring ... Spring changed back into Autumn and Autumn gave Winter and Spring a miss and went straight on into Summer ... Until one day ...] "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.120 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.120 Problem: The conversion to html isn't compatible with XHTML. Solution: Quote the values. (Jess Thrysoee) Files: runtime/syntax/2html.vim *** ../vim60.119/runtime/syntax/2html.vim Sun Sep 2 14:43:04 2001 --- runtime/syntax/2html.vim Mon Jan 7 22:24:33 2002 *************** *** 1,6 **** " Vim syntax support file " Maintainer: Bram Moolenaar ! " Last Change: 2001 Sep 02 " (modified by David Ne\v{c}as (Yeti) ) " Transform a file into HTML, using the current syntax highlighting. --- 1,6 ---- " Vim syntax support file " Maintainer: Bram Moolenaar ! " Last Change: 2001 Dec 12 " (modified by David Ne\v{c}as (Yeti) ) " Transform a file into HTML, using the current syntax highlighting. *************** *** 71,77 **** let x = s:HtmlColor(synIDattr(a:id, "fg#", s:whatterm)) let a = a . '' let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm)) ! let a = a . '' else let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm)) if x != "" | let a = a . '' | endif --- 71,77 ---- let x = s:HtmlColor(synIDattr(a:id, "fg#", s:whatterm)) let a = a . '' let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm)) ! let a = a . '' else let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm)) if x != "" | let a = a . '' | endif *************** *** 184,190 **** let s:new = "" if s:numblines ! let s:new = '' . strpart(' ', 0, strlen(line("$")) - strlen(s:lnum)) . s:lnum . ' ' endif " Loop over each character in the line --- 184,190 ---- let s:new = "" if s:numblines ! let s:new = '' . strpart(' ', 0, strlen(line("$")) - strlen(s:lnum)) . s:lnum . ' ' endif " Loop over each character in the line *************** *** 199,205 **** " Output the text with the same synID, with class set to c{s:id} let s:id = synIDtrans(s:id) ! let s:new = s:new . '' . substitute(substitute(substitute(substitute(substitute(strpart(s:line, s:startcol - 1, s:col - s:startcol), '&', '\&', 'g'), '<', '\<', 'g'), '>', '\>', 'g'), '"', '\"', 'g'), "\x0c", '
', 'g') . '
' " Add the class to class list if it's not there yet if stridx(s:idlist, "," . s:id . ",") == -1 let s:idlist = s:idlist . s:id . "," --- 199,205 ---- " Output the text with the same synID, with class set to c{s:id} let s:id = synIDtrans(s:id) ! let s:new = s:new . '' . substitute(substitute(substitute(substitute(substitute(strpart(s:line, s:startcol - 1, s:col - s:startcol), '&', '\&', 'g'), '<', '\<', 'g'), '>', '\>', 'g'), '"', '\"', 'g'), "\x0c", '
', 'g') . '
' " Add the class to class list if it's not there yet if stridx(s:idlist, "," . s:id . ",") == -1 let s:idlist = s:idlist . s:id . "," *************** *** 252,258 **** if exists("html_use_css") execute "normal A\n.lnr { " . s:CSS1(highlightID("LineNr")) . "}\e" else ! execute '%s+\([^<]*\)+' . s:HtmlOpening(highlightID("LineNr")) . '\1' . s:HtmlClosing(highlightID("LineNr")) . '+g' endif endif --- 252,258 ---- if exists("html_use_css") execute "normal A\n.lnr { " . s:CSS1(highlightID("LineNr")) . "}\e" else ! execute '%s+\([^<]*\)+' . s:HtmlOpening(highlightID("LineNr")) . '\1' . s:HtmlClosing(highlightID("LineNr")) . '+g' endif endif *************** *** 270,279 **** if exists("html_use_css") execute "normal A\n.c" . s:id . " { " . s:attr . "}" else ! execute '%s+\([^<]*\)+' . s:HtmlOpening(s:id) . '\1' . s:HtmlClosing(s:id) . '+g' endif else ! execute '%s+\([^<]*\)+\1+g' 8 endif endwhile --- 270,279 ---- if exists("html_use_css") execute "normal A\n.c" . s:id . " { " . s:attr . "}" else ! execute '%s+\([^<]*\)+' . s:HtmlOpening(s:id) . '\1' . s:HtmlClosing(s:id) . '+g' endif else ! execute '%s+\([^<]*\)+\1+g' 8 endif endwhile *** ../vim60.119/src/version.c Mon Jan 7 14:08:11 2002 --- src/version.c Mon Jan 7 22:30:22 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 120, /**/ -- BEDEVERE: Look! It's the old man from scene 24 - what's he Doing here? ARTHUR: He is the keeper of the Bridge. He asks each traveler five questions ... GALAHAD: Three questions. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.121 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.121 (extra) (depends on patch 6.0.116) Problem: Win32: After patch 6.0.116 Vim doesn't compile with mingw32. Solution: Add an #ifdef HAVE_ACL. Files: src/os_win32.c *** ../vim60.120/src/os_win32.c Tue Jan 1 21:13:14 2002 --- src/os_win32.c Sat Jan 5 13:29:06 2002 *************** *** 4058,4064 **** --- 4058,4066 ---- BOOL aclDefault; HANDLE hToken; DWORD bytes; + #ifdef HAVE_ACL TRUSTEE t; + #endif ACCESS_MASK am; ACCESS_MASK cm; PACL pacl; *** ../vim60.120/src/version.c Mon Jan 7 22:34:19 2002 --- src/version.c Wed Jan 9 10:01:38 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 121, /**/ -- Snoring is prohibited unless all bedroom windows are closed and securely locked. [real standing law in Massachusetts, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.122 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.122 (extra) Problem: Win16: Same resize problems as patch 6.0.117 fixed for Win32. And dialog textfield problem from patch 6.0.115. Solution: Set old_menu_height only when used. Add ES_AUTOHSCROLL flag. (Vince Negri) Files: src/gui_w16.c *** ../vim60.121/src/gui_w16.c Wed Sep 19 14:44:12 2001 --- src/gui_w16.c Wed Jan 9 16:17:08 2002 *************** *** 123,131 **** } if (fix_window && menu_height != old_menu_height) gui_set_shellsize(FALSE, FALSE); - old_menu_height = menu_height; return menu_height; } #endif /*FEAT_MENU*/ --- 123,133 ---- } if (fix_window && menu_height != old_menu_height) + { + old_menu_height = menu_height; gui_set_shellsize(FALSE, FALSE); + } return menu_height; } #endif /*FEAT_MENU*/ *************** *** 1481,1487 **** /* Edit box */ if (textfield != NULL) { ! p = add_dialog_element(p, ES_LEFT | WS_TABSTOP | WS_BORDER, PixelToDialogX(2 * dlgPaddingX), PixelToDialogY(2 * dlgPaddingY + msgheight), PixelToDialogX(dlgwidth - 4 * dlgPaddingX), --- 1483,1489 ---- /* Edit box */ if (textfield != NULL) { ! p = add_dialog_element(p, ES_LEFT | ES_AUTOHSCROLL | WS_TABSTOP | WS_BORDER, PixelToDialogX(2 * dlgPaddingX), PixelToDialogY(2 * dlgPaddingY + msgheight), PixelToDialogX(dlgwidth - 4 * dlgPaddingX), *** ../vim60.121/src/version.c Wed Jan 9 16:08:19 2002 --- src/version.c Wed Jan 9 16:18:48 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 122, /**/ -- It is illegal to take more than three sips of beer at a time while standing. [real standing law in Texas, United States of America] /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.123 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.123 (depends on patch 6.0.119) Problem: Win16: Compilation problems. Solution: Move "&&" to other lines. (Vince Negri) Files: src/eval.c *** ../vim60.122/src/eval.c Mon Jan 7 14:08:11 2002 --- src/eval.c Wed Jan 9 16:18:38 2002 *************** *** 3418,3430 **** #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ if ( # ifdef WIN3264 ! mch_writable(p) # else # if defined(UNIX) || defined(VMS) ! (perm & 0222) # endif # endif ! && mch_access((char *)p, W_OK) == 0 ) #endif { --- 3418,3430 ---- #ifndef MACOS_CLASSIC /* TODO: get either mch_writable or mch_access */ if ( # ifdef WIN3264 ! mch_writable(p) && # else # if defined(UNIX) || defined(VMS) ! (perm & 0222) && # endif # endif ! mch_access((char *)p, W_OK) == 0 ) #endif { *** ../vim60.122/src/version.c Wed Jan 9 16:23:13 2002 --- src/version.c Wed Jan 9 16:23:31 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 123, /**/ -- "Software is like sex... it's better when it's free." -- Linus Torvalds, initiator of the free Linux OS Makes me wonder what FSF stands for...? /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.124 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.124 Problem: When using a ":substitute" command that starts with "\=" (evaluated as an expression), "~" was still replaced with the previous substitute string. Solution: Skip the replacement when the substitute string starts with "\=". Also adjust the documentation about doubling backslashes. Files: src/ex_cmds.c, runtime/doc/change.txt *** ../vim60.123/src/ex_cmds.c Wed Dec 12 21:42:23 2001 --- src/ex_cmds.c Thu Jan 10 19:27:31 2002 *************** *** 3548,3555 **** /* * ~ in the substitute pattern is replaced with the old pattern. * We do it here once to avoid it to be replaced over and over again. */ ! sub = regtilde(sub, p_magic); /* * Check for a match on each line. --- 3548,3557 ---- /* * ~ in the substitute pattern is replaced with the old pattern. * We do it here once to avoid it to be replaced over and over again. + * But don't do it when it starts with "\=", then it's an expression. */ ! if (!(sub[0] == '\\' && sub[1] == '=')) ! sub = regtilde(sub, p_magic); /* * Check for a match on each line. *** ../vim60.123/runtime/doc/change.txt Tue Sep 25 21:40:33 2001 --- runtime/doc/change.txt Thu Jan 10 19:37:10 2002 *************** *** 1,4 **** ! *change.txt* For Vim version 6.0. Last change: 2001 Sep 11 VIM REFERENCE MANUAL by Bram Moolenaar --- 1,4 ---- ! *change.txt* For Vim version 6.0. Last change: 2002 Jan 10 VIM REFERENCE MANUAL by Bram Moolenaar *************** *** 640,651 **** *sub-replace-special* When the {string} starts with "\=" it is evaluated as an expression. The ! special meaning for characters as mentioned below does not apply then. ! The whole matched text can be accessed with "submatch(0)". The text matched ! with the first pair of () with "submatch(1)". Likewise for further sub-matches in (). ! Be careful: The separation character must not appear in the expression! ! Consider using a character like "@" or "|". Example: > :s@\n@\="\r" . expand("$HOME") . "\r"@ This replaces an end-of-line with a new line containing the value of $HOME. --- 640,655 ---- *sub-replace-special* When the {string} starts with "\=" it is evaluated as an expression. The ! special meaning for characters as mentioned below does not apply then, except ! "", "\" and "\\". Thus in the result of the expression you need to ! use two backslashes get one, put a backslash before a you want to insert ! and use a without a backslash where you want to break the line. ! The whole matched text can be accessed with "submatch(0)". The text ! matched with the first pair of () with "submatch(1)". Likewise for further sub-matches in (). ! Be careful: The separation character must not appear in the expression! ! Consider using a character like "@" or "|". There is no problem if the result ! of the expression contains the separation character. Example: > :s@\n@\="\r" . expand("$HOME") . "\r"@ This replaces an end-of-line with a new line containing the value of $HOME. *************** *** 663,671 **** ~ \~ replaced with the {string} of the previous substitute \~ ~ replaced with ~ \u next character made uppercase ! \U following characters made uppercase \l next character made lowercase ! \L following characters made lowercase \e end of \u, \U, \l and \L (NOTE: not !) \E end of \u, \U, \l and \L split line in two at this point (Type the as CTRL-V --- 667,675 ---- ~ \~ replaced with the {string} of the previous substitute \~ ~ replaced with ~ \u next character made uppercase ! \U following characters made uppercase, until \E \l next character made lowercase ! \L following characters made lowercase, until \E \e end of \u, \U, \l and \L (NOTE: not !) \E end of \u, \U, \l and \L split line in two at this point (Type the as CTRL-V *** ../vim60.123/src/version.c Wed Jan 9 16:29:27 2002 --- src/version.c Thu Jan 10 19:38:14 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 124, /**/ -- A M00se once bit my sister ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.125 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.125 (extra) Problem: Win32: When using the multi_byte_ime feature pressing the shift key would be handled as if a character was entered, thus mappings with a shifted key didn't work. (Charles Campbell) Solution: Ignore pressing the shift, control and alt keys. Files: src/os_win32.c *** ../vim60.124/src/os_win32.c Wed Jan 9 16:08:19 2002 --- src/os_win32.c Thu Jan 10 21:12:05 2002 *************** *** 1157,1180 **** if (cRecords > 0) { - #ifdef FEAT_MBYTE_IME - /* Windows IME sends two '\n's with only one 'ENTER'. - first, wVirtualKeyCode == 13. second, wVirtualKeyCode == 0 */ if (ir.EventType == KEY_EVENT && ir.Event.KeyEvent.bKeyDown) { if (ir.Event.KeyEvent.uChar.UnicodeChar == 0 && ir.Event.KeyEvent.wVirtualKeyCode == 13) { ReadConsoleInput(g_hConIn, &ir, 1, &cRecords); continue; } - return decode_key_event(&ir.Event.KeyEvent, &ch, &ch2, FALSE); - } - #else - if (ir.EventType == KEY_EVENT && ir.Event.KeyEvent.bKeyDown - && decode_key_event(&ir.Event.KeyEvent, &ch, &ch2, FALSE)) - return TRUE; #endif ReadConsoleInput(g_hConIn, &ir, 1, &cRecords); --- 1157,1177 ---- if (cRecords > 0) { if (ir.EventType == KEY_EVENT && ir.Event.KeyEvent.bKeyDown) { + #ifdef FEAT_MBYTE_IME + /* Windows IME sends two '\n's with only one 'ENTER'. First: + * wVirtualKeyCode == 13. second: wVirtualKeyCode == 0 */ if (ir.Event.KeyEvent.uChar.UnicodeChar == 0 && ir.Event.KeyEvent.wVirtualKeyCode == 13) { ReadConsoleInput(g_hConIn, &ir, 1, &cRecords); continue; } #endif + if (decode_key_event(&ir.Event.KeyEvent, &ch, &ch2, FALSE)) + return TRUE; + } ReadConsoleInput(g_hConIn, &ir, 1, &cRecords); *** ../vim60.124/src/version.c Thu Jan 10 20:17:24 2002 --- src/version.c Thu Jan 10 21:14:22 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 125, /**/ -- Mynd you, m00se bites Kan be pretty nasti ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.126 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.126 Problem: The python library was always statically linked. Solution: Link the python library dynamically. (Matthias Klose) Files: src/auto/configure, src/configure.in *** ../vim60.125/src/configure.in Thu Nov 1 12:22:41 2001 --- src/configure.in Fri Jan 11 12:39:19 2002 *************** *** 332,338 **** if test "${vi_cv_var_python_version}" = "1.4"; then vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libModules.a ${PYTHON_CONFDIR}/libPython.a ${PYTHON_CONFDIR}/libObjects.a ${PYTHON_CONFDIR}/libParser.a" else ! vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libpython${vi_cv_var_python_version}.a" fi vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" dnl remove -ltermcap, it can conflict with an earlier -lncurses --- 336,342 ---- if test "${vi_cv_var_python_version}" = "1.4"; then vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libModules.a ${PYTHON_CONFDIR}/libPython.a ${PYTHON_CONFDIR}/libObjects.a ${PYTHON_CONFDIR}/libParser.a" else ! vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" dnl remove -ltermcap, it can conflict with an earlier -lncurses *** ../vim60.125/src/auto/configure Thu Nov 1 12:22:41 2001 --- src/auto/configure Fri Jan 11 12:39:44 2002 *************** *** 1586,1592 **** if test "${vi_cv_var_python_version}" = "1.4"; then vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libModules.a ${PYTHON_CONFDIR}/libPython.a ${PYTHON_CONFDIR}/libObjects.a ${PYTHON_CONFDIR}/libParser.a" else ! vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libpython${vi_cv_var_python_version}.a" fi vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` --- 1590,1596 ---- if test "${vi_cv_var_python_version}" = "1.4"; then vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libModules.a ${PYTHON_CONFDIR}/libPython.a ${PYTHON_CONFDIR}/libObjects.a ${PYTHON_CONFDIR}/libParser.a" else ! vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` *** ../vim60.125/src/version.c Thu Jan 10 21:23:57 2002 --- src/version.c Fri Jan 11 13:00:42 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 126, /**/ -- If you don't get everything you want, think of everything you didn't get and don't want. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.127 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.127 Problem: When using a terminal that swaps screens and the Normal background color has a different background, using an external command may cause the color of the wrong screen to be changed. (Mark Waggoner) Solution: Don't call screen_stop_highlight() in stoptermcap(). Files: src/term.c *** ../vim60.126/src/term.c Sun Nov 4 18:45:17 2001 --- src/term.c Fri Jan 11 20:49:29 2002 *************** *** 3132,3138 **** void starttermcap() { - screen_stop_highlight(); if (full_screen && !termcap_active) { out_str(T_TI); /* start termcap mode */ --- 3132,3137 ---- *** ../vim60.126/src/version.c Fri Jan 11 13:03:17 2002 --- src/version.c Fri Jan 11 20:49:38 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 127, /**/ -- ARTHUR: ... and I am your king .... OLD WOMAN: Ooooh! I didn't know we had a king. I thought we were an autonomous collective ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.128 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.128 Problem: When moving a vertically split window to the far left or right, the scrollbars are not adjusted. (Scott E Lee) When 'mousefocus' is set the mouse pointer wasn't adjusted. Solution: Adjust the scrollbars and the mouse pointer. Files: src/window.c *** ../vim60.127/src/window.c Sun Dec 30 22:32:00 2001 --- src/window.c Sat Jan 12 16:15:08 2002 *************** *** 1422,1430 **** #if defined(FEAT_GUI) && defined(FEAT_VERTSPLIT) /* When 'guioptions' includes 'L' or 'R' may have to remove or add ! * scrollbars. */ if (gui.in_use) gui_init_which_components(NULL); #endif } --- 1422,1434 ---- #if defined(FEAT_GUI) && defined(FEAT_VERTSPLIT) /* When 'guioptions' includes 'L' or 'R' may have to remove or add ! * scrollbars. Have to update them anyway. */ if (gui.in_use) + { gui_init_which_components(NULL); + gui_update_scrollbars(TRUE); + } + need_mouse_correct = TRUE; #endif } *** ../vim60.127/src/version.c Fri Jan 11 20:54:04 2002 --- src/version.c Sat Jan 12 16:17:09 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 128, /**/ -- ARTHUR: What are you going to do. bleed on me? "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.129 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.129 Problem: When using a very long file name, ":ls" (repeated a few times) causes a crash. Test with "vim `perl -e 'print "A"x1000'`". (Tejeda) Solution: Terminate a string before getting its length in buflist_list(). Files: src/buffer.c *** ../vim60.128/src/buffer.c Wed Sep 19 12:37:17 2001 --- src/buffer.c Sat Jan 12 16:35:12 2002 *************** *** 2091,2096 **** --- 2091,2097 ---- len = (int)STRLEN(IObuff); STRNCPY(IObuff + len, NameBuff, IOSIZE - 20 - len); + IObuff[IOSIZE - 20 - len] = NUL; /* make sure it's terminated */ len = (int)STRLEN(IObuff); IObuff[len++] = '"'; *** ../vim60.128/src/version.c Sat Jan 12 16:22:05 2002 --- src/version.c Sat Jan 12 16:39:02 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 129, /**/ -- BLACK KNIGHT: I'm invincible! ARTHUR: You're a looney. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.130 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.130 Problem: When using ":cprev" while the error window is open, and the new line at the top wraps, the window isn't correctly drawn. (Yegappan Lakshmanan) Solution: When redrawing the topline don't scroll twice. Files: src/screen.c *** ../vim60.129/src/screen.c Sun Dec 30 21:41:24 2001 --- src/screen.c Sun Jan 13 20:33:11 2002 *************** *** 944,950 **** #endif ) { ! if (buf->b_mod_set && wp->w_topline == mod_top) { /* * w_topline is the first changed line, the scrolling will be done --- 944,950 ---- #endif ) { ! if (mod_top != 0 && wp->w_topline == mod_top) { /* * w_topline is the first changed line, the scrolling will be done *** ../vim60.129/src/version.c Sat Jan 12 16:39:27 2002 --- src/version.c Sun Jan 13 20:38:54 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 130, /**/ -- It is too bad that the speed of light hasn't kept pace with the changes in CPU speed and network bandwidth. -- /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.131 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.131 Problem: When using bufname() and there are two matches for listed buffers and one match for an unlisted buffer, the unlisted buffer is used. (Aric Blumer) Solution: When there is a match with a listed buffer, don't check for unlisted buffers. Files: src/buffer.c *** ../vim60.130/src/buffer.c Sat Jan 12 16:39:27 2002 --- src/buffer.c Mon Jan 14 12:43:09 2002 *************** *** 1636,1646 **** } /* ! * Try four ways of matching: * attempt == 0: without '^' or '$' (at any position) * attempt == 1: with '^' at start (only at postion 0) * attempt == 2: with '$' at end (only match at end) * attempt == 3: with '^' at start and '$' at end (only full match) */ else { --- 1636,1648 ---- } /* ! * Try four ways of matching a listed buffer: * attempt == 0: without '^' or '$' (at any position) * attempt == 1: with '^' at start (only at postion 0) * attempt == 2: with '$' at end (only match at end) * attempt == 3: with '^' at start and '$' at end (only full match) + * Repeat this for finding an unlisted buffer if there was no matching + * listed buffer. */ else { *************** *** 1650,1675 **** patend = pat + STRLEN(pat) - 1; toggledollar = (patend > pat && *patend == '$'); ! for (attempt = 0; attempt <= 3; ++attempt) { ! /* may add '^' and '$' */ ! if (toggledollar) ! *patend = (attempt < 2) ? NUL : '$'; /* add/remove '$' */ ! p = pat; ! if (*p == '^' && !(attempt & 1)) /* add/remove '^' */ ! ++p; ! prog = vim_regcomp(p, (int)p_magic); ! if (prog == NULL) { ! vim_free(pat); ! return -1; ! } - /* First try finding a listed buffer, if not found and "unlisted" - * is TRUE, try finding an unlisted buffer. */ - find_listed = TRUE; - for (;;) - { for (buf = firstbuf; buf != NULL; buf = buf->b_next) if (buf->b_p_bl == find_listed #ifdef FEAT_DIFF --- 1652,1677 ---- patend = pat + STRLEN(pat) - 1; toggledollar = (patend > pat && *patend == '$'); ! /* First try finding a listed buffer. If not found and "unlisted" ! * is TRUE, try finding an unlisted buffer. */ ! find_listed = TRUE; ! for (;;) { ! for (attempt = 0; attempt <= 3; ++attempt) { ! /* may add '^' and '$' */ ! if (toggledollar) ! *patend = (attempt < 2) ? NUL : '$'; /* add/remove '$' */ ! p = pat; ! if (*p == '^' && !(attempt & 1)) /* add/remove '^' */ ! ++p; ! prog = vim_regcomp(p, (int)p_magic); ! if (prog == NULL) ! { ! vim_free(pat); ! return -1; ! } for (buf = firstbuf; buf != NULL; buf = buf->b_next) if (buf->b_p_bl == find_listed #ifdef FEAT_DIFF *************** *** 1684,1698 **** } match = buf->b_fnum; /* remember first match */ } ! if (!unlisted || !find_listed || match >= 0) break; - find_listed = FALSE; } ! vim_free(prog); ! if (match >= 0) /* found one match */ break; } vim_free(pat); } --- 1686,1704 ---- } match = buf->b_fnum; /* remember first match */ } ! ! vim_free(prog); ! if (match >= 0) /* found one match */ break; } ! /* Only search for unlisted buffers if there was no match with ! * a listed buffer. */ ! if (!unlisted || !find_listed || match != -1) break; + find_listed = FALSE; } + vim_free(pat); } *** ../vim60.130/src/version.c Sun Jan 13 20:44:03 2002 --- src/version.c Mon Jan 14 12:46:18 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 131, /**/ -- Are leaders born or made? And if they're made, can we return them under warranty? (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.132 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.132 Problem: When setting 'iminsert' in the vimrc and using an xterm with two screens the ruler is drawn in the wrong screen. (Igor Goldenberg) Solution: Only draw the ruler when using the right screen. Files: src/option.c *** ../vim60.131/src/option.c Mon Nov 5 12:51:06 2001 --- src/option.c Tue Jan 15 13:53:02 2002 *************** *** 6021,6027 **** curbuf->b_p_iminsert = B_IMODE_NONE; } p_iminsert = curbuf->b_p_iminsert; ! showmode(); #if defined(FEAT_WINDOWS) && defined(FEAT_KEYMAP) /* Show/unshow value of 'keymap' in status lines. */ status_redraw_curbuf(); --- 6021,6028 ---- curbuf->b_p_iminsert = B_IMODE_NONE; } p_iminsert = curbuf->b_p_iminsert; ! if (termcap_active) /* don't do this in the alternate screen */ ! showmode(); #if defined(FEAT_WINDOWS) && defined(FEAT_KEYMAP) /* Show/unshow value of 'keymap' in status lines. */ status_redraw_curbuf(); *** ../vim60.131/src/version.c Mon Jan 14 12:49:05 2002 --- src/version.c Tue Jan 15 13:54:57 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 132, /**/ -- Engineers are widely recognized as superior marriage material: intelligent, dependable, employed, honest, and handy around the house. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.133 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.133 Problem: When opening another buffer while 'keymap' is set and 'iminsert' is zero, 'iminsert' is set to one unexpectedly. (Igor Goldenberg) Solution: Don't set 'iminsert' as a side effect of defining a ":lmap" mapping. Only do that when 'keymap' is set. Files: src/getchar.c, src/option.c *** ../vim60.132/src/getchar.c Fri Nov 2 16:29:44 2001 --- src/getchar.c Tue Jan 15 14:13:21 2002 *************** *** 2916,2934 **** if (!haskey || (maptype != 1 && !hasarg)) msg_start(); - /* When definding a ":lmap" switch on using them. */ - if (hasarg && maptype != 1 && mode == LANGMAP) - { - curbuf->b_p_iminsert = B_IMODE_LMAP; - if (curbuf->b_p_imsearch != B_IMODE_USE_INSERT) - curbuf->b_p_imsearch = B_IMODE_LMAP; - set_iminsert_global(); - set_imsearch_global(); - #ifdef FEAT_WINDOWS - status_redraw_curbuf(); - #endif - } - #ifdef FEAT_LOCALMAP /* * Check if a new local mapping wasn't already defined globally. --- 2916,2921 ---- *** ../vim60.132/src/option.c Tue Jan 15 13:56:47 2002 --- src/option.c Tue Jan 15 14:24:07 2002 *************** *** 4503,4508 **** --- 4503,4521 ---- { /* load or unload key mapping tables */ errmsg = keymap_init(); + + /* When successfully installed a new keymap switch on using it. */ + if (*curbuf->b_p_keymap != NUL && errmsg == NULL) + { + curbuf->b_p_iminsert = B_IMODE_LMAP; + if (curbuf->b_p_imsearch != B_IMODE_USE_INSERT) + curbuf->b_p_imsearch = B_IMODE_LMAP; + set_iminsert_global(); + set_imsearch_global(); + # ifdef FEAT_WINDOWS + status_redraw_curbuf(); + # endif + } } #endif *** ../vim60.132/src/version.c Tue Jan 15 13:56:47 2002 --- src/version.c Tue Jan 15 14:19:25 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 133, /**/ -- An alien life briefly visits earth. Just before departing it leaves a message in the dust on the back of a white van. The world is shocked and wants to know what it means. After months of studies the worlds best linguistic scientists are able to decipher the message: "Wash me!". /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.134 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.134 Problem: When completing ":set tags=" a path with an embedded space causes the completion to stop. (Sektor van Skijlen) Solution: Escape spaces with backslashes, like for ":set path=". Also take backslashes into account when searching for the start of the path to complete (e.g., for 'backupdir' and 'cscopeprg'). Files: src/ex_docmd.c, src/ex_getln.c, src/option.c, src/structs.h *** ../vim60.133/src/ex_docmd.c Mon Dec 31 17:47:49 2001 --- src/ex_docmd.c Wed Jan 2 13:08:49 2002 *************** *** 2153,2159 **** xp->xp_pattern = buff; xp->xp_context = EXPAND_COMMANDS; /* Default until we get past command */ ! xp->xp_set_path = FALSE; /* * 2. skip comment lines and leading space, colons or bars --- 2153,2159 ---- xp->xp_pattern = buff; xp->xp_context = EXPAND_COMMANDS; /* Default until we get past command */ ! xp->xp_backslash = XP_BS_NONE; /* * 2. skip comment lines and leading space, colons or bars *** ../vim60.133/src/ex_getln.c Wed Oct 31 20:51:33 2001 --- src/ex_getln.c Wed Jan 2 13:22:16 2002 *************** *** 2605,2611 **** for (i = 0; i < numfiles; ++i) { /* for ":set path=" we need to escape spaces twice */ ! if (xp->xp_set_path) { p = vim_strsave_escaped(files[i], (char_u *)" "); if (p != NULL) --- 2605,2611 ---- for (i = 0; i < numfiles; ++i) { /* for ":set path=" we need to escape spaces twice */ ! if (xp->xp_backslash == XP_BS_THREE) { p = vim_strsave_escaped(files[i], (char_u *)" "); if (p != NULL) *************** *** 2643,2649 **** } } } ! xp->xp_set_path = FALSE; } else if (xp->xp_context == EXPAND_TAGS) { --- 2643,2649 ---- } } } ! xp->xp_backslash = XP_BS_NONE; } else if (xp->xp_context == EXPAND_TAGS) { *************** *** 3103,3138 **** if (options & WILD_SILENT) flags |= EW_SILENT; ! if (xp->xp_context == EXPAND_FILES) { /* ! * Expand file names. ! */ ! return expand_wildcards(1, &pat, num_file, file, flags|EW_FILE); ! } ! else if (xp->xp_context == EXPAND_DIRECTORIES) ! { ! /* ! * Expand directory names. */ int free_pat = FALSE; int i; ! /* for ":set path=" we need to remove backslashes for escaped space */ ! if (xp->xp_set_path) { free_pat = TRUE; pat = vim_strsave(pat); for (i = 0; pat[i]; ++i) ! if (pat[i] == '\\' ! && pat[i + 1] == '\\' ! && pat[i + 2] == '\\' ! && pat[i + 3] == ' ') ! STRCPY(pat + i, pat + i + 3); } ! ret = expand_wildcards(1, &pat, num_file, file, ! (flags | EW_DIR) & ~EW_FILE); if (free_pat) vim_free(pat); return ret; --- 3103,3141 ---- if (options & WILD_SILENT) flags |= EW_SILENT; ! if (xp->xp_context == EXPAND_FILES || xp->xp_context == EXPAND_DIRECTORIES) { /* ! * Expand file or directory names. */ int free_pat = FALSE; int i; ! /* for ":set path=" and ":set tags=" halve backslashes for escaped ! * space */ ! if (xp->xp_backslash != XP_BS_NONE) { free_pat = TRUE; pat = vim_strsave(pat); for (i = 0; pat[i]; ++i) ! if (pat[i] == '\\') ! { ! if (xp->xp_backslash == XP_BS_THREE ! && pat[i + 1] == '\\' ! && pat[i + 2] == '\\' ! && pat[i + 3] == ' ') ! STRCPY(pat + i, pat + i + 3); ! if (xp->xp_backslash == XP_BS_ONE ! && pat[i + 1] == ' ') ! STRCPY(pat + i, pat + i + 1); ! } } ! if (xp->xp_context == EXPAND_FILES) ! flags |= EW_FILE; ! else ! flags = (flags | EW_DIR) & ~EW_FILE; ! ret = expand_wildcards(1, &pat, num_file, file, flags); if (free_pat) vim_free(pat); return ret; *** ../vim60.133/src/option.c Tue Jan 15 14:28:35 2002 --- src/option.c Tue Jan 15 14:24:07 2002 *************** *** 7603,7609 **** int opt_idx = 0; /* init for GCC */ char_u *p; char_u *s; - char_u *after_blank = NULL; int is_term_option = FALSE; int key; --- 7603,7608 ---- *************** *** 7636,7646 **** ++p; break; } - /* remember possible start of file name to expand */ - if (after_blank == NULL - && ((*p == ' ' && (p - s) < 2) - || (*p == ',' && p == s))) - after_blank = p + 1; --p; } if (STRNCMP(p, "no", 2) == 0) --- 7635,7640 ---- *************** *** 7733,7742 **** xp->xp_context = EXPAND_NOTHING; if (is_term_option || (flags & P_NUM)) return; ! if (after_blank != NULL) ! xp->xp_pattern = after_blank; ! else ! xp->xp_pattern = p + 1; if (flags & P_EXPAND) { p = options[opt_idx].var; --- 7727,7735 ---- xp->xp_context = EXPAND_NOTHING; if (is_term_option || (flags & P_NUM)) return; ! ! xp->xp_pattern = p + 1; ! if (flags & P_EXPAND) { p = options[opt_idx].var; *************** *** 7758,7768 **** || p == (char_u *)&p_cdpath #endif ) ! xp->xp_set_path = TRUE; } else xp->xp_context = EXPAND_FILES; } return; } --- 7751,7790 ---- || p == (char_u *)&p_cdpath #endif ) ! xp->xp_backslash = XP_BS_THREE; ! else ! xp->xp_backslash = XP_BS_ONE; } else + { xp->xp_context = EXPAND_FILES; + /* for 'tags' need three backslashes for a space */ + if (p == (char_u *)&p_tags) + xp->xp_backslash = XP_BS_THREE; + else + xp->xp_backslash = XP_BS_ONE; + } + } + + /* For an option that is a list of file names, find the start of the + * last file name. */ + for (p = arg + STRLEN(arg) - 1; p > xp->xp_pattern; --p) + { + /* count number of backslashes before ' ' or ',' */ + if (*p == ' ' || *p == ',') + { + s = p; + while (s > xp->xp_pattern && *(s - 1) == '\\') + --s; + if ((*p == ' ' && (xp->xp_backslash == XP_BS_THREE && (p - s) < 3)) + || (*p == ',' && (flags & P_COMMA) && ((p - s) & 1) == 0)) + { + xp->xp_pattern = p + 1; + break; + } + } } + return; } *** ../vim60.133/src/structs.h Fri Nov 2 16:29:44 2001 --- src/structs.h Wed Jan 2 13:16:36 2002 *************** *** 364,371 **** { int xp_context; /* type of expansion */ char_u *xp_pattern; /* start of item to expand */ ! int xp_set_path; /* ":set path=/dir/" */ } expand_T; /* * Command modifiers ":vertical", ":browse", ":confirm" and ":hide" set a flag. --- 364,376 ---- { int xp_context; /* type of expansion */ char_u *xp_pattern; /* start of item to expand */ ! int xp_backslash; /* one of the XP_BS_ values */ } expand_T; + + /* values for xp_backslash */ + #define XP_BS_NONE 0 /* nothing special for backslashes */ + #define XP_BS_ONE 1 /* uses one backslash before a space */ + #define XP_BS_THREE 2 /* uses three backslashes before a space */ /* * Command modifiers ":vertical", ":browse", ":confirm" and ":hide" set a flag. *** ../vim60.133/src/version.c Tue Jan 15 14:28:35 2002 --- src/version.c Tue Jan 15 14:30:42 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 134, /**/ -- Every engineer dreams about saving the universe and having sex with aliens. This is much more glamorous than the real life of an engineer, which consists of hiding from the universe and having sex without the participation of other life forms. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.135 (long) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.135 Problem: Menus that are not supposed to do anything used "", which still produced an error beep. When CTRL-O is mapped for Insert mode, ":amenu" commands didn't work in Insert mode. Menu language falls back to English when $LANG ends in "@euro". Solution: Use "" for a menu item that doesn't do anything, just like mappings. Use ":anoremenu" instead of ":amenu". Ignore "@euro" in the locale name. Files: runtime/makemenu.vim, runtime/menu.vim, src/menu.c *** ../vim60.134/runtime/makemenu.vim Mon Sep 24 11:44:52 2001 --- runtime/makemenu.vim Tue Jan 15 15:30:35 2002 *************** *** 1,6 **** " Script to define the syntax menu in menu.vim " Maintainer: Bram Moolenaar ! " Last Change: 2001 Sep 24 " This is used by "make menu" in the src directory. edit :p:h/menu.vim --- 1,6 ---- " Script to define the syntax menu in menu.vim " Maintainer: Bram Moolenaar ! " Last Change: 2002 Jan 15 " This is used by "make menu" in the src directory. edit :p:h/menu.vim *************** *** 38,49 **** " When starting a new letter, insert a menu separator. let c = submenu_name[0] if c != s:cur_menu_char ! exe 'am 50.' . s:cur_menu_nr . '.' . s:cur_menu_item . ' &Syntax.' . menu_name . ".-" . c . '- ' let s:cur_menu_item = s:cur_menu_item + 10 let s:cur_menu_char = c endif endif ! call append(s:lnum, 'am 50.' . s:cur_menu_nr . '.' . s:cur_menu_item . ' &Syntax.' . menu_name . "." . submenu_name . ' :cal SetSyn("' . syntax_name . '")') let s:cur_menu_item = s:cur_menu_item + 10 let s:lnum = s:lnum + 1 endfun --- 38,49 ---- " When starting a new letter, insert a menu separator. let c = submenu_name[0] if c != s:cur_menu_char ! exe 'an 50.' . s:cur_menu_nr . '.' . s:cur_menu_item . ' &Syntax.' . menu_name . ".-" . c . '- ' let s:cur_menu_item = s:cur_menu_item + 10 let s:cur_menu_char = c endif endif ! call append(s:lnum, 'an 50.' . s:cur_menu_nr . '.' . s:cur_menu_item . ' &Syntax.' . menu_name . "." . submenu_name . ' :cal SetSyn("' . syntax_name . '")') let s:cur_menu_item = s:cur_menu_item + 10 let s:lnum = s:lnum + 1 endfun *************** *** 55,60 **** --- 55,61 ---- SynMenu AB.Aflex:aflex SynMenu AB.AHDL:ahdl SynMenu AB.Amiga\ DOS:amiga + SynMenu AB.Ant:ant SynMenu AB.Antlr:antlr SynMenu AB.Apache\ config:apache SynMenu AB.Apache-style\ config:apachestyle *************** *** 78,83 **** --- 79,85 ---- SynMenu AB.Awk:awk SynMenu AB.Ayacc:ayacc SynMenu AB.B:b + SynMenu AB.Baan:baan SynMenu AB.BASIC:basic SynMenu AB.BC\ calculator:bc SynMenu AB.BDF\ font:bdf *************** *** 149,156 **** SynMenu EFG.GNUplot:gnuplot SynMenu EFG.GTKrc:gtkrc ! SynMenu HIJK.Haskell:haskell ! SynMenu HIJK.Haskell-literate:lhaskell SynMenu HIJK.Hercules:hercules SynMenu HIJK.HTML:html SynMenu HIJK.HTML\ with\ M4:htmlm4 --- 151,159 ---- SynMenu EFG.GNUplot:gnuplot SynMenu EFG.GTKrc:gtkrc ! SynMenu HIJK.Haskell.Haskell:haskell ! SynMenu HIJK.Haskell.Haskell-c2hs:chaskell ! SynMenu HIJK.Haskell.Haskell-literate:lhaskell SynMenu HIJK.Hercules:hercules SynMenu HIJK.HTML:html SynMenu HIJK.HTML\ with\ M4:htmlm4 *************** *** 187,192 **** --- 190,196 ---- SynMenu L-Ma.Lisp:lisp SynMenu L-Ma.Lite:lite SynMenu L-Ma.LOTOS:lotos + SynMenu L-Ma.LotusScript:lscript SynMenu L-Ma.Lout:lout SynMenu L-Ma.Lua:lua SynMenu L-Ma.Lynx\ Style:lss *************** *** 210,215 **** --- 214,220 ---- SynMenu Me-NO.Modsim\ III:modsim3 SynMenu Me-NO.Modula\ 2:modula2 SynMenu Me-NO.Modula\ 3:modula3 + SynMenu Me-NO.MOO:moo SynMenu Me-NO.Msql:msql SynMenu Me-NO.MS-DOS.MS-DOS\ \.bat\ file:dosbatch SynMenu Me-NO.MS-DOS.4DOS\ \.bat\ file:btm *************** *** 246,251 **** --- 251,257 ---- SynMenu PQ.PO\ (GNU\ gettext):po SynMenu PQ.Postfix\ main\ config:pfmain SynMenu PQ.PostScript:postscr + SynMenu PQ.PostScript\ Printer\ Description:ppd SynMenu PQ.Povray:pov SynMenu PQ.Povray\ configuration:povini SynMenu PQ.Printcap:pcap *************** *** 306,311 **** --- 312,318 ---- SynMenu Sh-S.Specman:specman SynMenu Sh-S.Spice:spice SynMenu Sh-S.Speedup:spup + SynMenu Sh-S.Splint:splint SynMenu Sh-S.Squid:squid SynMenu Sh-S.SQL:sql SynMenu Sh-S.SQL\ Forms:sqlforms *************** *** 354,365 **** --- 361,374 ---- SynMenu WXYZ.Whitespace\ (add):whitespace SynMenu WXYZ.WinBatch/Webbatch:winbatch SynMenu WXYZ.Windows\ Scripting\ Host:wsh + SynMenu WXYZ.WvDial:wvdial SynMenu WXYZ.X\ Keyboard\ Extension:xkb SynMenu WXYZ.X\ Pixmap:xpm SynMenu WXYZ.X\ Pixmap\ (2):xpm2 SynMenu WXYZ.X\ resources:xdefaults SynMenu WXYZ.Xmath:xmath SynMenu WXYZ.XML:xml + SynMenu WXYZ.Xslt:xslt SynMenu WXYZ.XXD\ hex\ dump:xxd SynMenu WXYZ.Yacc:yacc SynMenu WXYZ.Zsh\ shell\ script:zsh *** ../vim60.134/runtime/menu.vim Thu Nov 1 15:22:32 2001 --- runtime/menu.vim Tue Jan 15 16:17:03 2002 *************** *** 1,8 **** " You can also use this as a start for your own set of menus. - " Note that ":amenu" is often used to make a menu work in all modes. " " Maintainer: Bram Moolenaar ! " Last Change: 2001 Oct 25 " Make sure the '<' and 'C' flags are not included in 'cpoptions', otherwise " would not be recognized. See ":help 'cpoptions'". --- 1,11 ---- + " Vim support file to define the default menus " You can also use this as a start for your own set of menus. " " Maintainer: Bram Moolenaar ! " Last Change: 2002 Jan 15 ! ! " Note that ":an" (short for ":anoremenu") is often used to make a menu work ! " in all modes and avoid side effects from mappings defined by the user. " Make sure the '<' and 'C' flags are not included in 'cpoptions', otherwise " would not be recognized. See ":help 'cpoptions'". *************** *** 32,37 **** --- 35,42 ---- " Change spaces to underscores. let s:lang = substitute(tolower(s:lang), "\\.iso-", "\\.iso_", "") let s:lang = substitute(s:lang, " ", "_", "g") + " Remove "@euro", otherwise "LC_ALL=de_DE@euro gvim" will show English menus + let s:lang = substitute(s:lang, "@euro", "", "") menutrans clear exe "runtime! lang/menu_" . s:lang . ".vim" *************** *** 51,67 **** " Help menu ! amenu 9999.10 &Help.&Overview :help ! amenu 9999.20 &Help.&User\ Manual :help usr_toc ! amenu 9999.30 &Help.&How-to\ links :help how-to ! amenu 9999.40 &Help.&Find\.\.\. :call Helpfind() ! amenu 9999.45 &Help.-sep1- ! amenu 9999.50 &Help.&Credits :help credits ! amenu 9999.60 &Help.Co&pying :help copying ! amenu 9999.70 &Help.O&rphans :help iccf ! amenu 9999.75 &Help.-sep2- ! amenu 9999.80 &Help.&Version :version ! amenu 9999.90 &Help.&About :intro fun! s:Helpfind() if !exists("g:menutrans_help_dialog") --- 56,72 ---- " Help menu ! an 9999.10 &Help.&Overview :help ! an 9999.20 &Help.&User\ Manual :help usr_toc ! an 9999.30 &Help.&How-to\ links :help how-to ! an 9999.40 &Help.&Find\.\.\. :call Helpfind() ! an 9999.45 &Help.-sep1- ! an 9999.50 &Help.&Credits :help credits ! an 9999.60 &Help.Co&pying :help copying ! an 9999.70 &Help.O&rphans :help kcc ! an 9999.75 &Help.-sep2- ! an 9999.80 &Help.&Version :version ! an 9999.90 &Help.&About :intro fun! s:Helpfind() if !exists("g:menutrans_help_dialog") *************** *** 78,116 **** endfun " File menu ! amenu 10.310 &File.&Open\.\.\.:e :browse confirm e ! amenu 10.320 &File.Sp&lit-Open\.\.\.:sp :browse sp ! amenu 10.325 &File.&New:enew :confirm enew ! amenu 10.330 &File.&Close:close \ :if winheight(2) < 0 \ confirm enew \ else \ confirm close \ endif ! amenu 10.335 &File.-SEP1- : ! amenu 10.340 &File.&Save:w :if expand("%") == ""browse confirm welseconfirm wendif ! amenu 10.350 &File.Save\ &As\.\.\.:sav :browse confirm saveas if has("diff") ! amenu 10.400 &File.-SEP2- : ! amenu 10.410 &File.Split\ &Diff\ with\.\.\. :browse vert diffsplit ! amenu 10.420 &File.Split\ Patched\ &By\.\.\. :browse vert diffpatch endif if has("printer") ! amenu 10.500 &File.-SEP3- : ! amenu 10.510 &File.&Print :hardcopy ! vunmenu &File.&Print ! vmenu &File.&Print :hardcopy elseif has("unix") ! amenu 10.500 &File.-SEP3- : ! amenu 10.510 &File.&Print :w !lpr ! vunmenu &File.&Print ! vmenu &File.&Print :w !lpr endif ! amenu 10.600 &File.-SEP4- : ! amenu 10.610 &File.Sa&ve-Exit:wqa :confirm wqa ! amenu 10.620 &File.E&xit:qa :confirm qa " Pasting blockwise and linewise selections is not possible in Insert and " Visual mode without the +virtualedit feature. They are pasted as if they --- 83,121 ---- endfun " File menu ! an 10.310 &File.&Open\.\.\.:e :browse confirm e ! an 10.320 &File.Sp&lit-Open\.\.\.:sp :browse sp ! an 10.325 &File.&New:enew :confirm enew ! an 10.330 &File.&Close:close \ :if winheight(2) < 0 \ confirm enew \ else \ confirm close \ endif ! an 10.335 &File.-SEP1- ! an 10.340 &File.&Save:w :if expand("%") == ""browse confirm welseconfirm wendif ! an 10.350 &File.Save\ &As\.\.\.:sav :browse confirm saveas if has("diff") ! an 10.400 &File.-SEP2- ! an 10.410 &File.Split\ &Diff\ with\.\.\. :browse vert diffsplit ! an 10.420 &File.Split\ Patched\ &By\.\.\. :browse vert diffpatch endif if has("printer") ! an 10.500 &File.-SEP3- ! an 10.510 &File.&Print :hardcopy ! vunmenu &File.&Print ! vnoremenu &File.&Print :hardcopy elseif has("unix") ! an 10.500 &File.-SEP3- ! an 10.510 &File.&Print :w !lpr ! vunmenu &File.&Print ! vnoremenu &File.&Print :w !lpr endif ! an 10.600 &File.-SEP4- ! an 10.610 &File.Sa&ve-Exit:wqa :confirm wqa ! an 10.620 &File.E&xit:qa :confirm qa " Pasting blockwise and linewise selections is not possible in Insert and " Visual mode without the +virtualedit feature. They are pasted as if they *************** *** 128,204 **** endif " Edit menu ! amenu 20.310 &Edit.&Undou u ! amenu 20.320 &Edit.&Redo^R ! amenu 20.330 &Edit.Rep&eat\. . ! amenu 20.335 &Edit.-SEP1- : ! vmenu 20.340 &Edit.Cu&t"+x "+x ! vmenu 20.350 &Edit.&Copy"+y "+y ! cmenu 20.350 &Edit.&Copy"+y ! nmenu 20.360 &Edit.&Paste"+P "+gP ! cmenu &Edit.&Paste"+P + if has("virtualedit") ! vmenu &Edit.&Paste"+P "-cPaste ! imenu &Edit.&Paste"+P Pastegi else ! vmenu &Edit.&Paste"+P "-cgixPaste"_x ! imenu &Edit.&Paste"+P xPaste"_s endif ! nmenu 20.370 &Edit.Put\ &Before[p [p ! imenu &Edit.Put\ &Before[p [p ! nmenu 20.380 &Edit.Put\ &After]p ]p ! imenu &Edit.Put\ &After]p ]p if has("win32") || has("win16") ! vmenu 20.390 &Edit.&Deletex x endif ! amenu 20.400 &Edit.&Select\ allggVG :if &slm != ""exe ":norm gggHG"elseexe ":norm ggVG"endif ! amenu 20.405 &Edit.-SEP2- : if has("win32") || has("win16") || has("gui_gtk") || has("gui_motif") ! amenu 20.410 &Edit.&Find\.\.\. :promptfind ! vunmenu &Edit.&Find\.\.\. ! vmenu &Edit.&Find\.\.\. y:promptfind " ! amenu 20.420 &Edit.Find\ and\ Rep&lace\.\.\. :promptrepl ! vunmenu &Edit.Find\ and\ Rep&lace\.\.\. ! vmenu &Edit.Find\ and\ Rep&lace\.\.\. y:promptrepl " else ! amenu 20.410 &Edit.&Find/ / ! amenu 20.420 &Edit.Find\ and\ Rep&lace:%s :%s/ ! vunmenu &Edit.Find\ and\ Rep&lace:%s ! vmenu &Edit.Find\ and\ Rep&lace:s :s/ endif ! amenu 20.425 &Edit.-SEP3- : ! amenu 20.430 &Edit.Settings\ &Window :options " Edit/Global Settings ! amenu 20.440.100 &Edit.&Global\ Settings.Toggle\ Pattern\ &Highlight:set\ hls! :set hls! hls? ! amenu 20.440.110 &Edit.&Global\ Settings.Toggle\ &Ignore-case:set\ ic! :set ic! ic? ! amenu 20.440.110 &Edit.&Global\ Settings.Toggle\ &Showmatch:set\ sm! :set sm! sm? ! ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 1\ :set so=1 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 2\ :set so=2 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 3\ :set so=3 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 4\ :set so=4 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 5\ :set so=5 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 7\ :set so=7 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 10\ :set so=10 ! amenu 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 100\ :set so=100 ! ! amenu 20.440.130.40 &Edit.&Global\ Settings.&Virtual\ Edit.Never :set ve= ! amenu 20.440.130.50 &Edit.&Global\ Settings.&Virtual\ Edit.Block\ Selection :set ve=block ! amenu 20.440.130.60 &Edit.&Global\ Settings.&Virtual\ Edit.Insert\ mode :set ve=insert ! amenu 20.440.130.70 &Edit.&Global\ Settings.&Virtual\ Edit.Block\ and\ Insert :set ve=block,insert ! amenu 20.440.130.80 &Edit.&Global\ Settings.&Virtual\ Edit.Always :set ve=all ! amenu 20.440.140 &Edit.&Global\ Settings.Toggle\ Insert\ &Mode:set\ im! :set im! ! amenu 20.440.145 &Edit.&Global\ Settings.Toggle\ Vi\ C&ompatible:set\ cp! :set cp! ! amenu 20.440.150 &Edit.&Global\ Settings.Search\ &Path\.\.\. :call SearchP() ! amenu 20.440.160 &Edit.&Global\ Settings.Ta&g\ Files\.\.\. :call TagFiles() " " GUI options ! amenu 20.440.300 &Edit.&Global\ Settings.-SEP1- : ! amenu 20.440.310 &Edit.&Global\ Settings.Toggle\ &Toolbar :call ToggleGuiOption("T") ! amenu 20.440.320 &Edit.&Global\ Settings.Toggle\ &Bottom\ Scrollbar :call ToggleGuiOption("b") ! amenu 20.440.330 &Edit.&Global\ Settings.Toggle\ &Left\ Scrollbar :call ToggleGuiOption("l") ! amenu 20.440.340 &Edit.&Global\ Settings.Toggle\ &Right\ Scrollbar :call ToggleGuiOption("r") fun! s:SearchP() if !exists("g:menutrans_path_dialog") --- 133,212 ---- endif " Edit menu ! an 20.310 &Edit.&Undou u ! an 20.320 &Edit.&Redo^R ! an 20.330 &Edit.Rep&eat\. . ! ! an 20.335 &Edit.-SEP1- ! vnoremenu 20.340 &Edit.Cu&t"+x "+x ! vnoremenu 20.350 &Edit.&Copy"+y "+y ! cnoremenu 20.350 &Edit.&Copy"+y ! nnoremenu 20.360 &Edit.&Paste"+P "+gP ! cnoremenu &Edit.&Paste"+P + if has("virtualedit") ! vnoremenu &Edit.&Paste"+P "-cPaste ! inoremenu &Edit.&Paste"+P Pastegi else ! vnoremenu &Edit.&Paste"+P "-cgixPaste"_x ! inoremenu &Edit.&Paste"+P xPaste"_s endif ! nnoremenu 20.370 &Edit.Put\ &Before[p [p ! inoremenu &Edit.Put\ &Before[p [p ! nnoremenu 20.380 &Edit.Put\ &After]p ]p ! inoremenu &Edit.Put\ &After]p ]p if has("win32") || has("win16") ! vnoremenu 20.390 &Edit.&Deletex x endif ! an 20.400 &Edit.&Select\ allggVG :if &slm != ""exe ":norm gggHG"elseexe ":norm ggVG"endif ! ! an 20.405 &Edit.-SEP2- if has("win32") || has("win16") || has("gui_gtk") || has("gui_motif") ! an 20.410 &Edit.&Find\.\.\. :promptfind ! vunmenu &Edit.&Find\.\.\. ! vnoremenu &Edit.&Find\.\.\. y:promptfind " ! an 20.420 &Edit.Find\ and\ Rep&lace\.\.\. :promptrepl ! vunmenu &Edit.Find\ and\ Rep&lace\.\.\. ! vnoremenu &Edit.Find\ and\ Rep&lace\.\.\. y:promptrepl " else ! an 20.410 &Edit.&Find/ / ! an 20.420 &Edit.Find\ and\ Rep&lace:%s :%s/ ! vunmenu &Edit.Find\ and\ Rep&lace:%s ! vnoremenu &Edit.Find\ and\ Rep&lace:s :s/ endif ! ! an 20.425 &Edit.-SEP3- ! an 20.430 &Edit.Settings\ &Window :options " Edit/Global Settings ! an 20.440.100 &Edit.&Global\ Settings.Toggle\ Pattern\ &Highlight:set\ hls! :set hls! hls? ! an 20.440.110 &Edit.&Global\ Settings.Toggle\ &Ignore-case:set\ ic! :set ic! ic? ! an 20.440.110 &Edit.&Global\ Settings.Toggle\ &Showmatch:set\ sm! :set sm! sm? ! ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 1\ :set so=1 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 2\ :set so=2 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 3\ :set so=3 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 4\ :set so=4 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 5\ :set so=5 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 7\ :set so=7 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 10\ :set so=10 ! an 20.440.120 &Edit.&Global\ Settings.&Context\ lines.\ 100\ :set so=100 ! ! an 20.440.130.40 &Edit.&Global\ Settings.&Virtual\ Edit.Never :set ve= ! an 20.440.130.50 &Edit.&Global\ Settings.&Virtual\ Edit.Block\ Selection :set ve=block ! an 20.440.130.60 &Edit.&Global\ Settings.&Virtual\ Edit.Insert\ mode :set ve=insert ! an 20.440.130.70 &Edit.&Global\ Settings.&Virtual\ Edit.Block\ and\ Insert :set ve=block,insert ! an 20.440.130.80 &Edit.&Global\ Settings.&Virtual\ Edit.Always :set ve=all ! an 20.440.140 &Edit.&Global\ Settings.Toggle\ Insert\ &Mode:set\ im! :set im! ! an 20.440.145 &Edit.&Global\ Settings.Toggle\ Vi\ C&ompatible:set\ cp! :set cp! ! an 20.440.150 &Edit.&Global\ Settings.Search\ &Path\.\.\. :call SearchP() ! an 20.440.160 &Edit.&Global\ Settings.Ta&g\ Files\.\.\. :call TagFiles() " " GUI options ! an 20.440.300 &Edit.&Global\ Settings.-SEP1- ! an 20.440.310 &Edit.&Global\ Settings.Toggle\ &Toolbar :call ToggleGuiOption("T") ! an 20.440.320 &Edit.&Global\ Settings.Toggle\ &Bottom\ Scrollbar :call ToggleGuiOption("b") ! an 20.440.330 &Edit.&Global\ Settings.Toggle\ &Left\ Scrollbar :call ToggleGuiOption("l") ! an 20.440.340 &Edit.&Global\ Settings.Toggle\ &Right\ Scrollbar :call ToggleGuiOption("r") fun! s:SearchP() if !exists("g:menutrans_path_dialog") *************** *** 232,263 **** " Edit/File Settings " Boolean options ! amenu 20.440.100 &Edit.F&ile\ Settings.Toggle\ Line\ &Numbering:set\ nu! :set nu! nu? ! amenu 20.440.110 &Edit.F&ile\ Settings.Toggle\ &List\ Mode:set\ list! :set list! list? ! amenu 20.440.120 &Edit.F&ile\ Settings.Toggle\ Line\ &Wrap:set\ wrap! :set wrap! wrap? ! amenu 20.440.130 &Edit.F&ile\ Settings.Toggle\ W&rap\ at\ word:set\ lbr! :set lbr! lbr? ! amenu 20.440.160 &Edit.F&ile\ Settings.Toggle\ &expand-tab:set\ et! :set et! et? ! amenu 20.440.170 &Edit.F&ile\ Settings.Toggle\ &auto-indent:set\ ai! :set ai! ai? ! amenu 20.440.180 &Edit.F&ile\ Settings.Toggle\ &C-indenting:set\ cin! :set cin! cin? " other options ! amenu 20.440.600 &Edit.F&ile\ Settings.-SEP2- : ! amenu 20.440.610.20 &Edit.F&ile\ Settings.&Shiftwidth.2 :set sw=2 sw? ! amenu 20.440.610.30 &Edit.F&ile\ Settings.&Shiftwidth.3 :set sw=3 sw? ! amenu 20.440.610.40 &Edit.F&ile\ Settings.&Shiftwidth.4 :set sw=4 sw? ! amenu 20.440.610.50 &Edit.F&ile\ Settings.&Shiftwidth.5 :set sw=5 sw? ! amenu 20.440.610.60 &Edit.F&ile\ Settings.&Shiftwidth.6 :set sw=6 sw? ! amenu 20.440.610.80 &Edit.F&ile\ Settings.&Shiftwidth.8 :set sw=8 sw? ! ! amenu 20.440.620.20 &Edit.F&ile\ Settings.Soft\ &Tabstop.2 :set sts=2 sts? ! amenu 20.440.620.30 &Edit.F&ile\ Settings.Soft\ &Tabstop.3 :set sts=3 sts? ! amenu 20.440.620.40 &Edit.F&ile\ Settings.Soft\ &Tabstop.4 :set sts=4 sts? ! amenu 20.440.620.50 &Edit.F&ile\ Settings.Soft\ &Tabstop.5 :set sts=5 sts? ! amenu 20.440.620.60 &Edit.F&ile\ Settings.Soft\ &Tabstop.6 :set sts=6 sts? ! amenu 20.440.620.80 &Edit.F&ile\ Settings.Soft\ &Tabstop.8 :set sts=8 sts? ! amenu 20.440.630 &Edit.F&ile\ Settings.Te&xt\ Width\.\.\. :call TextWidth() ! amenu 20.440.640 &Edit.F&ile\ Settings.&File\ Format\.\.\. :call FileFormat() fun! s:TextWidth() if !exists("g:menutrans_textwidth_dialog") let g:menutrans_textwidth_dialog = "Enter new text width (0 to disable formatting): " --- 240,271 ---- " Edit/File Settings " Boolean options ! an 20.440.100 &Edit.F&ile\ Settings.Toggle\ Line\ &Numbering:set\ nu! :set nu! nu? ! an 20.440.110 &Edit.F&ile\ Settings.Toggle\ &List\ Mode:set\ list! :set list! list? ! an 20.440.120 &Edit.F&ile\ Settings.Toggle\ Line\ &Wrap:set\ wrap! :set wrap! wrap? ! an 20.440.130 &Edit.F&ile\ Settings.Toggle\ W&rap\ at\ word:set\ lbr! :set lbr! lbr? ! an 20.440.160 &Edit.F&ile\ Settings.Toggle\ &expand-tab:set\ et! :set et! et? ! an 20.440.170 &Edit.F&ile\ Settings.Toggle\ &auto-indent:set\ ai! :set ai! ai? ! an 20.440.180 &Edit.F&ile\ Settings.Toggle\ &C-indenting:set\ cin! :set cin! cin? " other options ! an 20.440.600 &Edit.F&ile\ Settings.-SEP2- ! an 20.440.610.20 &Edit.F&ile\ Settings.&Shiftwidth.2 :set sw=2 sw? ! an 20.440.610.30 &Edit.F&ile\ Settings.&Shiftwidth.3 :set sw=3 sw? ! an 20.440.610.40 &Edit.F&ile\ Settings.&Shiftwidth.4 :set sw=4 sw? ! an 20.440.610.50 &Edit.F&ile\ Settings.&Shiftwidth.5 :set sw=5 sw? ! an 20.440.610.60 &Edit.F&ile\ Settings.&Shiftwidth.6 :set sw=6 sw? ! an 20.440.610.80 &Edit.F&ile\ Settings.&Shiftwidth.8 :set sw=8 sw? ! ! an 20.440.620.20 &Edit.F&ile\ Settings.Soft\ &Tabstop.2 :set sts=2 sts? ! an 20.440.620.30 &Edit.F&ile\ Settings.Soft\ &Tabstop.3 :set sts=3 sts? ! an 20.440.620.40 &Edit.F&ile\ Settings.Soft\ &Tabstop.4 :set sts=4 sts? ! an 20.440.620.50 &Edit.F&ile\ Settings.Soft\ &Tabstop.5 :set sts=5 sts? ! an 20.440.620.60 &Edit.F&ile\ Settings.Soft\ &Tabstop.6 :set sts=6 sts? ! an 20.440.620.80 &Edit.F&ile\ Settings.Soft\ &Tabstop.8 :set sts=8 sts? ! an 20.440.630 &Edit.F&ile\ Settings.Te&xt\ Width\.\.\. :call TextWidth() ! an 20.440.640 &Edit.F&ile\ Settings.&File\ Format\.\.\. :call FileFormat() fun! s:TextWidth() if !exists("g:menutrans_textwidth_dialog") let g:menutrans_textwidth_dialog = "Enter new text width (0 to disable formatting): " *************** *** 303,309 **** let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:]*\)\.vim', '\1', '') ! exe "amenu 20.450." . s:idx . ' &Edit.C&olor\ Scheme.' . s:name . " :colors " . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 --- 311,317 ---- let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:]*\)\.vim', '\1', '') ! exe "an 20.450." . s:idx . ' &Edit.C&olor\ Scheme.' . s:name . " :colors " . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 *************** *** 316,322 **** let s:n = globpath(&runtimepath, "keymap/*.vim") if s:n != "" let s:idx = 100 ! amenu 20.460.90 &Edit.&Keymap.None :set keymap= while strlen(s:n) > 0 let s:i = stridx(s:n, "\n") if s:i < 0 --- 324,330 ---- let s:n = globpath(&runtimepath, "keymap/*.vim") if s:n != "" let s:idx = 100 ! an 20.460.90 &Edit.&Keymap.None :set keymap= while strlen(s:n) > 0 let s:i = stridx(s:n, "\n") if s:i < 0 *************** *** 327,333 **** let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:_]*\)\(_[0-9a-zA-Z-]*\)\=\.vim', '\1', '') ! exe "amenu 20.460." . s:idx . ' &Edit.&Keymap.' . s:name . " :set keymap=" . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 --- 335,341 ---- let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:_]*\)\(_[0-9a-zA-Z-]*\)\=\.vim', '\1', '') ! exe "an 20.460." . s:idx . ' &Edit.&Keymap.' . s:name . " :set keymap=" . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 *************** *** 337,416 **** unlet s:n endif if has("win32") || has("win16") || has("gui_gtk") || has("gui_photon") ! amenu 20.470 &Edit.Select\ Fo&nt\.\.\. :set guifont=* endif " Programming menu ! amenu 40.300 &Tools.&Jump\ to\ this\ tagg^] g vunmenu &Tools.&Jump\ to\ this\ tagg^] ! vmenu &Tools.&Jump\ to\ this\ tagg^] g ! amenu 40.310 &Tools.Jump\ &back^T if has("vms") ! amenu 40.320 &Tools.Build\ &Tags\ File :!mc vim:ctags . else ! amenu 40.320 &Tools.Build\ &Tags\ File :!ctags -R . endif " Tools.Fold Menu if has("folding") ! amenu 40.330 &Tools.-SEP1- : " open close folds ! amenu 40.340.110 &Tools.&Folding.&Enable/Disable\ foldszi zi ! amenu 40.340.120 &Tools.&Folding.&View\ Cursor\ Linezv zv ! amenu 40.340.120 &Tools.&Folding.Vie&w\ Cursor\ Line\ onlyzMzx zMzx ! amenu 40.340.130 &Tools.&Folding.C&lose\ more\ foldszm zm ! amenu 40.340.140 &Tools.&Folding.&Close\ all\ foldszM zM ! amenu 40.340.150 &Tools.&Folding.O&pen\ more\ foldszr zr ! amenu 40.340.160 &Tools.&Folding.&Open\ all\ foldszR zR " fold method ! amenu 40.340.200 &Tools.&Folding.-SEP1- : ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.M&anual :set fdm=manual ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.I&ndent :set fdm=indent ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.E&xpression :set fdm=expr ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.S&yntax :set fdm=syntax ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.&Diff :set fdm=diff ! amenu 40.340.210 &Tools.&Folding.Fold\ Met&hod.Ma&rker :set fdm=marker " create and delete folds ! vmenu 40.340.220 &Tools.&Folding.Create\ &Foldzf zf ! amenu 40.340.230 &Tools.&Folding.&Delete\ Foldzd zd ! amenu 40.340.240 &Tools.&Folding.Delete\ &All\ FoldszD zD " moving around in folds ! amenu 40.340.300 &Tools.&Folding.-SEP2- : ! amenu 40.340.310.10 &Tools.&Folding.Fold\ column\ &width.\ 0\ :set fdc=0 ! amenu 40.340.310.20 &Tools.&Folding.Fold\ column\ &width.\ 2\ :set fdc=2 ! amenu 40.340.310.30 &Tools.&Folding.Fold\ column\ &width.\ 3\ :set fdc=3 ! amenu 40.340.310.40 &Tools.&Folding.Fold\ column\ &width.\ 4\ :set fdc=4 ! amenu 40.340.310.50 &Tools.&Folding.Fold\ column\ &width.\ 5\ :set fdc=5 ! amenu 40.340.310.60 &Tools.&Folding.Fold\ column\ &width.\ 6\ :set fdc=6 ! amenu 40.340.310.70 &Tools.&Folding.Fold\ column\ &width.\ 7\ :set fdc=7 ! amenu 40.340.310.80 &Tools.&Folding.Fold\ column\ &width.\ 8\ :set fdc=8 endif " has folding if has("diff") ! amenu 40.350.100 &Tools.&Diff.&Update :diffupdate ! amenu 40.350.110 &Tools.&Diff.&Get\ Block :diffget vunmenu &Tools.&Diff.&Get\ Block ! vmenu &Tools.&Diff.&Get\ Block :diffget ! amenu 40.350.120 &Tools.&Diff.&Put\ Block :diffput vunmenu &Tools.&Diff.&Put\ Block ! vmenu &Tools.&Diff.&Put\ Block :diffput endif ! amenu 40.358 &Tools.-SEP2- : ! amenu 40.360 &Tools.&Make:make :make ! amenu 40.370 &Tools.&List\ Errors:cl :cl ! amenu 40.380 &Tools.L&ist\ Messages:cl! :cl! ! amenu 40.390 &Tools.&Next\ Error:cn :cn ! amenu 40.400 &Tools.&Previous\ Error:cp :cp ! amenu 40.410 &Tools.&Older\ List:cold :colder ! amenu 40.420 &Tools.N&ewer\ List:cnew :cnewer ! amenu 40.430.50 &Tools.Error\ &Window.&Update:cwin :cwin ! amenu 40.430.60 &Tools.Error\ &Window.&Open:copen :copen ! amenu 40.430.70 &Tools.Error\ &Window.&Close:cclose :cclose ! amenu 40.520 &Tools.-SEP3- : ! amenu 40.530 &Tools.&Convert\ to\ HEX:%!xxd \ :call XxdConv() ! amenu 40.540 &Tools.Conve&rt\ back:%!xxd\ -r \ :call XxdBack() " Use a function to do the conversion, so that it also works with 'insertmode' --- 345,425 ---- unlet s:n endif if has("win32") || has("win16") || has("gui_gtk") || has("gui_photon") ! an 20.470 &Edit.Select\ Fo&nt\.\.\. :set guifont=* endif " Programming menu ! an 40.300 &Tools.&Jump\ to\ this\ tagg^] g vunmenu &Tools.&Jump\ to\ this\ tagg^] ! vnoremenu &Tools.&Jump\ to\ this\ tagg^] g ! an 40.310 &Tools.Jump\ &back^T if has("vms") ! an 40.320 &Tools.Build\ &Tags\ File :!mc vim:ctags . else ! an 40.320 &Tools.Build\ &Tags\ File :!ctags -R . endif " Tools.Fold Menu if has("folding") ! an 40.330 &Tools.-SEP1- " open close folds ! an 40.340.110 &Tools.&Folding.&Enable/Disable\ foldszi zi ! an 40.340.120 &Tools.&Folding.&View\ Cursor\ Linezv zv ! an 40.340.120 &Tools.&Folding.Vie&w\ Cursor\ Line\ onlyzMzx zMzx ! an 40.340.130 &Tools.&Folding.C&lose\ more\ foldszm zm ! an 40.340.140 &Tools.&Folding.&Close\ all\ foldszM zM ! an 40.340.150 &Tools.&Folding.O&pen\ more\ foldszr zr ! an 40.340.160 &Tools.&Folding.&Open\ all\ foldszR zR " fold method ! an 40.340.200 &Tools.&Folding.-SEP1- ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.M&anual :set fdm=manual ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.I&ndent :set fdm=indent ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.E&xpression :set fdm=expr ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.S&yntax :set fdm=syntax ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.&Diff :set fdm=diff ! an 40.340.210 &Tools.&Folding.Fold\ Met&hod.Ma&rker :set fdm=marker " create and delete folds ! vnoremenu 40.340.220 &Tools.&Folding.Create\ &Foldzf zf ! an 40.340.230 &Tools.&Folding.&Delete\ Foldzd zd ! an 40.340.240 &Tools.&Folding.Delete\ &All\ FoldszD zD " moving around in folds ! an 40.340.300 &Tools.&Folding.-SEP2- ! an 40.340.310.10 &Tools.&Folding.Fold\ column\ &width.\ 0\ :set fdc=0 ! an 40.340.310.20 &Tools.&Folding.Fold\ column\ &width.\ 2\ :set fdc=2 ! an 40.340.310.30 &Tools.&Folding.Fold\ column\ &width.\ 3\ :set fdc=3 ! an 40.340.310.40 &Tools.&Folding.Fold\ column\ &width.\ 4\ :set fdc=4 ! an 40.340.310.50 &Tools.&Folding.Fold\ column\ &width.\ 5\ :set fdc=5 ! an 40.340.310.60 &Tools.&Folding.Fold\ column\ &width.\ 6\ :set fdc=6 ! an 40.340.310.70 &Tools.&Folding.Fold\ column\ &width.\ 7\ :set fdc=7 ! an 40.340.310.80 &Tools.&Folding.Fold\ column\ &width.\ 8\ :set fdc=8 endif " has folding if has("diff") ! an 40.350.100 &Tools.&Diff.&Update :diffupdate ! an 40.350.110 &Tools.&Diff.&Get\ Block :diffget vunmenu &Tools.&Diff.&Get\ Block ! vnoremenu &Tools.&Diff.&Get\ Block :diffget ! an 40.350.120 &Tools.&Diff.&Put\ Block :diffput vunmenu &Tools.&Diff.&Put\ Block ! vnoremenu &Tools.&Diff.&Put\ Block :diffput endif ! an 40.358 &Tools.-SEP2- ! an 40.360 &Tools.&Make:make :make ! an 40.370 &Tools.&List\ Errors:cl :cl ! an 40.380 &Tools.L&ist\ Messages:cl! :cl! ! an 40.390 &Tools.&Next\ Error:cn :cn ! an 40.400 &Tools.&Previous\ Error:cp :cp ! an 40.410 &Tools.&Older\ List:cold :colder ! an 40.420 &Tools.N&ewer\ List:cnew :cnewer ! an 40.430.50 &Tools.Error\ &Window.&Update:cwin :cwin ! an 40.430.60 &Tools.Error\ &Window.&Open:copen :copen ! an 40.430.70 &Tools.Error\ &Window.&Close:cclose :cclose ! ! an 40.520 &Tools.-SEP3- ! an 40.530 &Tools.&Convert\ to\ HEX:%!xxd \ :call XxdConv() ! an 40.540 &Tools.Conve&rt\ back:%!xxd\ -r \ :call XxdBack() " Use a function to do the conversion, so that it also works with 'insertmode' *************** *** 450,456 **** let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:]*\)\.vim', '\1', '') ! exe "amenu 30.440." . s:idx . ' &Tools.&Set\ Compiler.' . s:name . " :compiler " . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 --- 459,465 ---- let s:n = strpart(s:n, s:i + 1, 19999) endif let s:name = substitute(s:name, '.*[/\\:]\([^/\\:]*\)\.vim', '\1', '') ! exe "an 30.440." . s:idx . ' &Tools.&Set\ Compiler.' . s:name . " :compiler " . s:name . "" unlet s:name unlet s:i let s:idx = s:idx + 10 *************** *** 513,530 **** " remove old menu, if exists; keep one entry to avoid a torn off menu to " disappear. silent! unmenu &Buffers ! exe 'menu ' . g:bmenu_priority . ".1 &Buffers.Dummy l" silent! unmenu! &Buffers " create new menu; set 'cpo' to include the let cpo_save = &cpo set cpo&vim ! exe 'am ' . g:bmenu_priority . ".2 &Buffers.&Refresh\\ menu :call BMShow()" ! exe 'am ' . g:bmenu_priority . ".4 &Buffers.&Delete :bd" ! exe 'am ' . g:bmenu_priority . ".6 &Buffers.&Alternate :b #" ! exe 'am ' . g:bmenu_priority . ".7 &Buffers.&Next :bnext" ! exe 'am ' . g:bmenu_priority . ".8 &Buffers.&Previous :bprev" ! exe 'am ' . g:bmenu_priority . ".9 &Buffers.-SEP- :" let &cpo = cpo_save unmenu &Buffers.Dummy --- 522,539 ---- " remove old menu, if exists; keep one entry to avoid a torn off menu to " disappear. silent! unmenu &Buffers ! exe 'noremenu ' . g:bmenu_priority . ".1 &Buffers.Dummy l" silent! unmenu! &Buffers " create new menu; set 'cpo' to include the let cpo_save = &cpo set cpo&vim ! exe 'an ' . g:bmenu_priority . ".2 &Buffers.&Refresh\\ menu :call BMShow()" ! exe 'an ' . g:bmenu_priority . ".4 &Buffers.&Delete :bd" ! exe 'an ' . g:bmenu_priority . ".6 &Buffers.&Alternate :b #" ! exe 'an ' . g:bmenu_priority . ".7 &Buffers.&Next :bnext" ! exe 'an ' . g:bmenu_priority . ".8 &Buffers.&Previous :bprev" ! exe 'an ' . g:bmenu_priority . ".9 &Buffers.-SEP- :" let &cpo = cpo_save unmenu &Buffers.Dummy *************** *** 601,609 **** let munge = BMMunge(a:name, a:num) let hash = BMHash(munge) if s:bmenu_short == 0 ! let name = 'am ' . g:bmenu_priority . '.' . hash . ' &Buffers.' . munge else ! let name = 'am ' . g:bmenu_priority . '.' . hash . '.' . hash . ' &Buffers.' . BMHash2(munge) . munge endif " set 'cpo' to include the let cpo_save = &cpo --- 610,618 ---- let munge = BMMunge(a:name, a:num) let hash = BMHash(munge) if s:bmenu_short == 0 ! let name = 'an ' . g:bmenu_priority . '.' . hash . ' &Buffers.' . munge else ! let name = 'an ' . g:bmenu_priority . '.' . hash . '.' . hash . ' &Buffers.' . BMHash2(munge) . munge endif " set 'cpo' to include the let cpo_save = &cpo *************** *** 667,678 **** endif " !exists("no_buffers_menu") " Window menu ! amenu 70.300 &Window.&New^Wn n ! amenu 70.310 &Window.S&plit^Ws s ! amenu 70.320 &Window.Sp&lit\ To\ #^W^^ ! amenu 70.330 &Window.Split\ &Vertically^Wv v if has("vertsplit") ! amenu 70.332 &Window.Split\ File\ E&xplorer :call MenuExplOpen() if !exists("*MenuExplOpen") fun MenuExplOpen() if @% == "" --- 676,687 ---- endif " !exists("no_buffers_menu") " Window menu ! an 70.300 &Window.&New^Wn n ! an 70.310 &Window.S&plit^Ws s ! an 70.320 &Window.Sp&lit\ To\ #^W^^ ! an 70.330 &Window.Split\ &Vertically^Wv v if has("vertsplit") ! an 70.332 &Window.Split\ File\ E&xplorer :call MenuExplOpen() if !exists("*MenuExplOpen") fun MenuExplOpen() if @% == "" *************** *** 683,800 **** endfun endif endif ! amenu 70.335 &Window.-SEP1- : ! amenu 70.340 &Window.&Close^Wc :confirm close ! amenu 70.345 &Window.Close\ &Other(s)^Wo :confirm only ! amenu 70.350 &Window.-SEP2- : ! amenu 70.355 &Window.Move\ &To.&Top^WK K ! amenu 70.355 &Window.Move\ &To.&Bottom^WJ J ! amenu 70.355 &Window.Move\ &To.&Left\ side^WH H ! amenu 70.355 &Window.Move\ &To.&Right\ side^WL L ! amenu 70.360 &Window.Rotate\ &Up^WR R ! amenu 70.362 &Window.Rotate\ &Down^Wr r ! amenu 70.365 &Window.-SEP3- : ! amenu 70.370 &Window.&Equal\ Size^W= = ! amenu 70.380 &Window.&Max\ Height^W_ _ ! amenu 70.390 &Window.M&in\ Height^W1_ 1_ ! amenu 70.400 &Window.Max\ &Width^W\| \| ! amenu 70.410 &Window.Min\ Widt&h^W1\| 1\| " The popup menu ! amenu 1.10 PopUp.&Undo u ! amenu 1.15 PopUp.-SEP1- : ! vmenu 1.20 PopUp.Cu&t "+x ! vmenu 1.30 PopUp.&Copy "+y ! cmenu 1.30 PopUp.&Copy ! nmenu 1.40 PopUp.&Paste "+gP ! cmenu 1.40 PopUp.&Paste + if has("virtualedit") ! vmenu 1.40 PopUp.&Paste "-cPaste ! imenu 1.40 PopUp.&Paste Pastegi else ! vmenu 1.40 PopUp.&Paste "-cgixPaste"_x ! imenu 1.40 PopUp.&Paste xPaste"_s endif ! vmenu 1.50 PopUp.&Delete x ! amenu 1.55 PopUp.-SEP2- : vnoremenu 1.60 PopUp.Select\ Blockwise ! anoremenu 1.70 PopUp.Select\ &Word vaw ! anoremenu 1.80 PopUp.Select\ &Line V ! anoremenu 1.90 PopUp.Select\ &Block ! anoremenu 1.100 PopUp.Select\ &All ggVG " The GUI toolbar (for MS-Windows and GTK) if has("toolbar") ! amenu 1.10 ToolBar.Open :browse confirm e ! amenu 1.20 ToolBar.Save :if expand("%") == ""browse confirm welseconfirm wendif ! amenu 1.30 ToolBar.SaveAll :wa if has("printer") ! amenu 1.40 ToolBar.Print :hardcopy ! vunmenu ToolBar.Print ! vmenu ToolBar.Print :hardcopy elseif has("unix") ! amenu 1.40 ToolBar.Print :w !lpr ! vunmenu ToolBar.Print ! vmenu ToolBar.Print :w !lpr endif ! amenu 1.45 ToolBar.-sep1- ! amenu 1.50 ToolBar.Undo u ! amenu 1.60 ToolBar.Redo ! ! amenu 1.65 ToolBar.-sep2- ! vmenu 1.70 ToolBar.Cut "+x ! vmenu 1.80 ToolBar.Copy "+y ! cmenu 1.80 ToolBar.Copy ! nmenu 1.90 ToolBar.Paste "+gP ! cmenu ToolBar.Paste + if has("virtualedit") ! vmenu ToolBar.Paste "-cPaste ! imenu ToolBar.Paste Pastegi else ! vmenu ToolBar.Paste "-cgixPaste"_x ! imenu ToolBar.Paste xPaste"_s endif if !has("gui_athena") ! amenu 1.95 ToolBar.-sep3- ! amenu 1.100 ToolBar.Find :promptfind ! vunmenu ToolBar.Find ! vmenu ToolBar.Find y:promptfind " ! amenu 1.110 ToolBar.FindNext n ! amenu 1.120 ToolBar.FindPrev N ! amenu 1.130 ToolBar.Replace :promptrepl ! vunmenu ToolBar.Replace ! vmenu ToolBar.Replace y:promptrepl " endif if 0 " disabled; These are in the Windows menu ! amenu 1.135 ToolBar.-sep4- ! amenu 1.140 ToolBar.New n ! amenu 1.150 ToolBar.WinSplit s ! amenu 1.160 ToolBar.WinMax :resize 200 ! amenu 1.170 ToolBar.WinMin :resize 1 ! amenu 1.180 ToolBar.WinVSplit v ! amenu 1.190 ToolBar.WinMaxWidth 500> ! amenu 1.200 ToolBar.WinMinWidth 1\| ! amenu 1.210 ToolBar.WinClose :close endif ! amenu 1.215 ToolBar.-sep5- ! amenu 1.220 ToolBar.LoadSesn :call LoadVimSesn() ! amenu 1.230 ToolBar.SaveSesn :call SaveVimSesn() ! amenu 1.240 ToolBar.RunScript :browse so ! ! amenu 1.245 ToolBar.-sep6- ! amenu 1.250 ToolBar.Make :make ! amenu 1.260 ToolBar.Shell :sh ! amenu 1.270 ToolBar.RunCtags :!ctags -R . ! amenu 1.280 ToolBar.TagJump g] ! ! amenu 1.295 ToolBar.-sep7- ! amenu 1.300 ToolBar.Help :help ! amenu 1.310 ToolBar.FindHelp :call Helpfind() " Only set the tooltips here if not done in a language menu file if exists("*Do_toolbar_tmenu") --- 692,809 ---- endfun endif endif ! an 70.335 &Window.-SEP1- ! an 70.340 &Window.&Close^Wc :confirm close ! an 70.345 &Window.Close\ &Other(s)^Wo :confirm only ! an 70.350 &Window.-SEP2- ! an 70.355 &Window.Move\ &To.&Top^WK K ! an 70.355 &Window.Move\ &To.&Bottom^WJ J ! an 70.355 &Window.Move\ &To.&Left\ side^WH H ! an 70.355 &Window.Move\ &To.&Right\ side^WL L ! an 70.360 &Window.Rotate\ &Up^WR R ! an 70.362 &Window.Rotate\ &Down^Wr r ! an 70.365 &Window.-SEP3- ! an 70.370 &Window.&Equal\ Size^W= = ! an 70.380 &Window.&Max\ Height^W_ _ ! an 70.390 &Window.M&in\ Height^W1_ 1_ ! an 70.400 &Window.Max\ &Width^W\| \| ! an 70.410 &Window.Min\ Widt&h^W1\| 1\| " The popup menu ! an 1.10 PopUp.&Undo u ! an 1.15 PopUp.-SEP1- ! vnoremenu 1.20 PopUp.Cu&t "+x ! vnoremenu 1.30 PopUp.&Copy "+y ! cnoremenu 1.30 PopUp.&Copy ! nnoremenu 1.40 PopUp.&Paste "+gP ! cnoremenu 1.40 PopUp.&Paste + if has("virtualedit") ! vnoremenu 1.40 PopUp.&Paste "-cPaste ! inoremenu 1.40 PopUp.&Paste Pastegi else ! vnoremenu 1.40 PopUp.&Paste "-cgixPaste"_x ! inoremenu 1.40 PopUp.&Paste xPaste"_s endif ! vnoremenu 1.50 PopUp.&Delete x ! an 1.55 PopUp.-SEP2- vnoremenu 1.60 PopUp.Select\ Blockwise ! an 1.70 PopUp.Select\ &Word vaw ! an 1.80 PopUp.Select\ &Line V ! an 1.90 PopUp.Select\ &Block ! an 1.100 PopUp.Select\ &All ggVG " The GUI toolbar (for MS-Windows and GTK) if has("toolbar") ! an 1.10 ToolBar.Open :browse confirm e ! an 1.20 ToolBar.Save :if expand("%") == ""browse confirm welseconfirm wendif ! an 1.30 ToolBar.SaveAll :wa if has("printer") ! an 1.40 ToolBar.Print :hardcopy ! vunmenu ToolBar.Print ! vnoremenu ToolBar.Print :hardcopy elseif has("unix") ! an 1.40 ToolBar.Print :w !lpr ! vunmenu ToolBar.Print ! vnoremenu ToolBar.Print :w !lpr endif ! an 1.45 ToolBar.-sep1- ! an 1.50 ToolBar.Undo u ! an 1.60 ToolBar.Redo ! ! an 1.65 ToolBar.-sep2- ! vnoremenu 1.70 ToolBar.Cut "+x ! vnoremenu 1.80 ToolBar.Copy "+y ! cnoremenu 1.80 ToolBar.Copy ! nnoremenu 1.90 ToolBar.Paste "+gP ! cnoremenu ToolBar.Paste + if has("virtualedit") ! vnoremenu ToolBar.Paste "-cPaste ! inoremenu ToolBar.Paste Pastegi else ! vnoremenu ToolBar.Paste "-cgixPaste"_x ! inoremenu ToolBar.Paste xPaste"_s endif if !has("gui_athena") ! an 1.95 ToolBar.-sep3- ! an 1.100 ToolBar.Find :promptfind ! vunmenu ToolBar.Find ! vnoremenu ToolBar.Find y:promptfind " ! an 1.110 ToolBar.FindNext n ! an 1.120 ToolBar.FindPrev N ! an 1.130 ToolBar.Replace :promptrepl ! vunmenu ToolBar.Replace ! vnoremenu ToolBar.Replace y:promptrepl " endif if 0 " disabled; These are in the Windows menu ! an 1.135 ToolBar.-sep4- ! an 1.140 ToolBar.New n ! an 1.150 ToolBar.WinSplit s ! an 1.160 ToolBar.WinMax :resize 200 ! an 1.170 ToolBar.WinMin :resize 1 ! an 1.180 ToolBar.WinVSplit v ! an 1.190 ToolBar.WinMaxWidth 500> ! an 1.200 ToolBar.WinMinWidth 1\| ! an 1.210 ToolBar.WinClose :close endif ! an 1.215 ToolBar.-sep5- ! an 1.220 ToolBar.LoadSesn :call LoadVimSesn() ! an 1.230 ToolBar.SaveSesn :call SaveVimSesn() ! an 1.240 ToolBar.RunScript :browse so ! ! an 1.245 ToolBar.-sep6- ! an 1.250 ToolBar.Make :make ! an 1.260 ToolBar.Shell :sh ! an 1.270 ToolBar.RunCtags :!ctags -R . ! an 1.280 ToolBar.TagJump g] ! ! an 1.295 ToolBar.-sep7- ! an 1.300 ToolBar.Help :help ! an 1.310 ToolBar.FindHelp :call Helpfind() " Only set the tooltips here if not done in a language menu file if exists("*Do_toolbar_tmenu") *************** *** 862,870 **** " Define these items always, so that syntax can be switched on when it wasn't. " But skip them when the Syntax menu was disabled by the user. if !exists("did_install_syntax_menu") ! am 50.212 &Syntax.&Manual :syn manual ! am 50.214 &Syntax.A&utomatic :syn on ! am 50.216 &Syntax.on/off\ for\ &This\ file :call SynOnOff() if !exists("*s:SynOnOff") fun s:SynOnOff() if has("syntax_items") --- 871,879 ---- " Define these items always, so that syntax can be switched on when it wasn't. " But skip them when the Syntax menu was disabled by the user. if !exists("did_install_syntax_menu") ! an 50.212 &Syntax.&Manual :syn manual ! an 50.214 &Syntax.A&utomatic :syn on ! an 50.216 &Syntax.on/off\ for\ &This\ file :call SynOnOff() if !exists("*s:SynOnOff") fun s:SynOnOff() if has("syntax_items") *************** *** 914,1243 **** " The following menu items are generated by makemenu.vim. " The Start Of The Syntax Menu ! am 50.10.100 &Syntax.AB.Abaqus :cal SetSyn("abaqus") ! am 50.10.110 &Syntax.AB.ABC :cal SetSyn("abc") ! am 50.10.120 &Syntax.AB.ABEL :cal SetSyn("abel") ! am 50.10.130 &Syntax.AB.Ada :cal SetSyn("ada") ! am 50.10.140 &Syntax.AB.Aflex :cal SetSyn("aflex") ! am 50.10.150 &Syntax.AB.AHDL :cal SetSyn("ahdl") ! am 50.10.160 &Syntax.AB.Amiga\ DOS :cal SetSyn("amiga") ! am 50.10.170 &Syntax.AB.Antlr :cal SetSyn("antlr") ! am 50.10.180 &Syntax.AB.Apache\ config :cal SetSyn("apache") ! am 50.10.190 &Syntax.AB.Apache-style\ config :cal SetSyn("apachestyle") ! am 50.10.200 &Syntax.AB.Applix\ ELF :cal SetSyn("elf") ! am 50.10.210 &Syntax.AB.Arc\ Macro\ Language :cal SetSyn("aml") ! am 50.10.220 &Syntax.AB.ASP\ with\ VBSages :cal SetSyn("aspvbs") ! am 50.10.230 &Syntax.AB.ASP\ with\ Perl :cal SetSyn("aspperl") ! am 50.10.240 &Syntax.AB.Assembly.680x0 :cal SetSyn("asm68k") ! am 50.10.250 &Syntax.AB.Assembly.GNU :cal SetSyn("asm") ! am 50.10.260 &Syntax.AB.Assembly.H8300 :cal SetSyn("asmh8300") ! am 50.10.270 &Syntax.AB.Assembly.Intel\ Itanium :cal SetSyn("ia64") ! am 50.10.280 &Syntax.AB.Assembly.Microsoft :cal SetSyn("masm") ! am 50.10.290 &Syntax.AB.Assembly.Netwide :cal SetSyn("nasm") ! am 50.10.300 &Syntax.AB.Assembly.PIC :cal SetSyn("pic") ! am 50.10.310 &Syntax.AB.Assembly.Turbo :cal SetSyn("tasm") ! am 50.10.320 &Syntax.AB.Assembly.Z-80 :cal SetSyn("z8a") ! am 50.10.330 &Syntax.AB.ASN\.1 :cal SetSyn("asn") ! am 50.10.340 &Syntax.AB.Atlas :cal SetSyn("atlas") ! am 50.10.350 &Syntax.AB.Automake :cal SetSyn("automake") ! am 50.10.360 &Syntax.AB.Avenue :cal SetSyn("ave") ! am 50.10.370 &Syntax.AB.Awk :cal SetSyn("awk") ! am 50.10.380 &Syntax.AB.Ayacc :cal SetSyn("ayacc") ! am 50.10.400 &Syntax.AB.B :cal SetSyn("b") ! am 50.10.410 &Syntax.AB.BASIC :cal SetSyn("basic") ! am 50.10.420 &Syntax.AB.BC\ calculator :cal SetSyn("bc") ! am 50.10.430 &Syntax.AB.BDF\ font :cal SetSyn("bdf") ! am 50.10.440 &Syntax.AB.BibFile :cal SetSyn("bib") ! am 50.10.450 &Syntax.AB.BIND\ configuration :cal SetSyn("named") ! am 50.10.460 &Syntax.AB.BIND\ zone :cal SetSyn("bindzone") ! am 50.10.470 &Syntax.AB.Blank :cal SetSyn("blank") ! am 50.20.100 &Syntax.CD.C :cal SetSyn("c") ! am 50.20.110 &Syntax.CD.C++ :cal SetSyn("cpp") ! am 50.20.120 &Syntax.CD.Crontab :cal SetSyn("crontab") ! am 50.20.130 &Syntax.CD.Cyn++ :cal SetSyn("cynpp") ! am 50.20.140 &Syntax.CD.Cynlib :cal SetSyn("cynlib") ! am 50.20.150 &Syntax.CD.Cascading\ Style\ Sheets :cal SetSyn("css") ! am 50.20.160 &Syntax.CD.Century\ Term :cal SetSyn("cterm") ! am 50.20.170 &Syntax.CD.CFG :cal SetSyn("cfg") ! am 50.20.180 &Syntax.CD.CHILL :cal SetSyn("ch") ! am 50.20.190 &Syntax.CD.Change :cal SetSyn("change") ! am 50.20.200 &Syntax.CD.ChangeLog :cal SetSyn("changelog") ! am 50.20.210 &Syntax.CD.Clean :cal SetSyn("clean") ! am 50.20.220 &Syntax.CD.Clever :cal SetSyn("cl") ! am 50.20.230 &Syntax.CD.Clipper :cal SetSyn("clipper") ! am 50.20.240 &Syntax.CD.Cold\ Fusion :cal SetSyn("cf") ! am 50.20.250 &Syntax.CD.Configure\ script :cal SetSyn("config") ! am 50.20.260 &Syntax.CD.Csh\ shell\ script :cal SetSyn("csh") ! am 50.20.270 &Syntax.CD.Ctrl-H :cal SetSyn("ctrlh") ! am 50.20.280 &Syntax.CD.Cobol :cal SetSyn("cobol") ! am 50.20.290 &Syntax.CD.CSP :cal SetSyn("csp") ! am 50.20.300 &Syntax.CD.CUPL.CUPL :cal SetSyn("cupl") ! am 50.20.310 &Syntax.CD.CUPL.simulation :cal SetSyn("cuplsim") ! am 50.20.320 &Syntax.CD.CVS\ commit :cal SetSyn("cvs") ! am 50.20.330 &Syntax.CD.CWEB :cal SetSyn("cweb") ! am 50.20.350 &Syntax.CD.Debian.Debian\ ChangeLog :cal SetSyn("debchangelog") ! am 50.20.360 &Syntax.CD.Debian.Debian\ Control :cal SetSyn("debcontrol") ! am 50.20.370 &Syntax.CD.Diff :cal SetSyn("diff") ! am 50.20.380 &Syntax.CD.Digital\ Command\ Lang :cal SetSyn("dcl") ! am 50.20.390 &Syntax.CD.Diva\ (with\ SKILL) :cal SetSyn("diva") ! am 50.20.400 &Syntax.CD.DNS :cal SetSyn("dns") ! am 50.20.410 &Syntax.CD.DOT :cal SetSyn("dto") ! am 50.20.420 &Syntax.CD.Dracula :cal SetSyn("dracula") ! am 50.20.430 &Syntax.CD.DSSSL :cal SetSyn("dsl") ! am 50.20.440 &Syntax.CD.DTD :cal SetSyn("dtd") ! am 50.20.450 &Syntax.CD.DTML\ (Zope) :cal SetSyn("dtml") ! am 50.20.460 &Syntax.CD.Dylan.Dylan :cal SetSyn("dylan") ! am 50.20.470 &Syntax.CD.Dylan.Dylan\ intr :cal SetSyn("dylanintr") ! am 50.20.480 &Syntax.CD.Dylan.Dylan\ lid :cal SetSyn("dylanlid") ! am 50.30.100 &Syntax.EFG.Eiffel :cal SetSyn("eiffel") ! am 50.30.110 &Syntax.EFG.Elm\ Filter :cal SetSyn("elmfilt") ! am 50.30.120 &Syntax.EFG.Embedix\ Component\ Description :cal SetSyn("ecd") ! am 50.30.130 &Syntax.EFG.ERicsson\ LANGuage :cal SetSyn("erlang") ! am 50.30.140 &Syntax.EFG.ESQL-C :cal SetSyn("esqlc") ! am 50.30.150 &Syntax.EFG.Eterm\ config :cal SetSyn("eterm") ! am 50.30.160 &Syntax.EFG.Expect :cal SetSyn("expect") ! am 50.30.170 &Syntax.EFG.Exports :cal SetSyn("exports") ! am 50.30.190 &Syntax.EFG.Focus\ Executable :cal SetSyn("focexec") ! am 50.30.200 &Syntax.EFG.Focus\ Master :cal SetSyn("master") ! am 50.30.210 &Syntax.EFG.FORM :cal SetSyn("form") ! am 50.30.220 &Syntax.EFG.Forth :cal SetSyn("forth") ! am 50.30.230 &Syntax.EFG.Fortran :cal SetSyn("fortran") ! am 50.30.240 &Syntax.EFG.FoxPro :cal SetSyn("foxpro") ! am 50.30.250 &Syntax.EFG.Fvwm\ configuration :cal SetSyn("fvwm1") ! am 50.30.260 &Syntax.EFG.Fvwm2\ configuration :cal SetSyn("fvwm2") ! am 50.30.280 &Syntax.EFG.GDB\ command\ file :cal SetSyn("gdb") ! am 50.30.290 &Syntax.EFG.GDMO :cal SetSyn("gdmo") ! am 50.30.300 &Syntax.EFG.Gedcom :cal SetSyn("gedcom") ! am 50.30.310 &Syntax.EFG.GP :cal SetSyn("gp") ! am 50.30.320 &Syntax.EFG.GNU\ Server\ Pages :cal SetSyn("gsp") ! am 50.30.330 &Syntax.EFG.GNUplot :cal SetSyn("gnuplot") ! am 50.30.340 &Syntax.EFG.GTKrc :cal SetSyn("gtkrc") ! am 50.40.100 &Syntax.HIJK.Haskell :cal SetSyn("haskell") ! am 50.40.110 &Syntax.HIJK.Haskell-literate :cal SetSyn("lhaskell") ! am 50.40.120 &Syntax.HIJK.Hercules :cal SetSyn("hercules") ! am 50.40.130 &Syntax.HIJK.HTML :cal SetSyn("html") ! am 50.40.140 &Syntax.HIJK.HTML\ with\ M4 :cal SetSyn("htmlm4") ! am 50.40.150 &Syntax.HIJK.HTML/OS :cal SetSyn("htmlos") ! am 50.40.160 &Syntax.HIJK.Hyper\ Builder :cal SetSyn("hb") ! am 50.40.180 &Syntax.HIJK.Icon :cal SetSyn("icon") ! am 50.40.190 &Syntax.HIJK.IDL :cal SetSyn("idl") ! am 50.40.200 &Syntax.HIJK.Indent\ profile :cal SetSyn("indent") ! am 50.40.210 &Syntax.HIJK.Inform :cal SetSyn("inform") ! am 50.40.220 &Syntax.HIJK.Informix\ 4GL :cal SetSyn("fgl") ! am 50.40.230 &Syntax.HIJK.Inittab :cal SetSyn("inittab") ! am 50.40.240 &Syntax.HIJK.Inno\ Setup :cal SetSyn("iss") ! am 50.40.250 &Syntax.HIJK.InstallShield\ Rules :cal SetSyn("ishd") ! am 50.40.260 &Syntax.HIJK.Interactive\ Data\ Lang :cal SetSyn("idlang") ! am 50.40.280 &Syntax.HIJK.Jam :cal SetSyn("jam") ! am 50.40.290 &Syntax.HIJK.Jargon :cal SetSyn("jargon") ! am 50.40.300 &Syntax.HIJK.Java.Java :cal SetSyn("java") ! am 50.40.310 &Syntax.HIJK.Java.JavaCC :cal SetSyn("javacc") ! am 50.40.320 &Syntax.HIJK.Java.Java\ Server\ Pages :cal SetSyn("jsp") ! am 50.40.330 &Syntax.HIJK.Java.Java\ Properties :cal SetSyn("jproperties") ! am 50.40.340 &Syntax.HIJK.JavaScript :cal SetSyn("javascript") ! am 50.40.350 &Syntax.HIJK.Jess :cal SetSyn("jess") ! am 50.40.360 &Syntax.HIJK.Jgraph :cal SetSyn("jgraph") ! am 50.40.380 &Syntax.HIJK.KDE\ script :cal SetSyn("kscript") ! am 50.40.390 &Syntax.HIJK.Kimwitu :cal SetSyn("kwt") ! am 50.40.400 &Syntax.HIJK.Kixtart :cal SetSyn("kix") ! am 50.50.100 &Syntax.L-Ma.Lace :cal SetSyn("lace") ! am 50.50.110 &Syntax.L-Ma.Lamda\ Prolog :cal SetSyn("lprolog") ! am 50.50.120 &Syntax.L-Ma.Latte :cal SetSyn("latte") ! am 50.50.130 &Syntax.L-Ma.Lex :cal SetSyn("lex") ! am 50.50.140 &Syntax.L-Ma.LFTP :cal SetSyn("lftp") ! am 50.50.150 &Syntax.L-Ma.Lilo :cal SetSyn("lilo") ! am 50.50.160 &Syntax.L-Ma.Lisp :cal SetSyn("lisp") ! am 50.50.170 &Syntax.L-Ma.Lite :cal SetSyn("lite") ! am 50.50.180 &Syntax.L-Ma.LOTOS :cal SetSyn("lotos") ! am 50.50.190 &Syntax.L-Ma.Lout :cal SetSyn("lout") ! am 50.50.200 &Syntax.L-Ma.Lua :cal SetSyn("lua") ! am 50.50.210 &Syntax.L-Ma.Lynx\ Style :cal SetSyn("lss") ! am 50.50.220 &Syntax.L-Ma.Lynx\ config :cal SetSyn("lynx") ! am 50.50.240 &Syntax.L-Ma.M4 :cal SetSyn("m4") ! am 50.50.250 &Syntax.L-Ma.MaGic\ Point :cal SetSyn("mgp") ! am 50.50.260 &Syntax.L-Ma.Mail :cal SetSyn("mail") ! am 50.50.270 &Syntax.L-Ma.Makefile :cal SetSyn("make") ! am 50.50.280 &Syntax.L-Ma.MakeIndex :cal SetSyn("ist") ! am 50.50.290 &Syntax.L-Ma.Man\ page :cal SetSyn("man") ! am 50.50.300 &Syntax.L-Ma.Maple :cal SetSyn("maple") ! am 50.50.310 &Syntax.L-Ma.Mason :cal SetSyn("mason") ! am 50.50.320 &Syntax.L-Ma.Mathematica :cal SetSyn("mma") ! am 50.50.330 &Syntax.L-Ma.Matlab :cal SetSyn("matlab") ! am 50.60.100 &Syntax.Me-NO.MEL\ (for\ Maya) :cal SetSyn("mel") ! am 50.60.110 &Syntax.Me-NO.Metafont :cal SetSyn("mf") ! am 50.60.120 &Syntax.Me-NO.MetaPost :cal SetSyn("mp") ! am 50.60.130 &Syntax.Me-NO.MS\ Module\ Definition :cal SetSyn("def") ! am 50.60.140 &Syntax.Me-NO.Model :cal SetSyn("model") ! am 50.60.150 &Syntax.Me-NO.Modsim\ III :cal SetSyn("modsim3") ! am 50.60.160 &Syntax.Me-NO.Modula\ 2 :cal SetSyn("modula2") ! am 50.60.170 &Syntax.Me-NO.Modula\ 3 :cal SetSyn("modula3") ! am 50.60.180 &Syntax.Me-NO.Msql :cal SetSyn("msql") ! am 50.60.190 &Syntax.Me-NO.MS-DOS.MS-DOS\ \.bat\ file :cal SetSyn("dosbatch") ! am 50.60.200 &Syntax.Me-NO.MS-DOS.4DOS\ \.bat\ file :cal SetSyn("btm") ! am 50.60.210 &Syntax.Me-NO.MS-DOS.MS-DOS\ \.ini\ file :cal SetSyn("dosini") ! am 50.60.220 &Syntax.Me-NO.MS\ Resource\ file :cal SetSyn("rc") ! am 50.60.230 &Syntax.Me-NO.Mush :cal SetSyn("mush") ! am 50.60.240 &Syntax.Me-NO.Muttrc :cal SetSyn("muttrc") ! am 50.60.260 &Syntax.Me-NO.Nastran\ input/DMAP :cal SetSyn("nastran") ! am 50.60.270 &Syntax.Me-NO.Natural :cal SetSyn("natural") ! am 50.60.280 &Syntax.Me-NO.Novell\ batch :cal SetSyn("ncf") ! am 50.60.290 &Syntax.Me-NO.Not\ Quite\ C :cal SetSyn("nqc") ! am 50.60.300 &Syntax.Me-NO.Nroff :cal SetSyn("nroff") ! am 50.60.320 &Syntax.Me-NO.Objective\ C :cal SetSyn("objc") ! am 50.60.330 &Syntax.Me-NO.OCAML :cal SetSyn("ocaml") ! am 50.60.340 &Syntax.Me-NO.Omnimark :cal SetSyn("omnimark") ! am 50.60.350 &Syntax.Me-NO.OpenROAD :cal SetSyn("openroad") ! am 50.60.360 &Syntax.Me-NO.Open\ Psion\ Lang :cal SetSyn("opl") ! am 50.60.370 &Syntax.Me-NO.Oracle\ config :cal SetSyn("ora") ! am 50.70.100 &Syntax.PQ.Palm\ resource\ compiler :cal SetSyn("pilrc") ! am 50.70.110 &Syntax.PQ.PApp :cal SetSyn("papp") ! am 50.70.120 &Syntax.PQ.Pascal :cal SetSyn("pascal") ! am 50.70.130 &Syntax.PQ.PCCTS :cal SetSyn("pccts") ! am 50.70.140 &Syntax.PQ.PPWizard :cal SetSyn("ppwiz") ! am 50.70.150 &Syntax.PQ.Perl.Perl :cal SetSyn("perl") ! am 50.70.160 &Syntax.PQ.Perl.Perl\ POD :cal SetSyn("pod") ! am 50.70.170 &Syntax.PQ.Perl.Perl\ XS :cal SetSyn("xs") ! am 50.70.180 &Syntax.PQ.PHP\ 3-4 :cal SetSyn("php") ! am 50.70.190 &Syntax.PQ.Phtml :cal SetSyn("phtml") ! am 50.70.200 &Syntax.PQ.Pike :cal SetSyn("pike") ! am 50.70.210 &Syntax.PQ.Pine\ RC :cal SetSyn("pine") ! am 50.70.220 &Syntax.PQ.PL/M :cal SetSyn("plm") ! am 50.70.230 &Syntax.PQ.PL/SQL :cal SetSyn("plsql") ! am 50.70.240 &Syntax.PQ.PO\ (GNU\ gettext) :cal SetSyn("po") ! am 50.70.250 &Syntax.PQ.Postfix\ main\ config :cal SetSyn("pfmain") ! am 50.70.260 &Syntax.PQ.PostScript :cal SetSyn("postscr") ! am 50.70.270 &Syntax.PQ.Povray :cal SetSyn("pov") ! am 50.70.280 &Syntax.PQ.Povray\ configuration :cal SetSyn("povini") ! am 50.70.290 &Syntax.PQ.Printcap :cal SetSyn("pcap") ! am 50.70.300 &Syntax.PQ.Procmail :cal SetSyn("procmail") ! am 50.70.310 &Syntax.PQ.Product\ Spec\ File :cal SetSyn("psf") ! am 50.70.320 &Syntax.PQ.Progress :cal SetSyn("progress") ! am 50.70.330 &Syntax.PQ.Prolog :cal SetSyn("prolog") ! am 50.70.340 &Syntax.PQ.Purify\ log :cal SetSyn("purifylog") ! am 50.70.350 &Syntax.PQ.Python :cal SetSyn("python") ! am 50.80.100 &Syntax.R-Sg.R :cal SetSyn("r") ! am 50.80.110 &Syntax.R-Sg.Radiance :cal SetSyn("radiance") ! am 50.80.120 &Syntax.R-Sg.Ratpoison :cal SetSyn("ratpoison") ! am 50.80.130 &Syntax.R-Sg.Readline\ config :cal SetSyn("readline") ! am 50.80.140 &Syntax.R-Sg.RCS\ log\ output :cal SetSyn("rcslog") ! am 50.80.150 &Syntax.R-Sg.Rebol :cal SetSyn("rebol") ! am 50.80.160 &Syntax.R-Sg.Registry\ of\ MS-Windows :cal SetSyn("registry") ! am 50.80.170 &Syntax.R-Sg.Remind :cal SetSyn("remind") ! am 50.80.180 &Syntax.R-Sg.Renderman\ Shader\ Lang :cal SetSyn("sl") ! am 50.80.190 &Syntax.R-Sg.Rexx :cal SetSyn("rexx") ! am 50.80.200 &Syntax.R-Sg.Robots\.txt :cal SetSyn("robots") ! am 50.80.210 &Syntax.R-Sg.Rpcgen :cal SetSyn("rpcgen") ! am 50.80.220 &Syntax.R-Sg.RTF :cal SetSyn("rtf") ! am 50.80.230 &Syntax.R-Sg.Ruby :cal SetSyn("ruby") ! am 50.80.250 &Syntax.R-Sg.S-lang :cal SetSyn("slang") ! am 50.80.260 &Syntax.R-Sg.Samba\ config :cal SetSyn("samba") ! am 50.80.270 &Syntax.R-Sg.SAS :cal SetSyn("sas") ! am 50.80.280 &Syntax.R-Sg.Sather :cal SetSyn("sather") ! am 50.80.290 &Syntax.R-Sg.Scheme :cal SetSyn("scheme") ! am 50.80.300 &Syntax.R-Sg.Screen\ RC :cal SetSyn("screen") ! am 50.80.310 &Syntax.R-Sg.SDL :cal SetSyn("sdl") ! am 50.80.320 &Syntax.R-Sg.Sed :cal SetSyn("sed") ! am 50.80.330 &Syntax.R-Sg.Sendmail\.cf :cal SetSyn("sm") ! am 50.80.340 &Syntax.R-Sg.SGML.SGML\ catalog :cal SetSyn("catalog") ! am 50.80.350 &Syntax.R-Sg.SGML.SGML\ DTD :cal SetSyn("sgml") ! am 50.80.360 &Syntax.R-Sg.SGML.SGML\ Declarations :cal SetSyn("sgmldecl") ! am 50.80.370 &Syntax.R-Sg.SGML.SGML\ linuxdoc :cal SetSyn("sgmllnx") ! am 50.90.100 &Syntax.Sh-S.Sh\ shell\ script :cal SetSyn("sh") ! am 50.90.110 &Syntax.Sh-S.SiCAD :cal SetSyn("sicad") ! am 50.90.120 &Syntax.Sh-S.Simula :cal SetSyn("simula") ! am 50.90.130 &Syntax.Sh-S.Sinda.Sinda\ compare :cal SetSyn("sindacmp") ! am 50.90.140 &Syntax.Sh-S.Sinda.Sinda\ input :cal SetSyn("sinda") ! am 50.90.150 &Syntax.Sh-S.Sinda.Sinda\ output :cal SetSyn("sindaout") ! am 50.90.160 &Syntax.Sh-S.SKILL :cal SetSyn("skill") ! am 50.90.170 &Syntax.Sh-S.SLRN.SLRN\ rc :cal SetSyn("slrnrc") ! am 50.90.180 &Syntax.Sh-S.SLRN.SLRN\ score :cal SetSyn("slrnsc") ! am 50.90.190 &Syntax.Sh-S.SmallTalk :cal SetSyn("st") ! am 50.90.200 &Syntax.Sh-S.SMIL :cal SetSyn("smil") ! am 50.90.210 &Syntax.Sh-S.SMITH :cal SetSyn("smith") ! am 50.90.220 &Syntax.Sh-S.SNMP\ MIB :cal SetSyn("mib") ! am 50.90.230 &Syntax.Sh-S.SNNS.SNNS\ network :cal SetSyn("snnsnet") ! am 50.90.240 &Syntax.Sh-S.SNNS.SNNS\ pattern :cal SetSyn("snnspat") ! am 50.90.250 &Syntax.Sh-S.SNNS.SNNS\ result :cal SetSyn("snnsres") ! am 50.90.260 &Syntax.Sh-S.Snobol4 :cal SetSyn("snobol4") ! am 50.90.270 &Syntax.Sh-S.Snort\ Configuration :cal SetSyn("hog") ! am 50.90.280 &Syntax.Sh-S.SPEC\ (Linux\ RPM) :cal SetSyn("spec") ! am 50.90.290 &Syntax.Sh-S.Specman :cal SetSyn("specman") ! am 50.90.300 &Syntax.Sh-S.Spice :cal SetSyn("spice") ! am 50.90.310 &Syntax.Sh-S.Speedup :cal SetSyn("spup") ! am 50.90.320 &Syntax.Sh-S.Squid :cal SetSyn("squid") ! am 50.90.330 &Syntax.Sh-S.SQL :cal SetSyn("sql") ! am 50.90.340 &Syntax.Sh-S.SQL\ Forms :cal SetSyn("sqlforms") ! am 50.90.350 &Syntax.Sh-S.SQR :cal SetSyn("sqr") ! am 50.90.360 &Syntax.Sh-S.Standard\ ML :cal SetSyn("sml") ! am 50.90.370 &Syntax.Sh-S.Stored\ Procedures :cal SetSyn("stp") ! am 50.90.380 &Syntax.Sh-S.Strace :cal SetSyn("strace") ! am 50.100.100 &Syntax.TUV.Tads :cal SetSyn("tads") ! am 50.100.110 &Syntax.TUV.Tags :cal SetSyn("tags") ! am 50.100.120 &Syntax.TUV.TAK.TAK\ compare :cal SetSyn("tak") ! am 50.100.130 &Syntax.TUV.TAK.TAK\ input :cal SetSyn("tak") ! am 50.100.140 &Syntax.TUV.TAK.TAK\ output :cal SetSyn("takout") ! am 50.100.150 &Syntax.TUV.Tcl/Tk :cal SetSyn("tcl") ! am 50.100.160 &Syntax.TUV.TealInfo :cal SetSyn("tli") ! am 50.100.170 &Syntax.TUV.Telix\ Salt :cal SetSyn("tsalt") ! am 50.100.180 &Syntax.TUV.Termcap :cal SetSyn("ptcap") ! am 50.100.190 &Syntax.TUV.Terminfo :cal SetSyn("terminfo") ! am 50.100.200 &Syntax.TUV.TeX :cal SetSyn("tex") ! am 50.100.210 &Syntax.TUV.TeX\ configuration :cal SetSyn("texmf") ! am 50.100.220 &Syntax.TUV.Texinfo :cal SetSyn("texinfo") ! am 50.100.230 &Syntax.TUV.TF\ mud\ client :cal SetSyn("tf") ! am 50.100.240 &Syntax.TUV.Tidy\ configuration :cal SetSyn("tidy") ! am 50.100.250 &Syntax.TUV.Trasys\ input :cal SetSyn("trasys") ! am 50.100.260 &Syntax.TUV.TSS.Command\ Line :cal SetSyn("tsscl") ! am 50.100.270 &Syntax.TUV.TSS.Geometry :cal SetSyn("tssgm") ! am 50.100.280 &Syntax.TUV.TSS.Optics :cal SetSyn("tssop") ! am 50.100.300 &Syntax.TUV.UIT/UIL :cal SetSyn("uil") ! am 50.100.310 &Syntax.TUV.UnrealScript :cal SetSyn("uc") ! am 50.100.330 &Syntax.TUV.Verilog\ HDL :cal SetSyn("verilog") ! am 50.100.340 &Syntax.TUV.Vgrindefs :cal SetSyn("vgrindefs") ! am 50.100.350 &Syntax.TUV.VHDL :cal SetSyn("vhdl") ! am 50.100.360 &Syntax.TUV.Vim.Vim\ help\ file :cal SetSyn("help") ! am 50.100.370 &Syntax.TUV.Vim.Vim\ script :cal SetSyn("vim") ! am 50.100.380 &Syntax.TUV.Vim.Viminfo\ file :cal SetSyn("viminfo") ! am 50.100.390 &Syntax.TUV.Virata :cal SetSyn("virata") ! am 50.100.400 &Syntax.TUV.Visual\ Basic :cal SetSyn("vb") ! am 50.100.410 &Syntax.TUV.VRML :cal SetSyn("vrml") ! am 50.100.420 &Syntax.TUV.VSE\ JCL :cal SetSyn("vsejcl") ! am 50.110.100 &Syntax.WXYZ.WEB :cal SetSyn("web") ! am 50.110.110 &Syntax.WXYZ.Webmacro :cal SetSyn("webmacro") ! am 50.110.120 &Syntax.WXYZ.Website\ MetaLanguage :cal SetSyn("wml") ! am 50.110.130 &Syntax.WXYZ.Wdiff :cal SetSyn("wdiff") ! am 50.110.140 &Syntax.WXYZ.Wget\ config :cal SetSyn("wget") ! am 50.110.150 &Syntax.WXYZ.Whitespace\ (add) :cal SetSyn("whitespace") ! am 50.110.160 &Syntax.WXYZ.WinBatch/Webbatch :cal SetSyn("winbatch") ! am 50.110.170 &Syntax.WXYZ.Windows\ Scripting\ Host :cal SetSyn("wsh") ! am 50.110.190 &Syntax.WXYZ.X\ Keyboard\ Extension :cal SetSyn("xkb") ! am 50.110.200 &Syntax.WXYZ.X\ Pixmap :cal SetSyn("xpm") ! am 50.110.210 &Syntax.WXYZ.X\ Pixmap\ (2) :cal SetSyn("xpm2") ! am 50.110.220 &Syntax.WXYZ.X\ resources :cal SetSyn("xdefaults") ! am 50.110.230 &Syntax.WXYZ.Xmath :cal SetSyn("xmath") ! am 50.110.240 &Syntax.WXYZ.XML :cal SetSyn("xml") ! am 50.110.250 &Syntax.WXYZ.XXD\ hex\ dump :cal SetSyn("xxd") ! am 50.110.270 &Syntax.WXYZ.Yacc :cal SetSyn("yacc") ! am 50.110.290 &Syntax.WXYZ.Zsh\ shell\ script :cal SetSyn("zsh") " The End Of The Syntax Menu ! am 50.195 &Syntax.-SEP1- : ! am 50.200 &Syntax.Set\ '&syntax'\ only :let s:syntax_menu_synonly=1 ! am 50.202 &Syntax.Set\ '&filetype'\ too :call Nosynonly() fun! s:Nosynonly() if exists("s:syntax_menu_synonly") unlet s:syntax_menu_synonly endif endfun ! am 50.210 &Syntax.&Off :syn off ! am 50.700 &Syntax.-SEP3- : ! am 50.710 &Syntax.Co&lor\ test :sp $VIMRUNTIME/syntax/colortest.vimso % ! am 50.720 &Syntax.&Highlight\ test :so $VIMRUNTIME/syntax/hitest.vim ! am 50.730 &Syntax.&Convert\ to\ HTML :so $VIMRUNTIME/syntax/2html.vim endif " !exists("did_install_syntax_menu") --- 923,1261 ---- " The following menu items are generated by makemenu.vim. " The Start Of The Syntax Menu ! an 50.10.100 &Syntax.AB.Abaqus :cal SetSyn("abaqus") ! an 50.10.110 &Syntax.AB.ABC :cal SetSyn("abc") ! an 50.10.120 &Syntax.AB.ABEL :cal SetSyn("abel") ! an 50.10.130 &Syntax.AB.Ada :cal SetSyn("ada") ! an 50.10.140 &Syntax.AB.Aflex :cal SetSyn("aflex") ! an 50.10.150 &Syntax.AB.AHDL :cal SetSyn("ahdl") ! an 50.10.160 &Syntax.AB.Amiga\ DOS :cal SetSyn("amiga") ! an 50.10.170 &Syntax.AB.Ant :cal SetSyn("ant") ! an 50.10.180 &Syntax.AB.Antlr :cal SetSyn("antlr") ! an 50.10.190 &Syntax.AB.Apache\ config :cal SetSyn("apache") ! an 50.10.200 &Syntax.AB.Apache-style\ config :cal SetSyn("apachestyle") ! an 50.10.210 &Syntax.AB.Applix\ ELF :cal SetSyn("elf") ! an 50.10.220 &Syntax.AB.Arc\ Macro\ Language :cal SetSyn("aml") ! an 50.10.230 &Syntax.AB.ASP\ with\ VBSages :cal SetSyn("aspvbs") ! an 50.10.240 &Syntax.AB.ASP\ with\ Perl :cal SetSyn("aspperl") ! an 50.10.250 &Syntax.AB.Assembly.680x0 :cal SetSyn("asm68k") ! an 50.10.260 &Syntax.AB.Assembly.GNU :cal SetSyn("asm") ! an 50.10.270 &Syntax.AB.Assembly.H8300 :cal SetSyn("asmh8300") ! an 50.10.280 &Syntax.AB.Assembly.Intel\ Itanium :cal SetSyn("ia64") ! an 50.10.290 &Syntax.AB.Assembly.Microsoft :cal SetSyn("masm") ! an 50.10.300 &Syntax.AB.Assembly.Netwide :cal SetSyn("nasm") ! an 50.10.310 &Syntax.AB.Assembly.PIC :cal SetSyn("pic") ! an 50.10.320 &Syntax.AB.Assembly.Turbo :cal SetSyn("tasm") ! an 50.10.330 &Syntax.AB.Assembly.Z-80 :cal SetSyn("z8a") ! an 50.10.340 &Syntax.AB.ASN\.1 :cal SetSyn("asn") ! an 50.10.350 &Syntax.AB.Atlas :cal SetSyn("atlas") ! an 50.10.360 &Syntax.AB.Automake :cal SetSyn("automake") ! an 50.10.370 &Syntax.AB.Avenue :cal SetSyn("ave") ! an 50.10.380 &Syntax.AB.Awk :cal SetSyn("awk") ! an 50.10.390 &Syntax.AB.Ayacc :cal SetSyn("ayacc") ! an 50.10.410 &Syntax.AB.B :cal SetSyn("b") ! an 50.10.420 &Syntax.AB.Baan :cal SetSyn("baan") ! an 50.10.430 &Syntax.AB.BASIC :cal SetSyn("basic") ! an 50.10.440 &Syntax.AB.BC\ calculator :cal SetSyn("bc") ! an 50.10.450 &Syntax.AB.BDF\ font :cal SetSyn("bdf") ! an 50.10.460 &Syntax.AB.BibFile :cal SetSyn("bib") ! an 50.10.470 &Syntax.AB.BIND\ configuration :cal SetSyn("named") ! an 50.10.480 &Syntax.AB.BIND\ zone :cal SetSyn("bindzone") ! an 50.10.490 &Syntax.AB.Blank :cal SetSyn("blank") ! an 50.20.100 &Syntax.CD.C :cal SetSyn("c") ! an 50.20.110 &Syntax.CD.C++ :cal SetSyn("cpp") ! an 50.20.120 &Syntax.CD.Crontab :cal SetSyn("crontab") ! an 50.20.130 &Syntax.CD.Cyn++ :cal SetSyn("cynpp") ! an 50.20.140 &Syntax.CD.Cynlib :cal SetSyn("cynlib") ! an 50.20.150 &Syntax.CD.Cascading\ Style\ Sheets :cal SetSyn("css") ! an 50.20.160 &Syntax.CD.Century\ Term :cal SetSyn("cterm") ! an 50.20.170 &Syntax.CD.CFG :cal SetSyn("cfg") ! an 50.20.180 &Syntax.CD.CHILL :cal SetSyn("ch") ! an 50.20.190 &Syntax.CD.Change :cal SetSyn("change") ! an 50.20.200 &Syntax.CD.ChangeLog :cal SetSyn("changelog") ! an 50.20.210 &Syntax.CD.Clean :cal SetSyn("clean") ! an 50.20.220 &Syntax.CD.Clever :cal SetSyn("cl") ! an 50.20.230 &Syntax.CD.Clipper :cal SetSyn("clipper") ! an 50.20.240 &Syntax.CD.Cold\ Fusion :cal SetSyn("cf") ! an 50.20.250 &Syntax.CD.Configure\ script :cal SetSyn("config") ! an 50.20.260 &Syntax.CD.Csh\ shell\ script :cal SetSyn("csh") ! an 50.20.270 &Syntax.CD.Ctrl-H :cal SetSyn("ctrlh") ! an 50.20.280 &Syntax.CD.Cobol :cal SetSyn("cobol") ! an 50.20.290 &Syntax.CD.CSP :cal SetSyn("csp") ! an 50.20.300 &Syntax.CD.CUPL.CUPL :cal SetSyn("cupl") ! an 50.20.310 &Syntax.CD.CUPL.simulation :cal SetSyn("cuplsim") ! an 50.20.320 &Syntax.CD.CVS\ commit :cal SetSyn("cvs") ! an 50.20.330 &Syntax.CD.CWEB :cal SetSyn("cweb") ! an 50.20.350 &Syntax.CD.Debian.Debian\ ChangeLog :cal SetSyn("debchangelog") ! an 50.20.360 &Syntax.CD.Debian.Debian\ Control :cal SetSyn("debcontrol") ! an 50.20.370 &Syntax.CD.Diff :cal SetSyn("diff") ! an 50.20.380 &Syntax.CD.Digital\ Command\ Lang :cal SetSyn("dcl") ! an 50.20.390 &Syntax.CD.Diva\ (with\ SKILL) :cal SetSyn("diva") ! an 50.20.400 &Syntax.CD.DNS :cal SetSyn("dns") ! an 50.20.410 &Syntax.CD.DOT :cal SetSyn("dto") ! an 50.20.420 &Syntax.CD.Dracula :cal SetSyn("dracula") ! an 50.20.430 &Syntax.CD.DSSSL :cal SetSyn("dsl") ! an 50.20.440 &Syntax.CD.DTD :cal SetSyn("dtd") ! an 50.20.450 &Syntax.CD.DTML\ (Zope) :cal SetSyn("dtml") ! an 50.20.460 &Syntax.CD.Dylan.Dylan :cal SetSyn("dylan") ! an 50.20.470 &Syntax.CD.Dylan.Dylan\ intr :cal SetSyn("dylanintr") ! an 50.20.480 &Syntax.CD.Dylan.Dylan\ lid :cal SetSyn("dylanlid") ! an 50.30.100 &Syntax.EFG.Eiffel :cal SetSyn("eiffel") ! an 50.30.110 &Syntax.EFG.Elm\ Filter :cal SetSyn("elmfilt") ! an 50.30.120 &Syntax.EFG.Embedix\ Component\ Description :cal SetSyn("ecd") ! an 50.30.130 &Syntax.EFG.ERicsson\ LANGuage :cal SetSyn("erlang") ! an 50.30.140 &Syntax.EFG.ESQL-C :cal SetSyn("esqlc") ! an 50.30.150 &Syntax.EFG.Eterm\ config :cal SetSyn("eterm") ! an 50.30.160 &Syntax.EFG.Expect :cal SetSyn("expect") ! an 50.30.170 &Syntax.EFG.Exports :cal SetSyn("exports") ! an 50.30.190 &Syntax.EFG.Focus\ Executable :cal SetSyn("focexec") ! an 50.30.200 &Syntax.EFG.Focus\ Master :cal SetSyn("master") ! an 50.30.210 &Syntax.EFG.FORM :cal SetSyn("form") ! an 50.30.220 &Syntax.EFG.Forth :cal SetSyn("forth") ! an 50.30.230 &Syntax.EFG.Fortran :cal SetSyn("fortran") ! an 50.30.240 &Syntax.EFG.FoxPro :cal SetSyn("foxpro") ! an 50.30.250 &Syntax.EFG.Fvwm\ configuration :cal SetSyn("fvwm1") ! an 50.30.260 &Syntax.EFG.Fvwm2\ configuration :cal SetSyn("fvwm2") ! an 50.30.280 &Syntax.EFG.GDB\ command\ file :cal SetSyn("gdb") ! an 50.30.290 &Syntax.EFG.GDMO :cal SetSyn("gdmo") ! an 50.30.300 &Syntax.EFG.Gedcom :cal SetSyn("gedcom") ! an 50.30.310 &Syntax.EFG.GP :cal SetSyn("gp") ! an 50.30.320 &Syntax.EFG.GNU\ Server\ Pages :cal SetSyn("gsp") ! an 50.30.330 &Syntax.EFG.GNUplot :cal SetSyn("gnuplot") ! an 50.30.340 &Syntax.EFG.GTKrc :cal SetSyn("gtkrc") ! an 50.40.100 &Syntax.HIJK.Haskell.Haskell :cal SetSyn("haskell") ! an 50.40.110 &Syntax.HIJK.Haskell.Haskell-c2hs :cal SetSyn("chaskell") ! an 50.40.120 &Syntax.HIJK.Haskell.Haskell-literate :cal SetSyn("lhaskell") ! an 50.40.130 &Syntax.HIJK.Hercules :cal SetSyn("hercules") ! an 50.40.140 &Syntax.HIJK.HTML :cal SetSyn("html") ! an 50.40.150 &Syntax.HIJK.HTML\ with\ M4 :cal SetSyn("htmlm4") ! an 50.40.160 &Syntax.HIJK.HTML/OS :cal SetSyn("htmlos") ! an 50.40.170 &Syntax.HIJK.Hyper\ Builder :cal SetSyn("hb") ! an 50.40.190 &Syntax.HIJK.Icon :cal SetSyn("icon") ! an 50.40.200 &Syntax.HIJK.IDL :cal SetSyn("idl") ! an 50.40.210 &Syntax.HIJK.Indent\ profile :cal SetSyn("indent") ! an 50.40.220 &Syntax.HIJK.Inform :cal SetSyn("inform") ! an 50.40.230 &Syntax.HIJK.Informix\ 4GL :cal SetSyn("fgl") ! an 50.40.240 &Syntax.HIJK.Inittab :cal SetSyn("inittab") ! an 50.40.250 &Syntax.HIJK.Inno\ Setup :cal SetSyn("iss") ! an 50.40.260 &Syntax.HIJK.InstallShield\ Rules :cal SetSyn("ishd") ! an 50.40.270 &Syntax.HIJK.Interactive\ Data\ Lang :cal SetSyn("idlang") ! an 50.40.290 &Syntax.HIJK.Jam :cal SetSyn("jam") ! an 50.40.300 &Syntax.HIJK.Jargon :cal SetSyn("jargon") ! an 50.40.310 &Syntax.HIJK.Java.Java :cal SetSyn("java") ! an 50.40.320 &Syntax.HIJK.Java.JavaCC :cal SetSyn("javacc") ! an 50.40.330 &Syntax.HIJK.Java.Java\ Server\ Pages :cal SetSyn("jsp") ! an 50.40.340 &Syntax.HIJK.Java.Java\ Properties :cal SetSyn("jproperties") ! an 50.40.350 &Syntax.HIJK.JavaScript :cal SetSyn("javascript") ! an 50.40.360 &Syntax.HIJK.Jess :cal SetSyn("jess") ! an 50.40.370 &Syntax.HIJK.Jgraph :cal SetSyn("jgraph") ! an 50.40.390 &Syntax.HIJK.KDE\ script :cal SetSyn("kscript") ! an 50.40.400 &Syntax.HIJK.Kimwitu :cal SetSyn("kwt") ! an 50.40.410 &Syntax.HIJK.Kixtart :cal SetSyn("kix") ! an 50.50.100 &Syntax.L-Ma.Lace :cal SetSyn("lace") ! an 50.50.110 &Syntax.L-Ma.Lamda\ Prolog :cal SetSyn("lprolog") ! an 50.50.120 &Syntax.L-Ma.Latte :cal SetSyn("latte") ! an 50.50.130 &Syntax.L-Ma.Lex :cal SetSyn("lex") ! an 50.50.140 &Syntax.L-Ma.LFTP :cal SetSyn("lftp") ! an 50.50.150 &Syntax.L-Ma.Lilo :cal SetSyn("lilo") ! an 50.50.160 &Syntax.L-Ma.Lisp :cal SetSyn("lisp") ! an 50.50.170 &Syntax.L-Ma.Lite :cal SetSyn("lite") ! an 50.50.180 &Syntax.L-Ma.LOTOS :cal SetSyn("lotos") ! an 50.50.190 &Syntax.L-Ma.LotusScript :cal SetSyn("lscript") ! an 50.50.200 &Syntax.L-Ma.Lout :cal SetSyn("lout") ! an 50.50.210 &Syntax.L-Ma.Lua :cal SetSyn("lua") ! an 50.50.220 &Syntax.L-Ma.Lynx\ Style :cal SetSyn("lss") ! an 50.50.230 &Syntax.L-Ma.Lynx\ config :cal SetSyn("lynx") ! an 50.50.250 &Syntax.L-Ma.M4 :cal SetSyn("m4") ! an 50.50.260 &Syntax.L-Ma.MaGic\ Point :cal SetSyn("mgp") ! an 50.50.270 &Syntax.L-Ma.Mail :cal SetSyn("mail") ! an 50.50.280 &Syntax.L-Ma.Makefile :cal SetSyn("make") ! an 50.50.290 &Syntax.L-Ma.MakeIndex :cal SetSyn("ist") ! an 50.50.300 &Syntax.L-Ma.Man\ page :cal SetSyn("man") ! an 50.50.310 &Syntax.L-Ma.Maple :cal SetSyn("maple") ! an 50.50.320 &Syntax.L-Ma.Mason :cal SetSyn("mason") ! an 50.50.330 &Syntax.L-Ma.Mathematica :cal SetSyn("mma") ! an 50.50.340 &Syntax.L-Ma.Matlab :cal SetSyn("matlab") ! an 50.60.100 &Syntax.Me-NO.MEL\ (for\ Maya) :cal SetSyn("mel") ! an 50.60.110 &Syntax.Me-NO.Metafont :cal SetSyn("mf") ! an 50.60.120 &Syntax.Me-NO.MetaPost :cal SetSyn("mp") ! an 50.60.130 &Syntax.Me-NO.MS\ Module\ Definition :cal SetSyn("def") ! an 50.60.140 &Syntax.Me-NO.Model :cal SetSyn("model") ! an 50.60.150 &Syntax.Me-NO.Modsim\ III :cal SetSyn("modsim3") ! an 50.60.160 &Syntax.Me-NO.Modula\ 2 :cal SetSyn("modula2") ! an 50.60.170 &Syntax.Me-NO.Modula\ 3 :cal SetSyn("modula3") ! an 50.60.180 &Syntax.Me-NO.MOO :cal SetSyn("moo") ! an 50.60.190 &Syntax.Me-NO.Msql :cal SetSyn("msql") ! an 50.60.200 &Syntax.Me-NO.MS-DOS.MS-DOS\ \.bat\ file :cal SetSyn("dosbatch") ! an 50.60.210 &Syntax.Me-NO.MS-DOS.4DOS\ \.bat\ file :cal SetSyn("btm") ! an 50.60.220 &Syntax.Me-NO.MS-DOS.MS-DOS\ \.ini\ file :cal SetSyn("dosini") ! an 50.60.230 &Syntax.Me-NO.MS\ Resource\ file :cal SetSyn("rc") ! an 50.60.240 &Syntax.Me-NO.Mush :cal SetSyn("mush") ! an 50.60.250 &Syntax.Me-NO.Muttrc :cal SetSyn("muttrc") ! an 50.60.270 &Syntax.Me-NO.Nastran\ input/DMAP :cal SetSyn("nastran") ! an 50.60.280 &Syntax.Me-NO.Natural :cal SetSyn("natural") ! an 50.60.290 &Syntax.Me-NO.Novell\ batch :cal SetSyn("ncf") ! an 50.60.300 &Syntax.Me-NO.Not\ Quite\ C :cal SetSyn("nqc") ! an 50.60.310 &Syntax.Me-NO.Nroff :cal SetSyn("nroff") ! an 50.60.330 &Syntax.Me-NO.Objective\ C :cal SetSyn("objc") ! an 50.60.340 &Syntax.Me-NO.OCAML :cal SetSyn("ocaml") ! an 50.60.350 &Syntax.Me-NO.Omnimark :cal SetSyn("omnimark") ! an 50.60.360 &Syntax.Me-NO.OpenROAD :cal SetSyn("openroad") ! an 50.60.370 &Syntax.Me-NO.Open\ Psion\ Lang :cal SetSyn("opl") ! an 50.60.380 &Syntax.Me-NO.Oracle\ config :cal SetSyn("ora") ! an 50.70.100 &Syntax.PQ.Palm\ resource\ compiler :cal SetSyn("pilrc") ! an 50.70.110 &Syntax.PQ.PApp :cal SetSyn("papp") ! an 50.70.120 &Syntax.PQ.Pascal :cal SetSyn("pascal") ! an 50.70.130 &Syntax.PQ.PCCTS :cal SetSyn("pccts") ! an 50.70.140 &Syntax.PQ.PPWizard :cal SetSyn("ppwiz") ! an 50.70.150 &Syntax.PQ.Perl.Perl :cal SetSyn("perl") ! an 50.70.160 &Syntax.PQ.Perl.Perl\ POD :cal SetSyn("pod") ! an 50.70.170 &Syntax.PQ.Perl.Perl\ XS :cal SetSyn("xs") ! an 50.70.180 &Syntax.PQ.PHP\ 3-4 :cal SetSyn("php") ! an 50.70.190 &Syntax.PQ.Phtml :cal SetSyn("phtml") ! an 50.70.200 &Syntax.PQ.Pike :cal SetSyn("pike") ! an 50.70.210 &Syntax.PQ.Pine\ RC :cal SetSyn("pine") ! an 50.70.220 &Syntax.PQ.PL/M :cal SetSyn("plm") ! an 50.70.230 &Syntax.PQ.PL/SQL :cal SetSyn("plsql") ! an 50.70.240 &Syntax.PQ.PO\ (GNU\ gettext) :cal SetSyn("po") ! an 50.70.250 &Syntax.PQ.Postfix\ main\ config :cal SetSyn("pfmain") ! an 50.70.260 &Syntax.PQ.PostScript :cal SetSyn("postscr") ! an 50.70.270 &Syntax.PQ.PostScript\ Printer\ Description :cal SetSyn("ppd") ! an 50.70.280 &Syntax.PQ.Povray :cal SetSyn("pov") ! an 50.70.290 &Syntax.PQ.Povray\ configuration :cal SetSyn("povini") ! an 50.70.300 &Syntax.PQ.Printcap :cal SetSyn("pcap") ! an 50.70.310 &Syntax.PQ.Procmail :cal SetSyn("procmail") ! an 50.70.320 &Syntax.PQ.Product\ Spec\ File :cal SetSyn("psf") ! an 50.70.330 &Syntax.PQ.Progress :cal SetSyn("progress") ! an 50.70.340 &Syntax.PQ.Prolog :cal SetSyn("prolog") ! an 50.70.350 &Syntax.PQ.Purify\ log :cal SetSyn("purifylog") ! an 50.70.360 &Syntax.PQ.Python :cal SetSyn("python") ! an 50.80.100 &Syntax.R-Sg.R :cal SetSyn("r") ! an 50.80.110 &Syntax.R-Sg.Radiance :cal SetSyn("radiance") ! an 50.80.120 &Syntax.R-Sg.Ratpoison :cal SetSyn("ratpoison") ! an 50.80.130 &Syntax.R-Sg.Readline\ config :cal SetSyn("readline") ! an 50.80.140 &Syntax.R-Sg.RCS\ log\ output :cal SetSyn("rcslog") ! an 50.80.150 &Syntax.R-Sg.Rebol :cal SetSyn("rebol") ! an 50.80.160 &Syntax.R-Sg.Registry\ of\ MS-Windows :cal SetSyn("registry") ! an 50.80.170 &Syntax.R-Sg.Remind :cal SetSyn("remind") ! an 50.80.180 &Syntax.R-Sg.Renderman\ Shader\ Lang :cal SetSyn("sl") ! an 50.80.190 &Syntax.R-Sg.Rexx :cal SetSyn("rexx") ! an 50.80.200 &Syntax.R-Sg.Robots\.txt :cal SetSyn("robots") ! an 50.80.210 &Syntax.R-Sg.Rpcgen :cal SetSyn("rpcgen") ! an 50.80.220 &Syntax.R-Sg.RTF :cal SetSyn("rtf") ! an 50.80.230 &Syntax.R-Sg.Ruby :cal SetSyn("ruby") ! an 50.80.250 &Syntax.R-Sg.S-lang :cal SetSyn("slang") ! an 50.80.260 &Syntax.R-Sg.Samba\ config :cal SetSyn("samba") ! an 50.80.270 &Syntax.R-Sg.SAS :cal SetSyn("sas") ! an 50.80.280 &Syntax.R-Sg.Sather :cal SetSyn("sather") ! an 50.80.290 &Syntax.R-Sg.Scheme :cal SetSyn("scheme") ! an 50.80.300 &Syntax.R-Sg.Screen\ RC :cal SetSyn("screen") ! an 50.80.310 &Syntax.R-Sg.SDL :cal SetSyn("sdl") ! an 50.80.320 &Syntax.R-Sg.Sed :cal SetSyn("sed") ! an 50.80.330 &Syntax.R-Sg.Sendmail\.cf :cal SetSyn("sm") ! an 50.80.340 &Syntax.R-Sg.SGML.SGML\ catalog :cal SetSyn("catalog") ! an 50.80.350 &Syntax.R-Sg.SGML.SGML\ DTD :cal SetSyn("sgml") ! an 50.80.360 &Syntax.R-Sg.SGML.SGML\ Declarations :cal SetSyn("sgmldecl") ! an 50.80.370 &Syntax.R-Sg.SGML.SGML\ linuxdoc :cal SetSyn("sgmllnx") ! an 50.90.100 &Syntax.Sh-S.Sh\ shell\ script :cal SetSyn("sh") ! an 50.90.110 &Syntax.Sh-S.SiCAD :cal SetSyn("sicad") ! an 50.90.120 &Syntax.Sh-S.Simula :cal SetSyn("simula") ! an 50.90.130 &Syntax.Sh-S.Sinda.Sinda\ compare :cal SetSyn("sindacmp") ! an 50.90.140 &Syntax.Sh-S.Sinda.Sinda\ input :cal SetSyn("sinda") ! an 50.90.150 &Syntax.Sh-S.Sinda.Sinda\ output :cal SetSyn("sindaout") ! an 50.90.160 &Syntax.Sh-S.SKILL :cal SetSyn("skill") ! an 50.90.170 &Syntax.Sh-S.SLRN.SLRN\ rc :cal SetSyn("slrnrc") ! an 50.90.180 &Syntax.Sh-S.SLRN.SLRN\ score :cal SetSyn("slrnsc") ! an 50.90.190 &Syntax.Sh-S.SmallTalk :cal SetSyn("st") ! an 50.90.200 &Syntax.Sh-S.SMIL :cal SetSyn("smil") ! an 50.90.210 &Syntax.Sh-S.SMITH :cal SetSyn("smith") ! an 50.90.220 &Syntax.Sh-S.SNMP\ MIB :cal SetSyn("mib") ! an 50.90.230 &Syntax.Sh-S.SNNS.SNNS\ network :cal SetSyn("snnsnet") ! an 50.90.240 &Syntax.Sh-S.SNNS.SNNS\ pattern :cal SetSyn("snnspat") ! an 50.90.250 &Syntax.Sh-S.SNNS.SNNS\ result :cal SetSyn("snnsres") ! an 50.90.260 &Syntax.Sh-S.Snobol4 :cal SetSyn("snobol4") ! an 50.90.270 &Syntax.Sh-S.Snort\ Configuration :cal SetSyn("hog") ! an 50.90.280 &Syntax.Sh-S.SPEC\ (Linux\ RPM) :cal SetSyn("spec") ! an 50.90.290 &Syntax.Sh-S.Specman :cal SetSyn("specman") ! an 50.90.300 &Syntax.Sh-S.Spice :cal SetSyn("spice") ! an 50.90.310 &Syntax.Sh-S.Speedup :cal SetSyn("spup") ! an 50.90.320 &Syntax.Sh-S.Splint :cal SetSyn("splint") ! an 50.90.330 &Syntax.Sh-S.Squid :cal SetSyn("squid") ! an 50.90.340 &Syntax.Sh-S.SQL :cal SetSyn("sql") ! an 50.90.350 &Syntax.Sh-S.SQL\ Forms :cal SetSyn("sqlforms") ! an 50.90.360 &Syntax.Sh-S.SQR :cal SetSyn("sqr") ! an 50.90.370 &Syntax.Sh-S.Standard\ ML :cal SetSyn("sml") ! an 50.90.380 &Syntax.Sh-S.Stored\ Procedures :cal SetSyn("stp") ! an 50.90.390 &Syntax.Sh-S.Strace :cal SetSyn("strace") ! an 50.100.100 &Syntax.TUV.Tads :cal SetSyn("tads") ! an 50.100.110 &Syntax.TUV.Tags :cal SetSyn("tags") ! an 50.100.120 &Syntax.TUV.TAK.TAK\ compare :cal SetSyn("tak") ! an 50.100.130 &Syntax.TUV.TAK.TAK\ input :cal SetSyn("tak") ! an 50.100.140 &Syntax.TUV.TAK.TAK\ output :cal SetSyn("takout") ! an 50.100.150 &Syntax.TUV.Tcl/Tk :cal SetSyn("tcl") ! an 50.100.160 &Syntax.TUV.TealInfo :cal SetSyn("tli") ! an 50.100.170 &Syntax.TUV.Telix\ Salt :cal SetSyn("tsalt") ! an 50.100.180 &Syntax.TUV.Termcap :cal SetSyn("ptcap") ! an 50.100.190 &Syntax.TUV.Terminfo :cal SetSyn("terminfo") ! an 50.100.200 &Syntax.TUV.TeX :cal SetSyn("tex") ! an 50.100.210 &Syntax.TUV.TeX\ configuration :cal SetSyn("texmf") ! an 50.100.220 &Syntax.TUV.Texinfo :cal SetSyn("texinfo") ! an 50.100.230 &Syntax.TUV.TF\ mud\ client :cal SetSyn("tf") ! an 50.100.240 &Syntax.TUV.Tidy\ configuration :cal SetSyn("tidy") ! an 50.100.250 &Syntax.TUV.Trasys\ input :cal SetSyn("trasys") ! an 50.100.260 &Syntax.TUV.TSS.Command\ Line :cal SetSyn("tsscl") ! an 50.100.270 &Syntax.TUV.TSS.Geometry :cal SetSyn("tssgm") ! an 50.100.280 &Syntax.TUV.TSS.Optics :cal SetSyn("tssop") ! an 50.100.300 &Syntax.TUV.UIT/UIL :cal SetSyn("uil") ! an 50.100.310 &Syntax.TUV.UnrealScript :cal SetSyn("uc") ! an 50.100.330 &Syntax.TUV.Verilog\ HDL :cal SetSyn("verilog") ! an 50.100.340 &Syntax.TUV.Vgrindefs :cal SetSyn("vgrindefs") ! an 50.100.350 &Syntax.TUV.VHDL :cal SetSyn("vhdl") ! an 50.100.360 &Syntax.TUV.Vim.Vim\ help\ file :cal SetSyn("help") ! an 50.100.370 &Syntax.TUV.Vim.Vim\ script :cal SetSyn("vim") ! an 50.100.380 &Syntax.TUV.Vim.Viminfo\ file :cal SetSyn("viminfo") ! an 50.100.390 &Syntax.TUV.Virata :cal SetSyn("virata") ! an 50.100.400 &Syntax.TUV.Visual\ Basic :cal SetSyn("vb") ! an 50.100.410 &Syntax.TUV.VRML :cal SetSyn("vrml") ! an 50.100.420 &Syntax.TUV.VSE\ JCL :cal SetSyn("vsejcl") ! an 50.110.100 &Syntax.WXYZ.WEB :cal SetSyn("web") ! an 50.110.110 &Syntax.WXYZ.Webmacro :cal SetSyn("webmacro") ! an 50.110.120 &Syntax.WXYZ.Website\ MetaLanguage :cal SetSyn("wml") ! an 50.110.130 &Syntax.WXYZ.Wdiff :cal SetSyn("wdiff") ! an 50.110.140 &Syntax.WXYZ.Wget\ config :cal SetSyn("wget") ! an 50.110.150 &Syntax.WXYZ.Whitespace\ (add) :cal SetSyn("whitespace") ! an 50.110.160 &Syntax.WXYZ.WinBatch/Webbatch :cal SetSyn("winbatch") ! an 50.110.170 &Syntax.WXYZ.Windows\ Scripting\ Host :cal SetSyn("wsh") ! an 50.110.180 &Syntax.WXYZ.WvDial :cal SetSyn("wvdial") ! an 50.110.200 &Syntax.WXYZ.X\ Keyboard\ Extension :cal SetSyn("xkb") ! an 50.110.210 &Syntax.WXYZ.X\ Pixmap :cal SetSyn("xpm") ! an 50.110.220 &Syntax.WXYZ.X\ Pixmap\ (2) :cal SetSyn("xpm2") ! an 50.110.230 &Syntax.WXYZ.X\ resources :cal SetSyn("xdefaults") ! an 50.110.240 &Syntax.WXYZ.Xmath :cal SetSyn("xmath") ! an 50.110.250 &Syntax.WXYZ.XML :cal SetSyn("xml") ! an 50.110.260 &Syntax.WXYZ.Xslt :cal SetSyn("xslt") ! an 50.110.270 &Syntax.WXYZ.XXD\ hex\ dump :cal SetSyn("xxd") ! an 50.110.290 &Syntax.WXYZ.Yacc :cal SetSyn("yacc") ! an 50.110.310 &Syntax.WXYZ.Zsh\ shell\ script :cal SetSyn("zsh") " The End Of The Syntax Menu ! an 50.195 &Syntax.-SEP1- ! an 50.200 &Syntax.Set\ '&syntax'\ only :let s:syntax_menu_synonly=1 ! an 50.202 &Syntax.Set\ '&filetype'\ too :call Nosynonly() fun! s:Nosynonly() if exists("s:syntax_menu_synonly") unlet s:syntax_menu_synonly endif endfun ! an 50.210 &Syntax.&Off :syn off ! an 50.700 &Syntax.-SEP3- ! an 50.710 &Syntax.Co&lor\ test :sp $VIMRUNTIME/syntax/colortest.vimso % ! an 50.720 &Syntax.&Highlight\ test :so $VIMRUNTIME/syntax/hitest.vim ! an 50.730 &Syntax.&Convert\ to\ HTML :so $VIMRUNTIME/syntax/2html.vim endif " !exists("did_install_syntax_menu") *** ../vim60.134/src/menu.c Sun Sep 9 21:52:32 2001 --- src/menu.c Tue Jan 15 15:13:33 2002 *************** *** 371,377 **** * Add menu(s). * Replace special key codes. */ ! map_to = replace_termcodes(map_to, &map_buf, FALSE, TRUE); menuarg.modes = modes; #ifdef FEAT_TOOLBAR menuarg.iconfile = icon; --- 371,383 ---- * Add menu(s). * Replace special key codes. */ ! if (STRICMP(map_to, "") == 0) /* "" means nothing */ ! { ! map_to = (char_u *)""; ! map_buf = NULL; ! } ! else ! map_to = replace_termcodes(map_to, &map_buf, FALSE, TRUE); menuarg.modes = modes; #ifdef FEAT_TOOLBAR menuarg.iconfile = icon; *************** *** 711,720 **** /* free any old menu */ free_menu_string(menu, i); ! /* For "amenu", may insert an extra character */ ! /* Don't do this if adding a tearbar (addtearoff == FALSE) */ c = 0; ! if (amenu #ifdef FEAT_GUI_W32 && addtearoff #endif --- 717,727 ---- /* free any old menu */ free_menu_string(menu, i); ! /* For "amenu", may insert an extra character. ! * Don't do this if adding a tearbar (addtearoff == FALSE). ! * Don't do this for "". */ c = 0; ! if (amenu && call_data != NULL && *call_data != NUL #ifdef FEAT_GUI_W32 && addtearoff #endif *************** *** 1123,1129 **** else msg_putchar(' '); MSG_PUTS(" "); ! msg_outtrans_special(menu->strings[bit], FALSE); } } else --- 1130,1139 ---- else msg_putchar(' '); MSG_PUTS(" "); ! if (*menu->strings[bit] == NUL) ! msg_puts_attr((char_u *)"", hl_attr(HLF_8)); ! else ! msg_outtrans_special(menu->strings[bit], FALSE); } } else *** ../vim60.134/src/version.c Tue Jan 15 14:34:37 2002 --- src/version.c Tue Jan 15 16:34:51 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 135, /**/ -- For society, it's probably a good thing that engineers value function over appearance. For example, you wouldn't want engineers to build nuclear power plants that only _look_ like they would keep all the radiation inside. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.136 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.136 Problem: When completing in Insert mode, a mapping could be unexpectedly applied. Solution: Don't use mappings when checking for a typed character. Files: src/edit.c *** ../vim60.135/src/edit.c Sun Dec 30 21:23:29 2001 --- src/edit.c Tue Jan 15 17:12:44 2002 *************** *** 2917,2923 **** --- 2917,2925 ---- return; count = 0; + ++no_mapping; c = vpeekc_any(); + --no_mapping; if (c != NUL) { if (vim_is_ctrl_x_key(c) && c != Ctrl_X && c != Ctrl_R) *** ../vim60.135/src/version.c Tue Jan 15 16:37:40 2002 --- src/version.c Tue Jan 15 19:46:15 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 136, /**/ -- A consultant is a person who takes your money and annoys your employees while tirelessly searching for the best way to extend the consulting contract. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.137 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.137 Problem: GUI: When using the find or find/replace dialog from Insert mode, the input mode is stopped. Solution: Don't use the input method status when the main window doesn't have focus. Files: src/ui.c *** ../vim60.136/src/ui.c Mon Dec 31 15:35:23 2001 --- src/ui.c Tue Jan 15 19:42:02 2002 *************** *** 2754,2763 **** * disabled then (but might start later). * Also don't save when inside a mapping, vgetc_im_active has not been set * then. ! * And don't save when the keys were stuffed (e.g., for a "." command). */ if (!p_imdisable && KeyTyped && !KeyStuffed # ifdef FEAT_XIM && xic != NULL # endif ) { --- 2754,2768 ---- * disabled then (but might start later). * Also don't save when inside a mapping, vgetc_im_active has not been set * then. ! * And don't save when the keys were stuffed (e.g., for a "." command). ! * And don't save when the GUI is running but our window doesn't have ! * input focus (e.g., when a find dialog is open). */ if (!p_imdisable && KeyTyped && !KeyStuffed # ifdef FEAT_XIM && xic != NULL + # endif + # ifdef FEAT_GUI + && (!gui.in_use || gui.in_focus) # endif ) { *** ../vim60.136/src/version.c Tue Jan 15 19:48:49 2002 --- src/version.c Tue Jan 15 19:48:43 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 137, /**/ -- The process for understanding customers primarily involves sitting around with other marketing people and talking about what you would to if you were dumb enough to be a customer. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.138 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.138 Problem: GUI: When using the find or find/replace dialog from Insert mode, the text is inserted when CTRL-O is mapped. (Andre Pang) When opening the dialog again, a whole word search isn't recognized. When doing "replace all" a whole word search was never done. Solution: Don't put a search or replace command in the input buffer, execute it directly. Recognize "\<" and "\>" after removing "\V". Add "\<" and "\>" also for "replace all". Files: src/gui.c *** ../vim60.137/src/gui.c Thu Nov 1 14:56:27 2001 --- src/gui.c Wed Jan 16 11:35:01 2002 *************** *** 3952,3958 **** } #endif ! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_GUI_MOTIF) || defined(PROTO) /* * Update the current window and the screen. */ --- 3952,3959 ---- } #endif ! #if defined(FEAT_GUI_GTK) || defined(FEAT_SUN_WORKSHOP) \ ! || defined(FEAT_GUI_MOTIF) || defined(PROTO) /* * Update the current window and the screen. */ *************** *** 3995,4001 **** --- 3996,4005 ---- /* Remove "\V" */ if (len >= 2 && STRNCMP(text, "\\V", 2) == 0) + { mch_memmove(text, text + 2, (size_t)(len - 1)); + len -= 2; + } /* Recognize "\" and remove. */ if (len >= 4 *************** *** 4024,4038 **** int exact; /* Exact word match. */ { garray_T ga; ga_init2(&ga, 1, 100); - /* start stuffing in the command text */ - if (State & INSERT) - ga_append(&ga, Ctrl_O); - else if ((State | NORMAL) == 0) - ga_append(&ga, ESC); - if (flags == FR_REPLACE) { /* Do the replacement when the text under the cursor matches. */ --- 4028,4037 ---- int exact; /* Exact word match. */ { garray_T ga; + int i; ga_init2(&ga, 1, 100); if (flags == FR_REPLACE) { /* Do the replacement when the text under the cursor matches. */ *************** *** 4044,4074 **** } } else if (flags == FR_REPLACEALL) { - ga_concat(&ga, (char_u *)":%sno/"); - ga_concat(&ga, find_text); ga_concat(&ga, (char_u *)"/"); ga_concat(&ga, repl_text); ! ga_concat(&ga, (char_u *)"/g\r"); } ! ! if (flags != FR_REPLACEALL) { /* Search for the next match. */ ! if (down) ! ga_concat(&ga, (char_u *)"/\\V"); ! else ! ga_concat(&ga, (char_u *)"?\\V"); ! if (exact) ! ga_concat(&ga, (char_u *)"\\<"); ! ga_concat(&ga, find_text); ! if (exact) ! ga_concat(&ga, (char_u *)"\\>"); ! ga_concat(&ga, (char_u *)"\r"); } ! if (ga.ga_len > 0) ! add_to_input_buf((char_u *)ga.ga_data, ga.ga_len); vim_free(ga.ga_data); return (ga.ga_len > 0); --- 4043,4079 ---- } } else if (flags == FR_REPLACEALL) + ga_concat(&ga, (char_u *)"%s/"); + + ga_concat(&ga, (char_u *)"\\V"); + if (exact) + ga_concat(&ga, (char_u *)"\\<"); + ga_concat(&ga, find_text); + if (exact) + ga_concat(&ga, (char_u *)"\\>"); + + if (flags == FR_REPLACEALL) { ga_concat(&ga, (char_u *)"/"); ga_concat(&ga, repl_text); ! ga_concat(&ga, (char_u *)"/g"); ! do_cmdline_cmd(ga.ga_data); } ! else { /* Search for the next match. */ ! i = msg_scroll; ! do_search(NULL, down ? '/' : '?', ga.ga_data, 1L, ! SEARCH_MSG + SEARCH_MARK); ! msg_scroll = i; /* don't let an error message set msg_scroll */ } ! if (State & (NORMAL | INSERT)) ! { ! gui_update_screen(); /* update the screen */ ! msg_didout = 0; /* overwrite any message */ ! need_wait_return = FALSE; /* don't wait for return */ ! } vim_free(ga.ga_data); return (ga.ga_len > 0); *** ../vim60.137/src/version.c Tue Jan 15 19:50:54 2002 --- src/version.c Wed Jan 16 11:41:01 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 138, /**/ -- hundred-and-one symptoms of being an internet addict: 1. You actually wore a blue ribbon to protest the Communications Decency Act. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.139 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.139 Problem: When stopping 'wildmenu' completion, the statusline of the bottom-left vertically split window isn't redrawn. (Yegappan Lakshmanan) Solution: Redraw all the bottom statuslines. Files: src/ex_getln.c, src/proto/screen.pro, src/screen.c *** ../vim60.138/src/ex_getln.c Tue Jan 15 14:34:37 2002 --- src/ex_getln.c Wed Jan 16 12:18:03 2002 *************** *** 369,375 **** save_p_ls = -1; } else ! win_redr_status(lastwin); KeyTyped = skt; wild_menu_showing = 0; } --- 369,382 ---- save_p_ls = -1; } else ! { ! # ifdef FEAT_VERTSPLIT ! win_redraw_last_status(topframe); ! # else ! lastwin->w_redr_status = TRUE; ! # endif ! redraw_statuslines(); ! } KeyTyped = skt; wild_menu_showing = 0; } *** ../vim60.138/src/proto/screen.pro Tue Sep 25 21:49:23 2001 --- src/proto/screen.pro Wed Jan 16 12:20:07 2002 *************** *** 13,18 **** --- 13,19 ---- void status_redraw_all __ARGS((void)); void status_redraw_curbuf __ARGS((void)); void redraw_statuslines __ARGS((void)); + void win_redraw_last_status __ARGS((frame_T *frp)); void win_redr_status_matches __ARGS((expand_T *xp, int num_matches, char_u **matches, int match)); void win_redr_status __ARGS((win_T *wp)); int stl_connected __ARGS((win_T *wp)); *** ../vim60.138/src/screen.c Sun Jan 13 20:44:03 2002 --- src/screen.c Wed Jan 16 12:20:27 2002 *************** *** 140,148 **** static void screen_line __ARGS((int row, int coloff, int endcol, int clear_width)); # define SCREEN_LINE(r, o, e, c, rl) screen_line((r), (o), (e), (c)) #endif - #if defined(FEAT_WILDMENU) && defined(FEAT_VERTSPLIT) - static void win_redraw_last_status __ARGS((frame_T *frp)); - #endif #ifdef FEAT_VERTSPLIT static void draw_vsep_win __ARGS((win_T *wp, int row)); #endif --- 140,145 ---- *************** *** 4274,4284 **** } #endif ! #if defined(FEAT_WILDMENU) && defined(FEAT_VERTSPLIT) /* * Redraw all status lines at the bottom of frame "frp". */ ! static void win_redraw_last_status(frp) frame_T *frp; { --- 4271,4281 ---- } #endif ! #if (defined(FEAT_WILDMENU) && defined(FEAT_VERTSPLIT)) || defined(PROTO) /* * Redraw all status lines at the bottom of frame "frp". */ ! void win_redraw_last_status(frp) frame_T *frp; { *** ../vim60.138/src/version.c Wed Jan 16 11:42:43 2002 --- src/version.c Wed Jan 16 12:24:42 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 139, /**/ -- hundred-and-one symptoms of being an internet addict: 5. You find yourself brainstorming for new subjects to search. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.140 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.140 Problem: Memory allocated for local mappings and abbreviations is leaked when the buffer is wiped out. Solution: Clear the local mappings when deleting a buffer. Files: src/buffer.c, src/getchar.c, src/proto/getchar.pro, src/vim.h *** ../vim60.139/src/buffer.c Mon Jan 14 12:49:05 2002 --- src/buffer.c Wed Jan 16 13:05:47 2002 *************** *** 507,512 **** --- 507,516 ---- #endif #ifdef FEAT_USR_CMDS uc_clear(&buf->b_ucmds); /* clear local user commands */ + #ifdef FEAT_LOCALMAP + map_clear_int(buf, MAP_ALL_MODES, TRUE, FALSE); /* clear local mappings */ + map_clear_int(buf, MAP_ALL_MODES, TRUE, TRUE); /* clear local abbrevs */ + #endif #endif free_buf_options(buf, TRUE); #ifdef FEAT_MBYTE *** ../vim60.139/src/getchar.c Tue Jan 15 14:28:35 2002 --- src/getchar.c Wed Jan 16 12:49:18 2002 *************** *** 3278,3287 **** int forceit; int abbr; { - mapblock_T *mp, **mpp; int mode; - int hash; - int new_hash; #ifdef FEAT_LOCALMAP int local; --- 3278,3284 ---- *************** *** 3293,3301 **** } #endif - validate_maphash(); - mode = get_map_mode(&cmdp, forceit); for (hash = 0; hash < 256; ++hash) { --- 3290,3320 ---- } #endif mode = get_map_mode(&cmdp, forceit); + map_clear_int(curbuf, mode, + #ifdef FEAT_LOCALMAP + local, + #else + FALSE, + #endif + abbr); + } + + /* + * Clear all mappings in "mode". + */ + void + map_clear_int(buf, mode, local, abbr) + buf_T *buf; /* buffer for local mappings */ + int mode; /* mode in which to delete */ + int local; /* TRUE for buffer-local mappings */ + int abbr; /* TRUE for abbreviations */ + { + mapblock_T *mp, **mpp; + int hash; + int new_hash; + + validate_maphash(); for (hash = 0; hash < 256; ++hash) { *************** *** 3305,3311 **** break; #ifdef FEAT_LOCALMAP if (local) ! mpp = &curbuf->b_first_abbr; else #endif mpp = &first_abbr; --- 3324,3330 ---- break; #ifdef FEAT_LOCALMAP if (local) ! mpp = &buf->b_first_abbr; else #endif mpp = &first_abbr; *************** *** 3314,3320 **** { #ifdef FEAT_LOCALMAP if (local) ! mpp = &curbuf->b_maphash[hash]; else #endif mpp = &maphash[hash]; --- 3333,3339 ---- { #ifdef FEAT_LOCALMAP if (local) ! mpp = &buf->b_maphash[hash]; else #endif mpp = &maphash[hash]; *************** *** 3340,3347 **** #ifdef FEAT_LOCALMAP if (local) { ! mp->m_next = curbuf->b_maphash[new_hash]; ! curbuf->b_maphash[new_hash] = mp; } else #endif --- 3359,3366 ---- #ifdef FEAT_LOCALMAP if (local) { ! mp->m_next = buf->b_maphash[new_hash]; ! buf->b_maphash[new_hash] = mp; } else #endif *** ../vim60.139/src/proto/getchar.pro Sun Oct 28 21:23:45 2001 --- src/proto/getchar.pro Wed Jan 16 13:05:25 2002 *************** *** 41,46 **** --- 41,47 ---- int do_map __ARGS((int maptype, char_u *arg, int mode, int abbrev)); int get_map_mode __ARGS((char_u **cmdp, int forceit)); void map_clear __ARGS((char_u *cmdp, char_u *arg, int forceit, int abbr)); + void map_clear_int __ARGS((buf_T *buf, int mode, int local, int abbr)); int map_to_exists __ARGS((char_u *str, char_u *modechars)); int map_to_exists_mode __ARGS((char_u *rhs, int mode)); char_u *set_context_in_map_cmd __ARGS((expand_T *xp, char_u *cmd, char_u *arg, int forceit, int isabbrev, int isunmap, cmdidx_T cmdidx)); *** ../vim60.139/src/vim.h Wed Sep 19 16:57:09 2001 --- src/vim.h Wed Jan 16 13:03:57 2002 *************** *** 501,506 **** --- 501,507 ---- #define INSERT 0x10 /* Insert mode */ #define LANGMAP 0x20 /* Language mapping, can be combined with INSERT and CMDLINE */ + #define MAP_ALL_MODES 0x3f /* all mode bits used for mapping */ #define REPLACE_FLAG 0x40 /* Replace mode flag */ #define REPLACE (REPLACE_FLAG + INSERT) *** ../vim60.139/src/version.c Wed Jan 16 12:28:44 2002 --- src/version.c Wed Jan 16 13:45:27 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 140, /**/ -- hundred-and-one symptoms of being an internet addict: 6. You refuse to go to a vacation spot with no electricity and no phone lines. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.141 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.141 Problem: When using ":enew" in an empty buffer, some buffer-local things are not cleared. b:keymap_name is not set. Solution: Clear user commands and mappings local to the buffer when re-using the current buffer. Reload the keymap. Files: src/buffer.c *** ../vim60.140/src/buffer.c Thu Jan 17 11:00:13 2002 --- src/buffer.c Thu Jan 17 10:55:32 2002 *************** *** 46,52 **** static int ti_change __ARGS((char_u *str, char_u **last)); #endif static void free_buffer __ARGS((buf_T *)); ! static void free_buffer_stuff __ARGS((buf_T *)); static void clear_wininfo __ARGS((buf_T *buf)); #ifdef UNIX --- 46,52 ---- static int ti_change __ARGS((char_u *str, char_u **last)); #endif static void free_buffer __ARGS((buf_T *)); ! static void free_buffer_stuff __ARGS((buf_T *buf, int free_options)); static void clear_wininfo __ARGS((buf_T *buf)); #ifdef UNIX *************** *** 393,399 **** { /* Free all internal variables and reset option values, to make * ":bdel" compatible with Vim 5.7. */ ! free_buffer_stuff(buf); /* Make it look like a new buffer. */ buf->b_flags = BF_CHECK_RO | BF_NEVERLOADED; --- 393,399 ---- { /* Free all internal variables and reset option values, to make * ":bdel" compatible with Vim 5.7. */ ! free_buffer_stuff(buf, TRUE); /* Make it look like a new buffer. */ buf->b_flags = BF_CHECK_RO | BF_NEVERLOADED; *************** *** 481,487 **** free_buffer(buf) buf_T *buf; { ! free_buffer_stuff(buf); #ifdef FEAT_PERL perl_buf_free(buf); #endif --- 481,487 ---- free_buffer(buf) buf_T *buf; { ! free_buffer_stuff(buf, TRUE); #ifdef FEAT_PERL perl_buf_free(buf); #endif *************** *** 498,518 **** * Free stuff in the buffer for ":bdel" and when wiping out the buffer. */ static void ! free_buffer_stuff(buf) buf_T *buf; { ! clear_wininfo(buf); #ifdef FEAT_EVAL ! var_clear(&buf->b_vars); /* free all internal variables */ #endif #ifdef FEAT_USR_CMDS ! uc_clear(&buf->b_ucmds); /* clear local user commands */ #ifdef FEAT_LOCALMAP map_clear_int(buf, MAP_ALL_MODES, TRUE, FALSE); /* clear local mappings */ map_clear_int(buf, MAP_ALL_MODES, TRUE, TRUE); /* clear local abbrevs */ #endif - #endif - free_buf_options(buf, TRUE); #ifdef FEAT_MBYTE vim_free(buf->b_start_fenc); buf->b_start_fenc = NULL; --- 498,522 ---- * Free stuff in the buffer for ":bdel" and when wiping out the buffer. */ static void ! free_buffer_stuff(buf, free_options) buf_T *buf; + int free_options; /* free options as well */ { ! if (free_options) ! { ! clear_wininfo(buf); /* including window-local options */ ! free_buf_options(buf, TRUE); ! } #ifdef FEAT_EVAL ! var_clear(&buf->b_vars); /* free all internal variables */ #endif #ifdef FEAT_USR_CMDS ! uc_clear(&buf->b_ucmds); /* clear local user commands */ ! #endif #ifdef FEAT_LOCALMAP map_clear_int(buf, MAP_ALL_MODES, TRUE, FALSE); /* clear local mappings */ map_clear_int(buf, MAP_ALL_MODES, TRUE, TRUE); /* clear local abbrevs */ #endif #ifdef FEAT_MBYTE vim_free(buf->b_start_fenc); buf->b_start_fenc = NULL; *************** *** 1290,1297 **** if (buf != curbuf) /* autocommands deleted the buffer! */ return NULL; /* buf->b_nwindows = 0; why was this here? */ ! #ifdef FEAT_EVAL ! var_clear(&buf->b_vars); /* delete internal variables */ #endif } else --- 1294,1303 ---- if (buf != curbuf) /* autocommands deleted the buffer! */ return NULL; /* buf->b_nwindows = 0; why was this here? */ ! free_buffer_stuff(buf, FALSE); /* delete local variables et al. */ ! #ifdef FEAT_KEYMAP ! /* need to reload lmaps and set b:keymap_name */ ! curbuf->b_kmap_state |= KEYMAP_INIT; #endif } else *** ../vim60.140/src/version.c Thu Jan 17 11:00:13 2002 --- src/version.c Thu Jan 17 10:59:19 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 141, /**/ -- hundred-and-one symptoms of being an internet addict: 21. Your dog has its own home page. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.142 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.142 Problem: When Python is linked statically, loading dynamic extensions might fail. Solution: Add an extra linking flag when needed. (Andrew Rodionoff) Files: src/configure.in, src/auto/configure *** ../vim60.141/src/configure.in Fri Jan 11 13:03:17 2002 --- src/configure.in Thu Jan 17 12:02:23 2002 *************** *** 325,330 **** --- 329,335 ---- @echo "python_MODLIBS='$(MODLIBS)'" @echo "python_LIBS='$(LIBS)'" @echo "python_SYSLIBS='$(SYSLIBS)'" + @echo "python_LINKFORSHARED='$(LINKFORSHARED)'" eof dnl -- delete the lines from make about Entering/Leaving directory eval "`cd ${PYTHON_CONFDIR} && make -f ${tmp_mkf} __ | sed '/ directory /d'`" *************** *** 334,340 **** else vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi ! vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" dnl remove -ltermcap, it can conflict with an earlier -lncurses vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` ]) --- 339,345 ---- else vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi ! vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS} ${python_LINKFORSHARED}" dnl remove -ltermcap, it can conflict with an earlier -lncurses vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` ]) *** ../vim60.141/src/auto/configure Fri Jan 11 13:03:17 2002 --- src/auto/configure Thu Jan 17 12:03:36 2002 *************** *** 1580,1585 **** --- 1584,1590 ---- @echo "python_MODLIBS='$(MODLIBS)'" @echo "python_LIBS='$(LIBS)'" @echo "python_SYSLIBS='$(SYSLIBS)'" + @echo "python_LINKFORSHARED='$(LINKFORSHARED)'" eof eval "`cd ${PYTHON_CONFDIR} && make -f ${tmp_mkf} __ | sed '/ directory /d'`" rm -f ${tmp_mkf} *************** *** 1588,1594 **** else vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi ! vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS}" vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` fi --- 1593,1599 ---- else vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}" fi ! vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_MODLIBS} ${python_LIBS} ${python_SYSLIBS} ${python_LINKFORSHARED}" vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//` fi *** ../vim60.141/src/version.c Thu Jan 17 12:09:06 2002 --- src/version.c Thu Jan 17 12:08:51 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 142, /**/ -- hundred-and-one symptoms of being an internet addict: 23. You can't call your mother...she doesn't have a modem. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.143 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.143 Problem: When a syntax item includes a line break in a pattern, the syntax may not be updated properly when making a change. Solution: Add the "linebreaks" argument to ":syn sync". Files: runtime/doc/syntax.txt, src/screen.c, src/structs.h, src/syntax.c *** ../vim60.142/runtime/doc/syntax.txt Tue Sep 25 21:40:39 2001 --- runtime/doc/syntax.txt Thu Jan 17 15:21:41 2002 *************** *** 1895,1901 **** need to make sure syncing takes care of this. Example (match a character constant): > ! :syntax match Character /'.'/s+1e-1 < DEFINING REGIONS *:syn-region* *:syn-start* *:syn-skip* *:syn-end* --- 1962,1968 ---- need to make sure syncing takes care of this. Example (match a character constant): > ! :syntax match Character /'.'/hs=s+1,he=e-1 < DEFINING REGIONS *:syn-region* *:syn-start* *:syn-skip* *:syn-end* *************** *** 2594,2603 **** include". ============================================================================== ! 10. Synchronizing *:syn-sync* *E403* *E404* Vim wants to be able to start redrawing in any position in the document. To ! make this possible it needs to know the syntax item at the position where redrawing starts. :sy[ntax] sync [ccomment [group-name] | minlines={N} | ...] --- 2661,2670 ---- include". ============================================================================== ! 10. Synchronizing *:syn-sync* *E403* *E404* Vim wants to be able to start redrawing in any position in the document. To ! make this possible it needs to know the syntax state at the position where redrawing starts. :sy[ntax] sync [ccomment [group-name] | minlines={N} | ...] *************** *** 2626,2631 **** --- 2693,2709 ---- adding "minlines". This is useful if you have few things to sync on and a slow machine. Example: > :syntax sync ccomment maxlines=500 + < + *:syn-sync-linebreaks* + When using a pattern that matches multiple lines, a change in one line may + cause a pattern to no longer match in a previous line. This means has to + start above where the change was made. How many lines can be specified with + the "linebreaks" argument. For example, when a pattern may include one line + break use this: > + :syntax sync linebreaks=1 + The result is that redrawing always starts at least one line before where a + change was made. The default value for "linebreaks" is zero. Usually the + value for "minlines" is bigger than "linebreaks". First syncing method: *:syn-sync-first* *** ../vim60.142/src/screen.c Wed Jan 16 12:28:44 2002 --- src/screen.c Thu Jan 17 15:23:49 2002 *************** *** 823,829 **** --- 823,837 ---- if (buf->b_mod_set) { if (mod_top == 0 || mod_top > buf->b_mod_top) + { mod_top = buf->b_mod_top; + #ifdef FEAT_SYN_HL + /* Need to redraw lines above the change that may be included + * in a pattern match. */ + if (syntax_present(buf)) + mod_top -= buf->b_syn_sync_linebreaks; + #endif + } if (mod_bot == 0 || mod_bot < buf->b_mod_bot) mod_bot = buf->b_mod_bot; *** ../vim60.142/src/structs.h Tue Jan 15 14:34:37 2002 --- src/structs.h Thu Jan 17 15:22:02 2002 *************** *** 1049,1054 **** --- 1049,1055 ---- short b_syn_sync_id; /* group to sync on */ long b_syn_sync_minlines; /* minimal sync lines offset */ long b_syn_sync_maxlines; /* maximal sync lines offset */ + long b_syn_sync_linebreaks; /* offset for multi-line pattern */ char_u *b_syn_linecont_pat; /* line continuation pattern */ regprog_T *b_syn_linecont_prog; /* line continuation program */ int b_syn_linecont_ic; /* ignore-case flag for above */ *** ../vim60.142/src/syntax.c Thu Nov 1 12:22:41 2001 --- src/syntax.c Thu Jan 17 15:23:39 2002 *************** *** 383,388 **** --- 383,389 ---- static void syn_cmd_onoff __ARGS((exarg_T *eap, char *name)); static void syn_cmd_list __ARGS((exarg_T *eap, int syncing)); static void syn_lines_msg __ARGS((void)); + static void syn_match_msg __ARGS((void)); static void syn_list_one __ARGS((int id, int syncing, int link_only)); static void syn_list_cluster __ARGS((int id)); static void put_id_list __ARGS((char_u *name, short *list, int attr)); *************** *** 1149,1155 **** prev = NULL; for (p = buf->b_sst_first; p != NULL; ) { ! if (p->sst_lnum > buf->b_mod_top) { n = p->sst_lnum + buf->b_mod_xlines; if (n <= buf->b_mod_bot) --- 1150,1156 ---- prev = NULL; for (p = buf->b_sst_first; p != NULL; ) { ! if (p->sst_lnum + syn_buf->b_syn_sync_linebreaks > buf->b_mod_top) { n = p->sst_lnum + buf->b_mod_xlines; if (n <= buf->b_mod_bot) *************** *** 3029,3034 **** --- 3030,3036 ---- buf->b_syn_sync_flags = 0; buf->b_syn_sync_minlines = 0; buf->b_syn_sync_maxlines = 0; + buf->b_syn_sync_linebreaks = 0; vim_free(buf->b_syn_linecont_prog); buf->b_syn_linecont_prog = NULL; *************** *** 3059,3064 **** --- 3061,3067 ---- curbuf->b_syn_sync_flags = 0; curbuf->b_syn_sync_minlines = 0; curbuf->b_syn_sync_maxlines = 0; + curbuf->b_syn_sync_linebreaks = 0; vim_free(curbuf->b_syn_linecont_prog); curbuf->b_syn_linecont_prog = NULL; *************** *** 3346,3353 **** if (curbuf->b_syn_sync_flags & SF_CCOMMENT) { MSG_PUTS(_("syncing on C-style comments")); ! if (curbuf->b_syn_sync_minlines || curbuf->b_syn_sync_maxlines) ! syn_lines_msg(); return; } else if (!(curbuf->b_syn_sync_flags & SF_MATCH)) --- 3349,3356 ---- if (curbuf->b_syn_sync_flags & SF_CCOMMENT) { MSG_PUTS(_("syncing on C-style comments")); ! syn_lines_msg(); ! syn_match_msg(); return; } else if (!(curbuf->b_syn_sync_flags & SF_MATCH)) *************** *** 3359,3372 **** MSG_PUTS(_("syncing starts ")); msg_outnum(curbuf->b_syn_sync_minlines); MSG_PUTS(_(" lines before top line")); } return; } MSG_PUTS_TITLE(_("\n--- Syntax sync items ---")); ! if (curbuf->b_syn_sync_minlines || curbuf->b_syn_sync_maxlines) { MSG_PUTS(_("\nsyncing on items")); syn_lines_msg(); } } else --- 3362,3379 ---- MSG_PUTS(_("syncing starts ")); msg_outnum(curbuf->b_syn_sync_minlines); MSG_PUTS(_(" lines before top line")); + syn_match_msg(); } return; } MSG_PUTS_TITLE(_("\n--- Syntax sync items ---")); ! if (curbuf->b_syn_sync_minlines > 0 ! || curbuf->b_syn_sync_maxlines > 0 ! || curbuf->b_syn_sync_linebreaks > 0) { MSG_PUTS(_("\nsyncing on items")); syn_lines_msg(); + syn_match_msg(); } } else *************** *** 3414,3433 **** static void syn_lines_msg() { ! MSG_PUTS("; "); ! if (curbuf->b_syn_sync_minlines) { ! MSG_PUTS(_("minimal ")); ! msg_outnum(curbuf->b_syn_sync_minlines); ! if (curbuf->b_syn_sync_maxlines) ! MSG_PUTS(", "); } ! if (curbuf->b_syn_sync_maxlines) { ! MSG_PUTS(_("maximal ")); ! msg_outnum(curbuf->b_syn_sync_maxlines); } - MSG_PUTS(_(" lines before top line")); } static int last_matchgroup; --- 3421,3454 ---- static void syn_lines_msg() { ! if (curbuf->b_syn_sync_maxlines > 0 || curbuf->b_syn_sync_minlines > 0) { ! MSG_PUTS("; "); ! if (curbuf->b_syn_sync_minlines > 0) ! { ! MSG_PUTS(_("minimal ")); ! msg_outnum(curbuf->b_syn_sync_minlines); ! if (curbuf->b_syn_sync_maxlines) ! MSG_PUTS(", "); ! } ! if (curbuf->b_syn_sync_maxlines > 0) ! { ! MSG_PUTS(_("maximal ")); ! msg_outnum(curbuf->b_syn_sync_maxlines); ! } ! MSG_PUTS(_(" lines before top line")); } ! } ! ! static void ! syn_match_msg() ! { ! if (curbuf->b_syn_sync_linebreaks > 0) { ! MSG_PUTS(_("; match ")); ! msg_outnum(curbuf->b_syn_sync_linebreaks); ! MSG_PUTS(_(" line breaks")); } } static int last_matchgroup; *************** *** 5187,5196 **** } else if ( STRNCMP(key, "LINES", 5) == 0 || STRNCMP(key, "MINLINES", 8) == 0 ! || STRNCMP(key, "MAXLINES", 8) == 0) { ! if (key[0] == 'L') arg_end = key + 6; else arg_end = key + 9; if (arg_end[-1] != '=' || !isdigit(*arg_end)) --- 5208,5220 ---- } else if ( STRNCMP(key, "LINES", 5) == 0 || STRNCMP(key, "MINLINES", 8) == 0 ! || STRNCMP(key, "MAXLINES", 8) == 0 ! || STRNCMP(key, "LINEBREAKS", 10) == 0) { ! if (key[4] == 'S') arg_end = key + 6; + else if (key[0] == 'L') + arg_end = key + 11; else arg_end = key + 9; if (arg_end[-1] != '=' || !isdigit(*arg_end)) *************** *** 5201,5207 **** n = getdigits(&arg_end); if (!eap->skip) { ! if (key[1] == 'A') curbuf->b_syn_sync_maxlines = n; else curbuf->b_syn_sync_minlines = n; --- 5225,5233 ---- n = getdigits(&arg_end); if (!eap->skip) { ! if (key[4] == 'B') ! curbuf->b_syn_sync_linebreaks = n; ! else if (key[1] == 'A') curbuf->b_syn_sync_maxlines = n; else curbuf->b_syn_sync_minlines = n; *** ../vim60.142/src/version.c Thu Jan 17 12:12:55 2002 --- src/version.c Thu Jan 17 15:29:23 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 143, /**/ -- Q: What is the difference betwee open-source and commercial software? A: If you have a problem with commercial software you can call a phone number and they will tell you it might be solved in a future version. For open-source sofware there isn't a phone number to call, but you get the solution within a day. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.144 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.144 Problem: After patch 6.0.088 redoing "veU" doesn't work. Solution: Don't add the "U" to the redo buffer, it will be used as an undo command. Files: src/normal.c *** ../vim60.143/src/normal.c Sun Dec 30 17:47:16 2001 --- src/normal.c Mon Jan 21 12:46:56 2002 *************** *** 1515,1522 **** && oap->motion_force == NUL ) { ! prep_redo(oap->regname, 0L, NUL, 'v', get_op_char(oap->op_type), ! get_extra_op_char(oap->op_type), cap->nchar); redo_VIsual_mode = resel_VIsual_mode; redo_VIsual_col = resel_VIsual_col; redo_VIsual_line_count = resel_VIsual_line_count; --- 1515,1526 ---- && oap->motion_force == NUL ) { ! /* Prepare for redoing. Only use the nchar field for "r", ! * otherwise it might be the second char of the operator. */ ! prep_redo(oap->regname, 0L, NUL, 'v', ! get_op_char(oap->op_type), ! get_extra_op_char(oap->op_type), ! oap->op_type == OP_REPLACE ? cap->nchar : NUL); redo_VIsual_mode = resel_VIsual_mode; redo_VIsual_col = resel_VIsual_col; redo_VIsual_line_count = resel_VIsual_line_count; *** ../vim60.143/src/version.c Thu Jan 17 16:30:27 2002 --- src/version.c Mon Jan 21 12:50:36 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 144, /**/ -- 'Well, here's something to occupy you and keep your mind off things.' 'It won't work, I have an exceptionally large mind.' -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.145 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.145 Problem: When Vim can't read any input it might get stuck. When redirecting stdin and stderr Vim would not read commands from a file. (Servatius Brandt) Solution: When repeatedly trying to read a character when it's not possible, exit Vim. When stdin and stderr are not a tty, still try reading from them, but don't do a blocking wait. Files: src/ui.c *** ../vim60.144/src/ui.c Tue Jan 15 19:50:54 2002 --- src/ui.c Tue Jan 22 13:19:26 2002 *************** *** 134,142 **** #ifdef NO_CONSOLE_INPUT /* Don't wait for character input when the window hasn't been opened yet. ! * Must return something, otherwise we'll loop forever. */ if (no_console_input()) { buf[0] = CR; return 1; } --- 134,151 ---- #ifdef NO_CONSOLE_INPUT /* Don't wait for character input when the window hasn't been opened yet. ! * Do try reading, this works when redirecting stdin from a file. ! * Must return something, otherwise we'll loop forever. If we run into ! * this very often we probably got stuck, exit Vim. */ if (no_console_input()) { + static int count = 0; + + retval = mch_inchar(buf, maxlen, 10L); + if (retval > 0) + return retval; + if (wtime == -1 && ++count == 1000) + read_error_exit(); buf[0] = CR; return 1; } *** ../vim60.144/src/version.c Mon Jan 21 12:52:54 2002 --- src/version.c Tue Jan 22 13:21:08 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 145, /**/ -- Despite the cost of living, have you noticed how it remains so popular? /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.146 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.146 Problem: When 'statusline' contains "%{'-'}" this results in a zero. (Milan Vancura) Solution: Don't handle numbers with a minus as a number, they were not displayed anyway. Files: src/buffer.c *** ../vim60.145/src/buffer.c Thu Jan 17 12:09:06 2002 --- src/buffer.c Tue Jan 22 14:18:23 2002 *************** *** 3044,3054 **** if (str != NULL && *str != 0) { ! t = str; ! if (*t == '-') ! t++; ! t = skipdigits(t); ! if (*t == 0) { num = atoi((char *) str); vim_free(str); --- 3044,3050 ---- if (str != NULL && *str != 0) { ! if (*skipdigits(str) == NUL) { num = atoi((char *) str); vim_free(str); *** ../vim60.145/src/version.c Tue Jan 22 13:24:04 2002 --- src/version.c Tue Jan 22 14:20:06 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 146, /**/ -- It is hard to understand how a cemetery raised its burial cost and blamed it on the cost of living. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.147 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.147 Problem: It's not easy to mark a Vim version as being modified. The new license requires this. Solution: Add the --modified-by argument to configure and the MODIFIED_BY define. I's used in the intro screen and the ":version" output. Files: src/auto/configure, src/configure.in, src/config.h.in, src/version.c *** ../vim60.146/src/auto/configure Thu Jan 17 12:12:55 2002 --- src/auto/configure Tue Jan 22 15:34:21 2002 *************** *** 20,25 **** --- 20,27 ---- ac_help="$ac_help --with-global-runtime=DIR global runtime directory in 'runtimepath'" ac_help="$ac_help + --with-modified-by=NAME name of who modified a rlease version" + ac_help="$ac_help --with-features=TYPE tiny, small, normal, big or huge (default: normal)" ac_help="$ac_help --with-compiledby=NAME name to show in :version message" *************** *** 1207,1216 **** fi echo $ac_n "checking if character set is EBCDIC""... $ac_c" 1>&6 ! echo "configure:1212: checking if character set is EBCDIC" >&5 cat > conftest.$ac_ext <&6 + echo "configure:1221: checking --with-modified-by argument" >&5 + # Check whether --with-modified-by or --without-modified-by was given. + if test "${with_modified_by+set}" = set; then + withval="$with_modified_by" + echo "$ac_t""$withval" 1>&6; cat >> confdefs.h <&6 + fi + + echo $ac_n "checking if character set is EBCDIC""... $ac_c" 1>&6 ! echo "configure:1235: checking if character set is EBCDIC" >&5 cat > conftest.$ac_ext < MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.148 Problem: After "p" in an empty line, `[ goes to the second character. (Kontra Gergely) Solution: Don't increment the column number in an empty line. Files: src/ops.c *** ../vim60.147/src/ops.c Tue Nov 6 15:54:13 2001 --- src/ops.c Tue Jan 22 16:36:28 2002 *************** *** 2809,2828 **** orig_indent = get_indent(); curbuf->b_op_start = curwin->w_cursor; /* default for '[ mark */ - if (dir == FORWARD) - { - /* move to the start of the next (multi-byte) character */ - #ifdef FEAT_MBYTE - if (has_mbyte) - { - bytelen = (*mb_ptr2len_check)(ml_get_cursor()); - curbuf->b_op_start.col += bytelen; - } - else - #endif - curbuf->b_op_start.col++; - } - curbuf->b_op_end = curwin->w_cursor; /* default for '] mark */ /* --- 2809,2814 ---- *************** *** 2834,2840 **** (void)stuff_inserted((dir == FORWARD ? (count == -1 ? 'o' : 'a') : (count == -1 ? 'O' : 'i')), count, FALSE); /* Putting the text is done later, so can't really move the cursor to ! * the nex character. Use "l" to simulate it. */ if ((flags & PUT_CURSEND) && gchar_cursor() != NUL) stuffcharReadbuff('l'); return; --- 2820,2826 ---- (void)stuff_inserted((dir == FORWARD ? (count == -1 ? 'o' : 'a') : (count == -1 ? 'O' : 'i')), count, FALSE); /* Putting the text is done later, so can't really move the cursor to ! * the next character. Use "l" to simulate it. */ if ((flags & PUT_CURSEND) && gchar_cursor() != NUL) stuffcharReadbuff('l'); return; *************** *** 3130,3135 **** --- 3116,3125 ---- changed_lines(lnum, 0, curwin->w_cursor.lnum, nr_lines); + /* Set '[ mark. */ + curbuf->b_op_start = curwin->w_cursor; + curbuf->b_op_start.lnum = lnum; + /* adjust '] mark */ curbuf->b_op_end.lnum = curwin->w_cursor.lnum - 1; curbuf->b_op_end.col = bd.textcol + totlen - 1; *************** *** 3178,3183 **** --- 3168,3174 ---- } } new_cursor = curwin->w_cursor; + curbuf->b_op_start = curwin->w_cursor; } /* * Line mode: BACKWARD is the same as FORWARD on the previous line *** ../vim60.147/src/version.c Tue Jan 22 15:38:17 2002 --- src/version.c Tue Jan 22 16:47:25 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 148, /**/ -- Latest survey shows that 3 out of 4 people make up 75% of the world's population. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.149 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.149 Problem: The pattern "\(.\{-}\)*" causes a hang. When using a search pattern that causes a stack overflow to be detected Vim could still hang. Solution: Correctly report "operand could be empty" when using "\{-}". Check for "out_of_stack" inside loops to avoid a hang. Files: src/regexp.c *** ../vim60.148/src/regexp.c Mon Nov 5 09:00:25 2001 --- src/regexp.c Tue Jan 22 17:39:43 2002 *************** *** 1305,1311 **** reginsert_limits(BRACE_LIMITS, minval, maxval, ret); ++num_complex_braces; } ! if (minval > 0) *flagp = (HASWIDTH | (flags & HASNL)); break; } --- 1305,1311 ---- reginsert_limits(BRACE_LIMITS, minval, maxval, ret); ++num_complex_braces; } ! if (minval > 0 && maxval > 0) *flagp = (HASWIDTH | (flags & HASNL)); break; } *************** *** 3083,3089 **** #endif while (scan != NULL) { ! if (got_int) return FALSE; #ifdef DEBUG if (regnarrate) --- 3083,3089 ---- #endif while (scan != NULL) { ! if (got_int || out_of_stack) return FALSE; #ifdef DEBUG if (regnarrate) *************** *** 3676,3682 **** reg_nextline(); ++clnum; ccol = 0; ! if (got_int) return FALSE; } --- 3676,3682 ---- reg_nextline(); ++clnum; ccol = 0; ! if (got_int || out_of_stack) return FALSE; } *************** *** 3906,3912 **** regline = reg_getline(reglnum); reginput = regline + STRLEN(regline); fast_breakcheck(); ! if (got_int) return FALSE; } else --- 3906,3912 ---- regline = reg_getline(reglnum); reginput = regline + STRLEN(regline); fast_breakcheck(); ! if (got_int || out_of_stack) return FALSE; } else *************** *** 3941,3947 **** || regrepeat(OPERAND(scan), 1L) == 0) break; ++count; ! if (got_int) return FALSE; } } --- 3941,3947 ---- || regrepeat(OPERAND(scan), 1L) == 0) break; ++count; ! if (got_int || out_of_stack) return FALSE; } } *** ../vim60.148/src/version.c Tue Jan 22 16:51:24 2002 --- src/version.c Tue Jan 22 17:35:49 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 149, /**/ -- A fine is a tax for doing wrong. A tax is a fine for doing well. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.150 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.150 Problem: When using a multi-byte encoding, patch 6.0.148 causes "p" to work like "P". (Sung-Hyun Nam) Solution: Compute the byte length of a multi-byte character. Files: src/ops.c *** ../vim60.149/src/ops.c Tue Jan 22 16:51:24 2002 --- src/ops.c Thu Jan 24 11:23:26 2002 *************** *** 2780,2788 **** struct block_def bd; char_u *insert_string = NULL; int allocated = FALSE; - #ifdef FEAT_MBYTE - int bytelen = 0; - #endif long cnt; #ifdef FEAT_CLIPBOARD --- 2780,2785 ---- *************** *** 2983,2989 **** #ifdef FEAT_MBYTE if (has_mbyte) /* move to start of next multi-byte character */ ! curwin->w_cursor.col += bytelen; else #endif #ifdef FEAT_VIRTUALEDIT --- 2980,2986 ---- #ifdef FEAT_MBYTE if (has_mbyte) /* move to start of next multi-byte character */ ! curwin->w_cursor.col += (*mb_ptr2len_check)(ml_get_cursor()); else #endif #ifdef FEAT_VIRTUALEDIT *************** *** 3148,3153 **** --- 3145,3152 ---- #ifdef FEAT_MBYTE if (has_mbyte) { + int bytelen = (*mb_ptr2len_check)(ml_get_cursor()); + /* put it on the next of the multi-byte character. */ col += bytelen; if (yanklen) *** ../vim60.149/src/version.c Tue Jan 22 17:42:37 2002 --- src/version.c Thu Jan 24 11:26:36 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 150, /**/ -- hundred-and-one symptoms of being an internet addict: 47. You are so familiar with the WWW that you find the search engines useless. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.151 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.151 Problem: Redrawing the status line and ruler can be wrong when it contains multi-byte characters. Solution: Use character width and byte length correctly. (Yasuhiro Matsumoto) Files: src/screen.c *** ../vim60.150/src/screen.c Thu Jan 17 16:30:27 2002 --- src/screen.c Thu Jan 24 12:23:08 2002 *************** *** 4734,4740 **** { int clen = 0, i; - p[len] = NUL; /* Count total number of display cells. */ for (i = 0; p[i] != NUL; i += (*mb_ptr2len_check)(p + i)) clen += (*mb_ptr2cells)(p + i); --- 4734,4739 ---- *************** *** 4747,4754 **** { p = p + i - 1; *p = '<'; - len = len - i + 1; } } else --- 4746,4753 ---- { p = p + i - 1; *p = '<'; } + len = clen; } else *************** *** 7799,7805 **** */ i = (int)STRLEN(buffer); get_rel_pos(wp, buffer + i + 1); ! o = (int)STRLEN(buffer + i + 1); #ifdef FEAT_WINDOWS if (wp->w_status_height == 0) /* can't use last char of screen */ #endif --- 7798,7804 ---- */ i = (int)STRLEN(buffer); get_rel_pos(wp, buffer + i + 1); ! o = vim_strsize(buffer + i + 1); #ifdef FEAT_WINDOWS if (wp->w_status_height == 0) /* can't use last char of screen */ #endif *************** *** 7820,7825 **** --- 7819,7840 ---- get_rel_pos(wp, buffer + i); } /* Truncate at window boundary. */ + #ifdef FEAT_MBYTE + if (has_mbyte) + { + o = 0; + for (i = 0; buffer[i] != NUL; i += (*mb_ptr2len_check)(buffer + i)) + { + o += (*mb_ptr2cells)(buffer + i); + if (this_ru_col + o > WITH_WIDTH(width)) + { + buffer[i] = NUL; + break; + } + } + } + else + #endif if (this_ru_col + (int)STRLEN(buffer) > WITH_WIDTH(width)) buffer[WITH_WIDTH(width) - this_ru_col] = NUL; *** ../vim60.150/src/version.c Thu Jan 24 11:27:35 2002 --- src/version.c Thu Jan 24 13:45:14 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 151, /**/ -- Q: What is a patch 22? A: A patch you need to include to make it possible to include patches. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.152 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.152 Problem: strtrans() could hang on an illegal UTF-8 byte sequence. Solution: Skip over illegal bytes. (Yasuhiro Matsumoto) Files: src/charset.c *** ../vim60.151/src/charset.c Mon Oct 22 12:52:35 2001 --- src/charset.c Fri Jan 25 10:02:37 2002 *************** *** 347,353 **** p += l; } else ! len += byte2cells(*p++); } res = alloc((unsigned)(len + 1)); } --- 347,359 ---- p += l; } else ! { ! l = byte2cells(*p++); ! if (l > 0) ! len += l; ! else ! ++len; /* illegal byte sequence */ ! } } res = alloc((unsigned)(len + 1)); } *** ../vim60.151/src/version.c Thu Jan 24 13:47:03 2002 --- src/version.c Fri Jan 25 10:03:55 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 152, /**/ -- Time is money. Especially if you make clocks. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.153 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.153 Problem: When using (illegal) double-byte characters and Vim syntax highlighting Vim can crash. (Yasuhiro Matsumoto) Solution: Increase a pointer over a character instead of a byte. Files: src/regexp.c *** ../vim60.152/src/regexp.c Tue Jan 22 17:42:37 2002 --- src/regexp.c Mon Jan 28 14:01:09 2002 *************** *** 3904,3909 **** --- 3904,3912 ---- /* backup to last char of previous line */ --reglnum; regline = reg_getline(reglnum); + /* Just in case regrepeat() didn't count right. */ + if (regline == NULL) + return FALSE; reginput = regline + STRLEN(regline); fast_breakcheck(); if (got_int || out_of_stack) *************** *** 4158,4164 **** while (count < maxcount) { if (vim_isIDc(*scan) && (testval || !isdigit(*scan))) ! ++scan; else if (*scan == NUL) { if (!WITH_NL(OP(p)) || reglnum == reg_maxline) --- 4161,4169 ---- while (count < maxcount) { if (vim_isIDc(*scan) && (testval || !isdigit(*scan))) ! { ! ADVANCE_P(scan); ! } else if (*scan == NUL) { if (!WITH_NL(OP(p)) || reglnum == reg_maxline) *** ../vim60.152/src/version.c Fri Jan 25 10:05:09 2002 --- src/version.c Mon Jan 28 13:59:07 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 153, /**/ -- hundred-and-one symptoms of being an internet addict: 87. Everyone you know asks why your phone line is always busy ...and you tell them to send an e-mail. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.154 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.154 Problem: MS-DOS and MS-Windows: The menu entries for xxd don't work when there is no xxd in the path. When converting back from Hex the filetype may remain "xxd" if it is not detected. Solution: When xxd is not in the path use the one in the runtime directory, where the install program has put it. Clear the 'filetype' option before detecting the new value. Files: runtime/menu.vim *** ../vim60.153/runtime/menu.vim Tue Jan 15 16:37:40 2002 --- runtime/menu.vim Mon Jan 28 15:18:11 2002 *************** *** 429,435 **** if has("vms") %!mc vim:xxd else ! %!xxd endif set ft=xxd let &mod = mod --- 429,436 ---- if has("vms") %!mc vim:xxd else ! call s:XxdFind() ! exe "%!" . g:xxdprogram endif set ft=xxd let &mod = mod *************** *** 440,449 **** if has("vms") %!mc vim:xxd -r else ! %!xxd -r endif doautocmd filetypedetect BufReadPost let &mod = mod endfun " Setup the Tools.Compiler submenu --- 441,463 ---- if has("vms") %!mc vim:xxd -r else ! call s:XxdFind() ! exe "%!" . g:xxdprogram . " -r" endif + set ft= doautocmd filetypedetect BufReadPost let &mod = mod + endfun + + func! s:XxdFind() + if !exists("g:xxdprogram") + " On the PC xxd may not be in the path but in the install directory + if (has("win32") || has("dos32")) && !executable("xxd") + let g:xxdprogram = $VIMRUNTIME . (&shellslash ? '/' : '\') . "xxd.exe" + else + let g:xxdprogram = "xxd" + endif + endif endfun " Setup the Tools.Compiler submenu *** ../vim60.153/src/version.c Mon Jan 28 14:06:05 2002 --- src/version.c Mon Jan 28 15:19:25 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 154, /**/ -- hundred-and-one symptoms of being an internet addict: 91. It's Saturday afternoon in the middle of may and you are on computer. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.155 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.155 Problem: Mac: compilation problems in ui.c after patch 6.0.145. (Axel Kielhorn) Solution: Don't call mch_inchar() when NO_CONSOLE is defined. Files: src/ui.c *** ../vim60.154/src/ui.c Tue Jan 22 13:24:04 2002 --- src/ui.c Sun Jan 27 10:58:44 2002 *************** *** 141,149 **** --- 141,151 ---- { static int count = 0; + #ifndef NO_CONSOLE retval = mch_inchar(buf, maxlen, 10L); if (retval > 0) return retval; + #endif if (wtime == -1 && ++count == 1000) read_error_exit(); buf[0] = CR; *** ../vim60.154/src/version.c Mon Jan 28 16:11:30 2002 --- src/version.c Tue Jan 29 16:21:27 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 155, /**/ -- From "know your smileys": :-X My lips are sealed /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.156 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.156 Problem: Starting Vim with the -b argument and two files, ":next" doesn't set 'binary' in the second file, like Vim 5.7. (Norman Diamond) Solution: Set the global value for 'binary'. Files: src/option.c *** ../vim60.155/src/option.c Tue Jan 15 14:34:37 2002 --- src/option.c Tue Jan 29 16:32:30 2002 *************** *** 3883,3890 **** { p_tw = 0; p_wm = 0; ! p_ml = 0; ! p_et = 0; } } else if (oldval) /* switched off */ --- 3883,3891 ---- { p_tw = 0; p_wm = 0; ! p_ml = FALSE; ! p_et = FALSE; ! p_bin = TRUE; /* needed when called for the "-b" argument */ } } else if (oldval) /* switched off */ *** ../vim60.155/src/version.c Tue Jan 29 16:23:04 2002 --- src/version.c Tue Jan 29 16:34:31 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 156, /**/ -- From "know your smileys" 8<}} Glasses, big nose, beard /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.157 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.157 Problem: When defining a user command with "-complete=dir" files will also be expanded. Also, "-complete=mapping" doesn't appear to work. (Michael Naumann) Solution: Use the expansion flags defined with the user command. Handle expanding mappings specifically. Files: src/ex_docmd.c *** ../vim60.156/src/ex_docmd.c Tue Jan 15 14:34:37 2002 --- src/ex_docmd.c Wed Jan 30 16:48:00 2002 *************** *** 2770,2788 **** #ifdef FEAT_USR_CMDS case CMD_USER: case CMD_USER_BUF: ! /* XFILE: file names are handled above */ ! if (compl != EXPAND_NOTHING && !(argt & XFILE)) { # ifdef FEAT_MENU ! if (compl == EXPAND_MENUS) ! return set_context_in_menu_cmd(xp, cmd, arg, forceit); # endif ! if (compl == EXPAND_COMMANDS) ! return arg; ! while ((xp->xp_pattern = vim_strchr(arg, ' ')) != NULL) ! arg = xp->xp_pattern + 1; xp->xp_context = compl; - xp->xp_pattern = arg; } break; #endif --- 2770,2794 ---- #ifdef FEAT_USR_CMDS case CMD_USER: case CMD_USER_BUF: ! if (compl != EXPAND_NOTHING) { + /* XFILE: file names are handled above */ + if (!(argt & XFILE)) + { # ifdef FEAT_MENU ! if (compl == EXPAND_MENUS) ! return set_context_in_menu_cmd(xp, cmd, arg, forceit); # endif ! if (compl == EXPAND_COMMANDS) ! return arg; ! if (compl == EXPAND_MAPPINGS) ! return set_context_in_map_cmd(xp, (char_u *)"map", ! arg, forceit, FALSE, FALSE, CMD_map); ! while ((xp->xp_pattern = vim_strchr(arg, ' ')) != NULL) ! arg = xp->xp_pattern + 1; ! xp->xp_pattern = arg; ! } xp->xp_context = compl; } break; #endif *** ../vim60.156/src/version.c Wed Jan 30 16:50:08 2002 --- src/version.c Wed Jan 30 16:49:36 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 157, /**/ -- hundred-and-one symptoms of being an internet addict: 94. Now admit it... How many of you have made "modem noises" into the phone just to see if it was possible? :-) /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.158 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.158 Problem: When getting the warning for a file being changed outside of Vim and reloading the file, the 'readonly' option is reset, even when the permissions didn't change. (Marcel Svitalsky) Solution: Keep 'readonly' set when reloading a file and the permissions didn't change. Files: src/fileio.c *** ../vim60.157/src/fileio.c Wed Jan 2 17:10:11 2002 --- src/fileio.c Wed Jan 30 20:01:42 2002 *************** *** 5159,5164 **** --- 5167,5173 ---- linenr_T old_line_count = buf->b_ml.ml_line_count; exarg_T ea; pos_T old_cursor; + int old_ro = curbuf->b_p_ro; #ifdef FEAT_AUTOCMD aco_save_T aco; *************** *** 5205,5210 **** --- 5214,5224 ---- #ifdef FEAT_AUTOCMD keep_filetype = FALSE; #endif + /* If the mode didn't change and 'readonly' was set, keep the old + * value; the user probably used the ":view" command. But don't + * reset it, might have had a read error. */ + if (orig_mode == curbuf->b_orig_mode) + curbuf->b_p_ro |= old_ro; } #ifdef FEAT_AUTOCMD *** ../vim60.157/src/version.c Wed Jan 30 16:52:45 2002 --- src/version.c Wed Jan 30 20:08:31 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 158, /**/ -- hundred-and-one symptoms of being an internet addict: 102. When filling out your driver's license application, you give your IP address. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.159 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.159 Problem: Wildcard expansion for ":emenu" also shows separators. Solution: Skip menu separators for ":emenu", ":popup" and ":tearoff". Also, don't handle ":tmenu" as if it was ":tearoff". And leave out the alternatives with "&" included. Files: src/menu.c *** ../vim60.158/src/menu.c Tue Jan 15 16:37:40 2002 --- src/menu.c Wed Jan 30 21:43:51 2002 *************** *** 1160,1165 **** --- 1160,1166 ---- */ static vimmenu_T *expand_menu = NULL; static int expand_modes = 0x0; + static int expand_emenu; /* TRUE for ":emenu" command */ /* * Work out what to complete when doing command line completion of menu names. *************** *** 1211,1218 **** else if (*p == '.') after_dot = p + 1; } ! expand_menus = !(*cmd == 't' || *cmd == 'p'); ! if (expand_menus && vim_iswhite(*p)) return NULL; /* TODO: check for next command? */ if (*p == NUL) /* Complete the menu name */ { --- 1212,1222 ---- else if (*p == '.') after_dot = p + 1; } ! ! /* ":tearoff" and ":popup" only use menus, not entries */ ! expand_menus = !((*cmd == 't' && cmd[1] == 'e') || *cmd == 'p'); ! expand_emenu = (*cmd == 'e'); ! if (expand_menus && vim_iswhite(*p)) return NULL; /* TODO: check for next command? */ if (*p == NUL) /* Complete the menu name */ { *************** *** 1277,1283 **** } /* ! * Function given to ExpandGeneric() to obtain the list of group names. */ char_u * get_menu_name(xp, idx) --- 1281,1288 ---- } /* ! * Function given to ExpandGeneric() to obtain the list of (sub)menus (not ! * entries). */ char_u * get_menu_name(xp, idx) *************** *** 1285,1338 **** int idx; { static vimmenu_T *menu = NULL; - static int get_dname = FALSE; /* return menu->dname next time */ char_u *str; if (idx == 0) /* first call: start at first item */ - { menu = expand_menu; - get_dname = FALSE; - } /* Skip PopUp[nvoci]. */ while (menu != NULL && (menu_is_hidden(menu->dname) ! /* || menu_is_separator(menu->dname) */ || menu_is_tearoff(menu->dname) ! || (xp->xp_context == EXPAND_MENUS && menu->children == NULL))) menu = menu->next; if (menu == NULL) /* at end of linked list */ return NULL; if (menu->modes & expand_modes) ! { ! if (get_dname) ! { ! str = menu->dname; ! get_dname = FALSE; ! } ! else ! { ! str = menu->name; ! if (STRCMP(menu->name, menu->dname)) ! get_dname = TRUE; ! } ! } else - { str = (char_u *)""; - get_dname = FALSE; - } /* Advance to next menu entry. */ ! if (!get_dname) ! menu = menu->next; return str; } /* ! * Function given to ExpandGeneric() to obtain the list of group names. */ char_u * get_menu_names(xp, idx) --- 1290,1324 ---- int idx; { static vimmenu_T *menu = NULL; char_u *str; if (idx == 0) /* first call: start at first item */ menu = expand_menu; /* Skip PopUp[nvoci]. */ while (menu != NULL && (menu_is_hidden(menu->dname) ! || menu_is_separator(menu->dname) || menu_is_tearoff(menu->dname) ! || menu->children == NULL)) menu = menu->next; if (menu == NULL) /* at end of linked list */ return NULL; if (menu->modes & expand_modes) ! str = menu->dname; else str = (char_u *)""; /* Advance to next menu entry. */ ! menu = menu->next; return str; } /* ! * Function given to ExpandGeneric() to obtain the list of menus and menu ! * entries. */ char_u * get_menu_names(xp, idx) *************** *** 1348,1357 **** /* Skip Browse-style entries, popup menus and separators. */ while (menu != NULL ! && ( menu_is_hidden(menu->dname) ! /* || menu_is_separator(menu->dname) */ || menu_is_tearoff(menu->dname) - || (xp->xp_context == EXPAND_MENUS && menu->children == NULL) #ifndef FEAT_BROWSE || menu->dname[STRLEN(menu->dname) - 1] == '.' #endif --- 1334,1342 ---- /* Skip Browse-style entries, popup menus and separators. */ while (menu != NULL ! && ( menu_is_hidden(menu->dname) ! || (expand_emenu && menu_is_separator(menu->dname)) || menu_is_tearoff(menu->dname) #ifndef FEAT_BROWSE || menu->dname[STRLEN(menu->dname) - 1] == '.' #endif *** ../vim60.158/src/version.c Fri Feb 1 20:07:17 2002 --- src/version.c Fri Feb 1 20:01:23 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 159, /**/ -- hundred-and-one symptoms of being an internet addict: 149. You find your computer sexier than your girlfriend /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.160 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.160 Problem: When compiling with GCC 3.0.2 and using the "-O2" argument, the optimizer causes a problem that makes Vim crash. Solution: Add a configure check to avoid "-O2" for this version of gcc. Files: src/configure.in, src/auto/configure *** ../vim60.159/src/configure.in Tue Jan 22 15:38:17 2002 --- src/configure.in Tue Jan 22 19:46:56 2002 *************** *** 26,31 **** --- 26,38 ---- CFLAGS="-O" test "$GCC" = yes && CFLAGS="-O2 -fno-strength-reduce -Wall" fi + if test "$GCC" = yes; then + gccversion=`"$CC" --version` + if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2"; then + echo 'GCC 3.0.x has a bug in the optimizer, disabling "-O#"' + CFLAGS=`echo "$CFLAGS" | sed 's/-O[[23456789]]/-O/'` + fi + fi dnl If configure thinks we are cross compiling, there is probably something dnl wrong with the CC or CFLAGS settings, give an understandable error message *** ../vim60.159/src/auto/configure Tue Jan 22 15:38:17 2002 --- src/auto/configure Wed Jan 30 16:19:19 2002 *************** *** 1112,1117 **** --- 1112,1124 ---- CFLAGS="-O" test "$GCC" = yes && CFLAGS="-O2 -fno-strength-reduce -Wall" fi + if test "$GCC" = yes; then + gccversion=`"$CC" --version` + if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2"; then + echo 'GCC 3.0.x has a bug in the optimizer, disabling "-O#"' + CFLAGS=`echo "$CFLAGS" | sed 's/-O[23456789]/-O/'` + fi + fi if test "$cross_compiling" = yes; then { echo "configure: error: cannot compile a simple program, check CC and CFLAGS *** ../vim60.159/src/version.c Fri Feb 1 20:15:57 2002 --- src/version.c Fri Feb 1 20:16:14 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 160, /**/ -- hundred-and-one symptoms of being an internet addict: 150. You find yourself counting emoticons to get to sleep. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.161 (extra) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.161 Problem: Win32: Bitmaps don't work with signs. Solution: Make it possible to use bitmaps with signs. (Muraoka Taro) Files: src/ex_cmds.c, src/feature.h, src/gui_w32.c, src/gui_x11.c, src/proto/gui_w32.pro, src/proto/gui_x11.pro *** ../vim60.160/src/ex_cmds.c Thu Jan 10 20:17:24 2002 --- src/ex_cmds.c Sat Feb 2 21:55:07 2002 *************** *** 5064,5070 **** char_u *sn_name; /* name of sign */ char_u *sn_icon; /* name of pixmap */ #ifdef FEAT_SIGN_ICONS ! XImage *sn_image; /* icon image */ #endif char_u *sn_text; /* text used instead of pixmap */ int sn_line_hl; /* highlight ID for line */ --- 5064,5070 ---- char_u *sn_name; /* name of sign */ char_u *sn_icon; /* name of pixmap */ #ifdef FEAT_SIGN_ICONS ! void *sn_image; /* icon image */ #endif char_u *sn_text; /* text used instead of pixmap */ int sn_line_hl; /* highlight ID for line */ *************** *** 5565,5571 **** for (sp = first_sign; sp != NULL; sp = sp->sn_next) if (sp->sn_typenr == typenr) ! return (void *)sp->sn_image; return NULL; } #endif --- 5565,5571 ---- for (sp = first_sign; sp != NULL; sp = sp->sn_next) if (sp->sn_typenr == typenr) ! return sp->sn_image; return NULL; } #endif *** ../vim60.160/src/feature.h Tue Jan 22 16:39:07 2002 --- src/feature.h Sat Feb 2 22:00:58 2002 *************** *** 1064,1071 **** */ #if defined(FEAT_BIG) || defined(FEAT_SUN_WORKSHOP) # define FEAT_SIGNS ! # if (defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) \ ! && defined(HAVE_X11_XPM_H) # define FEAT_SIGN_ICONS # endif #endif --- 1064,1072 ---- */ #if defined(FEAT_BIG) || defined(FEAT_SUN_WORKSHOP) # define FEAT_SIGNS ! # if ((defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) \ ! && defined(HAVE_X11_XPM_H)) \ ! || (defined(WIN32) && defined(FEAT_GUI)) # define FEAT_SIGN_ICONS # endif #endif *** ../vim60.160/src/gui_w32.c Tue Jan 1 23:08:31 2002 --- src/gui_w32.c Sat Feb 2 21:59:29 2002 *************** *** 3387,3390 **** --- 3387,3513 ---- } # endif + #endif + + #if defined(FEAT_SIGN_ICONS) || defined(PROTO) + typedef struct _signicon_t + { + HANDLE hImage; + UINT uType; + } signicon_t; + + void + gui_mch_drawsign(row, col, typenr) + int row; + int col; + int typenr; + { + signicon_t *sign; + int x, y, w, h; + + if (!gui.in_use || (sign = (signicon_t *)sign_get_image(typenr)) == NULL) + return; + + x = TEXT_X(col); + y = TEXT_Y(row); + w = gui.char_width * 2; + h = gui.char_height; + switch (sign->uType) + { + case IMAGE_BITMAP: + { + HDC hdcMem; + HBITMAP hbmpOld; + + hdcMem = CreateCompatibleDC(s_hdc); + hbmpOld = (HBITMAP)SelectObject(hdcMem, sign->hImage); + BitBlt(s_hdc, x, y, w, h, hdcMem, 0, 0, SRCCOPY); + SelectObject(hdcMem, hbmpOld); + DeleteDC(hdcMem); + } + break; + case IMAGE_ICON: + case IMAGE_CURSOR: + DrawIconEx(s_hdc, x, y, (HICON)sign->hImage, w, h, 0, NULL, DI_NORMAL); + break; + } + } + + static void + close_signicon_image(signicon_t *sign) + { + if (sign) + switch (sign->uType) + { + case IMAGE_BITMAP: + DeleteObject((HGDIOBJ)sign->hImage); + break; + case IMAGE_CURSOR: + DestroyCursor((HCURSOR)sign->hImage); + break; + case IMAGE_ICON: + DestroyIcon((HICON)sign->hImage); + break; + } + } + + void * + gui_mch_register_sign(signfile) + char_u *signfile; + { + signicon_t sign, *psign; + char_u *ext; + + if (is_winnt_3()) + { + /* TODO: May be changed this message */ + EMSG(_("E255: Couldn't read in sign data!")); + return NULL; + } + + sign.hImage = NULL; + ext = signfile + STRLEN(signfile) - 4; /* get extention */ + if (ext > signfile) + { + int do_load = 1; + + if (!STRICMP(ext, ".bmp")) + sign.uType = IMAGE_BITMAP; + else if (!STRICMP(ext, ".ico")) + sign.uType = IMAGE_ICON; + else if (!STRICMP(ext, ".cur") || !STRICMP(ext, ".ani")) + sign.uType = IMAGE_CURSOR; + else + do_load = 0; + + if (do_load) + sign.hImage = (HANDLE)LoadImage(NULL, signfile, sign.uType, + gui.char_width * 2, gui.char_height, + LR_LOADFROMFILE | LR_CREATEDIBSECTION); + } + + psign = NULL; + if (sign.hImage && (psign = (signicon_t *)alloc(sizeof(signicon_t)))) + *psign = sign; + + if (!psign) + { + if (sign.hImage) + close_signicon_image(&sign); + EMSG(_("E255: Couldn't read in sign data!")); + } + return (void *)psign; + + } + + void + gui_mch_destroy_sign(sign) + void *sign; + { + if (sign) + { + close_signicon_image((signicon_t *)sign); + vim_free(sign); + } + } #endif *** ../vim60.160/src/gui_x11.c Wed Sep 26 16:15:32 2001 --- src/gui_x11.c Sat Feb 2 21:52:29 2002 *************** *** 3210,3216 **** } } ! XImage * gui_mch_register_sign(signfile) char_u *signfile; { --- 3210,3216 ---- } } ! void * gui_mch_register_sign(signfile) char_u *signfile; { *************** *** 3259,3272 **** } } ! return sign; } void gui_mch_destroy_sign(sign) ! XImage *sign; { ! XFree(sign->data); vim_free(sign); } #endif --- 3259,3272 ---- } } ! return (void *)sign; } void gui_mch_destroy_sign(sign) ! void *sign; { ! XFree(((XImage *)sign)->data); vim_free(sign); } #endif *** ../vim60.160/src/proto/gui_w32.pro Tue Sep 25 21:49:31 2001 --- src/proto/gui_w32.pro Sat Feb 2 22:11:29 2002 *************** *** 74,77 **** --- 74,80 ---- void gui_mch_menu_grey __ARGS((vimmenu_T *menu, int grey)); int gui_mch_dialog __ARGS((int type, char_u *title, char_u *message, char_u *buttons, int dfltbutton, char_u *textfield)); void gui_mch_set_foreground __ARGS((void)); + void gui_mch_drawsign __ARGS((int row, int col, int typenr)); + void *gui_mch_register_sign __ARGS((char_u *signfile)); + void gui_mch_destroy_sign __ARGS((void *sign)); /* vim: set ft=c : */ *** ../vim60.160/src/proto/gui_x11.pro Tue Sep 25 21:49:30 2001 --- src/proto/gui_x11.pro Sat Feb 2 22:06:55 2002 *************** *** 61,68 **** void gui_mch_setmouse __ARGS((int x, int y)); XButtonPressedEvent *gui_x11_get_last_mouse_event __ARGS((void)); void gui_mch_drawsign __ARGS((int row, int col, int typenr)); ! XImage *gui_mch_register_sign __ARGS((char_u *signfile)); ! void gui_mch_destroy_sign __ARGS((XImage *sign)); void gui_mch_mousehide __ARGS((int hide)); void mch_set_mouse_shape __ARGS((int shape)); void get_toolbar_pixmap __ARGS((vimmenu_T *menu, Pixmap *sen, Pixmap *insen)); --- 61,68 ---- void gui_mch_setmouse __ARGS((int x, int y)); XButtonPressedEvent *gui_x11_get_last_mouse_event __ARGS((void)); void gui_mch_drawsign __ARGS((int row, int col, int typenr)); ! void *gui_mch_register_sign __ARGS((char_u *signfile)); ! void gui_mch_destroy_sign __ARGS((void *sign)); void gui_mch_mousehide __ARGS((int hide)); void mch_set_mouse_shape __ARGS((int shape)); void get_toolbar_pixmap __ARGS((vimmenu_T *menu, Pixmap *sen, Pixmap *insen)); *** ../vim60.160/src/version.c Fri Feb 1 20:29:26 2002 --- src/version.c Sat Feb 2 22:12:13 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 161, /**/ -- hundred-and-one symptoms of being an internet addict: 164. You got out to buy software, instead of going out for a beer. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.162 (extra) Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.162 Problem: Client-server: An error message for a wrong expression appears in the server instead of the cient. Solution: Pass the error message from the server to the client. Also adjust the example code. (Flemming Madsen) Files: src/globals.h, src/if_xcmdsrv.c, src/main.c, src/os_mswin.c, src/proto/if_xcmdsrv.pro, src/proto/os_mswin.pro, runtime/doc/eval.txt, runtime/tools/xcmdsrv_client.c *** ../vim60.161/src/globals.h Fri Nov 2 16:29:44 2001 --- src/globals.h Sun Feb 3 11:57:48 2002 *************** *** 1132,1137 **** --- 1133,1141 ---- EXTERN char_u e_zerocount[] INIT(=N_("Zero count")); #ifdef FEAT_EVAL EXTERN char_u e_usingsid[] INIT(=N_("E81: Using not in a script context")); + #endif + #ifdef FEAT_CLIENTSERVER + EXTERN char_u e_invexprmsg[] INIT(=N_("E449: Invalid expression received")); #endif /* *** ../vim60.161/src/if_xcmdsrv.c Sat Nov 3 14:16:30 2001 --- src/if_xcmdsrv.c Sun Feb 3 12:18:33 2002 *************** *** 70,75 **** --- 70,76 ---- typedef struct PendingCommand { int serial; /* Serial number expected in result. */ + int code; /* Result Code. 0 is OK */ char_u *result; /* String result for command (malloc'ed). * NULL means command still pending. */ struct PendingCommand *nextPtr; *************** *** 136,141 **** --- 137,145 ---- * defaults to an empty string. * * -c code + * 0: for OK. This is the default. + * 1: for error: Result is the last error + * * -i errorInfo * -e errorCode * Not applicable for Vim *************** *** 385,393 **** ret = eval_to_string(cmd, NULL); --emsg_skip; if (result != NULL) ! *result = ret; else vim_free(ret); } else server_to_input_buf(cmd); --- 389,403 ---- ret = eval_to_string(cmd, NULL); --emsg_skip; if (result != NULL) ! { ! if (ret == NULL) ! *result = vim_strsave(_(e_invexprmsg)); ! else ! *result = ret; ! } else vim_free(ret); + return ret == NULL ? -1 : 0; } else server_to_input_buf(cmd); *************** *** 461,466 **** --- 471,477 ---- * AppendErrorProc to pass back the command's results). */ pending.serial = serial; + pending.code = 0; pending.result = NULL; pending.nextPtr = pendingCommands; pendingCommands = &pending; *************** *** 489,495 **** else vim_free(pending.result); ! return 0; } static int --- 500,506 ---- else vim_free(pending.result); ! return pending.code == 0 ? 0 : -1; } static int *************** *** 1092,1098 **** { char_u *propInfo; char_u *p; ! int result, actualFormat; long_u numItems, bytesAfter; Atom actualType; --- 1103,1109 ---- { char_u *propInfo; char_u *p; ! int result, actualFormat, code; long_u numItems, bytesAfter; Atom actualType; *************** *** 1223,1228 **** --- 1234,1245 ---- { if (res != NULL) ga_concat(&reply, res); + else if (asKeys == 0) + { + ga_concat(&reply, _(e_invexprmsg)); + ga_append(&reply, 0); + ga_concat(&reply, "-c 1"); + } ga_append(&reply, 0); (void)AppendPropCarefully(dpy, resWindow, commProperty, reply.ga_data, reply.ga_len); *************** *** 1243,1248 **** --- 1260,1266 ---- p += 2; gotSerial = 0; res = (char_u *)""; + code = 0; while ((p-propInfo) < numItems && *p == '-') { switch (p[1]) *************** *** 1255,1260 **** --- 1273,1282 ---- if (sscanf((char *)p + 2, " %d", &serial) == 1) gotSerial = 1; break; + case 'c': + if (sscanf((char *)p + 2, " %d", &code) != 1) + code = 0; + break; } while (*p != 0) p++; *************** *** 1273,1278 **** --- 1295,1301 ---- if (serial != pcPtr->serial || pcPtr->result != NULL) continue; + pcPtr->code = code; if (res != NULL) pcPtr->result = vim_strsave(res); else *** ../vim60.161/src/main.c Mon Nov 5 22:06:57 2001 --- src/main.c Sun Feb 3 11:45:33 2002 *************** *** 2628,2634 **** while (memchr(done, 0, numFiles) != NULL) { # ifdef WIN32 ! p = serverGetReply(srv, FALSE, TRUE, TRUE); if (p == NULL) break; # else --- 2628,2634 ---- while (memchr(done, 0, numFiles) != NULL) { # ifdef WIN32 ! p = serverGetReply(srv, NULL, TRUE, TRUE); if (p == NULL) break; # else *** ../vim60.161/src/os_mswin.c Sun Dec 30 21:52:17 2001 --- src/os_mswin.c Sun Feb 3 11:57:57 2002 *************** *** 1716,1725 **** /* Communication is via WM_COPYDATA messages. The message type is send in * the dwData parameter. Types are defined here. */ ! #define COPYDATA_KEYS 0 ! #define COPYDATA_REPLY 1 ! #define COPYDATA_EXPR 10 ! #define COPYDATA_RESULT 11 /* This is a structure containing a server HWND and its name. */ struct server_id --- 1716,1726 ---- /* Communication is via WM_COPYDATA messages. The message type is send in * the dwData parameter. Types are defined here. */ ! #define COPYDATA_KEYS 0 ! #define COPYDATA_REPLY 1 ! #define COPYDATA_EXPR 10 ! #define COPYDATA_RESULT 11 ! #define COPYDATA_ERROR_RESULT 12 /* This is a structure containing a server HWND and its name. */ struct server_id *************** *** 1775,1780 **** --- 1776,1784 ---- * COPYDATA_RESULT: * A reply. We are a client, and a server has sent this message * in response to a COPYDATA_EXPR. + * COPYDATA_ERROR_RESULT: + * A reply. We are a client, and a server has sent this message + * in response to a COPYDATA_EXPR that failed to evaluate. */ COPYDATASTRUCT *data = (COPYDATASTRUCT*)lParam; HWND sender = (HWND)wParam; *************** *** 1808,1815 **** res = eval_to_string(data->lpData, NULL); --emsg_skip; if (res == NULL) ! res = vim_strsave((char_u *)""); ! reply.dwData = COPYDATA_RESULT; reply.lpData = res; reply.cbData = STRLEN(res) + 1; --- 1812,1823 ---- res = eval_to_string(data->lpData, NULL); --emsg_skip; if (res == NULL) ! { ! res = vim_strsave(_(e_invexprmsg)); ! reply.dwData = COPYDATA_ERROR_RESULT; ! } ! else ! reply.dwData = COPYDATA_RESULT; reply.lpData = res; reply.cbData = STRLEN(res) + 1; *************** *** 1820,1829 **** case COPYDATA_REPLY: case COPYDATA_RESULT: if (data->lpData != NULL) { save_reply(sender, data->lpData, ! data->dwData == COPYDATA_RESULT); #ifdef FEAT_AUTOCMD if (data->dwData == COPYDATA_REPLY) { --- 1828,1840 ---- case COPYDATA_REPLY: case COPYDATA_RESULT: + case COPYDATA_ERROR_RESULT: if (data->lpData != NULL) { save_reply(sender, data->lpData, ! (data->dwData == COPYDATA_REPLY ? 0 : ! (data->dwData == COPYDATA_RESULT ? 1 : ! 2))); #ifdef FEAT_AUTOCMD if (data->dwData == COPYDATA_REPLY) { *************** *** 2071,2076 **** --- 2082,2088 ---- HWND target = findServer(name); COPYDATASTRUCT data; char_u *retval = NULL; + int retcode = 0; if (ptarget) *(HWND *)ptarget = target; *************** *** 2084,2097 **** return -1; if (asExpr) ! retval = serverGetReply(target, TRUE, TRUE, TRUE); if (result == NULL) vim_free(retval); else *result = retval; /* Caller assumes responsibility for freeing */ ! return 0; } /* --- 2096,2109 ---- return -1; if (asExpr) ! retval = serverGetReply(target, &retcode, TRUE, TRUE); if (result == NULL) vim_free(retval); else *result = retval; /* Caller assumes responsibility for freeing */ ! return retcode; } /* *************** *** 2119,2125 **** { HWND server; /* server window */ char_u *reply; /* reply string */ ! int expr_result; /* TRUE for COPYDATA_RESULT */ } reply_T; --- 2131,2137 ---- { HWND server; /* server window */ char_u *reply; /* reply string */ ! int expr_result; /* 0 for REPLY, 1 for RESULT 2 for error */ } reply_T; *************** *** 2155,2167 **** /* * Get a reply from server "server". ! * When "expr" is TRUE, get the result of an expression, otherwise a * server2client() message. * If "remove" is TRUE, consume the message, the caller must free it then. * if "wait" is TRUE block until a message arrives (or the server exits). */ char_u * ! serverGetReply(HWND server, int expr, int remove, int wait) { int i; char_u *reply; --- 2167,2180 ---- /* * Get a reply from server "server". ! * When "expr_res" is non NULL, get the result of an expression, otherwise a * server2client() message. + * When non NULL, point to return code. 0 => OK, -1 => ERROR * If "remove" is TRUE, consume the message, the caller must free it then. * if "wait" is TRUE block until a message arrives (or the server exits). */ char_u * ! serverGetReply(HWND server, int *expr_res, int remove, int wait) { int i; char_u *reply; *************** *** 2177,2186 **** for (i = 0; i < REPLY_COUNT; ++i) { rep = REPLY_ITEM(i); ! if (rep->server == server && rep->expr_result == expr) { /* Save the values we've found for later */ reply = rep->reply; if (remove) { --- 2190,2202 ---- for (i = 0; i < REPLY_COUNT; ++i) { rep = REPLY_ITEM(i); ! if (rep->server == server ! && ((rep->expr_result != 0) == (expr_res != NULL))) { /* Save the values we've found for later */ reply = rep->reply; + if (expr_res != NULL) + *expr_res = rep->expr_result == 1 ? 0 : -1; if (remove) { *** ../vim60.161/src/proto/os_mswin.pro Tue Sep 25 21:49:35 2001 --- src/proto/os_mswin.pro Sun Feb 3 11:45:33 2002 *************** *** 47,53 **** int serverSendReply __ARGS((char_u *name, char_u *reply)); int serverSendToVim __ARGS((char_u *name, char_u *cmd, char_u **result, void *ptarget, int asExpr)); void serverForeground __ARGS((char_u *name)); ! char_u *serverGetReply __ARGS((HWND server, int expr, int remove, int wait)); void serverProcessPendingMessages __ARGS((void)); char *charset_id2name __ARGS((int id)); int get_logfont __ARGS((LOGFONT *lf, char_u *name, HDC printer_dc)); --- 47,53 ---- int serverSendReply __ARGS((char_u *name, char_u *reply)); int serverSendToVim __ARGS((char_u *name, char_u *cmd, char_u **result, void *ptarget, int asExpr)); void serverForeground __ARGS((char_u *name)); ! char_u *serverGetReply __ARGS((HWND server, int *expr_res, int remove, int wait)); void serverProcessPendingMessages __ARGS((void)); char *charset_id2name __ARGS((int id)); int get_logfont __ARGS((LOGFONT *lf, char_u *name, HDC printer_dc)); *** ../vim60.161/runtime/doc/eval.txt Tue Sep 25 21:40:34 2001 --- runtime/doc/eval.txt Sun Feb 3 11:51:14 2002 *************** *** 671,676 **** --- 679,685 ---- *v:servername* *servername-variable* v:servername The resulting registered |x11-clientserver| name if any. + Read-only. *v:shell_error* *shell_error-variable* v:shell_error Result of the last shell command. When non-zero, the last *************** *** 1189,1195 **** sourced script file name word under the cursor WORD under the cursor ! The {serverid} of the las Modifiers: :p expand to full path :h head (last path component removed) --- 1205,1212 ---- sourced script file name word under the cursor WORD under the cursor ! the {clientid} of the last received ! message |server2client()| Modifiers: :p expand to full path :h head (last path component removed) *************** *** 1864,1870 **** < When {lnum} is invalid or there is no non-blank line at or above it, zero is returned. ! *remote_expr()* remote_expr({server}, {string} [, {idvar}]) Send the {string} to {server}. The string is sent as an expression and the result is returned after evaluation. --- 1874,1880 ---- < When {lnum} is invalid or there is no non-blank line at or above it, zero is returned. ! *remote_expr()* *E449* remote_expr({server}, {string} [, {idvar}]) Send the {string} to {server}. The string is sent as an expression and the result is returned after evaluation. *************** *** 1873,1883 **** remote_read() is stored there. See also |clientserver| |RemoteReply|. {only available when compiled with the |+clientserver| feature} ! Note: Any errors will be reported in the server and may mess ! up the display. Examples: > :echo remote_expr("gvim", "2+2") ! :echo remote_expr("gvim-001", "b:current_syntax") < remote_foreground({server}) *remote_foreground()* --- 1883,1893 ---- remote_read() is stored there. See also |clientserver| |RemoteReply|. {only available when compiled with the |+clientserver| feature} ! Note: Any errors will cause a local error message to be issued ! and the result will be the empty string. Examples: > :echo remote_expr("gvim", "2+2") ! :echo remote_expr("gvim1", "b:current_syntax") < remote_foreground({server}) *remote_foreground()* *** ../vim60.161/runtime/tools/xcmdsrv_client.c Sun Sep 2 14:51:52 2001 --- runtime/tools/xcmdsrv_client.c Sun Feb 3 11:45:33 2002 *************** *** 32,50 **** #define __ARGS(x) x /* Client API */ ! char * sendToVim __ARGS((Display *dpy, char *name, char *cmd, int asKeys)); #ifdef MAIN /* A sample program */ main(int argc, char **argv) { ! char *res; if (argc == 4) { ! if ((res = sendToVim(XOpenDisplay(NULL), ! argv[2], argv[3], argv[1][0] != 'e')) != NULL) puts(res); exit(0); } else --- 32,55 ---- #define __ARGS(x) x /* Client API */ ! char * sendToVim __ARGS((Display *dpy, char *name, char *cmd, int asKeys, int *code)); #ifdef MAIN /* A sample program */ main(int argc, char **argv) { ! char *res; ! int code; if (argc == 4) { ! if ((res = sendToVim(XOpenDisplay(NULL), argv[2], argv[3], ! argv[1][0] != 'e', &code)) != NULL) ! { ! if (code) ! printf("Error code returned: %d\n", code); puts(res); + } exit(0); } else *************** *** 72,78 **** int delete, char **loose)); static int SendInit __ARGS((Display *dpy)); static char *SendEventProc __ARGS((Display *dpy, XEvent *eventPtr, ! int expect)); static int IsSerialName __ARGS((char *name)); /* Private variables */ --- 77,83 ---- int delete, char **loose)); static int SendInit __ARGS((Display *dpy)); static char *SendEventProc __ARGS((Display *dpy, XEvent *eventPtr, ! int expect, int *code)); static int IsSerialName __ARGS((char *name)); /* Private variables */ *************** *** 91,101 **** */ char * ! sendToVim(dpy, name, cmd, asKeys) Display *dpy; /* Where to send. */ char *name; /* Where to send. */ char *cmd; /* What to send. */ int asKeys; /* Interpret as keystrokes or expr ? */ { Window w; Atom *plist; --- 96,107 ---- */ char * ! sendToVim(dpy, name, cmd, asKeys, code) Display *dpy; /* Where to send. */ char *name; /* Where to send. */ char *cmd; /* What to send. */ int asKeys; /* Interpret as keystrokes or expr ? */ + int *code; /* Return code. 0 => OK */ { Window w; Atom *plist; *************** *** 225,231 **** { XNextEvent(dpy, &event); if (event.type == PropertyNotify && e->window == commWindow) ! if ((result = SendEventProc(dpy, &event, serial)) != NULL) return result; } } --- 231,237 ---- { XNextEvent(dpy, &event); if (event.type == PropertyNotify && e->window == commWindow) ! if ((result = SendEventProc(dpy, &event, serial, code)) != NULL) return result; } } *************** *** 335,341 **** entry = p; while ((*p != 0) && (!isspace(*p))) p++; ! if ((*p != 0) && (strcmp(name, p + 1) == 0)) { sscanf(entry, "%x", (uint*) &returnValue); break; --- 341,347 ---- entry = p; while ((*p != 0) && (!isspace(*p))) p++; ! if ((*p != 0) && (strcasecmp(name, p + 1) == 0)) { sscanf(entry, "%x", (uint*) &returnValue); break; *************** *** 392,405 **** } static char * ! SendEventProc(dpy, eventPtr, expected) Display *dpy; XEvent *eventPtr; /* Information about event. */ int expected; /* The one were waiting for */ { unsigned char *propInfo; unsigned char *p; int result, actualFormat; unsigned long numItems, bytesAfter; Atom actualType; --- 398,413 ---- } static char * ! SendEventProc(dpy, eventPtr, expected, code) Display *dpy; XEvent *eventPtr; /* Information about event. */ int expected; /* The one were waiting for */ + int *code; /* Return code. 0 => OK */ { unsigned char *propInfo; unsigned char *p; int result, actualFormat; + int retCode; unsigned long numItems, bytesAfter; Atom actualType; *************** *** 469,474 **** --- 477,483 ---- p += 2; gotSerial = 0; res = ""; + retCode = 0; while (((p-propInfo) < numItems) && (*p == '-')) { switch (p[1]) *************** *** 481,486 **** --- 490,499 ---- if (sscanf(p + 2, " %d", &serial) == 1) gotSerial = 1; break; + case 'c': + if (sscanf(p + 2, " %d", &retCode) != 1) + retCode = 0; + break; } while (*p != 0) p++; *************** *** 490,495 **** --- 503,510 ---- if (!gotSerial) continue; + if (code != NULL) + *code = retCode; return serial == expected ? strdup(res) : NULL; } else *************** *** 556,578 **** } /* ! * Check if name looks like it had a 3 digit serial number appended */ static int IsSerialName(str) ! char *str; { ! if (strlen(str) < 5) ! return FALSE; ! str = str + strlen(str) - 4; ! if (*str++ != '-') ! return FALSE; ! if (!isdigit(*str++)) ! return FALSE; ! if (!isdigit(*str++)) ! return FALSE; ! if (!isdigit(*str++)) ! return FALSE; ! return TRUE; } --- 571,584 ---- } /* ! * Check if "str" looks like it had a serial number appended. ! * Actually just checks if the name ends in a digit. */ static int IsSerialName(str) ! char *str; { ! int len = strlen(str); ! return (len > 1 && isdigit(str[len - 1])); } *** ../vim60.161/src/version.c Sun Feb 3 12:33:39 2002 --- src/version.c Sun Feb 3 12:29:58 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 162, /**/ -- hundred-and-one symptoms of being an internet addict: 167. You have more than 100 websites in your Bookmark. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.163 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.163 Problem: When using a GUI dialog, a file name is sometimes used like it was a directory. Solution: Separate path and file name properly. For GTK, Motif and Athena concatenate directory and file name for the default selection. Files: src/diff.c, src/ex_cmds.c, src/ex_cmds2.c, src/ex_docmd.c, src/gui_athena.c, src/gui_gtk.c, src/gui_motif.c, src/message.c *** ../vim60.162/src/diff.c Wed Sep 19 18:36:35 2001 --- src/diff.c Sun Feb 3 13:43:37 2002 *************** *** 744,751 **** #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browseFile = do_browse(TRUE, (char_u *)_("Patch file"), ! NULL, NULL, eap->arg, BROWSE_FILTER_ALL_FILES, curbuf); if (browseFile == NULL) return; /* operation cancelled */ eap->arg = browseFile; --- 744,751 ---- #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browseFile = do_browse(FALSE, (char_u *)_("Patch file"), ! eap->arg, NULL, NULL, BROWSE_FILTER_ALL_FILES, NULL); if (browseFile == NULL) return; /* operation cancelled */ eap->arg = browseFile; *** ../vim60.162/src/ex_cmds.c Sun Feb 3 12:33:39 2002 --- src/ex_cmds.c Sun Feb 3 13:29:29 2002 *************** *** 2050,2057 **** #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browse_file = do_browse(TRUE, (char_u *)_("Save As"), NULL, ! NULL, ffname, NULL, curbuf); if (browse_file == NULL) goto theend; ffname = browse_file; --- 2050,2057 ---- #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browse_file = do_browse(TRUE, (char_u *)_("Save As"), ffname, ! NULL, NULL, NULL, curbuf); if (browse_file == NULL) goto theend; ffname = browse_file; *************** *** 2308,2314 **** /* ":browse wall": ask for file name if there isn't one */ if (buf->b_ffname == NULL && cmdmod.browse) buf->b_ffname = do_browse(TRUE, (char_u *)_("Save As"), NULL, ! NULL, (char_u *)"", NULL, buf); #endif if (buf->b_ffname == NULL) { --- 2308,2314 ---- /* ":browse wall": ask for file name if there isn't one */ if (buf->b_ffname == NULL && cmdmod.browse) buf->b_ffname = do_browse(TRUE, (char_u *)_("Save As"), NULL, ! NULL, NULL, NULL, buf); #endif if (buf->b_ffname == NULL) { *************** *** 2535,2542 **** #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browse_file = do_browse(FALSE, (char_u *)_("Edit File"), NULL, ! NULL, ffname, NULL, curbuf); if (browse_file == NULL) goto theend; ffname = browse_file; --- 2535,2542 ---- #ifdef FEAT_BROWSE if (cmdmod.browse) { ! browse_file = do_browse(FALSE, (char_u *)_("Edit File"), ffname, ! NULL, NULL, NULL, curbuf); if (browse_file == NULL) goto theend; ffname = browse_file; *** ../vim60.162/src/ex_cmds2.c Wed Oct 31 10:12:03 2001 --- src/ex_cmds2.c Sun Feb 3 13:44:58 2002 *************** *** 1711,1718 **** { char_u *fname = NULL; ! fname = do_browse(FALSE, (char_u *)_("Run Macro"), ! NULL, NULL, eap->arg, BROWSE_FILTER_MACROS, curbuf); if (fname != NULL) { cmd_source(fname, eap); --- 1711,1718 ---- { char_u *fname = NULL; ! fname = do_browse(FALSE, (char_u *)_("Run Macro"), eap->arg, ! NULL, NULL, BROWSE_FILTER_MACROS, NULL); if (fname != NULL) { cmd_source(fname, eap); *** ../vim60.162/src/ex_docmd.c Wed Jan 30 16:52:44 2002 --- src/ex_docmd.c Sun Feb 3 13:47:11 2002 *************** *** 5554,5560 **** && eap->cmdidx != CMD_new) { fname = do_browse(FALSE, (char_u *)_("Edit File in new window"), ! NULL, NULL, eap->arg, NULL, curbuf); if (fname == NULL) goto theend; eap->arg = fname; --- 5554,5560 ---- && eap->cmdidx != CMD_new) { fname = do_browse(FALSE, (char_u *)_("Edit File in new window"), ! eap->arg, NULL, NULL, NULL, curbuf); if (fname == NULL) goto theend; eap->arg = fname; *************** *** 5923,5930 **** { char_u *browseFile; ! browseFile = do_browse(FALSE, (char_u *)_("Append File"), NULL, ! NULL, eap->arg, NULL, curbuf); if (browseFile != NULL) { i = readfile(browseFile, NULL, --- 5923,5930 ---- { char_u *browseFile; ! browseFile = do_browse(FALSE, (char_u *)_("Append File"), eap->arg, ! NULL, NULL, NULL, curbuf); if (browseFile != NULL) { i = readfile(browseFile, NULL, *************** *** 6449,6455 **** if (cmdmod.browse) { browseFile = do_browse(TRUE, (char_u *)_("Save Redirection"), ! NULL, NULL, eap->arg, BROWSE_FILTER_ALL_FILES, curbuf); if (browseFile == NULL) return; /* operation cancelled */ eap->arg = browseFile; --- 6449,6455 ---- if (cmdmod.browse) { browseFile = do_browse(TRUE, (char_u *)_("Save Redirection"), ! eap->arg, NULL, NULL, BROWSE_FILTER_ALL_FILES, curbuf); if (browseFile == NULL) return; /* operation cancelled */ eap->arg = browseFile; *************** *** 6601,6607 **** eap->cmdidx == CMD_mksession ? (char_u *)_("Save Session") : # endif (char_u *)_("Save Setup"), ! NULL, (char_u *)"vim", fname, BROWSE_FILTER_MACROS, curbuf); if (browseFile == NULL) goto theend; fname = browseFile; --- 6601,6607 ---- eap->cmdidx == CMD_mksession ? (char_u *)_("Save Session") : # endif (char_u *)_("Save Setup"), ! fname, (char_u *)"vim", NULL, BROWSE_FILTER_MACROS, NULL); if (browseFile == NULL) goto theend; fname = browseFile; *** ../vim60.162/src/gui_athena.c Wed Dec 12 20:36:34 2001 --- src/gui_athena.c Sun Feb 3 15:24:05 2002 *************** *** 1836,1841 **** --- 1836,1856 ---- char_u *filter; /* not used (file name filter) */ { Position x, y; + char_u dirbuf[MAXPATHL]; + + /* Concatenate "initdir" and "dflt". */ + if (initdir == NULL || *initdir == NUL) + mch_dirname(dirbuf, MAXPATHL); + else if (STRLEN(initdir) + 2 < MAXPATHL) + STRCPY(dirbuf, initdir); + else + dirbuf[0] = NUL; + if (dflt != NULL && *dflt != NUL + && STRLEN(dirbuf) + 2 + STRLEN(dflt) < MAXPATHL) + { + add_pathsep(dirbuf); + STRCAT(dirbuf, dflt); + } /* Position the file selector just below the menubar */ XtTranslateCoords(vimShell, (Position)0, (Position) *************** *** 1845,1851 **** 0 #endif , &x, &y); ! return (char_u *)vim_SelFile(vimShell, (char *)title, (char *)initdir, NULL, (int)x, (int)y, gui.menu_fg_pixel, gui.menu_bg_pixel); } #endif --- 1860,1866 ---- 0 #endif , &x, &y); ! return (char_u *)vim_SelFile(vimShell, (char *)title, (char *)dirbuf, NULL, (int)x, (int)y, gui.menu_fg_pixel, gui.menu_bg_pixel); } #endif *** ../vim60.162/src/gui_gtk.c Fri Dec 14 20:19:45 2001 --- src/gui_gtk.c Sun Feb 3 15:25:14 2002 *************** *** 875,890 **** /* if our pointer is currently hidden, then we should show it. */ gui_mch_mousehide(FALSE); ! if (dflt == NULL) ! dflt = (char_u *)""; if (initdir == NULL || *initdir == NUL) - { mch_dirname(dirbuf, MAXPATHL); ! strcat((char *)dirbuf, "/"); /* make sure this is a directory */ ! initdir = dirbuf; ! } gtk_file_selection_set_filename(GTK_FILE_SELECTION(gui.filedlg), ! (const gchar *)initdir); gui_gtk_position_in_parent(GTK_WIDGET(gui.mainwin), GTK_WIDGET(gui.filedlg), VW_POS_MOUSE); --- 875,895 ---- /* if our pointer is currently hidden, then we should show it. */ gui_mch_mousehide(FALSE); ! /* Concatenate "initdir" and "dflt". */ if (initdir == NULL || *initdir == NUL) mch_dirname(dirbuf, MAXPATHL); ! else if (STRLEN(initdir) + 2 < MAXPATHL) ! STRCPY(dirbuf, initdir); ! else ! dirbuf[0] = NUL; ! /* Always need a trailing slash for a directory. */ ! add_pathsep(dirbuf); ! if (dflt != NULL && *dflt != NUL ! && STRLEN(dirbuf) + 2 + STRLEN(dflt) < MAXPATHL) ! STRCAT(dirbuf, dflt); ! gtk_file_selection_set_filename(GTK_FILE_SELECTION(gui.filedlg), ! (const gchar *)dirbuf); gui_gtk_position_in_parent(GTK_WIDGET(gui.mainwin), GTK_WIDGET(gui.filedlg), VW_POS_MOUSE); *************** *** 900,906 **** #endif /* FEAT_BROWSE */ ! #ifdef FEAT_GUI_DIALOG static char_u *dialog_textfield = NULL; static GtkWidget *dialog_textentry; --- 905,911 ---- #endif /* FEAT_BROWSE */ ! #if defined(FEAT_GUI_DIALOG) || defined(PROTO) static char_u *dialog_textfield = NULL; static GtkWidget *dialog_textentry; *** ../vim60.162/src/gui_motif.c Wed Sep 26 16:47:48 2001 --- src/gui_motif.c Sun Feb 3 14:23:53 2002 *************** *** 1531,1537 **** str = XmStringCreate(new_label, STRING_TAG); ! if (str) { XtVaSetValues(w, XmNlabelString, str, NULL); XmStringFree(str); } --- 1531,1538 ---- str = XmStringCreate(new_label, STRING_TAG); ! if (str) ! { XtVaSetValues(w, XmNlabelString, str, NULL); XmStringFree(str); } *************** *** 1552,1568 **** char_u *filter; /* file name filter */ { char_u dirbuf[MAXPATHL]; char_u *pattern; char_u *tofree = NULL; dialog_wgt = XmCreateFileSelectionDialog(vimShell, (char *)title, NULL, 0); - if (dflt == NULL) - dflt = (char_u *)""; if (initdir == NULL || *initdir == NUL) { mch_dirname(dirbuf, MAXPATHL); initdir = dirbuf; } /* Can only use one pattern for a file name. Get the first pattern out of --- 1553,1580 ---- char_u *filter; /* file name filter */ { char_u dirbuf[MAXPATHL]; + char_u dfltbuf[MAXPATHL]; char_u *pattern; char_u *tofree = NULL; dialog_wgt = XmCreateFileSelectionDialog(vimShell, (char *)title, NULL, 0); if (initdir == NULL || *initdir == NUL) { mch_dirname(dirbuf, MAXPATHL); initdir = dirbuf; + } + + if (dflt == NULL) + dflt = (char_u *)""; + else if (STRLEN(initdir) + STRLEN(dflt) + 2 < MAXPATHL) + { + /* The default selection should be the full path, "dflt" is only the + * file name. */ + STRCPY(dfltbuf, initdir); + add_pathsep(dfltbuf); + STRCAT(dfltbuf, dflt); + dflt = dfltbuf; } /* Can only use one pattern for a file name. Get the first pattern out of *** ../vim60.162/src/message.c Fri Sep 28 22:19:57 2001 --- src/message.c Sun Feb 3 13:42:00 2002 *************** *** 2475,2483 **** do_browse(saving, title, dflt, ext, initdir, filter, buf) int saving; /* write action */ char_u *title; /* title for the window */ ! char_u *dflt; /* default file name */ char_u *ext; /* extension added */ ! char_u *initdir; /* initial directory, NULL for current dir */ char_u *filter; /* file name filter */ buf_T *buf; /* buffer to read/write for */ { --- 2475,2484 ---- do_browse(saving, title, dflt, ext, initdir, filter, buf) int saving; /* write action */ char_u *title; /* title for the window */ ! char_u *dflt; /* default file name (may include directory) */ char_u *ext; /* extension added */ ! char_u *initdir; /* initial directory, NULL for current dir or ! when using path from "dflt" */ char_u *filter; /* file name filter */ buf_T *buf; /* buffer to read/write for */ { *************** *** 2498,2505 **** title = (char_u *)_("Open File dialog"); } ! /* When no directory specified, use default dir, buffer dir, last dir ! * or current dir */ if (initdir == NULL || *initdir == NUL) { /* When 'browsedir' is a directory, use it */ --- 2499,2525 ---- title = (char_u *)_("Open File dialog"); } ! /* When no directory specified, use default file name, default dir, buffer ! * dir, last dir or current dir */ ! if ((initdir == NULL || *initdir == NUL) && dflt != NULL && *dflt != NUL) ! { ! if (mch_isdir(dflt)) /* default file name is a directory */ ! { ! initdir = dflt; ! dflt = NULL; ! } ! else if (gettail(dflt) != dflt) /* default file name includes a path */ ! { ! tofree = vim_strsave(dflt); ! if (tofree != NULL) ! { ! initdir = tofree; ! *gettail(initdir) = NUL; ! dflt = gettail(dflt); ! } ! } ! } ! if (initdir == NULL || *initdir == NUL) { /* When 'browsedir' is a directory, use it */ *************** *** 2509,2515 **** else if ((saving || *p_bsdir == 'b') && buf != NULL && buf->b_ffname != NULL) { ! dflt = gettail(curbuf->b_ffname); tofree = vim_strsave(curbuf->b_ffname); if (tofree != NULL) { --- 2529,2536 ---- else if ((saving || *p_bsdir == 'b') && buf != NULL && buf->b_ffname != NULL) { ! if (dflt == NULL || *dflt == NUL) ! dflt = gettail(curbuf->b_ffname); tofree = vim_strsave(curbuf->b_ffname); if (tofree != NULL) { *************** *** 2560,2566 **** *gettail(last_dir) = NUL; if (*last_dir == NUL) { ! /* filename only returned, must be in current dir*/ vim_free(last_dir); last_dir = alloc(MAXPATHL); if (last_dir != NULL) --- 2581,2587 ---- *gettail(last_dir) = NUL; if (*last_dir == NUL) { ! /* filename only returned, must be in current dir */ vim_free(last_dir); last_dir = alloc(MAXPATHL); if (last_dir != NULL) *** ../vim60.162/src/version.c Sun Feb 3 12:42:13 2002 --- src/version.c Sun Feb 3 15:16:22 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 163, /**/ -- hundred-and-one symptoms of being an internet addict: 168. You have your own domain name. /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim ))) \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org /// To: vim-dev@vim.org Subject: Patch 6.0.164 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.0.164 Problem: After patch 6.0.135 the menu entries for pasting don't work in Insert and Visual mode. (Muraoka Taro) Solution: Add