ckb-next
v0.2.8 at branch master
ckb-next driver for corsair devices
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
gradientdialogwidget.h
Go to the documentation of this file.
1
#ifndef GRADIENTDIALOGWIDGET_H
2
#define GRADIENTDIALOGWIDGET_H
3
4
#include <QWidget>
5
#include <QMouseEvent>
6
#include <QPaintEvent>
7
8
class
GradientDialogWidget
:
public
QWidget
9
{
10
Q_OBJECT
11
public
:
12
explicit
GradientDialogWidget
(
QWidget
*parent = 0);
13
14
void
setStops
(
const
QGradientStops&
stops
);
15
inline
QGradientStops
stops
() {
return
_stops
; }
16
inline
int
stopCount
() {
return
_stops
.count(); }
17
18
QColor
colorAt
(
int
position);
19
20
inline
int
current
() {
return
_current
; }
21
int
moveCurrent
(
int
to);
22
void
setCurrentColor
(
const
QColor& color);
23
24
signals:
25
void
currentChanged
(QColor color,
bool
spontaneous,
int
position);
26
27
private
:
28
QColor
selected
;
29
int
selectedPos
,
selectedOffset
;
30
int
_current
;
31
QMap<int, QColor>
_colors
;
32
QGradientStops
_stops
;
33
34
QRect
fillRect
();
35
QRect
stopRect
(
int
pos);
36
int
selectedStop
();
37
QMap<int, QColor>
selectionColors
();
38
void
makeStops
();
39
40
void
paintEvent
(QPaintEvent*);
41
void
mousePressEvent
(QMouseEvent* event);
42
void
mouseMoveEvent
(QMouseEvent* event);
43
void
mouseReleaseEvent
(QMouseEvent* event);
44
};
45
46
#endif // GRADIENTDIALOGWIDGET_H
GradientDialogWidget::colorAt
QColor colorAt(int position)
Definition:
gradientdialogwidget.cpp:65
GradientDialogWidget
Definition:
gradientdialogwidget.h:8
GradientDialogWidget::stopCount
int stopCount()
Definition:
gradientdialogwidget.h:16
GradientDialogWidget::mouseMoveEvent
void mouseMoveEvent(QMouseEvent *event)
Definition:
gradientdialogwidget.cpp:255
GradientDialogWidget::stopRect
QRect stopRect(int pos)
Definition:
gradientdialogwidget.cpp:144
QWidget
GradientDialogWidget::mousePressEvent
void mousePressEvent(QMouseEvent *event)
Definition:
gradientdialogwidget.cpp:222
GradientDialogWidget::currentChanged
void currentChanged(QColor color, bool spontaneous, int position)
Definition:
moc_gradientdialogwidget.cpp:126
GradientDialogWidget::_current
int _current
Definition:
gradientdialogwidget.h:30
GradientDialogWidget::selectedPos
int selectedPos
Definition:
gradientdialogwidget.h:29
GradientDialogWidget::setStops
void setStops(const QGradientStops &stops)
Definition:
gradientdialogwidget.cpp:12
GradientDialogWidget::makeStops
void makeStops()
Definition:
gradientdialogwidget.cpp:30
GradientDialogWidget::selectionColors
QMap< int, QColor > selectionColors()
Definition:
gradientdialogwidget.cpp:160
GradientDialogWidget::setCurrentColor
void setCurrentColor(const QColor &color)
Definition:
gradientdialogwidget.cpp:117
GradientDialogWidget::moveCurrent
int moveCurrent(int to)
Definition:
gradientdialogwidget.cpp:94
GradientDialogWidget::selected
QColor selected
Definition:
gradientdialogwidget.h:28
GradientDialogWidget::_stops
QGradientStops _stops
Definition:
gradientdialogwidget.h:32
GradientDialogWidget::current
int current()
Definition:
gradientdialogwidget.h:20
GradientDialogWidget::selectedOffset
int selectedOffset
Definition:
gradientdialogwidget.h:29
GradientDialogWidget::stops
QGradientStops stops()
Definition:
gradientdialogwidget.h:15
GradientDialogWidget::mouseReleaseEvent
void mouseReleaseEvent(QMouseEvent *event)
Definition:
gradientdialogwidget.cpp:282
GradientDialogWidget::fillRect
QRect fillRect()
Definition:
gradientdialogwidget.cpp:138
GradientDialogWidget::GradientDialogWidget
GradientDialogWidget(QWidget *parent=0)
Definition:
gradientdialogwidget.cpp:6
GradientDialogWidget::_colors
QMap< int, QColor > _colors
Definition:
gradientdialogwidget.h:31
GradientDialogWidget::paintEvent
void paintEvent(QPaintEvent *)
Definition:
gradientdialogwidget.cpp:172
GradientDialogWidget::selectedStop
int selectedStop()
Definition:
gradientdialogwidget.cpp:152
src
ckb
gradientdialogwidget.h
Generated on Sat Jan 20 2018 16:59:28 for ckb-next by
1.8.6