[Qt-interest] Slow QTreeWidget

Kenneth Beck nekkceb at comcast.net
Wed Mar 25 17:06:47 CET 2009


R. Reucher wrote:
> On Wed March 25 2009 14:14:15 Kenneth Beck wrote:
>> setUpdatesEnabled(false) did not do much, except to delay the visual
>> update until the end. I have a progress bar that steps with each row
>> add, and the time between steps gets progressively slower as rows get
>> added, again as if it is looping back to somehow update all the previous
>> data with each call to setText.
> Are you sorting the entries while you insert them?
> 
> I have QTreeWidget's with ~8000 entries (6 columns each) and they are filled 
> within less than a second (using Qt 4.5 that is, with 4.4 this was 
> perceptibly slower).
TreeView is MUCH MUCH faster! It would still be nice to know what I was 
doing wrong on the TreeWidget -- there are other spots in my code that 
have the same problem.



More information about the Qt-interest-old mailing list