Reading/writing a draw tool notes.

This commit is contained in:
Roman Telezhynskyi 2020-10-28 14:09:56 +02:00
parent 460683c942
commit 8927abe99a
152 changed files with 11359 additions and 9542 deletions

View file

@ -3268,7 +3268,7 @@ void VPattern::ParseToolFlippingByLine(VMainGraphicsScene *scene, QDomElement &d
initData.parse = parse; initData.parse = parse;
initData.typeCreation = Source::FromFile; initData.typeCreation = Source::FromFile;
ToolsCommonAttributes(domElement, initData.id); DrawToolsCommonAttributes(domElement, initData.id, initData.notes);
initData.firstLinePointId = GetParametrUInt(domElement, AttrP1Line, NULL_ID_STR); initData.firstLinePointId = GetParametrUInt(domElement, AttrP1Line, NULL_ID_STR);
initData.secondLinePointId = GetParametrUInt(domElement, AttrP2Line, NULL_ID_STR); initData.secondLinePointId = GetParametrUInt(domElement, AttrP2Line, NULL_ID_STR);
initData.suffix = GetParametrString(domElement, AttrSuffix, QString()); initData.suffix = GetParametrString(domElement, AttrSuffix, QString());
@ -3300,7 +3300,7 @@ void VPattern::ParseToolFlippingByAxis(VMainGraphicsScene *scene, QDomElement &d
initData.parse = parse; initData.parse = parse;
initData.typeCreation = Source::FromFile; initData.typeCreation = Source::FromFile;
ToolsCommonAttributes(domElement, initData.id); DrawToolsCommonAttributes(domElement, initData.id, initData.notes);
initData.originPointId = GetParametrUInt(domElement, AttrCenter, NULL_ID_STR); initData.originPointId = GetParametrUInt(domElement, AttrCenter, NULL_ID_STR);
initData.axisType = static_cast<AxisType>(GetParametrUInt(domElement, AttrAxisType, QChar('1'))); initData.axisType = static_cast<AxisType>(GetParametrUInt(domElement, AttrAxisType, QChar('1')));
initData.suffix = GetParametrString(domElement, AttrSuffix, QString()); initData.suffix = GetParametrString(domElement, AttrSuffix, QString());

View file

@ -113,6 +113,9 @@ DialogAlongLine::DialogAlongLine(const VContainer *data, quint32 toolId, QWidget
// Call after initialization vis!!!! // Call after initialization vis!!!!
SetTypeLine(TypeLineNone);//By default don't show line SetTypeLine(TypeLineNone);//By default don't show line
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -294,7 +297,19 @@ void DialogAlongLine::SetSecondPointId(quint32 value)
VisToolAlongLine *line = qobject_cast<VisToolAlongLine *>(vis); VisToolAlongLine *line = qobject_cast<VisToolAlongLine *>(vis);
SCASSERT(line != nullptr) SCASSERT(line != nullptr)
line->setObject2Id(value); line->setObject2Id(value);
}
//---------------------------------------------------------------------------------------------------------------------
void DialogAlongLine::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogAlongLine::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View file

@ -71,6 +71,9 @@ public:
quint32 GetSecondPointId() const; quint32 GetSecondPointId() const;
void SetSecondPointId(quint32 value); void SetSecondPointId(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void Build(const Tool &type) override; virtual void Build(const Tool &type) override;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>412</width> <width>446</width>
<height>288</height> <height>365</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -20,317 +20,354 @@
<property name="locale"> <property name="locale">
<locale language="English" country="UnitedStates"/> <locale language="English" country="UnitedStates"/>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelEqual">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="plainText">
<string notr="true"/>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="text"> <string>Tool</string>
<string>Point label:</string> </attribute>
</property> <layout class="QVBoxLayout" name="verticalLayout">
</widget> <item>
</item> <layout class="QHBoxLayout" name="horizontalLayout">
<item row="1" column="0"> <item alignment="Qt::AlignLeft">
<widget class="QLabel" name="labelFirstPoint"> <widget class="QLabel" name="labelEditFormula">
<property name="text"> <property name="sizePolicy">
<string>First point:</string> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</property> <horstretch>0</horstretch>
</widget> <verstretch>0</verstretch>
</item> </sizepolicy>
<item row="1" column="1"> </property>
<widget class="QComboBox" name="comboBoxFirstPoint"> <property name="palette">
<property name="sizePolicy"> <palette>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <active>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>255</red>
<property name="toolTip"> <green>0</green>
<string>First point of the line</string> <blue>0</blue>
</property> </color>
</widget> </brush>
</item> </colorrole>
<item row="2" column="0"> </active>
<widget class="QLabel" name="labelSecondPoint"> <inactive>
<property name="text"> <colorrole role="WindowText">
<string>Second point:</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="2" column="1"> <blue>0</blue>
<widget class="QComboBox" name="comboBoxSecondPoint"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </colorrole>
<horstretch>0</horstretch> </inactive>
<verstretch>0</verstretch> <disabled>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="toolTip"> <color alpha="255">
<string>Second point of the line</string> <red>159</red>
</property> <green>158</green>
</widget> <blue>158</blue>
</item> </color>
<item row="3" column="0"> </brush>
<widget class="QLabel" name="label_6"> </colorrole>
<property name="text"> </disabled>
<string>Type of line:</string> </palette>
</property> </property>
</widget> <property name="text">
</item> <string>Length:</string>
<item row="3" column="1"> </property>
<widget class="QComboBox" name="comboBoxLineType"> </widget>
<property name="sizePolicy"> </item>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <item>
<horstretch>0</horstretch> <spacer name="horizontalSpacer">
<verstretch>0</verstretch> <property name="orientation">
</sizepolicy> <enum>Qt::Horizontal</enum>
</property> </property>
<property name="minimumSize"> <property name="sizeHint" stdset="0">
<size> <size>
<width>80</width> <width>40</width>
<height>0</height> <height>20</height>
</size> </size>
</property> </property>
<property name="maximumSize"> </spacer>
<size> </item>
<width>110</width> <item alignment="Qt::AlignRight">
<height>16777215</height> <widget class="QToolButton" name="toolButtonExprLength">
</size> <property name="toolTip">
</property> <string>Formula wizard</string>
<property name="toolTip"> </property>
<string/> <property name="text">
</property> <string notr="true">...</string>
<property name="iconSize"> </property>
<size> <property name="icon">
<width>80</width> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<height>14</height> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</size> </property>
</property> <property name="iconSize">
</widget> <size>
</item> <width>24</width>
<item row="4" column="0"> <height>24</height>
<widget class="QLabel" name="label"> </size>
<property name="text"> </property>
<string>Line color:</string> </widget>
</property> </item>
</widget> <item alignment="Qt::AlignRight">
</item> <widget class="QLabel" name="labelEqual">
<item row="4" column="1"> <property name="text">
<widget class="QComboBox" name="comboBoxLineColor"> <string/>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <property name="pixmap">
<horstretch>0</horstretch> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="toolTip"> <item alignment="Qt::AlignRight">
<string/> <widget class="QLabel" name="labelResultCalculation">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="minimumSize">
</property> <size>
<property name="placeholderText"> <width>87</width>
<string>Choose unique label.</string> <height>0</height>
</property> </size>
</widget> </property>
</item> <property name="baseSize">
</layout> <size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="plainText">
<string notr="true"/>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelFirstPoint">
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxFirstPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>First point of the line</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSecondPoint">
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxSecondPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Second point of the line</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Type of line:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxLineType">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string/>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxLineColor">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string/>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -123,6 +123,9 @@ DialogArc::DialogArc(const VContainer *data, quint32 toolId, QWidget *parent)
connect(ui->pushButtonGrowLengthF2, &QPushButton::clicked, this, &DialogArc::DeployF2TextEdit); connect(ui->pushButtonGrowLengthF2, &QPushButton::clicked, this, &DialogArc::DeployF2TextEdit);
vis = new VisToolArc(data); vis = new VisToolArc(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -219,7 +222,19 @@ void DialogArc::SetApproximationScale(qreal value)
VisToolArc *path = qobject_cast<VisToolArc *>(vis); VisToolArc *path = qobject_cast<VisToolArc *>(vis);
SCASSERT(path != nullptr) SCASSERT(path != nullptr)
path->setApproximationScale(value); path->setApproximationScale(value);
}
//---------------------------------------------------------------------------------------------------------------------
void DialogArc::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogArc::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View file

@ -73,6 +73,9 @@ public:
qreal GetApproximationScale() const; qreal GetApproximationScale() const;
void SetApproximationScale(qreal value); void SetApproximationScale(qreal value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

File diff suppressed because it is too large Load diff

View file

@ -116,6 +116,9 @@ DialogArcWithLength::DialogArcWithLength(const VContainer *data, quint32 toolId,
connect(ui->pushButtonGrowLengthArcLength, &QPushButton::clicked, this, &DialogArcWithLength::DeployLengthTextEdit); connect(ui->pushButtonGrowLengthArcLength, &QPushButton::clicked, this, &DialogArcWithLength::DeployLengthTextEdit);
vis = new VisToolArcWithLength(data); vis = new VisToolArcWithLength(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -245,7 +248,19 @@ void DialogArcWithLength::SetApproximationScale(qreal value)
VisToolArcWithLength *path = qobject_cast<VisToolArcWithLength *>(vis); VisToolArcWithLength *path = qobject_cast<VisToolArcWithLength *>(vis);
SCASSERT(path != nullptr) SCASSERT(path != nullptr)
path->setApproximationScale(value); path->setApproximationScale(value);
}
//---------------------------------------------------------------------------------------------------------------------
void DialogArcWithLength::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogArcWithLength::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View file

@ -71,6 +71,9 @@ public:
qreal GetApproximationScale() const; qreal GetApproximationScale() const;
void SetApproximationScale(qreal value); void SetApproximationScale(qreal value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

File diff suppressed because it is too large Load diff

View file

@ -106,6 +106,9 @@ DialogBisector::DialogBisector(const VContainer *data, quint32 toolId, QWidget *
this, &DialogBisector::PointNameChanged); this, &DialogBisector::PointNameChanged);
vis = new VisToolBisector(data); vis = new VisToolBisector(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -345,6 +348,18 @@ void DialogBisector::SetLineColor(const QString &value)
ChangeCurrentData(ui->comboBoxLineColor, value); ChangeCurrentData(ui->comboBoxLineColor, value);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogBisector::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogBisector::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
void DialogBisector::SaveData() void DialogBisector::SaveData()
{ {

View file

@ -74,6 +74,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>428</width> <width>405</width>
<height>321</height> <height>358</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,306 +17,343 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_8">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Point label:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Unique label</string> <palette>
</property> <active>
<property name="placeholderText"> <colorrole role="WindowText">
<string>Choose unique label.</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="0"> <blue>0</blue>
<widget class="QLabel" name="labelFirstPoint"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </colorrole>
<horstretch>0</horstretch> </active>
<verstretch>0</verstretch> <inactive>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="text"> <color alpha="255">
<string>First point:</string> <red>255</red>
</property> <green>0</green>
</widget> <blue>0</blue>
</item> </color>
<item row="1" column="1"> </brush>
<widget class="QComboBox" name="comboBoxFirstPoint"/> </colorrole>
</item> </inactive>
<item row="2" column="0"> <disabled>
<widget class="QLabel" name="labelSecondPoint"> <colorrole role="WindowText">
<property name="sizePolicy"> <brush brushstyle="SolidPattern">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <color alpha="255">
<horstretch>0</horstretch> <red>159</red>
<verstretch>0</verstretch> <green>158</green>
</sizepolicy> <blue>158</blue>
</property> </color>
<property name="text"> </brush>
<string>Second point:</string> </colorrole>
</property> </disabled>
</widget> </palette>
</item> </property>
<item row="2" column="1"> <property name="text">
<widget class="QComboBox" name="comboBoxSecondPoint"/> <string>Length:</string>
</item> </property>
<item row="3" column="0"> </widget>
<widget class="QLabel" name="labelThirdPoint"> </item>
<property name="sizePolicy"> <item>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <spacer name="horizontalSpacer">
<horstretch>0</horstretch> <property name="orientation">
<verstretch>0</verstretch> <enum>Qt::Horizontal</enum>
</sizepolicy> </property>
</property> <property name="sizeHint" stdset="0">
<property name="text"> <size>
<string>Third point:</string> <width>40</width>
</property> <height>20</height>
</widget> </size>
</item> </property>
<item row="3" column="1"> </spacer>
<widget class="QComboBox" name="comboBoxThirdPoint"/> </item>
</item> <item alignment="Qt::AlignRight">
<item row="4" column="0"> <widget class="QToolButton" name="toolButtonExprLength">
<widget class="QLabel" name="label_7"> <property name="toolTip">
<property name="text"> <string>Formula wizard</string>
<string>Type of line:</string> </property>
</property> <property name="text">
</widget> <string notr="true">...</string>
</item> </property>
<item row="4" column="1"> <property name="icon">
<widget class="QComboBox" name="comboBoxLineType"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<property name="minimumSize"> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<size> </property>
<width>80</width> <property name="iconSize">
<height>0</height> <size>
</size> <width>24</width>
</property> <height>24</height>
<property name="maximumSize"> </size>
<size> </property>
<width>110</width> </widget>
<height>16777215</height> </item>
</size> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="label_3">
<property name="iconSize"> <property name="text">
<size> <string/>
<width>80</width> </property>
<height>14</height> <property name="pixmap">
</size> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property> </property>
</widget> </widget>
</item> </item>
<item row="5" column="0"> <item alignment="Qt::AlignRight">
<widget class="QLabel" name="label"> <widget class="QLabel" name="labelResultCalculation">
<property name="text"> <property name="sizePolicy">
<string>Line color:</string> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</property> <horstretch>0</horstretch>
</widget> <verstretch>0</verstretch>
</item> </sizepolicy>
<item row="5" column="1"> </property>
<widget class="QComboBox" name="comboBoxLineColor"/> <property name="minimumSize">
</item> <size>
</layout> <width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_8">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelFirstPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxFirstPoint"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSecondPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxSecondPoint"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelThirdPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Third point:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxThirdPoint"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Type of line:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxLineType">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -73,6 +73,9 @@ DialogCubicBezier::DialogCubicBezier(const VContainer *data, quint32 toolId, QWi
this, &DialogCubicBezier::PointNameChanged); this, &DialogCubicBezier::PointNameChanged);
vis = new VisToolCubicBezier(data); vis = new VisToolCubicBezier(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -276,3 +279,15 @@ const QSharedPointer<VPointF> DialogCubicBezier::GetP4() const
{ {
return data->GeometricObject<VPointF>(getCurrentObjectId(ui->comboBoxP4)); return data->GeometricObject<VPointF>(getCurrentObjectId(ui->comboBoxP4));
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCubicBezier::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCubicBezier::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -55,6 +55,9 @@ public:
VCubicBezier GetSpline() const; VCubicBezier GetSpline() const;
void SetSpline(const VCubicBezier &spline); void SetSpline(const VCubicBezier &spline);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>387</width> <width>479</width>
<height>294</height> <height>362</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,134 +19,154 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="5" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="label"> <attribute name="title">
<property name="text"> <string>Tool</string>
<string>Color:</string> </attribute>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
</widget> <item row="0" column="0">
</item> <widget class="QLabel" name="labelFirstPoint">
<item row="5" column="1"> <property name="text">
<widget class="QComboBox" name="comboBoxColor"> <string>First point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="0" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxP1"/>
</property> </item>
</widget> <item row="1" column="0">
</item> <widget class="QLabel" name="labelSecondPoint">
<item row="7" column="0"> <property name="text">
<widget class="QLabel" name="labelName"> <string>Second point:</string>
<property name="text"> </property>
<string>Name:</string> </widget>
</property> </item>
</widget> <item row="1" column="1">
</item> <widget class="QComboBox" name="comboBoxP2"/>
<item row="7" column="1"> </item>
<widget class="QLineEdit" name="lineEditSplineName"> <item row="2" column="0">
<property name="readOnly"> <widget class="QLabel" name="labelThirdPoint">
<bool>true</bool> <property name="text">
</property> <string>Third point:</string>
</widget> </property>
</item> </widget>
<item row="0" column="0"> </item>
<widget class="QLabel" name="labelFirstPoint"> <item row="2" column="1">
<property name="text"> <widget class="QComboBox" name="comboBoxP3"/>
<string>First point:</string> </item>
</property> <item row="3" column="0">
</widget> <widget class="QLabel" name="labelForthPoint">
</item> <property name="text">
<item row="0" column="1"> <string>Fourth point:</string>
<widget class="QComboBox" name="comboBoxP1"/> </property>
</item> </widget>
<item row="1" column="0"> </item>
<widget class="QLabel" name="labelSecondPoint"> <item row="3" column="1">
<property name="text"> <widget class="QComboBox" name="comboBoxP4"/>
<string>Second point:</string> </item>
</property> <item row="4" column="0">
</widget> <widget class="QLabel" name="label_2">
</item> <property name="text">
<item row="1" column="1"> <string>Pen Style:</string>
<widget class="QComboBox" name="comboBoxP2"/> </property>
</item> </widget>
<item row="2" column="0"> </item>
<widget class="QLabel" name="labelThirdPoint"> <item row="4" column="1">
<property name="text"> <widget class="QComboBox" name="comboBoxPenStyle">
<string>Third point:</string> <property name="minimumSize">
</property> <size>
</widget> <width>80</width>
</item> <height>0</height>
<item row="2" column="1"> </size>
<widget class="QComboBox" name="comboBoxP3"/> </property>
</item> <property name="maximumSize">
<item row="3" column="0"> <size>
<widget class="QLabel" name="labelForthPoint"> <width>110</width>
<property name="text"> <height>16777215</height>
<string>Fourth point:</string> </size>
</property> </property>
</widget> <property name="iconSize">
</item> <size>
<item row="3" column="1"> <width>80</width>
<widget class="QComboBox" name="comboBoxP4"/> <height>14</height>
</item> </size>
<item row="4" column="0"> </property>
<widget class="QLabel" name="label_2"> </widget>
<property name="text"> </item>
<string>Pen Style:</string> <item row="5" column="0">
</property> <widget class="QLabel" name="label">
</widget> <property name="text">
</item> <string>Color:</string>
<item row="4" column="1"> </property>
<widget class="QComboBox" name="comboBoxPenStyle"> </widget>
<property name="minimumSize"> </item>
<size> <item row="5" column="1">
<width>80</width> <widget class="QComboBox" name="comboBoxColor">
<height>0</height> <property name="sizePolicy">
</size> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</property> <horstretch>0</horstretch>
<property name="maximumSize"> <verstretch>0</verstretch>
<size> </sizepolicy>
<width>110</width> </property>
<height>16777215</height> </widget>
</size> </item>
</property> <item row="6" column="0">
<property name="iconSize"> <widget class="QLabel" name="label_3">
<size> <property name="text">
<width>80</width> <string>Approximation Scale:</string>
<height>14</height> </property>
</size> </widget>
</property> </item>
</widget> <item row="6" column="1">
</item> <widget class="QDoubleSpinBox" name="doubleSpinBoxApproximationScale">
<item row="6" column="0"> <property name="toolTip">
<widget class="QLabel" name="label_3"> <string>Set approximation scale for this curve, 0 - use global value</string>
<property name="text"> </property>
<string>Approximation Scale:</string> <property name="decimals">
</property> <number>1</number>
</widget> </property>
</item> <property name="maximum">
<item row="6" column="1"> <double>10.000000000000000</double>
<widget class="QDoubleSpinBox" name="doubleSpinBoxApproximationScale"> </property>
<property name="toolTip"> <property name="singleStep">
<string>Set approximation scale for this curve, 0 - use global value</string> <double>0.100000000000000</double>
</property> </property>
<property name="decimals"> </widget>
<number>1</number> </item>
</property> <item row="7" column="0">
<property name="maximum"> <widget class="QLabel" name="labelName">
<double>10.000000000000000</double> <property name="text">
</property> <string>Name:</string>
<property name="singleStep"> </property>
<double>0.100000000000000</double> </widget>
</property> </item>
</widget> <item row="7" column="1">
</item> <widget class="QLineEdit" name="lineEditSplineName">
</layout> <property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -81,6 +81,9 @@ DialogCubicBezierPath::DialogCubicBezierPath(const VContainer *data, quint32 too
this, &DialogCubicBezierPath::currentPointChanged); this, &DialogCubicBezierPath::currentPointChanged);
vis = new VisToolCubicBezierPath(data); vis = new VisToolCubicBezierPath(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -360,3 +363,15 @@ void DialogCubicBezierPath::ValidatePath()
ChangeColor(ui->labelName, color); ChangeColor(ui->labelName, color);
ChangeColor(ui->labelPoint, color); ChangeColor(ui->labelPoint, color);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCubicBezierPath::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCubicBezierPath::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -56,6 +56,9 @@ public:
VCubicBezierPath GetPath() const; VCubicBezierPath GetPath() const;
void SetPath(const VCubicBezierPath &value); void SetPath(const VCubicBezierPath &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>324</width> <width>375</width>
<height>327</height> <height>439</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,118 +17,155 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_3">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item> <property name="currentIndex">
<layout class="QVBoxLayout" name="verticalLayout"> <number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>Tool</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_5"> <layout class="QHBoxLayout" name="horizontalLayout">
<item> <item>
<widget class="QLabel" name="labelPoint"> <layout class="QVBoxLayout" name="verticalLayout">
<property name="text"> <item>
<string>Point:</string> <layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="QLabel" name="labelPoint">
<property name="text">
<string>Point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxPoint"/>
</item>
</layout>
</item>
</layout>
</item>
<item>
<widget class="QListWidget" name="listWidget">
<property name="toolTip">
<string>List of points</string>
</property> </property>
</widget> </widget>
</item> </item>
<item> </layout>
<widget class="QComboBox" name="comboBoxPoint"/> </item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Color:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxColor"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLineEdit" name="lineEditSplPathName">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Pen style:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxPenStyle">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Approximation scale:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QDoubleSpinBox" name="doubleSpinBoxApproximationScale">
<property name="toolTip">
<string>Set approximation scale for this curve, 0 - use global value</string>
</property>
<property name="decimals">
<number>1</number>
</property>
<property name="maximum">
<double>10.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item> </item>
</layout> </layout>
</item> </item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</item> </widget>
<item> <widget class="QWidget" name="tab_2">
<widget class="QListWidget" name="listWidget"> <attribute name="title">
<property name="toolTip"> <string>Notes</string>
<string>List of points</string> </attribute>
</property> <layout class="QVBoxLayout" name="verticalLayout_4">
</widget> <item>
</item> <widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</layout> </item>
</item> </layout>
<item> </widget>
<layout class="QFormLayout" name="formLayout"> </widget>
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Color:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxColor"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLineEdit" name="lineEditSplPathName">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Pen style:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxPenStyle">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Approximation scale:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QDoubleSpinBox" name="doubleSpinBoxApproximationScale">
<property name="toolTip">
<string>Set approximation scale for this curve, 0 - use global value</string>
</property>
<property name="decimals">
<number>1</number>
</property>
<property name="maximum">
<double>10.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item>
</layout>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -96,6 +96,9 @@ DialogCurveIntersectAxis::DialogCurveIntersectAxis(const VContainer *data, quint
connect(timerFormula, &QTimer::timeout, this, &DialogCurveIntersectAxis::EvalAngle); connect(timerFormula, &QTimer::timeout, this, &DialogCurveIntersectAxis::EvalAngle);
vis = new VisToolCurveIntersectAxis(data); vis = new VisToolCurveIntersectAxis(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -343,3 +346,15 @@ void DialogCurveIntersectAxis::closeEvent(QCloseEvent *event)
ui->plainTextEditFormula->blockSignals(true); ui->plainTextEditFormula->blockSignals(true);
DialogTool::closeEvent(event); DialogTool::closeEvent(event);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCurveIntersectAxis::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCurveIntersectAxis::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -69,6 +69,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>419</width> <width>335</width>
<height>288</height> <height>331</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,300 +17,337 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_9"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Angle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprAngle">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="baseSize">
<size>
<width>4</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="lineWrapMode">
<enum>QPlainTextEdit::NoWrap</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLengthAngle">
<property name="maximumSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="label_4"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout_9">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Axis point:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QComboBox" name="comboBoxAxisPoint"> </property>
<property name="toolTip"> <property name="palette">
<string/> <palette>
</property> <active>
</widget> <colorrole role="WindowText">
</item> <brush brushstyle="SolidPattern">
<item row="1" column="0"> <color alpha="255">
<widget class="QLabel" name="label_5"> <red>255</red>
<property name="sizePolicy"> <green>0</green>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <blue>0</blue>
<horstretch>0</horstretch> </color>
<verstretch>0</verstretch> </brush>
</sizepolicy> </colorrole>
</property> </active>
<property name="text"> <inactive>
<string>Curve:</string> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
</widget> <color alpha="255">
</item> <red>255</red>
<item row="1" column="1"> <green>0</green>
<widget class="QComboBox" name="comboBoxCurve"/> <blue>0</blue>
</item> </color>
<item row="2" column="0"> </brush>
<widget class="QLabel" name="labelEditNamePoint"> </colorrole>
<property name="sizePolicy"> </inactive>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <disabled>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>159</red>
<property name="text"> <green>158</green>
<string>Point label:</string> <blue>158</blue>
</property> </color>
</widget> </brush>
</item> </colorrole>
<item row="2" column="1"> </disabled>
<widget class="QLineEdit" name="lineEditNamePoint"> </palette>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Angle:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="toolTip"> <item>
<string>Unique label</string> <spacer name="horizontalSpacer_2">
</property> <property name="orientation">
<property name="placeholderText"> <enum>Qt::Horizontal</enum>
<string>Choose unique label.</string> </property>
</property> <property name="sizeHint" stdset="0">
</widget> <size>
</item> <width>40</width>
<item row="3" column="0"> <height>20</height>
<widget class="QLabel" name="label_7"> </size>
<property name="text"> </property>
<string>Type of line:</string> </spacer>
</property> </item>
</widget> <item alignment="Qt::AlignRight">
</item> <widget class="QToolButton" name="toolButtonExprAngle">
<item row="3" column="1"> <property name="toolTip">
<widget class="QComboBox" name="comboBoxLineType"> <string>Formula wizard</string>
<property name="minimumSize"> </property>
<size> <property name="text">
<width>80</width> <string notr="true">...</string>
<height>0</height> </property>
</size> <property name="icon">
</property> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<property name="maximumSize"> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<size> </property>
<width>110</width> <property name="iconSize">
<height>16777215</height> <size>
</size> <width>24</width>
</property> <height>24</height>
<property name="iconSize"> </size>
<size> </property>
<width>80</width> </widget>
<height>14</height> </item>
</size> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="label_3">
</widget> <property name="text">
</item> <string/>
<item row="4" column="0"> </property>
<widget class="QLabel" name="label"> <property name="pixmap">
<property name="text"> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
<string>Line color:</string> </property>
</property> </widget>
</widget> </item>
</item> <item alignment="Qt::AlignRight">
<item row="4" column="1"> <widget class="QLabel" name="labelResultCalculation">
<widget class="QComboBox" name="comboBoxLineColor"/> <property name="sizePolicy">
</item> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</layout> <horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="baseSize">
<size>
<width>4</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="lineWrapMode">
<enum>QPlainTextEdit::NoWrap</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLengthAngle">
<property name="maximumSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Axis point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxAxisPoint">
<property name="toolTip">
<string/>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Curve:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxCurve"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Type of line:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxLineType">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -94,6 +94,9 @@ DialogCutArc::DialogCutArc(const VContainer *data, quint32 toolId, QWidget *pare
connect(ui->comboBoxArc, &QComboBox::currentTextChanged, this, &DialogCutArc::ArcChanged); connect(ui->comboBoxArc, &QComboBox::currentTextChanged, this, &DialogCutArc::ArcChanged);
vis = new VisToolCutArc(data); vis = new VisToolCutArc(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -264,3 +267,15 @@ quint32 DialogCutArc::getArcId() const
{ {
return getCurrentObjectId(ui->comboBoxArc); return getCurrentObjectId(ui->comboBoxArc);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCutArc::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCutArc::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -62,6 +62,9 @@ public:
quint32 getArcId() const; quint32 getArcId() const;
void setArcId(quint32 value); void setArcId(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>412</width> <width>334</width>
<height>189</height> <height>247</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,235 +17,272 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_formula">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="label_3"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Arc:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QComboBox" name="comboBoxArc"/> </property>
</item> <property name="palette">
<item row="1" column="0"> <palette>
<widget class="QLabel" name="labelEditNamePoint"> <active>
<property name="sizePolicy"> <colorrole role="WindowText">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <brush brushstyle="SolidPattern">
<horstretch>0</horstretch> <color alpha="255">
<verstretch>0</verstretch> <red>255</red>
</sizepolicy> <green>0</green>
</property> <blue>0</blue>
<property name="text"> </color>
<string>Point label:</string> </brush>
</property> </colorrole>
</widget> </active>
</item> <inactive>
<item row="1" column="1"> <colorrole role="WindowText">
<widget class="QLineEdit" name="lineEditNamePoint"> <brush brushstyle="SolidPattern">
<property name="toolTip"> <color alpha="255">
<string>Unique label</string> <red>255</red>
</property> <green>0</green>
<property name="placeholderText"> <blue>0</blue>
<string>Choose unique label.</string> </color>
</property> </brush>
</widget> </colorrole>
</item> </inactive>
</layout> <disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_formula">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Arc:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxArc"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -93,6 +93,9 @@ DialogCutSpline::DialogCutSpline(const VContainer *data, quint32 toolId, QWidget
connect(ui->comboBoxSpline, &QComboBox::currentTextChanged, this, &DialogCutSpline::SplineChanged); connect(ui->comboBoxSpline, &QComboBox::currentTextChanged, this, &DialogCutSpline::SplineChanged);
vis = new VisToolCutSpline(data); vis = new VisToolCutSpline(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -264,3 +267,15 @@ quint32 DialogCutSpline::getSplineId() const
{ {
return getCurrentObjectId(ui->comboBoxSpline); return getCurrentObjectId(ui->comboBoxSpline);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCutSpline::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCutSpline::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -61,6 +61,9 @@ public:
quint32 getSplineId() const; quint32 getSplineId() const;
void setSplineId(quint32 value); void setSplineId(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>412</width> <width>324</width>
<height>189</height> <height>240</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,235 +17,272 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="label_3"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Curve:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QComboBox" name="comboBoxSpline"/> </property>
</item> <property name="palette">
<item row="1" column="0"> <palette>
<widget class="QLabel" name="labelEditNamePoint"> <active>
<property name="sizePolicy"> <colorrole role="WindowText">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred"> <brush brushstyle="SolidPattern">
<horstretch>0</horstretch> <color alpha="255">
<verstretch>0</verstretch> <red>255</red>
</sizepolicy> <green>0</green>
</property> <blue>0</blue>
<property name="text"> </color>
<string>Point label:</string> </brush>
</property> </colorrole>
</widget> </active>
</item> <inactive>
<item row="1" column="1"> <colorrole role="WindowText">
<widget class="QLineEdit" name="lineEditNamePoint"> <brush brushstyle="SolidPattern">
<property name="toolTip"> <color alpha="255">
<string>Unique label</string> <red>255</red>
</property> <green>0</green>
<property name="placeholderText"> <blue>0</blue>
<string>Choose unique label.</string> </color>
</property> </brush>
</widget> </colorrole>
</item> </inactive>
</layout> <disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Curve:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxSpline"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -93,6 +93,9 @@ DialogCutSplinePath::DialogCutSplinePath(const VContainer *data, quint32 toolId,
connect(ui->comboBoxSplinePath, &QComboBox::currentTextChanged, this, &DialogCutSplinePath::SplinePathChanged); connect(ui->comboBoxSplinePath, &QComboBox::currentTextChanged, this, &DialogCutSplinePath::SplinePathChanged);
vis = new VisToolCutSplinePath(data); vis = new VisToolCutSplinePath(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -264,3 +267,15 @@ quint32 DialogCutSplinePath::getSplinePathId() const
{ {
return getCurrentObjectId(ui->comboBoxSplinePath); return getCurrentObjectId(ui->comboBoxSplinePath);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogCutSplinePath::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogCutSplinePath::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -61,6 +61,9 @@ public:
quint32 getSplinePathId() const; quint32 getSplinePathId() const;
void setSplinePathId(quint32 value); void setSplinePathId(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>412</width> <width>326</width>
<height>189</height> <height>245</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,235 +17,272 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="label_3"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Curve:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QComboBox" name="comboBoxSplinePath"/> </property>
</item> <property name="palette">
<item row="1" column="0"> <palette>
<widget class="QLabel" name="labelEditNamePoint"> <active>
<property name="sizePolicy"> <colorrole role="WindowText">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred"> <brush brushstyle="SolidPattern">
<horstretch>0</horstretch> <color alpha="255">
<verstretch>0</verstretch> <red>255</red>
</sizepolicy> <green>0</green>
</property> <blue>0</blue>
<property name="text"> </color>
<string>Point label:</string> </brush>
</property> </colorrole>
</widget> </active>
</item> <inactive>
<item row="1" column="1"> <colorrole role="WindowText">
<widget class="QLineEdit" name="lineEditNamePoint"> <brush brushstyle="SolidPattern">
<property name="toolTip"> <color alpha="255">
<string>Unique label</string> <red>255</red>
</property> <green>0</green>
<property name="placeholderText"> <blue>0</blue>
<string>Choose unique label.</string> </color>
</property> </brush>
</widget> </colorrole>
</item> </inactive>
</layout> <disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_4">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="whatsThis">
<string notr="true"/>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Curve:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxSplinePath"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -155,6 +155,9 @@ DialogEllipticalArc::DialogEllipticalArc(const VContainer *data, quint32 toolId,
this, &DialogEllipticalArc::DeployRotationAngleTextEdit); this, &DialogEllipticalArc::DeployRotationAngleTextEdit);
vis = new VisToolEllipticalArc(data); vis = new VisToolEllipticalArc(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -588,3 +591,15 @@ void DialogEllipticalArc::closeEvent(QCloseEvent *event)
ui->plainTextEditRotationAngle->blockSignals(true); ui->plainTextEditRotationAngle->blockSignals(true);
DialogTool::closeEvent(event); DialogTool::closeEvent(event);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogEllipticalArc::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogEllipticalArc::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -74,6 +74,9 @@ public:
QString GetColor() const; QString GetColor() const;
void SetColor(const QString &value); void SetColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>425</width> <width>396</width>
<height>530</height> <height>575</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,10 +17,16 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_3"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QVBoxLayout" name="verticalLayout_2"> <widget class="QTabWidget" name="tabWidget">
<item> <property name="currentIndex">
<number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>Tool</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_5"> <layout class="QHBoxLayout" name="horizontalLayout_5">
@ -1022,19 +1028,42 @@
</item> </item>
</layout> </layout>
</item> </item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</item> </widget>
<item> <widget class="QWidget" name="tab_2">
<widget class="QDialogButtonBox" name="buttonBox"> <attribute name="title">
<property name="orientation"> <string>Notes</string>
<enum>Qt::Horizontal</enum> </attribute>
</property> <layout class="QVBoxLayout" name="verticalLayout_3">
<property name="standardButtons"> <item>
<set>QDialogButtonBox::Apply|QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set> <widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</property> </item>
</widget> </layout>
</item> </widget>
</layout> </widget>
</item>
<item>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::Apply|QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item> </item>
</layout> </layout>
</widget> </widget>

View file

@ -123,6 +123,9 @@ DialogEndLine::DialogEndLine(const VContainer *data, quint32 toolId, QWidget *pa
connect(timerFormulaAngle, &QTimer::timeout, this, &DialogEndLine::EvalAngle); connect(timerFormulaAngle, &QTimer::timeout, this, &DialogEndLine::EvalAngle);
vis = new VisToolEndLine(data); vis = new VisToolEndLine(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -440,3 +443,15 @@ quint32 DialogEndLine::GetBasePointId() const
{ {
return getCurrentObjectId(ui->comboBoxBasePoint); return getCurrentObjectId(ui->comboBoxBasePoint);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogEndLine::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogEndLine::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -71,6 +71,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

File diff suppressed because it is too large Load diff

View file

@ -88,6 +88,9 @@ DialogFlippingByAxis::DialogFlippingByAxis(const VContainer *data, quint32 toolI
this, &DialogFlippingByAxis::PointChanged); this, &DialogFlippingByAxis::PointChanged);
vis = new VisToolFlippingByAxis(data); vis = new VisToolFlippingByAxis(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -402,3 +405,15 @@ void DialogFlippingByAxis::FillComboBoxAxisType(QComboBox *box)
box->addItem(tr("Vertical axis"), QVariant(static_cast<int>(AxisType::VerticalAxis))); box->addItem(tr("Vertical axis"), QVariant(static_cast<int>(AxisType::VerticalAxis)));
box->addItem(tr("Horizontal axis"), QVariant(static_cast<int>(AxisType::HorizontalAxis))); box->addItem(tr("Horizontal axis"), QVariant(static_cast<int>(AxisType::HorizontalAxis)));
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogFlippingByAxis::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogFlippingByAxis::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -74,6 +74,9 @@ public:
void SetVisibilityGroupTags(const QStringList &tags); void SetVisibilityGroupTags(const QStringList &tags);
QStringList GetVisibilityGroupTags() const; QStringList GetVisibilityGroupTags() const;
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void SetGroupCategories(const QStringList &categories) override; virtual void SetGroupCategories(const QStringList &categories) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

View file

@ -7,100 +7,141 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>304</width> <width>304</width>
<height>237</height> <height>296</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>Flipping by axis</string> <string>Flipping by axis</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <property name="windowIcon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<item row="0" column="0"> <property name="currentIndex">
<widget class="QLabel" name="labelOriginPoint"> <number>0</number>
<property name="text">
<string>Origin point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxOriginPoint"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSuffix">
<property name="text">
<string>Suffix:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QLineEdit" name="lineEditSuffix"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelAxisType">
<property name="text">
<string>Axis type:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxAxisType"/>
</item>
</layout>
</item>
<item>
<widget class="QGroupBox" name="groupBoxVisibilityGroup">
<property name="toolTip">
<string>Enable to create a visibility gropup from original objects</string>
</property> </property>
<property name="title"> <widget class="QWidget" name="tab">
<string>Visibility Group</string> <attribute name="title">
</property> <string>Tool</string>
<property name="checkable"> </attribute>
<bool>true</bool> <layout class="QVBoxLayout" name="verticalLayout">
</property> <item>
<property name="checked"> <layout class="QFormLayout" name="formLayout">
<bool>false</bool> <item row="0" column="0">
</property> <widget class="QLabel" name="labelOriginPoint">
<layout class="QGridLayout" name="gridLayout"> <property name="text">
<item row="0" column="0"> <string>Origin point:</string>
<widget class="QLabel" name="labelGroupName"> </property>
<property name="text"> </widget>
<string>Name:</string> </item>
</property> <item row="0" column="1">
</widget> <widget class="QComboBox" name="comboBoxOriginPoint"/>
</item> </item>
<item row="0" column="1"> <item row="2" column="0">
<widget class="QLineEdit" name="lineEditVisibilityGroup"> <widget class="QLabel" name="labelSuffix">
<property name="text"> <property name="text">
<string>Flipping by axis</string> <string>Suffix:</string>
</property> </property>
<property name="clearButtonEnabled"> </widget>
<bool>true</bool> </item>
</property> <item row="2" column="1">
</widget> <widget class="QLineEdit" name="lineEditSuffix"/>
</item> </item>
<item row="1" column="0"> <item row="1" column="0">
<widget class="QLabel" name="label"> <widget class="QLabel" name="labelAxisType">
<property name="text"> <property name="text">
<string>Tags:</string> <string>Axis type:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="1"> <item row="1" column="1">
<widget class="VCompleterLineEdit" name="lineEditGroupTags"> <widget class="QComboBox" name="comboBoxAxisType"/>
<property name="toolTip"> </item>
<string>Separate each tag with comma.</string> </layout>
</property> </item>
<property name="placeholderText"> <item>
<string>Add tags</string> <widget class="QGroupBox" name="groupBoxVisibilityGroup">
</property> <property name="toolTip">
<property name="clearButtonEnabled"> <string>Enable to create a visibility gropup from original objects</string>
<bool>true</bool> </property>
</property> <property name="title">
</widget> <string>Visibility Group</string>
</item> </property>
</layout> <property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>false</bool>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="labelGroupName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditVisibilityGroup">
<property name="text">
<string>Flipping by axis</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Tags:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="VCompleterLineEdit" name="lineEditGroupTags">
<property name="toolTip">
<string>Separate each tag with comma.</string>
</property>
<property name="placeholderText">
<string>Add tags</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget> </widget>
</item> </item>
<item> <item>
@ -122,7 +163,9 @@
<header>vlineedit.h</header> <header>vlineedit.h</header>
</customwidget> </customwidget>
</customwidgets> </customwidgets>
<resources/> <resources>
<include location="../../../vmisc/share/resources/icon.qrc"/>
</resources>
<connections> <connections>
<connection> <connection>
<sender>buttonBox</sender> <sender>buttonBox</sender>

View file

@ -88,6 +88,9 @@ DialogFlippingByLine::DialogFlippingByLine(const VContainer *data, quint32 toolI
this, &DialogFlippingByLine::PointChanged); this, &DialogFlippingByLine::PointChanged);
vis = new VisToolFlippingByLine(data); vis = new VisToolFlippingByLine(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -430,3 +433,15 @@ void DialogFlippingByLine::PointChanged()
CheckState(); CheckState();
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogFlippingByLine::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogFlippingByLine::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -74,6 +74,9 @@ public:
void SetVisibilityGroupTags(const QStringList &tags); void SetVisibilityGroupTags(const QStringList &tags);
QStringList GetVisibilityGroupTags() const; QStringList GetVisibilityGroupTags() const;
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void SetGroupCategories(const QStringList &categories) override; virtual void SetGroupCategories(const QStringList &categories) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>304</width> <width>319</width>
<height>237</height> <height>301</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,94 +17,131 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<item row="0" column="0"> <property name="currentIndex">
<widget class="QLabel" name="labelFirstLinePoint"> <number>0</number>
<property name="text">
<string>First line point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxFirstLinePoint"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSuffix">
<property name="text">
<string>Suffix:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QLineEdit" name="lineEditSuffix"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelSecondLinePoint">
<property name="text">
<string>Second line point:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxSecondLinePoint"/>
</item>
</layout>
</item>
<item>
<widget class="QGroupBox" name="groupBoxVisibilityGroup">
<property name="toolTip">
<string>Enable to create a visibility gropup from original objects</string>
</property> </property>
<property name="title"> <widget class="QWidget" name="tab">
<string>Visibility Group</string> <attribute name="title">
</property> <string>Tool</string>
<property name="checkable"> </attribute>
<bool>true</bool> <layout class="QVBoxLayout" name="verticalLayout">
</property> <item>
<property name="checked"> <layout class="QFormLayout" name="formLayout">
<bool>false</bool> <item row="0" column="0">
</property> <widget class="QLabel" name="labelFirstLinePoint">
<layout class="QGridLayout" name="gridLayout"> <property name="text">
<item row="0" column="0"> <string>First line point:</string>
<widget class="QLabel" name="labelGroupName"> </property>
<property name="text"> </widget>
<string>Name:</string> </item>
</property> <item row="0" column="1">
</widget> <widget class="QComboBox" name="comboBoxFirstLinePoint"/>
</item> </item>
<item row="0" column="1"> <item row="2" column="0">
<widget class="QLineEdit" name="lineEditVisibilityGroup"> <widget class="QLabel" name="labelSuffix">
<property name="text"> <property name="text">
<string>Flipping by line</string> <string>Suffix:</string>
</property> </property>
<property name="clearButtonEnabled"> </widget>
<bool>true</bool> </item>
</property> <item row="2" column="1">
</widget> <widget class="QLineEdit" name="lineEditSuffix"/>
</item> </item>
<item row="1" column="0"> <item row="1" column="0">
<widget class="QLabel" name="label"> <widget class="QLabel" name="labelSecondLinePoint">
<property name="text"> <property name="text">
<string>Tags:</string> <string>Second line point:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="1"> <item row="1" column="1">
<widget class="VCompleterLineEdit" name="lineEditGroupTags"> <widget class="QComboBox" name="comboBoxSecondLinePoint"/>
<property name="toolTip"> </item>
<string>Separate each tag with comma.</string> </layout>
</property> </item>
<property name="placeholderText"> <item>
<string>Add tags</string> <widget class="QGroupBox" name="groupBoxVisibilityGroup">
</property> <property name="toolTip">
<property name="clearButtonEnabled"> <string>Enable to create a visibility gropup from original objects</string>
<bool>true</bool> </property>
</property> <property name="title">
</widget> <string>Visibility Group</string>
</item> </property>
</layout> <property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>false</bool>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="labelGroupName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditVisibilityGroup">
<property name="text">
<string>Flipping by line</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Tags:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="VCompleterLineEdit" name="lineEditGroupTags">
<property name="toolTip">
<string>Separate each tag with comma.</string>
</property>
<property name="placeholderText">
<string>Add tags</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget> </widget>
</item> </item>
<item> <item>

View file

@ -90,6 +90,9 @@ DialogHeight::DialogHeight(const VContainer *data, quint32 toolId, QWidget *pare
this, &DialogHeight::PointNameChanged); this, &DialogHeight::PointNameChanged);
vis = new VisToolHeight(data); vis = new VisToolHeight(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -344,3 +347,15 @@ quint32 DialogHeight::GetP2LineId() const
{ {
return getCurrentObjectId(ui->comboBoxP2Line); return getCurrentObjectId(ui->comboBoxP2Line);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogHeight::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogHeight::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -70,6 +70,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>355</width> <width>384</width>
<height>245</height> <height>281</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -22,124 +22,141 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<property name="labelAlignment"> <widget class="QWidget" name="tab">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set> <attribute name="title">
</property> <string>Tool</string>
<item row="0" column="0"> </attribute>
<widget class="QLabel" name="labelEditNamePoint"> <layout class="QFormLayout" name="formLayout_2">
<property name="sizePolicy"> <property name="fieldGrowthPolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <enum>QFormLayout::ExpandingFieldsGrow</enum>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="text">
</property> <string>Point label:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="0" column="1">
</item> <widget class="QLineEdit" name="lineEditNamePoint">
<item row="1" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelBasePoint"> <string>Unique label</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <property name="placeholderText">
<horstretch>0</horstretch> <string>Choose unique label.</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>Base point:</string> <widget class="QLabel" name="labelBasePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxBasePoint"/> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelFirstLinePoint"> <string>Base point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxBasePoint"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>First point of line:</string> <widget class="QLabel" name="labelFirstLinePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxP1Line"/> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondLinePoint"> <string>First point of line:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="2" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxP1Line"/>
</property> </item>
<property name="text"> <item row="3" column="0">
<string>Second point of line:</string> <widget class="QLabel" name="labelSecondLinePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="3" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxP2Line"/> </sizepolicy>
</item> </property>
<item row="4" column="0"> <property name="text">
<widget class="QLabel" name="label_7"> <string>Second point of line:</string>
<property name="text"> </property>
<string>Type of line:</string> </widget>
</property> </item>
</widget> <item row="3" column="1">
</item> <widget class="QComboBox" name="comboBoxP2Line"/>
<item row="4" column="1"> </item>
<widget class="QComboBox" name="comboBoxLineType"> <item row="4" column="0">
<property name="minimumSize"> <widget class="QLabel" name="label_7">
<size> <property name="text">
<width>80</width> <string>Type of line:</string>
<height>0</height> </property>
</size> </widget>
</property> </item>
<property name="maximumSize"> <item row="4" column="1">
<size> <widget class="QComboBox" name="comboBoxLineType">
<width>110</width> <property name="minimumSize">
<height>16777215</height> <size>
</size> <width>80</width>
</property> <height>0</height>
<property name="iconSize"> </size>
<size> </property>
<width>80</width> <property name="maximumSize">
<height>14</height> <size>
</size> <width>110</width>
</property> <height>16777215</height>
</widget> </size>
</item> </property>
<item row="5" column="0"> <property name="iconSize">
<widget class="QLabel" name="label"> <size>
<property name="text"> <width>80</width>
<string>Line color:</string> <height>14</height>
</property> </size>
</widget> </property>
</item> </widget>
<item row="5" column="1"> </item>
<widget class="QComboBox" name="comboBoxLineColor"/> <item row="5" column="0">
</item> <widget class="QLabel" name="label">
</layout> <property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">
@ -154,11 +171,6 @@
</layout> </layout>
</widget> </widget>
<tabstops> <tabstops>
<tabstop>lineEditNamePoint</tabstop>
<tabstop>comboBoxBasePoint</tabstop>
<tabstop>comboBoxP1Line</tabstop>
<tabstop>comboBoxP2Line</tabstop>
<tabstop>comboBoxLineType</tabstop>
<tabstop>buttonBox</tabstop> <tabstop>buttonBox</tabstop>
</tabstops> </tabstops>
<resources> <resources>

View file

@ -72,6 +72,9 @@ DialogLine::DialogLine(const VContainer *data, quint32 toolId, QWidget *parent)
this, &DialogLine::PointNameChanged); this, &DialogLine::PointNameChanged);
vis = new VisToolLine(data); vis = new VisToolLine(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -239,3 +242,15 @@ QString DialogLine::GetTypeLine() const
{ {
return GetComboBoxCurrentData(ui->comboBoxLineType, TypeLineLine); return GetComboBoxCurrentData(ui->comboBoxLineType, TypeLineLine);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogLine::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogLine::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -64,6 +64,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -9,8 +9,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>300</width> <width>350</width>
<height>179</height> <height>213</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -28,120 +28,140 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout_2"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelFirstPoint"> <attribute name="title">
<property name="minimumSize"> <string>Tool</string>
<size> </attribute>
<width>90</width> <layout class="QFormLayout" name="formLayout">
<height>0</height> <property name="fieldGrowthPolicy">
</size> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>First point:</string> <widget class="QLabel" name="labelFirstPoint">
</property> <property name="minimumSize">
</widget> <size>
</item> <width>90</width>
<item row="0" column="1"> <height>0</height>
<widget class="QComboBox" name="comboBoxFirstPoint"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>First point:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="0" column="1">
<size> <widget class="QComboBox" name="comboBoxFirstPoint">
<width>0</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="1" column="0"> <property name="minimumSize">
<widget class="QLabel" name="labelSecondPoint"> <size>
<property name="minimumSize"> <width>0</width>
<size> <height>0</height>
<width>90</width> </size>
<height>0</height> </property>
</size> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>Second point:</string> <widget class="QLabel" name="labelSecondPoint">
</property> <property name="minimumSize">
</widget> <size>
</item> <width>90</width>
<item row="1" column="1"> <height>0</height>
<widget class="QComboBox" name="comboBoxSecondPoint"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Second point:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="1" column="1">
<size> <widget class="QComboBox" name="comboBoxSecondPoint">
<width>0</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="minimumSize">
<widget class="QLabel" name="label_7"> <size>
<property name="minimumSize"> <width>0</width>
<size> <height>0</height>
<width>90</width> </size>
<height>0</height> </property>
</size> </widget>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Type of line:</string> <widget class="QLabel" name="label_7">
</property> <property name="minimumSize">
</widget> <size>
</item> <width>90</width>
<item row="2" column="1"> <height>0</height>
<widget class="QComboBox" name="comboBoxLineType"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Type of line:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="2" column="1">
<size> <widget class="QComboBox" name="comboBoxLineType">
<width>80</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="maximumSize"> </sizepolicy>
<size> </property>
<width>110</width> <property name="minimumSize">
<height>16777215</height> <size>
</size> <width>80</width>
</property> <height>0</height>
<property name="iconSize"> </size>
<size> </property>
<width>80</width> <property name="maximumSize">
<height>14</height> <size>
</size> <width>110</width>
</property> <height>16777215</height>
</widget> </size>
</item> </property>
<item row="3" column="0"> <property name="iconSize">
<widget class="QLabel" name="label"> <size>
<property name="text"> <width>80</width>
<string>Line color:</string> <height>14</height>
</property> </size>
</widget> </property>
</item> </widget>
<item row="3" column="1"> </item>
<widget class="QComboBox" name="comboBoxLineColor"/> <item row="3" column="0">
</item> <widget class="QLabel" name="label">
</layout> <property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">
@ -156,9 +176,6 @@
</layout> </layout>
</widget> </widget>
<tabstops> <tabstops>
<tabstop>comboBoxFirstPoint</tabstop>
<tabstop>comboBoxSecondPoint</tabstop>
<tabstop>comboBoxLineType</tabstop>
<tabstop>buttonBox</tabstop> <tabstop>buttonBox</tabstop>
</tabstops> </tabstops>
<resources> <resources>

View file

@ -93,6 +93,9 @@ DialogLineIntersect::DialogLineIntersect(const VContainer *data, quint32 toolId,
this, &DialogLineIntersect::PointNameChanged); this, &DialogLineIntersect::PointNameChanged);
vis = new VisToolLineIntersect(data); vis = new VisToolLineIntersect(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -403,3 +406,15 @@ quint32 DialogLineIntersect::GetP2Line2() const
{ {
return getCurrentObjectId(ui->comboBoxP2Line2); return getCurrentObjectId(ui->comboBoxP2Line2);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogLineIntersect::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogLineIntersect::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -67,6 +67,9 @@ public:
QString GetPointName() const; QString GetPointName() const;
void SetPointName(const QString &value); void SetPointName(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
void PointChanged(); void PointChanged();

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>375</width> <width>401</width>
<height>196</height> <height>280</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -20,108 +20,149 @@
<property name="locale"> <property name="locale">
<locale language="English" country="UnitedStates"/> <locale language="English" country="UnitedStates"/>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout_4">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_4"> <widget class="QTabWidget" name="tabWidget">
<item> <property name="currentIndex">
<widget class="QLabel" name="labelEditNamePoint"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QLabel" name="label">
<property name="text">
<string>First line</string>
</property> </property>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>Tool</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>First line</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="labelP1Line1">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP1Line1"/>
</item>
<item>
<widget class="QLabel" name="labelP2Line1">
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP2Line1"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_2">
<property name="title">
<string>Second line</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="QLabel" name="labelP1Line2">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP1Line2"/>
</item>
<item>
<widget class="QLabel" name="labelP2Line2">
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP2Line2"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_5">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget> </widget>
</item> </item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="labelP1Line1">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP1Line1"/>
</item>
<item>
<widget class="QLabel" name="labelP2Line1">
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP2Line1"/>
</item>
</layout>
</item>
<item>
<widget class="QLabel" name="label_2">
<property name="text">
<string>Second line</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="QLabel" name="labelP1Line2">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP1Line2"/>
</item>
<item>
<widget class="QLabel" name="labelP2Line2">
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxP2Line2"/>
</item>
</layout>
</item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">
<property name="orientation"> <property name="orientation">

View file

@ -109,6 +109,9 @@ DialogLineIntersectAxis::DialogLineIntersectAxis(const VContainer *data, quint32
this, &DialogLineIntersectAxis::PointNameChanged); this, &DialogLineIntersectAxis::PointNameChanged);
vis = new VisToolLineIntersectAxis(data); vis = new VisToolLineIntersectAxis(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -412,3 +415,15 @@ void DialogLineIntersectAxis::closeEvent(QCloseEvent *event)
ui->plainTextEditFormula->blockSignals(true); ui->plainTextEditFormula->blockSignals(true);
DialogTool::closeEvent(event); DialogTool::closeEvent(event);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogLineIntersectAxis::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogLineIntersectAxis::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -72,6 +72,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>457</width> <width>340</width>
<height>321</height> <height>357</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,327 +17,364 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_9"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Angle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprAngle">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_10">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="baseSize">
<size>
<width>4</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="lineWrapMode">
<enum>QPlainTextEdit::NoWrap</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLengthAngle">
<property name="maximumSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelAxisPoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout_9">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Axis point:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QComboBox" name="comboBoxAxisPoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Axis Point</string> <palette>
</property> <active>
</widget> <colorrole role="WindowText">
</item> <brush brushstyle="SolidPattern">
<item row="1" column="0"> <color alpha="255">
<widget class="QLabel" name="labelFirstLinePoint"> <red>255</red>
<property name="sizePolicy"> <green>0</green>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <blue>0</blue>
<horstretch>0</horstretch> </color>
<verstretch>0</verstretch> </brush>
</sizepolicy> </colorrole>
</property> </active>
<property name="text"> <inactive>
<string>First line point:</string> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
</widget> <color alpha="255">
</item> <red>255</red>
<item row="1" column="1"> <green>0</green>
<widget class="QComboBox" name="comboBoxFirstLinePoint"> <blue>0</blue>
<property name="toolTip"> </color>
<string>First point of line</string> </brush>
</property> </colorrole>
</widget> </inactive>
</item> <disabled>
<item row="2" column="0"> <colorrole role="WindowText">
<widget class="QLabel" name="labelSecondLinePoint"> <brush brushstyle="SolidPattern">
<property name="sizePolicy"> <color alpha="255">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <red>159</red>
<horstretch>0</horstretch> <green>158</green>
<verstretch>0</verstretch> <blue>158</blue>
</sizepolicy> </color>
</property> </brush>
<property name="text"> </colorrole>
<string>Second line point:</string> </disabled>
</property> </palette>
</widget> </property>
</item> <property name="text">
<item row="2" column="1"> <string>Angle:</string>
<widget class="QComboBox" name="comboBoxSecondLinePoint"> </property>
<property name="toolTip"> </widget>
<string>Second point of line</string> </item>
</property> <item>
</widget> <spacer name="horizontalSpacer_2">
</item> <property name="orientation">
<item row="3" column="0"> <enum>Qt::Horizontal</enum>
<widget class="QLabel" name="labelEditNamePoint"> </property>
<property name="sizePolicy"> <property name="sizeHint" stdset="0">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <size>
<horstretch>0</horstretch> <width>40</width>
<verstretch>0</verstretch> <height>20</height>
</sizepolicy> </size>
</property> </property>
<property name="text"> </spacer>
<string>Point label:</string> </item>
</property> <item alignment="Qt::AlignRight">
</widget> <widget class="QToolButton" name="toolButtonExprAngle">
</item> <property name="toolTip">
<item row="3" column="1"> <string>Formula wizard</string>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="sizePolicy"> <property name="text">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <string notr="true">...</string>
<horstretch>0</horstretch> </property>
<verstretch>0</verstretch> <property name="icon">
</sizepolicy> <iconset resource="../../../vmisc/share/resources/icon.qrc">
</property> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="iconSize">
</property> <size>
<property name="placeholderText"> <width>24</width>
<string>Choose unique label.</string> <height>24</height>
</property> </size>
</widget> </property>
</item> </widget>
<item row="4" column="0"> </item>
<widget class="QLabel" name="label_7"> <item alignment="Qt::AlignRight">
<property name="text"> <widget class="QLabel" name="label_3">
<string>Type of line:</string> <property name="text">
</property> <string/>
</widget> </property>
</item> <property name="pixmap">
<item row="4" column="1"> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
<widget class="QComboBox" name="comboBoxLineType"> </property>
<property name="minimumSize"> </widget>
<size> </item>
<width>80</width> <item alignment="Qt::AlignRight">
<height>0</height> <widget class="QLabel" name="labelResultCalculation">
</size> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<property name="maximumSize"> <horstretch>0</horstretch>
<size> <verstretch>0</verstretch>
<width>110</width> </sizepolicy>
<height>16777215</height> </property>
</size> <property name="minimumSize">
</property> <size>
<property name="toolTip"> <width>87</width>
<string>Show line from first point to this point</string> <height>0</height>
</property> </size>
<property name="iconSize"> </property>
<size> <property name="toolTip">
<width>80</width> <string>Value</string>
<height>14</height> </property>
</size> <property name="text">
</property> <string notr="true">_</string>
</widget> </property>
</item> </widget>
<item row="5" column="0"> </item>
<widget class="QLabel" name="label"> </layout>
<property name="text"> </item>
<string>Line color:</string> <item>
</property> <layout class="QHBoxLayout" name="horizontalLayout_10">
</widget> <item>
</item> <widget class="VPlainTextEdit" name="plainTextEditFormula">
<item row="5" column="1"> <property name="sizePolicy">
<widget class="QComboBox" name="comboBoxLineColor"/> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
</layout> <verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="baseSize">
<size>
<width>4</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
<property name="lineWrapMode">
<enum>QPlainTextEdit::NoWrap</enum>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLengthAngle">
<property name="maximumSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelAxisPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Axis point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxAxisPoint">
<property name="toolTip">
<string>Axis Point</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelFirstLinePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First line point:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxFirstLinePoint">
<property name="toolTip">
<string>First point of line</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSecondLinePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Second line point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxSecondLinePoint">
<property name="toolTip">
<string>Second point of line</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Type of line:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxLineType">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string>Show line from first point to this point</string>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -146,6 +146,9 @@ DialogMove::DialogMove(const VContainer *data, quint32 toolId, QWidget *parent)
vis = new VisToolMove(data); vis = new VisToolMove(data);
SetRotationOrigPointId(NULL_ID); SetRotationOrigPointId(NULL_ID);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -634,3 +637,15 @@ void DialogMove::EvalLength()
Eval(formulaData, flagLength); Eval(formulaData, flagLength);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogMove::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogMove::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -79,6 +79,9 @@ public:
void SetVisibilityGroupTags(const QStringList &tags); void SetVisibilityGroupTags(const QStringList &tags);
QStringList GetVisibilityGroupTags() const; QStringList GetVisibilityGroupTags() const;
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void SetGroupCategories(const QStringList &categories) override; virtual void SetGroupCategories(const QStringList &categories) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

File diff suppressed because it is too large Load diff

View file

@ -114,6 +114,9 @@ DialogNormal::DialogNormal(const VContainer *data, quint32 toolId, QWidget *pare
this, &DialogNormal::PointNameChanged); this, &DialogNormal::PointNameChanged);
vis = new VisToolNormal(data); vis = new VisToolNormal(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -403,3 +406,15 @@ quint32 DialogNormal::GetSecondPointId() const
{ {
return getCurrentObjectId(ui->comboBoxSecondPoint); return getCurrentObjectId(ui->comboBoxSecondPoint);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogNormal::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogNormal::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -73,6 +73,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

File diff suppressed because it is too large Load diff

View file

@ -64,6 +64,9 @@ DialogPointFromArcAndTangent::DialogPointFromArcAndTangent(const VContainer *dat
}); });
vis = new VisToolPointFromArcAndTangent(data); vis = new VisToolPointFromArcAndTangent(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -198,3 +201,15 @@ void DialogPointFromArcAndTangent::SaveData()
point->setCrossPoint(GetCrossCirclesPoint()); point->setCrossPoint(GetCrossCirclesPoint());
point->RefreshGeometry(); point->RefreshGeometry();
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointFromArcAndTangent::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointFromArcAndTangent::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -64,6 +64,9 @@ public:
CrossCirclesPoint GetCrossCirclesPoint() const; CrossCirclesPoint GetCrossCirclesPoint() const;
void SetCrossCirclesPoint(CrossCirclesPoint p); void SetCrossCirclesPoint(CrossCirclesPoint p);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>370</width> <width>304</width>
<height>179</height> <height>215</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,102 +19,122 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="text">
</property> <string>Point label:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="0" column="1">
</item> <widget class="QLineEdit" name="lineEditNamePoint">
<item row="1" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelTangentPoint"> <string>Unique label</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="placeholderText">
<horstretch>0</horstretch> <string>Choose unique label.</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>Tangent point:</string> <widget class="QLabel" name="labelTangentPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxTangentPoint"> </sizepolicy>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Tangent point:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="1" column="1">
<size> <widget class="QComboBox" name="comboBoxTangentPoint">
<width>143</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="minimumSize">
<widget class="QLabel" name="labelArc"> <size>
<property name="sizePolicy"> <width>143</width>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <height>0</height>
<horstretch>0</horstretch> </size>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Arc:</string> <widget class="QLabel" name="labelArc">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxArc"> </sizepolicy>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Arc:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="2" column="1">
<size> <widget class="QComboBox" name="comboBoxArc">
<width>145</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="minimumSize">
<widget class="QLabel" name="label"> <size>
<property name="text"> <width>145</width>
<string>Take:</string> <height>0</height>
</property> </size>
</widget> </property>
</item> </widget>
<item row="3" column="1"> </item>
<widget class="QComboBox" name="comboBoxResult"/> <item row="3" column="0">
</item> <widget class="QLabel" name="label">
</layout> <property name="text">
<string>Take:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxResult"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -103,6 +103,9 @@ DialogPointFromCircleAndTangent::DialogPointFromCircleAndTangent(const VContaine
&DialogPointFromCircleAndTangent::DeployCircleRadiusTextEdit); &DialogPointFromCircleAndTangent::DeployCircleRadiusTextEdit);
vis = new VisToolPointFromCircleAndTangent(data); vis = new VisToolPointFromCircleAndTangent(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -330,3 +333,15 @@ void DialogPointFromCircleAndTangent::closeEvent(QCloseEvent *event)
ui->plainTextEditRadius->blockSignals(true); ui->plainTextEditRadius->blockSignals(true);
DialogTool::closeEvent(event); DialogTool::closeEvent(event);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointFromCircleAndTangent::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointFromCircleAndTangent::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -67,6 +67,9 @@ public:
CrossCirclesPoint GetCrossCirclesPoint() const; CrossCirclesPoint GetCrossCirclesPoint() const;
void SetCrossCirclesPoint(const CrossCirclesPoint &p); void SetCrossCirclesPoint(const CrossCirclesPoint &p);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
void PointChanged(); void PointChanged();

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>430</width> <width>365</width>
<height>255</height> <height>298</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,284 +17,321 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_2"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditRadius"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Radius:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprRadius">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircleRadius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="VPlainTextEdit" name="plainTextEditRadius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowRadius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout_2">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditRadius">
<string>Point label:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Unique label</string> <palette>
</property> <active>
<property name="placeholderText"> <colorrole role="WindowText">
<string>Choose unique label.</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="0"> <blue>0</blue>
<widget class="QLabel" name="labelCircleCenter"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </colorrole>
<horstretch>0</horstretch> </active>
<verstretch>0</verstretch> <inactive>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="text"> <color alpha="255">
<string>Center of the circle:</string> <red>255</red>
</property> <green>0</green>
</widget> <blue>0</blue>
</item> </color>
<item row="1" column="1"> </brush>
<widget class="QComboBox" name="comboBoxCircleCenter"> </colorrole>
<property name="sizePolicy"> </inactive>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <disabled>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>159</red>
<property name="minimumSize"> <green>158</green>
<size> <blue>158</blue>
<width>145</width> </color>
<height>0</height> </brush>
</size> </colorrole>
</property> </disabled>
</widget> </palette>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelTangentPoint"> <string>Radius:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item>
</sizepolicy> <spacer name="horizontalSpacer_2">
</property> <property name="orientation">
<property name="text"> <enum>Qt::Horizontal</enum>
<string>Tangent point:</string> </property>
</property> <property name="sizeHint" stdset="0">
</widget> <size>
</item> <width>40</width>
<item row="2" column="1"> <height>20</height>
<widget class="QComboBox" name="comboBoxTangentPoint"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </spacer>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item alignment="Qt::AlignRight">
</sizepolicy> <widget class="QToolButton" name="toolButtonExprRadius">
</property> <property name="toolTip">
<property name="minimumSize"> <string>Formula wizard</string>
<size> </property>
<width>143</width> <property name="text">
<height>0</height> <string notr="true">...</string>
</size> </property>
</property> <property name="icon">
</widget> <iconset resource="../../../vmisc/share/resources/icon.qrc">
</item> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<item row="3" column="0"> </property>
<widget class="QLabel" name="label"> <property name="iconSize">
<property name="text"> <size>
<string>Take:</string> <width>24</width>
</property> <height>24</height>
</widget> </size>
</item> </property>
<item row="3" column="1"> </widget>
<widget class="QComboBox" name="comboBoxResult"/> </item>
</item> <item alignment="Qt::AlignRight">
</layout> <widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircleRadius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="VPlainTextEdit" name="plainTextEditRadius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowRadius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelCircleCenter">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Center of the circle:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxCircleCenter">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>145</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelTangentPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Tangent point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxTangentPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>143</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Take:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxResult"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -104,6 +104,9 @@ DialogPointOfContact::DialogPointOfContact(const VContainer *data, quint32 toolI
this, &DialogPointOfContact::PointNameChanged); this, &DialogPointOfContact::PointNameChanged);
vis = new VisToolPointOfContact(data); vis = new VisToolPointOfContact(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -381,3 +384,15 @@ quint32 DialogPointOfContact::GetSecondPoint() const
{ {
return getCurrentObjectId(ui->comboBoxSecondPoint); return getCurrentObjectId(ui->comboBoxSecondPoint);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointOfContact::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointOfContact::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -68,6 +68,9 @@ public:
quint32 GetSecondPoint() const; quint32 GetSecondPoint() const;
void SetSecondPoint(quint32 value); void SetSecondPoint(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>498</width> <width>348</width>
<height>255</height> <height>295</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -20,315 +20,352 @@
<property name="locale"> <property name="locale">
<locale language="English" country="UnitedStates"/> <locale language="English" country="UnitedStates"/>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_2"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Radius:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprRadius">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_formula">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout_2">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Point label:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Unique label</string> <palette>
</property> <active>
<property name="placeholderText"> <colorrole role="WindowText">
<string>Choose unique label.</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="0"> <blue>0</blue>
<widget class="QLabel" name="labelArcCenter"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </colorrole>
<horstretch>0</horstretch> </active>
<verstretch>0</verstretch> <inactive>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="text"> <color alpha="255">
<string>Center of arc:</string> <red>255</red>
</property> <green>0</green>
</widget> <blue>0</blue>
</item> </color>
<item row="1" column="1"> </brush>
<widget class="QComboBox" name="comboBoxCenter"> </colorrole>
<property name="sizePolicy"> </inactive>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <disabled>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>159</red>
<property name="minimumSize"> <green>158</green>
<size> <blue>158</blue>
<width>145</width> </color>
<height>0</height> </brush>
</size> </colorrole>
</property> </disabled>
</widget> </palette>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelFirstPoint"> <string>Radius:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item>
</sizepolicy> <spacer name="horizontalSpacer">
</property> <property name="orientation">
<property name="text"> <enum>Qt::Horizontal</enum>
<string>Top of the line:</string> </property>
</property> <property name="sizeHint" stdset="0">
</widget> <size>
</item> <width>40</width>
<item row="2" column="1"> <height>20</height>
<widget class="QComboBox" name="comboBoxFirstPoint"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </spacer>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item alignment="Qt::AlignRight">
</sizepolicy> <widget class="QToolButton" name="toolButtonExprRadius">
</property> <property name="toolTip">
<property name="minimumSize"> <string>Formula wizard</string>
<size> </property>
<width>143</width> <property name="text">
<height>0</height> <string notr="true">...</string>
</size> </property>
</property> <property name="icon">
</widget> <iconset resource="../../../vmisc/share/resources/icon.qrc">
</item> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<item row="3" column="0"> </property>
<widget class="QLabel" name="labelSecondPoint"> <property name="iconSize">
<property name="sizePolicy"> <size>
<sizepolicy hsizetype="Expanding" vsizetype="Preferred"> <width>24</width>
<horstretch>0</horstretch> <height>24</height>
<verstretch>0</verstretch> </size>
</sizepolicy> </property>
</property> </widget>
<property name="text"> </item>
<string>End of the line:</string> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="label">
</widget> <property name="text">
</item> <string/>
<item row="3" column="1"> </property>
<widget class="QComboBox" name="comboBoxSecondPoint"> <property name="pixmap">
<property name="sizePolicy"> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </property>
<horstretch>0</horstretch> </widget>
<verstretch>0</verstretch> </item>
</sizepolicy> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="labelResultCalculation">
<property name="minimumSize"> <property name="sizePolicy">
<size> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<width>80</width> <horstretch>0</horstretch>
<height>0</height> <verstretch>0</verstretch>
</size> </sizepolicy>
</property> </property>
<property name="maximumSize"> <property name="minimumSize">
<size> <size>
<width>110</width> <width>87</width>
<height>16777215</height> <height>0</height>
</size> </size>
</property> </property>
<property name="iconSize"> <property name="toolTip">
<size> <string>Value</string>
<width>80</width> </property>
<height>14</height> <property name="text">
</size> <string notr="true">_</string>
</property> </property>
</widget> </widget>
</item> </item>
</layout> </layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_formula">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelArcCenter">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Center of arc:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxCenter">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>145</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelFirstPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Top of the line:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxFirstPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>143</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelSecondPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>End of the line:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxSecondPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -78,6 +78,9 @@ DialogPointOfIntersection::DialogPointOfIntersection(const VContainer *data, qui
vis = new VisToolPointOfIntersection(data); vis = new VisToolPointOfIntersection(data);
vis->VisualMode(NULL_ID);//Show vertical axis vis->VisualMode(NULL_ID);//Show vertical axis
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -232,3 +235,15 @@ quint32 DialogPointOfIntersection::GetSecondPointId() const
{ {
return getCurrentObjectId(ui->comboBoxSecondPoint); return getCurrentObjectId(ui->comboBoxSecondPoint);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointOfIntersection::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointOfIntersection::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -61,6 +61,9 @@ public:
quint32 GetSecondPointId() const; quint32 GetSecondPointId() const;
void SetSecondPointId(quint32 value); void SetSecondPointId(quint32 value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>340</width> <width>304</width>
<height>146</height> <height>194</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,78 +19,98 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Point label:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="toolTip"> <item row="0" column="1">
<string>Unique label</string> <widget class="QLineEdit" name="lineEditNamePoint">
</property> <property name="sizePolicy">
<property name="placeholderText"> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<string>Choose unique label.</string> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="1" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelFirstPoint"> <string>Unique label</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <property name="placeholderText">
<horstretch>0</horstretch> <string>Choose unique label.</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="1" column="0">
<size> <widget class="QLabel" name="labelFirstPoint">
<width>0</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="text"> </sizepolicy>
<string>X: vertical point:</string> </property>
</property> <property name="minimumSize">
</widget> <size>
</item> <width>0</width>
<item row="1" column="1"> <height>0</height>
<widget class="QComboBox" name="comboBoxFirstPoint"/> </size>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondPoint"> <string>X: vertical point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxFirstPoint"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Y: horizontal point:</string> <widget class="QLabel" name="labelSecondPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxSecondPoint"/> </sizepolicy>
</item> </property>
</layout> <property name="text">
<string>Y: horizontal point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxSecondPoint"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">
@ -105,9 +125,6 @@
</layout> </layout>
</widget> </widget>
<tabstops> <tabstops>
<tabstop>lineEditNamePoint</tabstop>
<tabstop>comboBoxFirstPoint</tabstop>
<tabstop>comboBoxSecondPoint</tabstop>
<tabstop>buttonBox</tabstop> <tabstop>buttonBox</tabstop>
</tabstops> </tabstops>
<resources> <resources>

View file

@ -71,6 +71,9 @@ DialogPointOfIntersectionArcs::DialogPointOfIntersectionArcs(const VContainer *d
this, &DialogPointOfIntersectionArcs::ArcChanged); this, &DialogPointOfIntersectionArcs::ArcChanged);
vis = new VisToolPointOfIntersectionArcs(data); vis = new VisToolPointOfIntersectionArcs(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -221,3 +224,15 @@ void DialogPointOfIntersectionArcs::SaveData()
point->setCrossPoint(GetCrossArcPoint()); point->setCrossPoint(GetCrossArcPoint());
point->RefreshGeometry(); point->RefreshGeometry();
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointOfIntersectionArcs::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointOfIntersectionArcs::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -64,6 +64,9 @@ public:
CrossCirclesPoint GetCrossArcPoint() const; CrossCirclesPoint GetCrossArcPoint() const;
void SetCrossArcPoint(CrossCirclesPoint p); void SetCrossArcPoint(CrossCirclesPoint p);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void ArcChanged(); virtual void ArcChanged();

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>300</width> <width>304</width>
<height>179</height> <height>212</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,76 +19,96 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="text">
</property> <string>Point label:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="0" column="1">
</item> <widget class="QLineEdit" name="lineEditNamePoint">
<item row="1" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelArc1"> <string>Unique label</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <property name="placeholderText">
<horstretch>0</horstretch> <string>Choose unique label.</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>First arc:</string> <widget class="QLabel" name="labelArc1">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxArc1"/> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelArc2"> <string>First arc:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxArc1"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Second arc:</string> <widget class="QLabel" name="labelArc2">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxArc2"/> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="text">
<widget class="QLabel" name="label"> <string>Second arc:</string>
<property name="text"> </property>
<string>Take:</string> </widget>
</property> </item>
</widget> <item row="2" column="1">
</item> <widget class="QComboBox" name="comboBoxArc2"/>
<item row="3" column="1"> </item>
<widget class="QComboBox" name="comboBoxResult"/> <item row="3" column="0">
</item> <widget class="QLabel" name="label">
</layout> <property name="text">
<string>Take:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxResult"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -123,6 +123,9 @@ DialogPointOfIntersectionCircles::DialogPointOfIntersectionCircles(const VContai
&DialogPointOfIntersectionCircles::DeployCircle2RadiusTextEdit); &DialogPointOfIntersectionCircles::DeployCircle2RadiusTextEdit);
vis = new VisToolPointOfIntersectionCircles(data); vis = new VisToolPointOfIntersectionCircles(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -420,3 +423,15 @@ void DialogPointOfIntersectionCircles::closeEvent(QCloseEvent *event)
ui->plainTextEditCircle2Radius->blockSignals(true); ui->plainTextEditCircle2Radius->blockSignals(true);
DialogTool::closeEvent(event); DialogTool::closeEvent(event);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointOfIntersectionCircles::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointOfIntersectionCircles::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -70,6 +70,9 @@ public:
CrossCirclesPoint GetCrossCirclesPoint() const; CrossCirclesPoint GetCrossCirclesPoint() const;
void SetCrossCirclesPoint(const CrossCirclesPoint &p); void SetCrossCirclesPoint(const CrossCirclesPoint &p);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
void PointChanged(); void PointChanged();

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>401</width> <width>417</width>
<height>331</height> <height>370</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,464 +17,501 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditCircle1Radius"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Radius of the first circle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprCircle1Radius">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_2">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircle1Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="VPlainTextEdit" name="plainTextEditCircle1Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowCircle1Radius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item alignment="Qt::AlignLeft">
<widget class="QLabel" name="labelEditCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Radius of the second circle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprCircle2Radius">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="VPlainTextEdit" name="plainTextEditCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowCircle2Radius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditCircle1Radius">
<string>Point label:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Unique label</string> <palette>
</property> <active>
<property name="placeholderText"> <colorrole role="WindowText">
<string>Choose unique label.</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="0"> <blue>0</blue>
<widget class="QLabel" name="labelCircle1Center"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </colorrole>
<horstretch>0</horstretch> </active>
<verstretch>0</verstretch> <inactive>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="text"> <color alpha="255">
<string>Center of the first circle:</string> <red>255</red>
</property> <green>0</green>
</widget> <blue>0</blue>
</item> </color>
<item row="1" column="1"> </brush>
<widget class="QComboBox" name="comboBoxCircle1Center"> </colorrole>
<property name="sizePolicy"> </inactive>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <disabled>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>159</red>
<property name="minimumSize"> <green>158</green>
<size> <blue>158</blue>
<width>145</width> </color>
<height>0</height> </brush>
</size> </colorrole>
</property> </disabled>
</widget> </palette>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelCircle2Center"> <string>Radius of the first circle:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item>
</sizepolicy> <spacer name="horizontalSpacer">
</property> <property name="orientation">
<property name="text"> <enum>Qt::Horizontal</enum>
<string>Center of the second circle:</string> </property>
</property> <property name="sizeHint" stdset="0">
</widget> <size>
</item> <width>40</width>
<item row="2" column="1"> <height>20</height>
<widget class="QComboBox" name="comboBoxCircle2Center"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </spacer>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item alignment="Qt::AlignRight">
</sizepolicy> <widget class="QToolButton" name="toolButtonExprCircle1Radius">
</property> <property name="toolTip">
<property name="minimumSize"> <string>Formula wizard</string>
<size> </property>
<width>143</width> <property name="text">
<height>0</height> <string notr="true">...</string>
</size> </property>
</property> <property name="icon">
</widget> <iconset resource="../../../vmisc/share/resources/icon.qrc">
</item> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<item row="3" column="0"> </property>
<widget class="QLabel" name="label"> <property name="iconSize">
<property name="text"> <size>
<string>Take:</string> <width>24</width>
</property> <height>24</height>
</widget> </size>
</item> </property>
<item row="3" column="1"> </widget>
<widget class="QComboBox" name="comboBoxResult"/> </item>
</item> <item alignment="Qt::AlignRight">
</layout> <widget class="QLabel" name="label_2">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircle1Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="VPlainTextEdit" name="plainTextEditCircle1Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowCircle1Radius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item alignment="Qt::AlignLeft">
<widget class="QLabel" name="labelEditCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Radius of the second circle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprCircle2Radius">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="VPlainTextEdit" name="plainTextEditCircle2Radius">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowCircle2Radius">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelCircle1Center">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Center of the first circle:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxCircle1Center">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>145</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelCircle2Center">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Center of the second circle:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxCircle2Center">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>143</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Take:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxResult"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -74,6 +74,9 @@ DialogPointOfIntersectionCurves::DialogPointOfIntersectionCurves(const VContaine
this, &DialogPointOfIntersectionCurves::CurveChanged); this, &DialogPointOfIntersectionCurves::CurveChanged);
vis = new VisToolPointOfIntersectionCurves(data); vis = new VisToolPointOfIntersectionCurves(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -248,3 +251,15 @@ void DialogPointOfIntersectionCurves::CurveChanged()
ChangeColor(ui->labelCurve2, color); ChangeColor(ui->labelCurve2, color);
CheckState(); CheckState();
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogPointOfIntersectionCurves::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogPointOfIntersectionCurves::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -66,6 +66,9 @@ public:
HCrossCurvesPoint GetHCrossPoint() const; HCrossCurvesPoint GetHCrossPoint() const;
void SetHCrossPoint(HCrossCurvesPoint hP); void SetHCrossPoint(HCrossCurvesPoint hP);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>285</width> <width>304</width>
<height>212</height> <height>242</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,96 +19,116 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelCurve1"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>First curve:</string> <widget class="QLabel" name="labelCurve1">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxCurve1"> </sizepolicy>
<property name="toolTip"> </property>
<string/> <property name="text">
</property> <string>First curve:</string>
</widget> </property>
</item> </widget>
<item row="1" column="0"> </item>
<widget class="QLabel" name="labelCurve2"> <item row="0" column="1">
<property name="sizePolicy"> <widget class="QComboBox" name="comboBoxCurve1">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <property name="toolTip">
<horstretch>0</horstretch> <string/>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>Second curve:</string> <widget class="QLabel" name="labelCurve2">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxCurve2"/> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelEditNamePoint"> <string>Second curve:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxCurve2"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Point label:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="toolTip"> <item row="2" column="1">
<string>Unique label</string> <widget class="QLineEdit" name="lineEditNamePoint">
</property> <property name="sizePolicy">
<property name="placeholderText"> <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<string>Choose unique label.</string> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
</widget> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="toolTip">
<widget class="QLabel" name="label"> <string>Unique label</string>
<property name="text"> </property>
<string>Vertical correction:</string> <property name="placeholderText">
</property> <string>Choose unique label.</string>
</widget> </property>
</item> </widget>
<item row="3" column="1"> </item>
<widget class="QComboBox" name="comboBoxVCorrection"/> <item row="3" column="0">
</item> <widget class="QLabel" name="label">
<item row="4" column="0"> <property name="text">
<widget class="QLabel" name="label_2"> <string>Vertical correction:</string>
<property name="text"> </property>
<string>Horizontal correction:</string> </widget>
</property> </item>
</widget> <item row="3" column="1">
</item> <widget class="QComboBox" name="comboBoxVCorrection"/>
<item row="4" column="1"> </item>
<widget class="QComboBox" name="comboBoxHCorrection"/> <item row="4" column="0">
</item> <widget class="QLabel" name="label_2">
</layout> <property name="text">
<string>Horizontal correction:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxHCorrection"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -107,6 +107,9 @@ DialogRotation::DialogRotation(const VContainer *data, quint32 toolId, QWidget *
this, &DialogRotation::PointChanged); this, &DialogRotation::PointChanged);
vis = new VisToolRotation(data); vis = new VisToolRotation(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -504,3 +507,15 @@ void DialogRotation::EvalAngle()
Eval(formulaData, flagAngle); Eval(formulaData, flagAngle);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogRotation::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogRotation::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -72,6 +72,9 @@ public:
void SetVisibilityGroupTags(const QStringList &tags); void SetVisibilityGroupTags(const QStringList &tags);
QStringList GetVisibilityGroupTags() const; QStringList GetVisibilityGroupTags() const;
void SetNotes(const QString &notes);
QString GetNotes() const;
virtual void SetGroupCategories(const QStringList &categories) override; virtual void SetGroupCategories(const QStringList &categories) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>392</width> <width>304</width>
<height>282</height> <height>338</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -17,264 +17,301 @@
<iconset resource="../../../vmisc/share/resources/icon.qrc"> <iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset> <normaloff>:/icon/64x64/icon64x64.png</normaloff>:/icon/64x64/icon64x64.png</iconset>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditAngle"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Angle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprAngle">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_2">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultAngle">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<item row="0" column="0">
<widget class="QLabel" name="labelOriginPoint">
<property name="text">
<string>Origin Point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxOriginPoint"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelSuffix">
<property name="text">
<string>Suffix:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditSuffix"/>
</item>
</layout>
</item>
<item>
<widget class="QGroupBox" name="groupBoxVisibilityGroup">
<property name="toolTip">
<string>Enable to create a visibility gropup from original objects</string>
</property> </property>
<property name="title"> <widget class="QWidget" name="tab">
<string>Visibility Group</string> <attribute name="title">
</property> <string>Tool</string>
<property name="checkable"> </attribute>
<bool>true</bool> <layout class="QVBoxLayout" name="verticalLayout">
</property> <item>
<property name="checked"> <layout class="QHBoxLayout" name="horizontalLayout">
<bool>false</bool> <item alignment="Qt::AlignLeft">
</property> <widget class="QLabel" name="labelEditAngle">
<layout class="QGridLayout" name="gridLayout"> <property name="sizePolicy">
<item row="1" column="0"> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<widget class="QLabel" name="label"> <horstretch>0</horstretch>
<property name="text"> <verstretch>0</verstretch>
<string>Tags:</string> </sizepolicy>
</property> </property>
</widget> <property name="palette">
</item> <palette>
<item row="0" column="1"> <active>
<widget class="QLineEdit" name="lineEditVisibilityGroup"> <colorrole role="WindowText">
<property name="text"> <brush brushstyle="SolidPattern">
<string>Rotation</string> <color alpha="255">
</property> <red>255</red>
<property name="clearButtonEnabled"> <green>0</green>
<bool>true</bool> <blue>0</blue>
</property> </color>
</widget> </brush>
</item> </colorrole>
<item row="0" column="0"> </active>
<widget class="QLabel" name="labelGroupName"> <inactive>
<property name="text"> <colorrole role="WindowText">
<string>Name:</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="1"> <blue>0</blue>
<widget class="VCompleterLineEdit" name="lineEditGroupTags"> </color>
<property name="toolTip"> </brush>
<string>Separate each tag with comma.</string> </colorrole>
</property> </inactive>
<property name="placeholderText"> <disabled>
<string>Add tags</string> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="clearButtonEnabled"> <color alpha="255">
<bool>true</bool> <red>159</red>
</property> <green>158</green>
</widget> <blue>158</blue>
</item> </color>
</layout> </brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Angle:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprAngle">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_2">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultAngle">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<item row="0" column="0">
<widget class="QLabel" name="labelOriginPoint">
<property name="text">
<string>Origin Point:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboBoxOriginPoint"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelSuffix">
<property name="text">
<string>Suffix:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineEditSuffix"/>
</item>
</layout>
</item>
<item>
<widget class="QGroupBox" name="groupBoxVisibilityGroup">
<property name="toolTip">
<string>Enable to create a visibility gropup from original objects</string>
</property>
<property name="title">
<string>Visibility Group</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>false</bool>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="1" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Tags:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditVisibilityGroup">
<property name="text">
<string>Rotation</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="labelGroupName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="VCompleterLineEdit" name="lineEditGroupTags">
<property name="toolTip">
<string>Separate each tag with comma.</string>
</property>
<property name="placeholderText">
<string>Add tags</string>
</property>
<property name="clearButtonEnabled">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget> </widget>
</item> </item>
<item> <item>
@ -290,16 +327,16 @@
</layout> </layout>
</widget> </widget>
<customwidgets> <customwidgets>
<customwidget>
<class>VCompleterLineEdit</class>
<extends>QLineEdit</extends>
<header>vlineedit.h</header>
</customwidget>
<customwidget> <customwidget>
<class>VPlainTextEdit</class> <class>VPlainTextEdit</class>
<extends>QPlainTextEdit</extends> <extends>QPlainTextEdit</extends>
<header location="global">vplaintextedit.h</header> <header location="global">vplaintextedit.h</header>
</customwidget> </customwidget>
<customwidget>
<class>VCompleterLineEdit</class>
<extends>QLineEdit</extends>
<header>vlineedit.h</header>
</customwidget>
</customwidgets> </customwidgets>
<resources> <resources>
<include location="../../../vmisc/share/resources/icon.qrc"/> <include location="../../../vmisc/share/resources/icon.qrc"/>

View file

@ -106,6 +106,9 @@ DialogShoulderPoint::DialogShoulderPoint(const VContainer *data, quint32 toolId,
this, &DialogShoulderPoint::PointNameChanged); this, &DialogShoulderPoint::PointNameChanged);
vis = new VisToolShoulderPoint(data); vis = new VisToolShoulderPoint(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -416,3 +419,15 @@ quint32 DialogShoulderPoint::GetP3() const
{ {
return getCurrentObjectId(ui->comboBoxP3); return getCurrentObjectId(ui->comboBoxP3);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogShoulderPoint::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogShoulderPoint::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -73,6 +73,9 @@ public:
QString GetLineColor() const; QString GetLineColor() const;
void SetLineColor(const QString &value); void SetLineColor(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
/** /**

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>488</width> <width>304</width>
<height>321</height> <height>356</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -20,354 +20,391 @@
<property name="locale"> <property name="locale">
<locale language="English" country="UnitedStates"/> <locale language="English" country="UnitedStates"/>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_2"> <widget class="QTabWidget" name="tabWidget">
<item alignment="Qt::AlignLeft"> <property name="currentIndex">
<widget class="QLabel" name="labelEditFormula"> <number>0</number>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>255</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>159</red>
<green>158</green>
<blue>158</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="text">
<string>Length:</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item alignment="Qt::AlignRight">
<widget class="QToolButton" name="toolButtonExprLength">
<property name="toolTip">
<string>Formula wizard</string>
</property>
<property name="text">
<string notr="true">...</string>
</property>
<property name="icon">
<iconset resource="../../../vmisc/share/resources/icon.qrc">
<normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
</property>
</widget>
</item>
<item alignment="Qt::AlignRight">
<widget class="QLabel" name="labelResultCalculation">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>87</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Value</string>
</property>
<property name="text">
<string notr="true">_</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_formula">
<item>
<widget class="VPlainTextEdit" name="plainTextEditFormula">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>28</height>
</size>
</property>
<property name="toolTip">
<string>Calculation</string>
</property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonGrowLength">
<property name="maximumSize">
<size>
<width>18</width>
<height>18</height>
</size>
</property>
<property name="sizeIncrement">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QVBoxLayout" name="verticalLayout">
<verstretch>0</verstretch> <item>
</sizepolicy> <layout class="QHBoxLayout" name="horizontalLayout_2">
</property> <item alignment="Qt::AlignLeft">
<property name="text"> <widget class="QLabel" name="labelEditFormula">
<string>Point label:</string> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
</widget> <horstretch>0</horstretch>
</item> <verstretch>0</verstretch>
<item row="0" column="1"> </sizepolicy>
<widget class="QLineEdit" name="lineEditNamePoint"> </property>
<property name="toolTip"> <property name="palette">
<string>Unique label</string> <palette>
</property> <active>
<property name="placeholderText"> <colorrole role="WindowText">
<string>Choose unique label.</string> <brush brushstyle="SolidPattern">
</property> <color alpha="255">
</widget> <red>255</red>
</item> <green>0</green>
<item row="1" column="0"> <blue>0</blue>
<widget class="QLabel" name="labelFirstPoint"> </color>
<property name="sizePolicy"> </brush>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </colorrole>
<horstretch>0</horstretch> </active>
<verstretch>0</verstretch> <inactive>
</sizepolicy> <colorrole role="WindowText">
</property> <brush brushstyle="SolidPattern">
<property name="text"> <color alpha="255">
<string>First point:</string> <red>255</red>
</property> <green>0</green>
</widget> <blue>0</blue>
</item> </color>
<item row="1" column="1"> </brush>
<widget class="QComboBox" name="comboBoxP1Line"> </colorrole>
<property name="sizePolicy"> </inactive>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <disabled>
<horstretch>0</horstretch> <colorrole role="WindowText">
<verstretch>0</verstretch> <brush brushstyle="SolidPattern">
</sizepolicy> <color alpha="255">
</property> <red>159</red>
<property name="minimumSize"> <green>158</green>
<size> <blue>158</blue>
<width>145</width> </color>
<height>0</height> </brush>
</size> </colorrole>
</property> </disabled>
</widget> </palette>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondPoint"> <string>Length:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item>
</sizepolicy> <spacer name="horizontalSpacer">
</property> <property name="orientation">
<property name="text"> <enum>Qt::Horizontal</enum>
<string>Second point:</string> </property>
</property> <property name="sizeHint" stdset="0">
</widget> <size>
</item> <width>40</width>
<item row="2" column="1"> <height>20</height>
<widget class="QComboBox" name="comboBoxP2Line"> </size>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </spacer>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item alignment="Qt::AlignRight">
</sizepolicy> <widget class="QToolButton" name="toolButtonExprLength">
</property> <property name="toolTip">
<property name="minimumSize"> <string>Formula wizard</string>
<size> </property>
<width>143</width> <property name="text">
<height>0</height> <string notr="true">...</string>
</size> </property>
</property> <property name="icon">
</widget> <iconset resource="../../../vmisc/share/resources/icon.qrc">
</item> <normaloff>:/icon/24x24/fx.png</normaloff>:/icon/24x24/fx.png</iconset>
<item row="3" column="0"> </property>
<widget class="QLabel" name="labelThirdPoint"> <property name="iconSize">
<property name="sizePolicy"> <size>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <width>24</width>
<horstretch>0</horstretch> <height>24</height>
<verstretch>0</verstretch> </size>
</sizepolicy> </property>
</property> </widget>
<property name="text"> </item>
<string>Third point:</string> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="label_3">
</widget> <property name="text">
</item> <string/>
<item row="3" column="1"> </property>
<widget class="QComboBox" name="comboBoxP3"> <property name="pixmap">
<property name="sizePolicy"> <pixmap resource="../../../vmisc/share/resources/icon.qrc">:/icon/24x24/equal.png</pixmap>
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> </property>
<horstretch>0</horstretch> </widget>
<verstretch>0</verstretch> </item>
</sizepolicy> <item alignment="Qt::AlignRight">
</property> <widget class="QLabel" name="labelResultCalculation">
<property name="minimumSize"> <property name="sizePolicy">
<size> <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
<width>145</width> <horstretch>0</horstretch>
<height>0</height> <verstretch>0</verstretch>
</size> </sizepolicy>
</property> </property>
</widget> <property name="minimumSize">
</item> <size>
<item row="4" column="0"> <width>87</width>
<widget class="QLabel" name="label_7"> <height>0</height>
<property name="sizePolicy"> </size>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </property>
<horstretch>0</horstretch> <property name="toolTip">
<verstretch>0</verstretch> <string>Value</string>
</sizepolicy> </property>
</property> <property name="text">
<property name="text"> <string notr="true">_</string>
<string>Type of line:</string> </property>
</property> </widget>
</widget> </item>
</item> </layout>
<item row="4" column="1"> </item>
<widget class="QComboBox" name="comboBoxLineType"> <item>
<property name="sizePolicy"> <layout class="QHBoxLayout" name="horizontalLayout_formula">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <item>
<horstretch>0</horstretch> <widget class="VPlainTextEdit" name="plainTextEditFormula">
<verstretch>0</verstretch> <property name="sizePolicy">
</sizepolicy> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</property> <horstretch>0</horstretch>
<property name="minimumSize"> <verstretch>0</verstretch>
<size> </sizepolicy>
<width>80</width> </property>
<height>0</height> <property name="maximumSize">
</size> <size>
</property> <width>16777215</width>
<property name="maximumSize"> <height>28</height>
<size> </size>
<width>110</width> </property>
<height>16777215</height> <property name="toolTip">
</size> <string>Calculation</string>
</property> </property>
<property name="iconSize"> <property name="tabChangesFocus">
<size> <bool>true</bool>
<width>80</width> </property>
<height>14</height> </widget>
</size> </item>
</property> <item>
</widget> <widget class="QPushButton" name="pushButtonGrowLength">
</item> <property name="maximumSize">
<item row="5" column="0"> <size>
<widget class="QLabel" name="label"> <width>18</width>
<property name="text"> <height>18</height>
<string>Line color:</string> </size>
</property> </property>
</widget> <property name="sizeIncrement">
</item> <size>
<item row="5" column="1"> <width>0</width>
<widget class="QComboBox" name="comboBoxLineColor"/> <height>0</height>
</item> </size>
</layout> </property>
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Show full calculation in message box&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="icon">
<iconset theme="go-down">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="iconSize">
<size>
<width>16</width>
<height>16</height>
</size>
</property>
<property name="flat">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="labelEditNamePoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Point label:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEditNamePoint">
<property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="labelFirstPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>First point:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="comboBoxP1Line">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>145</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="labelSecondPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBoxP2Line">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>143</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="labelThirdPoint">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Third point:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboBoxP3">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>145</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_7">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Type of line:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxLineType">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>110</width>
<height>16777215</height>
</size>
</property>
<property name="iconSize">
<size>
<width>80</width>
<height>14</height>
</size>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Line color:</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QComboBox" name="comboBoxLineColor"/>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

View file

@ -156,6 +156,9 @@ DialogSpline::DialogSpline(const VContainer *data, quint32 toolId, QWidget *pare
SCASSERT(scene != nullptr) SCASSERT(scene != nullptr)
connect(scene, &VMainGraphicsScene::MouseLeftPressed, path, &VisToolSpline::MouseLeftPressed); connect(scene, &VMainGraphicsScene::MouseLeftPressed, path, &VisToolSpline::MouseLeftPressed);
connect(scene, &VMainGraphicsScene::MouseLeftReleased, path, &VisToolSpline::MouseLeftReleased); connect(scene, &VMainGraphicsScene::MouseLeftReleased, path, &VisToolSpline::MouseLeftReleased);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -597,3 +600,15 @@ void DialogSpline::SetSpline(const VSpline &spline)
path->SetKCurve(spl.GetKcurve()); path->SetKCurve(spl.GetKcurve());
path->setApproximationScale(spl.GetApproximationScale()); path->setApproximationScale(spl.GetApproximationScale());
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogSpline::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogSpline::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -58,6 +58,9 @@ public:
VSpline GetSpline() const; VSpline GetSpline() const;
void SetSpline(const VSpline &spline); void SetSpline(const VSpline &spline);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

File diff suppressed because it is too large Load diff

View file

@ -133,6 +133,9 @@ DialogSplinePath::DialogSplinePath(const VContainer *data, quint32 toolId, QWidg
SCASSERT(scene != nullptr) SCASSERT(scene != nullptr)
connect(scene, &VMainGraphicsScene::MouseLeftPressed, path, &VisToolSplinePath::MouseLeftPressed); connect(scene, &VMainGraphicsScene::MouseLeftPressed, path, &VisToolSplinePath::MouseLeftPressed);
connect(scene, &VMainGraphicsScene::MouseLeftReleased, path, &VisToolSplinePath::MouseLeftReleased); connect(scene, &VMainGraphicsScene::MouseLeftReleased, path, &VisToolSplinePath::MouseLeftReleased);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -944,3 +947,15 @@ bool DialogSplinePath::IsValid() const
return fAngle1 && fAngle2 && fLength1 && fLength2 && flagError; return fAngle1 && fAngle2 && fLength1 && fLength2 && flagError;
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogSplinePath::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogSplinePath::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -58,6 +58,9 @@ public:
VSplinePath GetPath() const; VSplinePath GetPath() const;
void SetPath(const VSplinePath &value); void SetPath(const VSplinePath &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void ShowDialog(bool click) override; virtual void ShowDialog(bool click) override;

File diff suppressed because it is too large Load diff

View file

@ -83,6 +83,9 @@ DialogTriangle::DialogTriangle(const VContainer *data, quint32 toolId, QWidget *
this, &DialogTriangle::PointNameChanged); this, &DialogTriangle::PointNameChanged);
vis = new VisToolTriangle(data); vis = new VisToolTriangle(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -331,3 +334,15 @@ quint32 DialogTriangle::GetSecondPointId() const
{ {
return getCurrentObjectId(ui->comboBoxSecondPoint); return getCurrentObjectId(ui->comboBoxSecondPoint);
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogTriangle::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogTriangle::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -67,6 +67,9 @@ public:
QString GetPointName() const; QString GetPointName() const;
void SetPointName(const QString &value); void SetPointName(const QString &value);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>348</width> <width>304</width>
<height>212</height> <height>242</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -22,98 +22,118 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelEditNamePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Point label:</string> <widget class="QLabel" name="labelEditNamePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditNamePoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="text">
</property> <string>Point label:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="0" column="1">
</item> <widget class="QLineEdit" name="lineEditNamePoint">
<item row="1" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelAxisP1"> <string>Unique label</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Preferred"> <property name="placeholderText">
<horstretch>0</horstretch> <string>Choose unique label.</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>First point of axis:</string> <widget class="QLabel" name="labelAxisP1">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxAxisP1"/> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelAxisP2"> <string>First point of axis:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxAxisP1"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>Second point of axis:</string> <widget class="QLabel" name="labelAxisP2">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxAxisP2"/> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="text">
<widget class="QLabel" name="labelFirstPoint"> <string>Second point of axis:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="2" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxAxisP2"/>
</property> </item>
<property name="text"> <item row="3" column="0">
<string>First point:</string> <widget class="QLabel" name="labelFirstPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="3" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxFirstPoint"/> </sizepolicy>
</item> </property>
<item row="4" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondPoint"> <string>First point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Expanding" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="3" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxFirstPoint"/>
</property> </item>
<property name="text"> <item row="4" column="0">
<string>Second point:</string> <widget class="QLabel" name="labelSecondPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="4" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxSecondPoint"/> </sizepolicy>
</item> </property>
</layout> <property name="text">
<string>Second point:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboBoxSecondPoint"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">
@ -128,11 +148,6 @@
</layout> </layout>
</widget> </widget>
<tabstops> <tabstops>
<tabstop>lineEditNamePoint</tabstop>
<tabstop>comboBoxAxisP1</tabstop>
<tabstop>comboBoxAxisP2</tabstop>
<tabstop>comboBoxFirstPoint</tabstop>
<tabstop>comboBoxSecondPoint</tabstop>
<tabstop>buttonBox</tabstop> <tabstop>buttonBox</tabstop>
</tabstops> </tabstops>
<resources> <resources>

View file

@ -89,6 +89,9 @@ DialogTrueDarts::DialogTrueDarts(const VContainer *data, quint32 toolId, QWidget
this, &DialogTrueDarts::PointNameChanged); this, &DialogTrueDarts::PointNameChanged);
vis = new VisToolTrueDarts(data); vis = new VisToolTrueDarts(data);
ui->tabWidget->setCurrentIndex(0);
SetTabStopDistance(ui->plainTextEditToolNotes);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -426,3 +429,15 @@ void DialogTrueDarts::CheckName(QLineEdit *edit, QLabel *labelEditNamePoint, con
ChangeColor(labelEditNamePoint, OkColor(this)); ChangeColor(labelEditNamePoint, OkColor(this));
} }
} }
//---------------------------------------------------------------------------------------------------------------------
void DialogTrueDarts::SetNotes(const QString &notes)
{
ui->plainTextEditToolNotes->setPlainText(notes);
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogTrueDarts::GetNotes() const
{
return ui->plainTextEditToolNotes->toPlainText();
}

View file

@ -71,6 +71,9 @@ public:
void SetThirdDartPointId(const quint32 &value); void SetThirdDartPointId(const quint32 &value);
void SetChildrenId(const quint32 &ch1, const quint32 &ch2); void SetChildrenId(const quint32 &ch1, const quint32 &ch2);
void SetNotes(const QString &notes);
QString GetNotes() const;
public slots: public slots:
virtual void ChosenObject(quint32 id, const SceneObject &type) override; virtual void ChosenObject(quint32 id, const SceneObject &type) override;
virtual void PointNameChanged() override; virtual void PointNameChanged() override;

View file

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>372</width> <width>304</width>
<height>278</height> <height>308</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -19,138 +19,158 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<layout class="QFormLayout" name="formLayout"> <widget class="QTabWidget" name="tabWidget">
<property name="fieldGrowthPolicy"> <property name="currentIndex">
<enum>QFormLayout::ExpandingFieldsGrow</enum> <number>0</number>
</property> </property>
<item row="0" column="0"> <widget class="QWidget" name="tab">
<widget class="QLabel" name="labelFirstBasePoint"> <attribute name="title">
<property name="sizePolicy"> <string>Tool</string>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </attribute>
<horstretch>0</horstretch> <layout class="QFormLayout" name="formLayout_2">
<verstretch>0</verstretch> <property name="fieldGrowthPolicy">
</sizepolicy> <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>First base point:</string> <widget class="QLabel" name="labelFirstBasePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="0" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxFirstBasePoint"/> </sizepolicy>
</item> </property>
<item row="1" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondBasePoint"> <string>First base point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="0" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxFirstBasePoint"/>
</property> </item>
<property name="text"> <item row="1" column="0">
<string>Second base point:</string> <widget class="QLabel" name="labelSecondBasePoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="1" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxSecondBasePoint"/> </sizepolicy>
</item> </property>
<item row="2" column="0"> <property name="text">
<widget class="QLabel" name="labelFirstDartPoint"> <string>Second base point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="1" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxSecondBasePoint"/>
</property> </item>
<property name="text"> <item row="2" column="0">
<string>First dart point:</string> <widget class="QLabel" name="labelFirstDartPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="2" column="1"> <verstretch>0</verstretch>
<widget class="QComboBox" name="comboBoxFirstDartPoint"/> </sizepolicy>
</item> </property>
<item row="3" column="0"> <property name="text">
<widget class="QLabel" name="labelSecondDartPoint"> <string>First dart point:</string>
<property name="text"> </property>
<string>Second dart point:</string> </widget>
</property> </item>
</widget> <item row="2" column="1">
</item> <widget class="QComboBox" name="comboBoxFirstDartPoint"/>
<item row="3" column="1"> </item>
<widget class="QComboBox" name="comboBoxSecondDartPoint"> <item row="3" column="0">
<property name="sizePolicy"> <widget class="QLabel" name="labelSecondDartPoint">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <property name="text">
<horstretch>0</horstretch> <string>Second dart point:</string>
<verstretch>0</verstretch> </property>
</sizepolicy> </widget>
</property> </item>
<property name="minimumSize"> <item row="3" column="1">
<size> <widget class="QComboBox" name="comboBoxSecondDartPoint">
<width>0</width> <property name="sizePolicy">
<height>0</height> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
</size> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="iconSize"> </sizepolicy>
<size> </property>
<width>80</width> <property name="minimumSize">
<height>14</height> <size>
</size> <width>0</width>
</property> <height>0</height>
</widget> </size>
</item> </property>
<item row="4" column="0"> <property name="iconSize">
<widget class="QLabel" name="labelThirdDartPoint"> <size>
<property name="text"> <width>80</width>
<string>Third dart point:</string> <height>14</height>
</property> </size>
</widget> </property>
</item> </widget>
<item row="4" column="1"> </item>
<widget class="QComboBox" name="comboBoxThirdDartPoint"/> <item row="4" column="0">
</item> <widget class="QLabel" name="labelThirdDartPoint">
<item row="5" column="0"> <property name="text">
<widget class="QLabel" name="labelFirstNewDartPoint"> <string>Third dart point:</string>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> </widget>
<horstretch>0</horstretch> </item>
<verstretch>0</verstretch> <item row="4" column="1">
</sizepolicy> <widget class="QComboBox" name="comboBoxThirdDartPoint"/>
</property> </item>
<property name="text"> <item row="5" column="0">
<string>First new dart point:</string> <widget class="QLabel" name="labelFirstNewDartPoint">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</item> <horstretch>0</horstretch>
<item row="5" column="1"> <verstretch>0</verstretch>
<widget class="QLineEdit" name="lineEditFirstNewDartPoint"> </sizepolicy>
<property name="toolTip"> </property>
<string>Unique label</string> <property name="text">
</property> <string>First new dart point:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="5" column="1">
</item> <widget class="QLineEdit" name="lineEditFirstNewDartPoint">
<item row="6" column="0"> <property name="toolTip">
<widget class="QLabel" name="labelSecondNewDartPoint"> <string>Unique label</string>
<property name="text"> </property>
<string>Second new dart point:</string> <property name="placeholderText">
</property> <string>Choose unique label.</string>
</widget> </property>
</item> </widget>
<item row="6" column="1"> </item>
<widget class="QLineEdit" name="lineEditSecondNewDartPoint"> <item row="6" column="0">
<property name="toolTip"> <widget class="QLabel" name="labelSecondNewDartPoint">
<string>Unique label</string> <property name="text">
</property> <string>Second new dart point:</string>
<property name="placeholderText"> </property>
<string>Choose unique label.</string> </widget>
</property> </item>
</widget> <item row="6" column="1">
</item> <widget class="QLineEdit" name="lineEditSecondNewDartPoint">
</layout> <property name="toolTip">
<string>Unique label</string>
</property>
<property name="placeholderText">
<string>Choose unique label.</string>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Notes</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QPlainTextEdit" name="plainTextEditToolNotes"/>
</item>
</layout>
</widget>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

Some files were not shown because too many files have changed in this diff Show more