From 590e0089da204f3796e0bebf70b4d0f78512fd30 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Wed, 13 May 2020 17:52:43 +0300 Subject: [PATCH] Improve the property browser. Show full arc name. --- ChangeLog.txt | 1 + src/app/valentina/core/vtooloptionspropertybrowser.cpp | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/ChangeLog.txt b/ChangeLog.txt index cc924b47f..1df379dbf 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -47,6 +47,7 @@ - Setting scale factor for export and print. - New layout generator option: Prefer one sheet solution. - [smart-pattern/valentina#15] Organization of groups - groups categories +- Improve the property browser. Show full arc name. # Version 0.6.2 (unreleased) - [#903] Bug in tool Cut Spline path. diff --git a/src/app/valentina/core/vtooloptionspropertybrowser.cpp b/src/app/valentina/core/vtooloptionspropertybrowser.cpp index 27bd25e7a..2c8f9bd16 100644 --- a/src/app/valentina/core/vtooloptionspropertybrowser.cpp +++ b/src/app/valentina/core/vtooloptionspropertybrowser.cpp @@ -983,6 +983,9 @@ void VToolOptionsPropertyBrowser::ChangeDataToolArc(VPE::VProperty *property) SCASSERT(i != nullptr) switch (PropertiesList().indexOf(id)) { + case 0: // AttrName + Q_UNREACHABLE();//The attribute is read only + break; case 8: // AttrRadius i->SetFormulaRadius(value.value()); break; @@ -1021,6 +1024,9 @@ void VToolOptionsPropertyBrowser::ChangeDataToolArcWithLength(VPE::VProperty *pr SCASSERT(i != nullptr) switch (PropertiesList().indexOf(id)) { + case 0: // AttrName + Q_UNREACHABLE();//The attribute is read only + break; case 8: // AttrRadius i->SetFormulaRadius(value.value()); break; @@ -2019,6 +2025,7 @@ void VToolOptionsPropertyBrowser::ShowOptionsToolArc(QGraphicsItem *item) i->ShowVisualization(true); formView->setTitle(tr("Arc")); + AddPropertyObjectName(i, tr("Name:"), true); AddPropertyParentPointName(i->CenterPointName(), tr("Center point:"), AttrCenter); AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius(), AttrRadius); AddPropertyFormula(tr("First angle:"), i->GetFormulaF1(), AttrAngle1); @@ -2035,6 +2042,7 @@ void VToolOptionsPropertyBrowser::ShowOptionsToolArcWithLength(QGraphicsItem *it i->ShowVisualization(true); formView->setTitle(tr("Arc with given length")); + AddPropertyObjectName(i, tr("Name:"), true); AddPropertyParentPointName(i->CenterPointName(), tr("Center point:"), AttrCenter); AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius(), AttrRadius); AddPropertyFormula(tr("First angle:"), i->GetFormulaF1(), AttrAngle1);