VerticalRenderer

The VerticalRenderer class manages a list of Renderers that are laid out top to bottom. More...

Publicly inherits SgmlRenderer.

Publicly inherited by Cell, FormRenderer.

Public Methods

VerticalRenderer( Canvas* canvas, SgmlParser* parser, int clipWidth=???, QObject* parent=???, const char* name=??? );
boolfindAnchor( const QString& name, int& x, int& y );
virtual boolredraw( );
voidrepaint( QPainter& p, const Rect& r );
virtual ~VerticalRenderer( );

Public Slots

virtual voidcontent( QString text );
virtual voidendOfData( );
virtual voidendTag( );
virtual voidstartTag( );
virtual voidwidthChanged( int w );

Private Data Members

int_marginLeft;
int_marginRight;
QList<ChildInfo>_renderers;
int_sgmlDepth;
SgmlRenderer*_sgmlRenderer;
TextRenderer*_textRenderer;
QString_titleString;
int_vspace;

Detailed Documentation

The VerticalRenderer class manages a list of Renderers that are laid out top to bottom.

A VerticalRenderer receives start tag, end tag, and content signals from an SgmlParser, and creates appropriate Renders to display the content. It also manages their geometry and insures that the proper amount of padding exists betweem each of its children.

Public Methods Documentation

VerticalRenderer ( Canvas* canvas, SgmlParser* parser, int clipWidth=???, QObject* parent=???, const char* name=??? );

Create a VerticalRenderer.

virtual bool redraw ( );

Reposition my children so that they do not overlap. Child widgets are laid out from top to bottom, with vertical space between them.

virtual ~VerticalRenderer ( );

This is a virtual destructor.

Public Slots Documentation

virtual void content ( QString text );

Process the content signal from the SgmlParser. Forward the content to the current text renderer. If there is no current text renderer, create one based on the current style's whitespace setting (Normal or Pre).

virtual void endOfData ( );

Forward the endOfData signal to the open child renderer, if any.

virtual void endTag ( );

Adjust the current left and right margins. If there is an open table renderer, forward the end tag to it. If the end tag is for the open table renderer, close the table renderer. Otherwise, if the end tag is for an inline element, forward it to the open text renderer, if any. If the end tag is for a block-level element, close the open text renderer, if any.

virtual void startTag ( );

Adjust the current left and right margins. If there is an open table renderer then forward the start tag to it, and return. Otherwise take the following actions, based on the display type of the start tag:

Block
Close any open text renderer.
Inline
Forward the start tag to the open text renderer, if any.
Table
Create a new table renderer.
Image
Create a new text renderer, and forward the start tag.
HLine
Create a new horizontal line renderer.
Title
Clear the title text buffer.

virtual void widthChanged ( int w );

Notify each of the child renderers of their new preferred widths.


Return to Index.
Automatically generated on Aug 11 23:32