aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp')
-rw-r--r--src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp b/src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp
index fe070fc08a..b11e34cf71 100644
--- a/src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp
+++ b/src/libs/modelinglib/qmt/config/stereotypedefinitionparser.cpp
@@ -55,6 +55,7 @@ static const int KEYWORD_DISPLAY = 11;
static const int KEYWORD_TEXTALIGN = 12;
static const int KEYWORD_BASECOLOR = 13;
static const int KEYWORD_SHAPE = 14;
+static const int KEYWORD_OUTLINE = 15;
// Shape items
static const int KEYWORD_CIRCLE = 30;
@@ -166,16 +167,13 @@ public:
IconCommandParameter() = default;
- IconCommandParameter(int keyword, ShapeValueF::Unit unit, ShapeValueF::Origin origin = ShapeValueF::OriginSmart)
- : m_keyword(keyword),
- m_unit(unit),
+ IconCommandParameter(ShapeValueF::Unit unit, ShapeValueF::Origin origin = ShapeValueF::OriginSmart)
+ : m_unit(unit),
m_origin(origin)
{
}
- IconCommandParameter(int keyword, Type type)
- : m_keyword(keyword),
- m_type(type)
+ IconCommandParameter(Type type) : m_type(type)
{
}
@@ -190,7 +188,6 @@ public:
void setBoolean(bool boolean) { m_boolean = boolean; }
private:
- int m_keyword = -1;
Type m_type = ShapeValue;
ShapeValueF::Unit m_unit = ShapeValueF::UnitAbsolute;
ShapeValueF::Origin m_origin = ShapeValueF::OriginSmart;
@@ -245,6 +242,7 @@ void StereotypeDefinitionParser::parse(ITextSource *source)
<< qMakePair(QString("textalignment"), KEYWORD_TEXTALIGN)
<< qMakePair(QString("basecolor"), KEYWORD_BASECOLOR)
<< qMakePair(QString("shape"), KEYWORD_SHAPE)
+ << qMakePair(QString("outline"), KEYWORD_OUTLINE)
<< qMakePair(QString("circle"), KEYWORD_CIRCLE)
<< qMakePair(QString("ellipse"), KEYWORD_ELLIPSE)
<< qMakePair(QString("line"), KEYWORD_LINE)
@@ -436,6 +434,9 @@ void StereotypeDefinitionParser::parseIcon()
case KEYWORD_SHAPE:
stereotypeIcon.setIconShape(parseIconShape());
break;
+ case KEYWORD_OUTLINE:
+ stereotypeIcon.setOutlineShape(parseIconShape());
+ break;
case KEYWORD_NAME:
stereotypeIcon.setName(parseStringProperty());
stereotypeIcon.setHasName(true);
@@ -455,22 +456,22 @@ void StereotypeDefinitionParser::parseIcon()
QPair<int, StereotypeDefinitionParser::IconCommandParameter> StereotypeDefinitionParser::SCALED(int keyword)
{
- return qMakePair(keyword, IconCommandParameter(keyword, ShapeValueF::UnitScaled));
+ return qMakePair(keyword, IconCommandParameter(ShapeValueF::UnitScaled));
}
QPair<int, StereotypeDefinitionParser::IconCommandParameter> StereotypeDefinitionParser::FIX(int keyword)
{
- return qMakePair(keyword, IconCommandParameter(keyword, ShapeValueF::UnitRelative));
+ return qMakePair(keyword, IconCommandParameter(ShapeValueF::UnitRelative));
}
QPair<int, StereotypeDefinitionParser::IconCommandParameter> StereotypeDefinitionParser::ABSOLUTE(int keyword)
{
- return qMakePair(keyword, IconCommandParameter(keyword, ShapeValueF::UnitAbsolute));
+ return qMakePair(keyword, IconCommandParameter(ShapeValueF::UnitAbsolute));
}
QPair<int, StereotypeDefinitionParser::IconCommandParameter> StereotypeDefinitionParser::BOOLEAN(int keyword)
{
- return qMakePair(keyword, IconCommandParameter(keyword, IconCommandParameter::Boolean));
+ return qMakePair(keyword, IconCommandParameter(IconCommandParameter::Boolean));
}
IconShape StereotypeDefinitionParser::parseIconShape()