View Full Version : Plasmoid opacity

25th July 2009, 00:59
Hi all!
Do anybody know how to set opacity for plasmoid?
Background transparency like Desktop Folder plasmoid has...
I have tried with QPointer::setOpacity() but that doesn't work.

void TestPlasmoid::paintInterface(QPainter *p, const QStyleOptionGraphicsItem *option, const QRect &contentsRect)

25th July 2009, 07:44
Isn't the background drawn by your current plasma theme? And please show us, what your base class is and have do you set/draw the background.

25th July 2009, 09:49
The FolderView plasmoid uses a different background image - the "widgets/translucentbackground" instead of the normal "widgets/background".

So, the appearance is not hard-coded, and (depending on the theme) the FV could have even more opaque background than the normal plasmoids.

25th July 2009, 15:22
Thanks for help! I figured it out, setBackgroundHints(Plasma::Applet::TranslucentBack ground); makes the trick.