ClarisWksText Class Reference

the main class to read the text part of Claris Works file More...

#include <ClarisWksText.hxx>

Public Member Functions

 ClarisWksText (ClarisWksDocument &document)
 constructor More...
 
virtual ~ClarisWksText ()
 destructor More...
 
int version () const
 returns the file version More...
 
int numPages () const
 returns the number of pages More...
 
bool updatePageSpanList (MWAWPageSpan const &page, std::vector< MWAWPageSpan > &spanList)
 updates the page span list and returns true if this is possible More...
 
std::shared_ptr< ClarisWksStruct::DSETreadDSETZone (ClarisWksStruct::DSET const &zone, MWAWEntry const &entry, bool &complete)
 reads the zone Text DSET More...
 

Protected Member Functions

void setProperty (MWAWListener &listener, ClarisWksTextInternal::Paragraph const &ruler, int listId=-1)
 sends a paragraph property to the listener More...
 
bool sendZone (int number, MWAWListenerPtr const &listener=MWAWListenerPtr())
 sends the zone data to the listener (if it exists ) More...
 
bool canSendTextAsGraphic (int number) const
 check if we can send a textzone as graphic More...
 
void flushExtra ()
 sends the data which have not yet been sent to the listener More...
 
bool readParagraphs (MWAWEntry const &entry, ClarisWksTextInternal::Zone &zone)
 try to read the paragraph More...
 
bool readFonts (MWAWEntry const &entry, ClarisWksTextInternal::Zone &zone)
 try to read a font sequence More...
 
bool readTokens (MWAWEntry const &entry, ClarisWksTextInternal::Zone &zone)
 try to the token zone) More...
 
bool readTextZoneSize (MWAWEntry const &entry, ClarisWksTextInternal::Zone &zone)
 try to read the text zone size More...
 
bool readTextSection (ClarisWksTextInternal::Zone &zone)
 try to read the section More...
 
bool sendText (ClarisWksTextInternal::Zone const &zone, MWAWListenerPtr listener)
 send the text zone to the listener More...
 
bool canSendTextAsGraphic (ClarisWksTextInternal::Zone const &zone) const
 check if we can send a textzone has graphic More...
 
int findListId (ClarisWksTextInternal::Zone const &zone, int actListId, long cPos, long &lastPos)
 try to find a list id which corresponds to the list beginning in actPos More...
 
bool readParagraphs ()
 read the rulers block which is present at the beginning of the text in the first version of Claris Works : v1-2 More...
 
bool readParagraph (int id=-1)
 the definition of ruler : present at the beginning of the text in the first version of Claris Works : v1-2, present in the STYL entries in v4-v6 files More...
 
bool readSTYL_RULR (int N, int fSz)
 read a STYL Paragraph sequence More...
 

Protected Attributes

ClarisWksDocumentm_document
 the document More...
 
MWAWParserStatePtr m_parserState
 the parser state More...
 
std::shared_ptr< ClarisWksTextInternal::Statem_state
 the state More...
 
MWAWParserm_mainParser
 the main parser; More...
 

Private Member Functions

 ClarisWksText (ClarisWksText const &orig)=delete
 
ClarisWksTextoperator= (ClarisWksText const &orig)=delete
 

Friends

class ClarisWksTextInternal::SubDocument
 
class ClarisWksDocument
 
class ClarisWksParser
 
class ClarisWksStyleManager
 

Detailed Description

the main class to read the text part of Claris Works file

Constructor & Destructor Documentation

ClarisWksText::ClarisWksText ( ClarisWksDocument document)
explicit

constructor

ClarisWksText::~ClarisWksText ( )
virtual

destructor

ClarisWksText::ClarisWksText ( ClarisWksText const &  orig)
privatedelete

Member Function Documentation

bool ClarisWksText::canSendTextAsGraphic ( int  number) const
protected

check if we can send a textzone as graphic

bool ClarisWksText::canSendTextAsGraphic ( ClarisWksTextInternal::Zone const &  zone) const
protected

check if we can send a textzone has graphic

int ClarisWksText::findListId ( ClarisWksTextInternal::Zone const &  zone,
int  actListId,
long  cPos,
long &  lastPos 
)
protected

try to find a list id which corresponds to the list beginning in actPos

Referenced by sendText().

void ClarisWksText::flushExtra ( )
protected

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

int ClarisWksText::numPages ( ) const

returns the number of pages

ClarisWksText& ClarisWksText::operator= ( ClarisWksText const &  orig)
privatedelete
std::shared_ptr< ClarisWksStruct::DSET > ClarisWksText::readDSETZone ( ClarisWksStruct::DSET const &  zone,
MWAWEntry const &  entry,
bool &  complete 
)

reads the zone Text DSET

bool ClarisWksText::readFonts ( MWAWEntry const &  entry,
ClarisWksTextInternal::Zone zone 
)
protected

try to read a font sequence

Referenced by readDSETZone().

bool ClarisWksText::readParagraph ( int  id = -1)
protected

the definition of ruler : present at the beginning of the text in the first version of Claris Works : v1-2, present in the STYL entries in v4-v6 files

Referenced by readParagraphs(), and readSTYL_RULR().

bool ClarisWksText::readParagraphs ( MWAWEntry const &  entry,
ClarisWksTextInternal::Zone zone 
)
protected

try to read the paragraph

bool ClarisWksText::readParagraphs ( )
protected

read the rulers block which is present at the beginning of the text in the first version of Claris Works : v1-2

Referenced by readDSETZone().

bool ClarisWksText::readSTYL_RULR ( int  N,
int  fSz 
)
protected

read a STYL Paragraph sequence

bool ClarisWksText::readTextSection ( ClarisWksTextInternal::Zone zone)
protected

try to read the section

find f0=O| (for second section)[1|2|4] f1=0| (for second section [2e,4e,5b] , f2=0|2d|4d|5a

Referenced by readDSETZone().

bool ClarisWksText::readTextZoneSize ( MWAWEntry const &  entry,
ClarisWksTextInternal::Zone zone 
)
protected

try to read the text zone size

Referenced by readDSETZone().

bool ClarisWksText::readTokens ( MWAWEntry const &  entry,
ClarisWksTextInternal::Zone zone 
)
protected

try to the token zone)

Referenced by readDSETZone().

bool ClarisWksText::sendText ( ClarisWksTextInternal::Zone const &  zone,
MWAWListenerPtr  listener 
)
protected

send the text zone to the listener

Referenced by flushExtra(), and sendZone().

bool ClarisWksText::sendZone ( int  number,
MWAWListenerPtr const &  listener = MWAWListenerPtr() 
)
protected

sends the zone data to the listener (if it exists )

void ClarisWksText::setProperty ( MWAWListener listener,
ClarisWksTextInternal::Paragraph const &  ruler,
int  listId = -1 
)
protected

sends a paragraph property to the listener

Referenced by sendText().

bool ClarisWksText::updatePageSpanList ( MWAWPageSpan const &  page,
std::vector< MWAWPageSpan > &  spanList 
)

updates the page span list and returns true if this is possible

int ClarisWksText::version ( ) const

Friends And Related Function Documentation

friend class ClarisWksDocument
friend
friend class ClarisWksParser
friend
friend class ClarisWksStyleManager
friend

Member Data Documentation

ClarisWksDocument& ClarisWksText::m_document
protected
MWAWParser* ClarisWksText::m_mainParser
protected

the main parser;


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

Generated on Thu May 30 2024 13:09:13 for libmwaw by doxygen 1.8.10