20#ifndef LIBREPCB_CORE_TEXT_H
21#define LIBREPCB_CORE_TEXT_H
26#include "../serialization/serializableobjectlist.h"
27#include "../types/alignment.h"
28#include "../types/angle.h"
29#include "../types/length.h"
30#include "../types/point.h"
49 Q_DECLARE_TR_FUNCTIONS(
Text)
69 Text(
const Uuid& uuid,
const Layer& layer,
const QString& text,
86 bool setText(
const QString& text)
noexcept;
121 static constexpr const char*
tagname =
"text";
The Alignment class.
Definition alignment.h:115
The Angle class is used to represent an angle (for example 12.75 degrees)
Definition angle.h:76
The Layer class provides all supported geometry layers.
Definition layer.h:42
The Point class is used to represent a point/coordinate/vector, for example (1.2mm; 5....
Definition point.h:78
The SExpression class.
Definition sexpression.h:69
The Signal class is used to emit signals on non-QObject derived classes.
Definition signalslot.h:65
The Slot class is used to receive signals from non-QObject derived classes.
Definition signalslot.h:170
The Text class.
Definition text.h:48
bool setText(const QString &text) noexcept
Definition text.cpp:92
const Angle & getRotation() const noexcept
Definition text.h:79
bool setPosition(const Point &pos) noexcept
Definition text.cpp:102
~Text() noexcept
Definition text.cpp:75
bool operator==(const Text &rhs) const noexcept
Definition text.cpp:162
Signal< Text, Event > onEdited
Definition text.h:62
Uuid mUuid
Definition text.h:107
Event
Definition text.h:53
const PositiveLength & getHeight() const noexcept
Definition text.h:80
QString mText
Definition text.h:109
const Layer & getLayer() const noexcept
Definition text.h:77
Text & operator=(const Text &rhs) noexcept
Definition text.cpp:173
const Alignment & getAlign() const noexcept
Definition text.h:81
const QString & getText() const noexcept
Definition text.h:82
Angle mRotation
Definition text.h:111
bool setLayer(const Layer &layer) noexcept
Definition text.cpp:82
bool setHeight(const PositiveLength &height) noexcept
Definition text.cpp:122
const Point & getPosition() const noexcept
Definition text.h:78
void serialize(SExpression &root) const
Serialize into librepcb::SExpression node.
Definition text.cpp:146
PositiveLength mHeight
Definition text.h:112
const Uuid & getUuid() const noexcept
Definition text.h:76
bool operator!=(const Text &rhs) const noexcept
Definition text.h:103
Alignment mAlign
Definition text.h:113
bool setRotation(const Angle &rotation) noexcept
Definition text.cpp:112
const Layer * mLayer
Definition text.h:108
Slot< Text, Event > OnEditedSlot
Definition text.h:63
Point mPosition
Definition text.h:110
bool setAlign(const Alignment &align) noexcept
Definition text.cpp:132
The Uuid class is a replacement for QUuid to get UUID strings without {} braces.
Definition uuid.h:56
Definition occmodel.cpp:76
type_safe::constrained_type< Length, PositiveLengthConstraint, PositiveLengthVerifier > PositiveLength
Definition length.h:810
static constexpr const char * tagname
Definition text.h:121