Krita Source Code Documentation
Loading...
Searching...
No Matches
kis_slider_based_paintop_property.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2016 Dmitry Kazakov <dimula73@gmail.com>
3 *
4 * SPDX-License-Identifier: GPL-2.0-or-later
5 */
6
7#ifndef __KIS_SLIDER_BASED_PAINTOP_PROPERTY_H
8#define __KIS_SLIDER_BASED_PAINTOP_PROPERTY_H
9
11
12class KRITAIMAGE_EXPORT KisSliderBasedPaintOpPropertyBase
14{
15 Q_OBJECT
16
17public:
19
20Q_SIGNALS:
22};
23
24
35template<typename T>
38{
39public:
40 KisSliderBasedPaintOpProperty(Type type, SubType subType, const KoID &id, KisPaintOpSettingsRestrictedSP settings, QObject *parent);
41
42 KisSliderBasedPaintOpProperty(Type type, const KoID &id, KisPaintOpSettingsRestrictedSP settings, QObject *parent);
43
44 KisSliderBasedPaintOpProperty(const KoID &id, KisPaintOpSettingsRestrictedSP settings, QObject *parent);
45
46 T min() const;
47 T max() const;
48 void setRange(T min, T max);
49
50 T singleStep() const;
51 void setSingleStep(T value);
52 T pageStep() const;
53 void setPageStep(T value);
54
55 qreal exponentRatio() const;
56 void setExponentRatio(qreal value);
57 int decimals() const;
58 void setDecimals(int value);
59
60 QString suffix() const;
61 void setSuffix(QString value);
62
63private:
66
70
72 QString m_suffix;
73};
74
76
77extern template class KisSliderBasedPaintOpProperty<int>;
78extern template class KisSliderBasedPaintOpProperty<qreal>;
81
85
90
91#endif /* __KIS_SLIDER_BASED_PAINTOP_PROPERTY_H */
float value(const T *src, size_t ch)
KisUniformPaintOpProperty(Type type, SubType subType, const KoID &id, KisPaintOpSettingsRestrictedSP settings, QObject *parent)
SubType
Hint to guess what this property is used for.
Definition KoID.h:30
#define KRITAIMAGE_EXPORT_TEMPLATE