ADTF Qt5
Loading...
Searching...
No Matches
themed_icon.h
Go to the documentation of this file.
1
7
8/*
9 * This file depends on Qt which is licensed under LGPLv3.
10 * See ADTF_DIR/3rdparty/qt5 and doc/license for detailed information.
11 */
12
13#pragma once
14
15#include <QList>
16#include <QPair>
17#include <QString>
18#include <QIcon>
19
20namespace adtf
21{
22namespace ui
23{
24namespace thor
25{
29class cThemedIconColorMapping
30{
31 QList<QPair<QColor, QColor>> m_colorMapping;
32
33public:
34 cThemedIconColorMapping();
35 ~cThemedIconColorMapping();
36
43 void AddColorMapping(QColor colorFrom, QColor colorTo);
44
51 const QColor MapColor(QColor colorFrom) const;
52
58 static cThemedIconColorMapping GetDefaultColorMapping();
59};
60
64enum class eThemedIcon
65{
66 OpenFile,
67 LED_Red,
68 LED_Green,
69 LED_Yellow,
70 LED_Grey,
71 Status_Error,
72 Status_Warning,
73 Status_Debug,
74 Arrow_Left,
75 Arrow_Up,
76 Arrow_Right,
77 Arrow_Down,
78 Help,
79 Info,
80 Edit_Add,
81 Edit_Remove,
82 Edit_Cut,
83 Edit_Copy,
84 Edit_Paste,
85 Edit_Modify,
86 Edit_Undo,
87 Edit_Redo,
88 Zoom,
89 Zoom_In,
90 Zoom_Out
91};
92
101 QString file, cThemedIconColorMapping themedIconColorMapping = cThemedIconColorMapping::GetDefaultColorMapping());
102
110
111} // namespace thor
112
113namespace v0
114{
118} // namespace v0
119
120using v0::cThemedIconColorMapping;
122using v0::eThemedIcon;
123
124} // namespace ui
125} // namespace adtf
Definition themed_icon.h:30
void AddColorMapping(QColor colorFrom, QColor colorTo)
const QColor MapColor(QColor colorFrom) const
static cThemedIconColorMapping GetDefaultColorMapping()
Legacy version namespace for all functionality of the ADTF UI SDK taken over from ADTF v3....
Definition themed_colors.h:23
eThemedIcon
Definition themed_icon.h:65
QIcon create_themed_icon(QString file, cThemedIconColorMapping themedIconColorMapping=cThemedIconColorMapping::GetDefaultColorMapping())
Creates a themed icon from given svg file with color mapping.
Namespace for all ui classes and interfaces provided since v1.0.0.
Definition adtfui_pkg.h:13
QIcon create_themed_icon(QString file, cThemedIconColorMapping themedIconColorMapping=cThemedIconColorMapping::GetDefaultColorMapping())
Creates a themed icon from given svg file with color mapping.
Namespace for the ADTF UI SDK.
Definition adtfui_pkg.h:13
Namespace for all functionality provided by ADTF and its SDKs.
Definition adtfui_pkg.h:13