an abstract class which defines basic picture (a line, a rectangle, ...) More...
#include <MWAWPictBasic.hxx>
Public Types | |
enum | SubType { Line, Rectangle, Polygon, Circle, Arc, Path } |
the picture subtype ( line, rectangle, polygon, circle, arc) More... | |
![]() | |
enum | Type { Basic, PictData, Bitmap, OleContainer, 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 | ~MWAWPictBasic () |
virtual destructor More... | |
virtual Type | getType () const |
returns the picture type More... | |
virtual SubType | getSubType () const =0 |
returns the picture subtype More... | |
void | setLineWidth (float w) |
sets the line width (by default 1.0) More... | |
void | setLineColor (MWAWColor const col) |
sets the line color. More... | |
void | setSurfaceColor (MWAWColor const col, bool hasColor=true) |
sets the surface color. More... | |
bool | hasSurfaceColor () const |
virtual bool | getBinary (WPXBinaryData &data, std::string &s) const |
returns the final representation in encoded odg (if possible) More... | |
virtual bool | getODGBinary (WPXBinaryData &) const |
virtual function which tries to convert the picture in ODG and put the result in a WPXBinaryData More... | |
virtual int | cmp (MWAWPict const &a) const |
a virtual function used to obtain a strict order. More... | |
![]() | |
virtual | ~MWAWPict () |
virtual destructor More... | |
Box2f | getBdBox () const |
returns the bdbox of the picture More... | |
void | setBdBox (Box2f const &box) |
sets the bdbox of the picture More... | |
Protected Member Functions | |
virtual void | getGraphicStyleProperty (WPXPropertyList &list) const =0 |
function to implement in subclass in order to get the graphics style More... | |
void | getStyle1DProperty (WPXPropertyList &list) const |
returns the basic style property for 1D form (line, ...) More... | |
void | getStyle2DProperty (WPXPropertyList &list) const |
returns the basic style property for 2D form (line, ...) More... | |
void | startODG (MWAWPropertyHandlerEncoder &doc) const |
adds the odg header knowing the minPt and the maxPt More... | |
void | endODG (MWAWPropertyHandlerEncoder &doc) const |
adds the odg footer More... | |
void | extendBDBox (float val, int id) |
a function to extend the bdbox More... | |
MWAWPictBasic () | |
protected constructor must not be called directly More... | |
MWAWPictBasic (MWAWPictBasic const &p) | |
protected constructor must not be called directly More... | |
MWAWPictBasic & | operator= (MWAWPictBasic const &p) |
protected= must not be called directly More... | |
![]() | |
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... | |
MWAWPict & | operator= (MWAWPict const &p) |
protected operator= must not be called directly More... | |
Private Attributes | |
float | m_lineWidth |
the linewidth More... | |
MWAWColor | m_lineColor |
the line color More... | |
MWAWColor | m_surfaceColor |
the line color More... | |
bool | m_surfaceHasColor |
true if the surface has some color More... | |
float | m_extend [2] |
m_extend[0]: from lineWidth, m_extend[1]: came from extra data More... | |
Additional Inherited Members | |
![]() | |
static Box2f | getBdBox (int numPt, Vec2f const *pt) |
computes the minimum and maximum of a list of point More... | |
an abstract class which defines basic picture (a line, a rectangle, ...)
|
inlinevirtual |
virtual destructor
|
inlineprotected |
protected constructor must not be called directly
|
inlineprotected |
protected constructor must not be called directly
|
inlinevirtual |
a virtual function used to obtain a strict order.
Reimplemented from MWAWPict.
Reimplemented in MWAWPictPolygon, MWAWPictPath, MWAWPictArc, MWAWPictCircle, MWAWPictRectangle, and MWAWPictLine.
Referenced by MWAWPictLine::cmp(), MWAWPictRectangle::cmp(), MWAWPictCircle::cmp(), MWAWPictArc::cmp(), MWAWPictPath::cmp(), and MWAWPictPolygon::cmp().
|
protected |
adds the odg footer
Referenced by MWAWPictLine::getODGBinary(), MWAWPictRectangle::getODGBinary(), MWAWPictCircle::getODGBinary(), MWAWPictArc::getODGBinary(), MWAWPictPath::getODGBinary(), and MWAWPictPolygon::getODGBinary().
|
inlineprotected |
a function to extend the bdbox
Referenced by MWAWPictLine::setArrow(), and setLineWidth().
|
inlinevirtual |
returns the final representation in encoded odg (if possible)
Reimplemented from MWAWPict.
Referenced by MRWGraph::sendRule().
|
protectedpure virtual |
function to implement in subclass in order to get the graphics style
Implemented in MWAWPictPolygon, MWAWPictPath, MWAWPictArc, MWAWPictCircle, MWAWPictRectangle, and MWAWPictLine.
Referenced by startODG().
|
inlinevirtual |
virtual function which tries to convert the picture in ODG and put the result in a WPXBinaryData
Reimplemented in MWAWPictPolygon, MWAWPictPath, MWAWPictArc, MWAWPictCircle, MWAWPictRectangle, and MWAWPictLine.
Referenced by getBinary().
|
protected |
returns the basic style property for 1D form (line, ...)
Referenced by MWAWPictLine::getGraphicStyleProperty(), MWAWPictArc::getGraphicStyleProperty(), MWAWPictPath::getGraphicStyleProperty(), MWAWPictPolygon::getGraphicStyleProperty(), and getStyle2DProperty().
|
protected |
returns the basic style property for 2D form (line, ...)
Referenced by MWAWPictRectangle::getGraphicStyleProperty(), MWAWPictCircle::getGraphicStyleProperty(), MWAWPictPath::getGraphicStyleProperty(), and MWAWPictPolygon::getGraphicStyleProperty().
|
pure virtual |
returns the picture subtype
Implemented in MWAWPictPolygon, MWAWPictPath, MWAWPictArc, MWAWPictCircle, MWAWPictRectangle, and MWAWPictLine.
Referenced by cmp().
|
inlinevirtual |
returns the picture type
Implements MWAWPict.
|
inline |
|
inlineprotected |
protected= must not be called directly
|
inline |
sets the line color.
default values : black
Referenced by MSKGraphInternal::BasicForm::getBinaryData(), and MRWGraph::sendRule().
|
inline |
sets the line width (by default 1.0)
Referenced by MSKGraphInternal::BasicForm::getBinaryData(), MWAWPictBasic(), and MRWGraph::sendRule().
|
inline |
sets the surface color.
default value white
Referenced by MSKGraphInternal::BasicForm::getBinaryData().
|
protected |
adds the odg header knowing the minPt and the maxPt
Referenced by MWAWPictLine::getODGBinary(), MWAWPictRectangle::getODGBinary(), MWAWPictCircle::getODGBinary(), MWAWPictArc::getODGBinary(), MWAWPictPath::getODGBinary(), and MWAWPictPolygon::getODGBinary().
|
private |
m_extend[0]: from lineWidth, m_extend[1]: came from extra data
Referenced by cmp(), extendBDBox(), MWAWPictBasic(), and operator=().
|
private |
the line color
Referenced by cmp(), getStyle1DProperty(), operator=(), and setLineColor().
|
private |
the linewidth
Referenced by cmp(), getStyle1DProperty(), operator=(), and setLineWidth().
|
private |
the line color
Referenced by cmp(), getStyle2DProperty(), operator=(), and setSurfaceColor().
|
private |
true if the surface has some color
Referenced by cmp(), getStyle2DProperty(), hasSurfaceColor(), operator=(), and setSurfaceColor().