src/widgets/colorindexinput.h

Wed, 15 Jun 2022 13:03:20 +0300

author
Teemu Piippo <teemu.s.piippo@gmail.com>
date
Wed, 15 Jun 2022 13:03:20 +0300
changeset 228
948867719906
parent 214
8e1fe64ce4e3
child 258
fe094d0687ad
permissions
-rw-r--r--

refactor

178
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
1 #pragma once
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
2 #include "document.h"
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
3
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
4 class ColorIndexInput : public QWidget
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
5 {
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
6 Q_OBJECT
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
7 public:
214
8e1fe64ce4e3 begin refactor of gl side
Teemu Piippo <teemu.s.piippo@gmail.com>
parents: 205
diff changeset
8 ColorIndexInput(ColorTable *colorTable, ColorIndex color = MAIN_COLOR, QWidget *parent = nullptr);
178
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
9 ~ColorIndexInput();
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
10 ldraw::Color selectedColor() const;
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
11 void setSelectedColor(ldraw::Color color);
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
12 Q_SIGNALS:
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
13 void colorChanged(ldraw::Color color);
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
14 private:
214
8e1fe64ce4e3 begin refactor of gl side
Teemu Piippo <teemu.s.piippo@gmail.com>
parents: 205
diff changeset
15 ColorTable* const colorTable;
178
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
16 class Ui_ColorIndexInput& ui;
a23024fc98e0 fix saving
Teemu Piippo <teemu@hecknology.net>
parents:
diff changeset
17 };

mercurial