GtkTreeView fixed-height-mode versus an expanding-width column.

View: New views
1 Messages — Rating Filter:   Alert me  

GtkTreeView fixed-height-mode versus an expanding-width column.

by Murray Cumming :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I want to use fixed-height mode for performance but I also want, for
instance, a middle column to expand to fill the available space instead
of expanding the last column.

For instance, if I have
  ID | Name         | Date
  1  | Someone      | 1/1/2001
  2  | Someone Else | 2/2/2002
then that Name column is the only one that really needs to use more
space.

But gtk_tree_view_set_fixed_height_mode() requires that all
GtkTreeViewColumns use
gtk_tree_view_column_set_sizing(GTK_TREE_VIEW_COLUMN_FIXED),
which requires me to call gtk_tree_view_column_set_fixed_width()
to get anything but a zero-width column. This doesn't seem to be
necessary for the last column, however.
 
So how could I
a) Calculate an appropriate fixed width for that middle column,
and
b) Recalculate it when the GtkTreeView is allocated more space
?

--
murrayc@...
www.murrayc.com
www.openismus.com

_______________________________________________
gtk-list mailing list
gtk-list@...
http://mail.gnome.org/mailman/listinfo/gtk-list