Re: How to get box shadows in qlabels?

Barry Scott <[email protected]>
Newsgroups gmane.comp.python.pyqt-pykde
Message-ID <[email protected]>

> On 10 Mar 2020, at 02:53, Souvik Dutta Chowdhury <[email protected]> wrote:
> 
> Hmm but there is nothing pyqt5 called QGraphicsBoxShadowEffect 

In the docs https://doc.qt.io/qt-5/qgraphicsdropshadoweffect.html <https://doc.qt.io/qt-5/qgraphicsdropshadoweffect.html> it says that
this is part of widgets "qmake:	QT += widgets"
That tells me that I should look in PyQt5.QtWidgets to find the class.


>>> from PyQt5 import QtWidgets

>>> QtWidgets.QGraphicsDropShadowEffect
<class 'PyQt5.QtWidgets.QGraphicsDropShadowEffect'>

Barry

> 
> Get Outlook for Android <https://aka.ms/ghei36>

> 
> From: michael h <[email protected]>
> Sent: Tuesday, March 10, 2020 8:20:43 AM
> To: Souvik Dutta <[email protected]>
> Cc: pyqt <[email protected]>
> Subject: Re: [PyQt] How to get box shadows in qlabels?
>  
> 
> On Sun, Mar 8, 2020 at 9:35 PM Souvik Dutta <[email protected] <mailto:[email protected]>> wrote:
> I am trying to get some neumorphism effect in qlabel. I want two box shadows for this. Both of them will be in opposite direction, one will be white and another will be black. How can I do this, I mean is there an inbuilt function. I tried adding box-shadows, box-shadow and boxshadow in the style sheet but everytime it says no property called boxshadow.
> 
> 
> I don't believe QSS supports box-shadow. QLabel does have setGraphicsEffect() though. 


> _______________________________________________
> PyQt mailing list    [email protected]
> https://www.riverbankcomputing.com/mailman/listinfo/pyqt

_______________________________________________
PyQt mailing list    [email protected]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.