Hello,
I want to do a really simple thing, but i am unable to find how to do it here at the foruns os in the SDK help.
I want to define the background color of a control. My aplication will define many controls:
-------------------
|..........................|
|..------...------....|
|.|...2..|..|..3....|...|
|.|.......|..|.......|...|
|..------...------ ...|
|...........1.............|
|..........................|
-------------------
1, 2 and 3 are controls. The application may load things, such as images, on the controls or not. Those things may be loaded in the entire control or not. The background color of the control must appear on not-loaded parts of the control.
You can see a control like an region with a background that may be filled by elements. Where it is not filled, the background color must appear.
How can i define background colors for controls?
Thanks in advance,
Vitor.

Reply With Quote
raw() method. Then you need to draw your "element" using CWindowGc::BitBltMasked(). The important is that you need to create a mask for your element. The mask shall be a monochrome bitmap (black and white). The black represents part of the "element" that shall be drawn on the screen. The white one will be "hollow" -> meaning the background of parent's control will be displayed.


