the main class to read the text part of HanMac Word file More...
#include <HMWKText.hxx>
Public Member Functions | |
| HMWKText (HMWKParser &parser) | |
| constructor | |
| virtual | ~HMWKText () |
| 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 subId, bool asGraphic=false) |
| send a text zone | |
| bool | canSendTextAsGraphic (long id, long subId) |
| check if we can send a textzone as graphic | |
| void | flushExtra () |
| sends the data which have not yet been sent to the listener | |
| void | updateTextZoneTypes (std::map< long, int > const &idTypeMap) |
| update the text zone type with map id->type | |
| std::vector< long > const & | getTokenIdList () const |
| returns the list of zoneId which corresponds to the token | |
| void | getHeaderFooterId (long &headerId, long &footerId) const |
| return sthe header/footer id | |
| bool | readTextZone (shared_ptr< HMWKZone > zone) |
| try to read a text zone (type 1) | |
| bool | readFontNames (shared_ptr< HMWKZone > zone) |
| try to read the fonts name zone (type 5) | |
| bool | readStyles (shared_ptr< HMWKZone > zone) |
| try to read the style zone (type 3) | |
| bool | readSections (shared_ptr< HMWKZone > zone) |
| try to read a section info zone (type 4) | |
| bool | sendText (HMWKZone &zone, bool asGraphic=false) |
| try to send a text zone (type 1) | |
| bool | canSendTextAsGraphic (HMWKZone &zone) |
| check if we can send a textzone has graphic | |
| bool | readFont (HMWKZone &zone, MWAWFont &font) |
| try to read a font in a text zone | |
| bool | readParagraph (HMWKZone &zone, HMWKTextInternal::Paragraph ¶) |
| try to read a paragraph in a text zone | |
| void | setProperty (HMWKTextInternal::Paragraph const ¶, float width) |
| send the ruler properties | |
| bool | readToken (HMWKZone &zone, HMWKTextInternal::Token &token) |
| try to read an token in a text zone | |
Protected Attributes | |
| MWAWParserStatePtr | m_parserState |
| the parser state | |
| shared_ptr < HMWKTextInternal::State > | m_state |
| the state | |
| HMWKParser * | m_mainParser |
| the main parser; | |
Private Member Functions | |
| HMWKText (HMWKText const &orig) | |
| HMWKText & | operator= (HMWKText const &orig) |
Friends | |
| class | HMWKParser |
the main class to read the text part of HanMac Word file
| HMWKText::HMWKText | ( | HMWKParser & | parser | ) |
constructor
| HMWKText::~HMWKText | ( | ) | [virtual] |
destructor
| HMWKText::HMWKText | ( | HMWKText const & | orig | ) | [private] |
| bool HMWKText::canSendTextAsGraphic | ( | long | id, |
| long | subId | ||
| ) | [protected] |
check if we can send a textzone as graphic
| bool HMWKText::canSendTextAsGraphic | ( | HMWKZone & | zone | ) | [protected] |
check if we can send a textzone has graphic
| void HMWKText::flushExtra | ( | ) | [protected] |
sends the data which have not yet been sent to the listener
send data to the listener
| void HMWKText::getHeaderFooterId | ( | long & | headerId, |
| long & | footerId | ||
| ) | const [protected] |
return sthe header/footer id
| std::vector< long > const & HMWKText::getTokenIdList | ( | ) | const [protected] |
returns the list of zoneId which corresponds to the token
| int HMWKText::numPages | ( | ) | const |
returns the number of pages
| bool HMWKText::readFont | ( | HMWKZone & | zone, |
| MWAWFont & | font | ||
| ) | [protected] |
try to read a font in a text zone
Referenced by canSendTextAsGraphic(), and sendText().
| bool HMWKText::readFontNames | ( | shared_ptr< HMWKZone > | zone | ) | [protected] |
try to read the fonts name zone (type 5)
| bool HMWKText::readParagraph | ( | HMWKZone & | zone, |
| HMWKTextInternal::Paragraph & | para | ||
| ) | [protected] |
try to read a paragraph in a text zone
Referenced by canSendTextAsGraphic(), readTextZone(), and sendText().
| bool HMWKText::readSections | ( | shared_ptr< HMWKZone > | zone | ) | [protected] |
try to read a section info zone (type 4)
| bool HMWKText::readStyles | ( | shared_ptr< HMWKZone > | zone | ) | [protected] |
try to read the style zone (type 3)
| bool HMWKText::readTextZone | ( | shared_ptr< HMWKZone > | zone | ) | [protected] |
try to read a text zone (type 1)
| bool HMWKText::readToken | ( | HMWKZone & | zone, |
| HMWKTextInternal::Token & | token | ||
| ) | [protected] |
try to read an token in a text zone
Referenced by readTextZone(), and sendText().
| bool HMWKText::sendMainText | ( | ) | [protected] |
send the main text zone
| bool HMWKText::sendText | ( | long | id, |
| long | subId, | ||
| bool | asGraphic = false |
||
| ) | [protected] |
send a text zone
Referenced by flushExtra(), and sendMainText().
| bool HMWKText::sendText | ( | HMWKZone & | zone, |
| bool | asGraphic = false |
||
| ) | [protected] |
try to send a text zone (type 1)
| void HMWKText::setProperty | ( | HMWKTextInternal::Paragraph const & | para, |
| float | width | ||
| ) | [protected] |
send the ruler properties
Referenced by sendText().
| void HMWKText::updateTextZoneTypes | ( | std::map< long, int > const & | idTypeMap | ) | [protected] |
update the text zone type with map id->type
| int HMWKText::version | ( | ) | const |
returns the file version
friend class HMWKParser [friend] |
HMWKParser* HMWKText::m_mainParser [protected] |
the main parser;
Referenced by readFont(), readParagraph(), and sendText().
MWAWParserStatePtr HMWKText::m_parserState [protected] |
the parser state
Referenced by flushExtra(), readFont(), readFontNames(), readParagraph(), sendText(), setProperty(), and version().
shared_ptr<HMWKTextInternal::State> HMWKText::m_state [protected] |
the state
Referenced by canSendTextAsGraphic(), flushExtra(), getHeaderFooterId(), getTokenIdList(), numPages(), readSections(), readTextZone(), sendMainText(), sendText(), updateTextZoneTypes(), and version().