Re: Weird colors

"Fer" <[email protected]>
Newsgroups gmane.comp.windows.gui4cli
Message-ID <[email protected]>

> I took a look at the source code.
> It looks in getColorAttr/getCOLORREF that the attribute colors are kept as three bytes as in one of the next lines:
> #	sysnr	\0
> Reg	Green	Blue
> 
> When the first byte is a # then the color is expected to be a system color else a RGB color.
> But 35 is the value for # so the RGB value 35 27 229 looks like "#" 27 229 and is misinterpreted as a system color.
> As for now don't use 35 but 34 or 36 :)


Hi Fred,


You've been busy digging very deep !!
I've already suspected something in that direction though
the manual does not exclude 35 as a valid Red value for
a background color.
I only found out this problem because in one of my guis the
background color of the textboxes is calculated from the
average color of the area of the desktop background occupied
by the window of that gui. Pretty complicated indeed, I can't
even repeat that last sentence without mistakes.
For now I've added the condition that R=35 must be read as
R=36.

Thanks for your efforts,


Fer




------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/gui4cli/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/gui4cli/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.