Pselus
Active member
- Joined
- Dec 21, 2005
- Messages
- 29
Right, so...long story short, I have a panel with curved corners. I need the portion of the panel outside the curve to be transparent. La-dee-da, thats easy as pie...done did it.
Problem: Due to the amount of graphical processing in the app (and the use of this panel ALL over the place), when the application raises an event or resizes there is alot of "flickering". I traced the issue down to the fact that the application is redrawing the background and for a split second it is showing through all the controls (on each of the panels in the application...so it causes alot of visual nastiness).
Now, the true problem arises in that, when I override OnPaintBackground...this flickering stops flat out...but I cant get the outside corners to draw transparent.
Ive tried alot of different things and come to the conclusion that you CANNOT use transparency if you Override OnPaintBackground (and do nothing in it). I pray that I am wrong about that conclusion and was hoping someone here would konw a way that I can.
for reference sake my panel is based off this example.
Here is a shot of the panel before overriding OnPaintBackground:
[Broken External Image]:http://www.livethislife.net/images/ForWork/panelbefore.gif
and here is a shot after overriding OnPaintBackground:
[Broken External Image]:http://www.livethislife.net/images/ForWork/panelafter.gif
So...anyone know of a way for me to draw a transparent rectangle as the background without actually drawing the background?
To further complicate matters...I need to do this over gradients.
Problem: Due to the amount of graphical processing in the app (and the use of this panel ALL over the place), when the application raises an event or resizes there is alot of "flickering". I traced the issue down to the fact that the application is redrawing the background and for a split second it is showing through all the controls (on each of the panels in the application...so it causes alot of visual nastiness).
Now, the true problem arises in that, when I override OnPaintBackground...this flickering stops flat out...but I cant get the outside corners to draw transparent.
Ive tried alot of different things and come to the conclusion that you CANNOT use transparency if you Override OnPaintBackground (and do nothing in it). I pray that I am wrong about that conclusion and was hoping someone here would konw a way that I can.
for reference sake my panel is based off this example.
Here is a shot of the panel before overriding OnPaintBackground:
[Broken External Image]:http://www.livethislife.net/images/ForWork/panelbefore.gif
and here is a shot after overriding OnPaintBackground:
[Broken External Image]:http://www.livethislife.net/images/ForWork/panelafter.gif
So...anyone know of a way for me to draw a transparent rectangle as the background without actually drawing the background?
To further complicate matters...I need to do this over gradients.