Changeset View
Changeset View
Standalone View
Standalone View
libs/ui/widgets/KisGamutMaskToolbar.h
- This file was added.
1 | /* | ||||
---|---|---|---|---|---|
2 | * Copyright (c) 2018 Anna Medonosova <anna.medonosova@gmail.com> | ||||
3 | * | ||||
4 | * This library is free software; you can redistribute it and/or modify | ||||
5 | * it under the terms of the GNU Lesser General Public License as published by | ||||
6 | * the Free Software Foundation; version 2.1 of the License. | ||||
7 | * | ||||
8 | * This library is distributed in the hope that it will be useful, | ||||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
11 | * GNU Lesser General Public License for more details. | ||||
12 | * | ||||
13 | * You should have received a copy of the GNU Lesser General Public License | ||||
14 | * along with this program; if not, write to the Free Software | ||||
15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||||
16 | */ | ||||
17 | | ||||
18 | #ifndef KISGAMUTMASKTOOLBAR_H | ||||
19 | #define KISGAMUTMASKTOOLBAR_H | ||||
20 | | ||||
21 | #include <QWidget> | ||||
22 | #include <QIcon> | ||||
23 | | ||||
24 | #include <resources/KoGamutMask.h> | ||||
25 | #include "kritaui_export.h" | ||||
26 | | ||||
27 | #include "ui_wdgGamutMaskToolbar.h" | ||||
28 | | ||||
29 | class KisCanvasResourceProvider; | ||||
30 | | ||||
31 | class KRITAUI_EXPORT KisGamutMaskToolbar : public QWidget | ||||
32 | { | ||||
33 | Q_OBJECT | ||||
34 | public: | ||||
35 | KisGamutMaskToolbar(QWidget* parent = nullptr); | ||||
36 | void connectMaskSignals(KisCanvasResourceProvider* resourceProvider); | ||||
37 | | ||||
38 | Q_SIGNALS: | ||||
39 | void sigGamutMaskToggle(bool state); | ||||
40 | void sigGamutMaskChanged(KoGamutMask*); | ||||
41 | | ||||
42 | public Q_SLOTS: | ||||
43 | void slotGamutMaskSet(KoGamutMask* mask); | ||||
44 | void slotGamutMaskUnset(); | ||||
45 | | ||||
46 | private Q_SLOTS: | ||||
47 | void slotGamutMaskToggle(bool state); | ||||
48 | void slotGamutMaskRotate(int angle); | ||||
49 | | ||||
50 | private: | ||||
51 | Ui_wdgGamutMaskToolbar* m_ui; | ||||
52 | KoGamutMask* m_selectedMask; | ||||
53 | | ||||
54 | QIcon m_iconMaskOff; | ||||
55 | QIcon m_iconMaskOn; | ||||
56 | | ||||
57 | QString m_textNoMask; | ||||
58 | QString m_textMaskDisabled; | ||||
59 | }; | ||||
60 | | ||||
61 | #endif // KISGAMUTMASKTOOLBAR_H |