lib Library API Documentation

KoOasisContext Class Reference

Used during loading of Oasis format (and discarded at the end of the loading). More...

#include <kooasiscontext.h>

Collaboration diagram for KoOasisContext:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 KoOasisContext (KoDocument *doc, KoVariableCollection &varColl, KoOasisStyles &styles, KoStore *store)
KoDocumentkoDocument ()
KoVariableCollection & variableCollection ()
KoStorestore ()
KoOasisStylesoasisStyles ()
KoStyleStackstyleStack ()
const QDomDocumentmanifestDocument () const
void fillStyleStack (const QDomElement &object, const char *nsURI, const char *attrName)
void addStyles (const QDomElement *style)
KoListStyleStacklistStyleStack ()
QString currentListStyleName () const
void setCurrentListStyleName (const QString &s)
bool pushListLevelStyle (const QString &listStyleName, int level)
bool pushOutlineListLevelStyle (int level)
void setCursorPosition (KoTextParag *cursorTextParagraph, int cursorTextIndex)
KoTextParag * cursorTextParagraph () const
int cursorTextIndex () const

Detailed Description

Used during loading of Oasis format (and discarded at the end of the loading).

In addition to keeping a reference to the KoOasisStyles instance, this class also has 'state' information - a stack with the currently used styles (with its ancestors in the stack), another one with the list styles currently applicable (one item in the stack per list level).

Author:
David Faure <faure@kde.org>

Definition at line 50 of file kooasiscontext.h.


Constructor & Destructor Documentation

KoOasisContext::KoOasisContext KoDocument doc,
KoVariableCollection &  varColl,
KoOasisStyles styles,
KoStore store
 

Stores reference to the KoOasisStyles parsed by KoDocument.

Make sure that the KoOasisStyles instance outlives this KoOasisContext instance. (This is the case during loaiding, when using the KoOasisStyles given by KoDocument)

Parameters:
doc KoDocument, needed by some field variables
varColl reference to the collection that creates and stores variables (fields)
styles reference to the KoOasisStyles parsed by KoDocument
store pointer to store, if available, for e.g. loading images.

Definition at line 28 of file kooasiscontext.cc.

References KoOasisStore::loadAndParse().


Member Function Documentation

bool KoOasisContext::pushListLevelStyle const QString listStyleName,
int  level
 

Used for lists (numbered paragraphs).

Returns:
true on success (a list style was found and pushed)

Definition at line 93 of file kooasiscontext.cc.

References KoOasisStyles::listStyles().

Referenced by KoParagStyle::loadStyle(), and pushOutlineListLevelStyle().

bool KoOasisContext::pushOutlineListLevelStyle int  level  ) 
 

Used for outline levels.

Definition at line 104 of file kooasiscontext.cc.

References KoDom::namedItemNS(), KoOasisStyles::officeStyle(), and pushListLevelStyle().

Referenced by KoParagStyle::loadStyle().

void KoOasisContext::setCursorPosition KoTextParag *  cursorTextParagraph,
int  cursorTextIndex
 

Set cursor position (set by KoTextParag upon finding the processing instruction).

Definition at line 130 of file kooasiscontext.cc.


The documentation for this class was generated from the following files:
KDE Logo
This file is part of the documentation for lib Library Version 1.4.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Mon Feb 13 09:41:04 2006 by doxygen 1.4.2 written by Dimitri van Heesch, © 1997-2003