MSKParser Class Referenceabstract

generic parser for Microsoft Works file More...

`#include <MSKParser.hxx>`

Inheritance diagram for MSKParser:

## Public Member Functions

| MSKParser (MWAWInputStreamPtr input, MWAWRSRCParserPtr rsrcParser, MWAWHeader *header)
| constructor More...
| MSKParser (MWAWInputStreamPtr input, MWAWParserStatePtr parserState)
| constructor using the parser state More...
virtual | ~MSKParser ()
| destructor More...
MWAWInputStreamPtr & | getInput ()
| returns the actual input More...
bool | getColor (int id, MWAWColor &col, int vers=-1) const
| return the color which correspond to an index More...
virtual void | sendFrameText (MWAWEntry const &entry, std::string const &frame)
| virtual function used to send the text of a frame (v4) More...
virtual void | sendOLE (int id, MWAWPosition const &pos, WPXPropertyList frameExtras)
| virtual function used to send an OLE (v4) More...
virtual Vec2f | getPageLeftTop () const =0
| returns the page top left point More...
libmwaw::DebugFile & | ascii ()
| a DebugFile used to write what we recognize when we parse the document More...
Public Member Functions inherited from MWAWParser
virtual | ~MWAWParser ()
| virtual destructor More...
virtual void | parse (WPXDocumentInterface *documentInterface)=0
| virtual function used to parse the input More...
virtual bool | checkHeader (MWAWHeader *header, bool strict=false)=0
| virtual function used to check if the document header is correct (or not) More...
int | version () const
| returns the works version More...
void | setVersion (int vers)
| sets the works version More...

## Static Public Member Functions

static std::vector< MWAWColor > const & | getPalette (int vers)
| return a list of color corresponding to a version More...

## Protected Attributes

shared_ptr < MSKParserInternal::State > | m_state
| the state More...
MWAWInputStreamPtr | m_input
| the input which can be an OLE in MSWorks 4 file More...
libmwaw::DebugFile | m_asciiFile
| the debug file of the actual input More...

## Friends

class | MSKGraph

## Additional Inherited Members

Protected Member Functions inherited from MWAWParser
| MWAWParser (MWAWInputStreamPtr input, MWAWRSRCParserPtr rsrcParser, MWAWHeader *header)
| constructor (protected) More...
| MWAWParser (MWAWParserStatePtr state)
| constructor using a state More...
MWAWParserStatePtr | getParserState ()
| returns the parser state More...
MWAWHeader * | getHeader ()
| returns the header More...
MWAWInputStreamPtr & | getInput ()
| returns the actual input More...
MWAWContentListenerPtr & | getListener ()
| returns the listener More...
MWAWPageSpan const & | getPageSpan () const
| returns the actual page dimension More...
MWAWPageSpan & | getPageSpan ()
| returns the actual page dimension More...
double | getFormLength () const
| returns the form length More...
double | getFormWidth () const
| returns the form width More...
double | getPageLength () const
| returns the page length (form length without margin ) More...
double | getPageWidth () const
| returns the page width (form width without margin ) More...
MWAWRSRCParserPtr & | getRSRCParser ()
| returns the rsrc parser More...
void | setListener (MWAWContentListenerPtr &listener)
| sets the listener More...
void | resetListener ()
| resets the listener More...
MWAWFontConverterPtr & | getFontConverter ()
| returns the font converter More...
void | setFontConverter (MWAWFontConverterPtr fontConverter)
| sets the font convertor More...
libmwaw::DebugFile & | ascii ()
| a DebugFile used to write what we recognize when we parse the document More...
void | setAsciiName (char const *name)
| Debugging: change the default ascii file. More...
std::string const & | asciiName () const
| return the ascii file name More...

## Detailed Description

generic parser for Microsoft Works file

## Constructor & Destructor Documentation

MSKParser::MSKParser | ( | MWAWInputStreamPtr | input,
|  | MWAWRSRCParserPtr | rsrcParser,
|  | MWAWHeader * | header
| ) |  |

constructor

MSKParser::MSKParser | ( | MWAWInputStreamPtr | input,
|  | MWAWParserStatePtr | parserState
| ) |  |

constructor using the parser state

MSKParser::~MSKParser | ( |  | ) |

virtual

destructor

## Member Function Documentation

libmwaw::DebugFile& MSKParser::ascii | ( |  | ) |

inline

a DebugFile used to write what we recognize when we parse the document

Referenced by MSK3Parser::checkHeader(), MSK3Parser::createZones(), MSKGraph::getEntryPicture(), MSKGraph::getEntryPictureV1(), MSK3Parser::parse(), MSK4Zone::parseHeaderIndex(), MSK4Zone::parseHeaderIndexEntry(), MSKGraph::readChart(), MSK3Parser::readDocumentInfo(), MSK4Zone::readDOP(), MSK4Text::readFDP(), MSK4Text::readFontNames(), MSK4Zone::readFRAM(), MSK3Parser::readGroup(), MSK3Parser::readGroupHeaderInfo(), MSK3Text::readParagraph(), MSK4Text::readParagraph(), MSKGraph::readPictureV4(), MSK4Text::readPLC(), MSK3Parser::readPrintInfo(), MSK4Zone::readPRNT(), MSKGraph::readRB(), MSK4Zone::readRLRB(), MSK4Zone::readSELN(), MSKGraph::readTable(), MSK4Text::readText(), MSKGraph::readText(), MSKGraph::send(), MSK3Text::sendText(), MSK4Zone::setAscii(), and MSK4Text::toknDataParser().

bool MSKParser::getColor | ( | int | id,
|  | MWAWColor & | col,
|  | int | vers = `-1`
| ) |  | const

return the color which correspond to an index

Referenced by MSK3Text::readFont(), MSKGraph::readPictHeader(), and MSKGraph::readTable().

MWAWInputStreamPtr& MSKParser::getInput | ( |  | ) |

inline

returns the actual input

Referenced by MSK3Parser::checkHeader(), MSK3Parser::createDocument(), MSK3Text::createZones(), MSK3Parser::createZones(), MSK4Zone::createZones(), MSKGraph::getEntryPicture(), MSKGraph::getEntryPictureV1(), MSK4Zone::newPage(), MSK3Parser::parse(), MSKGraph::readChart(), MSK4Zone::readContentZones(), MSK3Parser::readDocumentInfo(), MSK3Text::readFont(), MSKGraph::readFont(), MSK4Zone::readFootNote(), MSK3Parser::readGroup(), MSKGraph::readGroup(), MSK3Parser::readGroupHeaderInfo(), MSK3Text::readHeaderFooterString(), MSK3Text::readParagraph(), MSKGraph::readPictHeader(), MSK3Parser::readPrintInfo(), MSKGraph::readTable(), MSKGraph::readText(), MSK3Parser::readZone(), MSK3Text::readZoneHeader(), MSKGraph::send(), MSK4Parser::sendFootNote(), MSK3Parser::sendFootNote(), MSKGraph::sendObjects(), MSK3Text::sendText(), and MSK3Text::updateNotes().

virtual Vec2f MSKParser::getPageLeftTop | ( |  | ) | const

pure virtual

returns the page top left point

Implemented in MSK4Zone, and MSK3Parser.

Referenced by MSKGraph::send().

std::vector< MWAWColor > const & MSKParser::getPalette | ( | int | vers | ) |

static

return a list of color corresponding to a version

Referenced by getColor(), and MSKGraph::send().

void MSKParser::sendFrameText | ( | MWAWEntry const & | entry,
|  | std::string const & | frame
| ) |  |

virtual

virtual function used to send the text of a frame (v4)

Reimplemented in MSK4Zone.

Referenced by MSKGraph::sendFrameText().

void MSKParser::sendOLE | ( | int | id,
|  | MWAWPosition const & | pos,
|  | WPXPropertyList | frameExtras
| ) |  |

virtual

virtual function used to send an OLE (v4)

Reimplemented in MSK4Zone.

Referenced by MSKGraph::send().

## Friends And Related Function Documentation

friend class MSKGraph

friend

## Member Data Documentation

libmwaw::DebugFile MSKParser::m_asciiFile

protected

the debug file of the actual input

Referenced by ascii().

MWAWInputStreamPtr MSKParser::m_input

protected

the input which can be an OLE in MSWorks 4 file

Referenced by getInput().

shared_ptr<MSKParserInternal::State> MSKParser::m_state

protected

the state

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

- MSKParser.hxx
- MSKParser.cxx