Gtk2HsContentsIndex
Graphics.UI.Gtk.TreeList.TreeStore
Description
Synopsis
data TreeStore
data TMType
= TMinvalid
| TMuint
| TMint
| TMuchar
| TMchar
| TMboolean
| TMenum
| TMflags
| TMpointer
| TMfloat
| TMdouble
| TMstring
| TMobject
| TMboxed
data GenericValue
= GVuint CUInt
| GVint CInt
| GVuchar CUChar
| GVchar CChar
| GVboolean Bool
| GVenum Int
| GVflags Int
| GVpointer (Ptr ())
| GVfloat Float
| GVdouble Double
| GVstring (Maybe String)
| GVobject GObject
| GVboxed (Ptr ())
treeStoreNew :: [TMType] -> IO TreeStore
treeStoreSetValue :: TreeStoreClass ts => ts -> TreeIter -> Int -> GenericValue -> IO ()
treeStoreRemove :: TreeStoreClass ts => ts -> TreeIter -> IO Bool
treeStoreInsert :: TreeStoreClass ts => ts -> Maybe TreeIter -> Int -> IO TreeIter
treeStoreInsertBefore :: TreeStoreClass ts => ts -> TreeIter -> IO TreeIter
treeStoreInsertAfter :: TreeStoreClass ts => ts -> TreeIter -> IO TreeIter
treeStorePrepend :: TreeStoreClass ts => ts -> Maybe TreeIter -> IO TreeIter
treeStoreAppend :: TreeStoreClass ts => ts -> Maybe TreeIter -> IO TreeIter
treeStoreIsAncestor :: TreeStoreClass ts => ts -> TreeIter -> TreeIter -> IO Bool
treeStoreIterDepth :: TreeStoreClass ts => ts -> TreeIter -> IO Int
treeStoreClear :: TreeStoreClass ts => ts -> IO ()
Documentation
data TreeStore
Instances
TreeStoreClass TreeStore
TreeModelClass TreeStore
GObjectClass TreeStore
data TMType
Constructors
TMinvalid
TMuint
TMint
TMuchar
TMchar
TMboolean
TMenum
TMflags
TMpointer
TMfloat
TMdouble
TMstring
TMobject
TMboxed
Instances
Enum TMType
data GenericValue

A union with information about the currently stored type.

  • Internally used by TreeStore.
Constructors
GVuint CUInt
GVint CInt
GVuchar CUChar
GVchar CChar
GVboolean Bool
GVenum Int
GVflags Int
GVpointer (Ptr ())
GVfloat Float
GVdouble Double
GVstring (Maybe String)
GVobject GObject
GVboxed (Ptr ())
Instances
Storable GenericValue
treeStoreNew :: [TMType] -> IO TreeStore
Generate a new entity to store tree information.
treeStoreSetValue :: TreeStoreClass ts => ts -> 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 ts => ts -> 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 ts => ts -> Maybe TreeIter -> Int -> 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 ts => ts -> TreeIter -> IO TreeIter
Insert a node in front of the sibling node on the same level.
treeStoreInsertAfter :: TreeStoreClass ts => ts -> TreeIter -> IO TreeIter
Insert a node behind the sibling node on the same level.
treeStorePrepend :: TreeStoreClass ts => ts -> Maybe TreeIter -> IO TreeIter

Insert a child node in front of every other sibling.

treeStoreAppend :: TreeStoreClass ts => ts -> Maybe TreeIter -> IO TreeIter

Insert a child node behind other siblings.

treeStoreIsAncestor :: TreeStoreClass ts => ts -> 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 ts => ts -> TreeIter -> IO Int
Calculate the level of a node. Returns 1 for a root node.
treeStoreClear :: TreeStoreClass ts => ts -> IO ()
Removes all rows from the store.
Produced by Haddock version 0.6