scantools
1.0.7
Graphics manipulation with a view towards scanned documents
|
72 explicit length(QString lstring,
bool *ok=0) {
73 bool myOk =
set(lstring);
101 bool set(QString lstring);
107 return (_length <= 0);
114 operator QString()
const {
115 return QString(
"%1mm").arg(
get(
mm));
126 return _length == other._length;
138 result._length = _length + rhs._length;
151 result._length = _length - rhs._length;
164 result._length = _length/div;
174 Q_DECLARE_METATYPE(
length)
const length operator/(const qreal div) const
Divide a length by a number.
const length operator-(const length rhs) const
Difference of two lengths.
The length stores a length and converts between units.
const length operator+(const length rhs) const
Sum of the lengths.
unit
List of supported units.
bool isNonPositive() const
Check if length is positive.
length()
Constructs a zero length.
bool operator==(const length other) const
Checks for equality.
length(qreal l, unit u)
Constructs length of given value and unit.
length(QString lstring, bool *ok=0)
Constructs length from a string.
bool set(QString lstring)
Constructs length from a string.
qreal get(unit u) const
Returns length in given unit.
void set(qreal l, unit u)
Sets length.