GrantleeTheme

kdegrantleeplugin.cpp
1/*
2 * SPDX-FileCopyrightText: 2015 Daniel Vrátil <dvratil@redhat.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.1-or-later
5 *
6 */
7
8#include "kdegrantleeplugin.h"
9#include "color.h"
10#include "colorscheme.h"
11#include "icon.h"
12#include "palette.h"
13
14KDEGrantleePlugin::KDEGrantleePlugin(QObject *parent)
15 : QObject(parent)
16 , KTextTemplate::TagLibraryInterface()
17{
18 Color::registerMetaType();
19 ColorScheme::registerMetaType();
20 Palette::registerMetaType();
21}
22
23KDEGrantleePlugin::~KDEGrantleePlugin() = default;
24QHash<QString, KTextTemplate::AbstractNodeFactory *> KDEGrantleePlugin::nodeFactories(const QString &name)
25{
26 Q_UNUSED(name)
28 nodeFactories[QStringLiteral("colorMix")] = new ColorMixTag();
29 nodeFactories[QStringLiteral("icon")] = new IconTag();
30
31 return nodeFactories;
32}
33QHash<QString, KTextTemplate::Filter *> KDEGrantleePlugin::filters(const QString &name)
34{
35 Q_UNUSED(name)
37 filters.insert(QStringLiteral("colorHexRgb"), new ColorHexRgbFilter());
38 filters.insert(QStringLiteral("colorCssRgba"), new ColorCssRgbaFilter());
39 filters.insert(QStringLiteral("colorLighter"), new ColorLighterFilter());
40 filters.insert(QStringLiteral("colorDarker"), new ColorDarkerFilter());
41 filters.insert(QStringLiteral("colorSetAlpha"), new ColorSetAlphaFilter());
42 return filters;
43}
44
45#include "moc_kdegrantleeplugin.cpp"
iterator insert(const Key &key, const T &value)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:37:38 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.