Reference Manual

Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

# Inti::Gtk::CellRendererText Class Reference

A GtkCellRendererText C++ wrapper class. More...

`#include <inti/gtk/cellrenderer.h>`

Inheritance diagram for Inti::Gtk::CellRendererText:

List of all members.

## Public Member Functions

Constructors

- CellRendererText ()
    Construct a new CellRendererText.
- virtual ~CellRendererText ()
    Destructor.

Accessors

- GtkCellRendererText * gtk_cell_renderer_text () const
    Get a pointer to the GtkCellRendererText structure.
- GtkCellRendererTextClass * gtk_cell_renderer_text_class () const
    Get a pointer to the GtkCellRendererTextClass structure.
- operator GtkCellRendererText * () const
    Conversion operator; safely converts a CellRendererText to a GtkCellRendererText pointer.

Methods

- void set_fixed_height_from_font (int number_of_rows)
    Sets the height of a renderer to explicitly be determined by the "font" and the "y_pad" property set on it.

Property Proxies

- const TextPropertyProxy prop_text ()
    Text to render (String : Read / Write).
- const MarkupPropertyProxy prop_markup ()
    Marked up text to render (String : Write).
- const AttributePropertyProxy prop_attribute ()
    A list of style attributes to apply to the text of the renderer (Pointer<Pango::AttrList> : Read / Write).
- const BackgroundPropertyProxy prop_background ()
    Background color as a string (String : Write).
- const BackgroundGdkPropertyProxy prop_background_gdk ()
    Background color as a Gdk::Color (Pointer<Gdk::Color> : Read / Write).
- const ForegroundPropertyProxy prop_foreground ()
    Foreground color as a string (String : Write).
- const ForegroundGdkPropertyProxy prop_foreground_gdk ()
    Foreground color as a Gdk::Color (Pointer<Gdk::Color> : Read / Write).
- const EditablePropertyProxy prop_editable ()
    Whether the text can be modified by the user (bool : Read / Write).
- const FontPropertyProxy prop_font ()
    Font description as a string (String : Read / Write).
- const FontDescPropertyProxy prop_font_desc ()
    Font description as a Pango::FontDescription (Pointer<Pango::FontDescription> : Read / Write).
- const FamilyPropertyProxy prop_family ()
    Name of the font family, e.g. Sans, Helvetica, Times, Monospace (String : Read / Write).
- const StylePropertyProxy prop_style ()
    Font style (Pango::Style : Read / Write).
- const VariantPropertyProxy prop_variant ()
    Font variant (Pango::Variant : Read / Write).
- const WeightPropertyProxy prop_weight ()
    Font weight (int : Read / Write).
- const StretchPropertyProxy prop_stretch ()
    Font stretch (Pango::Stretch : Read / Write).
- const SizePropertyProxy prop_size ()
    Font size (int : Read / Write).
- const SizePointsPropertyProxy prop_size_points ()
    Font size in points (double : Read / Write).
- const ScalePropertyProxy prop_scale ()
    Font scaling factor (double : Read / Write).
- const RisePropertyProxy prop_rise ()
    Offset of text above the baseline (below the baseline if rise is negative) (int : Read / Write).
- const StrikethroughPropertyProxy prop_strikethrough ()
    Whether to strike through the text (bool : Read / Write).
- const UnderlinePropertyProxy prop_underline ()
    Style of underline for this text (Pango::Underline : Read / Write).
- const BackgroundSetPropertyProxy prop_background_set ()
    Whether this tag affects the background color (bool : Read / Write).
- const ForegroundSetPropertyProxy prop_foreground_set ()
    Whether this tag affects the foreground color.
- const EditableSetPropertyProxy prop_editable_set ()
    Whether this tag affects text editability (bool : Read / Write).
- const FamilySetPropertyProxy prop_family_set ()
    Whether this tag affects the font family (bool : Read / Write).
- const StyleSetPropertyProxy prop_style_set ()
    Whether this tag affects the font style (bool : Read / Write).
- const VariantSetPropertyProxy prop_variant_set ()
    Whether this tag affects the font variant (bool : Read / Write).
- const WeightSetPropertyProxy prop_weight_set ()
    Whether this tag affects the font weight (bool : Read / Write).
- const StretchSetPropertyProxy prop_stretch_set ()
    Whether this tag affects the font stretch (bool : Read / Write).
- const SizeSetPropertyProxy prop_size_set ()
    Whether this tag affects the font size (bool : Read / Write).
- const ScaleSetPropertyProxy prop_scale_set ()
    Whether this tag scales the font size by a factor (bool : Read / Write).
- const RiseSetPropertyProxy prop_rise_set ()
    Whether this tag scales the font size by a factor (bool : Read / Write).
- const StrikethroughSetPropertyProxy prop_strikethrough_set ()
    Whether this tag affects strikethrough (bool : Read / Write).
- const UnderlineSetPropertyProxy prop_underline_set ()
    Whether this tag affects underlining (bool : Read / Write).

Signal Proxies

- const EditedSignalProxy sig_edited ()
    Connect to the editing_done_signal; emitted when the user has finished editing the cell text.

## Protected Member Functions

Constructors

- CellRendererText (GtkCellRendererText *cell, bool reference=false)
    Construct a new CellRendererText from an existing GtkCellRendererText.

Signal Handlers

- virtual void on_edited (const String &path, const String &new_text)
    Called when the user has finished editing the cell text.

## Detailed Description

A GtkCellRendererText C++ wrapper class.

## Constructor & Destructor Documentation

Inti::Gtk::CellRendererText::CellRendererText | ( | GtkCellRendererText * | cell,
|  | bool | reference = false
| ) | `[explicit, protected]`

Construct a new CellRendererText from an existing GtkCellRendererText.

Parameters:

  cell | A pointer to a GtkCellRendererText.
  reference | Set false if the initial reference count is floating, set true if it's not.

The cell can be a newly created GtkCellRendererText or an existing GtkCellRendererText. (see G::Object::Object).

Inti::Gtk::CellRendererText::CellRendererText | ( |  | ) |

| Construct a new CellRendererText. You can adjust how text is drawn using object properties. Also, with TreeViewColumn, you can bind a property to a value in a TreeModel. For example, you can bind the "text" property on the cell renderer to a string value in the model, thus rendering a different string in each row of the TreeView.

## Member Function Documentation

void Inti::Gtk::CellRendererText::set_fixed_height_from_font | ( | int | number_of_rows | ) |

Sets the height of a renderer to explicitly be determined by the "font" and the "y_pad" property set on it.

Parameters:

  number_of_rows | Number of rows of text each cell renderer is allocated, or -1

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 number_of_rows is -1, then the fixed height is unset, and the height is determined by the properties again.

The documentation for this class was generated from the following file:

- cellrenderer.h

Main Page - Footer