The environment is plain-old win32 under C/C++ without any fancy MFC or similar mumbo-jumbo. I have a window, which has several children and grandchildren. Some children are oddly-shaped icons, and I need them to have transparent background (oddly-shaped icons). Consider a this pseudo-structure:
- Parent1
- Child1 (normal)
- Child2 (oddly-shaped icon)
- Child3 (normal) / Parent2
- Grandchild1 (normal)
- Grandchild2 (oddly-shaped icon)
Above, Child2 and Grandchild2 are supposed to have transparent background (WM_ERASEBKGND does nothing, or (WNDCLASS)->hbrBackground = NULL). Right now the background for these icons is transparent, but transparent to extreme -- I see stuff under Parent1 -- desktop, etc.
This all happens under Windows Mobile.
Is there any extra flag I have to set for Parent1 and Parent2? Any good tricks you might offer?
I would be surprised if noone had similar problems, since many applications now have to display icons, all shapes and sizes.
EDIT: The oddly-shaped window is icon with transparencies. It would be nice if parent window would not do clipping for these particular windows, but invalidate them every time parent draws itself. CS_PARENTDC looks very promising, but not promising enough. Any ideas?