Bug 234347

Summary: Table Data view is very slow with more than ~10 image entries
Product: [Applications] KEXI Reporter: George Goldberg <grundleborg>
Component: TablesAssignee: Jarosław Staniek <staniek>
Status: CLOSED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description George Goldberg 2010-04-14 16:14:19 UTC
I've got a table with 12 columns, one of which contains an image. Each row has an image in the image column of about 60kB size, jpeg.

With more than ten rows in the table, the view starts to slow down. When I click on a field it takes a few seconds for the line-edit to appear, and when I start typing there is a delay before characters appear.

By the time I have 50 rows in the table, there is a delay of about 15 seconds when I press any key, or select any row before the UI catches up.
Comment 1 George Goldberg 2010-04-14 17:20:33 UTC
I noticed this happens even when moving the mouse over a different row - it takes some seconds before that row is redrawn with the highlight that is triggered by hovering.

At a guess, is something called by the Model's data() method really slow?
Comment 2 Jarosław Staniek 2010-04-14 17:23:34 UTC
Hi, it would be good if you attach a small test database for this case. Thanks!
Comment 3 George Goldberg 2010-04-14 17:47:53 UTC
http://www.grundleborg.com/kde/misc/bugstest.kexi

(Unfortunately this is too big to post as an attachment).

This database exhibits the bug a bit (not as clearly as my real-life database, which is about 3.3Mb now with 55 rows, but I'd rather not post that anywhere public). On my system at least, there is about a 1 second delay with clicking on any cell before it becomes editable, and if I wave the mouse around, the highlighted row takes a while to catch up with it.
Comment 4 Jarosław Staniek 2010-04-14 17:51:35 UTC
Thanks!

In the future you can mail a file to me too.
Comment 5 Jarosław Staniek 2010-05-08 11:11:20 UTC
SVN commit 1124236 by staniek:

Table View
*Optimize display of scaled image entries in table grid by caching, table was previously unusable for 10+ rows
BUG:234347



 M  +39 -8     kexiutils/utils.cpp  
 M  +10 -2     kexiutils/utils.h  
 M  +35 -3     widget/tableview/kexiblobtableedit.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1124236
Comment 6 Jarosław Staniek 2010-05-08 11:15:22 UTC
SVN commit 1124238 by staniek:

merge r1124236 from trunk

Table View
*Optimize display of scaled image entries in table grid by caching, table was previously unusable for 10+ rows
BUG:234347

reviewed on #kexi IRC


 M  +39 -8     kexiutils/utils.cpp  
 M  +10 -2     kexiutils/utils.h  
 M  +35 -3     widget/tableview/kexiblobtableedit.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1124238
Comment 7 George Goldberg 2010-05-08 12:20:20 UTC
Fantastic! The biggest issue I was having is now fixed. Thanks so much.