MCPcopy Create free account
hub / github.com/LUX-Core/lux / setRange

Method setRange

src/qt/qcustomplot.cpp:7683–7699  ·  view source on GitHub ↗

! Sets the range of the axis. This slot may be connected with the \ref rangeChanged signal of another axis so this axis is always synchronized with the other axis range, when it changes. To invert the direction of an axis, use \ref setRangeReversed. */

Source from the content-addressed store, hash-verified

7681 To invert the direction of an axis, use \ref setRangeReversed.
7682*/
7683void QCPAxis::setRange(const QCPRange &range)
7684{
7685 if (range.lower == mRange.lower && range.upper == mRange.upper)
7686 return;
7687
7688 if (!QCPRange::validRange(range)) return;
7689 QCPRange oldRange = mRange;
7690 if (mScaleType == stLogarithmic)
7691 {
7692 mRange = range.sanitizedForLogScale();
7693 } else
7694 {
7695 mRange = range.sanitizedForLinScale();
7696 }
7697 Q_EMIT rangeChanged(mRange);
7698 Q_EMIT rangeChanged(mRange, oldRange);
7699}
7700
7701/*!
7702 Sets whether the user can (de-)select the parts in \a selectable by clicking on the QCustomPlot surface.

Callers 11

createProgressMethod · 0.80
hideMethod · 0.80
setupTaskbarMethod · 0.80
CoinControlDialogMethod · 0.80
rescaleKeyAxisMethod · 0.80
rescaleValueAxisMethod · 0.80
Q_FOREACHFunction · 0.80
setupFullAxesBoxMethod · 0.80
mouseMoveEventMethod · 0.80
setTypeMethod · 0.80
setDataRangeMethod · 0.80

Calls 2

sanitizedForLogScaleMethod · 0.80
sanitizedForLinScaleMethod · 0.80

Tested by

no test coverage detected