TechDrawGui::QGIBalloonLabel Class Reference

#include <QGIViewBalloon.h>

Public Types

enum  { Type = QGraphicsItem::UserType + 141 }
 

Signals

void dragFinished ()
 
void dragging (bool)
 
void hover (bool state)
 
void selected (bool state)
 

Public Member Functions

virtual QRectF boundingRect () const override
 
QGCustomTextgetDimText (void)
 
QFont getFont (void)
 
virtual void mouseReleaseEvent (QGraphicsSceneMouseEvent *event) override
 
virtual void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=nullptr) override
 
 QGIBalloonLabel ()
 
void setColor (QColor c)
 
void setDimString (QString t)
 
void setDimString (QString t, qreal maxWidth)
 
void setDimText (QGCustomText *newText)
 
void setFont (QFont f)
 
void setLabelCenter ()
 
void setPosFromCenter (const double &xCenter, const double &yCenter)
 
void setPrettyNormal (void)
 
void setPrettyPre (void)
 
void setPrettySel (void)
 
int type () const override
 
double X () const
 
double Y () const
 
virtual ~QGIBalloonLabel ()=default
 

Public Attributes

bool hasHover
 
QGIViewBalloonparent
 
std::vector< intseps
 
bool verticalSep
 

Protected Member Functions

virtual void hoverEnterEvent (QGraphicsSceneHoverEvent *event) override
 
virtual void hoverLeaveEvent (QGraphicsSceneHoverEvent *event) override
 
virtual QVariant itemChange (GraphicsItemChange change, const QVariant &value) override
 
virtual void mouseDoubleClickEvent (QGraphicsSceneMouseEvent *event) override
 
virtual void mouseMoveEvent (QGraphicsSceneMouseEvent *event) override
 
virtual void mousePressEvent (QGraphicsSceneMouseEvent *event) override
 

Protected Attributes

QColor m_colNormal
 
bool m_ctrl
 
bool m_drag
 
QGCustomTextm_labelText
 
double posX
 
double posY
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
Type 

Constructor & Destructor Documentation

◆ QGIBalloonLabel()

QGIBalloonLabel::QGIBalloonLabel ( )

◆ ~QGIBalloonLabel()

virtual TechDrawGui::QGIBalloonLabel::~QGIBalloonLabel ( )
virtualdefault

Member Function Documentation

◆ boundingRect()

QRectF QGIBalloonLabel::boundingRect ( ) const
overridevirtual

◆ dragFinished

void TechDrawGui::QGIBalloonLabel::dragFinished ( )
signal

Referenced by mouseReleaseEvent().

◆ dragging

void TechDrawGui::QGIBalloonLabel::dragging ( bool  )
signal

Referenced by itemChange().

◆ getDimText()

QGCustomText * TechDrawGui::QGIBalloonLabel::getDimText ( void  )

◆ getFont()

QFont TechDrawGui::QGIBalloonLabel::getFont ( void  )

◆ hover

void TechDrawGui::QGIBalloonLabel::hover ( bool  state)
signal

Referenced by hoverEnterEvent(), and hoverLeaveEvent().

◆ hoverEnterEvent()

void QGIBalloonLabel::hoverEnterEvent ( QGraphicsSceneHoverEvent *  event)
overrideprotectedvirtual

◆ hoverLeaveEvent()

void QGIBalloonLabel::hoverLeaveEvent ( QGraphicsSceneHoverEvent *  event)
overrideprotectedvirtual

◆ itemChange()

QVariant QGIBalloonLabel::itemChange ( GraphicsItemChange  change,
const QVariant &  value 
)
overrideprotectedvirtual

◆ mouseDoubleClickEvent()

void QGIBalloonLabel::mouseDoubleClickEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotectedvirtual

◆ mouseMoveEvent()

void QGIBalloonLabel::mouseMoveEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotectedvirtual

◆ mousePressEvent()

void QGIBalloonLabel::mousePressEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotectedvirtual

References m_ctrl, and m_drag.

◆ mouseReleaseEvent()

void QGIBalloonLabel::mouseReleaseEvent ( QGraphicsSceneMouseEvent *  event)
overridevirtual

References dragFinished(), m_ctrl, and m_drag.

◆ paint()

void QGIBalloonLabel::paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option,
QWidget widget = nullptr 
)
overridevirtual

◆ selected

◆ setColor()

◆ setDimString() [1/2]

◆ setDimString() [2/2]

void QGIBalloonLabel::setDimString ( QString  t,
qreal  maxWidth 
)

References m_labelText.

◆ setDimText()

void TechDrawGui::QGIBalloonLabel::setDimText ( QGCustomText newText)

References m_labelText.

◆ setFont()

void QGIBalloonLabel::setFont ( QFont  f)

◆ setLabelCenter()

void QGIBalloonLabel::setLabelCenter ( )

◆ setPosFromCenter()

◆ setPrettyNormal()

void QGIBalloonLabel::setPrettyNormal ( void  )

◆ setPrettyPre()

void QGIBalloonLabel::setPrettyPre ( void  )

◆ setPrettySel()

void QGIBalloonLabel::setPrettySel ( void  )

◆ type()

int TechDrawGui::QGIBalloonLabel::type ( void  ) const
override

◆ X()

◆ Y()

Member Data Documentation

◆ hasHover

bool TechDrawGui::QGIBalloonLabel::hasHover

◆ m_colNormal

QColor TechDrawGui::QGIBalloonLabel::m_colNormal
protected

Referenced by setColor().

◆ m_ctrl

bool TechDrawGui::QGIBalloonLabel::m_ctrl
protected

◆ m_drag

bool TechDrawGui::QGIBalloonLabel::m_drag
protected

◆ m_labelText

◆ parent

◆ posX

double TechDrawGui::QGIBalloonLabel::posX
protected

Referenced by QGIBalloonLabel(), setLabelCenter(), and X().

◆ posY

double TechDrawGui::QGIBalloonLabel::posY
protected

Referenced by QGIBalloonLabel(), setLabelCenter(), and Y().

◆ seps

std::vector<int> TechDrawGui::QGIBalloonLabel::seps

◆ verticalSep


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