an abstract class which defines basic formated picture ( AppleŠ Pict, DB3, ...) More...
#include <MWAWPictData.hxx>
Public Types | |
| enum | SubType { PictMac, DB3, Unknown } |
| the picture subtype More... | |
Public Member Functions | |
| virtual Type | getType () const |
| returns the picture type | |
| virtual SubType | getSubType () const =0 |
| returns the picture subtype | |
| virtual bool | getBinary (librevenge::RVNGBinaryData &res, std::string &s) const |
| returns the final librevenge::RVNGBinary data | |
| virtual bool | sure () const |
| returns true if we are relatively sure that the data are correct | |
| virtual bool | valid () const |
| returns true if the picture is valid | |
| bool | isEmpty () const |
| returns true if the picture is valid and has size 0 or contains no data | |
| virtual int | cmp (MWAWPict const &a) const |
| a virtual function used to obtain a strict order, must be redefined in the subs class | |
Static Public Member Functions | |
| static ReadResult | check (MWAWInputStreamPtr input, int size, MWAWBox2f &box) |
| checks if the data pointed by input is known | |
| static MWAWPictData * | get (MWAWInputStreamPtr input, int size) |
| checks if the data pointed by input is known | |
Protected Member Functions | |
| MWAWPictData () | |
| protected constructor: use check to construct a picture | |
| MWAWPictData (MWAWBox2f &) | |
Static Protected Member Functions | |
| static bool | createFileData (librevenge::RVNGBinaryData const &orig, librevenge::RVNGBinaryData &result) |
| a file pict can be created from the data pict by adding a header with size 512, this function do this conversion needed to return the final picture | |
| static ReadResult | checkOrGet (MWAWInputStreamPtr input, int size, MWAWBox2f &box, MWAWPictData **result=0L) |
| checks if the data pointed by input and of given size is a pict | |
Protected Attributes | |
| librevenge::RVNGBinaryData | m_data |
| the data size (without the empty header of 512 characters) | |
| bool | m_empty |
| some picture can be valid but empty | |
an abstract class which defines basic formated picture ( AppleŠ Pict, DB3, ...)
| MWAWPictData::MWAWPictData | ( | ) | [inline, protected] |
protected constructor: use check to construct a picture
| MWAWPictData::MWAWPictData | ( | MWAWBox2f & | ) | [inline, protected] |
| static ReadResult MWAWPictData::check | ( | MWAWInputStreamPtr | input, |
| int | size, | ||
| MWAWBox2f & | box | ||
| ) | [inline, static] |
checks if the data pointed by input is known
Referenced by GreatWksBMParser::checkHeader(), MacDrawParser::checkHeader(), MacDrawProParser::checkHeader(), MacDocParser::createZones(), MsWksGraphInternal::DataPict::getBinaryData(), MWAWOLEParser::parse(), MacWrtParser::readGraphic(), WriterPlsParser::readGraphic(), MoreParser::readGraphic(), ClarisWksGraph::readPICT(), MsWksTable::sendChart(), ActaText::sendGraphic(), FullWrtGraph::sendGraphic(), NisusWrtGraph::sendPageGraphics(), MacDocParser::sendPicture(), EDocParser::sendPicture(), TeachTxtParser::sendPicture(), DocMkrParser::sendPicture(), RagTimeParser::sendPicture(), and MsWrdParser::sendPicture().
| MWAWPictData::ReadResult MWAWPictData::checkOrGet | ( | MWAWInputStreamPtr | input, |
| int | size, | ||
| MWAWBox2f & | box, | ||
| MWAWPictData ** | result = 0L |
||
| ) | [static, protected] |
checks if the data pointed by input and of given size is a pict
Reimplemented in MWAWPictMac.
| virtual int MWAWPictData::cmp | ( | MWAWPict const & | a | ) | const [inline, virtual] |
a virtual function used to obtain a strict order, must be redefined in the subs class
Reimplemented from MWAWPict.
Reimplemented in MWAWPictDUnknown, MWAWPictDB3, and MWAWPictMac.
| bool MWAWPictData::createFileData | ( | librevenge::RVNGBinaryData const & | orig, |
| librevenge::RVNGBinaryData & | result | ||
| ) | [static, protected] |
a file pict can be created from the data pict by adding a header with size 512, this function do this conversion needed to return the final picture
Referenced by MWAWPictMac::getBinary(), and getBinary().
| static MWAWPictData* MWAWPictData::get | ( | MWAWInputStreamPtr | input, |
| int | size | ||
| ) | [inline, static] |
checks if the data pointed by input is known
Referenced by MsWksGraphInternal::DataPict::getBinaryData(), MWAWPictMac::parsePict1(), MWAWPictMac::parsePict2(), MindWrtParser::readGraphic(), MacWrtParser::readGraphic(), WriterPlsParser::readGraphic(), WriteNowText::readTokenV2(), MsWksTable::sendChart(), FullWrtGraph::sendGraphic(), ClarisDrawGraph::sendGroup(), ClarisDrawGraph::sendMainGroupChild(), LightWayTxtGraph::sendPICT(), GreatWksBMParser::sendPicture(), MacDocParser::sendPicture(), EDocParser::sendPicture(), TeachTxtParser::sendPicture(), DocMkrParser::sendPicture(), GreatWksGraph::sendPicture(), RagTimeParser::sendPicture(), WriteNowParser::sendPicture(), MsWrdParser::sendPicture(), MacWrtProParser::sendPicture(), ClarisWksGraph::sendPicture(), SuperPaintParser::sendPictures(), BeagleWksDRParser::sendPictures(), and MoreText::sendText().
| virtual bool MWAWPictData::getBinary | ( | librevenge::RVNGBinaryData & | res, |
| std::string & | s | ||
| ) | const [inline, virtual] |
returns the final librevenge::RVNGBinary data
Reimplemented from MWAWPict.
Reimplemented in MWAWPictMac.
| virtual SubType MWAWPictData::getSubType | ( | ) | const [pure virtual] |
returns the picture subtype
Implemented in MWAWPictDUnknown, MWAWPictDB3, and MWAWPictMac.
| virtual Type MWAWPictData::getType | ( | ) | const [inline, virtual] |
returns the picture type
Implements MWAWPict.
| bool MWAWPictData::isEmpty | ( | ) | const [inline] |
returns true if the picture is valid and has size 0 or contains no data
Referenced by MWAWPictMac::getBinary(), and getBinary().
| virtual bool MWAWPictData::sure | ( | ) | const [inline, virtual] |
returns true if we are relatively sure that the data are correct
| virtual bool MWAWPictData::valid | ( | ) | const [inline, virtual] |
returns true if the picture is valid
Reimplemented in MWAWPictDUnknown, MWAWPictDB3, and MWAWPictMac.
Referenced by getBinary().
librevenge::RVNGBinaryData MWAWPictData::m_data [protected] |
the data size (without the empty header of 512 characters)
Referenced by cmp(), MWAWPictMac::getBinary(), getBinary(), MWAWPictDB3::valid(), and MWAWPictDUnknown::valid().
bool MWAWPictData::m_empty [protected] |
some picture can be valid but empty
Referenced by cmp(), isEmpty(), MWAWPictDB3::MWAWPictDB3(), and MWAWPictDUnknown::MWAWPictDUnknown().