the main class to read/store pictures in a Pc MS Works document v5-8 More...
#include <WPS8Graph.h>
Public Member Functions | |
| WPS8Graph (WPS8Parser &parser) | |
| constructor More... | |
| ~WPS8Graph () | |
| destructor More... | |
| void | setListener (WPSContentListenerPtr &listen) |
| sets the listener More... | |
| void | computePositions () const |
| computes the final position of all found figures. More... | |
| int | numPages () const |
| returns the number page where we find a picture. In practice, 0/1 More... | |
| bool | sendObject (WPSPosition const &pos, int id, bool ole) |
| sends an object More... | |
| bool | sendIBGF (WPSPosition const &pos, int ibgfId) |
| sends data corresponding to a ibgf entry on a given pos position More... | |
| void | sendObjects (int page, int pageToIgnore=-2) |
| send all the objects of a given page: More... | |
Protected Member Functions | |
| int | version () const |
| returns the file version More... | |
| void | sendBorder (int borderId) |
| sends the border frames. More... | |
| void | storeObjects (std::vector< WPSOLEParserObject > const &objects, std::vector< int > const &ids) |
| adds a list of objects with given ids in the ole lists More... | |
| bool | readStructures (RVNGInputStreamPtr input) |
| finds all entries which correspond to some pictures, parses them and stores data More... | |
| bool | readPICT (RVNGInputStreamPtr input, WPSEntry const &entry) |
| reads a PICT/MEF4 entry : reads uncompressed picture of sx*sy of rgb More... | |
| bool | readIBGF (RVNGInputStreamPtr input, WPSEntry const &entry) |
| reads a IBGF zone: an entry to a background picture More... | |
| bool | readBDR (RVNGInputStreamPtr input, WPSEntry const &entry) |
| parsed BDR/WBDR zone: a complex border formed with 8 pictures More... | |
| bool | readMetaFile (RVNGInputStreamPtr input, long endPos, librevenge::RVNGBinaryData &pict) |
| reads METAFILE/CODE More... | |
| libwps::DebugFile & | ascii () |
| returns the debug file More... | |
Protected Attributes | |
| WPSContentListenerPtr | m_listener |
| the listener More... | |
| WPS8Parser & | m_mainParser |
| the main parser More... | |
| shared_ptr< WPS8GraphInternal::State > | m_state |
| the state More... | |
| libwps::DebugFile & | m_asciiFile |
| the ascii file More... | |
Private Member Functions | |
| WPS8Graph (WPS8Graph const &orig) | |
| WPS8Graph & | operator= (WPS8Graph const &orig) |
Friends | |
| class | WPS8Parser |
the main class to read/store pictures in a Pc MS Works document v5-8
This class must be associated with a WPS8Parser. It contains code to read the BDR/WBDR, PICT/MEF4, IBGF entries and to store the pictures which are found in the other ole parts.
|
explicit |
constructor
| WPS8Graph::~WPS8Graph | ( | ) |
destructor
|
private |
|
inlineprotected |
returns the debug file
Referenced by readBDR(), readIBGF(), readMetaFile(), and readPICT().
| void WPS8Graph::computePositions | ( | ) | const |
computes the final position of all found figures.
In reality, as all the pictures seemed to be given with characters positions, it does nothing
| int WPS8Graph::numPages | ( | ) | const |
returns the number page where we find a picture. In practice, 0/1
|
protected |
parsed BDR/WBDR zone: a complex border formed with 8 pictures
Referenced by readStructures().
|
protected |
reads a IBGF zone: an entry to a background picture
This small entry seems to contain only an identificator which pointed to a PICT Zone
Referenced by readStructures().
|
protected |
reads METAFILE/CODE
METAFILE/CODE see http://www.fileformat.info/format/wmf/egff.htm FIXME: we must also recognize the enhanced metafile format: EMF, if we want to read text which are created after 2007.
Referenced by readBDR(), and readPICT().
|
protected |
reads a PICT/MEF4 entry : reads uncompressed picture of sx*sy of rgb
This kind of entry seems mainly used to store a background picture
Referenced by readStructures().
|
protected |
finds all entries which correspond to some pictures, parses them and stores data
|
protected |
sends the border frames.
Actually, sends the eight consecutive pictures which form a border on 3 consecutive lines
Referenced by sendObjects().
| bool WPS8Graph::sendIBGF | ( | WPSPosition const & | pos, |
| int | ibgfId | ||
| ) |
sends data corresponding to a ibgf entry on a given pos position
| bool WPS8Graph::sendObject | ( | WPSPosition const & | pos, |
| int | id, | ||
| bool | ole | ||
| ) |
sends an object
| pos | the object position in the document |
| id | the object identificator |
| ole | indicated if we look for objects coming from a ole zone or objects coming from a Pict zone |
Referenced by sendIBGF().
| void WPS8Graph::sendObjects | ( | int | page, |
| int | pageToIgnore = -2 |
||
| ) |
send all the objects of a given page:
| page | if page < 0, sends all the pictures which have not been used, |
| pageToIgnore | pictures on this pages are not send |
As all the pictures seemed to be given with characters positions, this function only does something if page < 0.
|
inline |
sets the listener
|
protected |
adds a list of objects with given ids in the ole lists
|
protected |
returns the file version
|
friend |
|
protected |
the ascii file
|
protected |
the listener
Referenced by sendBorder(), sendObject(), and sendObjects().
|
protected |
the main parser
Referenced by readStructures(), and version().
|
mutableprotected |
the state
Referenced by computePositions(), numPages(), readBDR(), readIBGF(), readPICT(), sendBorder(), sendIBGF(), sendObject(), sendObjects(), storeObjects(), version(), and WPS8Graph().