1/****************************************************************************
2**
3** Copyright (C) 2017 The Qt Company Ltd.
4** Contact: http://www.qt.io/licensing/
5**
6** This file is part of the Qt Quick Templates 2 module of the Qt Toolkit.
7**
8** $QT_BEGIN_LICENSE:LGPL3$
9** Commercial License Usage
10** Licensees holding valid commercial Qt licenses may use this file in
11** accordance with the commercial license agreement provided with the
12** Software or, alternatively, in accordance with the terms contained in
13** a written agreement between you and The Qt Company. For licensing terms
14** and conditions see http://www.qt.io/terms-conditions. For further
15** information use the contact form at http://www.qt.io/contact-us.
16**
17** GNU Lesser General Public License Usage
18** Alternatively, this file may be used under the terms of the GNU Lesser
19** General Public License version 3 as published by the Free Software
20** Foundation and appearing in the file LICENSE.LGPLv3 included in the
21** packaging of this file. Please review the following information to
22** ensure the GNU Lesser General Public License version 3 requirements
23** will be met: https://www.gnu.org/licenses/lgpl.html.
24**
25** GNU General Public License Usage
26** Alternatively, this file may be used under the terms of the GNU
27** General Public License version 2.0 or later as published by the Free
28** Software Foundation and appearing in the file LICENSE.GPL included in
29** the packaging of this file. Please review the following information to
30** ensure the GNU General Public License version 2.0 requirements will be
31** met: http://www.gnu.org/licenses/gpl-2.0.html.
32**
33** $QT_END_LICENSE$
34**
35****************************************************************************/
36
37#include "qquickpalette_p.h"
38
39QT_BEGIN_NAMESPACE
40
41QColor QQuickPalette::alternateBase() const
42{
43 return v.color(cr: QPalette::AlternateBase);
44}
45
46void QQuickPalette::setAlternateBase(const QColor &color)
47{
48 v.setColor(acg: QPalette::All, acr: QPalette::AlternateBase, acolor: color);
49}
50
51void QQuickPalette::resetAlternateBase()
52{
53 v.resolve(mask: v.resolve() & ~(1 << QPalette::AlternateBase));
54}
55
56QColor QQuickPalette::base() const
57{
58 return v.color(cr: QPalette::Base);
59}
60
61void QQuickPalette::setBase(const QColor &color)
62{
63 v.setColor(acg: QPalette::All, acr: QPalette::Base, acolor: color);
64}
65
66void QQuickPalette::resetBase()
67{
68 v.resolve(mask: v.resolve() & ~(1 << QPalette::Base));
69}
70
71QColor QQuickPalette::brightText() const
72{
73 return v.color(cr: QPalette::BrightText);
74}
75
76void QQuickPalette::setBrightText(const QColor &color)
77{
78 v.setColor(acg: QPalette::All, acr: QPalette::BrightText, acolor: color);
79}
80
81void QQuickPalette::resetBrightText()
82{
83 v.resolve(mask: v.resolve() & ~(1 << QPalette::BrightText));
84}
85
86QColor QQuickPalette::button() const
87{
88 return v.color(cr: QPalette::Button);
89}
90
91void QQuickPalette::setButton(const QColor &color)
92{
93 v.setColor(acg: QPalette::All, acr: QPalette::Button, acolor: color);
94}
95
96void QQuickPalette::resetButton()
97{
98 v.resolve(mask: v.resolve() & ~(1 << QPalette::Button));
99}
100
101QColor QQuickPalette::buttonText() const
102{
103 return v.color(cr: QPalette::ButtonText);
104}
105
106void QQuickPalette::setButtonText(const QColor &color)
107{
108 v.setColor(acg: QPalette::All, acr: QPalette::ButtonText, acolor: color);
109}
110
111void QQuickPalette::resetButtonText()
112{
113 v.resolve(mask: v.resolve() & ~(1 << QPalette::ButtonText));
114}
115
116QColor QQuickPalette::dark() const
117{
118 return v.color(cr: QPalette::Dark);
119}
120
121void QQuickPalette::setDark(const QColor &color)
122{
123 v.setColor(acg: QPalette::All, acr: QPalette::Dark, acolor: color);
124}
125
126void QQuickPalette::resetDark()
127{
128 v.resolve(mask: v.resolve() & ~(1 << QPalette::Dark));
129}
130
131QColor QQuickPalette::highlight() const
132{
133 return v.color(cr: QPalette::Highlight);
134}
135
136void QQuickPalette::setHighlight(const QColor &color)
137{
138 v.setColor(acg: QPalette::All, acr: QPalette::Highlight, acolor: color);
139}
140
141void QQuickPalette::resetHighlight()
142{
143 v.resolve(mask: v.resolve() & ~(1 << QPalette::Highlight));
144}
145
146QColor QQuickPalette::highlightedText() const
147{
148 return v.color(cr: QPalette::HighlightedText);
149}
150
151void QQuickPalette::setHighlightedText(const QColor &color)
152{
153 v.setColor(acg: QPalette::All, acr: QPalette::HighlightedText, acolor: color);
154}
155
156void QQuickPalette::resetHighlightedText()
157{
158 v.resolve(mask: v.resolve() & ~(1 << QPalette::HighlightedText));
159}
160
161QColor QQuickPalette::light() const
162{
163 return v.color(cr: QPalette::Light);
164}
165
166void QQuickPalette::setLight(const QColor &color)
167{
168 v.setColor(acg: QPalette::All, acr: QPalette::Light, acolor: color);
169}
170
171void QQuickPalette::resetLight()
172{
173 v.resolve(mask: v.resolve() & ~(1 << QPalette::Light));
174}
175
176QColor QQuickPalette::link() const
177{
178 return v.color(cr: QPalette::Link);
179}
180
181void QQuickPalette::setLink(const QColor &color)
182{
183 v.setColor(acg: QPalette::All, acr: QPalette::Link, acolor: color);
184}
185
186void QQuickPalette::resetLink()
187{
188 v.resolve(mask: v.resolve() & ~(1 << QPalette::Link));
189}
190
191QColor QQuickPalette::linkVisited() const
192{
193 return v.color(cr: QPalette::LinkVisited);
194}
195
196void QQuickPalette::setLinkVisited(const QColor &color)
197{
198 v.setColor(acg: QPalette::All, acr: QPalette::LinkVisited, acolor: color);
199}
200
201void QQuickPalette::resetLinkVisited()
202{
203 v.resolve(mask: v.resolve() & ~(1 << QPalette::LinkVisited));
204}
205
206QColor QQuickPalette::mid() const
207{
208 return v.color(cr: QPalette::Mid);
209}
210
211void QQuickPalette::setMid(const QColor &color)
212{
213 v.setColor(acg: QPalette::All, acr: QPalette::Mid, acolor: color);
214}
215
216void QQuickPalette::resetMid()
217{
218 v.resolve(mask: v.resolve() & ~(1 << QPalette::Mid));
219}
220
221QColor QQuickPalette::midlight() const
222{
223 return v.color(cr: QPalette::Midlight);
224}
225
226void QQuickPalette::setMidlight(const QColor &color)
227{
228 v.setColor(acg: QPalette::All, acr: QPalette::Midlight, acolor: color);
229}
230
231void QQuickPalette::resetMidlight()
232{
233 v.resolve(mask: v.resolve() & ~(1 << QPalette::Midlight));
234}
235
236QColor QQuickPalette::shadow() const
237{
238 return v.color(cr: QPalette::Shadow);
239}
240
241void QQuickPalette::setShadow(const QColor &color)
242{
243 v.setColor(acg: QPalette::All, acr: QPalette::Shadow, acolor: color);
244}
245
246void QQuickPalette::resetShadow()
247{
248 v.resolve(mask: v.resolve() & ~(1 << QPalette::Shadow));
249}
250
251QColor QQuickPalette::text() const
252{
253 return v.color(cr: QPalette::Text);
254}
255
256void QQuickPalette::setText(const QColor &color)
257{
258 v.setColor(acg: QPalette::All, acr: QPalette::Text, acolor: color);
259}
260
261void QQuickPalette::resetText()
262{
263 v.resolve(mask: v.resolve() & ~(1 << QPalette::Text));
264}
265
266QColor QQuickPalette::toolTipBase() const
267{
268 return v.color(cr: QPalette::ToolTipBase);
269}
270
271void QQuickPalette::setToolTipBase(const QColor &color)
272{
273 v.setColor(acg: QPalette::All, acr: QPalette::ToolTipBase, acolor: color);
274}
275
276void QQuickPalette::resetToolTipBase()
277{
278 v.resolve(mask: v.resolve() & ~(1 << QPalette::ToolTipBase));
279}
280
281QColor QQuickPalette::toolTipText() const
282{
283 return v.color(cr: QPalette::ToolTipText);
284}
285
286void QQuickPalette::setToolTipText(const QColor &color)
287{
288 v.setColor(acg: QPalette::All, acr: QPalette::ToolTipText, acolor: color);
289}
290
291void QQuickPalette::resetToolTipText()
292{
293 v.resolve(mask: v.resolve() & ~(1 << QPalette::ToolTipText));
294}
295
296QColor QQuickPalette::window() const
297{
298 return v.color(cr: QPalette::Window);
299}
300
301void QQuickPalette::setWindow(const QColor &color)
302{
303 v.setColor(acg: QPalette::All, acr: QPalette::Window, acolor: color);
304}
305
306void QQuickPalette::resetWindow()
307{
308 v.resolve(mask: v.resolve() & ~(1 << QPalette::Window));
309}
310
311QColor QQuickPalette::windowText() const
312{
313 return v.color(cr: QPalette::WindowText);
314}
315
316void QQuickPalette::setWindowText(const QColor &color)
317{
318 v.setColor(acg: QPalette::All, acr: QPalette::WindowText, acolor: color);
319}
320
321void QQuickPalette::resetWindowText()
322{
323 v.resolve(mask: v.resolve() & ~(1 << QPalette::WindowText));
324}
325
326QT_END_NAMESPACE
327

source code of qtquickcontrols2/src/quicktemplates2/qquickpalette.cpp