20#ifndef LIBREPCB_EDITOR_TEXTGRAPHICSITEM_H
21#define LIBREPCB_EDITOR_TEXTGRAPHICSITEM_H
37class GraphicsLayerList;
38class OriginCrossGraphicsItem;
39class PrimitiveTextGraphicsItem;
55 QGraphicsItem* parent =
nullptr) noexcept;
66 QPainterPath
shape() const noexcept override;
73 virtual QVariant
itemChange(GraphicsItemChange change,
74 const QVariant& value) noexcept override;
The Text class.
Definition text.h:48
The GraphicsLayerList class.
Definition graphicslayerlist.h:48
The OriginCrossGraphicsItem class.
Definition origincrossgraphicsitem.h:50
The PrimitiveTextGraphicsItem class is the graphical representation of a text.
Definition primitivetextgraphicsitem.h:52
The TextGraphicsItem class is the graphical representation of a librepcb::Text.
Definition textgraphicsitem.h:49
QScopedPointer< OriginCrossGraphicsItem > mOriginCrossGraphicsItem
Definition textgraphicsitem.h:82
std::optional< QString > mTextOverride
Definition textgraphicsitem.h:80
void updateText() noexcept
Definition textgraphicsitem.cpp:149
void setTextOverride(const std::optional< QString > &text) noexcept
Definition textgraphicsitem.cpp:88
void textEdited(const Text &text, Text::Event event) noexcept
Definition textgraphicsitem.cpp:120
virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value) noexcept override
Definition textgraphicsitem.cpp:106
void setOriginCrossVisible(bool visible) noexcept
Definition textgraphicsitem.cpp:83
Text & mText
Definition textgraphicsitem.h:78
const GraphicsLayerList & mLayers
Definition textgraphicsitem.h:79
QPainterPath shape() const noexcept override
Definition textgraphicsitem.cpp:100
QScopedPointer< PrimitiveTextGraphicsItem > mTextGraphicsItem
Definition textgraphicsitem.h:81
TextGraphicsItem(const TextGraphicsItem &other)=delete
Text::OnEditedSlot mOnEditedSlot
Definition textgraphicsitem.h:85
Text & getObj() noexcept
Definition textgraphicsitem.h:59
TextGraphicsItem()=delete
Definition occmodel.cpp:77