Go to the documentation of this file.
38 #ifndef WORD_MAKER_PARSER
39 # define WORD_MAKER_PARSER
std::shared_ptr< MWAWTextListener > MWAWTextListenerPtr
a smart pointer of MWAWTextListener
Definition: libmwaw_internal.hxx:567
basic class to store an entry in a file This contained :
Definition: MWAWEntry.hxx:47
@ Time
Definition: libmwaw_internal.hxx:401
MWAWVariable< Justification > m_justify
the justification
Definition: MWAWParagraph.hxx:167
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:551
virtual class which defines the ancestor of all text zone parser
Definition: MWAWParser.hxx:299
bool empty() const
small function to know if a zone is empty
Definition: WordMakerParser.cxx:77
int m_numPicture
the number of picture
Definition: WordMakerParser.cxx:94
MWAWFontConverterPtr & getFontConverter()
returns the font converter
Definition: MWAWParser.hxx:150
int m_id
the zone id
Definition: WordMakerParser.cxx:84
Internal: the subdocument of a WordMakerParser.
Definition: WordMakerParser.cxx:130
State()
constructor
Definition: WordMakerParser.cxx:101
State(State const &)=delete
void set(Script const &newscript)
sets the script position
Definition: MWAWFont.hxx:314
@ MWAW_T_WORDMAKER
WordMaker: v1.
Definition: MWAWDocument.hxx:241
bool createZones()
finds the different objects zones
Definition: WordMakerParser.cxx:282
void setPageSpan(const int pageSpan)
set the page span ( default 1)
Definition: MWAWPageSpan.hxx:268
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:129
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:842
void addDelimiter(long pos, char c)
adds a not breaking delimiter in position pos
Definition: MWAWDebug.cxx:73
bool checkHeader(MWAWHeader *header, bool strict=false) final
checks if the document header is correct (or not)
Definition: WordMakerParser.cxx:481
void setRelativePosition(AnchorTo anchor, XPos X=XLeft, YPos Y=YTop)
sets the relative position
Definition: MWAWPosition.hxx:237
MWAWVariable< std::vector< MWAWTabStop > > m_tabs
the tabulations
Definition: MWAWParagraph.hxx:162
~WordMakerParser() final
destructor
Definition: WordMakerParser.cxx:191
int m_numPages
the number of page of the final document
Definition: WordMakerParser.cxx:115
void setPage(int pg) const
sets the page
Definition: MWAWPosition.hxx:205
std::string m_DTFormat
the date/time format using strftime format if defined
Definition: libmwaw_internal.hxx:424
static Script sub100()
return a yposition which correspond to a basic subscript100
Definition: MWAWFont.hxx:125
@ boldBit
Definition: MWAWFont.hxx:190
This class contents the main functions needed to create a Word processing Document.
Definition: MWAWTextListener.hxx:65
Type m_type
the zone type
Definition: WordMakerParser.cxx:82
void setColor(MWAWColor color)
sets the font color
Definition: MWAWFont.hxx:341
bool open(std::string const &filename)
opens/creates a file to store a result
Definition: MWAWDebug.cxx:46
bool readFont(long len, MWAWFont &font)
try to read a font and its beginning position
Definition: WordMakerParser.cxx:600
@ CENTER
Definition: MWAWParagraph.hxx:48
void setInterline(double value, librevenge::RVNGUnit unit, LineSpacingType type=Fixed)
set the interline
Definition: MWAWParagraph.hxx:129
Internal: small structure used to store a zone of a WordMakerParser.
Definition: WordMakerParser.cxx:61
long m_beginPos
the zone beginning in the file
Definition: WordMakerParser.cxx:88
@ WBackground
Definition: MWAWPosition.hxx:53
void setMarginBottom(const double marginBottom)
set the page bottom margin
Definition: MWAWPageSpan.hxx:208
the class to store a color
Definition: libmwaw_internal.hxx:192
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
MWAWVariable< double > m_spacings[3]
the line spacing
Definition: MWAWParagraph.hxx:156
class to store the paragraph properties
Definition: MWAWParagraph.hxx:85
void setMarginLeft(const double marginLeft)
set the page left margin
Definition: MWAWPageSpan.hxx:193
void parse(MWAWListenerPtr &listener, libmwaw::SubDocumentType type) final
the parser function
Definition: WordMakerParser.cxx:158
Zone * m_currentZone
the current zone
Definition: WordMakerParser.cxx:120
@ Simple
Definition: MWAWFont.hxx:49
std::vector< MWAWEntry > m_pictureList
the list of document picture entries
Definition: WordMakerParser.cxx:124
static MWAWPictData * get(MWAWInputStreamPtr const &input, int size)
checks if the data pointed by input is known
Definition: MWAWPictData.hxx:108
the AppleŠ printer information : TPrint
Definition: MWAWPrinter.hxx:82
MWAWTextListenerPtr & getTextListener()
returns the text listener
Definition: MWAWParser.hxx:145
the main class to read a WordMaker file
Definition: WordMakerParser.hxx:63
void addNote(char const *note)
adds a note in the file, in actual position
Definition: MWAWDebug.cxx:59
abstract class used to store a subdocument (with a comparison function)
Definition: MWAWSubDocument.hxx:42
MWAWVariable< double > m_margins[3]
the margins
Definition: MWAWParagraph.hxx:148
bool m_hasTitlePage
true if the document has a title page
Definition: WordMakerParser.cxx:86
@ Z_HEADER
Definition: WordMakerParser.cxx:63
@ DECIMAL
Definition: MWAWParagraph.hxx:48
long m_numCharacter
the number of character
Definition: WordMakerParser.cxx:90
libmwaw::DebugFile & ascii()
a DebugFile used to write what we recognize when we parse the document
Definition: MWAWParser.hxx:195
static Script super100()
return a yposition which correspond to a basic superscript100
Definition: MWAWFont.hxx:135
@ embossBit
Definition: MWAWFont.hxx:190
Zone(Type type)
constructor
Definition: WordMakerParser.cxx:65
Defines MWAWCell (cell content and format)
@ Date
Definition: libmwaw_internal.hxx:401
std::string const & asciiName() const
return the ascii file name
Definition: MWAWParser.hxx:232
class to store a tab use by MWAWParagraph
Definition: MWAWParagraph.hxx:46
void setFormLength(const double formLength)
set the total page length
Definition: MWAWPageSpan.hxx:178
SubDocumentType
Definition: libmwaw_internal.hxx:188
std::shared_ptr< MWAWInputStream > m_input
the input
Definition: MWAWSubDocument.hxx:77
void reset()
writes the current file and reset to zero
Definition: MWAWDebug.hxx:93
@ JustificationCenter
Definition: MWAWParagraph.hxx:90
bool readFontNames(long len)
try to read the fonts names
Definition: WordMakerParser.cxx:571
bool readParagraph(long len, MWAWParagraph ¶, MWAWFont &font)
try to read a paragraph (and its default font)
Definition: WordMakerParser.cxx:658
@ shadowBit
Definition: MWAWFont.hxx:191
void setTextListener(MWAWTextListenerPtr &listener)
sets the text listener
Definition: MWAWParser.cxx:158
void setAsciiName(char const *name)
Debugging: change the default ascii file.
Definition: MWAWParser.hxx:227
void skipZone(long beginPos, long endPos)
skips the file zone defined by beginPos-endPos
Definition: MWAWDebug.hxx:113
Internal: the state of a WordMakerParser.
Definition: WordMakerParser.cxx:99
T y() const
second element
Definition: libmwaw_internal.hxx:673
bool dumpFile(librevenge::RVNGBinaryData &data, char const *fileName)
a debug function to store in a datafile in the current directory WARNING: this function erase the fil...
Definition: MWAWDebug.cxx:193
void setFormWidth(const double formWidth)
set the total page width
Definition: MWAWPageSpan.hxx:183
T x() const
first element
Definition: libmwaw_internal.hxx:668
Class to define the position of an object (textbox, picture, ..) in the document.
Definition: MWAWPosition.hxx:48
void setBegin(long off)
sets the begin offset
Definition: MWAWEntry.hxx:67
bool readPrintInfo(long len)
try to read the printer information
Definition: WordMakerParser.cxx:517
std::shared_ptr< MWAWRSRCParser > MWAWRSRCParserPtr
a smart pointer of MWAWRSRCParser
Definition: libmwaw_internal.hxx:561
Wrapping m_wrapping
Wrapping.
Definition: MWAWPosition.hxx:278
long length() const
returns the length of the zone
Definition: MWAWEntry.hxx:93
bool operator!=(MWAWSubDocument const &doc) const final
operator!=
Definition: WordMakerParser.cxx:141
@ PageBreak
Definition: MWAWListener.hxx:58
void setStream(MWAWInputStreamPtr const &ip)
resets the input
Definition: MWAWDebug.hxx:81
Alignment m_alignment
the alignment ( left, center, ...)
Definition: MWAWParagraph.hxx:76
Definition: libmwaw_internal.hxx:144
std::string getDebugString(std::shared_ptr< MWAWFontConverter > &converter) const
returns a string which can be used for debugging
Definition: MWAWFont.cxx:181
@ Z_FOOTER
Definition: WordMakerParser.cxx:63
long begin() const
returns the begin offset
Definition: MWAWEntry.hxx:83
void setLength(long l)
sets the zone size
Definition: MWAWEntry.hxx:72
MWAWPageSpan const & getPageSpan() const
returns the actual page dimension
Definition: MWAWParser.hxx:160
MWAWBox2< float > MWAWBox2f
MWAWBox2 of float.
Definition: libmwaw_internal.hxx:1193
double m_position
the tab position
Definition: MWAWParagraph.hxx:74
void setId(int newId)
sets the font id
Definition: MWAWFont.hxx:264
a field
Definition: libmwaw_internal.hxx:399
@ PageNumber
Definition: libmwaw_internal.hxx:401
void setMarginTop(const double marginTop)
set the page top margin
Definition: MWAWPageSpan.hxx:203
bool read(MWAWInputStreamPtr input)
reads the struture in a file
Definition: MWAWPrinter.cxx:235
MWAWParserStatePtr getParserState()
returns the parser state
Definition: MWAWParser.hxx:113
bool readPicture(long len, MWAWEmbeddedObject &object, MWAWBox2f &bdbox, int &page)
try to read a picture (and its size)
Definition: WordMakerParser.cxx:775
~SubDocument() final
destructor
Definition: WordMakerParser.cxx:138
long end() const
returns the end offset
Definition: MWAWEntry.hxx:88
void setSize(float sz, bool isRelative=false)
sets the font size
Definition: MWAWFont.hxx:275
std::multimap< Zone::Type, Zone > m_typeToZoneMap
a map type to zone
Definition: WordMakerParser.cxx:122
MWAWBox2< int > MWAWBox2i
MWAWBox2 of int.
Definition: libmwaw_internal.hxx:1191
@ italicBit
Definition: MWAWFont.hxx:190
MWAWVariable< librevenge::RVNGUnit > m_marginsUnit
the margins INCH, ...
Definition: MWAWParagraph.hxx:150
MWAWInputStreamPtr & getInput()
returns the actual input
Definition: MWAWParser.hxx:123
Defines MWAWTextListener: the libmwaw word processor listener.
Internal: the structures of a WordMakerParser.
Definition: WordMakerParser.cxx:59
State & operator=(State const &)=default
@ Page
Definition: MWAWPosition.hxx:51
MWAWParser * m_parser
the main zone parser
Definition: MWAWSubDocument.hxx:75
bool sendZone(WordMakerParserInternal::Zone const &zone)
try to send the content of a zone
Definition: WordMakerParser.cxx:859
@ JustificationFull
Definition: MWAWParagraph.hxx:90
@ JustificationRight
Definition: MWAWParagraph.hxx:91
int m_actPage
the actual page
Definition: WordMakerParser.cxx:115
void addPos(long pos)
adds a new position in the file
Definition: MWAWDebug.cxx:53
void setMarginRight(const double marginRight)
set the page right margin
Definition: MWAWPageSpan.hxx:198
bool valid() const
returns true if the zone length is positive
Definition: MWAWEntry.hxx:99
T const & get() const
return the current value
Definition: libmwaw_internal.hxx:630
void setHeaderFooter(MWAWHeaderFooter const &headerFooter)
add a header/footer on some page
Definition: MWAWPageSpan.cxx:227
SubDocument(WordMakerParser &pars, MWAWInputStreamPtr const &input, Zone const &zone)
Definition: WordMakerParser.cxx:132
void parse(librevenge::RVNGTextInterface *documentInterface) final
virtual function used to parse the input
Definition: WordMakerParser.cxx:198
WordMakerParser(MWAWInputStreamPtr const &input, MWAWRSRCParserPtr const &rsrcParser, MWAWHeader *header)
constructor
Definition: WordMakerParser.cxx:179
MWAWVec2< T > size() const
the box size
Definition: libmwaw_internal.hxx:1067
std::shared_ptr< WordMakerParserInternal::State > m_state
the state
Definition: WordMakerParser.hxx:110
long m_endDataZone
the end data zone limit
Definition: WordMakerParser.cxx:118
@ Z_MAIN
Definition: WordMakerParser.cxx:63
std::shared_ptr< MWAWListener > MWAWListenerPtr
a smart pointer of MWAWListener
Definition: libmwaw_internal.hxx:553
Definition: MWAWDocument.hxx:57
void newPage()
adds a new page
Definition: WordMakerParser.cxx:820
bool readTabulations(long len, MWAWParagraph ¶)
try to read a list of tabulations
Definition: WordMakerParser.cxx:726
void setMargins(double margin, int wh=libmwaw::LeftBit|libmwaw::RightBit|libmwaw::TopBit|libmwaw::BottomBit)
set all the margins
Definition: MWAWPageSpan.hxx:213
@ RIGHT
Definition: MWAWParagraph.hxx:48
Class to store font.
Definition: MWAWFont.hxx:44
int m_numParagraph
the number of paragraph
Definition: WordMakerParser.cxx:92
MWAWVec2< int > MWAWVec2i
MWAWVec2 of int.
Definition: libmwaw_internal.hxx:838
std::stringstream DebugStream
a basic stream (if debug_with_files is not defined, does nothing)
Definition: MWAWDebug.hxx:61
void setUnderlineStyle(Line::Style style=Line::None, bool doReset=true)
sets the underline style ( by default, we also reset the style)
Definition: MWAWFont.hxx:466
Type
the zone type
Definition: WordMakerParser.cxx:63
A class which defines the page properties.
Definition: MWAWPageSpan.hxx:99
void resetTextListener()
resets the listener
Definition: MWAWParser.cxx:163
bool sendPicture(MWAWEntry const &entry)
try to send a picture
Definition: WordMakerParser.cxx:831
void createDocument(librevenge::RVNGTextInterface *documentInterface)
creates the listener which will be associated to the document
Definition: WordMakerParser.cxx:235
void setFlags(uint32_t fl)
sets the font attributes bold, ...
Definition: MWAWFont.hxx:325
Zone m_zone
the zone
Definition: WordMakerParser.cxx:155
Generated on Mon Jul 26 2021 00:00:00 for libmwaw by
doxygen 1.8.20