! \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 */
| 1139 | \see draw |
| 1140 | */ |
| 1141 | void 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 |
no test coverage detected