On 20/03/09 01:49, Charles E. Campbell, Jr. wrote:
>
> merk wrote:
>> In a recent post, the response to a question included
>>
>>
>>>    hi def link pdbCol1      Red
>>>    hi def link pdbCol2      Yellow
>>>    hi def link pdbCol3      Green
>>>    hi def link pdbCol4      Magenta
>>>    hi def link pdbCol5      Cyan
>>>    hi def link pdbCol6      White
>>>    hi def link pdbCol7      Red
>>>    hi def link pdbCol8      Yellow
>>>    hi def link pdbCol9      Green
>>>    hi def link pdbCol10     Magenta
>>>    hi def link pdbCol11     Cyan
>>>
>>
>> Where are these colors defined?  How do I use them in my syntax
>> file?   When I just try to use them I get no coloring.  Whereas if I
>> use Statement or Structure, I get colors.   Is it possible to use hex
>> values at this level to define colors?
>>
> They're all defined with the astronaut colorscheme
> (http://vim.sourceforge.net/scripts/script.php?script_id=122).
> As an example, though:
>
> hi Red ctermfg=red guifg=red term=none
>
> You can define the other colors similarly.
>
> Regards,
> Chip Campbell

And if you don't want to use the astronaut colorscheme, you can define 
default colouring in your owncoded syntax scripts with just

        hi def pdbColl term=NONE ctermfg=red guifg=red
or
        hi def link mysynError Error

or similar.

Numeric values can be used, but in a cterm they are usually in decimal, 
0 (black) to 15 (white) for a 16-color terminal (and I recommend using 
the symbolic names instead, namely black, darkblue, darkgreen, ..., 
yellow, white), while in the GUI they are in hex, as in

        hi def mysynFooBar guifg=#654321

which means a color made of the following components: red 0x65, green 
0x43 and blue 0x21, each on a scale of 0x00 to 0xFF. (If you want your 
colors to be displayable on a 256-color screen with no dithering, each 
of the red, green and blue components should be an integer multiple of 
0x33. These are the so-called "safe" GUI colors.)


Best regards,
Tony.
-- 
"Deep" is a word like "theory" or "semantic" -- it implies all sorts of
marvelous things.  It's one thing to be able to say "I've got a
theory", quite another to say "I've got a semantic theory", but, ah,
those who can claim "I've got a deep semantic theory", they are truly
blessed.
                -- Randy Davis

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

Reply via email to