MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / shape

Method shape

src/openms_gui/source/VISUAL/TOPPASEdge.cpp:114–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

112 }
113
114 QPainterPath TOPPASEdge::shape() const
115 {
116 QPainterPath shape_1;
117 shape_1.moveTo(startPos() + QPointF(-10, -10));
118 shape_1.lineTo(endPos() + QPointF(-10, -10));
119 shape_1.lineTo(endPos() + QPointF(10, 10));
120 shape_1.lineTo(startPos() + QPointF(10, 10));
121 shape_1.closeSubpath();
122
123 QPainterPath shape_2;
124 shape_2.moveTo(startPos() + QPointF(-10, 10));
125 shape_2.lineTo(endPos() + QPointF(-10, 10));
126 shape_2.lineTo(endPos() + QPointF(10, -10));
127 shape_2.lineTo(startPos() + QPointF(10, -10));
128 shape_2.closeSubpath();
129
130 return shape_1.united(shape_2);
131 }
132
133 void TOPPASEdge::paint(QPainter* painter, const QStyleOptionGraphicsItem* /*option*/, QWidget* /*widget*/)
134 {

Callers 1

borderPoint_Method · 0.45

Calls 1

unitedMethod · 0.80

Tested by

no test coverage detected