On/Off-Switch with QPushButton

Luca Beltrame lbeltrame at kde.org
Sun Nov 1 10:38:43 UTC 2015


In data domenica 1 novembre 2015 11:15:21 CET, Rainer Dorsch ha scritto:

Hello,

for the record, you're talking about Python plasmoids for Plasma 4.11.x, 
correct?

> AttributeError: 'PushButton' object has no attribute 'setIconSize'
> Interesting enough the size issue is then gone...

Is setIconSize actually a method of push buttons? Also, just for a question, 
why using QPushButtons? They will not follow the Plasma theme and colors for 
anyone using the plasmoid.

Also, I would suggest to avoid triggering exceptions in Python code that is 
run from Plasma, because the exception may lead to the underlying C++ object 
being deleted, potentially crashing the whole shell.



-- 
Luca Beltrame - KDE Forums team
KDE Science supporter
GPG key ID: A29D259B
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 455 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20151101/2a7b07b1/attachment.sig>


More information about the Plasma-devel mailing list