20#ifndef LIBREPCB_EDITOR_TEXTGRAPHICSITEM_H
21#define LIBREPCB_EDITOR_TEXTGRAPHICSITEM_H
37class IF_GraphicsLayerProvider;
38class OriginCrossGraphicsItem;
39class PrimitiveTextGraphicsItem;
55 QGraphicsItem* parent =
nullptr) noexcept;
65 QPainterPath
shape() const noexcept override;
72 virtual QVariant
itemChange(GraphicsItemChange change,
73 const QVariant& value) noexcept override;
The Text class.
Definition text.h:48
The IF_GraphicsLayerProvider class defines an interface for classes which provide layers.
Definition graphicslayer.h:111
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:81
std::optional< QString > mTextOverride
Definition textgraphicsitem.h:79
void updateText() noexcept
Definition textgraphicsitem.cpp:144
void setTextOverride(const std::optional< QString > &text) noexcept
Definition textgraphicsitem.cpp:83
void textEdited(const Text &text, Text::Event event) noexcept
Definition textgraphicsitem.cpp:115
virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value) noexcept override
Definition textgraphicsitem.cpp:101
Text & mText
Definition textgraphicsitem.h:77
QPainterPath shape() const noexcept override
Definition textgraphicsitem.cpp:95
QScopedPointer< PrimitiveTextGraphicsItem > mTextGraphicsItem
Definition textgraphicsitem.h:80
const IF_GraphicsLayerProvider & mLayerProvider
Definition textgraphicsitem.h:78
TextGraphicsItem(const TextGraphicsItem &other)=delete
Text::OnEditedSlot mOnEditedSlot
Definition textgraphicsitem.h:84
Text & getObj() noexcept
Definition textgraphicsitem.h:59
TextGraphicsItem()=delete
Definition occmodel.cpp:76