Waleed95
20th December 2011, 14:42
Should I just put the function in the .cpp file along with the name of the widget?
Like :
QGraphicsDropShadowEffect QGraphicsDropShadowEffect (HWChatWidget);
Help would be appreciated.
Spitfire
21st December 2011, 14:01
You need to apply the effect to a widget.
Parent is not the widget that the effect is applied to, but the efect will be deleted with the parent.
QWidget* w = new QWidget(this);
w->setFixedSize( 100, 100 );
w->setStyleSheet( "background-color:red;");
QGraphicsDropShadowEffect* e = new QGraphicsDropShadowEffect(w);
e->setBlurRadius( 10 );
w->setGraphicsEffect( e );
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.