[prev in list] [next in list] [prev in thread] [next in thread]
List: pykde
Subject: Re: [PyKDE] PyQT 4.x Display Roles
From: Andreas Pakulat <apaku () gmx ! de>
Date: 2006-10-12 7:42:16
Message-ID: 20061012074216.GB6736 () morpheus ! apaku ! dnsalias ! org
[Download RAW message or body]
On 11.10.06 19:46:45, Matt Chambers wrote:
> Many examples show data() actually doing stuff like
>
> if role != QtCore.Qt.DisplayRole:
> return QtCore.QVariant()
/me too.
> I was able to eek out quite a bit more speed by creating a global instance of
> QVariant and returning the same one over and over again, instead of
> creating a new object every time data is called, which can be hundreds of times
> in just a few seconds.
>
> so I do:
> if role != QtCore.Qt.DisplayRole:
> return EMPTY_QVARIANT
Now I got it ;)
> My cpu fan still comes on if I use the scroll bar but its not as bad.
That's not really a profiling tool...
Andreas
--
Don't let your mind wander -- it's too little to be let out alone.
_______________________________________________
PyKDE mailing list PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic