Scribus Developer Documentation - API
logo-pen

Scribus Developer Documentation - API

StyleReader Class Reference

#include <stylereader.h>

Collaboration diagram for StyleReader:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 StyleReader (QString documentName, gtWriter *wr, bool textOnly, bool prefix, bool combineStyles=true)
 ~StyleReader ()
bool updateStyle (gtStyle *style, gtStyle *parent2Style, const QString &key, const QString &value)
bool startElement (const QString &, const QString &, const QString &name, const QXmlAttributes &attrs)
bool endElement (const QString &, const QString &, const QString &name)
void parse (QString fileName)
gtStylegetDefaultStyle (void)
gtStylegetStyle (const QString &name)
void setStyle (const QString &name, gtStyle *style)
QString getFont (const QString &key)
ListStylegetList (const QString &name)

Static Public Member Functions

static void startElement (void *user_data, const xmlChar *fullname, const xmlChar **atts)
static void endElement (void *user_data, const xmlChar *name)

Private Member Functions

double getSize (QString s, double parentSize=-1)
void styleProperties (const QXmlAttributes &attrs)
void defaultStyle (const QXmlAttributes &attrs)
void styleStyle (const QXmlAttributes &attrs)
void tabStop (const QXmlAttributes &attrs)
void setupFrameStyle ()

Private Attributes

gtWriterwriter
bool importTextOnly
bool usePrefix
bool packStyles
bool readProperties
QString docname
StyleMap styles
StyleMap listParents
StyleMap attrsStyles
CounterMap pstyleCounts
FontMap fonts
ListMap lists
gtStylecurrentStyle
gtStyleparentStyle
bool inList
QString currentList
ListStylecurrentListStyle
bool defaultStyleCreated

Static Private Attributes

static StyleReadersreader = NULL


Detailed Description

Definition at line 120 of file odtim/stylereader.h.


Constructor & Destructor Documentation

StyleReader::StyleReader ( QString  documentName,
gtWriter wr,
bool  textOnly,
bool  prefix,
bool  combineStyles = true 
)

StyleReader::~StyleReader (  ) 

Definition at line 816 of file odtim/stylereader.cpp.

References sreader, and styles.


Member Function Documentation

double StyleReader::getSize ( QString  s,
double  parentSize = -1 
) [private]

Definition at line 763 of file odtim/stylereader.cpp.

References gtMeasure::d2d(), SC_C, SC_IN, SC_MM, SC_P, and SC_PT.

Referenced by styleProperties(), tabStop(), and updateStyle().

void StyleReader::styleProperties ( const QXmlAttributes &  attrs  )  [private]

void StyleReader::defaultStyle ( const QXmlAttributes &  attrs  )  [private]

void StyleReader::styleStyle ( const QXmlAttributes &  attrs  )  [private]

void StyleReader::tabStop ( const QXmlAttributes &  attrs  )  [private]

void StyleReader::setupFrameStyle (  )  [private]

bool StyleReader::updateStyle ( gtStyle style,
gtStyle parent2Style,
const QString &  key,
const QString &  value 
)

void StyleReader::startElement ( void *  user_data,
const xmlChar *  fullname,
const xmlChar **  atts 
) [static]

Definition at line 870 of file odtim/stylereader.cpp.

References sreader, and startElement().

Referenced by startElement().

void StyleReader::endElement ( void *  user_data,
const xmlChar *  name 
) [static]

Definition at line 883 of file odtim/stylereader.cpp.

References endElement(), and sreader.

Referenced by endElement().

bool StyleReader::startElement ( const QString &  ,
const QString &  ,
const QString &  name,
const QXmlAttributes &  attrs 
)

bool StyleReader::endElement ( const QString &  ,
const QString &  ,
const QString &  name 
)

void StyleReader::parse ( QString  fileName  ) 

Definition at line 519 of file odtim/stylereader.cpp.

References sSAXHandler.

Referenced by OdtIm::OdtIm(), and ContentReader::parse().

gtStyle * StyleReader::getDefaultStyle ( void   ) 

gtStyle * StyleReader::getStyle ( const QString &  name  ) 

void StyleReader::setStyle ( const QString &  name,
gtStyle style 
)

QString StyleReader::getFont ( const QString &  key  ) 

Definition at line 612 of file odtim/stylereader.cpp.

References fonts.

Referenced by styleProperties(), and updateStyle().

ListStyle * StyleReader::getList ( const QString &  name  ) 

Definition at line 642 of file odtim/stylereader.cpp.

References lists.

Referenced by ContentReader::endElement(), and ContentReader::startElement().


Member Data Documentation

StyleReader * StyleReader::sreader = NULL [static, private]

Definition at line 123 of file odtim/stylereader.h.

Referenced by endElement(), startElement(), StyleReader(), and ~StyleReader().

Definition at line 125 of file odtim/stylereader.h.

Referenced by setupFrameStyle(), and StyleReader().

bool StyleReader::usePrefix [private]

Definition at line 126 of file odtim/stylereader.h.

Referenced by getStyle(), setStyle(), and StyleReader().

bool StyleReader::packStyles [private]

Definition at line 127 of file odtim/stylereader.h.

Referenced by setStyle(), and StyleReader().

QString StyleReader::docname [private]

Definition at line 129 of file odtim/stylereader.h.

Referenced by getStyle(), setStyle(), and StyleReader().

Definition at line 131 of file odtim/stylereader.h.

Referenced by startElement(), and styleStyle().

Definition at line 132 of file odtim/stylereader.h.

Referenced by setStyle(), and setupFrameStyle().

Definition at line 133 of file odtim/stylereader.h.

Referenced by setStyle(), and setupFrameStyle().

Definition at line 134 of file odtim/stylereader.h.

Referenced by getFont(), and startElement().

Definition at line 135 of file odtim/stylereader.h.

Referenced by endElement(), and getList().

Definition at line 137 of file odtim/stylereader.h.

Referenced by endElement(), styleProperties(), StyleReader(), and styleStyle().

bool StyleReader::inList [private]

QString StyleReader::currentList [private]

Definition at line 139 of file odtim/stylereader.h.

Referenced by startElement(), and StyleReader().

Definition at line 140 of file odtim/stylereader.h.

Referenced by endElement(), startElement(), and StyleReader().

Definition at line 141 of file odtim/stylereader.h.

Referenced by defaultStyle(), StyleReader(), and styleStyle().


The documentation for this class was generated from the following files:
Created with personalized Doxygen. This is documentation for GPL software Scribus - Open Source Desktop Publishing.