Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Friends | List of all members
WriteNowText Class Reference

the main class to read the text part of writenow file More...

`#include <WriteNowText.hxx>`

## Public Member Functions
| WriteNowText (WriteNowParser &parser)
| constructor More...
virtual | ~WriteNowText ()
| destructor More...
int | version () const
| returns the file version More...
int | numPages () const
| returns the number of pages More...
WriteNowEntry | getHeader () const
| returns the header entry (if defined) More...
WriteNowEntry | getFooter () const
| returns the footer entry (if defined) More...

## Protected Member Functions
bool | createZones ()
| finds the different text zones More...
void | flushExtra ()
| sends the data which have not yet been sent to the listener More...
bool | parseZone (WriteNowEntry const &entry, std::vector< WriteNowEntry > &listData)
| try to read the text zone ( list of entries ) and to create the text data zone More...
std::shared_ptr< WriteNowTextInternal::ContentZones > | parseContent (WriteNowEntry const &entry)
| parse a text data zone ( and create the associated structure ) More...
void | sendZone (int id)
| send all the content zone of a zone defined by id 0: main, 1 header/footer, 2: footnote More...
bool | send (WriteNowEntry const &entry)
| send the text to the listener More...
bool | send (std::vector< WriteNowTextInternal::ContentZone > &listZones, std::vector< std::shared_ptr< WriteNowTextInternal::ContentZones > > &footnoteList, WriteNowTextInternal::Paragraph &ruler)
| send the text to the listener More...
void | setProperty (WriteNowTextInternal::Paragraph const &ruler)
| sends a paragraph property to the listener More...
bool | readFontNames (WriteNowEntry const &entry)
| try to read the fonts zone More...
bool | readFont (MWAWInputStream &input, bool inStyle, WriteNowTextInternal::Font &font)
| read a font More...
bool | readParagraph (MWAWInputStream &input, WriteNowTextInternal::Paragraph &ruler)
| read a paragraph format More...
bool | readToken (MWAWInputStream &input, WriteNowTextInternal::Token &token)
| read a token More...
bool | readTokenV2 (MWAWInputStream &input, WriteNowTextInternal::Token &token)
| read a token (v2) More...
bool | readTable (MWAWInputStream &input, WriteNowTextInternal::TableData &table)
| read a table frame (checkme) More...
bool | readStyles (WriteNowEntry const &entry)
| try to read the styles zone More...

## Protected Attributes
MWAWParserStatePtr | m_parserState
| the parser state More...
std::shared_ptr< WriteNowTextInternal::State > | m_state
| the state More...
std::shared_ptr< WriteNowEntryManager > | m_entryManager
| the list of entry More...
WriteNowParser * | m_mainParser
| the main parser; More...

## Private Member Functions
| WriteNowText (WriteNowText const &orig)=delete
WriteNowText & | operator= (WriteNowText const &orig)=delete

## Friends
class | WriteNowParser
struct | WriteNowTextInternal::Cell

## Detailed Description

the main class to read the text part of writenow file

## Constructor & Destructor Documentation

## ◆ WriteNowText() [1/2]

WriteNowText::WriteNowText | ( | WriteNowParser & | parser | ) |
| explicit

constructor

## ◆ ~WriteNowText()

WriteNowText::~WriteNowText | ( |  | ) |
| virtual

destructor

## ◆ WriteNowText() [2/2]

WriteNowText::WriteNowText | ( | WriteNowText const & | orig | ) |
| private delete

## Member Function Documentation

## ◆ createZones()

bool WriteNowText::createZones | ( |  | ) |
| protected

finds the different text zones

we can now create the content zone and type them

## ◆ flushExtra()

void WriteNowText::flushExtra | ( |  | ) |
| protected

sends the data which have not yet been sent to the listener

## ◆ getFooter()

WriteNowEntry WriteNowText::getFooter | ( |  | ) | const

returns the footer entry (if defined)

## ◆ getHeader()

WriteNowEntry WriteNowText::getHeader | ( |  | ) | const

returns the header entry (if defined)

## ◆ numPages()

int WriteNowText::numPages | ( |  | ) | const

returns the number of pages

## ◆ operator=()

WriteNowText& WriteNowText::operator= | ( | WriteNowText const & | orig | ) |
| private delete

## ◆ parseContent()

std::shared_ptr< WriteNowTextInternal::ContentZones > WriteNowText::parseContent | ( | WriteNowEntry const & | entry | ) |
| protected

parse a text data zone ( and create the associated structure )

Referenced by createZones().

## ◆ parseZone()

bool WriteNowText::parseZone | ( | WriteNowEntry const & | entry,
|  | std::vector< WriteNowEntry > & | listData
| ) |  |
| protected

try to read the text zone ( list of entries ) and to create the text data zone

Referenced by createZones().

## ◆ readFont()

bool WriteNowText::readFont | ( | MWAWInputStream & | input,
|  | bool | inStyle,
|  | WriteNowTextInternal::Font & | font
| ) |  |
| protected

read a font

Referenced by readStyles(), and send().

## ◆ readFontNames()

bool WriteNowText::readFontNames | ( | WriteNowEntry const & | entry | ) |
| protected

try to read the fonts zone

Referenced by createZones().

## ◆ readParagraph()

bool WriteNowText::readParagraph | ( | MWAWInputStream & | input,
|  | WriteNowTextInternal::Paragraph & | ruler
| ) |  |
| protected

read a paragraph format

Referenced by readStyles(), and send().

## ◆ readStyles()

bool WriteNowText::readStyles | ( | WriteNowEntry const & | entry | ) |
| protected

try to read the styles zone

Referenced by createZones().

## ◆ readTable()

bool WriteNowText::readTable | ( | MWAWInputStream & | input,
|  | WriteNowTextInternal::TableData & | table
| ) |  |
| protected

read a table frame (checkme)

Referenced by send().

## ◆ readToken()

bool WriteNowText::readToken | ( | MWAWInputStream & | input,
|  | WriteNowTextInternal::Token & | token
| ) |  |
| protected

read a token

Referenced by send().

## ◆ readTokenV2()

bool WriteNowText::readTokenV2 | ( | MWAWInputStream & | input,
|  | WriteNowTextInternal::Token & | token
| ) |  |
| protected

read a token (v2)

Referenced by send().

## ◆ send() [1/2]

bool WriteNowText::send | ( | WriteNowEntry const & | entry | ) |
| protected

send the text to the listener

Referenced by sendZone().

## ◆ send() [2/2]

bool WriteNowText::send | ( | std::vector< WriteNowTextInternal::ContentZone > & | listZones,
|  | std::vector< std::shared_ptr< WriteNowTextInternal::ContentZones > > & | footnoteList,
|  | WriteNowTextInternal::Paragraph & | ruler
| ) |  |
| protected

send the text to the listener

## ◆ sendZone()

void WriteNowText::sendZone | ( | int | id | ) |
| protected

send all the content zone of a zone defined by id 0: main, 1 header/footer, 2: footnote

Referenced by flushExtra().

## ◆ setProperty()

void WriteNowText::setProperty | ( | WriteNowTextInternal::Paragraph const & | ruler | ) |
| protected

sends a paragraph property to the listener

Referenced by send().

## ◆ version()

int WriteNowText::version | ( |  | ) | const

returns the file version

Referenced by parseContent(), parseZone(), readFont(), readParagraph(), and send().

## Friends And Related Function Documentation

## ◆ WriteNowParser

friend class WriteNowParser
| friend

## ◆ WriteNowTextInternal::Cell

friend struct WriteNowTextInternal::Cell
| friend

## Member Data Documentation

## ◆ m_entryManager

std::shared_ptr<WriteNowEntryManager> WriteNowText::m_entryManager
| protected

the list of entry

Referenced by createZones().

## ◆ m_mainParser

WriteNowParser* WriteNowText::m_mainParser
| protected

the main parser;

Referenced by createZones(), numPages(), parseZone(), readFont(), readParagraph(), readTable(), send(), and sendZone().

## ◆ m_parserState

MWAWParserStatePtr WriteNowText::m_parserState
| protected

the parser state

Referenced by parseContent(), parseZone(), readFontNames(), readStyles(), readTokenV2(), send(), sendZone(), setProperty(), and version().

## ◆ m_state

std::shared_ptr<WriteNowTextInternal::State> WriteNowText::m_state
| protected

the state

Referenced by createZones(), getFooter(), getHeader(), numPages(), parseContent(), readFont(), readFontNames(), readStyles(), send(), sendZone(), setProperty(), and version().

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

- WriteNowText.hxx
- WriteNowText.cxx