Wednesday, August 17, 2011

Re: vimgrep/quickfix ignores "au BufNewFile,BufRead,BufWinEnter *.vb ... syntax enable | color mine"

On Aug 17, 11:04 am, "Christian Brabandt" <cbli...@256bit.org> wrote:
> On Wed, August 17, 2011 5:00 pm, Paul wrote:
> > I am trying to get the following 1-line autocommand to work:
>
> > autocmd BufNewFile,BufRead,BufWinEnter *.vb setl ft=vb | syntax enable
> > | colorscheme mine
>
> > It seems to work when the buffer is new.  But when I do a vimgrep and
> > get placed in the location of the first quickfix line item, everything
> > is monochrome until I issue ":syntax enable | colorscheme mine".  Is
> > there another event that I should add to the au command?
>
> Is there a reason, you don't want global syntax highlighting (e.g.
> use :syntax enable in your .vimrc)?

That has the same effect as issuing ":syntax enable" manually, which I
do after the syntax highlighting disappear. However, the syntax
highlighting disappears again after a vimgrep.

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: