HanMacWrdJText Class Reference

the main class to read the text part of HanMac Word-J file More...

#include <HanMacWrdJText.hxx>

Public Member Functions

 HanMacWrdJText (HanMacWrdJParser &parser)
 constructor
virtual ~HanMacWrdJText ()
 destructor
int version () const
 returns the file version
int numPages () const
 returns the number of pages

Protected Member Functions

bool sendMainText ()
 send the main text zone
bool sendText (long id, long cPos, MWAWListenerPtr listener=MWAWListenerPtr())
 send a text zone
bool canSendTextAsGraphic (long id, long cPos)
 check if we can send a textzone as graphic
bool sendText (HanMacWrdJTextInternal::TextZone const &zone, long cPos, MWAWListenerPtr listener=MWAWListenerPtr())
 send a text zone
bool canSendTextAsGraphic (HanMacWrdJTextInternal::TextZone const &zone, long cPos)
 check if we can send a textzone has graphic
void flushExtra ()
 sends the data which have not yet been sent to the listener
int computeNumPages (HanMacWrdJTextInternal::TextZone const &zone)
 compute the number of pages present in a zone
std::vector< long > getTokenIdList () const
 returns the list of zoneId which corresponds to the token
void updateTextZoneTypes (std::map< long, int > const &idTypeMap)
 update the text zone type with map id->type
void updateFootnoteInformations (long const &textZId, std::vector< long > const &fPosList)
 update the footnote text zone id and the list of first char position
bool readFontNames (MWAWEntry const &entry)
 try to read the fonts name zone (type 15)
bool readFonts (MWAWEntry const &entry)
 try to read the fonts zone (type 0)
bool readFont (MWAWFont &font, long endPos=-1)
 try to read the font ( reading up to endPos if endPos is defined )
bool readParagraphs (MWAWEntry const &entry)
 try to read the paragraphs zone (type 1)
bool readParagraph (HanMacWrdJTextInternal::Paragraph &para, long endPos=-1)
 try to read a paragraph ( reading up to endPos if endPos is defined )
bool readStyles (MWAWEntry const &entry)
 try to read the style zone (type 2)
bool readTextZonesList (MWAWEntry const &entry)
 try to read the list of textzones ( type 4)
bool readTextZone (MWAWEntry const &entry, int actZone)
 try to read a text zone ( type 5 )
bool readTextToken (long endPos, HanMacWrdJTextInternal::TextZone &zone)
 try to read the token in the text zone
bool readSections (MWAWEntry const &entry)
 try to read the different sections
bool readFtnPos (MWAWEntry const &entry)
 try to read the footnote position

Protected Attributes

MWAWParserStatePtr m_parserState
 the parser state
std::shared_ptr< HanMacWrdJTextInternal::Statem_state
 the state
HanMacWrdJParserm_mainParser
 the main parser;

Private Member Functions

 HanMacWrdJText (HanMacWrdJText const &orig)=delete
HanMacWrdJTextoperator= (HanMacWrdJText const &orig)=delete

Friends

class HanMacWrdJTextInternal::SubDocument
class HanMacWrdJParser

Detailed Description

the main class to read the text part of HanMac Word-J file

Constructor & Destructor Documentation

◆ HanMacWrdJText() [1/2]

HanMacWrdJText::HanMacWrdJText ( HanMacWrdJParser & parser)
explicit

◆ ~HanMacWrdJText()

HanMacWrdJText::~HanMacWrdJText ( )
virtual

destructor

◆ HanMacWrdJText() [2/2]

HanMacWrdJText::HanMacWrdJText ( HanMacWrdJText const & orig)
privatedelete

Member Function Documentation

◆ canSendTextAsGraphic() [1/2]

bool HanMacWrdJText::canSendTextAsGraphic ( HanMacWrdJTextInternal::TextZone const & zone,
long cPos )
protected

check if we can send a textzone has graphic

◆ canSendTextAsGraphic() [2/2]

bool HanMacWrdJText::canSendTextAsGraphic ( long id,
long cPos )
protected

check if we can send a textzone as graphic

Referenced by canSendTextAsGraphic(), and HanMacWrdJParser.

◆ computeNumPages()

int HanMacWrdJText::computeNumPages ( HanMacWrdJTextInternal::TextZone const & zone)
protected

compute the number of pages present in a zone

Referenced by HanMacWrdJParser, and numPages().

◆ flushExtra()

void HanMacWrdJText::flushExtra ( )
protected

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

send data to the listener

Referenced by HanMacWrdJParser.

◆ getTokenIdList()

std::vector< long > HanMacWrdJText::getTokenIdList ( ) const
protected

returns the list of zoneId which corresponds to the token

Referenced by HanMacWrdJParser.

◆ numPages()

int HanMacWrdJText::numPages ( ) const

returns the number of pages

Referenced by HanMacWrdJParser.

◆ operator=()

HanMacWrdJText & HanMacWrdJText::operator= ( HanMacWrdJText const & orig)
privatedelete

◆ readFont()

bool HanMacWrdJText::readFont ( MWAWFont & font,
long endPos = -1 )
protected

try to read the font ( reading up to endPos if endPos is defined )

Referenced by HanMacWrdJParser, and readFonts().

◆ readFontNames()

bool HanMacWrdJText::readFontNames ( MWAWEntry const & entry)
protected

try to read the fonts name zone (type 15)

Referenced by HanMacWrdJParser.

◆ readFonts()

bool HanMacWrdJText::readFonts ( MWAWEntry const & entry)
protected

try to read the fonts zone (type 0)

Referenced by HanMacWrdJParser.

◆ readFtnPos()

bool HanMacWrdJText::readFtnPos ( MWAWEntry const & entry)
protected

try to read the footnote position

Referenced by HanMacWrdJParser.

◆ readParagraph()

bool HanMacWrdJText::readParagraph ( HanMacWrdJTextInternal::Paragraph & para,
long endPos = -1 )
protected

try to read a paragraph ( reading up to endPos if endPos is defined )

Referenced by HanMacWrdJParser, and readParagraphs().

◆ readParagraphs()

bool HanMacWrdJText::readParagraphs ( MWAWEntry const & entry)
protected

try to read the paragraphs zone (type 1)

Referenced by HanMacWrdJParser.

◆ readSections()

bool HanMacWrdJText::readSections ( MWAWEntry const & entry)
protected

try to read the different sections

Referenced by HanMacWrdJParser.

◆ readStyles()

bool HanMacWrdJText::readStyles ( MWAWEntry const & entry)
protected

try to read the style zone (type 2)

Referenced by HanMacWrdJParser.

◆ readTextToken()

bool HanMacWrdJText::readTextToken ( long endPos,
HanMacWrdJTextInternal::TextZone & zone )
protected

try to read the token in the text zone

Referenced by HanMacWrdJParser, and readTextZone().

◆ readTextZone()

bool HanMacWrdJText::readTextZone ( MWAWEntry const & entry,
int actZone )
protected

try to read a text zone ( type 5 )

Referenced by HanMacWrdJParser.

◆ readTextZonesList()

bool HanMacWrdJText::readTextZonesList ( MWAWEntry const & entry)
protected

try to read the list of textzones ( type 4)

Referenced by HanMacWrdJParser.

◆ sendMainText()

bool HanMacWrdJText::sendMainText ( )
protected

send the main text zone

Referenced by HanMacWrdJParser.

◆ sendText() [1/2]

bool HanMacWrdJText::sendText ( HanMacWrdJTextInternal::TextZone const & zone,
long cPos,
MWAWListenerPtr listener = MWAWListenerPtr() )
protected

send a text zone

◆ sendText() [2/2]

bool HanMacWrdJText::sendText ( long id,
long cPos,
MWAWListenerPtr listener = MWAWListenerPtr() )
protected

◆ updateFootnoteInformations()

void HanMacWrdJText::updateFootnoteInformations ( long const & textZId,
std::vector< long > const & fPosList )
protected

update the footnote text zone id and the list of first char position

Referenced by HanMacWrdJParser.

◆ updateTextZoneTypes()

void HanMacWrdJText::updateTextZoneTypes ( std::map< long, int > const & idTypeMap)
protected

update the text zone type with map id->type

Referenced by HanMacWrdJParser.

◆ version()

int HanMacWrdJText::version ( ) const

returns the file version

Referenced by HanMacWrdJParser.

◆ HanMacWrdJParser

friend class HanMacWrdJParser
friend

Referenced by HanMacWrdJParser, and HanMacWrdJText().

◆ HanMacWrdJTextInternal::SubDocument

Member Data Documentation

◆ m_mainParser

◆ m_parserState

◆ m_state


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

Generated on for libmwaw by doxygen 1.18.0