Re: Gtk::TreeView performance



Thanks very much indeed for this pointer, armed with this info I've speeded up the loading of my grids by a factor of 5.

I had been trying:

   TreeViewColumn::set_fixed_width()
and
  
TreeViewColumn::set_sizing(TREE_VIEW_COLUMN_FIXED)

but hadn't noticed
CellRenderer::set_fixed_size(width, height) or tree-view property "fixed-height-mode".

The
"fixed-height-mode" is the key for me -- I had been working with gtk2.2 which doesn't have that property.

With:

TreeViewColumn::set_sizing(TREE_VIEW_COLUMN_FIXED)
tree-view property "fixed-height-mode"
TreeViewColumn::set_fixed_width()

I get dramatic improvements.

CellRenderer::set_fixed_size(width, height) doesn't seem to make any difference, once the other three are set.

Many thanks, this has really made my day.

John

It might be faster if it's not having to recalculate sizes all the time.
  You can set everything to some form of fixed-size mode using:

- CellRenderer::set_fixed_size(width, height)
- TreeViewColumn::set_sizing(TREE_VIEW_COLUMN_FIXED)
- setting the tree-view property "fixed-height-mode" to true

This is based on the gtkmm API docs, I haven't actually tried it, or
even used gtkmm before.  I think that some of this may not be present in
older versions of GTK.

--
Tim Evans
Applied Research Associates NZ
http://www.aranz.com/
_______________________________________________
gtk-list mailing list
gtk-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-list



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]