9#ifndef KISINTPARSESPINBOX_H
10#define KISINTPARSESPINBOX_H
13#include <QScopedPointer>
15#include <kritawidgetutils_export.h>
17template <
typename SpinBoxTypeTP,
typename BaseSpinBoxTypeTP>
37 void stepBy(
int steps)
override;
53 void setValue(
int value,
bool overwriteExpression =
false);
59 bool isLastValid()
const;
65 virtual QString veryCleanText()
const;
79 QValidator::State validate(QString &input,
int &pos)
const override;
80 int valueFromText(
const QString &text)
const override;
81 QString textFromValue(
int value)
const override;
84 template <
typename SpinBoxTypeTP,
typename BaseSpinBoxTypeTP>
86 QScopedPointer<KisParseSpinBoxPrivate<KisIntParseSpinBox, QSpinBox>>
d;
float value(const T *src, size_t ch)
The KisIntParseSpinBox class is a cleverer SpinBox, able to parse arithmetic expressions.
QScopedPointer< KisParseSpinBoxPrivate< KisIntParseSpinBox, QSpinBox > > d
void errorWhileParsing(const QString &expr) const
signal emitted when the last parsed expression is not valid.
void noMoreParsingError() const
signal emitted when the last parsed expression is valid and the expression before was not valid.