Go to the documentation of this file.
34 #ifndef PIXELPAINT_PARSER
35 # define PIXELPAINT_PARSER
40 #include <librevenge/librevenge.h>
67 void parse(librevenge::RVNGDrawingInterface *documentInterface)
final;
74 void createDocument(librevenge::RVNGDrawingInterface *documentInterface);
101 std::shared_ptr<PixelPaintParserInternal::State>
m_state;
std::vector< MWAWColor > m_colorList
the color map
Definition: PixelPaintParser.cxx:66
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:551
bool readFileHeaderV1(bool onlyCheck=false)
try to read the v1 file header: bitmap size + some windows dimension + preferences
Definition: PixelPaintParser.cxx:195
void init()
inits all internal variables
Definition: PixelPaintParser.cxx:87
std::shared_ptr< MWAWGraphicListener > MWAWGraphicListenerPtr
a smart pointer of MWAWGraphicListener
Definition: libmwaw_internal.hxx:549
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
MWAWGraphicListenerPtr & getGraphicListener()
returns the graphic listener
Definition: MWAWParser.hxx:130
the main class to read a PixelPaint file or a PNTG file
Definition: PixelPaintParser.hxx:56
void setRelativePosition(AnchorTo anchor, XPos X=XLeft, YPos Y=YTop)
sets the relative position
Definition: MWAWPosition.hxx:237
@ MWAW_K_PAINT
bitmap graphic
Definition: MWAWDocument.hxx:84
bool open(std::string const &filename)
opens/creates a file to store a result
Definition: MWAWDebug.cxx:46
the class to store a color
Definition: libmwaw_internal.hxx:192
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
int version() const
returns the works version
Definition: MWAWParser.hxx:108
bool readColorMap(bool onlyCheck=false)
try to read the color map
Definition: PixelPaintParser.cxx:412
Internal: the structures of a PixelPaintParser.
Definition: PixelPaintParser.cxx:52
@ MWAW_T_PIXELPAINT
PixelPaint: v1-v2.1.
Definition: MWAWDocument.hxx:139
double getPageWidth() const
returns the page width (form width without margin )
Definition: MWAWPageSpan.hxx:157
void addNote(char const *note)
adds a note in the file, in actual position
Definition: MWAWDebug.cxx:59
double getMarginLeft() const
returns the left margin
Definition: MWAWPageSpan.hxx:132
libmwaw::DebugFile & ascii()
a DebugFile used to write what we recognize when we parse the document
Definition: MWAWParser.hxx:195
bool sendBitmap()
try to send a bitmap
Definition: PixelPaintParser.cxx:469
std::string const & asciiName() const
return the ascii file name
Definition: MWAWParser.hxx:232
Internal: the state of a PixelPaintParser.
Definition: PixelPaintParser.cxx:55
void reset()
writes the current file and reset to zero
Definition: MWAWDebug.hxx:93
double getMarginRight() const
returns the right margin
Definition: MWAWPageSpan.hxx:137
void setAsciiName(char const *name)
Debugging: change the default ascii file.
Definition: MWAWParser.hxx:227
bool checkHeader(MWAWHeader *header, bool strict=false) final
checks if the document header is correct (or not)
Definition: PixelPaintParser.cxx:830
bool createZones()
finds the different objects zones
Definition: PixelPaintParser.cxx:151
Class to define the position of an object (textbox, picture, ..) in the document.
Definition: MWAWPosition.hxx:48
bool readFileHeaderV2(bool onlyCheck=false)
try to read the v2 file header: unknown
Definition: PixelPaintParser.cxx:365
void setGraphicListener(MWAWGraphicListenerPtr &listener)
sets the graphic listener
Definition: MWAWParser.cxx:125
void setVersion(int vers)
sets the document's version
Definition: MWAWParser.hxx:206
std::shared_ptr< MWAWRSRCParser > MWAWRSRCParserPtr
a smart pointer of MWAWRSRCParser
Definition: libmwaw_internal.hxx:561
double getPageLength() const
returns the page length (form width without margin )
Definition: MWAWPageSpan.hxx:152
Wrapping m_wrapping
Wrapping.
Definition: MWAWPosition.hxx:278
void setStream(MWAWInputStreamPtr const &ip)
resets the input
Definition: MWAWDebug.hxx:81
Definition: libmwaw_internal.hxx:144
MWAWPageSpan const & getPageSpan() const
returns the actual page dimension
Definition: MWAWParser.hxx:160
PixelPaintParser(MWAWInputStreamPtr const &input, MWAWRSRCParserPtr const &rsrcParser, MWAWHeader *header)
constructor
Definition: PixelPaintParser.cxx:76
virtual class which defines the ancestor of all graphic zone parser
Definition: MWAWParser.hxx:251
~PixelPaintParser() final
destructor
Definition: PixelPaintParser.cxx:83
State()
constructor
Definition: PixelPaintParser.cxx:57
MWAWParserStatePtr getParserState()
returns the parser state
Definition: MWAWParser.hxx:113
MWAWBox2< int > MWAWBox2i
MWAWBox2 of int.
Definition: libmwaw_internal.hxx:1191
bool readPatternMap(bool onlyCheck=false)
try to read the color map
Definition: PixelPaintParser.cxx:438
bool readBitmapV1(bool onlyCheck=false)
try to read a bitmap(v1)
Definition: PixelPaintParser.cxx:489
std::shared_ptr< PixelPaintParserInternal::State > m_state
the state
Definition: PixelPaintParser.hxx:101
MWAWInputStreamPtr & getInput()
returns the actual input
Definition: MWAWParser.hxx:123
a bitmap of int to store indexed bitmap
Definition: MWAWPictBitmap.hxx:357
void parse(librevenge::RVNGDrawingInterface *documentInterface) final
virtual function used to parse the input
Definition: PixelPaintParser.cxx:100
@ Page
Definition: MWAWPosition.hxx:51
bool readBitmapV2(bool onlyCheck=false)
try to read a bitmap(v2)
Definition: PixelPaintParser.cxx:589
void addPos(long pos)
adds a new position in the file
Definition: MWAWDebug.cxx:53
@ WNone
Definition: MWAWPosition.hxx:53
void setMargins(double margin, int wh=libmwaw::LeftBit|libmwaw::RightBit|libmwaw::TopBit|libmwaw::BottomBit)
set all the margins
Definition: MWAWPageSpan.hxx:213
void createDocument(librevenge::RVNGDrawingInterface *documentInterface)
creates the listener which will be associated to the document
Definition: PixelPaintParser.cxx:128
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
std::shared_ptr< MWAWPict > m_bitmap
the bitmap
Definition: PixelPaintParser.cxx:68
void resetGraphicListener()
resets the listener
Definition: MWAWParser.cxx:130
MWAWVec2i m_bitmapSize
the bitmap size(v1)
Definition: PixelPaintParser.cxx:64
A class which defines the page properties.
Definition: MWAWPageSpan.hxx:99
This class contains the code needed to create Graphic document.
Definition: MWAWGraphicListener.hxx:60
Generated on Fri Sep 18 2020 18:14:52 for libmwaw by
doxygen 1.8.20