MCPcopy Index your code
hub / github.com/Audio4Linux/JDSP4Linux / setGraph

Method setGraph

3rdparty/qcustomplot/qcustomplot.cpp:30531–30547  ·  view source on GitHub ↗

! Sets the QCPGraph this tracer sticks to. The tracer \a position will be set to type QCPItemPosition::ptPlotCoords and the axes will be set to the axes of \a graph. To free the tracer from any graph, set \a graph to \c nullptr. The tracer \a position can then be placed freely like any other item position. This is the state the tracer will assume when its graph gets deleted while stil

Source from the content-addressed store, hash-verified

30529 \see setGraphKey
30530*/
30531void QCPItemTracer::setGraph(QCPGraph *graph)
30532{
30533 if (graph)
30534 {
30535 if (graph->parentPlot() == mParentPlot)
30536 {
30537 position->setType(QCPItemPosition::ptPlotCoords);
30538 position->setAxes(graph->keyAxis(), graph->valueAxis());
30539 mGraph = graph;
30540 updatePosition();
30541 } else
30542 qDebug() << Q_FUNC_INFO << "graph isn't in same QCustomPlot instance as this item";
30543 } else
30544 {
30545 mGraph = nullptr;
30546 }
30547}
30548
30549/*!
30550 Sets the key of the graph's data point the tracer will be positioned at. This is the only free

Callers

nothing calls this directly

Calls 2

setTypeMethod · 0.80
setAxesMethod · 0.80

Tested by

no test coverage detected