Maintainer | gtk2hs-users@lists.sourceforge.net |
---|---|
Stability | provisional |
Portability | portable (depends on GHC) |
Safe Haskell | None |
Language | Haskell98 |
A CellRenderer
which displays a single-line text.
- data CellRendererText
- class CellRendererClass o => CellRendererTextClass o
- castToCellRendererText :: GObjectClass obj => obj -> CellRendererText
- gTypeCellRendererText :: GType
- toCellRendererText :: CellRendererTextClass o => o -> CellRendererText
- cellRendererTextNew :: IO CellRendererText
- cellRendererTextSetFixedHeightFromFont :: CellRendererTextClass self => self -> Int -> IO ()
- cellText :: (CellRendererTextClass cr, GlibString string) => Attr cr string
- cellTextMarkup :: (CellRendererTextClass cr, GlibString string) => WriteAttr cr (Maybe string)
- cellTextSingleParagraphMode :: CellRendererTextClass self => Attr self Bool
- cellTextBackground :: (CellRendererClass self, GlibString string) => WriteAttr self string
- cellTextBackgroundColor :: CellRendererClass self => Attr self Color
- cellTextBackgroundSet :: CellRendererClass self => Attr self Bool
- cellTextForeground :: (CellRendererClass self, GlibString string) => WriteAttr self string
- cellTextForegroundColor :: CellRendererClass self => Attr self Color
- cellTextForegroundSet :: CellRendererClass self => Attr self Bool
- cellTextEditable :: CellRendererTextClass self => Attr self Bool
- cellTextEditableSet :: CellRendererTextClass self => Attr self Bool
- cellTextFont :: (CellRendererTextClass self, GlibString string) => Attr self string
- cellTextFontDesc :: CellRendererTextClass self => Attr self FontDescription
- cellTextFamily :: (CellRendererTextClass self, GlibString string) => Attr self string
- cellTextFamilySet :: CellRendererTextClass self => Attr self Bool
- cellTextStyle :: CellRendererTextClass self => Attr self FontStyle
- cellTextStyleSet :: CellRendererTextClass self => Attr self Bool
- cellTextVariant :: CellRendererTextClass self => Attr self Variant
- cellTextVariantSet :: CellRendererTextClass self => Attr self Bool
- cellTextWeight :: CellRendererTextClass self => Attr self Int
- cellTextWeightSet :: CellRendererTextClass self => Attr self Bool
- cellTextStretch :: CellRendererTextClass self => Attr self Stretch
- cellTextStretchSet :: CellRendererTextClass self => Attr self Bool
- cellTextSize :: CellRendererTextClass self => Attr self Double
- cellTextSizePoints :: CellRendererTextClass self => Attr self Double
- cellTextSizeSet :: CellRendererTextClass self => Attr self Bool
- cellTextScale :: CellRendererTextClass self => Attr self Double
- cellTextScaleSet :: CellRendererTextClass self => Attr self Bool
- cellTextRise :: CellRendererTextClass self => Attr self Int
- cellTextRiseSet :: CellRendererTextClass self => Attr self Bool
- cellTextStrikethrough :: CellRendererTextClass self => Attr self Bool
- cellTextStrikethroughSet :: CellRendererTextClass self => Attr self Bool
- cellTextUnderline :: CellRendererTextClass self => Attr self Underline
- cellTextUnderlineSet :: CellRendererTextClass self => Attr self Bool
- cellTextLanguage :: (CellRendererTextClass self, GlibString string) => Attr self (Maybe string)
- cellTextLanguageSet :: CellRendererTextClass self => Attr self Bool
- cellTextEllipsize :: CellRendererTextClass self => Attr self EllipsizeMode
- cellTextEllipsizeSet :: CellRendererTextClass self => Attr self Bool
- cellTextWidthChars :: CellRendererTextClass self => Attr self Int
- cellTextWrapMode :: CellRendererTextClass self => Attr self LayoutWrapMode
- cellTextWrapWidth :: CellRendererTextClass self => Attr self Int
- cellTextAlignment :: CellRendererTextClass self => Attr self LayoutAlignment
- edited :: (CellRendererTextClass self, GlibString string) => Signal self (TreePath -> string -> IO ())
- onEdited :: (CellRendererTextClass self, GlibString string) => self -> (TreePath -> string -> IO ()) -> IO (ConnectId self)
- afterEdited :: (CellRendererTextClass self, GlibString string) => self -> (TreePath -> string -> IO ()) -> IO (ConnectId self)
Detail
A CellRendererText
renders a given text in its cell, using the font,
color and style information provided by its attributes. The text will be
ellipsized if it is too long and the ellipsize property allows it.
If the cellMode
is CellRendererModeEditable
, the CellRendererText
allows the user to edit its text using an Entry
widget.
Class Hierarchy
|GObject
| +----Object
| +----CellRenderer
| +----CellRendererText | +----CellRendererCombo
Types
data CellRendererText Source #
class CellRendererClass o => CellRendererTextClass o Source #
castToCellRendererText :: GObjectClass obj => obj -> CellRendererText Source #
toCellRendererText :: CellRendererTextClass o => o -> CellRendererText Source #
Constructors
cellRendererTextNew :: IO CellRendererText Source #
Create a new CellRendererText object.
Methods
cellRendererTextSetFixedHeightFromFont Source #
:: CellRendererTextClass self | |
=> self | |
-> Int |
|
-> IO () |
Sets the height of a renderer to explicitly be determined by the
cellTextFont
and cellYPad
attribute set on it. Further changes in these properties do not affect the
height, so they must be accompanied by a subsequent call to this function.
Using this function is unflexible, and should really only be used if
calculating the size of a cell is too slow (ie, a massive number of cells
displayed). If numberOfRows
is -1, then the fixed height is unset, and
the height is determined by the properties again.
Attributes
cellText :: (CellRendererTextClass cr, GlibString string) => Attr cr string Source #
Define the attribute that specifies the text to be rendered. See
also cellTextMarkup
.
cellTextMarkup :: (CellRendererTextClass cr, GlibString string) => WriteAttr cr (Maybe string) Source #
Define a markup string instead of a text. See cellText
.
cellTextSingleParagraphMode :: CellRendererTextClass self => Attr self Bool Source #
Whether or not to keep all text in a single paragraph.
Default value: False
cellTextBackground :: (CellRendererClass self, GlibString string) => WriteAttr self string Source #
Text background color as a string.
Default value: ""
cellTextBackgroundColor :: CellRendererClass self => Attr self Color Source #
Text background color as a Color
.
cellTextBackgroundSet :: CellRendererClass self => Attr self Bool Source #
Whether the 'cellTextBackground'\/'cellTextBackgroundColor' attribute is set.
Default value: False
cellTextForeground :: (CellRendererClass self, GlibString string) => WriteAttr self string Source #
Text foreground color as a string.
Default value: ""
cellTextForegroundColor :: CellRendererClass self => Attr self Color Source #
Text foreground color as a Color
.
cellTextForegroundSet :: CellRendererClass self => Attr self Bool Source #
Whether the 'cellTextForeground'\/'cellTextForegroundColor' attribute is set.
Default value: False
cellTextEditable :: CellRendererTextClass self => Attr self Bool Source #
Whether the text can be modified by the user.
cellTextEditableSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextEditable
flag affects text editability.
cellTextFont :: (CellRendererTextClass self, GlibString string) => Attr self string Source #
Font description as a string.
cellTextFontDesc :: CellRendererTextClass self => Attr self FontDescription Source #
Font description as a FontDescription
.
cellTextFamily :: (CellRendererTextClass self, GlibString string) => Attr self string Source #
Name of the font family, e.g. Sans, Helvetica, Times, Monospace.
cellTextFamilySet :: CellRendererTextClass self => Attr self Bool Source #
Determines if cellTextFamily
has an effect.
cellTextStyle :: CellRendererTextClass self => Attr self FontStyle Source #
Font style (e.g. normal or italics).
cellTextStyleSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextStyle
tag is used, default is False
.
cellTextVariant :: CellRendererTextClass self => Attr self Variant Source #
Font variant (e.g. small caps).
cellTextVariantSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextVariant
tag is used, default is False
.
cellTextWeight :: CellRendererTextClass self => Attr self Int Source #
Font weight, default: 400.
cellTextWeightSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextWeight
tag is used, default is False
.
cellTextStretch :: CellRendererTextClass self => Attr self Stretch Source #
Font stretch.
cellTextStretchSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextStretch
tag is used, default is False
.
cellTextSize :: CellRendererTextClass self => Attr self Double Source #
Font size in points.
cellTextSizePoints :: CellRendererTextClass self => Attr self Double Source #
Font size in points.
Allowed values: >= 0
Default value: 0
cellTextSizeSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextSize
tag is used, default is False
.
cellTextScale :: CellRendererTextClass self => Attr self Double Source #
Font scaling factor. Default is 1.
cellTextScaleSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextScale
tag is used, default is False
.
cellTextRise :: CellRendererTextClass self => Attr self Int Source #
Offset of text above the baseline (below the baseline if rise is negative).
Allowed values: >= -2147483647
Default value: 0
cellTextRiseSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextRise
tag is used, default is False
.
cellTextStrikethrough :: CellRendererTextClass self => Attr self Bool Source #
Whether to strike through the text.
cellTextStrikethroughSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextStrikethrough
tag is used, default is False
.
cellTextUnderline :: CellRendererTextClass self => Attr self Underline Source #
Style of underline for this text.
cellTextUnderlineSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextUnderline
tag is used, default is False
.
cellTextLanguage :: (CellRendererTextClass self, GlibString string) => Attr self (Maybe string) Source #
The language this text is in, as an ISO code. Pango can use this as a hint when rendering the text. If you don't understand this parameter, you probably don't need it.
cellTextLanguageSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextLanguage
tag is used, default is False
.
cellTextEllipsize :: CellRendererTextClass self => Attr self EllipsizeMode Source #
Specifies the preferred place to ellipsize the string, if the cell
renderer does not have enough room to display the entire string.
Setting it to EllipsizeNone
turns off
ellipsizing. See the cellTextWrapWidth
property for another way of
making the text fit into a given width.
- Available in Gtk 2.6 or higher.
cellTextEllipsizeSet :: CellRendererTextClass self => Attr self Bool Source #
Whether the cellTextEllipsize
tag affects the ellipsize mode.
- Available in Gtk 2.6 or higher.
cellTextWidthChars :: CellRendererTextClass self => Attr self Int Source #
The desired width of the cell, in characters. If this property is set
to -1
, the width will be calculated automatically, otherwise the cell
will request either 3 characters or the property value, whichever is
greater.
- Available in Gtk 2.6 or higher.
cellTextWrapMode :: CellRendererTextClass self => Attr self LayoutWrapMode Source #
Specifies how to break the string into multiple lines, if the cell
renderer does not have enough room to display the entire string.
This property has no effect unless the cellTextWrapWidth
property is set.
- Available in Gtk 2.8 or higher.
cellTextWrapWidth :: CellRendererTextClass self => Attr self Int Source #
Specifies the width at which the text is wrapped. The wrap-mode
property can be used to influence at what character positions the
line breaks can be placed. Setting wrap-width to -1
turns wrapping off.
- Available in Gtk 2.8 or higher.
cellTextAlignment :: CellRendererTextClass self => Attr self LayoutAlignment Source #
Specifies how to align the lines of text with respect to each other.
Note that this property describes how to align the lines of text in case
there are several of them. The
cellXAlign
property of
CellRenderer
, on the other hand, sets the horizontal alignment of the
whole text.
Default value: AlignLeft
- Available since Gtk+ version 2.10
Signals
edited :: (CellRendererTextClass self, GlibString string) => Signal self (TreePath -> string -> IO ()) Source #
Emitted when the user finished editing a cell.
Whenever editing is finished successfully, this signal is emitted which
indicates that the model should be updated with the supplied value.
The value is always a string which matches the cellText
attribute of
CellRendererText
(and its derivates like CellRendererCombo
).
- This signal is not emitted when editing is disabled (see
cellTextEditable
) or when the user aborts editing.
Deprecated
onEdited :: (CellRendererTextClass self, GlibString string) => self -> (TreePath -> string -> IO ()) -> IO (ConnectId self) Source #
Deprecated: instead of 'onEdited obj' use 'on obj edited'
afterEdited :: (CellRendererTextClass self, GlibString string) => self -> (TreePath -> string -> IO ()) -> IO (ConnectId self) Source #
Deprecated: instead of 'afterEdited obj' use 'after obj edited'