|
Karsten Hopp |
cc85de |
To: vim-dev@vim.org
|
|
Karsten Hopp |
cc85de |
Subject: Patch 7.2.424
|
|
Karsten Hopp |
cc85de |
Fcc: outbox
|
|
Karsten Hopp |
cc85de |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
cc85de |
Mime-Version: 1.0
|
|
Karsten Hopp |
cc85de |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
cc85de |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
cc85de |
------------
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
Patch 7.2.424
|
|
Karsten Hopp |
cc85de |
Problem: ":colorscheme" without an argument doesn't do anything.
|
|
Karsten Hopp |
cc85de |
Solution: Make it echo the current color scheme name. (partly by Christian
|
|
Karsten Hopp |
cc85de |
Brabandt)
|
|
Karsten Hopp |
cc85de |
Files: runtime/doc/syntax.txt, src/ex_cmds.h, src/ex_docmd.c
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
*** ../vim-7.2.423/runtime/doc/syntax.txt 2008-08-09 19:36:52.000000000 +0200
|
|
Karsten Hopp |
cc85de |
--- runtime/doc/syntax.txt 2010-05-14 15:27:47.000000000 +0200
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 113,118 ****
|
|
Karsten Hopp |
cc85de |
--- 113,121 ----
|
|
Karsten Hopp |
cc85de |
:syntax off $VIMRUNTIME/syntax/nosyntax.vim
|
|
Karsten Hopp |
cc85de |
Also see |syntax-loading|.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
+ NOTE: If displaying long lines is slow and switching off syntax highlighting
|
|
Karsten Hopp |
cc85de |
+ makes it fast, consider setting the 'synmaxcol' option to a lower value.
|
|
Karsten Hopp |
cc85de |
+
|
|
Karsten Hopp |
cc85de |
==============================================================================
|
|
Karsten Hopp |
cc85de |
2. Syntax files *:syn-files*
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 3829,3841 ****
|
|
Karsten Hopp |
cc85de |
in their own color.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
*:colo* *:colorscheme* *E185*
|
|
Karsten Hopp |
cc85de |
:colo[rscheme] {name} Load color scheme {name}. This searches 'runtimepath'
|
|
Karsten Hopp |
cc85de |
for the file "colors/{name}.vim. The first one that
|
|
Karsten Hopp |
cc85de |
is found is loaded.
|
|
Karsten Hopp |
cc85de |
! To see the name of the currently active color scheme
|
|
Karsten Hopp |
cc85de |
! (if there is one): >
|
|
Karsten Hopp |
cc85de |
! :echo g:colors_name
|
|
Karsten Hopp |
cc85de |
! < Doesn't work recursively, thus you can't use
|
|
Karsten Hopp |
cc85de |
":colorscheme" in a color scheme script.
|
|
Karsten Hopp |
cc85de |
After the color scheme has been loaded the
|
|
Karsten Hopp |
cc85de |
|ColorScheme| autocommand event is triggered.
|
|
Karsten Hopp |
cc85de |
--- 3871,3890 ----
|
|
Karsten Hopp |
cc85de |
in their own color.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
*:colo* *:colorscheme* *E185*
|
|
Karsten Hopp |
cc85de |
+ :colo[rscheme] Output the name of the currently active color scheme.
|
|
Karsten Hopp |
cc85de |
+ This is basically the same as >
|
|
Karsten Hopp |
cc85de |
+ :echo g:colors_name
|
|
Karsten Hopp |
cc85de |
+ < In case g:colors_name has not been defined :colo will
|
|
Karsten Hopp |
cc85de |
+ output "default". When compiled without the |+eval|
|
|
Karsten Hopp |
cc85de |
+ feature it will output "unknown".
|
|
Karsten Hopp |
cc85de |
+
|
|
Karsten Hopp |
cc85de |
:colo[rscheme] {name} Load color scheme {name}. This searches 'runtimepath'
|
|
Karsten Hopp |
cc85de |
for the file "colors/{name}.vim. The first one that
|
|
Karsten Hopp |
cc85de |
is found is loaded.
|
|
Karsten Hopp |
cc85de |
! To see the name of the currently active color scheme: >
|
|
Karsten Hopp |
cc85de |
! :colo
|
|
Karsten Hopp |
cc85de |
! < The name is also stored in the g:colors_name variable.
|
|
Karsten Hopp |
cc85de |
! Doesn't work recursively, thus you can't use
|
|
Karsten Hopp |
cc85de |
":colorscheme" in a color scheme script.
|
|
Karsten Hopp |
cc85de |
After the color scheme has been loaded the
|
|
Karsten Hopp |
cc85de |
|ColorScheme| autocommand event is triggered.
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 4032,4038 ****
|
|
Karsten Hopp |
cc85de |
colors.
|
|
Karsten Hopp |
cc85de |
When a colorscheme is being used, changing 'background' causes it to
|
|
Karsten Hopp |
cc85de |
be reloaded, which may reset all colors (including Normal). First
|
|
Karsten Hopp |
cc85de |
! delete the "colors_name" variable when you don't want this.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
When you have set "ctermfg" or "ctermbg" for the Normal group, Vim
|
|
Karsten Hopp |
cc85de |
needs to reset the color when exiting. This is done with the "op"
|
|
Karsten Hopp |
cc85de |
--- 4081,4087 ----
|
|
Karsten Hopp |
cc85de |
colors.
|
|
Karsten Hopp |
cc85de |
When a colorscheme is being used, changing 'background' causes it to
|
|
Karsten Hopp |
cc85de |
be reloaded, which may reset all colors (including Normal). First
|
|
Karsten Hopp |
cc85de |
! delete the "g:colors_name" variable when you don't want this.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
When you have set "ctermfg" or "ctermbg" for the Normal group, Vim
|
|
Karsten Hopp |
cc85de |
needs to reset the color when exiting. This is done with the "op"
|
|
Karsten Hopp |
cc85de |
*** ../vim-7.2.423/src/ex_cmds.h 2010-05-13 16:46:16.000000000 +0200
|
|
Karsten Hopp |
cc85de |
--- src/ex_cmds.h 2010-05-14 13:08:45.000000000 +0200
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 256,262 ****
|
|
Karsten Hopp |
cc85de |
EX(CMD_colder, "colder", qf_age,
|
|
Karsten Hopp |
cc85de |
RANGE|NOTADR|COUNT|TRLBAR),
|
|
Karsten Hopp |
cc85de |
EX(CMD_colorscheme, "colorscheme", ex_colorscheme,
|
|
Karsten Hopp |
cc85de |
! NEEDARG|WORD1|TRLBAR|CMDWIN),
|
|
Karsten Hopp |
cc85de |
EX(CMD_command, "command", ex_command,
|
|
Karsten Hopp |
cc85de |
EXTRA|BANG|NOTRLCOM|USECTRLV|CMDWIN),
|
|
Karsten Hopp |
cc85de |
EX(CMD_comclear, "comclear", ex_comclear,
|
|
Karsten Hopp |
cc85de |
--- 256,262 ----
|
|
Karsten Hopp |
cc85de |
EX(CMD_colder, "colder", qf_age,
|
|
Karsten Hopp |
cc85de |
RANGE|NOTADR|COUNT|TRLBAR),
|
|
Karsten Hopp |
cc85de |
EX(CMD_colorscheme, "colorscheme", ex_colorscheme,
|
|
Karsten Hopp |
cc85de |
! WORD1|TRLBAR|CMDWIN),
|
|
Karsten Hopp |
cc85de |
EX(CMD_command, "command", ex_command,
|
|
Karsten Hopp |
cc85de |
EXTRA|BANG|NOTRLCOM|USECTRLV|CMDWIN),
|
|
Karsten Hopp |
cc85de |
EX(CMD_comclear, "comclear", ex_comclear,
|
|
Karsten Hopp |
cc85de |
*** ../vim-7.2.423/src/ex_docmd.c 2010-03-02 15:55:51.000000000 +0100
|
|
Karsten Hopp |
cc85de |
--- src/ex_docmd.c 2010-05-14 15:26:14.000000000 +0200
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 6226,6232 ****
|
|
Karsten Hopp |
cc85de |
ex_colorscheme(eap)
|
|
Karsten Hopp |
cc85de |
exarg_T *eap;
|
|
Karsten Hopp |
cc85de |
{
|
|
Karsten Hopp |
cc85de |
! if (load_colors(eap->arg) == FAIL)
|
|
Karsten Hopp |
cc85de |
EMSG2(_("E185: Cannot find color scheme %s"), eap->arg);
|
|
Karsten Hopp |
cc85de |
}
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
--- 6226,6256 ----
|
|
Karsten Hopp |
cc85de |
ex_colorscheme(eap)
|
|
Karsten Hopp |
cc85de |
exarg_T *eap;
|
|
Karsten Hopp |
cc85de |
{
|
|
Karsten Hopp |
cc85de |
! if (*eap->arg == NUL)
|
|
Karsten Hopp |
cc85de |
! {
|
|
Karsten Hopp |
cc85de |
! #ifdef FEAT_EVAL
|
|
Karsten Hopp |
cc85de |
! char_u *expr = vim_strsave((char_u *)"g:colors_name");
|
|
Karsten Hopp |
cc85de |
! char_u *p = NULL;
|
|
Karsten Hopp |
cc85de |
!
|
|
Karsten Hopp |
cc85de |
! if (expr != NULL)
|
|
Karsten Hopp |
cc85de |
! {
|
|
Karsten Hopp |
cc85de |
! ++emsg_off;
|
|
Karsten Hopp |
cc85de |
! p = eval_to_string(expr, NULL, FALSE);
|
|
Karsten Hopp |
cc85de |
! --emsg_off;
|
|
Karsten Hopp |
cc85de |
! vim_free(expr);
|
|
Karsten Hopp |
cc85de |
! }
|
|
Karsten Hopp |
cc85de |
! if (p != NULL)
|
|
Karsten Hopp |
cc85de |
! {
|
|
Karsten Hopp |
cc85de |
! MSG(p);
|
|
Karsten Hopp |
cc85de |
! vim_free(p);
|
|
Karsten Hopp |
cc85de |
! }
|
|
Karsten Hopp |
cc85de |
! else
|
|
Karsten Hopp |
cc85de |
! MSG("default");
|
|
Karsten Hopp |
cc85de |
! #else
|
|
Karsten Hopp |
cc85de |
! MSG(_("unknown"));
|
|
Karsten Hopp |
cc85de |
! #endif
|
|
Karsten Hopp |
cc85de |
! }
|
|
Karsten Hopp |
cc85de |
! else if (load_colors(eap->arg) == FAIL)
|
|
Karsten Hopp |
cc85de |
EMSG2(_("E185: Cannot find color scheme %s"), eap->arg);
|
|
Karsten Hopp |
cc85de |
}
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
*** ../vim-7.2.423/src/version.c 2010-05-14 12:16:19.000000000 +0200
|
|
Karsten Hopp |
cc85de |
--- src/version.c 2010-05-14 15:23:20.000000000 +0200
|
|
Karsten Hopp |
cc85de |
***************
|
|
Karsten Hopp |
cc85de |
*** 683,684 ****
|
|
Karsten Hopp |
cc85de |
--- 683,686 ----
|
|
Karsten Hopp |
cc85de |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
cc85de |
+ /**/
|
|
Karsten Hopp |
cc85de |
+ 424,
|
|
Karsten Hopp |
cc85de |
/**/
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
--
|
|
Karsten Hopp |
cc85de |
Everyone has a photographic memory. Some don't have film.
|
|
Karsten Hopp |
cc85de |
|
|
Karsten Hopp |
cc85de |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
cc85de |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
cc85de |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
cc85de |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|