You are not logged in.

Dear visitor, welcome to QtForum.org. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Monday, April 30th 2012, 10:04am

QGraphicEffects and non rectangular widgets on Qt 4.6 embedded

Hi everyone,

I've got a problem with QGraphicEffects on Qt 4.6 embedded:
On widgets which do not have Qt::WA_NoSystemBackground set the effect is applied on the whole widget rectangle -- not only on the visible parts (i have rounded borders set with a stylesheet + opacity or shadow effects).

The problem is that if i set Qt::WA_NoSystemBackground on widgets which auto-resize, they loose their background (which is normal -- Qt doc: "[...]when the widget receives paint events, the background is not automatically repainted.).

So, my Question is: How do I apply effects on non rectangular widgets in Qt 4.6 embedded, so that the area they are applied to is the visible part of the widget?

Please tell me if I haven't described the problem well, then I'll post desktop vs. embedded screenshots and the code sample.

Thanks in advance

André