Renderer
Object Hierarchy:
Pango.Renderer
Pango.Renderer
Pango.Renderer
GLib.Object
GLib.Object
GLib.Object->Pango.Renderer
Description:
[
CCode ( type_id =
"pango_renderer_get_type ()" ) ]
[
Version ( since =
"1.8" ) ]
public abstract class Renderer :
Object
`PangoRenderer` is a base class for objects that can render text provided as `PangoGlyphString` or `PangoLayout`.
By subclassing `PangoRenderer` and overriding operations such as draw_glyphs
and draw_rectangle
, renderers for
particular font backends and destinations can be created.
Content:
Creation methods:
Methods:
public void activate ()
Does initial setup before rendering operations on
this .
public virtual void begin ()
public void deactivate ()
Cleans up after rendering operations on this
.
public virtual void draw_error_underline (int x, int y, int width, int height)
Draw a squiggly line that approximately covers the given rectangle in the
style of an underline used to indicate a spelling error.
public virtual void draw_glyph (Font font, Glyph glyph, double x, double y)
Draws a single glyph with coordinates in device space.
public virtual void draw_glyph_item (string ? text, GlyphItem glyph_item, int x, int y)
Draws the glyphs in glyph_item
with the specified
`PangoRenderer`, embedding the text associated with the glyphs in the output if the output format supports it.
public virtual void draw_glyphs (Font font, GlyphString glyphs, int x, int y)
Draws the glyphs in glyphs
with the specified `PangoRenderer`.
public void draw_layout (Layout layout, int x, int y)
Draws layout
with the specified `PangoRenderer`.
public void draw_layout_line (LayoutLine line, int x, int y)
Draws line
with the specified `PangoRenderer`.
public virtual void draw_rectangle (RenderPart part, int x, int y, int width, int height)
Draws an axis-aligned rectangle in user space coordinates with the specified
`PangoRenderer`.
public virtual void draw_shape (AttrShape attr, int x, int y)
public virtual void draw_trapezoid (RenderPart part, double y1_, double x11, double x21, double y2, double x12, double x22)
Draws a trapezoid with the parallel sides aligned with the X axis using the
given `PangoRenderer`; coordinates are in device space.
public virtual void end ()
public uint16 get_alpha (RenderPart part)
Gets the current alpha for the specified part.
public unowned Color ? get_color (RenderPart part)
Gets the current rendering color for the specified part.
public unowned Layout ? get_layout ()
Gets the layout currently being rendered using
this .
public unowned LayoutLine ? get_layout_line ()
Gets the layout line currently being rendered using
this .
public unowned Matrix ? get_matrix ()
Gets the transformation matrix that will be applied when rendering.
public virtual void part_changed (RenderPart part)
Informs Pango that the way that the rendering is done for part
has changed.
public virtual void prepare_run (LayoutRun run)
public void set_alpha (RenderPart part, uint16 alpha)
Sets the alpha for part of the rendering.
public void set_color (RenderPart part, Color ? color)
Sets the color for part of the rendering.
public void set_matrix (Matrix ? matrix)
Sets the transformation matrix that will be applied when rendering.
Inherited Members:
All known members inherited from class GLib.Object