#include <QGIViewBalloon.h>
Public Types | |
enum | { Type = QGraphicsItem::UserType + 140 } |
Public Types inherited from TechDrawGui::QGIView | |
enum | { Type = QGraphicsItem::UserType + 101 } |
Public Slots | |
void | balloonLabelDragFinished (void) |
void | balloonLabelDragged (bool ctrl) |
void | hover (bool state) |
void | select (bool state) |
void | updateBalloon (bool obtuse=false) |
Public Slots inherited from TechDrawGui::QGIView | |
virtual void | onSourceChange (TechDraw::DrawView *newParent) |
Public Member Functions | |
virtual void | drawBorder () override |
virtual QGIBalloonLabel * | getBalloonLabel (void) |
QString | getLabelText (void) |
virtual QColor | getNormalColor (void) override |
virtual void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=nullptr) override |
void | placeBalloon (QPointF pos) |
int | prefDefaultArrow () const |
bool | prefOrthoPyramid () const |
QGIViewBalloon () | |
virtual void | setGroupSelection (bool b) override |
void | setPrettyNormal (void) |
void | setPrettyPre (void) |
void | setPrettySel (void) |
void | setViewPartFeature (TechDraw::DrawViewBalloon *obj) |
int | type () const override |
virtual void | updateView (bool update=false) override |
virtual | ~QGIViewBalloon ()=default |
Public Member Functions inherited from TechDrawGui::QGIView | |
virtual void | addArbitraryItem (QGraphicsItem *qgi) |
void | alignTo (QGraphicsItem *, const QString &alignment) |
virtual QRectF | boundingRect () const override |
virtual void | draw (void) |
virtual void | drawBorder (void) |
virtual void | drawCaption (void) |
QGIViewClip * | getClipGroup (void) |
virtual QColor | getCurrentColor (void) |
virtual bool | getFrameState (void) |
MDIViewPage * | getMDIViewPage (void) const |
virtual QColor | getNormalColor (void) |
virtual QColor | getPreColor (void) |
double | getScale (void) |
virtual QColor | getSelectColor (void) |
virtual QColor | getSettingColor (void) |
const char * | getViewName () const |
const std::string | getViewNameAsString () const |
TechDraw::DrawView * | getViewObject () const |
virtual void | isVisible (bool state) |
virtual bool | isVisible (void) |
void | makeMark (Base::Vector3d v, QColor c=Qt::red) |
void | makeMark (double x, double y, QColor c=Qt::red) |
void | makeMark (QPointF p, QColor c=Qt::red) |
void | mouseMoveEvent (QGraphicsSceneMouseEvent *event) override |
void | mousePressEvent (QGraphicsSceneMouseEvent *event) override |
void | mouseReleaseEvent (QGraphicsSceneMouseEvent *event) override |
virtual void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=nullptr) override |
QGIView () | |
virtual void | removeChild (QGIView *child) |
virtual void | rotateView (void) |
virtual void | setGroupSelection (bool b) |
void | setLocked (bool b) |
virtual void | setSettingColor (QColor c) |
void | setViewFeature (TechDraw::DrawView *obj) |
virtual void | toggleCache (bool state) |
int | type () const override |
virtual void | updateView (bool update=false) |
virtual | ~QGIView () |
void | setPosition (qreal x, qreal y) |
Methods to ensure that Y-Coordinates are orientated correctly. More... | |
qreal | getY () |
bool | isInnerView () |
void | isInnerView (bool state) |
double | getYInClip (double y) |
Public Attributes | |
TechDraw::DrawViewBalloon * | dvBalloon |
Public Attributes inherited from TechDrawGui::QGIView | |
boost::signals2::signal< void(QGIView *, QPointF)> | signalSelectPoint |
Protected Member Functions | |
void | draw () override |
void | drawBalloon (bool dragged=false) |
QString | getPrecision (void) |
TechDraw::DrawView * | getSourceView () const |
virtual QVariant | itemChange (GraphicsItemChange change, const QVariant &value) override |
virtual void | mouseMoveEvent (QGraphicsSceneMouseEvent *event) override |
virtual void | mousePressEvent (QGraphicsSceneMouseEvent *event) override |
virtual void | mouseReleaseEvent (QGraphicsSceneMouseEvent *event) override |
void | parentViewMousePressed (QGIView *view, QPointF pos) |
virtual void | setPens (void) |
virtual void | setSvgPens (void) |
Protected Member Functions inherited from TechDrawGui::QGIView | |
virtual QRectF | customChildrenBoundingRect (void) const |
void | dumpRect (const char *text, QRectF r) |
Base::Reference< ParameterGrp > | getParmGroupCol (void) |
QGIView * | getQGIVByName (std::string name) |
void | hoverEnterEvent (QGraphicsSceneHoverEvent *event) override |
void | hoverLeaveEvent (QGraphicsSceneHoverEvent *event) override |
QVariant | itemChange (GraphicsItemChange change, const QVariant &value) override |
Protected Attributes | |
QGIArrow * | arrow |
QGIBalloonLabel * | balloonLabel |
QGIDimLines * | balloonLines |
QGIDimLines * | balloonShape |
bool | hasHover |
bool | m_ctrl |
bool | m_dragInProgress |
double | m_lineWidth |
bool | m_obtuse |
bool | m_originDragged = false |
Base::Vector3d | m_saveOffset |
QGIView * | parent |
Protected Attributes inherited from TechDrawGui::QGIView | |
QHash< QString, QGraphicsItem * > | alignHash |
QGCustomBorder * | m_border |
QBrush | m_brush |
QGICaption * | m_caption |
QColor | m_colCurrent |
QColor | m_colNormal |
QColor | m_colPre |
QColor | m_colSel |
QColor | m_colSetting |
QPen | m_decorPen |
int | m_dragState |
QFont | m_font |
bool | m_innerView |
QGCustomLabel * | m_label |
QGCustomImage * | m_lock |
bool | m_locked |
double | m_lockHeight |
double | m_lockWidth |
QPen | m_pen |
std::string | viewName |
TechDraw::DrawView * | viewObj |
Additional Inherited Members | |
Static Public Member Functions inherited from TechDrawGui::QGIView | |
static int | calculateFontPixelSize (double sizeInMillimetres) |
static int | calculateFontPixelWidth (const QFont &font) |
static double | getDimFontSize (void) |
static QGSPage * | getGraphicsScene (TechDraw::DrawView *dv) |
static QGVPage * | getGraphicsView (TechDraw::DrawView *dv) |
static QString | getPrefFont (void) |
static double | getPrefFontSize (void) |
static Gui::ViewProvider * | getViewProvider (App::DocumentObject *obj) |
Static Public Attributes inherited from TechDrawGui::QGIView | |
static const double | DefaultFontSizeInMM = 5.0 |
|
explicit |
References arrow, balloonLabel, balloonLabelDragFinished(), balloonLabelDragged(), balloonLines, balloonShape, draftgeoutils.intersections::connect(), ZVALUE::DIMENSION, getNormalColor(), hover(), ZVALUE::LABEL, m_ctrl, TechDrawGui::QGIBalloonLabel::parent, prefDefaultArrow(), select(), TechDrawGui::QGIBalloonLabel::setColor(), TechDrawGui::QGIPrimPath::setFill(), TechDrawGui::QGIPrimPath::setFillColor(), TechDrawGui::QGIPrimPath::setFillOverride(), TechDrawGui::QGIPrimPath::setNormalColor(), TechDrawGui::QGIBalloonLabel::setPosFromCenter(), TechDrawGui::QGIPrimPath::setPrettyNormal(), TechDrawGui::QGIBalloonLabel::setPrettyNormal(), TechDrawGui::QGIArrow::setStyle(), and TechDrawGui::QGIPrimPath::setStyle().
|
virtualdefault |
|
slot |
References TechDrawGui::Rez::appX(), balloonLabel, Gui::Command::commitCommand(), Gui::Command::Doc, TechDraw::DrawView::getScale(), getSourceView(), TechDrawGui::QGIView::getViewObject(), m_dragInProgress, m_originDragged, m_saveOffset, Gui::Command::openCommand(), draftutils.translate::QT_TRANSLATE_NOOP, Base::Vector3< _Precision >::x, TechDrawGui::QGIBalloonLabel::X(), Base::Vector3< _Precision >::y, and TechDrawGui::QGIBalloonLabel::Y().
Referenced by QGIViewBalloon().
|
slot |
References drawBalloon(), getSourceView(), TechDrawGui::QGIView::getViewObject(), m_ctrl, m_dragInProgress, m_originDragged, and m_saveOffset.
Referenced by QGIViewBalloon().
|
overrideprotectedvirtual |
Reimplemented from TechDrawGui::QGIView.
References drawBalloon().
Referenced by hover(), itemChange(), placeBalloon(), select(), setViewPartFeature(), and updateView().
|
protected |
References arrow, balloonLabel, balloonLines, balloonShape, TechDrawGui::QGCustomText::boundingRect(), TechDraw::DrawViewBalloon::BubbleShape, Base::Console(), TechDrawGui::QGIArrow::draw(), TechDraw::DrawViewBalloon::EndType, TechDraw::DrawViewBalloon::EndTypeScale, Base::Persistence::getClassTypeId(), TechDrawGui::QGIBalloonLabel::getDimText(), TechDrawGui::QGIArrow::getOverlapAdjust(), TechDrawGui::QGIArrow::getPrefArrowSize(), TechDraw::DrawView::getScale(), App::PropertyEnumeration::getValue(), App::PropertyFloat::getValue(), App::PropertyQuantity::getValue(), App::PropertyEnumeration::getValueAsString(), TechDrawGui::QGIView::getViewObject(), TechDraw::DrawViewBalloon::getViewPart(), TechDrawGui::QGIView::getViewProvider(), TechDrawGui::Rez::guiX(), TechDraw::DrawViewPart::hasGeometry(), hasHover, Base::BaseClass::isDerivedFrom(), TechDraw::DrawView::isLocked(), TechDrawGui::QGIView::isVisible(), TechDraw::DrawViewBalloon::KinkLength, Base::ConsoleSingleton::Log(), m_lineWidth, m_originDragged, m_saveOffset, TechDraw::DrawViewBalloon::OriginX, TechDraw::DrawViewBalloon::OriginY, prefOrthoPyramid(), draftfunctions.scale::scale(), TechDrawGui::QGIBalloonLabel::seps, setPrettyNormal(), setPrettyPre(), setPrettySel(), TechDrawGui::QGIArrow::setSize(), TechDrawGui::QGIArrow::setStyle(), TechDraw::DrawViewBalloon::ShapeScale, TechDrawGui::QGIBalloonLabel::verticalSep, Base::Vector3< _Precision >::x, TechDraw::DrawView::X, TechDrawGui::QGIBalloonLabel::X(), Base::Vector3< _Precision >::y, TechDraw::DrawView::Y, and TechDrawGui::QGIBalloonLabel::Y().
Referenced by balloonLabelDragged(), and draw().
|
overridevirtual |
Reimplemented from TechDrawGui::QGIView.
|
virtual |
Referenced by TechDrawGui::MDIViewPage::clearSceneSelection().
QString TechDrawGui::QGIViewBalloon::getLabelText | ( | void | ) |
|
overridevirtual |
Reimplemented from TechDrawGui::QGIView.
References TechDrawGui::PreferencesGui::dimQColor(), TechDrawGui::QGIView::getViewObject(), TechDrawGui::QGIView::getViewProvider(), and TechDrawGui::QGIView::m_colNormal.
Referenced by QGIViewBalloon(), setViewPartFeature(), and updateView().
|
protected |
|
protected |
References App::PropertyLink::getValue(), TechDrawGui::QGIView::getViewObject(), and TechDraw::DrawViewBalloon::SourceView.
Referenced by balloonLabelDragFinished(), and balloonLabelDragged().
|
slot |
References draw(), and hasHover.
Referenced by QGIViewBalloon().
|
overrideprotectedvirtual |
References balloonLabel, draw(), and TechDrawGui::QGIView::itemChange().
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overridevirtual |
Reimplemented from TechDrawGui::QGIView.
References TechDrawGui::QGIView::paint(), setPens(), and setSvgPens().
|
protected |
void QGIViewBalloon::placeBalloon | ( | QPointF | pos | ) |
References TechDrawGui::Rez::appX(), balloonLabel, TechDrawGui::QGIView::calculateFontPixelSize(), draw(), TechDraw::DrawView::findParentPage(), TechDrawGui::QGIBalloonLabel::getFont(), TechDraw::DrawView::getScale(), TechDrawGui::QGIView::getViewObject(), TechDrawGui::QGIView::getViewProvider(), TechDrawGui::Rez::guiX(), TechDrawGui::QGIBalloonLabel::setDimString(), TechDrawGui::QGIBalloonLabel::setFont(), and TechDrawGui::QGIBalloonLabel::setPosFromCenter().
int QGIViewBalloon::prefDefaultArrow | ( | ) | const |
Referenced by QGIViewBalloon().
bool QGIViewBalloon::prefOrthoPyramid | ( | ) | const |
References App::GetApplication(), ParameterGrp::GetBool(), ParameterGrp::GetGroup(), and App::Application::GetUserParameter().
Referenced by drawBalloon().
|
slot |
References draw().
Referenced by QGIViewBalloon().
|
overridevirtual |
Reimplemented from TechDrawGui::QGIView.
References arrow, balloonLabel, and balloonLines.
|
protectedvirtual |
References arrow, balloonLines, balloonShape, m_lineWidth, and TechDrawGui::QGIPrimPath::setWidth().
Referenced by paint().
void QGIViewBalloon::setPrettyNormal | ( | void | ) |
References arrow, balloonLines, balloonShape, and TechDrawGui::QGIPrimPath::setPrettyNormal().
Referenced by drawBalloon().
void QGIViewBalloon::setPrettyPre | ( | void | ) |
References arrow, balloonLines, balloonShape, and TechDrawGui::QGIPrimPath::setPrettyPre().
Referenced by drawBalloon().
void QGIViewBalloon::setPrettySel | ( | void | ) |
References arrow, balloonLines, balloonShape, and TechDrawGui::QGIPrimPath::setPrettySel().
Referenced by drawBalloon().
|
protectedvirtual |
References arrow, balloonLines, balloonShape, TechDrawGui::QGIPrimPath::getWidth(), m_lineWidth, and TechDrawGui::QGIPrimPath::setWidth().
Referenced by paint().
void QGIViewBalloon::setViewPartFeature | ( | TechDraw::DrawViewBalloon * | obj | ) |
References balloonLabel, draw(), getNormalColor(), TechDraw::DrawView::getScale(), App::PropertyString::getStrValue(), App::PropertyLink::getValue(), App::PropertyFloat::getValue(), App::PropertyQuantity::getValue(), TechDrawGui::Rez::guiX(), TechDrawGui::QGIBalloonLabel::setColor(), TechDrawGui::QGIBalloonLabel::setDimString(), TechDrawGui::QGIBalloonLabel::setPosFromCenter(), TechDrawGui::QGIView::setViewFeature(), TechDraw::DrawViewBalloon::SourceView, TechDraw::DrawViewBalloon::Text, TechDraw::DrawViewBalloon::TextWrapLen, updateBalloon(), TechDraw::DrawView::X, and TechDraw::DrawView::Y.
|
override |
Referenced by ArchProfile.ProfileTaskPanel::accept(), and ArchProfile.ProfileTaskPanel::retranslateUi().
|
slot |
References balloonLabel, TechDrawGui::QGIView::calculateFontPixelSize(), TechDrawGui::QGIBalloonLabel::getFont(), TechDraw::DrawView::getScale(), TechDrawGui::QGIView::getViewObject(), TechDrawGui::QGIView::getViewProvider(), TechDrawGui::Rez::guiX(), Gui::QtTools::horizontalAdvance(), TechDrawGui::QGIBalloonLabel::seps, TechDrawGui::QGIBalloonLabel::setDimString(), TechDrawGui::QGIBalloonLabel::setFont(), TechDrawGui::QGIBalloonLabel::setPosFromCenter(), and TechDrawGui::QGIBalloonLabel::verticalSep.
Referenced by setViewPartFeature(), and updateView().
|
overridevirtual |
Reimplemented from TechDrawGui::QGIView.
References arrow, balloonLabel, balloonLines, balloonShape, draw(), getNormalColor(), TechDrawGui::QGIView::getViewObject(), TechDrawGui::QGIView::getViewProvider(), TechDrawGui::Rez::guiX(), TechDrawGui::QGIBalloonLabel::setColor(), TechDrawGui::QGIBalloonLabel::setDimString(), TechDrawGui::QGIPrimPath::setFillColor(), TechDrawGui::QGIPrimPath::setNormalColor(), and updateBalloon().
Referenced by TechDrawGui::TaskBalloon::reject().
|
protected |
|
protected |
|
protected |
Referenced by drawBalloon(), QGIViewBalloon(), setGroupSelection(), setPens(), setPrettyNormal(), setPrettyPre(), setPrettySel(), setSvgPens(), and updateView().
|
protected |
Referenced by drawBalloon(), QGIViewBalloon(), setPens(), setPrettyNormal(), setPrettyPre(), setPrettySel(), setSvgPens(), and updateView().
TechDraw::DrawViewBalloon* TechDrawGui::QGIViewBalloon::dvBalloon |
Referenced by TechDrawGui::TaskBalloon::TaskBalloon().
|
protected |
Referenced by drawBalloon(), and hover().
|
protected |
Referenced by balloonLabelDragged(), and QGIViewBalloon().
|
protected |
Referenced by balloonLabelDragFinished(), and balloonLabelDragged().
|
protected |
Referenced by drawBalloon(), setPens(), and setSvgPens().
|
protected |
|
protected |
Referenced by balloonLabelDragFinished(), balloonLabelDragged(), and drawBalloon().
|
protected |
Referenced by balloonLabelDragFinished(), balloonLabelDragged(), and drawBalloon().
|
protected |