SgmlRenderer

The SgmlRenderer class is the base class for any renderer that takes input from an SgmlParser. More...

Publicly inherits Renderer.

Publicly inherited by TableRenderer, TextRenderer, VerticalRenderer.

Public Methods

SgmlRenderer( Canvas* canvas, SgmlParser* parser, int clipWidth=???, QObject* parent=???, const char* name=??? );
virtual boolfindAnchor( const QString& name, int& x, int& y );
SgmlParser*parser( );
Style*style( );
const QList<Style>&styleStack( );
STag*tag( );
const QList<STag>&tagStack( );
virtual ~SgmlRenderer( );

Public Slots

virtual voidcontent( QString text );
virtual voidendOfData( );
virtual voidendTag( );
virtual voidstartTag( );

Private Data Members

SgmlParser*_parser;

Detailed Documentation

The SgmlRenderer class is the base class for any renderer that takes input from an SgmlParser.

This class processes start and end tag signals from the SgmlParser, and maintains a tag path, tag stack, style sheet, and current style. The tag path is the concatenation of all open tags for the current document instance. the tag stack keeps track of each open tags associated attributes. The style sheet is associated with the type of document being parsed. The style is the current style for the tag path, taking into account inheritance of styles from parent elements in the document instance.

Public Methods Documentation

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

Create a new SgmlRender. An SgmlRenderer takes two additional parameters, tagPath and styleSheet. The tagPath is the concatenation of all open tags at the time the SgmlRenderer was created. The styleSheet is a pointer to the list of styles associated with the current document type. The style sheet determines how the content is rendered.

virtual ~SgmlRenderer ( );

This is a virtual destructor that does nothing.

Public Slots Documentation

virtual void content ( QString text );

Process a content signal from the SgmlParser. All subclasses must reimplement this function.

virtual void endOfData ( );

Process the endOfData signal from the SgmlParser. All subclasses must reimplement this.


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