lib Library API Documentation

KoSavingContext Class Reference

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

#include <kooasiscontext.h>

Collaboration diagram for KoSavingContext:

Collaboration graph
[legend]
List of all members.

Public Types

typedef QMap< KoParagStyle *,
QString
StyleNameMap
typedef QMap< QString, bool > FontFaces
enum  SavingMode { Store, Flat }

Public Member Functions

 KoSavingContext (KoGenStyles &mainStyles, KoVariableSettings *settings=0, bool hasColumns=false, SavingMode savingMode=Store)
KoGenStylesmainStyles ()
SavingMode savingMode () const
void setStyleNameMap (const StyleNameMap &map)
QString styleAutoName (KoParagStyle *style) const
void setCursorPosition (KoTextParag *cursorTextParagraph, int cursorTextIndex)
KoTextParag * cursorTextParagraph () const
int cursorTextIndex () const
void addFontFace (const QString &fontName)
void writeFontFaces (KoXmlWriter &writer)
bool hasColumns () const
KoVariableSettings * variableSettings () const

Detailed Description

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

Among other things, this class acts as a repository of fonts used by a document during saving, in order to create the office:font-face-decls element.

Author:
David Faure <faure@kde.org>

Definition at line 128 of file kooasiscontext.h.


Constructor & Destructor Documentation

KoSavingContext::KoSavingContext KoGenStyles mainStyles,
KoVariableSettings *  settings = 0,
bool  hasColumns = false,
SavingMode  savingMode = Store
 

Constructor.

Parameters:
mainStyles 
settings optional, used for saving the page-number in the first paragraph
hasColumns optional, used by KoParagLayout for the type of page breaks
savingMode either Store (a KoStore will be used) or Flat (all data must be inline in the XML)

Definition at line 143 of file kooasiscontext.cc.


Member Function Documentation

SavingMode KoSavingContext::savingMode  )  const [inline]
 

Returns:
the saving mode: Store (a KoStore will be used) or Flat (all data must be inline in the XML)

Definition at line 146 of file kooasiscontext.h.

void KoSavingContext::setStyleNameMap const StyleNameMap map  )  [inline]
 

Called after saving the user styles.

Associates every KoParagStyle with its automatic name (style:name attribute)

Definition at line 152 of file kooasiscontext.h.

QString KoSavingContext::styleAutoName KoParagStyle style  )  const [inline]
 

Returns:
the automatic name for a KoParagStyle

Definition at line 155 of file kooasiscontext.h.

void KoSavingContext::setCursorPosition KoTextParag *  cursorTextParagraph,
int  cursorTextIndex
 

Set cursor position (so that KoTextParag can insert a processing instruction).

Definition at line 157 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:18 2006 by doxygen 1.4.2 written by Dimitri van Heesch, © 1997-2003