[GRASS5] Color prompt partially implemented, color confusion.
Helena Mitasova
hmitaso at unity.ncsu.edu
Mon Apr 17 09:28:24 EDT 2006
>>
>> G_str_to_color ignores case.
>> D_translate_color is case sensitive
>>
>> name D_translate_color G_str_to_color
>> red 255 0 0 same
>> orange 255 128 0 255 127 0
>> yellow 255 255 0 same
>> green 0 255 0 same
>> blue 0 0 255 same
>> indigo 0 128 255 0 127 255
>> violet 255 0 255 same (this is a strange violet)
>> black 0 0 0 same
>> white 255 255 255 same
>> gray 175 175 175 127 127 127
>> brown 180 77 25 same
>> magenta 255 0 128 255 0 255 (D_ has a very strange
>> magenta)
>> aqua 100 128 255 100 127 255
>> grey lookup to gray 127 127 127
>> cyan doesn't exist 0 255 255
>>
>> How should we straighten out these colors?
>
> Colours which refer to the corners of the colour cube should have the
> correct values, so magenta should be 255,0,255. Arguably, gray/grey
> (do we need both spellings; the rest of GRASS uses US spellings
> consistently) should be 127/128 (the centre of the colour cube).
>
> It doesn't really matter about orange, indigo, violet, brown or aqua,
> as those don't have any obvious definition, although we should decide
> whether 50% is 127 or 128 and use one value consistently.
>
> Cyan should either be removed from G_str_to_color() or added to the
> list of standard colours in the display architecture. Updating the
> display architecture is tricky, as there are quite a few places that
> would need to be changed. OTOH, it's the only corner which isn't in
> the list.
I would vote for adding cyan if possible, Helena
>
> If choose to add cyan to the list of standard colours, we may as well
> renumber them so that the corners use the indices from 1 to 8 (i.e.
> index = 1+r+2g+4b); zero is reserved for transparent in some contexts.
>
> --
> Glynn Clements <glynn at gclements.plus.com>
>
> _______________________________________________
> grass5 mailing list
> grass5 at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grass5
More information about the grass-dev
mailing list