Thursday, August 2, 2012

RE: Syntax - New Key Word with New Color

> On 2, ???? 2012, at 16:59, "Waters, Bill" <waters@ti.com> wrote:
>
> > I want the word "NOTE" when in a comment in a C file to show up with a LightRed forground and a Black background.
> >
> > I added cNote to my own version of c.vim...
> >
> > syn keyword cNote contained NOTE
> > syn cluster cCommentGroup contains=cTodo,cNote
> > ...
> > hi def link cNote Cursor
> >
> > And this works, but "NOTE" has a Green forground and a Black background.
> >
> > I think that I need to add this. But where?
> >
> > SynColor Note_Color term=standout cterm=NONE ctermfg=Black ctermbg=LightRed gui=NONE guifg=Blue guibg=Yellow
> >
> > And then make this change to c.vim...
> >
> > hi def link cNote Note_Color
> >
> > Thanks,
> > Bill
>
>
> -----Original Message-----
> From: vim_use@googlegroups.com [mailto:vim_use@googlegroups.com] On Behalf Of Salman Halim
> Sent: Thursday, August 02, 2012 4:33 PM
> To: vim_use@googlegroups.com
> Subject: Re: Syntax - New Key Word with New Color
>
> Just do:
>
> Hi cnote guifg=lightred guibg=blue ctermfg=...
>
> You don't have to link a highlight definition to an existing one if you don't want to.
>
> Sorry for top-posting. iPhone...
>
> Salman
>


Cool. That got it. Thanks Salman! Guess I was making it more complicated than it needed to be in this case...

Bill

--
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: