33 #ifndef MWAW_GRAPHIC_SHAPE 34 # define MWAW_GRAPHIC_SHAPE 39 # include "librevenge/librevenge.h" 75 bool get(librevenge::RVNGPropertyList &pList,
MWAWVec2f const &orig)
const;
203 bool addPathTo(
MWAWVec2f const &orig, librevenge::RVNGPropertyListVector &propList)
const;
210 std::vector<PathData>
getPath(
bool forTransformation)
const;
static MWAWGraphicShape circle(MWAWBox2f const &box)
static constructor to create a circle
Definition: MWAWGraphicShape.hxx:126
Type getType() const
returns the type corresponding to a shape
Definition: MWAWGraphicShape.hxx:189
PathData(char type, MWAWVec2f const &x=MWAWVec2f(), MWAWVec2f const &x1=MWAWVec2f(), MWAWVec2f const &x2=MWAWVec2f())
constructor
Definition: MWAWGraphicShape.hxx:55
MWAWVec2f m_cornerWidth
the rectangle round corner
Definition: MWAWGraphicShape.hxx:219
MWAWGraphicShape()
constructor
Definition: MWAWGraphicShape.hxx:99
Definition: MWAWGraphicShape.hxx:49
std::vector< MWAWVec2f > m_vertices
the list of vertices for lines or polygons
Definition: MWAWGraphicShape.hxx:223
void translate(MWAWVec2f const &delta)
translate all the coordinate by delta
Definition: MWAWGraphicShape.cxx:94
std::vector< PathData > getPath(bool forTransformation) const
return a path corresponding to the shape
Definition: MWAWGraphicShape.cxx:596
Definition: MWAWGraphicShape.hxx:51
void scale(MWAWVec2f const &factor)
scale all the coordinate by a factor
Definition: MWAWGraphicShape.cxx:107
Definition: MWAWGraphicShape.hxx:49
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:47
static MWAWGraphicShape polyline(MWAWBox2f const &box)
static constructor to create a polyline
Definition: MWAWGraphicShape.hxx:154
static MWAWGraphicShape arc(MWAWBox2f const &box, MWAWBox2f const &circleBox, MWAWVec2f const &angles)
static constructor to create a arc
Definition: MWAWGraphicShape.hxx:134
Definition: MWAWGraphicShape.hxx:49
MWAWVec2f m_arcAngles
the start and end value which defines an arc
Definition: MWAWGraphicShape.hxx:221
Command
an enum used to define the interface command
Definition: MWAWGraphicShape.hxx:51
Command addTo(MWAWVec2f const &orig, bool asSurface, librevenge::RVNGPropertyList &propList) const
updates the propList to send to an interface
Definition: MWAWGraphicShape.cxx:457
MWAWBox2f m_formBox
the internal shape bdbox ( used for arc, circle to store the circle bdbox )
Definition: MWAWGraphicShape.hxx:217
Definition: MWAWGraphicShape.hxx:49
Definition: MWAWGraphicShape.hxx:51
static MWAWGraphicShape path(MWAWBox2f const &box)
static constructor to create a path
Definition: MWAWGraphicShape.hxx:170
bool m_sweep
sweep value ( A command)
Definition: MWAWGraphicShape.hxx:95
MWAWVec2f m_r
the radius ( A command)
Definition: MWAWGraphicShape.hxx:89
bool m_largeAngle
large angle ( A command)
Definition: MWAWGraphicShape.hxx:93
MWAWBox2f getBdBox() const
returns the basic bdbox
Definition: MWAWGraphicShape.hxx:194
Type
an enum used to define the shape type
Definition: MWAWGraphicShape.hxx:49
void rotate(float angle, MWAWVec2f const &delta)
rotate all the coordinate by angle (origin rotation) then translate coordinate
Definition: MWAWGraphicShape.cxx:120
Definition: MWAWGraphicShape.hxx:49
static MWAWGraphicShape rectangle(MWAWBox2f const &box, MWAWVec2f const &corners=MWAWVec2f(0, 0))
static constructor to create a rectangle
Definition: MWAWGraphicShape.hxx:117
Definition: MWAWGraphicShape.hxx:49
MWAWVec2f m_x1
x1 value
Definition: MWAWGraphicShape.hxx:85
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:838
float m_rotate
the rotate ( A command)
Definition: MWAWGraphicShape.hxx:91
Definition: MWAWGraphicShape.hxx:49
char m_type
the type: M, L, ...
Definition: MWAWGraphicShape.hxx:81
MWAWVec2f m_x2
x2 value
Definition: MWAWGraphicShape.hxx:87
Definition: MWAWGraphicShape.hxx:51
int cmp(PathData const &a) const
comparison function
Definition: MWAWGraphicShape.cxx:199
friend std::ostream & operator<<(std::ostream &o, PathData const &path)
a print operator
Definition: MWAWGraphicShape.cxx:59
void transform(MWAWTransformation const &matrix, float rotation)
multiply all the coordinate by a matrix
Definition: MWAWGraphicShape.cxx:141
std::string m_extra
extra data
Definition: MWAWGraphicShape.hxx:227
static MWAWGraphicShape line(MWAWVec2f const &orign, MWAWVec2f const &dest)
static constructor to create a line
Definition: MWAWGraphicShape.cxx:227
Definition: MWAWGraphicShape.hxx:51
Definition: MWAWGraphicShape.hxx:51
static MWAWGraphicShape pie(MWAWBox2f const &box, MWAWBox2f const &circleBox, MWAWVec2f const &angles)
static constructor to create a pie
Definition: MWAWGraphicShape.hxx:144
Definition: MWAWGraphicShape.hxx:49
a structure used to define a picture shape
Definition: MWAWGraphicShape.hxx:45
static MWAWGraphicShape polygon(MWAWBox2f const &box)
static constructor to create a polygon
Definition: MWAWGraphicShape.hxx:162
~MWAWGraphicShape()
destructor
Definition: MWAWGraphicShape.cxx:223
std::vector< PathData > m_path
the list of path component
Definition: MWAWGraphicShape.hxx:225
Definition: MWAWGraphicShape.hxx:49
Definition: MWAWGraphicShape.hxx:51
MWAWBox2f m_bdBox
the shape bdbox
Definition: MWAWGraphicShape.hxx:215
MWAWVec2f m_x
the main x value
Definition: MWAWGraphicShape.hxx:83
a simple path component
Definition: MWAWGraphicShape.hxx:53
static MWAWGraphicShape measure(MWAWVec2f const &orign, MWAWVec2f const &dest)
static constructor to create a measure
Definition: MWAWGraphicShape.cxx:245
Type m_type
the type
Definition: MWAWGraphicShape.hxx:213
bool addPathTo(MWAWVec2f const &orig, librevenge::RVNGPropertyListVector &propList) const
adds the shape path to a propListVector
Definition: MWAWGraphicShape.cxx:433
Definition: MWAWGraphicShape.hxx:49