KCMUtils

SettingHighlighter.qml
1/*
2 SPDX-FileCopyrightText: 2020 Kevin Ottens <kevin.ottens@enioka.com>
3 SPDX-FileCopyrightText: 2020 David Redondo <kde@david.redondo.de>
4
5 SPDX-License-Identifier: LGPL-2.0-or-later
6*/
7
8import QtQuick
9import org.kde.kcmutils.private as KCMUtilsPrivate
10
11/**
12 * SettingHighlighter automatically impacts the representation of an item based on
13 * the value of a setting. When you are using this item you need to manually
14 * manage whether the highlighting is enabled or not. For a higher level component
15 * see KCM.SettingStateBinding which will manage the state of the Item
16 * @since 6.0
17 */
18Loader {
19 id: root
20
21 active: typeof kcm !== "undefined" && root.target !== null
22
23 /**
24 * target: Item
25 * The graphical element whose appearance will be altered.
26 * If target is not set, it will try to find the visual parent item
27 */
28 property Item target: root.parent
30 /**
31 * highlight: bool
32 * Whether the target will be highlighted.
33 */
34 property bool highlight: false
35
36 sourceComponent: KCMUtilsPrivate.SettingHighlighterPrivate {
37 id: helper
38 highlight: root.highlight
39 target: root.target
40 defaultIndicatorVisible: kcm.defaultsIndicatorsVisible
41 }
42}
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:02:19 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.