Go to the documentation of this file.
38 #ifndef MARINER_WRT_GRAPH
39 # define MARINER_WRT_GRAPH
44 #include <librevenge/librevenge.h>
114 void sendToken(
int zoneId,
long tokenId);
130 std::shared_ptr<MarinerWrtGraphInternal::State>
m_state;
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
void sendToken(int zoneId, long tokenId)
try to send a token
Definition: MarinerWrtGraph.cxx:554
@ Time
Definition: libmwaw_internal.hxx:401
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:551
bool hasPictBorders() const
return true if the picture has some border
Definition: MarinerWrtGraph.cxx:131
bool readTokenBlock0(MarinerWrtStruct const &data, MarinerWrtGraphInternal::Token &tkn, std::string &res)
try to read the first token zone ( which can contains some field text )
Definition: MarinerWrtGraph.cxx:1018
std::string m_extra
some extra data
Definition: MarinerWrtGraph.cxx:374
Zone()
constructor
Definition: MarinerWrtGraph.cxx:381
a note
Definition: libmwaw_internal.hxx:445
float getPatternPercent(int id) const
return the pattern percent which corresponds to an id (or -1)
Definition: MarinerWrtGraph.cxx:536
virtual ~MarinerWrtGraph()
destructor
Definition: MarinerWrtGraph.cxx:518
bool readToken(MarinerWrtEntry const &entry, int zoneId)
try to read a token zone (can be a picture or a field)
Definition: MarinerWrtGraph.cxx:815
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:129
long m_pictId
a picture id
Definition: MarinerWrtGraph.cxx:217
std::vector< Pattern > m_patternList
a list patternId -> percent
Definition: MarinerWrtGraph.cxx:419
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:842
MWAWColor m_pictBorderColor
the pict border color
Definition: MarinerWrtGraph.cxx:221
int m_refType
the zone to used type
Definition: MarinerWrtGraph.cxx:205
Type m_type
the border repetition
Definition: libmwaw_internal.hxx:385
@ Dash
Definition: libmwaw_internal.hxx:335
int m_ruleType
the rule type
Definition: MarinerWrtGraph.cxx:228
void setRelativePosition(AnchorTo anchor, XPos X=XLeft, YPos Y=YTop)
sets the relative position
Definition: MWAWPosition.hxx:237
std::string name() const
returns the entry name;
Definition: MarinerWrtParser.cxx:1541
long value(int i) const
returns the ith value (or 0 if it does not exists )
Definition: MarinerWrtParser.cxx:1594
MarinerWrtGraph * m_graphParser
the graph parser
Definition: MarinerWrtGraph.cxx:472
@ Simple
Definition: libmwaw_internal.hxx:335
bool m_parsed
a flag to know if the data has been sent
Definition: MarinerWrtGraph.cxx:372
std::ostream & operator<<(std::ostream &o, Token const &tkn)
Definition: MarinerWrtGraph.cxx:237
Internal: the struct use to store a token entry.
Definition: MarinerWrtGraph.cxx:107
static MWAWColor white()
return the white color
Definition: libmwaw_internal.hxx:250
@ BottomBit
Definition: libmwaw_internal.hxx:178
void sendPSZone(MarinerWrtGraphInternal::PSZone const &ps, MWAWPosition const &pos)
try to send a ps picture as pos
Definition: MarinerWrtGraph.cxx:778
Pattern(uint16_t const *pat, bool uniform)
constructor ( 4 uint16_t by pattern )
Definition: MarinerWrtGraph.cxx:74
int m_pictBorderType[4]
the pict border type
Definition: MarinerWrtGraph.cxx:223
a structure used to define a picture shape
Definition: MWAWGraphicShape.hxx:46
the class to store a color
Definition: libmwaw_internal.hxx:192
MarinerWrtGraph & operator=(MarinerWrtGraph const &orig)=delete
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
std::shared_ptr< MWAWSubDocument > MWAWSubDocumentPtr
a smart pointer of MWAWSubDocument
Definition: libmwaw_internal.hxx:565
static MWAWGraphicShape line(MWAWVec2f const &orign, MWAWVec2f const &dest)
static constructor to create a line
Definition: MWAWGraphicShape.cxx:228
void sendPicture(MarinerWrtGraphInternal::Token const &tkn)
try to send a picture token as char
Definition: MarinerWrtGraph.cxx:743
SubDocument(SubDocument const &orig)=delete
SubDocument & operator=(SubDocument const &orig)=delete
float m_percent
the percent color
Definition: MarinerWrtGraph.cxx:102
std::shared_ptr< MarinerWrtGraphInternal::State > m_state
the state
Definition: MarinerWrtGraph.hxx:130
bool sendPageGraphics()
try to send the page graphic
Definition: MarinerWrtGraph.cxx:1200
long m_id[2]
the token id and the graph? id
Definition: MarinerWrtGraph.cxx:196
@ None
Definition: libmwaw_internal.hxx:335
#define MWAW_FALLTHROUGH
Definition: libmwaw_internal.hxx:118
double m_width
the border total width in point
Definition: libmwaw_internal.hxx:387
void addNote(char const *note)
adds a note in the file, in actual position
Definition: MWAWDebug.cxx:59
friend std::ostream & operator<<(std::ostream &o, Token const &tkn)
operator<<
Definition: MarinerWrtGraph.cxx:237
abstract class used to store a subdocument (with a comparison function)
Definition: MWAWSubDocument.hxx:42
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:48
MWAWBox2f m_bdBox
the shape bdbox
Definition: MWAWGraphicShape.hxx:218
void sendRule(MarinerWrtGraphInternal::Token const &tkn)
try to send a rule
Definition: MarinerWrtGraph.cxx:649
@ Dot
Definition: libmwaw_internal.hxx:335
std::vector< unsigned char > m_data
the pattern data: a sequence of data: p[0..7,0],p[8..15,0]...p[0..7,1],p[8..15,1],...
Definition: MWAWGraphicStyle.hxx:363
int numPages() const
returns the number of pages
Definition: MarinerWrtGraph.cxx:527
bool operator!=(MWAWSubDocument const &doc) const final
operator!=
Definition: MarinerWrtGraph.cxx:497
Internal: the structures of a MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:62
void sendText(int zoneId)
ask the main parser to send a text zone
Definition: MarinerWrtGraph.cxx:548
MarinerWrtParser * m_mainParser
the main parser;
Definition: MarinerWrtGraph.hxx:133
Token()
constructor
Definition: MarinerWrtGraph.cxx:109
PSZone()
constructor
Definition: MarinerWrtGraph.cxx:349
@ PageCount
Definition: libmwaw_internal.hxx:401
Defines MWAWCell (cell content and format)
@ Date
Definition: libmwaw_internal.hxx:401
void parse(MWAWListenerPtr &listener, libmwaw::SubDocumentType type) final
the parser function
Definition: MarinerWrtGraph.cxx:481
bool readPostscript(MarinerWrtEntry const &entry, int zoneId)
try to read a postscript zone
Definition: MarinerWrtGraph.cxx:1124
a basic pattern used in a MWAWGraphicStyle:
Definition: MWAWGraphicStyle.hxx:277
int m_fieldType
the field type
Definition: MarinerWrtGraph.cxx:210
MWAWVec2f const & size() const
returns the frame size
Definition: MWAWPosition.hxx:135
static MWAWColor barycenter(float alpha, MWAWColor const &colA, float beta, MWAWColor const &colB)
return alpha*colA+beta*colB
Definition: libmwaw_internal.cxx:206
SubDocumentType
Definition: libmwaw_internal.hxx:188
friend std::ostream & operator<<(std::ostream &o, PSZone const &file)
operator<<
Definition: MarinerWrtGraph.cxx:358
std::shared_ptr< MWAWInputStream > m_input
the input
Definition: MWAWSubDocument.hxx:77
Internal: the struct use to store a ps zone of a MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:347
std::string m_extra
some extra data
Definition: MarinerWrtGraph.cxx:234
std::vector< double > m_widthsList
the different length used for each line/sep (if defined)
Definition: libmwaw_internal.hxx:391
bool decodeZone(std::vector< MarinerWrtStruct > &dataList, long numData=999999)
try to decode a zone
Definition: MarinerWrtParser.cxx:1440
MWAWEntry m_pictData
the picture data
Definition: MarinerWrtGraph.cxx:215
void skipZone(long beginPos, long endPos)
skips the file zone defined by beginPos-endPos
Definition: MWAWDebug.hxx:113
void setDefaultPatternList(int version)
set the default pattern map
Definition: MarinerWrtGraph.cxx:424
std::map< long, PSZone > m_psZoneMap
the map id->entry to a psfile
Definition: MarinerWrtGraph.cxx:389
bool m_parsed
true if the token has been send to a listener
Definition: MarinerWrtGraph.cxx:232
int version() const
returns the file version
Definition: MarinerWrtGraph.cxx:522
void getColor(MWAWColor &c) const
returns the font color
Definition: MWAWFont.hxx:336
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
bool m_uniform
a flag to know if the pattern is uniform or not
Definition: MarinerWrtGraph.cxx:98
float m_lineWidth
the linewidth
Definition: MWAWGraphicStyle.hxx:508
void endDocument(bool delayed=true) final
ends the actual document
Definition: MWAWGraphicListener.cxx:481
void setSize(MWAWVec2f const &sz)
sets the frame size
Definition: MWAWPosition.hxx:215
int m_rulePattern
the rule pattern
Definition: MarinerWrtGraph.cxx:230
~SubDocument() final
destructor
Definition: MarinerWrtGraph.cxx:462
Internal: the struct use to store a zone of a MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:379
the main class to read the graphic part of a Mariner Write file
Definition: MarinerWrtGraph.hxx:69
MarinerWrtGraph(MarinerWrtGraph const &orig)=delete
int m_highType
the high byte of the field type
Definition: MarinerWrtGraph.cxx:200
Class to define the position of an object (textbox, picture, ..) in the document.
Definition: MWAWPosition.hxx:48
a border
Definition: libmwaw_internal.hxx:333
bool isBlack() const
return true if the color is black
Definition: libmwaw_internal.hxx:284
uint32_t m_refId
the zone to used id
Definition: MarinerWrtGraph.cxx:207
MWAWVec2i m_dim
the dimension width x height
Definition: MWAWGraphicStyle.hxx:358
bool getBinaryResult(MWAWEmbeddedObject &result)
return the final graphic
Definition: MWAWGraphicEncoder.cxx:77
long length() const
returns the length of the zone
Definition: MWAWEntry.hxx:93
void setBorders(int wh, MWAWBorder const &border)
sets the cell border: wh=libmwaw::LeftBit|...
Definition: MWAWGraphicStyle.cxx:232
@ RightBit
Definition: libmwaw_internal.hxx:178
long m_id
an id
Definition: MarinerWrtGraph.cxx:370
float size() const
returns the font size
Definition: MWAWFont.hxx:270
long begin() const
returns the begin offset
Definition: MWAWEntry.hxx:83
void insertShape(MWAWPosition const &pos, MWAWGraphicShape const &shape, MWAWGraphicStyle const &style) final
adds a shape picture in given position
Definition: MWAWGraphicListener.cxx:1032
std::map< long, Token > m_tokenMap
the map id->token
Definition: MarinerWrtGraph.cxx:387
MWAWEntry m_pos
the file data position (for type=0 data )
Definition: MarinerWrtParser.hxx:122
the main class to read a Mariner Write file
Definition: MarinerWrtParser.hxx:135
void setPattern(Pattern const &pat, float opacity=1)
set the pattern
Definition: MWAWGraphicStyle.hxx:426
static MWAWColor black()
return the back color
Definition: libmwaw_internal.hxx:245
MWAWBox2< float > MWAWBox2f
MWAWBox2 of float.
Definition: libmwaw_internal.hxx:1193
int m_type
the field type
Definition: MarinerWrtGraph.cxx:198
std::string m_value
the token value
Definition: MarinerWrtGraph.cxx:212
int getZoneId(uint32_t fileId, bool &endNote)
return a zoneid corresponding to a fileId (or -1) and set the endnote flag
Definition: MarinerWrtParser.cxx:311
int m_type
the data type
Definition: MarinerWrtParser.hxx:124
Internal: the subdocument of a MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:451
a field
Definition: libmwaw_internal.hxx:399
@ PageNumber
Definition: libmwaw_internal.hxx:401
void flushExtra()
sends the data which have not yet been sent to the listener
Definition: MarinerWrtGraph.cxx:1205
std::map< int, Zone > m_zoneMap
a map id -> textZone
Definition: MarinerWrtGraph.cxx:417
void addPictBorder(MWAWGraphicStyle &style) const
add border properties
Definition: MarinerWrtGraph.cxx:138
@ Char
Definition: MWAWPosition.hxx:51
MWAWColor m_colors[2]
the two indexed colors
Definition: MWAWGraphicStyle.hxx:361
Style m_style
the border style
Definition: libmwaw_internal.hxx:380
a entry to store a zone structure
Definition: MarinerWrtParser.hxx:62
long end() const
returns the end offset
Definition: MWAWEntry.hxx:88
MWAWColor m_lineColor
the line color
Definition: MWAWGraphicStyle.hxx:516
void sendText(int zoneId)
ask the text parser to send a zone
Definition: MarinerWrtParser.cxx:324
bool isBasic() const
returns true if this corresponds to a simple container
Definition: MarinerWrtParser.hxx:113
main class used to define store librevenge::RVNGDrawingInterface lists of command in a librevenge::RV...
Definition: MWAWGraphicEncoder.hxx:56
long m_valPictId
a optional picture id
Definition: MarinerWrtGraph.cxx:219
Pattern()
constructor with default pattern
Definition: MarinerWrtGraph.cxx:67
@ LeftBit
Definition: libmwaw_internal.hxx:178
@ Double
Definition: libmwaw_internal.hxx:337
Internal: a struct used to read some field.
Definition: MarinerWrtParser.hxx:96
void startDocument() final
starts a new document
Definition: MWAWGraphicListener.cxx:470
Defines MWAWTextListener: the libmwaw word processor listener.
Internal: the struct use to store a pattern in MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:65
@ Page
Definition: MWAWPosition.hxx:51
std::shared_ptr< MWAWParserState > MWAWParserStatePtr
a smart pointer of MWAWParserState
Definition: libmwaw_internal.hxx:557
MarinerWrtGraph(MarinerWrtParser &parser)
constructor
Definition: MarinerWrtGraph.cxx:511
@ TopBit
Definition: libmwaw_internal.hxx:178
int m_id
the zone id
Definition: MarinerWrtGraph.cxx:474
MWAWGraphicStyle::Pattern m_pattern
the graphic style pattern
Definition: MarinerWrtGraph.cxx:100
void addPos(long pos)
adds a new position in the file
Definition: MWAWDebug.cxx:53
bool valid() const
returns true if the zone length is positive
Definition: MWAWEntry.hxx:99
Internal: the state of a MarinerWrtGraph.
Definition: MarinerWrtGraph.cxx:394
MWAWVec2i m_dim
the dimension
Definition: MarinerWrtGraph.cxx:202
MWAWEntry m_pos
the file position
Definition: MarinerWrtGraph.cxx:366
an interface used to insert comment in a binary file, written in ascii form (if debug_with_files is n...
Definition: MWAWDebug.hxx:66
@ FootNote
Definition: libmwaw_internal.hxx:447
float m_pictBorderWidth[4]
the pict border width
Definition: MarinerWrtGraph.cxx:225
std::shared_ptr< MWAWListener > MWAWListenerPtr
a smart pointer of MWAWListener
Definition: libmwaw_internal.hxx:553
AnchorTo m_anchorTo
anchor position
Definition: MWAWPosition.hxx:270
Class to store font.
Definition: MWAWFont.hxx:44
@ EndNote
Definition: libmwaw_internal.hxx:447
static MWAWGraphicShape rectangle(MWAWBox2f const &box, MWAWVec2f const &corners=MWAWVec2f(0, 0))
static constructor to create a rectangle
Definition: MWAWGraphicShape.hxx:120
MWAWColor m_color
the border color
Definition: libmwaw_internal.hxx:393
int m_type
a local type?
Definition: MarinerWrtGraph.cxx:368
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
Zone & getZone(int id)
return a reference to a textzone ( if zone not exists, created it )
Definition: MarinerWrtGraph.cxx:406
int m_numPages
Definition: MarinerWrtGraph.cxx:421
SubDocument(MarinerWrtGraph &pars, MWAWInputStreamPtr const &input, int id)
constructor
Definition: MarinerWrtGraph.cxx:454
State()
constructor
Definition: MarinerWrtGraph.cxx:396
This class contains the code needed to create Graphic document.
Definition: MWAWGraphicListener.hxx:60
MWAWParserStatePtr m_parserState
the parser state
Definition: MarinerWrtGraph.hxx:127
Generated on Fri Sep 18 2020 18:14:52 for libmwaw by
doxygen 1.8.20