[Glade-devel] glade-3 and GtkTreeView



Hans Kramer wrote:
[...]
I am not familiar enough with these kind of widgets and their complexity
to make any smart suggestions here. Nonetheless, I think it would rather
convenient to design the ModelView inside Glade as well, instead of
adding them later on inside the application.

Are there any ideas or thoughts roaming around how to implement this,
without making the code base of Glade insanely convoluted. I would
gladly invest some time if there is interest in this.

     To answer your question briefly, I'd be thrilled if you would pick
up the ball on this issue, its definitly on the most wanted list.

Here's a short background on the topic:

     Since around December 2004 we have almost complete support for
non-widget objects in glade-3; I say almost because we're missing
a couple details:
     o Only GtkWindow objects are allowed to be top-levels in glade-3
       (which is easy to change)
     o Object references arent implemented
       (http://bugzilla.gnome.org/show_bug.cgi?id=304390)
       it'd be nice if; for example we could associate a GtkVScale with
       a GtkAdjustment by a magic reference, so that if the GtkAdjustment
       changes its name, the GtkVScale will still refer to the correct
       adjustment.

But asides from that, the core code allows any object type to parent
any other object type, so it should be possible for GtkTreeView
columns to be added as children to the GtkTreeView, and then set the
GtkTreeStore as a "reference" to a previously defined tree store
in the project (pretty much as requested here:
http://bugzilla.gnome.org/show_bug.cgi?id=131382)

What I'm not sure of is how to deal with column attributes:
==========================================================
        gtk_tree_view_insert_column_with_attributes
                (GTK_TREE_VIEW (view_widget), COLUMN_ENABLED,
                 _("Reset"), renderer,
                 "sensitive", COLUMN_NDEFAULT,
                 "activatable", COLUMN_NDEFAULT,
                 "active", COLUMN_ENABLED,
                 "visible", COLUMN_CHILD,
                 NULL);
==========================================================

Maybe these could be handled as child properties of the column ?
How do we make column indexes "usable" ?

We'll probably need an extra editor segment (like menus and
toolbars) to edit treeviews and thier friends.

Note that currently you need to apply this patch to libglade
for non-widget objects to work in libglade:
     http://bugzilla.gnome.org/show_bug.cgi?id=161903

Cheers,
                            -Tristan




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