MCPcopy Create free account
hub / github.com/CieNTi/serial_port_plotter / drawToPaintBuffer

Method drawToPaintBuffer

qcustomplot/qcustomplot.cpp:1141–1157  ·  view source on GitHub ↗

! \internal Draws the contents of this layer into the paint buffer which is associated with this layer. The association is established by the parent QCustomPlot, which manages all paint buffers (see \ref QCustomPlot::setupPaintBuffers). \see draw */

Source from the content-addressed store, hash-verified

1139 \see draw
1140*/
1141void QCPLayer::drawToPaintBuffer()
1142{
1143 if (!mPaintBuffer.isNull())
1144 {
1145 if (QCPPainter *painter = mPaintBuffer.data()->startPainting())
1146 {
1147 if (painter->isActive())
1148 draw(painter);
1149 else
1150 qDebug() << Q_FUNC_INFO << "paint buffer returned inactive painter";
1151 delete painter;
1152 mPaintBuffer.data()->donePainting();
1153 } else
1154 qDebug() << Q_FUNC_INFO << "paint buffer returned zero painter";
1155 } else
1156 qDebug() << Q_FUNC_INFO << "no valid paint buffer associated with this layer";
1157}
1158
1159/*!
1160 If the layer mode (\ref setMode) is set to \ref lmBuffered, this method allows replotting only

Callers 1

replotMethod · 0.80

Calls 3

startPaintingMethod · 0.80
dataMethod · 0.80
donePaintingMethod · 0.80

Tested by

no test coverage detected