## ETree ETree |

## Synopsis

    struct              ETree;
    gboolean            e_tree_construct                    (ETree *tree,
                                                             ETreeModel *etm,
                                                             ETableExtras *ete,
                                                             ETableSpecification *specification);
    GtkWidget *         e_tree_new                          (ETreeModel *etm,
                                                             ETableExtras *ete,
                                                             ETableSpecification *specification);
    ETableState *       e_tree_get_state_object             (ETree *tree);
    ETableSpecification * e_tree_get_spec                   (ETree *tree);
    void                e_tree_set_state_object             (ETree *tree,
                                                             ETableState *state);
    void                e_tree_show_cursor_after_reflow     (ETree *tree);
    void                e_tree_set_cursor                   (ETree *tree,
                                                             ETreePath path);
    ETreePath           e_tree_get_cursor                   (ETree *tree);
    void                e_tree_path_foreach                 (ETree *tree,
                                                             ETreeForeachFunc callback,
                                                             gpointer closure);
    void                e_tree_get_cell_at                  (ETree *tree,
                                                             gint x,
                                                             gint y,
                                                             gint *row_return,
                                                             gint *col_return);
    void                e_tree_get_cell_geometry            (ETree *tree,
                                                             gint row,
                                                             gint col,
                                                             gint *x_return,
                                                             gint *y_return,
                                                             gint *width_return,
                                                             gint *height_return);
    ETreeModel *        e_tree_get_model                    (ETree *tree);
    ESelectionModel *   e_tree_get_selection_model          (ETree *tree);
    ETreeTableAdapter * e_tree_get_table_adapter            (ETree *tree);
    void                e_tree_drag_source_set              (ETree *tree,
                                                             GdkModifierType start_button_mask,
                                                             const GtkTargetEntry *targets,
                                                             gint n_targets,
                                                             GdkDragAction actions);
    void                e_tree_drag_source_unset            (ETree *tree);
    GdkDragContext *    e_tree_drag_begin                   (ETree *tree,
                                                             gint row,
                                                             gint col,
                                                             GtkTargetList *targets,
                                                             GdkDragAction actions,
                                                             gint button,
                                                             GdkEvent *event);
    gboolean            e_tree_is_dragging                  (ETree *tree);
    ETableItem *        e_tree_get_item                     (ETree *tree);
    GnomeCanvasItem *   e_tree_get_header_item              (ETree *tree);
    void                e_tree_set_info_message             (ETree *tree,
                                                             const gchar *info_message);
    void                e_tree_freeze_state_change          (ETree *tree);
    void                e_tree_thaw_state_change            (ETree *tree);
    gboolean            e_tree_is_editing                   (ETree *tree);

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----GtkWidget
                   +----GtkContainer
                         +----GtkTable
                               +----ETree

## Implemented Interfaces

ETree implements AtkImplementorIface, GtkBuildable and GtkScrollable.

## Properties

      "ETreeTableAdapter"        ETreeTableAdapter*    : Read
      "always-search"            gboolean              : Read / Write
      "drawfocus"                gboolean              : Write
      "horizontal-draw-grid"     gboolean              : Write
      "is-editing"               gboolean              : Read
      "length-threshold"         gint                  : Write
      "uniform-row-height"       gboolean              : Read / Write
      "vertical-draw-grid"       gboolean              : Write

## Style Properties

      "alternating-row-colors"   gboolean              : Read
      "expander-size"            gint                  : Read
      "vertical-spacing"         gint                  : Read

## Signals

      "click"                                          : Run Last
      "cursor-activated"                               : Run Last
      "cursor-change"                                  : Run Last
      "double-click"                                   : Run Last
      "key-press"                                      : Run Last
      "right-click"                                    : Run Last
      "selection-change"                               : Run Last
      "start-drag"                                     : Run Last
      "state-change"                                   : Run Last
      "tree-drag-begin"                                : Run Last
      "tree-drag-data-delete"                          : Run Last
      "tree-drag-data-get"                             : Run Last
      "tree-drag-data-received"                        : Run Last
      "tree-drag-drop"                                 : Run Last
      "tree-drag-end"                                  : Run Last
      "tree-drag-leave"                                : Run Last
      "tree-drag-motion"                               : Run Last
      "white-space-event"                              : Run Last

## Description

## Details

### struct ETree

    struct ETree;

### e_tree_construct ()

    gboolean            e_tree_construct                    (ETree *tree,
                                                             ETreeModel *etm,
                                                             ETableExtras *ete,
                                                             ETableSpecification *specification);

This is the internal implementation of `e_tree_new()` for use by subclasses or language bindings. See `e_tree_new()` for details.

`tree` : | The newly created ETree object.
`etm` : | The model for this table.
`ete` : | An optional ETableExtras. (`NULL` is valid.)
`specification` : | an ETableSpecification
Returns : | `TRUE` on success, `FALSE` if an error occurred

### e_tree_new ()

    GtkWidget *         e_tree_new                          (ETreeModel *etm,
                                                             ETableExtras *ete,
                                                             ETableSpecification *specification);

This function creates an ETree from the given parameters. The ETreeModel is a tree model to be represented. The ETableExtras is an optional set of pixbufs, cells, and sorting functions to be used when interpreting the spec. If you pass in `NULL` it uses the default ETableExtras. (See `e_table_extras_new()`).

`specification` is the specification of the set of viewable columns and the default sorting state and such. `state` is an optional string specifying the current sorting state and such.

`etm` : | The model for this tree
`ete` : | An optional ETableExtras (`NULL` is valid.)
`specification` : | an ETableSpecification
Returns : | The newly created ETree or `NULL` if there's an error.

### e_tree_get_state_object ()

    ETableState *       e_tree_get_state_object             (ETree *tree);

Builds an ETableState corresponding to the current state of the ETree.

`tree` : | ETree object to act on
Returns : | The `ETableState` object generated.

### e_tree_get_spec ()

    ETableSpecification * e_tree_get_spec                   (ETree *tree);

Returns the specification object.

`tree` : | The ETree to query

### e_tree_set_state_object ()

    void                e_tree_set_state_object             (ETree *tree,
                                                             ETableState *state);

### e_tree_show_cursor_after_reflow ()

    void                e_tree_show_cursor_after_reflow     (ETree *tree);

### e_tree_set_cursor ()

    void                e_tree_set_cursor                   (ETree *tree,
                                                             ETreePath path);

### e_tree_get_cursor ()

    ETreePath           e_tree_get_cursor                   (ETree *tree);

### e_tree_path_foreach ()

    void                e_tree_path_foreach                 (ETree *tree,
                                                             ETreeForeachFunc callback,
                                                             gpointer closure);

### e_tree_get_cell_at ()

    void                e_tree_get_cell_at                  (ETree *tree,
                                                             gint x,
                                                             gint y,
                                                             gint *row_return,
                                                             gint *col_return);

Return the row and column for the cell in which the pixel at (`x`, `y`) is contained.

`tree` : | An ETree widget
`x` : | X coordinate for the pixel
`y` : | Y coordinate for the pixel
`row_return` : | Pointer to return the row value
`col_return` : | Pointer to return the column value

### e_tree_get_cell_geometry ()

    void                e_tree_get_cell_geometry            (ETree *tree,
                                                             gint row,
                                                             gint col,
                                                             gint *x_return,
                                                             gint *y_return,
                                                             gint *width_return,
                                                             gint *height_return);

Computes the data about this cell.

`tree` : | The tree.
`row` : | The row to get the geometry of.
`col` : | The col to get the geometry of.
`x_return` : | Returns the x coordinate of the upper right hand corner of the cell with respect to the widget.
`y_return` : | Returns the y coordinate of the upper right hand corner of the cell with respect to the widget.
`width_return` : | Returns the width of the cell.
`height_return` : | Returns the height of the cell.

### e_tree_get_model ()

    ETreeModel *        e_tree_get_model                    (ETree *tree);

Returns the model upon which this ETree is based.

`tree` : | the ETree
Returns : | the model

### e_tree_get_selection_model ()

    ESelectionModel *   e_tree_get_selection_model          (ETree *tree);

Returns the selection model of this ETree.

`tree` : | the ETree
Returns : | the selection model

### e_tree_get_table_adapter ()

    ETreeTableAdapter * e_tree_get_table_adapter            (ETree *tree);

Returns the table adapter this ETree uses.

`tree` : | the ETree
Returns : | the model

### e_tree_drag_source_set ()

    void                e_tree_drag_source_set              (ETree *tree,
                                                             GdkModifierType start_button_mask,
                                                             const GtkTargetEntry *targets,
                                                             gint n_targets,
                                                             GdkDragAction actions);

### e_tree_drag_source_unset ()

    void                e_tree_drag_source_unset            (ETree *tree);

### e_tree_drag_begin ()

    GdkDragContext *    e_tree_drag_begin                   (ETree *tree,
                                                             gint row,
                                                             gint col,
                                                             GtkTargetList *targets,
                                                             GdkDragAction actions,
                                                             gint button,
                                                             GdkEvent *event);

### e_tree_is_dragging ()

    gboolean            e_tree_is_dragging                  (ETree *tree);

`tree` : | An ETree widget
Returns : | whether is `tree` in a drag&drop operation.

### e_tree_get_item ()

    ETableItem *        e_tree_get_item                     (ETree *tree);

### e_tree_get_header_item ()

    GnomeCanvasItem *   e_tree_get_header_item              (ETree *tree);

### e_tree_set_info_message ()

    void                e_tree_set_info_message             (ETree *tree,
                                                             const gchar *info_message);

Creates an info message in table area, or removes old.

`tree` : | ETree instance
`info_message` : | Message to set. Can be NULL.

### e_tree_freeze_state_change ()

    void                e_tree_freeze_state_change          (ETree *tree);

### e_tree_thaw_state_change ()

    void                e_tree_thaw_state_change            (ETree *tree);

### e_tree_is_editing ()

    gboolean            e_tree_is_editing                   (ETree *tree);

## Property Details

### The `"ETreeTableAdapter"` property

      "ETreeTableAdapter"        ETreeTableAdapter*    : Read

ETree table adapter.

### The `"always-search"` property

      "always-search"            gboolean              : Read / Write

Always search.

Default value: FALSE

### The `"drawfocus"` property

      "drawfocus"                gboolean              : Write

Draw focus.

Default value: FALSE

### The `"horizontal-draw-grid"` property

      "horizontal-draw-grid"     gboolean              : Write

Horizontal Draw Grid.

Default value: FALSE

### The `"is-editing"` property

      "is-editing"               gboolean              : Read

Whether is in an editing mode.

Default value: FALSE

### The `"length-threshold"` property

      "length-threshold"         gint                  : Write

Length Threshold.

Allowed values: >= 0

Default value: 0

### The `"uniform-row-height"` property

      "uniform-row-height"       gboolean              : Read / Write

Uniform row height.

Default value: FALSE

### The `"vertical-draw-grid"` property

      "vertical-draw-grid"       gboolean              : Write

Vertical Draw Grid.

Default value: FALSE

## Style Property Details

### The `"alternating-row-colors"` style property

      "alternating-row-colors"   gboolean              : Read

Whether to use alternating row colors.

Default value: TRUE

### The `"expander-size"` style property

      "expander-size"            gint                  : Read

Size of the expander arrow.

Allowed values: >= 0

Default value: 10

### The `"vertical-spacing"` style property

      "vertical-spacing"         gint                  : Read

Vertical space between rows. It is added to top and to bottom of a row.

Allowed values: >= 0

Default value: 3

## Signal Details

### The `"click"` signal

    gboolean            user_function                      (ETree    *etree,
                                                            gint      arg1,
                                                            gpointer  arg2,
                                                            gint      arg3,
                                                            GdkEvent *arg4,
                                                            gpointer  user_data)      : Run Last

### The `"cursor-activated"` signal

    void                user_function                      (ETree   *etree,
                                                            gint     arg1,
                                                            gpointer arg2,
                                                            gpointer user_data)      : Run Last

### The `"cursor-change"` signal

    void                user_function                      (ETree   *etree,
                                                            gint     arg1,
                                                            gpointer arg2,
                                                            gpointer user_data)      : Run Last

### The `"double-click"` signal

    void                user_function                      (ETree    *etree,
                                                            gint      arg1,
                                                            gpointer  arg2,
                                                            gint      arg3,
                                                            GdkEvent *arg4,
                                                            gpointer  user_data)      : Run Last

### The `"key-press"` signal

    gboolean            user_function                      (ETree    *etree,
                                                            gint      arg1,
                                                            gpointer  arg2,
                                                            gint      arg3,
                                                            GdkEvent *arg4,
                                                            gpointer  user_data)      : Run Last

### The `"right-click"` signal

    gboolean            user_function                      (ETree    *etree,
                                                            gint      arg1,
                                                            gpointer  arg2,
                                                            gint      arg3,
                                                            GdkEvent *arg4,
                                                            gpointer  user_data)      : Run Last

### The `"selection-change"` signal

    void                user_function                      (ETree   *etree,
                                                            gpointer user_data)      : Run Last

### The `"start-drag"` signal

    void                user_function                      (ETree    *etree,
                                                            gint      arg1,
                                                            gpointer  arg2,
                                                            gint      arg3,
                                                            GdkEvent *arg4,
                                                            gpointer  user_data)      : Run Last

### The `"state-change"` signal

    void                user_function                      (ETree   *etree,
                                                            gpointer user_data)      : Run Last

### The `"tree-drag-begin"` signal

    void                user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            gpointer        user_data)      : Run Last

### The `"tree-drag-data-delete"` signal

    void                user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            gpointer        user_data)      : Run Last

### The `"tree-drag-data-get"` signal

    void                user_function                      (ETree            *etree,
                                                            gint              arg1,
                                                            gpointer          arg2,
                                                            gint              arg3,
                                                            GdkDragContext   *arg4,
                                                            GtkSelectionData *arg5,
                                                            guint             arg6,
                                                            guint             arg7,
                                                            gpointer          user_data)      : Run Last

### The `"tree-drag-data-received"` signal

    void                user_function                      (ETree            *etree,
                                                            gint              arg1,
                                                            gpointer          arg2,
                                                            gint              arg3,
                                                            GdkDragContext   *arg4,
                                                            gint              arg5,
                                                            gint              arg6,
                                                            GtkSelectionData *arg7,
                                                            guint             arg8,
                                                            guint             arg9,
                                                            gpointer          user_data)      : Run Last

### The `"tree-drag-drop"` signal

    gboolean            user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            gint            arg5,
                                                            gint            arg6,
                                                            guint           arg7,
                                                            gpointer        user_data)      : Run Last

### The `"tree-drag-end"` signal

    void                user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            gpointer        user_data)      : Run Last

### The `"tree-drag-leave"` signal

    void                user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            guint           arg5,
                                                            gpointer        user_data)      : Run Last

### The `"tree-drag-motion"` signal

    gboolean            user_function                      (ETree          *etree,
                                                            gint            arg1,
                                                            gpointer        arg2,
                                                            gint            arg3,
                                                            GdkDragContext *arg4,
                                                            gint            arg5,
                                                            gint            arg6,
                                                            guint           arg7,
                                                            gpointer        user_data)      : Run Last

### The `"white-space-event"` signal

    gboolean            user_function                      (ETree    *etree,
                                                            GdkEvent *arg1,
                                                            gpointer  user_data)      : Run Last