gtk-0.12.0: Binding to the Gtk+ graphical user interface library.

Portability | portable (depends on GHC)
Stability | provisional
Maintainer | gtk2hs-users@lists.sourceforge.net

Graphics.UI.Gtk.ModelView.CellView

Contents

- Detail
- Class Hierarchy
- Types
- Constructors
- Methods
- Attributes

Description

A widget displaying a single row of a `TreeModel`

- Module available since Gtk+ version 2.6

Synopsis

- data CellView
- class WidgetClass o => CellViewClass o
- castToCellView :: GObjectClass obj => obj -> CellView
- gTypeCellView :: GType
- toCellView :: CellViewClass o => o -> CellView
- cellViewNew :: IO CellView
- cellViewNewWithMarkup :: String -> IO CellView
- cellViewNewWithPixbuf :: Pixbuf -> IO CellView
- cellViewNewWithText :: String -> IO CellView
- cellViewSetModel :: (CellViewClass self, TreeModelClass model) => self -> Maybe model -> IO ()
- cellViewGetSizeOfRow :: CellViewClass self => self -> TreePath -> IO Requisition
- cellViewSetBackgroundColor :: CellViewClass self => self -> Color -> IO ()
- cellViewGetCellRenderers :: CellViewClass self => self -> IO [CellRenderer]
- cellViewBackground :: CellViewClass self => WriteAttr self String

# Detail

A `CellView` displays a single row of a `TreeModel`, using cell renderers just like `TreeView`. `CellView` doesn't support some of the more complex features of `TreeView`, like cell editing and drag and drop.

# Class Hierarchy

     | GObject
     | +----Object
     | +----Widget
     | +----CellView

# Types

data CellView

Instances

Eq CellView |
Ord CellView |
GObjectClass CellView |
CellLayoutClass CellView |
CellViewClass CellView |
WidgetClass CellView |
ObjectClass CellView |

class WidgetClass o => CellViewClass o

Instances

CellViewClass CellView |

castToCellView :: GObjectClass obj => obj -> CellView

gTypeCellView :: GType

toCellView :: CellViewClass o => o -> CellView

# Constructors

cellViewNew :: IO CellView

Creates a new `CellView` widget.

cellViewNewWithMarkup

Arguments

:: String | `markup` - the text to display in the cell view
-> IO CellView |

Creates a new `CellView` widget, adds a `CellRendererText` to it, and makes its show `markup`. The text can be marked up with the Pango text markup language.

cellViewNewWithPixbuf

Arguments

:: Pixbuf | `pixbuf` - the image to display in the cell view
-> IO CellView |

Creates a new `CellView` widget, adds a `CellRendererPixbuf` to it, and makes its show `pixbuf`.

cellViewNewWithText

Arguments

:: String | `text` - the text to display in the cell view
-> IO CellView |

Creates a new `CellView` widget, adds a `CellRendererText` to it, and makes its show `text`.

# Methods

cellViewSetModel

Arguments

:: (CellViewClass self, TreeModelClass model) |
=> self |
-> Maybe model | `model` - a `TreeModel`
-> IO () |

Sets the model for `cellView`. If `cellView` already has a model set, it will remove it before setting the new model. If `model` is `Nothing`, then it will unset the old model.

cellViewGetSizeOfRow

Arguments

:: CellViewClass self |
=> self |
-> TreePath | `path` - a `TreePath`
-> IO Requisition | returns the size requisition

Returns the size needed by the cell view to display the model row pointed to by `path`.

cellViewSetBackgroundColor

Arguments

:: CellViewClass self |
=> self |
-> Color | `color` - the new background color
-> IO () |

Sets the background color of `view`.

cellViewGetCellRenderers :: CellViewClass self => self -> IO [CellRenderer]

Returns the cell renderers which have been added to `cellView`.

# Attributes

cellViewBackground :: CellViewClass self => WriteAttr self String

Background color as a string.

Default value: `""`