LibreCAD
|
#include <text.h>
Public Member Functions | |
Text (const geo::Coordinate &insertion_point, const std::string text_value, const double height, const double angle, const std::string style, const TextConst::DrawingDirection textgeneration, const TextConst::HAlign halign, const TextConst::VAlign valign, const Layer_CSPtr layer, const MetaInfo_CSPtr metaInfo=nullptr, const Block_CSPtr block=nullptr) | |
Text, default constructor. More... | |
Text (const Text_CSPtr &other, bool sameID) | |
geo::Coordinate | insertion_point () const |
std::string const & | text_value () const |
double const | angle () const |
std::string const & | style () const |
TextConst::DrawingDirection const & | textgeneration () const |
TextConst::VAlign const & | valign () const |
TextConst::HAlign const & | halign () const |
double | height () const |
virtual CADEntity_CSPtr | move (const geo::Coordinate &offset) const override |
move, moves by an offset More... | |
virtual CADEntity_CSPtr | copy (const geo::Coordinate &offset) const override |
copy, copies line by an offset More... | |
virtual CADEntity_CSPtr | rotate (const geo::Coordinate &rotation_center, const double rotation_angle) const override |
rotate, rotate operation More... | |
virtual CADEntity_CSPtr | scale (const geo::Coordinate &scale_center, const geo::Coordinate &scale_factor) const override |
scale, scales the entity More... | |
virtual CADEntity_CSPtr | mirror (const geo::Coordinate &axis1, const geo::Coordinate &axis2) const override |
virtual const geo::Area | boundingBox () const override |
boundingBox of the entity More... | |
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 information #return new entity with same ID More... | |
virtual void | accept (GeoEntityVisitor &v) const override |
virtual void | dispatch (EntityDispatch &ed) const override |
virtual std::map< unsigned int, lc::geo::Coordinate > | dragPoints () const override |
Get all points of the entity that can be dragged. More... | |
virtual CADEntity_CSPtr | setDragPoints (std::map< unsigned int, lc::geo::Coordinate > dragPoints) const override |
Return modified entity. More... | |
![]() | |
CADEntity () | |
CADEntity (Layer_CSPtr layer, const MetaInfo_CSPtr metaInfo=nullptr, const Block_CSPtr block=nullptr) | |
CADEntity Constructor. More... | |
CADEntity (CADEntity_CSPtr cadEntity, bool sameID) | |
CADEntity (CADEntity_CSPtr cadEntity) | |
virtual | ~CADEntity ()=default |
Layer_CSPtr | layer () const |
layer return the layer this entity is placed on More... | |
template<typename T > | |
const std::shared_ptr< const T > | metaInfo (std::string metaName) const |
MetaInfo_CSPtr | metaInfo () const |
Block_CSPtr | block () const |
Return the current entity block. More... | |
![]() | |
ID () | |
Default constructor, provides a new unique ID to each entity. More... | |
ID (ID_DATATYPE) | |
virtual | ~ID ()=default |
ID_DATATYPE | id () const |
returns the ID of the entity More... | |
bool | operator== (const ID &id) const |
void | setID (ID_DATATYPE id) |
![]() | |
virtual | ~Visitable ()=default |
Public Attributes | |
const geo::Coordinate | _insertion_point |
const std::string | _text_value |
const double | _height |
const double | _angle |
const std::string | _style |
const TextConst::DrawingDirection | _textgeneration |
const TextConst::VAlign | _valign |
const TextConst::HAlign | _halign |
Additional Inherited Members | |
![]() | |
static std::atomic< ID_DATATYPE > | __idCounter |
![]() | |
CADEntity (const lc::builder::CADEntityBuilder &builder) | |
Text::Text | ( | const geo::Coordinate & | insertion_point, |
const std::string | text_value, | ||
const double | height, | ||
const double | angle, | ||
const std::string | style, | ||
const TextConst::DrawingDirection | textgeneration, | ||
const TextConst::HAlign | halign, | ||
const TextConst::VAlign | valign, | ||
const Layer_CSPtr | layer, | ||
const MetaInfo_CSPtr | metaInfo = nullptr , |
||
const Block_CSPtr | block = nullptr |
||
) |
Text, default constructor.
geo::Coordinate | insertion_point, insertion_point of the text |
double | height, height of the text |
string | text_value, the text itself |
double | angle, angle of obliqueness |
string | style, name of text style |
TextConst::DrawingDirection | textgeneration, Text drawing direction |
TextConst::HAlign | halign, Horizontal alignment |
TextConst::VAlign | valign, Vertical alignment |
Layer_CSPtr | layer, Layer of the entity |
metatypes | metatypes of the cad entity |
Definition at line 9 of file text.cpp.
Text::Text | ( | const Text_CSPtr & | other, |
bool | sameID | ||
) |
|
inlineoverridevirtual |
Reimplemented from lc::entity::CADEntity.
|
inline |
|
overridevirtual |
boundingBox of the entity
Implements lc::entity::CADEntity.
Definition at line 104 of file text.cpp.
|
overridevirtual |
copy, copies line by an offset
geo::Coordinate | offset |
Implements lc::entity::CADEntity.
Definition at line 57 of file text.cpp.
|
inlineoverridevirtual |
Implements lc::entity::CADEntity.
|
overridevirtual |
Get all points of the entity that can be dragged.
Implements lc::Draggable.
Definition at line 128 of file text.cpp.
|
inline |
|
inline |
|
inline |
|
inlineoverridevirtual |
Implements lc::entity::CADEntity.
|
overridevirtual |
modify Return a new entity with the same ID bit with possible modified metainfo and/pr layer information #return new entity with same ID
Implements lc::entity::CADEntity.
Definition at line 109 of file text.cpp.
|
overridevirtual |
move, moves by an offset
geo::Coordinate | offset |
Implements lc::entity::CADEntity.
Definition at line 42 of file text.cpp.
|
overridevirtual |
rotate, rotate operation
geo::Coordinate | rotation_center |
double | rotation_angle |
Implements lc::entity::CADEntity.
Definition at line 73 of file text.cpp.
|
overridevirtual |
scale, scales the entity
geo::Coordinate | scale_center |
double | scale_factor |
Implements lc::entity::CADEntity.
Definition at line 88 of file text.cpp.
|
overridevirtual |
Return modified entity.
dragPoints | Modified points |
Implements lc::Draggable.
Definition at line 136 of file text.cpp.
|
inline |
|
inline |
|
inline |
|
inline |
const TextConst::HAlign lc::entity::Text::_halign |
const geo::Coordinate lc::entity::Text::_insertion_point |
const TextConst::DrawingDirection lc::entity::Text::_textgeneration |
const TextConst::VAlign lc::entity::Text::_valign |