LibrePCB Developers Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TextGraphicsItem Class Referencefinal

The TextGraphicsItem class is the graphical representation of a librepcb::Text. More...

#include <textgraphicsitem.h>

+ Inheritance diagram for TextGraphicsItem:
+ Collaboration diagram for TextGraphicsItem:

Public Member Functions

 TextGraphicsItem ()=delete
 
 TextGraphicsItem (const TextGraphicsItem &other)=delete
 
 TextGraphicsItem (Text &text, const IF_GraphicsLayerProvider &lp, QGraphicsItem *parent=nullptr) noexcept
 
 ~TextGraphicsItem () noexcept
 
TextgetText () noexcept
 
TextGraphicsItemoperator= (const TextGraphicsItem &rhs)=delete
 
- Public Member Functions inherited from PrimitiveTextGraphicsItem
 PrimitiveTextGraphicsItem (const PrimitiveTextGraphicsItem &other)=delete
 
 PrimitiveTextGraphicsItem (QGraphicsItem *parent=nullptr) noexcept
 
virtual ~PrimitiveTextGraphicsItem () noexcept
 
void setPosition (const Point &pos) noexcept
 
void setRotation (const Angle &rot) noexcept
 
void setText (const QString &text) noexcept
 
void setHeight (const PositiveLength &height) noexcept
 
void setAlignment (const Alignment &align) noexcept
 
void setFont (Font font) noexcept
 
void setLayer (const GraphicsLayer *layer) noexcept
 
void layerColorChanged (const GraphicsLayer &layer, const QColor &newColor) noexceptoverride
 
void layerHighlightColorChanged (const GraphicsLayer &layer, const QColor &newColor) noexceptoverride
 
void layerVisibleChanged (const GraphicsLayer &layer, bool newVisible) noexceptoverride
 
void layerEnabledChanged (const GraphicsLayer &layer, bool newEnabled) noexceptoverride
 
void layerDestroyed (const GraphicsLayer &layer) noexceptoverride
 
QRectF boundingRect () const noexceptoverride
 
QPainterPath shape () const noexceptoverride
 
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0) noexceptoverride
 
PrimitiveTextGraphicsItemoperator= (const PrimitiveTextGraphicsItem &rhs)=delete
 
- Public Member Functions inherited from IF_GraphicsLayerObserver
virtual ~IF_GraphicsLayerObserver ()
 

Private Member Functions

void textLayerNameChanged (const GraphicsLayerName &newLayerName) noexceptoverride
 
void textTextChanged (const QString &newText) noexceptoverride
 
void textPositionChanged (const Point &newPos) noexceptoverride
 
void textRotationChanged (const Angle &newRot) noexceptoverride
 
void textHeightChanged (const PositiveLength &newHeight) noexceptoverride
 
void textAlignChanged (const Alignment &newAlign) noexceptoverride
 

Private Attributes

TextmText
 
const IF_GraphicsLayerProvidermLayerProvider
 
QScopedPointer
< OriginCrossGraphicsItem
mOriginCrossGraphicsItem
 

Additional Inherited Members

- Public Types inherited from PrimitiveTextGraphicsItem
enum  Font
 
- Protected Member Functions inherited from IF_TextObserver
 IF_TextObserver () noexcept
 
 IF_TextObserver (const IF_TextObserver &other)=delete
 
virtual ~IF_TextObserver () noexcept
 
IF_TextObserveroperator= (const IF_TextObserver &rhs)=delete
 

Detailed Description

The TextGraphicsItem class is the graphical representation of a librepcb::Text.

Author
ubruhin
Date
2017-05-28

Constructor & Destructor Documentation

TextGraphicsItem ( )
delete
TextGraphicsItem ( const TextGraphicsItem other)
delete
TextGraphicsItem ( Text text,
const IF_GraphicsLayerProvider lp,
QGraphicsItem *  parent = nullptr 
)
noexcept
~TextGraphicsItem ( )
noexcept

+ Here is the call graph for this function:

Member Function Documentation

Text& getText ( )
inlinenoexcept

+ Here is the caller graph for this function:

TextGraphicsItem& operator= ( const TextGraphicsItem rhs)
delete
void textLayerNameChanged ( const GraphicsLayerName newLayerName)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

void textTextChanged ( const QString &  newText)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

void textPositionChanged ( const Point newPos)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

void textRotationChanged ( const Angle newRot)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

void textHeightChanged ( const PositiveLength newHeight)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

void textAlignChanged ( const Alignment newAlign)
overrideprivatevirtualnoexcept

Implements IF_TextObserver.

Member Data Documentation

Text& mText
private
const IF_GraphicsLayerProvider& mLayerProvider
private
QScopedPointer<OriginCrossGraphicsItem> mOriginCrossGraphicsItem
private

The documentation for this class was generated from the following files: