|
Graphics.UI.Gtk.TreeList.TreeStore | Portability | portable (depends on GHC) | Stability | provisional | Maintainer | gtk2hs-users@lists.sourceforge.net |
|
|
|
|
|
Description |
A tree-like data structure that can be used with the TreeView
|
|
Synopsis |
|
|
|
|
Detail
|
|
The TreeStore object is a list model for use with a TreeView widget.
It implements the TreeModel interface, and consequentialy, can use all of
the methods available there. It also implements the TreeSortable interface
so it can be sorted by the view. Finally, it also implements the tree drag
and drop interfaces.
|
|
Class Hierarchy
|
|
| GObject
| +----TreeStore
|
|
Types
|
|
data TreeStore |
Instances | |
|
|
class TreeModelClass o => TreeStoreClass o |
| Instances | |
|
|
castToTreeStore :: GObjectClass obj => obj -> TreeStore |
|
toTreeStore :: TreeStoreClass o => o -> TreeStore |
|
data TMType |
Constructors | TMinvalid | | TMuint | | TMint | | TMboolean | | TMenum | | TMflags | | TMfloat | | TMdouble | | TMstring | | TMobject | |
| Instances | |
|
|
data GenericValue |
A union with information about the currently stored type.
- Internally used by TreeStore.
| Constructors | |
|
|
Constructors
|
|
treeStoreNew :: [TMType] -> IO TreeStore |
Generate a new entity to store tree information.
|
|
Methods
|
|
treeStoreSetValue :: TreeStoreClass self => self -> TreeIter -> Int -> GenericValue -> IO () |
Set the data of a specific node. The supplied
value must match the type that was set for the column.
|
|
treeStoreRemove :: TreeStoreClass self => self -> TreeIter -> IO Bool |
Remove a specific node.
- The TreeIter will point to the entry following the one which
was just removed. The function returns False if the
tiTreeIter does not point to a valid element (i.e. the
function just removed the bottom entry from the tree).
- This function returned () in Gtk version 2.0.X
|
|
treeStoreInsert |
:: TreeStoreClass self | | => self | | -> Maybe TreeIter | parent - A valid TreeIter, or Nothing
| -> Int | position - position to insert the new row
| -> IO TreeIter | | Insert a child node into the tree. If the parent
is Nothing the insert at the root of the tree. The pos parameter determines
the position with respect to other siblings. Set this to -1 to insert the
node as last node.
|
|
|
treeStoreInsertBefore :: TreeStoreClass self => self -> TreeIter -> IO TreeIter |
Insert a node in front of the sibling node on the same level.
|
|
treeStoreInsertAfter :: TreeStoreClass self => self -> TreeIter -> IO TreeIter |
Insert a node behind the sibling node on the same level.
|
|
treeStorePrepend |
|
|
treeStoreAppend |
|
|
treeStoreIsAncestor :: TreeStoreClass self => self -> TreeIter -> TreeIter -> IO Bool |
Check if a node is in a parental relationship
with another node. Returns True even if parent is grandparent,... of child.
|
|
treeStoreIterDepth :: TreeStoreClass self => self -> TreeIter -> IO Int |
Calculate the level of a node. Returns 1 for a root node.
|
|
treeStoreClear :: TreeStoreClass self => self -> IO () |
Removes all rows from the store.
|
|
Produced by Haddock version 0.7 |