MCPcopy Create free account
hub / github.com/BehaviorTree/Groot / paint

Method paint

QtNodeEditor/src/ConnectionPainter.cpp:279–309  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

277
278
279void
280ConnectionPainter::
281paint(QPainter* painter,
282 Connection const &connection)
283{
284 drawHoveredOrSelected(painter, connection);
285
286 drawSketchLine(painter, connection);
287
288 drawNormalLine(painter, connection);
289
290#ifdef NODE_DEBUG_DRAWING
291 debugDrawing(painter, connection);
292#endif
293
294 // draw end points
295 ConnectionGeometry const& geom = connection.connectionGeometry();
296
297 QPointF const & source = geom.source();
298 QPointF const & sink = geom.sink();
299
300 auto const & connectionStyle = connection.style();
301
302 double const pointDiameter = connectionStyle.pointDiameter();
303
304 painter->setPen(connectionStyle.constructionColor());
305 painter->setBrush(connectionStyle.constructionColor());
306 double const pointRadius = pointDiameter / 2.0;
307 painter->drawEllipse(source, pointRadius, pointRadius);
308 painter->drawEllipse(sink, pointRadius, pointRadius);
309}

Callers

nothing calls this directly

Calls 6

drawHoveredOrSelectedFunction · 0.85
drawSketchLineFunction · 0.85
drawNormalLineFunction · 0.85
debugDrawingFunction · 0.85
sourceMethod · 0.80
sinkMethod · 0.80

Tested by

no test coverage detected