Mirror of the Vim source from https://github.com/vim/vim
Revisión | dd9db57ee7ce46bdc86cd787fb58907f20c0a973 (tree) |
---|---|
Tiempo | 2005-07-29 07:36:45 |
Autor | vimboss |
Commiter | vimboss |
updated for version 7.0118
@@ -1,4 +1,4 @@ | ||
1 | -*eval.txt* For Vim version 7.0aa. Last change: 2005 Jul 25 | |
1 | +*eval.txt* For Vim version 7.0aa. Last change: 2005 Jul 28 | |
2 | 2 | |
3 | 3 | |
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -2416,29 +2416,24 @@ | ||
2416 | 2416 | |
2417 | 2417 | *getbufline()* |
2418 | 2418 | getbufline({expr}, {lnum} [, {end}]) |
2419 | - Return the lines starting from {lnum} to {end} in the buffer | |
2420 | - {expr} as a List. If {end} is omitted, only the line {lnum} | |
2421 | - is returned. | |
2419 | + Return a List with the lines starting from {lnum} to {end} | |
2420 | + (inclusive) in the buffer {expr}. If {end} is omitted, a List | |
2421 | + with only the line {lnum} is returned. | |
2422 | 2422 | |
2423 | 2423 | For the use of {expr}, see |bufname()| above. |
2424 | 2424 | |
2425 | - When {lnum} is a String that doesn't start with a | |
2426 | - digit, line() is called to translate the String into a Number. | |
2427 | - | |
2428 | - {end} is used in the same way as {lnum}. | |
2425 | + For {lnum} and {end} "$" can be used for the last line of the | |
2426 | + buffer. Otherwise a number must be used. | |
2429 | 2427 | |
2430 | 2428 | When {lnum} is smaller than 1 or bigger than the number of |
2431 | 2429 | lines in the buffer, an empty List is returned. |
2432 | 2430 | |
2433 | 2431 | When {end} is greater than the number of lines in the buffer, |
2434 | 2432 | it is treated as {end} is set to the number of lines in the |
2435 | - buffer. | |
2436 | - | |
2437 | - When non-existing line ranges are specified, an empty List is | |
2438 | - returned. When {end} is before {lnum} an empty List is | |
2433 | + buffer. When {end} is before {lnum} an empty List is | |
2439 | 2434 | returned. |
2440 | 2435 | |
2441 | - This function works only for loaded buffers. For unloaded and | |
2436 | + This function works only for loaded buffers. For unloaded and | |
2442 | 2437 | non-existing buffers, an empty List is returned. |
2443 | 2438 | |
2444 | 2439 | Example: > |
@@ -1,4 +1,4 @@ | ||
1 | -*options.txt* For Vim version 7.0aa. Last change: 2005 Jul 26 | |
1 | +*options.txt* For Vim version 7.0aa. Last change: 2005 Jul 28 | |
2 | 2 | |
3 | 3 | |
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -2282,9 +2282,11 @@ | ||
2282 | 2282 | |viminfo-file|. And Vim expects the terminal to use utf-8 too. Thus |
2283 | 2283 | setting 'encoding' to one of these values instead of utf-8 only has |
2284 | 2284 | effect for encoding used for files when 'fileencoding' is empty. |
2285 | - | |
2286 | - When 'encoding' is set to a Unicode encoding, and 'fileencodings' was | |
2287 | - not set yet, the default for 'fileencodings' is changed. | |
2285 | + "utf-16" is NOT supported (and probably never will be, since it's such | |
2286 | + an ugly encoding). *utf-16* | |
2287 | + | |
2288 | + When 'encoding' is set to a Unicode encoding, and 'fileencodings' was | |
2289 | + not set yet, the default for 'fileencodings' is changed. | |
2288 | 2290 | |
2289 | 2291 | *'endofline'* *'eol'* *'noendofline'* *'noeol'* |
2290 | 2292 | 'endofline' 'eol' boolean (default on) |
@@ -1,4 +1,4 @@ | ||
1 | -*syntax.txt* For Vim version 7.0aa. Last change: 2005 Jul 18 | |
1 | +*syntax.txt* For Vim version 7.0aa. Last change: 2005 Jul 28 | |
2 | 2 | |
3 | 3 | |
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -3641,6 +3641,15 @@ | ||
3641 | 3641 | result is like this single command has been used: > |
3642 | 3642 | :hi Comment term=bold ctermfg=Cyan guifg=#80a0ff gui=bold |
3643 | 3643 | < |
3644 | +When listing a highlight group and 'verbose' is non-zero, the listing will | |
3645 | +also tell where it was last set. Example: > | |
3646 | + :verbose hi Comment | |
3647 | +< Comment xxx term=bold ctermfg=4 guifg=Blue ~ | |
3648 | + Last set from /home/mool/vim/vim7/runtime/syntax/syncolor.vim ~ | |
3649 | + | |
3650 | +For details about when this message is given and when it's valid see | |
3651 | +|:set-verbose|. | |
3652 | + | |
3644 | 3653 | *highlight-args* *E416* *E417* *E423* |
3645 | 3654 | There are three types of terminals for highlighting: |
3646 | 3655 | term a normal terminal (vt100, xterm) |
@@ -4984,6 +4984,7 @@ | ||
4984 | 4984 | g:netrw_rmf_cmd pi_netrw.txt /*g:netrw_rmf_cmd* |
4985 | 4985 | g:var eval.txt /*g:var* |
4986 | 4986 | g; motion.txt /*g;* |
4987 | +g< message.txt /*g<* | |
4987 | 4988 | g<Down> motion.txt /*g<Down>* |
4988 | 4989 | g<End> motion.txt /*g<End>* |
4989 | 4990 | g<Home> motion.txt /*g<Home>* |
@@ -6746,6 +6747,7 @@ | ||
6746 | 6747 | usr_45.txt usr_45.txt /*usr_45.txt* |
6747 | 6748 | usr_90.txt usr_90.txt /*usr_90.txt* |
6748 | 6749 | usr_toc.txt usr_toc.txt /*usr_toc.txt* |
6750 | +utf-16 options.txt /*utf-16* | |
6749 | 6751 | utf-8 mbyte.txt /*utf-8* |
6750 | 6752 | utf-8-char-arg mbyte.txt /*utf-8-char-arg* |
6751 | 6753 | utf-8-in-xwindows mbyte.txt /*utf-8-in-xwindows* |
@@ -1,4 +1,4 @@ | ||
1 | -*todo.txt* For Vim version 7.0aa. Last change: 2005 Jul 27 | |
1 | +*todo.txt* For Vim version 7.0aa. Last change: 2005 Jul 28 | |
2 | 2 | |
3 | 3 | |
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -30,6 +30,8 @@ | ||
30 | 30 | *known-bugs* |
31 | 31 | -------------------- Known bugs and current work ----------------------- |
32 | 32 | |
33 | +Is it simple to let ":verbose hi mailSubject" mention where it was last set? | |
34 | + | |
33 | 35 | Mac unicode patch (Da Woon Jung): |
34 | 36 | - selecting proportional font breaks display |
35 | 37 | - UTF-8 text causes display problems. Font replacement causes this. |
@@ -52,8 +54,6 @@ | ||
52 | 54 | - Win32: tearoff menu window should have a scrollbar when it's taller than |
53 | 55 | the screen. |
54 | 56 | - mblen(NULL, 0) also in Vim 6.3? |
55 | -- Win32: Crash when pasting Simplified Chinese in utf-8. (rainux, 2005 June | |
56 | - 20) | |
57 | 57 | |
58 | 58 | |
59 | 59 | PLANNED FOR VERSION 7.0: |
@@ -1,4 +1,4 @@ | ||
1 | -*version7.txt* For Vim version 7.0aa. Last change: 2005 Jul 27 | |
1 | +*version7.txt* For Vim version 7.0aa. Last change: 2005 Jul 28 | |
2 | 2 | |
3 | 3 | |
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -238,6 +238,9 @@ | ||
238 | 238 | commands and highlighting is kept. Only works when the 'more' option is set. |
239 | 239 | Previously it only partly worked for ":clist". |
240 | 240 | |
241 | +The |g<| command can be used to see the last page of messages after you have | |
242 | +hit <Enter> at the |hit-enter-prompt|. Then you can scroll further back. | |
243 | + | |
241 | 244 | |
242 | 245 | POSIX compatibility *new-posix* |
243 | 246 | ------------------- |
@@ -724,6 +727,9 @@ | ||
724 | 727 | The 's' flag is added to the search() and searchpair() function to set the |
725 | 728 | ' mark if the cursor is moved. (Yegappan Lakshmanan) |
726 | 729 | |
730 | +When 'verbose' is set the output of ":highlight" will show where a highlight | |
731 | +item was last set. | |
732 | + | |
727 | 733 | ============================================================================== |
728 | 734 | COMPILE TIME CHANGES *compile-changes-7* |
729 | 735 |
@@ -14,11 +14,11 @@ | ||
14 | 14 | |
15 | 15 | $(SPELLDIR)/de.latin1.spl : $(VIM) $(FILES) |
16 | 16 | :sys env LANG=de_DE.ISO8859-1 |
17 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/de de_DE" -c q | |
17 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/de de_DE" -c q | |
18 | 18 | |
19 | 19 | $(SPELLDIR)/de.utf-8.spl : $(VIM) $(FILES) |
20 | 20 | :sys env LANG=de_DE.UTF-8 |
21 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/de de_DE" -c q | |
21 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/de de_DE" -c q | |
22 | 22 | |
23 | 23 | ../README_de.txt: README_de_DE_comb.txt |
24 | 24 | :copy $source $target |
@@ -18,16 +18,16 @@ | ||
18 | 18 | |
19 | 19 | $(SPELLDIR)/en.latin1.spl : $(VIM) $(FILES) |
20 | 20 | :sys env LANG=en_US.ISO8859-1 |
21 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/en en_US en_AU en_CA en_GB | |
22 | - en_NZ" -c q | |
21 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/en | |
22 | + en_US en_AU en_CA en_GB en_NZ" -c q | |
23 | 23 | |
24 | 24 | $(SPELLDIR)/en.utf-8.spl : $(VIM) $(FILES) |
25 | 25 | :sys env LANG=en_US.UTF-8 |
26 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/en en_US en_AU en_CA en_GB | |
27 | - en_NZ" -c q | |
26 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/en | |
27 | + en_US en_AU en_CA en_GB en_NZ" -c q | |
28 | 28 | |
29 | 29 | $(SPELLDIR)/en.ascii.spl : $(VIM) $(FILES) |
30 | - :sys $(VIM) -e -c "mkspell! -ascii $(SPELLDIR)/en | |
30 | + :sys $(VIM) -u NONE -e -c "mkspell! -ascii $(SPELLDIR)/en | |
31 | 31 | en_US en_AU en_CA en_GB en_NZ" -c q |
32 | 32 | |
33 | 33 | ../README_en.txt: README_en_US.txt README_en_AU.txt |
@@ -13,10 +13,10 @@ | ||
13 | 13 | |
14 | 14 | $(SPELLDIR)/he.utf-8.spl : $(VIM) $(FILES) |
15 | 15 | :sys env LANG=he_IL.UTF-8 |
16 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/he he_IL" -c q | |
16 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/he he_IL" -c q | |
17 | 17 | |
18 | 18 | $(SPELLDIR)/he.iso-8859-8.spl : $(VIM) $(FILES) |
19 | - :sys $(VIM) -e -c "set enc=iso-8859-8" | |
19 | + :sys $(VIM) -u NONE -e -c "set enc=iso-8859-8" | |
20 | 20 | -c "mkspell! $(SPELLDIR)/he he_IL" -c q |
21 | 21 | |
22 | 22 | ../README_he.txt : README_he_IL.txt |
@@ -13,11 +13,11 @@ | ||
13 | 13 | |
14 | 14 | $(SPELLDIR)/nl.latin1.spl : $(VIM) $(FILES) |
15 | 15 | :sys env LANG=nl_NL.ISO8859-1 |
16 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/nl nl_NL" -c q | |
16 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/nl nl_NL" -c q | |
17 | 17 | |
18 | 18 | $(SPELLDIR)/nl.utf-8.spl : $(VIM) $(FILES) |
19 | 19 | :sys env LANG=nl_NL.UTF-8 |
20 | - $(VIM) -e -c "mkspell! $(SPELLDIR)/nl nl_NL" -c q | |
20 | + $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/nl nl_NL" -c q | |
21 | 21 | |
22 | 22 | ../README_nl.txt : README_nl_NL.txt |
23 | 23 | :copy $source $target |
@@ -13,13 +13,13 @@ | ||
13 | 13 | $(SPELLDIR)/pl.cp1250.spl ../README_pl.txt |
14 | 14 | |
15 | 15 | $(SPELLDIR)/pl.iso-8859-2.spl : $(VIM) $(FILES) |
16 | - :sys env LANG=pl_PL.ISO8859-2 $(VIM) -e -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
16 | + :sys env LANG=pl_PL.ISO8859-2 $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
17 | 17 | |
18 | 18 | $(SPELLDIR)/pl.utf-8.spl : $(VIM) $(FILES) |
19 | - :sys env LANG=pl_PL.UTF-8 $(VIM) -e -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
19 | + :sys env LANG=pl_PL.UTF-8 $(VIM) -u NONE -e -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
20 | 20 | |
21 | 21 | $(SPELLDIR)/pl.cp1250.spl : $(VIM) $(FILES) |
22 | - :sys $(VIM) -e -c "set enc=cp1250" -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
22 | + :sys $(VIM) -u NONE -e -c "set enc=cp1250" -c "mkspell! $(SPELLDIR)/pl pl_PL" -c q | |
23 | 23 | |
24 | 24 | ../README_pl.txt: README_pl_PL.txt |
25 | 25 | :copy $source $target |
@@ -643,6 +643,7 @@ | ||
643 | 643 | static long get_tv_number __ARGS((typval_T *varp)); |
644 | 644 | static long get_tv_number_chk __ARGS((typval_T *varp, int *denote)); |
645 | 645 | static linenr_T get_tv_lnum __ARGS((typval_T *argvars)); |
646 | +static linenr_T get_tv_lnum_buf __ARGS((typval_T *argvars, buf_T *buf)); | |
646 | 647 | static char_u *get_tv_string __ARGS((typval_T *varp)); |
647 | 648 | static char_u *get_tv_string_buf __ARGS((typval_T *varp, char_u *buf)); |
648 | 649 | static char_u *get_tv_string_chk __ARGS((typval_T *varp)); |
@@ -9187,11 +9188,12 @@ | ||
9187 | 9188 | buf = get_buf_tv(&argvars[0]); |
9188 | 9189 | --emsg_off; |
9189 | 9190 | |
9190 | - lnum = get_tv_lnum(&argvars[1]); | |
9191 | + lnum = get_tv_lnum_buf(&argvars[1], buf); | |
9191 | 9192 | if (argvars[2].v_type == VAR_UNKNOWN) |
9192 | 9193 | end = lnum; |
9193 | 9194 | else |
9194 | - end = get_tv_lnum(&argvars[2]); | |
9195 | + end = get_tv_lnum_buf(&argvars[2], buf); | |
9196 | + | |
9195 | 9197 | get_buffer_lines(buf, lnum, end, TRUE, rettv); |
9196 | 9198 | } |
9197 | 9199 |
@@ -15651,7 +15653,8 @@ | ||
15651 | 15653 | } |
15652 | 15654 | |
15653 | 15655 | /* |
15654 | - * Get the lnum from the first argument. Also accepts ".", "$", etc. | |
15656 | + * Get the lnum from the first argument. | |
15657 | + * Also accepts ".", "$", etc., but that only works for the current buffer. | |
15655 | 15658 | * Returns -1 on error. |
15656 | 15659 | */ |
15657 | 15660 | static linenr_T |
@@ -15673,6 +15676,24 @@ | ||
15673 | 15676 | } |
15674 | 15677 | |
15675 | 15678 | /* |
15679 | + * Get the lnum from the first argument. | |
15680 | + * Also accepts "$", then "buf" is used. | |
15681 | + * Returns 0 on error. | |
15682 | + */ | |
15683 | + static linenr_T | |
15684 | +get_tv_lnum_buf(argvars, buf) | |
15685 | + typval_T *argvars; | |
15686 | + buf_T *buf; | |
15687 | +{ | |
15688 | + if (argvars[0].v_type == VAR_STRING | |
15689 | + && argvars[0].vval.v_string != NULL | |
15690 | + && argvars[0].vval.v_string[0] == '$' | |
15691 | + && buf != NULL) | |
15692 | + return buf->b_ml.ml_line_count; | |
15693 | + return get_tv_number_chk(&argvars[0], NULL); | |
15694 | +} | |
15695 | + | |
15696 | +/* | |
15676 | 15697 | * Get the string value of a variable. |
15677 | 15698 | * If it is a Number variable, the number is converted into a string. |
15678 | 15699 | * get_tv_string() uses a single, static buffer. YOU CAN ONLY USE IT ONCE! |
@@ -18678,6 +18699,23 @@ | ||
18678 | 18699 | } |
18679 | 18700 | #endif |
18680 | 18701 | |
18702 | +/* | |
18703 | + * Display script name where an item was last set. | |
18704 | + * Should only be invoked when 'verbose' is non-zero. | |
18705 | + */ | |
18706 | + void | |
18707 | +last_set_msg(scriptID) | |
18708 | + scid_T scriptID; | |
18709 | +{ | |
18710 | + if (scriptID != 0) | |
18711 | + { | |
18712 | + verbose_enter(); | |
18713 | + MSG_PUTS(_("\n\tLast set from ")); | |
18714 | + MSG_PUTS(get_scriptname(scriptID)); | |
18715 | + verbose_leave(); | |
18716 | + } | |
18717 | +} | |
18718 | + | |
18681 | 18719 | #endif /* FEAT_EVAL */ |
18682 | 18720 | |
18683 | 18721 | #if defined(FEAT_MODIFY_FNAME) || defined(FEAT_EVAL) || defined(PROTO) |
@@ -1034,7 +1034,7 @@ | ||
1034 | 1034 | emsg_on_display = FALSE; /* can delete error message now */ |
1035 | 1035 | did_emsg = FALSE; |
1036 | 1036 | msg_didany = FALSE; /* reset lines_left in msg_start() */ |
1037 | - clear_sb_text(); /* clear scroll-back text */ | |
1037 | + may_clear_sb_text(); /* clear scroll-back text on next msg */ | |
1038 | 1038 | showruler(FALSE); |
1039 | 1039 | |
1040 | 1040 | setcursor(); |
@@ -870,10 +870,13 @@ | ||
870 | 870 | if (releasing) |
871 | 871 | break; |
872 | 872 | releasing = TRUE; |
873 | - try_again = mf_release_all(); | |
873 | + | |
874 | + clear_sb_text(); /* free any scrollback text */ | |
875 | + try_again = mf_release_all(); /* release as many blocks as possible */ | |
874 | 876 | #ifdef FEAT_EVAL |
875 | - try_again |= garbage_collect(); | |
876 | -#endif | |
877 | + try_again |= garbage_collect(); /* cleanup recursive lists/dicts */ | |
878 | +#endif | |
879 | + | |
877 | 880 | releasing = FALSE; |
878 | 881 | if (!try_again) |
879 | 882 | break; |
@@ -3814,15 +3814,7 @@ | ||
3814 | 3814 | showoneopt(&options[opt_idx], opt_flags); |
3815 | 3815 | #ifdef FEAT_EVAL |
3816 | 3816 | if (p_verbose > 0) |
3817 | - { | |
3818 | - if (options[opt_idx].scriptID != 0) | |
3819 | - { | |
3820 | - verbose_enter(); | |
3821 | - MSG_PUTS(_("\n\tLast set from ")); | |
3822 | - MSG_PUTS(get_scriptname(options[opt_idx].scriptID)); | |
3823 | - verbose_leave(); | |
3824 | - } | |
3825 | - } | |
3817 | + last_set_msg(options[opt_idx].scriptID); | |
3826 | 3818 | #endif |
3827 | 3819 | } |
3828 | 3820 | else |
@@ -27,6 +27,7 @@ | ||
27 | 27 | zh_CN.UTF-8 \ |
28 | 28 | zh_TW \ |
29 | 29 | zh_TW.UTF-8 \ |
30 | +# end marker | |
30 | 31 | |
31 | 32 | MOFILES = \ |
32 | 33 | af.mo \ |
@@ -51,6 +52,7 @@ | ||
51 | 52 | zh_CN.mo \ |
52 | 53 | zh_TW.UTF-8.mo \ |
53 | 54 | zh_TW.mo \ |
55 | +# end marker | |
54 | 56 | |
55 | 57 | CONVERTED = \ |
56 | 58 | cs.cp1250.mo \ |
@@ -60,6 +62,7 @@ | ||
60 | 62 | sk.cp1250.mo \ |
61 | 63 | uk.cp1251.mo \ |
62 | 64 | zh_CN.cp936.mo \ |
65 | +# end marker | |
63 | 66 | |
64 | 67 | CHECKFILES = \ |
65 | 68 | af.ck \ |
@@ -91,6 +94,7 @@ | ||
91 | 94 | sk.cp1250.ck \ |
92 | 95 | uk.cp1251.ck \ |
93 | 96 | zh_CN.cp936.ck \ |
97 | +# end marker | |
94 | 98 | |
95 | 99 | PACKAGE = vim |
96 | 100 | SHELL = /bin/sh |
@@ -86,6 +86,7 @@ | ||
86 | 86 | int read_viminfo_varlist __ARGS((vir_T *virp, int writing)); |
87 | 87 | void write_viminfo_varlist __ARGS((FILE *fp)); |
88 | 88 | int store_session_globals __ARGS((FILE *fd)); |
89 | +void last_set_msg __ARGS((scid_T scriptID)); | |
89 | 90 | int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen)); |
90 | 91 | char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags)); |
91 | 92 | /* vim: set ft=c : */ |
@@ -39,7 +39,9 @@ | ||
39 | 39 | void msg_puts_long_attr __ARGS((char_u *longstr, int attr)); |
40 | 40 | void msg_puts_long_len_attr __ARGS((char_u *longstr, int len, int attr)); |
41 | 41 | void msg_puts_attr __ARGS((char_u *s, int attr)); |
42 | +void may_clear_sb_text __ARGS((void)); | |
42 | 43 | void clear_sb_text __ARGS((void)); |
44 | +void show_sb_text __ARGS((void)); | |
43 | 45 | int msg_use_printf __ARGS((void)); |
44 | 46 | void mch_errmsg __ARGS((char *str)); |
45 | 47 | void mch_msg __ARGS((char *str)); |
@@ -51,6 +51,9 @@ | ||
51 | 51 | #endif |
52 | 52 | int sg_link; /* link to this highlight group ID */ |
53 | 53 | int sg_set; /* combination of SG_* flags */ |
54 | +#ifdef FEAT_EVAL | |
55 | + scid_T sg_scriptID; /* script in which the group was last set */ | |
56 | +#endif | |
54 | 57 | }; |
55 | 58 | |
56 | 59 | #define SG_TERM 1 /* term has been set */ |
@@ -6352,6 +6355,9 @@ | ||
6352 | 6355 | if (!init) |
6353 | 6356 | HL_TABLE()[from_id - 1].sg_set |= SG_LINK; |
6354 | 6357 | HL_TABLE()[from_id - 1].sg_link = to_id; |
6358 | +#ifdef FEAT_EVAL | |
6359 | + HL_TABLE()[from_id - 1].sg_scriptID = current_SID; | |
6360 | +#endif | |
6355 | 6361 | redraw_all_later(NOT_VALID); |
6356 | 6362 | } |
6357 | 6363 | } |
@@ -7101,6 +7107,9 @@ | ||
7101 | 7107 | #endif |
7102 | 7108 | else |
7103 | 7109 | set_hl_attr(idx); |
7110 | +#ifdef FEAT_EVAL | |
7111 | + HL_TABLE()[idx].sg_scriptID = current_SID; | |
7112 | +#endif | |
7104 | 7113 | redraw_all_later(NOT_VALID); |
7105 | 7114 | } |
7106 | 7115 | vim_free(key); |
@@ -7201,6 +7210,12 @@ | ||
7201 | 7210 | HL_TABLE()[idx].sg_font_name = NULL; |
7202 | 7211 | HL_TABLE()[idx].sg_gui_attr = 0; |
7203 | 7212 | #endif |
7213 | +#ifdef FEAT_EVAL | |
7214 | + /* Clear the script ID only when there is no link, since that is not | |
7215 | + * cleared. */ | |
7216 | + if (HL_TABLE()[idx].sg_link == 0) | |
7217 | + HL_TABLE()[idx].sg_scriptID = 0; | |
7218 | +#endif | |
7204 | 7219 | } |
7205 | 7220 | |
7206 | 7221 | #if defined(FEAT_GUI) || defined(PROTO) |
@@ -7868,13 +7883,19 @@ | ||
7868 | 7883 | 0, sgp->sg_font_name, "font"); |
7869 | 7884 | #endif |
7870 | 7885 | |
7871 | - if (sgp->sg_link) | |
7886 | + if (sgp->sg_link && !got_int) | |
7872 | 7887 | { |
7873 | 7888 | (void)syn_list_header(didh, 9999, id); |
7889 | + didh = TRUE; | |
7874 | 7890 | msg_puts_attr((char_u *)"links to", hl_attr(HLF_D)); |
7875 | 7891 | msg_putchar(' '); |
7876 | 7892 | msg_outtrans(HL_TABLE()[HL_TABLE()[id - 1].sg_link - 1].sg_name); |
7877 | 7893 | } |
7894 | + | |
7895 | +#ifdef FEAT_EVAL | |
7896 | + if (didh && p_verbose > 0) | |
7897 | + last_set_msg(sgp->sg_scriptID); | |
7898 | +#endif | |
7878 | 7899 | } |
7879 | 7900 | |
7880 | 7901 | static int |
@@ -7890,6 +7911,8 @@ | ||
7890 | 7911 | char_u *ts; |
7891 | 7912 | int i; |
7892 | 7913 | |
7914 | + if (got_int) | |
7915 | + return FALSE; | |
7893 | 7916 | if (type == LIST_STRING ? (sarg != NULL) : (iarg != 0)) |
7894 | 7917 | { |
7895 | 7918 | ts = buf; |
@@ -7915,10 +7938,12 @@ | ||
7915 | 7938 | (void)syn_list_header(didh, |
7916 | 7939 | (int)(vim_strsize(ts) + STRLEN(name) + 1), id); |
7917 | 7940 | didh = TRUE; |
7918 | - | |
7919 | - MSG_PUTS_ATTR(name, hl_attr(HLF_D)); | |
7920 | - MSG_PUTS_ATTR("=", hl_attr(HLF_D)); | |
7921 | - msg_outtrans(ts); | |
7941 | + if (!got_int) | |
7942 | + { | |
7943 | + MSG_PUTS_ATTR(name, hl_attr(HLF_D)); | |
7944 | + MSG_PUTS_ATTR("=", hl_attr(HLF_D)); | |
7945 | + msg_outtrans(ts); | |
7946 | + } | |
7922 | 7947 | } |
7923 | 7948 | return didh; |
7924 | 7949 | } |
@@ -8068,11 +8093,17 @@ | ||
8068 | 8093 | if (!did_header) |
8069 | 8094 | { |
8070 | 8095 | msg_putchar('\n'); |
8096 | + if (got_int) | |
8097 | + return TRUE; | |
8071 | 8098 | msg_outtrans(HL_TABLE()[id - 1].sg_name); |
8072 | 8099 | endcol = 15; |
8073 | 8100 | } |
8074 | 8101 | else if (msg_col + outlen + 1 >= Columns) |
8102 | + { | |
8075 | 8103 | msg_putchar('\n'); |
8104 | + if (got_int) | |
8105 | + return TRUE; | |
8106 | + } | |
8076 | 8107 | else |
8077 | 8108 | { |
8078 | 8109 | if (msg_col >= endcol) /* wrap around is like starting a new line */ |
@@ -36,5 +36,5 @@ | ||
36 | 36 | #define VIM_VERSION_NODOT "vim70aa" |
37 | 37 | #define VIM_VERSION_SHORT "7.0aa" |
38 | 38 | #define VIM_VERSION_MEDIUM "7.0aa ALPHA" |
39 | -#define VIM_VERSION_LONG "VIM - Vi IMproved 7.0aa ALPHA (2005 Jul 27)" | |
40 | -#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.0aa ALPHA (2005 Jul 27, compiled " | |
39 | +#define VIM_VERSION_LONG "VIM - Vi IMproved 7.0aa ALPHA (2005 Jul 28)" | |
40 | +#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.0aa ALPHA (2005 Jul 28, compiled " |