a structure used to define a picture shape More...
#include <MWAWGraphicShape.hxx>
| Classes | |
| struct | PathData | 
| a simple path component  More... | |
| Public Types | |
| enum | Type { Arc, Circle, Line, Measure, Rectangle, Path, Pie, Polygon, Polyline, ShapeUnknown } | 
| an enum used to define the shape type  More... | |
| enum | Command { C_Ellipse, C_Polyline, C_Rectangle, C_Path, C_Polygon, C_Bad } | 
| an enum used to define the interface command  More... | |
| Public Member Functions | |
| MWAWGraphicShape () | |
| constructor  More... | |
| MWAWGraphicShape (MWAWGraphicShape const &)=default | |
| MWAWGraphicShape & | operator= (MWAWGraphicShape const &)=default | 
| ~MWAWGraphicShape () | |
| destructor  More... | |
| void | translate (MWAWVec2f const &delta) | 
| translate all the coordinate by delta  More... | |
| void | scale (MWAWVec2f const &factor) | 
| rescale all the coordinate  More... | |
| MWAWGraphicShape | rotate (float angle, MWAWVec2f const ¢er) const | 
| return a new shape corresponding to a rotation from center.  More... | |
| MWAWGraphicShape | transform (MWAWTransformation const &matrix) const | 
| returns a new shape corresponding to a matrix transformation  More... | |
| Type | getType () const | 
| returns the type corresponding to a shape  More... | |
| MWAWBox2f | getBdBox () const | 
| returns the basic bdbox  More... | |
| MWAWBox2f | getBdBox (MWAWGraphicStyle const &style, bool moveToO=false) const | 
| returns the bdbox corresponding to a style  More... | |
| Command | addTo (MWAWVec2f const &orig, bool asSurface, librevenge::RVNGPropertyList &propList) const | 
| updates the propList to send to an interface  More... | |
| bool | addPathTo (MWAWVec2f const &orig, librevenge::RVNGPropertyListVector &propList) const | 
| adds the shape path to a propListVector  More... | |
| int | cmp (MWAWGraphicShape const &a) const | 
| compare two shapes  More... | |
| Static Public Member Functions | |
| static MWAWGraphicShape | line (MWAWVec2f const &orign, MWAWVec2f const &dest) | 
| static constructor to create a line  More... | |
| static MWAWGraphicShape | measure (MWAWVec2f const &orign, MWAWVec2f const &dest) | 
| static constructor to create a measure  More... | |
| static MWAWGraphicShape | rectangle (MWAWBox2f const &box, MWAWVec2f const &corners=MWAWVec2f(0, 0)) | 
| static constructor to create a rectangle  More... | |
| static MWAWGraphicShape | circle (MWAWBox2f const &box) | 
| static constructor to create a circle  More... | |
| static MWAWGraphicShape | arc (MWAWBox2f const &box, MWAWBox2f const &circleBox, MWAWVec2f const &angles) | 
| static constructor to create a arc  More... | |
| static MWAWGraphicShape | pie (MWAWBox2f const &box, MWAWBox2f const &circleBox, MWAWVec2f const &angles) | 
| static constructor to create a pie  More... | |
| static MWAWGraphicShape | polyline (MWAWBox2f const &box) | 
| static constructor to create a polyline  More... | |
| static MWAWGraphicShape | polygon (MWAWBox2f const &box) | 
| static constructor to create a polygon  More... | |
| static MWAWGraphicShape | path (MWAWBox2f const &box) | 
| static constructor to create a path  More... | |
| Public Attributes | |
| Type | m_type | 
| the type  More... | |
| MWAWBox2f | m_bdBox | 
| the shape bdbox  More... | |
| MWAWBox2f | m_formBox | 
| the internal shape bdbox ( used for arc, circle to store the circle bdbox )  More... | |
| MWAWVec2f | m_cornerWidth | 
| the rectangle round corner  More... | |
| MWAWVec2f | m_arcAngles | 
| the start and end value which defines an arc  More... | |
| std::vector< MWAWVec2f > | m_vertices | 
| the list of vertices for lines or polygons  More... | |
| std::vector< PathData > | m_path | 
| the list of path component  More... | |
| std::string | m_extra | 
| extra data  More... | |
| Protected Member Functions | |
| std::vector< PathData > | getPath (bool forTransformation) const | 
| return a path corresponding to the shape  More... | |
| Friends | |
| std::ostream & | operator<< (std::ostream &o, MWAWGraphicShape const &sh) | 
| a print operator  More... | |
a structure used to define a picture shape
| 
 | inline | 
constructor
| 
 | default | 
| MWAWGraphicShape::~MWAWGraphicShape | ( | ) | 
destructor
| bool MWAWGraphicShape::addPathTo | ( | MWAWVec2f const & | orig, | 
| librevenge::RVNGPropertyListVector & | propList | ||
| ) | const | 
adds the shape path to a propListVector
| MWAWGraphicShape::Command MWAWGraphicShape::addTo | ( | MWAWVec2f const & | orig, | 
| bool | asSurface, | ||
| librevenge::RVNGPropertyList & | propList | ||
| ) | const | 
updates the propList to send to an interface
Referenced by MWAWTextListener::insertShape(), MWAWPresentationListener::insertShape(), MWAWGraphicListener::insertShape(), and MWAWSpreadsheetListener::insertShape().
| 
 | inlinestatic | 
static constructor to create a arc
Referenced by ApplePictParser::drawPie(), MsWksGraph::getEntryPicture(), GreatWksGraph::readFrameHeader(), MacDrawProParser::readGeometryShapeData(), RagTime5Graph::readGraphicShape(), MacDraftParser::readObject(), MacDrawParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), and WingzGraph::sendShape().
| 
 | inlinestatic | 
static constructor to create a circle
Referenced by ApplePictParser::drawCircle(), RagTime5Graph::readGraphicShape(), MacDraftParser::readObject(), MacDrawParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), SuperPaintParser::readShape(), BeagleWksDRParser::readShapeDefinitions(), CricketDrawParser::send(), PowerPoint7Graph::sendFrame(), PowerPoint1Parser::sendFrame(), PowerPoint3Parser::sendFrame(), WingzGraph::sendShape(), MacDrawProParser::updateGeometryShape(), and FreeHandParserInternal::Shape::updateShape().
| int MWAWGraphicShape::cmp | ( | MWAWGraphicShape const & | a | ) | const | 
compare two shapes
| 
 | inline | 
returns the basic bdbox
Referenced by ApplePictParser::drawPolygon(), MacDrawParserInternal::Shape::getBdBox(), MacDraft5ParserInternal::Shape::getBdBox(), MacDraftParserInternal::Shape::getBdBox(), MacDrawProParserInternal::Shape::getBdBox(), RagTime5GraphInternal::Shape::getBdBox(), MWAWTextListener::insertShape(), CricketDrawParser::send(), MacDrawProParser::send(), PowerPoint7Graph::sendFrame(), PowerPoint1Parser::sendFrame(), PowerPoint3Parser::sendFrame(), MacDraft5ParserInternal::Shape::transform(), and MacDraftParserInternal::Shape::transform().
| MWAWBox2f MWAWGraphicShape::getBdBox | ( | MWAWGraphicStyle const & | style, | 
| bool | moveToO = false | ||
| ) | const | 
returns the bdbox corresponding to a style
| 
 | protected | 
return a path corresponding to the shape
Referenced by addPathTo(), rotate(), and transform().
| 
 | inline | 
returns the type corresponding to a shape
Referenced by MWAWTextListener::insertShape(), MWAWPresentationListener::insertShape(), MWAWGraphicListener::insertShape(), and MWAWSpreadsheetListener::insertShape().
| 
 | static | 
static constructor to create a line
Referenced by ApplePictParser::drawLine(), MsWksGraph::getEntryPicture(), measure(), GreatWksGraph::readFrameHeader(), RagTime5Graph::readGraphicShape(), MacDraftParser::readObject(), MacDrawParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), SuperPaintParser::readShape(), ClarisDrawGraph::readShape(), ClarisWksGraph::readShape(), BeagleWksDRParser::readShapeDefinitions(), CricketDrawParser::send(), RagTimeParser::sendBasicPicture(), HanMacWrdKGraph::sendEmptyPicture(), HanMacWrdJGraph::sendEmptyPicture(), MWAWTable::sendExtraLines(), PowerPoint7Graph::sendFrame(), PowerPoint1Parser::sendFrame(), PowerPoint3Parser::sendFrame(), MarinerWrtGraph::sendRule(), WingzGraph::sendShape(), MacDrawProParser::updateGeometryShape(), and FreeHandParserInternal::Shape::updateShape().
| 
 | static | 
static constructor to create a measure
Referenced by MacDraft5Parser::readObject().
| 
 | default | 
| 
 | inlinestatic | 
static constructor to create a path
Referenced by MsWksGraph::getEntryPicture(), GreatWksGraph::readFrameHeader(), CorelPainterParser::readPolygon(), rotate(), and transform().
| 
 | inlinestatic | 
static constructor to create a pie
Referenced by ApplePictParser::drawPie(), GreatWksGraph::readFrameHeader(), MacDrawProParser::readGeometryShapeData(), RagTime5Graph::readGraphicShape(), MacDraftParser::readObject(), MacDrawParser::readObject(), MacDraft5Parser::readObject(), SuperPaintParser::readShape(), ClarisDrawGraph::readShape(), ClarisWksGraph::readShape(), BeagleWksDRParser::readStyle(), PowerPoint3Parser::sendFrame(), WingzGraph::sendShape(), and PowerPoint7GraphInternal::FrameArc::updateShape().
| 
 | inlinestatic | 
static constructor to create a polygon
Referenced by MsWksGraph::getEntryPicture(), GreatWksGraph::readFrameHeader(), BeagleWksDRParser::readShapeDefinitions(), and WingzGraph::sendShape().
| 
 | inlinestatic | 
static constructor to create a polyline
Referenced by WingzGraph::sendShape().
| 
 | inlinestatic | 
static constructor to create a rectangle
Referenced by ApplePictParser::drawRectangle(), ApplePictParser::drawRoundRectangle(), GreatWksGraph::readFrameHeader(), RagTime5Graph::readGraphicShape(), MacDraftParser::readObject(), MacDrawParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), SuperPaintParser::readShape(), BeagleWksDRParser::readShapeDefinitions(), HanMacWrdKGraph::sendEmptyPicture(), HanMacWrdJGraph::sendEmptyPicture(), PowerPoint7Graph::sendFrame(), PowerPoint1Parser::sendFrame(), PowerPoint3Parser::sendFrame(), MarinerWrtGraph::sendRule(), WingzGraph::sendShape(), MacDrawProParser::updateGeometryShape(), and FreeHandParserInternal::Shape::updateShape().
| MWAWGraphicShape MWAWGraphicShape::rotate | ( | float | angle, | 
| MWAWVec2f const & | center | ||
| ) | const | 
return a new shape corresponding to a rotation from center.
Referenced by ClarisWksGraph::readShape(), PowerPoint7Graph::sendFrame(), PowerPoint3Parser::sendFrame(), MacDraft5ParserInternal::Shape::transform(), and MacDraftParserInternal::Shape::transform().
| void MWAWGraphicShape::scale | ( | MWAWVec2f const & | factor | ) | 
rescale all the coordinate
Referenced by PowerPoint7Graph::sendFrame(), PowerPoint3Parser::sendFrame(), CorelPainterParser::sendZone(), MacDraft5ParserInternal::Shape::transform(), MacDraftParserInternal::Shape::transform(), and transform().
| MWAWGraphicShape MWAWGraphicShape::transform | ( | MWAWTransformation const & | matrix | ) | const | 
returns a new shape corresponding to a matrix transformation
Referenced by CricketDrawParser::send(), and FreeHandParser::sendShape().
| void MWAWGraphicShape::translate | ( | MWAWVec2f const & | delta | ) | 
translate all the coordinate by delta
Referenced by ClarisWksGraph::readShape(), PowerPoint7Graph::sendFrame(), PowerPoint3Parser::sendFrame(), MacDraft5ParserInternal::Shape::transform(), MacDraftParserInternal::Shape::transform(), transform(), MacDraft5ParserInternal::Shape::translate(), and MacDraftParserInternal::Shape::translate().
| 
 | friend | 
a print operator
| MWAWVec2f MWAWGraphicShape::m_arcAngles | 
the start and end value which defines an arc
Referenced by addTo(), arc(), cmp(), getPath(), operator<<(), pie(), HanMacWrdJGraph::readShapeGraph(), and HanMacWrdKGraph::readShapeGraph().
| MWAWBox2f MWAWGraphicShape::m_bdBox | 
the shape bdbox
Referenced by addPathTo(), addTo(), arc(), circle(), cmp(), ApplePictParser::drawPolygon(), getBdBox(), line(), operator<<(), path(), pie(), polygon(), polyline(), GreatWksGraph::readFrameHeader(), MacDraftParser::readObject(), MacDraft5Parser::readObject(), MacDrawProParser::readRotationInObjectData(), CricketDrawParser::readShape(), ClarisDrawGraph::readShape(), ClarisWksGraph::readShape(), HanMacWrdJGraph::readShapeGraph(), HanMacWrdKGraph::readShapeGraph(), rectangle(), rotate(), scale(), MarinerWrtGraph::sendRule(), FreeHandParser::sendShape(), transform(), translate(), MacDrawProParser::updateGeometryShape(), and FreeHandParserInternal::Shape::updateShape().
| MWAWVec2f MWAWGraphicShape::m_cornerWidth | 
the rectangle round corner
Referenced by addTo(), cmp(), getPath(), operator<<(), MacDraftParser::readObject(), ClarisWksGraph::readShape(), HanMacWrdJGraph::readShapeGraph(), HanMacWrdKGraph::readShapeGraph(), BeagleWksDRParser::readStyle(), and rectangle().
| std::string MWAWGraphicShape::m_extra | 
extra data
Referenced by operator<<(), and ClarisWksGraph::readShape().
| MWAWBox2f MWAWGraphicShape::m_formBox | 
the internal shape bdbox ( used for arc, circle to store the circle bdbox )
Referenced by addTo(), arc(), circle(), cmp(), getPath(), operator<<(), pie(), GreatWksGraph::readFrameHeader(), MacDraftParser::readObject(), MacDraft5Parser::readObject(), MacDrawProParser::readRotationInObjectData(), ClarisWksGraph::readShape(), HanMacWrdJGraph::readShapeGraph(), HanMacWrdKGraph::readShapeGraph(), rectangle(), scale(), and translate().
| std::vector<PathData> MWAWGraphicShape::m_path | 
the list of path component
Referenced by addTo(), cmp(), getPath(), operator<<(), CorelPainterParser::readPolygon(), CricketDrawParser::readShape(), rotate(), scale(), transform(), translate(), and FreeHandParserInternal::Shape::updateShape().
| Type MWAWGraphicShape::m_type | 
the type
Referenced by addPathTo(), addTo(), arc(), circle(), MWAWGraphicShape::PathData::cmp(), cmp(), ApplePictParser::drawPolygon(), MWAWGraphicShape::PathData::get(), getBdBox(), PowerPoint7GraphInternal::State::getCustomShape(), PowerPoint3ParserInternal::State::getCustomShape(), ClarisWksGraphInternal::ZoneShape::getNumData(), getPath(), HanMacWrdKGraphInternal::ShapeGraph::getStyle(), getType(), MacDrawProParserInternal::Shape::isLine(), line(), measure(), MsWksGraphInternal::BasicShape::needExtraBorderWidth(), MacDrawProParserInternal::operator<<(), operator<<(), path(), pie(), polygon(), polyline(), GreatWksGraph::readFrameHeader(), MacDraftParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), ClarisWksGraph::readShape(), HanMacWrdJGraph::readShapeGraph(), HanMacWrdKGraph::readShapeGraph(), rectangle(), MWAWGraphicShape::PathData::rotate(), MWAWGraphicShape::PathData::scale(), MacDrawProParser::send(), ClarisDrawGraph::sendShape(), ClarisWksGraph::sendShape(), HanMacWrdJGraph::sendShapeGraph(), MWAWGraphicShape::PathData::transform(), PowerPoint7GraphInternal::FramePolygon::updateShape(), FreeHandParserInternal::Shape::updateShape(), PowerPoint3ParserInternal::Polygon::updateShape(), and GreatWksGraphInternal::FrameShape::updateStyle().
| std::vector<MWAWVec2f> MWAWGraphicShape::m_vertices | 
the list of vertices for lines or polygons
Referenced by addTo(), cmp(), ApplePictParser::drawPolygon(), PowerPoint7GraphInternal::State::getCustomShape(), PowerPoint3ParserInternal::State::getCustomShape(), getPath(), line(), operator<<(), MacDraftParser::readObject(), MacDraft5Parser::readObject(), CricketDrawParser::readShape(), HanMacWrdJGraph::readShapeGraph(), HanMacWrdKGraph::readShapeGraph(), scale(), translate(), PowerPoint7GraphInternal::FramePolygon::updateShape(), FreeHandParserInternal::Shape::updateShape(), and PowerPoint3ParserInternal::Polygon::updateShape().