Krita Source Code Documentation
Loading...
Searching...
No Matches
PaletteView.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2017 Wolthera van Hövell tot Westerflier <griffinvalley@gmail.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6
7#ifndef LIBKIS_PALETTE_VIEW_H
8#define LIBKIS_PALETTE_VIEW_H
9
10#include <QObject>
11#include <QScopedPointer>
12#include "kritalibkis_export.h"
13#include "libkis.h"
14#include "Palette.h"
15#include "ManagedColor.h"
16#include <kis_palette_view.h>
17#include <KisPaletteModel.h>
18
19#include <Swatch.h>
20
21class KisSwatch;
22
30class KRITALIBKIS_EXPORT PaletteView : public QWidget
31{
32 Q_OBJECT
33public:
34 PaletteView(QWidget *parent = 0);
36public Q_SLOTS:
42 void setPalette(Palette *palette);
50 bool addEntryWithDialog(ManagedColor *color);
56 bool addGroupWithDialog();
63 bool removeSelectedEntryWithDialog();
70 void trySelectClosestColor(ManagedColor *color);
71Q_SIGNALS:
84
85private Q_SLOTS:
86
87 void fgSelected(QModelIndex index);
88
89private:
90
91
92
93 struct Private;
94 const QScopedPointer<Private> d;
95};
96
97#endif // LIBKIS_PALETTE_VIEW_H
The ManagedColor class is a class to handle colors that are color managed. A managed color is a color...
The PaletteView class is a wrapper around a MVC method for handling palettes. This class shows a nice...
Definition PaletteView.h:31
void entrySelectedForeGround(Swatch entry)
entrySelectedForeGround fires when a swatch is selected with leftclick.
void entrySelectedBackGround(Swatch entry)
entrySelectedBackGround fires when a swatch is selected with rightclick.
const QScopedPointer< Private > d
Definition PaletteView.h:94
The Palette class Palette is a resource object that stores organised color data. It's purpose is to a...
Definition Palette.h:44
The Swatch class is a thin wrapper around the KisSwatch class.
Definition Swatch.h:22
rgba palette[MAX_PALETTE]
Definition palette.c:35