transparent brush style?

Login to reply to this topic.
Sat, 2008-04-12 07:59
Joined: 2008-02-26
Forum posts: 9

is there any way to draw a partially transparent rect with CWindowGc.DrawRect()?
i can easily bring an alpha channeled CFbsBitmap to "mask" the brush, but can't figure out if there's even a way to do that


Mon, 2008-04-14 09:19
Joined: 2004-11-29
Forum posts: 1142
Re: transparent brush style?

I have actually never tried it, but I think it works to simply set alpha channel on the color you set for the Brush.

Mon, 2008-04-14 21:29
Joined: 2008-02-26
Forum posts: 9
Re: transparent brush style?

thanks, that works like a charm; i didn't even know TRgb could hold alpha channel information Smiling

as a side note, why on earth did they define the TRgb constructor that takes a hex value as a parameter to use the value in "reverse order" - blue, green, red, rather than the more logical rgb :|

  • Login to reply to this topic.