On 2008-12-28, [email protected] wrote:
> Hi,
> 
> I am a Gentoo user. Basically, I want to enable the filetype plugin
> and use the default syntax highlighting distributed with Gentoo. But I
> want to apply my custom syntax highlighting also. I did the following,
> but did not get what I expected:
> 
> vim /etc/fstab
> syn match mTab /\t/
> hi link mTab Visual
> 
> The expected result is that all tab char. will be displayed in a
> reverse color, so I can find them easily. If the file I am working
> with does not have 'filetype' set, my commands works; if vim has set
> the 'filetype', and it detected the file type, my commands won't work
> at all.
> 
> any idea about how to fix this? thx

I think you can fix this by putting this command in your ~/.vimrc
after your "filetype plugin on" command:

   au Syntax * syn match Visual /\t/

I replaced mTab with Visual for convenience and it worked for the
few test cases I tried.

Regards,
Gary


--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to