Range

Public Methods

void

Range()

void

Range(T start, T end, Format format=Format::Numeric, Scale scale=Scale::Linear)

void

Range(const QString &start, const QString &end, const Format format=Format::Numeric, const Scale scale=Scale::Linear)

bool

autoScale() const

int

autoTickCount() const

T

center() const

Range< T >

checkRange() const

bool

contains(const Range< T > &other) const

bool

contains(T value) const

QString

dateTimeFormat() const

const QString&

dateTimeFormat()

T

diff() const

T

diff(Scale scale, T start, T end)

int

direction() const

T

end() const

T&

end()

void

extend(T value)

bool

finite() const

void

fixLimits()

Format

format() const

Format&

format()

bool

inverse() const

bool

isZero() const

T

length() const

void

niceExtend(bool extend=true)

void

niceShrink()

double

niceSize(double size, bool round)

int

relativePrecision() const

Scale

scale() const

Scale&

scale()

void

setAutoScale(bool b)

void

setDateTimeFormat(const QString &format)

void

setEnd(T end)

void

setFormat(Format format)

void

setRange(T start, T end, Format format, Scale scale)

void

setRange(T start, T end)

void

setScale(Scale scale)

void

setStart(T start)

T

size() const

T

start() const

T&

start()

T

stepSize(const int steps) const

QString

toLocaleString(bool round=true) const

std::string

toStdString(bool round=true) const

QString

toString(bool round=true, QLocale locale=QLocale()) const

void

translate(T start, T end)

bool

valid() const

void

zoom(const double factor, const bool nice, const double relZoomPosScene=0.5)

Detailed Description

template<class T>
class Range : private RangeT

Public Functions

inline QString toString(bool round = true, QLocale locale = QLocale()) const

Return a string in the format ‘start .. end’ and uses system locale (specialization see below)

inline QString toLocaleString(bool round = true) const

Return a string in the format ‘start .. end’ and uses number locale.

inline void zoom(const double factor, const bool nice, const double relZoomPosScene = 0.5)

TODO: implement zooming depending on the relZoomPosScene also for non linear scales!