49 if (scale_factor.
x() == scale_factor.
y()) {
71 os <<
"LWVertex2D(location=" << a.
_location <<
" startWidth=" << a.
_startWidth <<
" startHeight=" <<
105 const Layer_CSPtr
layer,
106 const MetaInfo_CSPtr
metaInfo =
nullptr,
107 const Block_CSPtr
block =
nullptr
110 LWPolyline(
const LWPolyline_CSPtr other,
bool sameID =
false);
129 std::vector<LWVertex2D>
const &
vertex()
const {
140 double minDistanceToSnap,
141 int maxNumberOfSnapPoints)
const override;
181 virtual CADEntity_CSPtr
rotate(
const geo::Coordinate &rotation_center,
const double rotation_angle)
const override;
203 virtual CADEntity_CSPtr
modify(Layer_CSPtr layer,
const MetaInfo_CSPtr
metaInfo, Block_CSPtr
block)
const override;
209 std::vector<CADEntity_CSPtr>
const asEntities()
const;
216 ed.
visit(shared_from_this());
220 virtual std::map<unsigned int, lc::geo::Coordinate>
dragPoints()
const override;
virtual CADEntity_CSPtr modify(Layer_CSPtr layer, const MetaInfo_CSPtr metaInfo, Block_CSPtr block) const override
modify Return a new entity with the same ID bit with possible modified metainfo and/pr layer informat...
geo::Coordinate const & extrusionDirection() const
virtual CADEntity_CSPtr scale(const geo::Coordinate &scale_center, const geo::Coordinate &scale_factor) const override
scale, scales the entity
virtual CADEntity_CSPtr move(const geo::Coordinate &offset) const override
move, moves by an offset
double x() const
Returns x of Coordinate.
geo::Coordinate const location() const
std::vector< LWVertex2D > const & vertex() const
virtual void visit(entity::Line_CSPtr)=0
Layer_CSPtr layer() const
layer return the layer this entity is placed on
double y() const
Returns y of Coordinate.
Coordinate scale(const double &scale_factor) const
double startWidth() const
virtual geo::Coordinate nearestPointOnPath(const geo::Coordinate &coord) const override
Find the nearest point on the path for this entity for the coordinate coord The path of a entity that...
virtual void dispatch(EntityDispatch &ed) const override
virtual void accept(GeoEntityVisitor &v) const override
virtual std::map< unsigned int, lc::geo::Coordinate > dragPoints() const override
Get all points of the entity that can be dragged.
MetaInfo_CSPtr metaInfo() const
DECLARE_SHORT_SHARED_PTR(Document)
LWVertex2D(LWVertex2D const &other)
virtual CADEntity_CSPtr mirror(const geo::Coordinate &axis1, const geo::Coordinate &axis2) const override
LWPolyline(const std::vector< LWVertex2D > &vertex, double width, double elevation, double tickness, bool closed, geo::Coordinate const &extrusionDirection, const Layer_CSPtr layer, const MetaInfo_CSPtr metaInfo=nullptr, const Block_CSPtr block=nullptr)
virtual CADEntity_CSPtr rotate(const geo::Coordinate &rotation_center, const double rotation_angle) const override
rotate, rotate operation
Coordinate rotate(const Coordinate &angleVector) const
rotate around (0.,0.) with a given angle vector
std::tuple< geo::Coordinate, std::shared_ptr< const geo::Vector >, std::shared_ptr< const geo::Arc > > nearestPointOnPath2(const geo::Coordinate &coord) const
LWVertex2D(geo::Coordinate const location, double const bulge=0., double const startWidth=0., double const endWidth=0.)
friend std::ostream & operator<<(std::ostream &os, const LWVertex2D &a)
const geo::Coordinate _extrusionDirection
LWVertex2D const move(geo::Coordinate const &offset)
virtual CADEntity_CSPtr setDragPoints(std::map< unsigned int, lc::geo::Coordinate > dragPoints) const override
Return modified entity.
std::vector< CADEntity_CSPtr > _entities
Block_CSPtr block() const
Return the current entity block.
virtual const geo::Area boundingBox() const override
boundingBox of the entity
LWVertex2D const rotate(const geo::Coordinate &rotation_center, double rotation_angle)
virtual CADEntity_CSPtr copy(const geo::Coordinate &offset) const override
copy, copies by an offset
const std::vector< LWVertex2D > _vertex
geo::Coordinate _location
virtual std::vector< EntityCoordinate > snapPoints(const geo::Coordinate &coord, const SimpleSnapConstrain &constrain, double minDistanceToSnap, int maxNumberOfSnapPoints) const override
Find a number of snap points the line has available This function returns a ordered list...
LWVertex2D const scale(const geo::Coordinate &scale_center, const geo::Coordinate &scale_factor)
void generateEntities()
Generate entities of the polyline.
std::vector< CADEntity_CSPtr > const asEntities() const