After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 155003 - Slowdown after hide/unhide all rows
Slowdown after hide/unhide all rows
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: General
git master
Other All
: High normal
: ---
Assigned To: Jody Goldberg
Jody Goldberg
: 649584 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2004-10-10 09:41 UTC by Adrian Custer
Modified: 2011-05-06 19:04 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Adrian Custer 2004-10-10 09:41:51 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.
Comment 1 Morten Welinder 2004-10-11 17:59:26 UTC
Confirmed.
Comment 2 Morten Welinder 2004-10-11 18:03:42 UTC
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}
Comment 3 Morten Welinder 2004-10-11 23:27:57 UTC
Jody: how do you want to deal with this?  Something specific for hiding or
some general optimize-rows/cols code?
Comment 4 Jody Goldberg 2004-11-02 15:23:47 UTC
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.
Comment 5 Jody Goldberg 2006-12-17 07:39:56 UTC
started work on this.
Comment 6 Morten Welinder 2011-05-06 18:55:21 UTC
*** Bug 649584 has been marked as a duplicate of this bug. ***
Comment 7 Morten Welinder 2011-05-06 19:04:57 UTC
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report.