RE: [PHP-GTK-DOC] cvs: php-gtk-doc /en/reference/gtk gtktree.xml
| From: | Steph | Date: | Fri, 30 Jul 2004 19:30:48 +0000 |
| Subject: | RE: [PHP-GTK-DOC] cvs: php-gtk-doc /en/reference/gtk gtktree.xml | ||
| References: | 1 | Groups: | php.gtk.doc |
| Request: | Send a blank email to php-gtk-doc+get-985@lists.php.net to get a copy of this message | ||
Tree and treeitem aren't too scary or difficult to check (looking briefly at
gtk source).
The bit that says 'GTK_TYPE_NONE' tells you how many parameters there are.
The parameters themselves are then listed. Get nervous if one of the
parameters has the word POINTER in it - otherwise they generally should work
in PHP-GTK as well as they do in GTK itself.
gtktree.c:
tree_signals[SELECTION_CHANGED] =
gtk_signal_new ("selection_changed",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, selection_changed),
_gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tree_signals[SELECT_CHILD] =
gtk_signal_new ("select_child",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, select_child),
_gtk_marshal_VOID__OBJECT,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
tree_signals[UNSELECT_CHILD] =
gtk_signal_new ("unselect_child",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, unselect_child),
_gtk_marshal_VOID__OBJECT,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
}
gtktreeitem.c:
tree_item_signals[EXPAND_TREE] =
gtk_signal_new ("expand",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeItemClass, expand),
_gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tree_item_signals[COLLAPSE_TREE] =
gtk_signal_new ("collapse",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeItemClass, collapse),
_gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
}
> -----Original Message-----
> From: Scott Mattocks [mailto:scottmattocks@php.net]
> Sent: 30 July 2004 20:06
> To: php-gtk-doc@lists.php.net
> Subject: [PHP-GTK-DOC] cvs: php-gtk-doc /en/reference/gtk gtktree.xml
>
>
> scottmattocks Fri Jul 30 15:05:30 2004 EDT
>
> Modified files:
> /php-gtk-doc/en/reference/gtk gtktree.xml
> Log:
> Documented unselect_item, select_child, unselect_child,
> set_selection_mode, set_view_mode, set_view_lines. Method docs
> should be sufficient. (More examples could be added) May need to
> add signals.
>
>
> http://cvs.php.net/diff.php/php-gtk-doc/en/reference/gtk/gtktree.x
> ml?r1=1.6&r2=1.7&ty=u
> Index: php-gtk-doc/en/reference/gtk/gtktree.xml
> diff -u php-gtk-doc/en/reference/gtk/gtktree.xml:1.6
> php-gtk-doc/en/reference/gtk/gtktree.xml:1.7
> --- php-gtk-doc/en/reference/gtk/gtktree.xml:1.6 Fri Jul 30
> 08:29:49 2004
> +++ php-gtk-doc/en/reference/gtk/gtktree.xml Fri Jul 30 15:05:30 2004
> @@ -284,7 +284,7 @@
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> - Selects a node of the tree.
> + Selects a node of the tree by position.
> </shortdesc>
> <desc>
> <simpara>
> @@ -330,16 +330,19 @@
> <function>unselect_item</function>
> </funcdef>
> <paramdef>int
> - <parameter>item</parameter>
> + <parameter>position</parameter>
> </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> - Unselects a node of the tree.
> + Unselects a node of the tree by position.
> </shortdesc>
> <desc>
> <simpara>
> - Unhighlights and unselects a previously selected node.
> + Unselects the node in <parameter>position</parameter>.
> Unselecting a node causes the node to emit the <signalname
> class="GtkTree">deselect</signalname> signal. Unselecting a node
> that is not selected will select the node.
> + </simpara>
> + <simpara>
> + Node positions are indexed begining with zero. The fourth
> node is in position three.
> </simpara>
> </desc>
> </method>
> @@ -347,30 +350,44 @@
> <method id="gtk.gtktree.method.select_child">
> <funcsynopsis>
> <funcprototype>
> - <funcdef>void <function>select_child</function></funcdef>
> - <paramdef><classname>GtkWidget</classname>
> <parameter>tree_item</parameter></paramdef>
> + <funcdef>void
> + <function>select_child</function>
> + </funcdef>
> + <paramdef>
> + <classname>GtkWidget</classname>
> + <parameter>tree_item</parameter>
> + </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> -
> + Selects a node of a tree by object.
> </shortdesc>
> <desc>
> -
> + <simpara>
> + Selects the node <parameter>tree_item</parameter>.
> Selecting a node causes the <signalname
> class="GtkTreeItem">select</signalname> signal to be emitted.
> + </simpara>
> </desc>
> </method>
>
> <method id="gtk.gtktree.method.unselect_child">
> <funcsynopsis>
> <funcprototype>
> - <funcdef>void <function>unselect_child</function></funcdef>
> - <paramdef><classname>GtkWidget</classname>
> <parameter>tree_item</parameter></paramdef>
> + <funcdef>void
> + <function>unselect_child</function>
> + </funcdef>
> + <paramdef>
> + <classname>GtkWidget</classname>
> + <parameter>tree_item</parameter>
> + </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> -
> + Unselects a node of a tree by object.
> </shortdesc>
> <desc>
> -
> + <simpara>
> + Unselects <parameter>tree_item</parameter>. Unselecting a
> node causes the <signalname
> class="GtkTreeItem">deselect</signalname> signal to be emitted.
> + </simpara>
> </desc>
> </method>
>
> @@ -402,45 +419,74 @@
> <method id="gtk.gtktree.method.set_selection_mode">
> <funcsynopsis>
> <funcprototype>
> - <funcdef>void <function>set_selection_mode</function></funcdef>
> - <paramdef><enumname>GtkSelectionMode</enumname>
> <parameter>mode</parameter></paramdef>
> + <funcdef>void
> + <function>set_selection_mode</function>
> + </funcdef>
> + <paramdef>
> + <enumname>GtkSelectionMode</enumname>
> + <parameter>mode</parameter>
> + </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> -
> + Sets the tree's selection mode.
> </shortdesc>
> <desc>
> -
> + <simpara>
> + Sets the selection mode to <parameter>mode</parameter>.
> <literal>GTK_SELECTION_SINGLE</literal> is the default.
> + </simpara>
> + <simpara>
> + The selection mode determines how many nodes may/must be
> selected at one time.
> + </simpara>
> + <simpara>
> + See also: <enumname>GtkSelectionMode</enumname>
> + </simpara>
> </desc>
> </method>
>
> <method id="gtk.gtktree.method.set_view_mode">
> <funcsynopsis>
> <funcprototype>
> - <funcdef>void <function>set_view_mode</function></funcdef>
> - <paramdef><enumname>GtkTreeViewMode</enumname>
> <parameter>mode</parameter></paramdef>
> + <funcdef>void
> + <function>set_view_mode</function>
> + </funcdef>
> + <paramdef>
> + <enumname>GtkTreeViewMode</enumname>
> + <parameter>mode</parameter>
> + </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> -
> + Sets the tree's view mode.
> </shortdesc>
> <desc>
> -
> + <simpara>
> + Sets the tree's view mode to <parameter>mode</parameter>.
> The view mode defines how the tree looks when items are selected.
> The default mode is <literal>GTK_TREE_VIEW_ITEM</literal>.
> + </simpara>
> + <simpara>
> + See also: <enumname>GtkTreeViewMode</enumname>
> + </simpara>
> </desc>
> </method>
>
> <method id="gtk.gtktree.method.set_view_lines">
> <funcsynopsis>
> <funcprototype>
> - <funcdef>void <function>set_view_lines</function></funcdef>
> - <paramdef>int <parameter>flag</parameter></paramdef>
> + <funcdef>void
> + <function>set_view_lines</function>
> + </funcdef>
> + <paramdef>int
> + <parameter>flag</parameter>
> + </paramdef>
> </funcprototype>
> </funcsynopsis>
> <shortdesc>
> -
> + Sets how lines between nodes and children are to be drawn.
> </shortdesc>
> <desc>
> -
> + <simpara>
> + Sets whether or not lines between nodes and children should
> be drawn. If <parameter>flag</parameter> evaluates to
> <literal>true</literal> (<parameter>flag</parameter> > 0)
> connecting lines between nodes and children will be drawn. If
> <parameter>flag</parameter> evaluates to <literal>false</literal>
> (<parameter>flag</parameter> <= 0) connecting lines between
> nodes and children will not be drawn. By default tree's begin
> with view lines set to one.
> + </simpara>
> </desc>
> </method>
>
>
> --
> PHP-GTK Documentation Mailing List (http://gtk.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>