GNOME Bugzilla – Bug 155003
Slowdown after hide/unhide all rows
Last modified: 2011-05-06 19:04:57 UTC
After hiding and unhiding all the columns and then all the rows, when returning to that worksheet, gnumeric pauses and the cpu maxes out briefly before redisplay. 1) new gnumeric 2) select "Sheet 2" 3) select "Sheet 1" ==> normal speed display 4) Edit -> Select -> Select All 5) Format -> Columns -> Hide 6) Format -> Columns -> Unhide 7) Format -> Rows -> Hide 8) format -> Rows -> Unhide 9) Select "Sheet2" 10) Select "Sheet1" ==> Takes a momment, and cpu goes through a large computation. If you select only one cell, it becomes fast again. If you reselect the whole sheet, it becomes slow again.
Confirmed.
I looks like the sheet gets the idea that all rows and all columns have been touched. (gdb) p sheet->cols $3 = {max_used = 255, default_style = {pos = -1, size_pts = 48, size_pixels = 64, margin_a = 2, margin_b = 2, is_default = 0, outline_level = 0, is_collapsed = 0, hard_size = 0, visible = 1, in_filter = 0, needs_respan = 0, spans = 0x0}, info = 0x498660, max_outline_level = 0, size_pts = 0, size_pixels = 0} (gdb) p sheet->rows $4 = {max_used = 65535, default_style = {pos = -1, size_pts = 12.75, size_pixels = 17, margin_a = 0, margin_b = 0, is_default = 0, outline_level = 0, is_collapsed = 0, hard_size = 0, visible = 1, in_filter = 0, needs_respan = 0, spans = 0x0}, info = 0x4bc0c8, max_outline_level = 0, size_pts = 0, size_pixels = 0}
Jody: how do you want to deal with this? Something specific for hiding or some general optimize-rows/cols code?
morten : both. For 1.4 we should make the unhide code smarter to remove the bogus empty cols/rows for 1.5 we can attack this on two levels - Allow col/row group hiding so that we don't actually create all of them - move the cell storage into the style quadtree so that we're not dependent on the existence of cols/rows to know what's empty.
started work on this.
*** Bug 649584 has been marked as a duplicate of this bug. ***
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report.