34 #ifndef MW_PRO_STRUCTURES
35 # define MW_PRO_STRUCTURES
52 namespace MWProParserInternal
57 namespace MWProStructuresInternal
83 bool send(
int blockId);
100 MWAW_DEBUG_MSG((
"MWProStructuresListenerState::numSection: not called in main zone\n"));
119 bool newPage(
bool softBreak=
false);
143 shared_ptr<MWProStructuresInternal::Font>
m_font;
231 shared_ptr<MWProStructuresInternal::Block>
readBlock();
234 shared_ptr<MWProStructuresInternal::Block>
readBlockV2(
int id);
249 bool readSections(std::vector<MWProStructuresInternal::Section> §ions);
264 bool getPattern(
int patId,
float &patternPercent)
const;
276 bool send(
int blockId,
bool mainZone=
false);
306 shared_ptr<MWProStructuresInternal::State>
m_state;
Internal: the fonts.
Definition: MWProStructures.cxx:288
Internal: class to store the paragraph properties.
Definition: MWProStructures.cxx:322
an interface to transmit the info of MWProStructures to a listener
Definition: MWProStructures.hxx:72
Internal: the subdocument of a MWProParser.
Definition: MWProParser.cxx:233
void init()
inits all internal variables
Definition: MWProStructures.cxx:545
the main class to read the structures part of MacWrite Pro file
Definition: MWProStructures.hxx:153
MWProParser & m_mainParser
the main parser
Definition: MWProStructures.hxx:303
bool send(int blockId, bool mainZone=false)
try to send a block which corresponds to blockid
Definition: MWProStructures.cxx:2476
bool isSent(int blockId)
returns true if the block is already sent ( or does not exists)
Definition: MWProStructures.cxx:2609
bool send(int blockId)
try to send a block which corresponds to blockid
Definition: MWProStructures.cxx:2615
int getEndBlockSize()
returns the size of the block end data
Definition: MWProStructures.cxx:1811
int m_numCols
Definition: MWProStructures.hxx:137
int numSection() const
returns the actual section
Definition: MWProStructures.hxx:98
shared_ptr< MWProStructuresInternal::State > m_state
the state
Definition: MWProStructures.hxx:306
an interface used to insert comment in a binary file, written in ascii form (if debug_with_files is n...
Definition: MWAWDebug.hxx:66
bool readParagraph(MWProStructuresInternal::Paragraph ¶)
try to read a paragraph
Definition: MWProStructures.cxx:1360
std::vector< int > getPageBreaksPos() const
return a list of page break position ( as some page break are soft )
Definition: MWProStructures.cxx:2652
bool readBlocksList()
try to read the list of block entries
Definition: MWProStructures.cxx:1743
void insertSoftPageBreak()
insert a page break ( if we are not on a new page )
Definition: MWProStructures.cxx:2622
libmwaw::DebugFile & ascii()
returns the debug file
Definition: MWProStructures.hxx:282
int numPages() const
returns the number of pages
Definition: MWProStructures.cxx:563
bool sendFont(int id)
try to send a character style
Definition: MWProStructures.cxx:2748
int m_numTab
Definition: MWProStructures.hxx:133
libmwaw::DebugFile m_asciiFile
the debug file
Definition: MWProStructures.hxx:309
shared_ptr< MWProStructuresInternal::Block > readBlock()
try to read a block entry
Definition: MWProStructures.cxx:1950
int m_section
Definition: MWProStructures.hxx:135
~MWProStructuresListenerState()
the destructor
Definition: MWProStructures.cxx:2605
bool readStyle(int styleId)
try to read a style
Definition: MWProStructures.cxx:1648
bool createZones()
finds the different objects zones
Definition: MWProStructures.cxx:710
bool getPattern(int patId, float &patternPercent) const
try to return the pattern corresponding to patId
Definition: MWProStructures.cxx:669
bool sendParagraph(int id)
try to send a paragraph
Definition: MWProStructures.cxx:2794
std::string getParagraphDebugString(int paraId)
debug function which returns a string corresponding to a paragrapId
Definition: MWProStructures.cxx:2817
the class to store a color
Definition: libmwaw_internal.hxx:166
bool readParagraphs()
try to read a list of paragraph
Definition: MWProStructures.cxx:1306
the main class to read a MacWrite II and MacWrite Pro file
Definition: MWProParser.hxx:68
bool readFontsName()
try to read the fonts zone
Definition: MWProStructures.cxx:1096
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:116
bool readFont(MWProStructuresInternal::Font &font)
try to read a font
Definition: MWProStructures.cxx:1219
bool readSelection()
try to read a 16 bytes the zone which follow the char styles zone ( the selection?)
Definition: MWProStructures.cxx:2338
shared_ptr< MWProStructuresInternal::Block > readBlockV2(int id)
try to read a block entry
Definition: MWProStructures.cxx:1823
bool readSections(std::vector< MWProStructuresInternal::Section > §ions)
try to read the section info ?
Definition: MWProStructures.cxx:2220
shared_ptr< MWProStructures > m_structures
Definition: MWProStructures.hxx:141
bool isSent(int blockId)
returns true if the block is already sent ( or does not exists)
Definition: MWProStructures.cxx:2457
bool getColor(int colId, MWAWColor &color) const
try to return the color corresponding to colId
Definition: MWProStructures.cxx:612
std::string m_asciiName
the debug file name
Definition: MWProStructures.hxx:312
bool newPage(bool softBreak=false)
create a new page
Definition: MWProStructures.cxx:2628
bool m_isMainZone
Definition: MWProStructures.hxx:127
bool readStyles()
try to read the paragraph styles zone which begins at address 0x200
Definition: MWProStructures.cxx:1607
std::string const & asciiName() const
return the ascii file name
Definition: MWProStructures.hxx:287
virtual ~MWProStructures()
destructor
Definition: MWProStructures.cxx:540
bool resendAll()
force resent data : font + paragraph
Definition: MWProStructures.cxx:2739
MWAWInputStreamPtr m_input
the main input
Definition: MWProStructures.hxx:300
void setAsciiName(char const *name)
Debugging: change the default ascii file (by default struct )
Definition: MWProStructures.hxx:171
bool createZonesV2()
finds the different objects zones in a MacWriteII file
Definition: MWProStructures.cxx:828
bool sendMainZone()
send the main zone
Definition: MWProStructures.cxx:938
void flushExtra()
flush not send zones
Definition: MWProStructures.cxx:2545
shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:348
int getHeaderId(int page, int &numSimillar) const
return the header blockid ( or 0)
Definition: MWProStructures.cxx:570
int version() const
returns the file version.
Definition: MWProStructures.cxx:551
bool m_newPageDone
Definition: MWProStructures.hxx:139
MWAWParserStatePtr m_parserState
the parser state
Definition: MWProStructures.hxx:297
bool readFontsDef()
try to read the list of fonts
Definition: MWProStructures.cxx:1167
void buildPageStructures()
look for pages structures
Definition: MWProStructures.cxx:969
shared_ptr< MWProStructuresInternal::Font > m_font
Definition: MWProStructures.hxx:143
int m_actTab
Definition: MWProStructures.hxx:131
MWProStructuresListenerState(shared_ptr< MWProStructures > structures, bool mainZone)
the constructor
Definition: MWProStructures.cxx:2589
std::string getFontDebugString(int fontId)
debug function which returns a string corresponding to a fontId
Definition: MWProStructures.cxx:2771
int m_actPage
Definition: MWProStructures.hxx:129
shared_ptr< MWAWContentListener > MWAWContentListenerPtr
a smart pointer of MWAWContentListener
Definition: libmwaw_internal.hxx:340
MWAWContentListenerPtr & getListener()
returns the actual listener
Definition: MWProStructures.cxx:558
void buildTableStructures()
look for tables structures and if so, prepare data
Definition: MWProStructures.cxx:1038
void sendSection(int numSection)
try to send the i^th section
Definition: MWProStructures.cxx:2834
shared_ptr< MWAWParserState > MWAWParserStatePtr
a smart pointer of MWAWParserState
Definition: libmwaw_internal.hxx:356
shared_ptr< MWProStructuresInternal::Paragraph > m_paragraph
Definition: MWProStructures.hxx:145
MWProStructures(MWProParser &mainParser)
constructor
Definition: MWProStructures.cxx:533
static bool readString(MWAWInputStreamPtr input, std::string &res)
try to read a string
Definition: MWProStructures.cxx:2378
int getFooterId(int page, int &numSimillar) const
return the footer blockid ( or 0)
Definition: MWProStructures.cxx:590
bool readStructB()
try to read a zone which follow the fonts zone(checkme)
Definition: MWProStructures.cxx:2413
Internal: the cell of a WNProStructure.
Definition: MWProStructures.cxx:338
void sendChar(char c)
send a character
Definition: MWProStructures.cxx:2665
bool readCharStyles()
try to read the character styles zone
Definition: MWProStructures.cxx:1521