Dynamic element text item : when the source of text is label or composite text with variable %{label}, and the label of the element is created from a formula,

the displayed text of the dynamic text item is up to date according to the formula 


git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5086 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
blacksun
2017-10-26 17:12:49 +00:00
parent 7e2134e0db
commit e2a49e4872
4 changed files with 149 additions and 7 deletions

View File

@@ -76,6 +76,7 @@ class DynamicElementTextItem : public DiagramTextItem
Element *parentElement() const;
Element *elementUseForInfo() const;
void refreshLabelConnection();
DynamicElementTextItem::TextFrom textFrom() const;
void setTextFrom (DynamicElementTextItem::TextFrom text_from);
@@ -104,8 +105,11 @@ class DynamicElementTextItem : public DiagramTextItem
void reportFormulaChanged();
void setConnectionForReportFormula(const QString &formula);
void removeConnectionForReportFormula(const QString &formula);
void setupFormulaConnection();
void clearFormulaConnection();
void updateReportFormulaConnection();
void updateReportText();
void updateLabel();
void conductorWasAdded(Conductor *conductor);
void conductorWasRemoved(Conductor *conductor);
void setPotentialConductor();
@@ -126,6 +130,7 @@ class DynamicElementTextItem : public DiagramTextItem
DynamicElementTextItem::TextFrom m_text_from = UserText;
QUuid m_uuid;
QMetaObject::Connection m_report_formula_con;
QList<QMetaObject::Connection> m_formula_connection;
QColor m_user_color;
};