Class: Gtk::CellRenderer
- Inherits:
-
Object
- Object
- Gtk::CellRenderer
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#accessible_type=(type) ⇒ nil
Sets the type to be used for creating accessibles for cells rendered by cell renderers of renderer_class.
-
#activate(event, widget, path, background_area, cell_area, flags) ⇒ TrueClass
Passes an activate event to the cell renderer for possible processing.
-
#cell_background=(cell_background) ⇒ String
Cell-background.
-
#cell_background_gdk ⇒ Gdk::Color
Cell background as a Gdk::Color.
-
#cell_background_gdk=(cell_background_gdk) ⇒ Gdk::Color
Cell background as a Gdk::Color.
-
#cell_background_rgba ⇒ Gdk::RGBA
Cell background as a Gdk::RGBA.
-
#cell_background_rgba=(cell_background_rgba) ⇒ Gdk::RGBA
Cell background as a Gdk::RGBA.
- #cell_background_set=(cell_background_set) ⇒ TrueClass
-
#cell_background_set? ⇒ TrueClass
Cell-background-set.
- #editing=(editing) ⇒ TrueClass
-
#editing? ⇒ TrueClass
Editing.
-
#get_aligned_area(widget, flags, cell_area, aligned_area) ⇒ nil
Gets the aligned area used by cell inside cell_area.
-
#get_alignment(xalign, yalign) ⇒ nil
Fills in xalign and yalign with the appropriate values of cell.
-
#get_fixed_size(width, height) ⇒ nil
Fills in width and height with the appropriate size of cell.
-
#get_padding(xpad, ypad) ⇒ nil
Fills in xpad and ypad with the appropriate values of cell.
-
#get_preferred_height(widget, minimum_size, natural_size) ⇒ nil
Retreives a renderer’s natural size when rendered to widget.
-
#get_preferred_height_for_width(widget, width, minimum_height, natural_height) ⇒ nil
Retreives a cell renderers’s minimum and natural height if it were rendered to widget with the specified width.
-
#get_preferred_size(widget, minimum_size, natural_size) ⇒ nil
Retrieves the minimum and natural size of a cell taking into account the widget’s preference for height-for-width management.
-
#get_preferred_width(widget, minimum_size, natural_size) ⇒ nil
Retreives a renderer’s natural size when rendered to widget.
-
#get_preferred_width_for_height(widget, height, minimum_width, natural_width) ⇒ nil
Retreives a cell renderers’s minimum and natural width if it were rendered to widget with the specified height.
-
#get_size(widget, cell_area, x_offset, y_offset, width, height) ⇒ nil
Obtains the width and height needed to render the cell.
-
#get_state(widget, cell_state) ⇒ Gtk::StateFlags
Translates the cell renderer state to Gtk::StateFlags, based on the cell renderer and widget sensitivity, and the given Gtk::CellRendererState.
-
#height ⇒ Integer
Height.
- #height=(height) ⇒ Integer
-
#is_activatable ⇒ TrueClass
Checks whether the cell renderer can do something when activated.
- #is_expanded=(is_expanded) ⇒ TrueClass
-
#is_expanded? ⇒ TrueClass
Is-expanded.
- #is_expander=(is_expander) ⇒ TrueClass
-
#is_expander? ⇒ TrueClass
Is-expander.
-
#mode ⇒ Gtk::CellRendererMode
Mode.
- #mode=(mode) ⇒ Gtk::CellRendererMode
-
#render(cr, widget, background_area, cell_area, flags) ⇒ nil
Invokes the virtual render function of the Gtk::CellRenderer.
-
#request_mode ⇒ Gtk::SizeRequestMode
Gets whether the cell renderer prefers a height-for-width layout or a width-for-height layout.
-
#sensitive ⇒ TrueClass
Returns the cell renderer’s sensitivity.
- #sensitive=(sensitive) ⇒ TrueClass
-
#sensitive? ⇒ TrueClass
Sensitive.
-
#set_alignment(xalign, yalign) ⇒ nil
Sets the renderer’s alignment within its available space.
-
#set_fixed_size(width, height) ⇒ nil
Sets the renderer size to be explicit, independent of the properties set.
-
#set_padding(xpad, ypad) ⇒ nil
Sets the renderer’s padding.
-
#start_editing(event, widget, path, background_area, cell_area, flags) ⇒ Gtk::CellEditable
Starts editing the contents of this cell, through a new Gtk::CellEditable widget created by the Gtk::CellRendererClass.start_editing virtual function.
-
#stop_editing(canceled) ⇒ nil
Informs the cell renderer that the editing is stopped.
-
#visible ⇒ TrueClass
Returns the cell renderer’s visibility.
- #visible=(visible) ⇒ TrueClass
-
#visible? ⇒ TrueClass
Visible.
-
#width ⇒ Integer
Width.
- #width=(width) ⇒ Integer
-
#xalign ⇒ Gtk::gfloat
Xalign.
- #xalign=(xalign) ⇒ Gtk::gfloat
-
#xpad ⇒ Integer
Xpad.
- #xpad=(xpad) ⇒ Integer
-
#yalign ⇒ Gtk::gfloat
Yalign.
- #yalign=(yalign) ⇒ Gtk::gfloat
-
#ypad ⇒ Integer
Ypad.
- #ypad=(ypad) ⇒ Integer
Instance Method Details
#accessible_type=(type) ⇒ nil
Sets the type to be used for creating accessibles for cells rendered by cell renderers of renderer_class. Note that multiple accessibles will be created.
This function should only be called from class init functions of cell renderers.
#activate(event, widget, path, background_area, cell_area, flags) ⇒ TrueClass
Passes an activate event to the cell renderer for possible processing. Some cell renderers may use events; for example, Gtk::CellRendererToggle toggles when it gets a mouse click.
#cell_background=(cell_background) ⇒ String
Returns cell-background.
#cell_background_gdk ⇒ Gdk::Color
Cell background as a Gdk::Color
#cell_background_gdk=(cell_background_gdk) ⇒ Gdk::Color
Cell background as a Gdk::Color
#cell_background_rgba ⇒ Gdk::RGBA
Cell background as a Gdk::RGBA
#cell_background_rgba=(cell_background_rgba) ⇒ Gdk::RGBA
Cell background as a Gdk::RGBA
#cell_background_set=(cell_background_set) ⇒ TrueClass
#cell_background_set? ⇒ TrueClass
Returns cell-background-set.
#editing=(editing) ⇒ TrueClass
#editing? ⇒ TrueClass
Returns editing.
#get_aligned_area(widget, flags, cell_area, aligned_area) ⇒ nil
Gets the aligned area used by cell inside cell_area. Used for finding the appropriate edit and focus rectangle.
#get_alignment(xalign, yalign) ⇒ nil
Fills in xalign and yalign with the appropriate values of cell.
#get_fixed_size(width, height) ⇒ nil
Fills in width and height with the appropriate size of cell.
#get_padding(xpad, ypad) ⇒ nil
Fills in xpad and ypad with the appropriate values of cell.
#get_preferred_height(widget, minimum_size, natural_size) ⇒ nil
Retreives a renderer’s natural size when rendered to widget.
#get_preferred_height_for_width(widget, width, minimum_height, natural_height) ⇒ nil
Retreives a cell renderers’s minimum and natural height if it were rendered to widget with the specified width.
#get_preferred_size(widget, minimum_size, natural_size) ⇒ nil
Retrieves the minimum and natural size of a cell taking into account the widget’s preference for height-for-width management.
#get_preferred_width(widget, minimum_size, natural_size) ⇒ nil
Retreives a renderer’s natural size when rendered to widget.
#get_preferred_width_for_height(widget, height, minimum_width, natural_width) ⇒ nil
Retreives a cell renderers’s minimum and natural width if it were rendered to widget with the specified height.
#get_size(widget, cell_area, x_offset, y_offset, width, height) ⇒ nil
Obtains the width and height needed to render the cell. Used by view widgets to determine the appropriate size for the cell_area passed to gtk_cell_renderer_render(). If cell_area is not nil, fills in the x and y offsets (if set) of the cell relative to this location.
Please note that the values set in width and height, as well as those in x_offset and y_offset are inclusive of the xpad and ypad properties.
#get_state(widget, cell_state) ⇒ Gtk::StateFlags
Translates the cell renderer state to Gtk::StateFlags, based on the cell renderer and widget sensitivity, and the given Gtk::CellRendererState.
#height ⇒ Integer
Returns height.
#height=(height) ⇒ Integer
#is_activatable ⇒ TrueClass
Checks whether the cell renderer can do something when activated.
#is_expanded=(is_expanded) ⇒ TrueClass
#is_expanded? ⇒ TrueClass
Returns is-expanded.
#is_expander=(is_expander) ⇒ TrueClass
#is_expander? ⇒ TrueClass
Returns is-expander.
#mode ⇒ Gtk::CellRendererMode
Returns mode.
#mode=(mode) ⇒ Gtk::CellRendererMode
#render(cr, widget, background_area, cell_area, flags) ⇒ nil
Invokes the virtual render function of the Gtk::CellRenderer. The three passed-in rectangles are areas in cr. Most renderers will draw within cell_area; the xalign, yalign, xpad, and ypad fields of the Gtk::CellRenderer should be honored with respect to cell_area. background_area includes the blank space around the cell, and also the area containing the tree expander; so the background_area rectangles for all cells tile to cover the entire window.
#request_mode ⇒ Gtk::SizeRequestMode
Gets whether the cell renderer prefers a height-for-width layout or a width-for-height layout.
#sensitive ⇒ TrueClass
Returns the cell renderer’s sensitivity.
#sensitive=(sensitive) ⇒ TrueClass
#sensitive? ⇒ TrueClass
Returns sensitive.
#set_alignment(xalign, yalign) ⇒ nil
Sets the renderer’s alignment within its available space.
#set_fixed_size(width, height) ⇒ nil
Sets the renderer size to be explicit, independent of the properties set.
#set_padding(xpad, ypad) ⇒ nil
Sets the renderer’s padding.
#start_editing(event, widget, path, background_area, cell_area, flags) ⇒ Gtk::CellEditable
Starts editing the contents of this cell, through a new Gtk::CellEditable widget created by the Gtk::CellRendererClass.start_editing virtual function.
#stop_editing(canceled) ⇒ nil
Informs the cell renderer that the editing is stopped. If canceled is true, the cell renderer will emit the Gtk::CellRenderer::editing-canceled signal.
This function should be called by cell renderer implementations in response to the Gtk::CellEditable::editing-done signal of Gtk::CellEditable.
#visible ⇒ TrueClass
Returns the cell renderer’s visibility.
#visible=(visible) ⇒ TrueClass
#visible? ⇒ TrueClass
Returns visible.
#width ⇒ Integer
Returns width.
#width=(width) ⇒ Integer
#xalign ⇒ Gtk::gfloat
Returns xalign.
#xalign=(xalign) ⇒ Gtk::gfloat
#xpad ⇒ Integer
Returns xpad.
#xpad=(xpad) ⇒ Integer
#yalign ⇒ Gtk::gfloat
Returns yalign.
#yalign=(yalign) ⇒ Gtk::gfloat
#ypad ⇒ Integer
Returns ypad.