MWAWPict Class Referenceabstract

Generic function used to define/store a picture. More...

#include <MWAWPict.hxx>

Inheritance diagram for MWAWPict:
MWAWPictBitmap MWAWPictData MWAWPictBitmapBW MWAWPictBitmapColor MWAWPictBitmapIndexed MWAWPictDB3 MWAWPictDUnknown MWAWPictMac

Public Types

enum  Type { PictData, Bitmap, Unknown }
 the different picture types: More...
 
enum  ReadResult { MWAW_R_BAD =0, MWAW_R_OK, MWAW_R_OK_EMPTY, MWAW_R_MAYBE }
 an enum to defined the result of a parsing use by some picture's classes which can read their data More...
 

Public Member Functions

virtual ~MWAWPict ()
 virtual destructor More...
 
virtual Type getType () const =0
 returns the picture type More...
 
Box2f getBdBox () const
 returns the bdbox of the picture More...
 
void setBdBox (Box2f const &box)
 sets the bdbox of the picture More...
 
virtual bool getBinary (WPXBinaryData &, std::string &) const
 tries to convert the picture in a binary data : More...
 
virtual int cmp (MWAWPict const &a) const
 a virtual function used to obtain a strict order, must be redefined in the subs class More...
 

Protected Member Functions

void extendBDBox (float val)
 udaptes the bdbox, by extended it by (val-previousVal) More...
 
 MWAWPict ()
 protected constructor must not be called directly More...
 
 MWAWPict (MWAWPict const &p)
 protected constructor must not be called directly More...
 
MWAWPictoperator= (MWAWPict const &p)
 protected operator= must not be called directly More...
 

Static Protected Member Functions

static Box2f getBdBox (int numPt, Vec2f const *pt)
 computes the minimum and maximum of a list of point More...
 

Private Attributes

Box2f m_bdbox
 the bdbox (min and max pt) More...
 
float m_bdBoxExt
 the actual extension of the original box, More...
 

Detailed Description

Generic function used to define/store a picture.

Member Enumeration Documentation

an enum to defined the result of a parsing use by some picture's classes which can read their data

  • R_OK_EMPTY: data ok but empty content,
  • R_MAYBE: can not check if the data are valid
  • ...
Enumerator
MWAW_R_BAD 
MWAW_R_OK 
MWAW_R_OK_EMPTY 
MWAW_R_MAYBE 

the different picture types:

  • pictData: a classic format of file (AppleŠ Pict, ...)
  • bitmap: a image
  • ...
Enumerator
PictData 
Bitmap 
Unknown 

Constructor & Destructor Documentation

virtual MWAWPict::~MWAWPict ( )
inlinevirtual

virtual destructor

MWAWPict::MWAWPict ( )
inlineprotected

protected constructor must not be called directly

MWAWPict::MWAWPict ( MWAWPict const &  p)
inlineprotected

protected constructor must not be called directly

Member Function Documentation

virtual int MWAWPict::cmp ( MWAWPict const &  a) const
inlinevirtual

a virtual function used to obtain a strict order, must be redefined in the subs class

Reimplemented in MWAWPictBitmapColor, MWAWPictBitmapIndexed, MWAWPictBitmapBW, MWAWPictDUnknown, MWAWPictBitmap, MWAWPictDB3, MWAWPictData, and MWAWPictMac.

Referenced by MWAWPictData::cmp(), and MWAWPictBitmap::cmp().

void MWAWPict::extendBDBox ( float  val)
inlineprotected

udaptes the bdbox, by extended it by (val-previousVal)

Referenced by MWAWPictMac::MWAWPictMac().

Box2f MWAWPict::getBdBox ( ) const
inline

returns the bdbox of the picture

static Box2f MWAWPict::getBdBox ( int  numPt,
Vec2f const *  pt 
)
inlinestaticprotected

computes the minimum and maximum of a list of point

virtual bool MWAWPict::getBinary ( WPXBinaryData &  ,
std::string &   
) const
inlinevirtual

tries to convert the picture in a binary data :

  • either a basic image/pict
  • or an encrypted pict in ODG : "image/mwaw-odg"

Reimplemented in MWAWPictBitmap, MWAWPictData, and MWAWPictMac.

virtual Type MWAWPict::getType ( ) const
pure virtual

returns the picture type

Implemented in MWAWPictBitmap, and MWAWPictData.

Referenced by cmp().

MWAWPict& MWAWPict::operator= ( MWAWPict const &  p)
inlineprotected

protected operator= must not be called directly

void MWAWPict::setBdBox ( Box2f const &  box)
inline

sets the bdbox of the picture

Referenced by MWAWPictData::get(), and MWAWPictBitmap::MWAWPictBitmap().

Member Data Documentation

Box2f MWAWPict::m_bdbox
private

the bdbox (min and max pt)

Referenced by cmp(), getBdBox(), operator=(), and setBdBox().

float MWAWPict::m_bdBoxExt
private

the actual extension of the original box,

Referenced by extendBDBox(), getBdBox(), and operator=().


The documentation for this class was generated from the following file:

Generated on Tue Mar 10 2015 17:32:10 for libmwaw by doxygen 1.8.5