20 #ifndef LIBREPCB_CORE_STROKETEXT_H 21 #define LIBREPCB_CORE_STROKETEXT_H 26 #include "../geometry/path.h" 27 #include "../serialization/serializableobjectlist.h" 28 #include "../types/alignment.h" 29 #include "../types/angle.h" 30 #include "../types/length.h" 31 #include "../types/point.h" 32 #include "../types/stroketextspacing.h" 82 bool mirrored,
bool autoRotate) noexcept;
109 bool setText(
const QString& text) noexcept;
132 return !(*
this == rhs);
156 static constexpr
const char* tagname =
"stroke_text";
bool setLineSpacing(const StrokeTextSpacing &spacing) noexcept
Definition: stroketext.cpp:192
const Layer & getLayer() const noexcept
Definition: stroketext.h:88
const UnsignedLength & getStrokeWidth() const noexcept
Definition: stroketext.h:92
bool setPosition(const Point &pos) noexcept
Definition: stroketext.cpp:142
const QString & getText() const noexcept
Definition: stroketext.h:102
Signal< StrokeText, Event > onEdited
Definition: stroketext.h:70
Angle mRotation
Definition: stroketext.h:141
bool setHeight(const PositiveLength &height) noexcept
Definition: stroketext.cpp:162
Uuid mUuid
Definition: stroketext.h:137
bool setStrokeWidth(const UnsignedLength &strokeWidth) noexcept
Definition: stroketext.cpp:172
bool setText(const QString &text) noexcept
Definition: stroketext.cpp:132
bool setMirrored(bool mirrored) noexcept
Definition: stroketext.cpp:212
The Alignment class.
Definition: alignment.h:115
StrokeTextSpacing mLetterSpacing
Definition: stroketext.h:144
const StrokeTextSpacing & getLineSpacing() const noexcept
Definition: stroketext.h:96
Definition: occmodel.cpp:76
bool setAutoRotate(bool autoRotate) noexcept
Definition: stroketext.cpp:222
StrokeTextSpacing mLineSpacing
Definition: stroketext.h:145
Definition: stroketext.h:155
const Alignment & getAlign() const noexcept
Definition: stroketext.h:99
PositiveLength mHeight
Definition: stroketext.h:142
The Layer class provides all supported geometry layers.
Definition: layer.h:40
The StrokeText class.
Definition: stroketext.h:51
bool setLayer(const Layer &layer) noexcept
Definition: stroketext.cpp:122
const StrokeTextSpacing & getLetterSpacing() const noexcept
Definition: stroketext.h:93
bool setRotation(const Angle &rotation) noexcept
Definition: stroketext.cpp:152
const Layer * mLayer
Definition: stroketext.h:138
The Angle class is used to represent an angle (for example 12.75 degrees)
Definition: angle.h:76
bool getAutoRotate() const noexcept
Definition: stroketext.h:101
Event
Definition: stroketext.h:56
Slot< StrokeText, Event > OnEditedSlot
Definition: stroketext.h:71
bool operator!=(const StrokeText &rhs) const noexcept
Definition: stroketext.h:131
Represents the letter- or line spacing configuration of a stroke text.
Definition: stroketextspacing.h:44
bool operator==(const StrokeText &rhs) const noexcept
Definition: stroketext.cpp:259
const Point & getPosition() const noexcept
Definition: stroketext.h:89
bool mAutoRotate
Definition: stroketext.h:148
StrokeText & operator=(const StrokeText &rhs) noexcept
Definition: stroketext.cpp:275
The Point class is used to represent a point/coordinate/vector, for example (1.2mm; 5...
Definition: point.h:78
bool getMirrored() const noexcept
Definition: stroketext.h:100
void serialize(SExpression &root) const
Serialize into librepcb::SExpression node.
Definition: stroketext.cpp:236
bool setAlign(const Alignment &align) noexcept
Definition: stroketext.cpp:202
const Angle & getRotation() const noexcept
Definition: stroketext.h:90
QString mText
Definition: stroketext.h:139
~StrokeText() noexcept
Definition: stroketext.cpp:100
The Signal class is used to emit signals on non-QObject derived classes.
Definition: signalslot.h:65
type_safe::constrained_type< Length, PositiveLengthConstraint, PositiveLengthVerifier > PositiveLength
Definition: length.h:785
QVector< Path > generatePaths(const StrokeFont &font) const noexcept
Definition: stroketext.cpp:107
UnsignedLength mStrokeWidth
Definition: stroketext.h:143
Point mPosition
Definition: stroketext.h:140
The Uuid class is a replacement for QUuid to get UUID strings without {} braces.
Definition: uuid.h:56
const Uuid & getUuid() const noexcept
Definition: stroketext.h:87
The StrokeFont class.
Definition: strokefont.h:54
const PositiveLength & getHeight() const noexcept
Definition: stroketext.h:91
The SExpression class.
Definition: sexpression.h:66
bool setLetterSpacing(const StrokeTextSpacing &spacing) noexcept
Definition: stroketext.cpp:182
bool mMirrored
Definition: stroketext.h:147
Alignment mAlign
Definition: stroketext.h:146
type_safe::constrained_type< Length, UnsignedLengthConstraint, UnsignedLengthVerifier > UnsignedLength
Definition: length.h:670