libmspub::MSPUBParser Class Reference

#include <MSPUBParser.h>

Inheritance diagram for libmspub::MSPUBParser:
libmspub::MSPUBParser2k libmspub::MSPUBParser97

Classes

struct  TextParagraphReference
struct  TextSpanReference

Public Member Functions

 MSPUBParser (librevenge::RVNGInputStream *input, MSPUBCollector *collector)
virtual ~MSPUBParser ()
virtual bool parse ()

Protected Types

typedef std::vector< ContentChunkReference >::const_iterator ccr_iterator_t

Protected Member Functions

virtual unsigned getColorIndexByQuillEntry (unsigned entry)
 MSPUBParser ()
 MSPUBParser (const MSPUBParser &)
MSPUBParseroperator= (const MSPUBParser &)
virtual bool parseContents (librevenge::RVNGInputStream *input)
bool parseMetaData ()
bool parseQuill (librevenge::RVNGInputStream *input)
bool parseEscher (librevenge::RVNGInputStream *input)
bool parseEscherDelay (librevenge::RVNGInputStream *input)
MSPUBBlockInfo parseBlock (librevenge::RVNGInputStream *input, bool skipHierarchicalData=false)
EscherContainerInfo parseEscherContainer (librevenge::RVNGInputStream *input)
bool parseContentChunkReference (librevenge::RVNGInputStream *input, MSPUBBlockInfo block)
QuillChunkReference parseQuillChunkReference (librevenge::RVNGInputStream *input)
bool parseDocumentChunk (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
bool parsePageChunk (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
bool parsePaletteChunk (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
bool parsePageShapeList (librevenge::RVNGInputStream *input, MSPUBBlockInfo block, unsigned pageSeqNum)
bool parseShape (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
bool parseBorderArtChunk (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
bool parseFontChunk (librevenge::RVNGInputStream *input, const ContentChunkReference &chunk)
void parsePaletteEntry (librevenge::RVNGInputStream *input, MSPUBBlockInfo block)
void parseColors (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
void parseFonts (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
void parseDefaultStyle (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
void parseShapeGroup (librevenge::RVNGInputStream *input, const EscherContainerInfo &spgr, Coordinate parentCoordinateSystem, Coordinate parentGroupAbsoluteCoord)
void skipBlock (librevenge::RVNGInputStream *input, MSPUBBlockInfo block)
void parseEscherShape (librevenge::RVNGInputStream *input, const EscherContainerInfo &sp, Coordinate &parentCoordinateSystem, Coordinate &parentGroupAbsoluteCoord)
bool findEscherContainer (librevenge::RVNGInputStream *input, const EscherContainerInfo &parent, EscherContainerInfo &out, unsigned short type)
bool findEscherContainerWithTypeInSet (librevenge::RVNGInputStream *input, const EscherContainerInfo &parent, EscherContainerInfo &out, std::set< unsigned short > types)
std::map< unsigned short, unsigned > extractEscherValues (librevenge::RVNGInputStream *input, const EscherContainerInfo &record)
FOPTValues extractFOPTValues (librevenge::RVNGInputStream *input, const libmspub::EscherContainerInfo &record)
std::vector< TextSpanReferenceparseCharacterStyles (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
std::vector< TextParagraphReferenceparseParagraphStyles (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
std::vector< CalculationparseGuides (const std::vector< unsigned char > &guideData)
std::vector< VertexparseVertices (const std::vector< unsigned char > &vertexData)
std::vector< unsigned > parseTableCellDefinitions (librevenge::RVNGInputStream *input, const QuillChunkReference &chunk)
std::vector< unsigned short > parseSegments (const std::vector< unsigned char > &segmentData)
DynamicCustomShape getDynamicCustomShape (const std::vector< unsigned char > &vertexData, const std::vector< unsigned char > &segmentData, const std::vector< unsigned char > &guideData, unsigned geoWidth, unsigned geoHeight)
int getColorIndex (librevenge::RVNGInputStream *input, const MSPUBBlockInfo &info)
unsigned getFontIndex (librevenge::RVNGInputStream *input, const MSPUBBlockInfo &info)
CharacterStyle getCharacterStyle (librevenge::RVNGInputStream *input)
ParagraphStyle getParagraphStyle (librevenge::RVNGInputStream *input)
std::shared_ptr< FillgetNewFill (const std::map< unsigned short, unsigned > &foptProperties, bool &skipIfNotBg, std::map< unsigned short, std::vector< unsigned char > > &foptValues)

Static Protected Member Functions

static short getBlockDataLength (unsigned type)
static bool isBlockDataString (unsigned type)
static PageType getPageTypeBySeqNum (unsigned seqNum)
static unsigned getEscherElementTailLength (unsigned short type)
static unsigned getEscherElementAdditionalHeaderLength (unsigned short type)
static ImgType imgTypeByBlipType (unsigned short type)
static int getStartOffset (ImgType type, unsigned short initial)
static bool lineExistsByFlagPointer (unsigned *flags, unsigned *geomFlags=nullptr)

Protected Attributes

librevenge::RVNGInputStream * m_input
unsigned m_length
MSPUBCollectorm_collector
std::vector< MSPUBBlockInfom_blockInfo
std::vector< ContentChunkReferencem_contentChunks
std::vector< unsigned > m_cellsChunkIndices
std::vector< unsigned > m_pageChunkIndices
std::vector< unsigned > m_shapeChunkIndices
std::vector< unsigned > m_paletteChunkIndices
std::vector< unsigned > m_borderArtChunkIndices
std::vector< unsigned > m_fontChunkIndices
std::vector< unsigned > m_unknownChunkIndices
boost::optional< unsigned > m_documentChunkIndex
int m_lastSeenSeqNum
unsigned m_lastAddedImage
std::vector< int > m_alternateShapeSeqNums
std::vector< int > m_escherDelayIndices

Member Typedef Documentation

◆ ccr_iterator_t

typedef std::vector<ContentChunkReference>::const_iterator libmspub::MSPUBParser::ccr_iterator_t
protected

Constructor & Destructor Documentation

◆ MSPUBParser() [1/3]

libmspub::MSPUBParser::MSPUBParser ( librevenge::RVNGInputStream * input,
MSPUBCollector * collector )
explicit

◆ ~MSPUBParser()

libmspub::MSPUBParser::~MSPUBParser ( )
virtual

◆ MSPUBParser() [2/3]

libmspub::MSPUBParser::MSPUBParser ( )
protected

◆ MSPUBParser() [3/3]

libmspub::MSPUBParser::MSPUBParser ( const MSPUBParser & )
protected

Member Function Documentation

◆ extractEscherValues()

std::map< unsigned short, unsigned > libmspub::MSPUBParser::extractEscherValues ( librevenge::RVNGInputStream * input,
const EscherContainerInfo & record )
protected

Referenced by parseEscherShape().

◆ extractFOPTValues()

FOPTValues libmspub::MSPUBParser::extractFOPTValues ( librevenge::RVNGInputStream * input,
const libmspub::EscherContainerInfo & record )
protected

Referenced by parseEscherShape().

◆ findEscherContainer()

bool libmspub::MSPUBParser::findEscherContainer ( librevenge::RVNGInputStream * input,
const EscherContainerInfo & parent,
EscherContainerInfo & out,
unsigned short type )
protected

Referenced by parseEscher(), and parseEscherShape().

◆ findEscherContainerWithTypeInSet()

bool libmspub::MSPUBParser::findEscherContainerWithTypeInSet ( librevenge::RVNGInputStream * input,
const EscherContainerInfo & parent,
EscherContainerInfo & out,
std::set< unsigned short > types )
protected

◆ getBlockDataLength()

short libmspub::MSPUBParser::getBlockDataLength ( unsigned type)
staticprotected

Referenced by parseBlock().

◆ getCharacterStyle()

CharacterStyle libmspub::MSPUBParser::getCharacterStyle ( librevenge::RVNGInputStream * input)
protected

◆ getColorIndex()

int libmspub::MSPUBParser::getColorIndex ( librevenge::RVNGInputStream * input,
const MSPUBBlockInfo & info )
protected

Referenced by getCharacterStyle().

◆ getColorIndexByQuillEntry()

unsigned libmspub::MSPUBParser::getColorIndexByQuillEntry ( unsigned entry)
protectedvirtual

Reimplemented in libmspub::MSPUBParser2k.

Referenced by getCharacterStyle().

◆ getDynamicCustomShape()

DynamicCustomShape libmspub::MSPUBParser::getDynamicCustomShape ( const std::vector< unsigned char > & vertexData,
const std::vector< unsigned char > & segmentData,
const std::vector< unsigned char > & guideData,
unsigned geoWidth,
unsigned geoHeight )
protected

Referenced by parseEscherShape().

◆ getEscherElementAdditionalHeaderLength()

unsigned libmspub::MSPUBParser::getEscherElementAdditionalHeaderLength ( unsigned short type)
staticprotected

Referenced by extractEscherValues().

◆ getEscherElementTailLength()

unsigned libmspub::MSPUBParser::getEscherElementTailLength ( unsigned short type)
staticprotected

◆ getFontIndex()

unsigned libmspub::MSPUBParser::getFontIndex ( librevenge::RVNGInputStream * input,
const MSPUBBlockInfo & info )
protected

Referenced by getCharacterStyle().

◆ getNewFill()

std::shared_ptr< Fill > libmspub::MSPUBParser::getNewFill ( const std::map< unsigned short, unsigned > & foptProperties,
bool & skipIfNotBg,
std::map< unsigned short, std::vector< unsigned char > > & foptValues )
protected

Referenced by parseEscherShape().

◆ getPageTypeBySeqNum()

PageType libmspub::MSPUBParser::getPageTypeBySeqNum ( unsigned seqNum)
staticprotected

Referenced by parsePageChunk().

◆ getParagraphStyle()

ParagraphStyle libmspub::MSPUBParser::getParagraphStyle ( librevenge::RVNGInputStream * input)
protected

◆ getStartOffset()

int libmspub::MSPUBParser::getStartOffset ( ImgType type,
unsigned short initial )
staticprotected

Referenced by parseEscherDelay().

◆ imgTypeByBlipType()

ImgType libmspub::MSPUBParser::imgTypeByBlipType ( unsigned short type)
staticprotected

Referenced by parseEscherDelay().

◆ isBlockDataString()

bool libmspub::MSPUBParser::isBlockDataString ( unsigned type)
staticprotected

Referenced by parseBlock().

◆ lineExistsByFlagPointer()

bool libmspub::MSPUBParser::lineExistsByFlagPointer ( unsigned * flags,
unsigned * geomFlags = nullptr )
staticprotected

Referenced by parseEscherShape().

◆ operator=()

MSPUBParser & libmspub::MSPUBParser::operator= ( const MSPUBParser & )
protected

◆ parse()

bool libmspub::MSPUBParser::parse ( )
virtual

◆ parseBlock()

◆ parseBorderArtChunk()

bool libmspub::MSPUBParser::parseBorderArtChunk ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parseCharacterStyles()

std::vector< MSPUBParser::TextSpanReference > libmspub::MSPUBParser::parseCharacterStyles ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseColors()

void libmspub::MSPUBParser::parseColors ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseContentChunkReference()

bool libmspub::MSPUBParser::parseContentChunkReference ( librevenge::RVNGInputStream * input,
MSPUBBlockInfo block )
protected

Referenced by parseContents().

◆ parseContents()

bool libmspub::MSPUBParser::parseContents ( librevenge::RVNGInputStream * input)
protectedvirtual

Reimplemented in libmspub::MSPUBParser2k.

Referenced by parse().

◆ parseDefaultStyle()

void libmspub::MSPUBParser::parseDefaultStyle ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseDocumentChunk()

bool libmspub::MSPUBParser::parseDocumentChunk ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parseEscher()

bool libmspub::MSPUBParser::parseEscher ( librevenge::RVNGInputStream * input)
protected

Referenced by parse().

◆ parseEscherContainer()

EscherContainerInfo libmspub::MSPUBParser::parseEscherContainer ( librevenge::RVNGInputStream * input)
protected

◆ parseEscherDelay()

bool libmspub::MSPUBParser::parseEscherDelay ( librevenge::RVNGInputStream * input)
protected

Referenced by parse().

◆ parseEscherShape()

void libmspub::MSPUBParser::parseEscherShape ( librevenge::RVNGInputStream * input,
const EscherContainerInfo & sp,
Coordinate & parentCoordinateSystem,
Coordinate & parentGroupAbsoluteCoord )
protected

Referenced by parseShapeGroup().

◆ parseFontChunk()

bool libmspub::MSPUBParser::parseFontChunk ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parseFonts()

void libmspub::MSPUBParser::parseFonts ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseGuides()

std::vector< Calculation > libmspub::MSPUBParser::parseGuides ( const std::vector< unsigned char > & guideData)
protected

Referenced by getDynamicCustomShape().

◆ parseMetaData()

bool libmspub::MSPUBParser::parseMetaData ( )
protected

Referenced by parse().

◆ parsePageChunk()

bool libmspub::MSPUBParser::parsePageChunk ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parsePageShapeList()

bool libmspub::MSPUBParser::parsePageShapeList ( librevenge::RVNGInputStream * input,
MSPUBBlockInfo block,
unsigned pageSeqNum )
protected

Referenced by parsePageChunk().

◆ parsePaletteChunk()

bool libmspub::MSPUBParser::parsePaletteChunk ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parsePaletteEntry()

void libmspub::MSPUBParser::parsePaletteEntry ( librevenge::RVNGInputStream * input,
MSPUBBlockInfo block )
protected

Referenced by parsePaletteChunk().

◆ parseParagraphStyles()

std::vector< MSPUBParser::TextParagraphReference > libmspub::MSPUBParser::parseParagraphStyles ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseQuill()

bool libmspub::MSPUBParser::parseQuill ( librevenge::RVNGInputStream * input)
protected

◆ parseQuillChunkReference()

QuillChunkReference libmspub::MSPUBParser::parseQuillChunkReference ( librevenge::RVNGInputStream * input)
protected

Referenced by parseQuill().

◆ parseSegments()

std::vector< unsigned short > libmspub::MSPUBParser::parseSegments ( const std::vector< unsigned char > & segmentData)
protected

Referenced by getDynamicCustomShape().

◆ parseShape()

bool libmspub::MSPUBParser::parseShape ( librevenge::RVNGInputStream * input,
const ContentChunkReference & chunk )
protected

Referenced by parseContents().

◆ parseShapeGroup()

void libmspub::MSPUBParser::parseShapeGroup ( librevenge::RVNGInputStream * input,
const EscherContainerInfo & spgr,
Coordinate parentCoordinateSystem,
Coordinate parentGroupAbsoluteCoord )
protected

Referenced by parseEscher(), and parseShapeGroup().

◆ parseTableCellDefinitions()

std::vector< unsigned > libmspub::MSPUBParser::parseTableCellDefinitions ( librevenge::RVNGInputStream * input,
const QuillChunkReference & chunk )
protected

Referenced by parseQuill().

◆ parseVertices()

std::vector< Vertex > libmspub::MSPUBParser::parseVertices ( const std::vector< unsigned char > & vertexData)
protected

◆ skipBlock()

void libmspub::MSPUBParser::skipBlock ( librevenge::RVNGInputStream * input,
MSPUBBlockInfo block )
protected

Member Data Documentation

◆ m_alternateShapeSeqNums

std::vector<int> libmspub::MSPUBParser::m_alternateShapeSeqNums
protected

◆ m_blockInfo

std::vector<MSPUBBlockInfo> libmspub::MSPUBParser::m_blockInfo
protected

Referenced by MSPUBParser(), and parseContents().

◆ m_borderArtChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_borderArtChunkIndices
protected

◆ m_cellsChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_cellsChunkIndices
protected

◆ m_collector

◆ m_contentChunks

◆ m_documentChunkIndex

◆ m_escherDelayIndices

std::vector<int> libmspub::MSPUBParser::m_escherDelayIndices
protected

◆ m_fontChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_fontChunkIndices
protected

◆ m_input

librevenge::RVNGInputStream* libmspub::MSPUBParser::m_input
protected

◆ m_lastAddedImage

unsigned libmspub::MSPUBParser::m_lastAddedImage
protected

◆ m_lastSeenSeqNum

int libmspub::MSPUBParser::m_lastSeenSeqNum
protected

◆ m_length

◆ m_pageChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_pageChunkIndices
protected

◆ m_paletteChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_paletteChunkIndices
protected

◆ m_shapeChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_shapeChunkIndices
protected

◆ m_unknownChunkIndices

std::vector<unsigned> libmspub::MSPUBParser::m_unknownChunkIndices
protected

The documentation for this class was generated from the following files:

Generated for libmspub by doxygen 1.14.0