pango-Layout-Objects {RGtk2} | R Documentation |
High-level layout driver objects
pangoLayoutNew(context)
pangoLayoutCopy(object)
pangoLayoutGetContext(object)
pangoLayoutContextChanged(object)
pangoLayoutSetText(object, text, length = -1)
pangoLayoutGetText(object)
pangoLayoutSetMarkup(object, markup, length = -1)
pangoLayoutSetMarkupWithAccel(object, markup, accel.marker)
pangoLayoutSetAttributes(object, attrs)
pangoLayoutGetAttributes(object)
pangoLayoutSetFontDescription(object, desc = NULL)
pangoLayoutGetFontDescription(object)
pangoLayoutSetWidth(object, width)
pangoLayoutGetWidth(object)
pangoLayoutSetWrap(object, wrap)
pangoLayoutGetWrap(object)
pangoLayoutIsWrapped(object)
pangoLayoutSetEllipsize(object, ellipsize)
pangoLayoutGetEllipsize(object)
pangoLayoutIsEllipsized(object)
pangoLayoutSetIndent(object, indent)
pangoLayoutGetIndent(object)
pangoLayoutGetSpacing(object)
pangoLayoutSetSpacing(object, spacing)
pangoLayoutSetJustify(object, justify)
pangoLayoutGetJustify(object)
pangoLayoutSetAutoDir(object, auto.dir)
pangoLayoutGetAutoDir(object)
pangoLayoutSetAlignment(object, alignment)
pangoLayoutGetAlignment(object)
pangoLayoutSetTabs(object, tabs = NULL)
pangoLayoutGetTabs(object)
pangoLayoutSetSingleParagraphMode(object, setting)
pangoLayoutGetSingleParagraphMode(object)
pangoLayoutGetUnknownGlyphsCount(object)
pangoLayoutGetLogAttrs(object)
pangoLayoutIndexToPos(object, index, pos)
pangoLayoutIndexToLineX(object, index., trailing)
pangoLayoutXyToIndex(object, x, y)
pangoLayoutGetCursorPos(object, index)
pangoLayoutMoveCursorVisually(object, strong, old.index, old.trailing, direction)
pangoLayoutGetExtents(object)
pangoLayoutGetPixelExtents(object)
pangoLayoutGetSize(object)
pangoLayoutGetPixelSize(object)
pangoLayoutGetLineCount(object)
pangoLayoutGetLine(object, line)
pangoLayoutGetLineReadonly(object, line)
pangoLayoutGetLines(object)
pangoLayoutGetLinesReadonly(object)
pangoLayoutGetIter(object)
pangoLayoutIterNextRun(object)
pangoLayoutIterNextChar(object)
pangoLayoutIterNextCluster(object)
pangoLayoutIterNextLine(object)
pangoLayoutIterAtLastLine(object)
pangoLayoutIterGetIndex(object)
pangoLayoutIterGetBaseline(object)
pangoLayoutIterGetRun(object)
pangoLayoutIterGetRunReadonly(object)
pangoLayoutIterGetLine(object)
pangoLayoutIterGetLineReadonly(object)
pangoLayoutIterGetCharExtents(object)
pangoLayoutIterGetClusterExtents(object)
pangoLayoutIterGetRunExtents(object)
pangoLayoutIterGetLineYrange(object)
pangoLayoutIterGetLineExtents(object)
pangoLayoutIterGetLayoutExtents(object)
pangoLayoutLineGetExtents(object)
pangoLayoutLineGetPixelExtents(object)
pangoLayoutLineIndexToX(object, index, trailing)
pangoLayoutLineXToIndex(object, x.pos)
pangoLayoutLineGetXRanges(object, start.index, end.index)
pangoLayout(context)
While complete access to the layout capabilities of Pango is provided using the detailed interfaces for itemization and shaping, using that functionality directly involves writing a fairly large amount of code. The objects and functions in this section provide a high-level driver for formatting entire paragraphs of text at once.
PangoLayout
PangoLayout
structure represents and entire paragraph
of text. It is initialized with a PangoContext
, UTF-8 string
and set of attributes for that string. Once that is done, the
set of formatted lines can be extracted from the object,
the layout can be rendered, and conversion between logical
character positions within the layout's text, and the physical
position of the resulting glyphs can be made.
There are also a number of parameters to adjust the formatting
of a PangoLayout
, which are illustrated in .
It is possible, as well, to ignore the 2-D setup, and simply
treat the results of a PangoLayout
as a list of lines.
The PangoLayout
structure is opaque, and has no user-visible
fields.
PangoLayoutIter
PangoLayoutIter
structure can be used to
iterate over the visual extents of a PangoLayout
.
The PangoLayoutIter
structure is opaque, and
has no user-visible fields.
PangoLayoutLine
PangoLayoutLine
structure represents one of the lines resulting
from laying out a paragraph via PangoLayout
. PangoLayoutLine
structures are obtained by calling pangoLayoutGetLine
and
are only valid until the text, attributes, or settings of the
parent PangoLayout
are modified.
Routines for rendering PangoLayout objects are provided in code specific to each rendering system.
layout
PangoLayout
] the parent layout for this linestartIndex
layout->text
length
runs
isParagraphStart
TRUE
if this is the first line of the paragraphresolvedDir
PangoDirection
of the line
pangoLayout
is the equivalent of pangoLayoutNew
.
PangoWrapMode
PangoWrapMode
describes how to wrap the lines of a PangoLayout
to the desired width.
word
char
PangoEllipsizeMode
PangoEllipsizeMode
type describes what sort of (if any)
ellipsization should be applied to a line of text. In
the ellipsization process characters are removed from the
text in order to make it fit to a given width and replaced
with an ellipsis.
none
start
middle
end
PangoAlignment
PangoAlignment
describes how to align the lines of a PangoLayout
within the
available space. If the PangoLayout
is set to justify
using pangoLayoutSetJustify
, this only has effect for partial lines.
left
center
right
Derived by RGtkGen from GTK+ documentation
http://developer.gnome.org/doc/API/2.0/pango/pango-Layout-Objects.html