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 99134 - GtkTreeView calls GtkTreeModel::get_value for invisible elements
GtkTreeView calls GtkTreeModel::get_value for invisible elements
Status: RESOLVED DUPLICATE of bug 80868
Product: gtk+
Classification: Platform
Component: Widget: GtkTreeView
2.0.x
Other Linux
: Normal normal
: ---
Assigned To: gtktreeview-bugs
gtktreeview-bugs
Depends on:
Blocks:
 
 
Reported: 2002-11-20 23:26 UTC by Pawel Salek
Modified: 2011-02-04 16:11 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
tree-view-bug-demo.c (13.32 KB, text/plain)
2002-11-20 23:27 UTC, Pawel Salek
Details

Description Pawel Salek 2002-11-20 23:26:03 UTC
GtkTreeView calls GtkTreeModel::get_value for invisible elements which can
be a big performance hit for large displayed trees (possibly larger than
available memory). It does so even when the column widths are fixed (I
could understand if the calls were made to calculate the column widths).
GtkCellRendererText provides a special function
gtk_cell_renderer_text_set_fixed_height_from_font() to allegedly speed up 
computation of the cell height but it does not appear to help.

I attach a test program that demonstrates the problem. Displaying takes 13
times longer than it could in principle.
Comment 1 Pawel Salek 2002-11-20 23:27:32 UTC
Created attachment 12440 [details]
tree-view-bug-demo.c
Comment 2 Kristian Rietveld 2002-12-19 02:44:50 UTC
Moving remaining bugs to 2.2.1.
Comment 3 Pawel Salek 2003-01-07 21:49:22 UTC
While we are at it, could GtkTreeView provide hints which elements
will be "soon" needed, possibly provide a list of rows that 
GtkTreeModel::get_value is going to be evaluated for? This would make
it easier to fetch actually needed elements from a database, or a IMAP
server, etc.
Comment 4 Kristian Rietveld 2003-01-22 20:17:40 UTC
Such kind of hints are not easily possible with the current
architecture. With your own treemodel + the disable-validation hack
you can prolly do get-data-on-demand models.


*** This bug has been marked as a duplicate of 80868 ***