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

Method widgetPosition

QtNodeEditor/src/NodeGeometry.cpp:217–234  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

215
216
217QPointF
218NodeGeometry::
219widgetPosition() const
220{
221 if (auto w = _dataModel->embeddedWidget())
222 {
223 if (_dataModel->validationState() != NodeValidationState::Valid)
224 {
225 return QPointF(_spacing + portWidth(PortType::In),
226 ( _height - validationHeight() - _spacing - w->height()) / 2.0);
227 }
228
229 return QPointF(_spacing + portWidth(PortType::In),
230 ( _height - w->height()) / 2.0);
231 }
232
233 return QPointF();
234}
235
236unsigned int
237NodeGeometry::

Callers

nothing calls this directly

Calls 2

embeddedWidgetMethod · 0.80
QPointFClass · 0.50

Tested by

no test coverage detected