Add always show option
This commit is contained in:
@@ -24,7 +24,8 @@ QtObject {
|
|||||||
{ value: "StayAwake", label: "Stay awake", description: "Idle lock and screensaver override" },
|
{ value: "StayAwake", label: "Stay awake", description: "Idle lock and screensaver override" },
|
||||||
{ value: "ScreenRecording", label: "Screen recording", description: "GPU screen recorder status" },
|
{ value: "ScreenRecording", label: "Screen recording", description: "GPU screen recorder status" },
|
||||||
{ value: "Dictation", label: "Dictation", description: "Voice typing status" }
|
{ value: "Dictation", label: "Dictation", description: "Voice typing status" }
|
||||||
] }
|
] },
|
||||||
|
{ key: "alwaysShow", type: "boolean", label: "Always Show", description: "Show inactive indicators without waiting for hover.", defaultValue: false }
|
||||||
] },
|
] },
|
||||||
"NotificationCenter": { displayName: "Notification center", description: "Recent notifications + DND", category: "Status", allowMultiple: false },
|
"NotificationCenter": { displayName: "Notification center", description: "Recent notifications + DND", category: "Status", allowMultiple: false },
|
||||||
"SystemUpdate": { displayName: "System update", description: "Indicates available system updates", category: "System", allowMultiple: false },
|
"SystemUpdate": { displayName: "System update", description: "Indicates available system updates", category: "System", allowMultiple: false },
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ Example `shell.json` (bar subtree only shown):
|
|||||||
| `panels.bluetooth` | Bluetooth icon + popup with device list, connect/disconnect, battery | left = popup · right = toggle radio · middle = bluetoothctl TUI |
|
| `panels.bluetooth` | Bluetooth icon + popup with device list, connect/disconnect, battery | left = popup · right = toggle radio · middle = bluetoothctl TUI |
|
||||||
| `panels.monitor` | Brightness and laptop display controls | left = popup |
|
| `panels.monitor` | Brightness and laptop display controls | left = popup |
|
||||||
|
|
||||||
The `Indicators` widget loads individual bar indicators from `indicators/`. Omit `items` (or set it to an empty array) to show all indicators in the default order, or set `items` to a subset such as `["Dnd", "NightLight"]`. Multiple `Indicators` instances are allowed, so different sections can show different subsets. Rich panels such as `PowerPanel`, `NetworkPanel`, and `AudioPanel` live in `../panels/` above.
|
The `Indicators` widget loads individual bar indicators from `indicators/`. Omit `items` (or set it to an empty array) to show all indicators in the default order, or set `items` to a subset such as `["Dnd", "NightLight"]`. Set `alwaysShow` to `true` to keep inactive indicators visible instead of revealing them only on hover. Multiple `Indicators` instances are allowed, so different sections can show different subsets. Rich panels such as `PowerPanel`, `NetworkPanel`, and `AudioPanel` live in `../panels/` above.
|
||||||
|
|
||||||
## Orientation
|
## Orientation
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,8 @@ BarWidget {
|
|||||||
property var indicatorActiveStates: ({})
|
property var indicatorActiveStates: ({})
|
||||||
property bool indicatorAreaHovered: false
|
property bool indicatorAreaHovered: false
|
||||||
property bool indicatorItemHovered: false
|
property bool indicatorItemHovered: false
|
||||||
readonly property bool revealInactiveIndicators: indicatorAreaHovered || indicatorItemHovered
|
readonly property bool alwaysShowIndicators: setting("alwaysShow", false) === true
|
||||||
|
readonly property bool revealInactiveIndicators: alwaysShowIndicators || indicatorAreaHovered || indicatorItemHovered
|
||||||
|
|
||||||
signal refreshRequested()
|
signal refreshRequested()
|
||||||
|
|
||||||
|
|||||||
@@ -486,6 +486,8 @@ Item {
|
|||||||
var copy = Util.cloneJson(widgetDialogEntry)
|
var copy = Util.cloneJson(widgetDialogEntry)
|
||||||
copy[key] = value
|
copy[key] = value
|
||||||
widgetDialogEntry = copy
|
widgetDialogEntry = copy
|
||||||
|
if (widgetDialogFormLoader.item && "entry" in widgetDialogFormLoader.item)
|
||||||
|
widgetDialogFormLoader.item.entry = widgetDialogEntry
|
||||||
}
|
}
|
||||||
|
|
||||||
FloatingWindow {
|
FloatingWindow {
|
||||||
|
|||||||
@@ -80,7 +80,7 @@ Column {
|
|||||||
spacing: Style.spacing.labelGap
|
spacing: Style.spacing.labelGap
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
visible: text !== ""
|
visible: text !== "" && String(modelData && modelData.type ? modelData.type : "") !== "boolean"
|
||||||
text: modelData && modelData.label ? modelData.label : (modelData && modelData.key ? modelData.key : "")
|
text: modelData && modelData.label ? modelData.label : (modelData && modelData.key ? modelData.key : "")
|
||||||
color: Qt.darker(root.foreground, 1.3)
|
color: Qt.darker(root.foreground, 1.3)
|
||||||
font.family: root.fontFamily
|
font.family: root.fontFamily
|
||||||
@@ -89,7 +89,7 @@ Column {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
visible: !!(modelData && modelData.description)
|
visible: !!(modelData && modelData.description) && String(modelData && modelData.type ? modelData.type : "") !== "boolean"
|
||||||
text: modelData ? (modelData.description || "") : ""
|
text: modelData ? (modelData.description || "") : ""
|
||||||
color: Qt.darker(root.foreground, 1.6)
|
color: Qt.darker(root.foreground, 1.6)
|
||||||
font.family: root.fontFamily
|
font.family: root.fontFamily
|
||||||
@@ -155,7 +155,8 @@ Column {
|
|||||||
property var field: ({})
|
property var field: ({})
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
label: "Enabled"
|
label: field && field.label ? String(field.label) : "Enabled"
|
||||||
|
description: field && field.description ? String(field.description) : ""
|
||||||
foreground: root.foreground
|
foreground: root.foreground
|
||||||
accent: root.accent
|
accent: root.accent
|
||||||
fontFamily: root.fontFamily
|
fontFamily: root.fontFamily
|
||||||
|
|||||||
Reference in New Issue
Block a user