src/objecttypes/errorline.cpp

changeset 6
73e448b2943d
parent 3
55a55a9ec2c2
child 8
44679e468ba9
equal deleted inserted replaced
5:593a658cba8e 6:73e448b2943d
1 #include <QBrush>
1 #include "errorline.h" 2 #include "errorline.h"
2 3
3 modelobjects::ErrorLine::ErrorLine(QStringView text) : 4 modelobjects::ErrorLine::ErrorLine(QStringView text) :
4 text{text.toString()} 5 text{text.toString()}
5 { 6 {
28 return SetPropertyResult::Success; 29 return SetPropertyResult::Success;
29 default: 30 default:
30 return BaseObject::setProperty(property, value); 31 return BaseObject::setProperty(property, value);
31 } 32 }
32 } 33 }
34
35 QString modelobjects::ErrorLine::textRepresentation() const
36 {
37 return this->text;
38 }
39
40 QBrush modelobjects::ErrorLine::textRepresentationForeground() const
41 {
42 return QBrush{Qt::yellow};
43 }
44
45 QBrush modelobjects::ErrorLine::textRepresentationBackground() const
46 {
47 return QBrush{Qt::red};
48 }

mercurial