! Sets the scale type of the color scale, i.e. whether values are associated with colors linearly or logarithmically. It is equivalent to calling QCPColorMap::setDataScaleType on any of the connected color maps. It is also equivalent to directly accessing the \ref axis and setting its scale type with \ref QCPAxis::setScaleType. Note that this method controls the coordinate transf
| 20274 | \see setDataRange, setGradient |
| 20275 | */ |
| 20276 | void QCPColorScale::setDataScaleType(QCPAxis::ScaleType scaleType) |
| 20277 | { |
| 20278 | if (mDataScaleType != scaleType) |
| 20279 | { |
| 20280 | mDataScaleType = scaleType; |
| 20281 | if (mColorAxis) |
| 20282 | mColorAxis.data()->setScaleType(mDataScaleType); |
| 20283 | if (mDataScaleType == QCPAxis::stLogarithmic) |
| 20284 | setDataRange(mDataRange.sanitizedForLogScale()); |
| 20285 | emit dataScaleTypeChanged(mDataScaleType); |
| 20286 | } |
| 20287 | } |
| 20288 | |
| 20289 | /*! |
| 20290 | Sets the color gradient that will be used to represent data values. |
nothing calls this directly
no test coverage detected