[Glade-devel] [Glade-users] Using Treeviews
Tristan Van Berkom
tvb at gnome.org
Thu Dec 21 13:32:30 EST 2006
On Thu, 2006-12-21 at 14:43 -0300, John Coppens wrote:
[...]
> Hi Tristan.
>
> Defining the model data in the GUI is tempting, but I doubt if it is
> entirely appropiate or useful. The interface is likely to become
> complicated, for example permitting conditional attributes...
>
> _Not_ having all possibilities available in the GUI is, IMHO,
> counter-productive, as reliance on a GUI would mean less frequent
> 'manual' use...
Hi,
Here is my own personal opinion on the matter...
Treeviews are designed for optimization, you can display a
dataset of 100,000 rows in a treeview and you'll only render
the visible rows - this is the excelent value of the GtkTreeView.
Over time, treeviews have been abused, people use treeviews
to display a static list of choices for example - a job much
better suited for some simple canvas implementation, a dropdown
menu, combo box or such - why do I call this abuse ? because
it shouldnt take someone the effort of writing an entire treeview
code just to display a couple of options.
So, in the terms of what I think are valid use cases of a treeview,
where a treeview is not overkill for the task at hand, the model
data is invariably dynamic, nothing that could be defined in a
GUI designer.
So I would opt to sooner add support for canvases etc in glade
for those cases where people need simple hardcoded lists/choices,
and leave dynamic model data to the programmer to generate.
Maybe thats a drastic opinion ;-)
Cheers,
-Tristan
More information about the Glade-devel
mailing list