TreeView Class Reference

Inheritance diagram for TreeView:

Container List of all members.

Detailed Description

A container to display a tree or a list (a list is a tree with all row a the same level).


Public Member Functions

 this ()
 Creates a new TreeView.
 this (TreeModel model)
 Creates a new TreeView from a TreeModel.
TreeModel getModel ()
 Gets the model for this tree.
ListStore getListStore ()
 Gets the list model for this tree.
void setModel (TreeModel model)
 Sets the model fro this tree view.
TreeSelection getSelection ()
 Gets a tree selection for this tree view.
Adjustment getHAdjustment ()
 getHAdjustment
void setHAdjustment (Adjustment adjustment)
 setHAdjustment
Adjustment getVAdjustment ()
 getVAdjustment
void setVAdjustment (Adjustment adjustment)
 setVAdjustment
bit getHeadersVisible ()
 Gets the headers visibility.
void setHeadersVisible (bit visible)
 Sets the headers visibility.
void columnsAutosize ()
 coluns autosize
void setHeadersClickable (bit setting)
 Sets the headers clickable or not.
void setRulesHint (bit setting)
 Sets the rules hint ???
bit getRulesHint ()
 Gets rules hint ???
gint appendColumn (TreeViewColumn column)
 Appends a new column to the tree.
gint removeColumn (TreeViewColumn column)
 remove column
gint insertColumn (TreeViewColumn column, gint position)
 insert column
gint insertEditableColumn (int position, char[] title, CellRenderer renderer, bit editable)
 Inserts a column and sets it's attributes.
gint gtk_tree_view_insert_column_with_attributes (GtkTreeView *tree_view, gint position, gchar *title, GtkCellRenderer *cell,...)
gint gtk_tree_view_insert_column_with_data_func (gtkT(), gint position, gchar *title, GtkCellRenderer *cell, GtkTreeCellDataFunc func, gpointer data, GDestroyNotify dnotify)
TreeViewColumn getColumn (int n)
 Gets a column by column number.
void removeAllColumns ()
 Removes all column from this tree view.
ListG getColumns ()
void moveColumnAfter (TreeViewColumn column, TreeViewColumn base_column)
 moveColumnAfter
void setExpanderColumn (TreeViewColumn column)
 setExpanderColumn
TreeViewColumn getExpanderColumn ()
 getgetExpanderColumn
void gtk_tree_view_set_column_drag_function (gtkT(), GtkTreeViewColumnDropFunc func, gpointer user_data, GtkDestroyNotify destroy)
void scrollToPoint (gint tree_x, gint tree_y)
 scrollToPoint
void scrollToCell (TreePath path, TreeViewColumn column, gboolean use_align, gfloat row_align, gfloat col_align)
 scrollToCell
void rowActivated (TreePath path, TreeViewColumn column)
 rowActivated
void expandAll ()
 expandAll
void collapseAll ()
 collapseAll
void expandToPath (TreePath path)
 expandToPath
bit expandRow (TreePath path, bit openAll)
 expandRow
bit expandRow (TreeIter iter, TreeModel model, bit openAll)
 Expands the row of the iter.
bit collapseRow (TreePath path)
 collapseRow
void mapExpandedRows (TreeViewMappingFunc func, gpointer data)
bit rowExpanded (TreePath path)
 rowExpanded
void setReorderable (bit reorderable)
 setReorderable
bit getReorderable ()
 getReorderable
void setCursor (TreePath path, TreeViewColumn focus_column, gboolean start_editing)
 setCursor
void setCursorOnCell (TreePath path, TreeViewColumn focus_column, CellRenderer focus_cell, gboolean start_editing)
 setCursorOnCell
void getCursor (TreePath path, TreeViewColumn focus_column)
 get cursor
WindowG getBinWindow ()
 getBinWindow
bit getPathAtPos (gint x, gint y, inout TreePath path, inout TreeViewColumn column, out gint cellX, out gint cellY)
 getPathAtPos
void getCellArea (TreePath path, TreeViewColumn column, Rectangle *rect)
 getCellArea
void getBackgroundArea (TreePath path, TreeViewColumn column, Rectangle *rect)
 getBackgroundArea
void getVisibleRect (Rectangle *visible_rect)
 getVisibleRect
void widgetToTreeCoords (gint wx, gint wy, gint *tx, gint *ty)
 widgetToTreeCoords
void treeToWidgetCoords (gint wx, gint wy, gint *tx, gint *ty)
 treeToWidgetCoords
void enableModelDragSource (ModifierType start_button_mask, GtkTargetEntry *targets, gint n_targets, DragAction actions)
 enableModelDragSource
void enableModelDrasDesc (GtkTargetEntry *targets, gint n_targets, DragAction actions)
 enableModelDrasDesc
void unsetRowsDragSource ()
 unsetRowsDragSource
void unsetRowsDragDest ()
 unsetRowsDragDest
void setDragDestRow (TreePath path, TreeViewDropPosition pos)
 setDragDestRow
void getDragDestRow (TreePath path, TreeViewDropPosition *pos)
 getDragDestRow
bit getDestRowAtPos (gint drag_x, gint drag_y, TreePath path, TreeViewDropPosition *pos)
 getDestRowAtPos
Pixmap createRowDragIcon (TreePath path)
 createRowDragIcon
void setEnableSearch (bit enable_search)
 setEnableSearch
bit getEnableSearch ()
 getEnableSearch
gint getSearchColumn ()
 getSearchColumn
void setSearchColumn (gint column)
 setSearchColumn
GtkTreeViewSearchEqualFunc gtk_tree_view_get_search_equal_func (gtkT())
void gtk_tree_view_set_search_equal_func (gtkT(), GtkTreeViewSearchEqualFunc search_equal_func, gpointer search_user_data, GtkDestroyNotify search_destroy)
TreeIter getSelectedIter ()
 gets the first selected iter or null if no rows are selected

Static Public Member Functions

GType getType ()
 Gets this class type.


Member Function Documentation

gint TreeView.appendColumn TreeViewColumn  column  ) 
 

Appends a new column to the tree.

Parameters:
column the new column

void TreeView.collapseAll  ) 
 

collapseAll

bit TreeView.collapseRow TreePath  path  ) 
 

collapseRow

Parameters:
path 
Returns:

void TreeView.columnsAutosize  ) 
 

coluns autosize

Pixmap TreeView.createRowDragIcon TreePath  path  ) 
 

createRowDragIcon

Parameters:
path 
Returns:

void TreeView.enableModelDragSource ModifierType  start_button_mask,
GtkTargetEntry *  targets,
gint  n_targets,
DragAction  actions
 

enableModelDragSource

Parameters:
start_button_mask 
targets 
n_targets 
actions 

void TreeView.enableModelDrasDesc GtkTargetEntry *  targets,
gint  n_targets,
DragAction  actions
 

enableModelDrasDesc

Parameters:
targets 
n_targets 
actions 

void TreeView.expandAll  ) 
 

expandAll

bit TreeView.expandRow TreeIter  iter,
TreeModel  model,
bit  openAll
 

Expands the row of the iter.

Parameters:
iter 
openAll 
Returns:

bit TreeView.expandRow TreePath  path,
bit  openAll
 

expandRow

Parameters:
path 
open_all 
Returns:

void TreeView.expandToPath TreePath  path  ) 
 

expandToPath

Parameters:
path 

void TreeView.getBackgroundArea TreePath  path,
TreeViewColumn  column,
Rectangle *  rect
 

getBackgroundArea

Parameters:
path 
column 
rect 

WindowG TreeView.getBinWindow  ) 
 

getBinWindow

Returns:

void TreeView.getCellArea TreePath  path,
TreeViewColumn  column,
Rectangle *  rect
 

getCellArea

Parameters:
path 
column 
rect 

TreeViewColumn TreeView.getColumn int  n  ) 
 

Gets a column by column number.

Parameters:
n the column number
Returns:
a new TreeViewColumn for the Gtk column

ListG TreeView.getColumns  ) 
 

Todo:
return an array of TreeViewColumn instead of a list Gets s ListG with all the columns
Returns:
a listG

void TreeView.getCursor TreePath  path,
TreeViewColumn  focus_column
 

get cursor

Parameters:
path 
focus_column 

bit TreeView.getDestRowAtPos gint  drag_x,
gint  drag_y,
TreePath  path,
TreeViewDropPosition *  pos
 

getDestRowAtPos

Parameters:
drag_x 
drag_y 
path 
pos 
Returns:

void TreeView.getDragDestRow TreePath  path,
TreeViewDropPosition *  pos
 

getDragDestRow

Parameters:
path 
pos 

bit TreeView.getEnableSearch  ) 
 

getEnableSearch

Returns:

TreeViewColumn TreeView.getExpanderColumn  ) 
 

getgetExpanderColumn

Returns:
TreeViewColumn

Adjustment TreeView.getHAdjustment  ) 
 

getHAdjustment

Returns:

bit TreeView.getHeadersVisible  ) 
 

Gets the headers visibility.

Returns:
true if the headers are visible

ListStore TreeView.getListStore  ) 
 

Gets the list model for this tree.

Returns:
a new ListStore from the tree view model

TreeModel TreeView.getModel  ) 
 

Gets the model for this tree.

Returns:
a new TreeStore from the tree view model

bit TreeView.getPathAtPos gint  x,
gint  y,
inout TreePath  path,
inout TreeViewColumn  column,
out gint  cellX,
out gint  cellY
 

getPathAtPos

Parameters:
x 
y 
path 
column 
cell_x 
cell_y 
Returns:

bit TreeView.getReorderable  ) 
 

getReorderable

Returns:

bit TreeView.getRulesHint  ) 
 

Gets rules hint ???

Returns:
rules hint ???

gint TreeView.getSearchColumn  ) 
 

getSearchColumn

Returns:

TreeIter TreeView.getSelectedIter  ) 
 

gets the first selected iter or null if no rows are selected

TreeSelection TreeView.getSelection  ) 
 

Gets a tree selection for this tree view.

Returns:
a tree selection for this tree

GType TreeView.getType  )  [static]
 

Gets this class type.

Returns:
this class type

Reimplemented from Widget.

Adjustment TreeView.getVAdjustment  ) 
 

getVAdjustment

Returns:

void TreeView.getVisibleRect Rectangle *  visible_rect  ) 
 

getVisibleRect

Parameters:
visible_rect 

GtkTreeViewSearchEqualFunc TreeView.gtk_tree_view_get_search_equal_func gtkT()   ) 
 

Todo:
move this to a listener ???

gint TreeView.gtk_tree_view_insert_column_with_attributes GtkTreeView *  tree_view,
gint  position,
gchar *  title,
GtkCellRenderer *  cell,
  ...
 

Todo:

gint TreeView.gtk_tree_view_insert_column_with_data_func gtkT()  ,
gint  position,
gchar *  title,
GtkCellRenderer *  cell,
GtkTreeCellDataFunc  func,
gpointer  data,
GDestroyNotify  dnotify
 

Todo:

void TreeView.gtk_tree_view_set_column_drag_function gtkT()  ,
GtkTreeViewColumnDropFunc  func,
gpointer  user_data,
GtkDestroyNotify  destroy
 

Todo:
add this to a listener

void TreeView.gtk_tree_view_set_search_equal_func gtkT()  ,
GtkTreeViewSearchEqualFunc  search_equal_func,
gpointer  search_user_data,
GtkDestroyNotify  search_destroy
 

Todo:
move this to a listener ???

gint TreeView.insertColumn TreeViewColumn  column,
gint  position
 

insert column

Parameters:
column 
position 
Returns:
number of columns

gint TreeView.insertEditableColumn int  position,
char[]  title,
CellRenderer  renderer,
bit  editable
 

Inserts a column and sets it's attributes.

Parameters:
position 
title 
renderer 
editable 
Returns:
number of columns including the new one

void TreeView.mapExpandedRows TreeViewMappingFunc  func,
gpointer  data
 

Todo:

void TreeView.moveColumnAfter TreeViewColumn  column,
TreeViewColumn  base_column
 

moveColumnAfter

Parameters:
column 
base_column 

void TreeView.removeAllColumns  ) 
 

Removes all column from this tree view.

gint TreeView.removeColumn TreeViewColumn  column  ) 
 

remove column

Parameters:
column 
Returns:
number of columns

void TreeView.rowActivated TreePath  path,
TreeViewColumn  column
 

rowActivated

Parameters:
path 
column 

bit TreeView.rowExpanded TreePath  path  ) 
 

rowExpanded

Parameters:
path 
Returns:

void TreeView.scrollToCell TreePath  path,
TreeViewColumn  column,
gboolean  use_align,
gfloat  row_align,
gfloat  col_align
 

scrollToCell

Parameters:
path 
column 
use_align 
row_align 
col_align 

void TreeView.scrollToPoint gint  tree_x,
gint  tree_y
 

scrollToPoint

Parameters:
tree_x 
tree_y 

void TreeView.setCursor TreePath  path,
TreeViewColumn  focus_column,
gboolean  start_editing
 

setCursor

Parameters:
path 
focus_column 
start_editing 

void TreeView.setCursorOnCell TreePath  path,
TreeViewColumn  focus_column,
CellRenderer  focus_cell,
gboolean  start_editing
 

setCursorOnCell

Parameters:
path 
focus_column 
focus_cell 
start_editing 

void TreeView.setDragDestRow TreePath  path,
TreeViewDropPosition  pos
 

setDragDestRow

Parameters:
path 
pos 

void TreeView.setEnableSearch bit  enable_search  ) 
 

setEnableSearch

Parameters:
enable_search 

void TreeView.setExpanderColumn TreeViewColumn  column  ) 
 

setExpanderColumn

Parameters:
column 

void TreeView.setHAdjustment Adjustment  adjustment  ) 
 

setHAdjustment

Parameters:
adjustment 

void TreeView.setHeadersClickable bit  setting  ) 
 

Sets the headers clickable or not.

Parameters:
setting if true the headers will be clicable

void TreeView.setHeadersVisible bit  visible  ) 
 

Sets the headers visibility.

Parameters:
visible if true the headers will be visible

void TreeView.setModel TreeModel  model  ) 
 

Sets the model fro this tree view.

Parameters:
model the new treeModel

void TreeView.setReorderable bit  reorderable  ) 
 

setReorderable

Parameters:
reorderable 

void TreeView.setRulesHint bit  setting  ) 
 

Sets the rules hint ???

Parameters:
setting 

void TreeView.setSearchColumn gint  column  ) 
 

setSearchColumn

Parameters:
column 

void TreeView.setVAdjustment Adjustment  adjustment  ) 
 

setVAdjustment

Parameters:
adjustment 

TreeView.this TreeModel  model  ) 
 

Creates a new TreeView from a TreeModel.

Parameters:
model the treeModel

TreeView.this  ) 
 

Creates a new TreeView.

void TreeView.treeToWidgetCoords gint  wx,
gint  wy,
gint *  tx,
gint *  ty
 

treeToWidgetCoords

Parameters:
wx 
wy 
tx 
ty 

void TreeView.unsetRowsDragDest  ) 
 

unsetRowsDragDest

void TreeView.unsetRowsDragSource  ) 
 

unsetRowsDragSource

void TreeView.widgetToTreeCoords gint  wx,
gint  wy,
gint *  tx,
gint *  ty
 

widgetToTreeCoords

Parameters:
wx 
wy 
tx 
ty 


SourceForge.net Logo DSource.org Logo digitalmars.com Logo