Class parbox is
the central class of the document rendering primitives of
XPCE. These classes are used to visualise a mixture of text and
graphics. They realise the common document rendering primitives such as
paragraphs, embedded graphics, list-making environments, tables, etc.
Below is a brief summary of these classes:
floating objects:
placed at the left or right margin with the text floating around the
graphical.
list. A list is a set of list items,
each of which consists of a label and a body. Class lbox
defines the layout of these items. It can be used to create
bullet-lists, definition lists, etc.
Two classes support the above:
->compute
has filled a line, this attribute defines the placements of the hbox
objects in the physical line. The meaning of left, right
and center are obvious. The value justtify
implies a straight right and left margin.<-line_width
and the width of the content.
Auto cropping is used mostly for defining table-cells, where the natural width of the cell is (initially) determined by the content.
If parbox->geometry
is invoked with an explicit width, parbox<-auto_crop
is automatically set to @off,
trying to fullfil the requested width as closely as possible.
->compute
has filled a line, this attribute defines the placements of the hbox
objects in the physical line. The meaning of left, right
and center are obvious. The value justtify
implies a straight right and left margin.
Inherits description from: parbox-alignment
->cdata.-auto_cropcharacter data.
If ignore_blanks is leading, first all leading blank
characters are skipped. Words encountered in the string are added as
instances of the class tbox
using the specified style. Sequences of spaces, tabs and newlines are
mapped to a single hbox
object. If the space argument is provided, this is used for
representing these spaces, otherwise a default stretchable hbox
object is created with the dimensions of a space in the current font.
See also parbox->append, tbox->initialise
and class hbox.
<-height
of a parbox is always defined by the parbox<-line_width
and the content. If width is specified, the parbox changes
its
parbox<-line_width trying to fullfil the
requested width. It will then adjust the graphical<-width
and graphical<-height
accordingly.
Specifying an explicit graphical<-width
sets parbox<-auto_crop
to @off.
<-line_width and
parbox<-alignment.->geometry
of the parbox is changed.
If the parbox->line_width
is changed, the parbox will sent the message
graphical->container_size_changed
to each embedded graphical
object. This mechanism allows for defining the width of a graphical in
terms of the width of the paragraph.
@receiver: Considered parbox @arg1 Considered hbox @arg2 Index of @arg2 in @receiver
On success, a tuple object containing the parbox and index of the hbox are returned.
Typically, this method is used to locate anchors. Class hbox
is therefore subclassed and decorated with identifying information for
the anchor. parbox<-find
is then used to locate an instance with the desired property of the
anchor class.
See also parbox<-box_area.
<-width of largest hbox
object in paragraph. It is not desirable to make the paragraph smaller
(see parbox->line_width)
than this size.
Introduced to support the compuation of column widths in table objects whose cells are filled with parbox objects.