Re: EuGTK:Column Widths in GtkTreeView
- Posted by euphoric (admin) Aug 30, 2019
- 823 views
RESOLVED: Looks like I can grab the "allocation" property of the GtkTreeView!
Now, if you try to code ? get(tv,"width"), and run in a terminal, you'll see an error message:
ERROR: ****** Invalid call: GtkTreeView->get_width
Yep! I seen't it!
because treeviews have no width. The window which contains the treeview does, however. Here's what works:
? get(get(tv,"window"),"width") -- crazy, eh?
Well, the width of the "window" doesn't help, as that isn't the size of the TreeView. I want only the width of the container of the widget (I guess).
So, I have a GtkTreeView inside a GtkScrolledWindow inside a GtkBox inside a GtkPaned... and none of those have width, so I can't get the width of the GtkTreeView!
That's messed up.
How would I keep my columns relatively-spaced and remain completely inside the GtkScrolledWindow?!
Or maybe I've done something wrong.
Thank you for the guidance!