mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-01-03 11:00:53 +01:00
Forget file from previous commit
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5118 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -23,6 +23,7 @@
|
|||||||
#include "QPropertyUndoCommand/qpropertyundocommand.h"
|
#include "QPropertyUndoCommand/qpropertyundocommand.h"
|
||||||
#include "terminal.h"
|
#include "terminal.h"
|
||||||
#include "conductor.h"
|
#include "conductor.h"
|
||||||
|
#include "elementtextitemgroup.h"
|
||||||
|
|
||||||
#include <QDomDocument>
|
#include <QDomDocument>
|
||||||
#include <QDomElement>
|
#include <QDomElement>
|
||||||
@@ -222,11 +223,26 @@ void DynamicElementTextItem::fromXml(const QDomElement &dom_elmt)
|
|||||||
/**
|
/**
|
||||||
* @brief DynamicElementTextItem::ParentElement
|
* @brief DynamicElementTextItem::ParentElement
|
||||||
* @return a pointer to the parent element. Note the pointer can be null.
|
* @return a pointer to the parent element. Note the pointer can be null.
|
||||||
|
* Note that the text can return a parent element,
|
||||||
|
* even if the text belong to a group of this same element.
|
||||||
*/
|
*/
|
||||||
Element *DynamicElementTextItem::parentElement() const {
|
Element *DynamicElementTextItem::parentElement() const {
|
||||||
return m_parent_element;
|
return m_parent_element;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief DynamicElementTextItem::parentGroup
|
||||||
|
* @return The group where this text belong, if this item
|
||||||
|
* is note in a group, return nullptr.
|
||||||
|
*/
|
||||||
|
ElementTextItemGroup *DynamicElementTextItem::parentGroup() const
|
||||||
|
{
|
||||||
|
if(group())
|
||||||
|
return dynamic_cast<ElementTextItemGroup *>(group());
|
||||||
|
else
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief DynamicElementTextItem::elementUseForInfo
|
* @brief DynamicElementTextItem::elementUseForInfo
|
||||||
* @return a pointer to the element we must use for the variable information.
|
* @return a pointer to the element we must use for the variable information.
|
||||||
@@ -493,6 +509,11 @@ bool DynamicElementTextItem::frame() const
|
|||||||
return m_frame;
|
return m_frame;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QUuid DynamicElementTextItem::uuid() const
|
||||||
|
{
|
||||||
|
return m_uuid;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief DynamicElementTextItem::mousePressEvent
|
* @brief DynamicElementTextItem::mousePressEvent
|
||||||
* @param event
|
* @param event
|
||||||
|
|||||||
@@ -24,6 +24,7 @@
|
|||||||
|
|
||||||
class Element;
|
class Element;
|
||||||
class Conductor;
|
class Conductor;
|
||||||
|
class ElementTextItemGroup;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief The DynamicElementTextItem class
|
* @brief The DynamicElementTextItem class
|
||||||
@@ -77,6 +78,7 @@ class DynamicElementTextItem : public DiagramTextItem
|
|||||||
void fromXml(const QDomElement &dom_elmt) override;
|
void fromXml(const QDomElement &dom_elmt) override;
|
||||||
|
|
||||||
Element *parentElement() const;
|
Element *parentElement() const;
|
||||||
|
ElementTextItemGroup *parentGroup() const;
|
||||||
Element *elementUseForInfo() const;
|
Element *elementUseForInfo() const;
|
||||||
void refreshLabelConnection();
|
void refreshLabelConnection();
|
||||||
|
|
||||||
@@ -93,6 +95,7 @@ class DynamicElementTextItem : public DiagramTextItem
|
|||||||
QString compositeText() const;
|
QString compositeText() const;
|
||||||
void setFrame(const bool frame);
|
void setFrame(const bool frame);
|
||||||
bool frame() const;
|
bool frame() const;
|
||||||
|
QUuid uuid() const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void mousePressEvent(QGraphicsSceneMouseEvent *event) override;
|
void mousePressEvent(QGraphicsSceneMouseEvent *event) override;
|
||||||
|
|||||||
Reference in New Issue
Block a user