Appearance was six cards deep and Light/Dark was the third of them, below the wallpaper grid and the entire lock screen -- so the control reached most often was the last one you got to. It is five tabs now, Theme first. The mock showed four; the page turned out to have eleven cards, so Titlebars and Windows became Windows, and Clock and vitals became Shell, rather than pretending four would hold them. Region, Date & Time and Displays each rendered a complete dataset as rows: every installed locale, the whole tz database, every mode the monitor advertises. The chooser was never the problem -- SearchPicker already existed and worked. It was simply rendered always-expanded, so the one line saying what is currently set sat under hundreds that were not. PickerRow collapses each behind its current value and closes again once something is picked. The avatar never appeared to change because accountsservice writes every picture to the same path, leaving the URL byte-identical while Qt served its cached image. cache:false was already set and could not have helped: an unchanged source is never re-read at all. avatarUrl now carries a revision fragment, bumped only when a write actually succeeds. Pictures are cropped before they are set, in the picture's own pixel coordinates so the result does not depend on the size it happened to be displayed at, and written out at 512x512 through GdkPixbuf -- already a dependency here, so nothing new is required. Snapshots listed nothing. The timeline and its Delete buttons existed the whole time, behind a row labelled "Browse...", a word that promises a file browser. The three most recent points are shown inline now, with the rest one press away. qmldir-registration-contract exists because an unregistered component is not a quiet problem: Quickshell fails the entire configuration on it, so the settings window dies and the bar and dock go with it. That happened twice while writing this, both times on a machine somebody was using. It is pure file inspection, so it runs before a change ever reaches the running shell. Claude-Session: https://claude.ai/code/session_01BRvzt4H8XXLPVH5MyYdk9L
84 lines
2.6 KiB
QML
84 lines
2.6 KiB
QML
// A setting whose value is chosen from far more options than belong on screen.
|
|
//
|
|
// PickerRow {
|
|
// label: "Language"
|
|
// value: SystemLocale.currentLabel
|
|
// SearchPicker { items: SystemLocale.locales; onPicked: ... }
|
|
// }
|
|
//
|
|
// Three pages rendered an entire dataset as rows -- every installed locale, the
|
|
// whole tz database, every mode a monitor advertises -- so the one line telling
|
|
// you what is currently set was buried under hundreds that were not. The chooser
|
|
// itself was never the problem and is unchanged: this only collapses it behind
|
|
// the current value, which is what a person came to the page to read.
|
|
//
|
|
// Collapsed by default, and closes again once something is picked, so the page
|
|
// returns to being readable rather than staying open on a list nobody needs any
|
|
// more.
|
|
|
|
import QtQuick
|
|
import qs.config
|
|
|
|
Column {
|
|
id: root
|
|
|
|
property string label: ""
|
|
property string detail: ""
|
|
// What is set right now. Shown on the collapsed row, so the common case --
|
|
// looking rather than changing -- needs no interaction at all.
|
|
property string value: ""
|
|
property bool enabled: true
|
|
property bool divider: true
|
|
property bool expanded: false
|
|
|
|
default property alias content: body.data
|
|
|
|
// Pages call this from their picker's onPicked, so choosing something puts
|
|
// the list away instead of leaving it open over the rest of the page.
|
|
function collapse(): void { root.expanded = false; }
|
|
|
|
width: parent ? parent.width : 620
|
|
spacing: 0
|
|
|
|
SettingRow {
|
|
width: parent.width
|
|
label: root.label
|
|
detail: root.detail
|
|
activatable: root.enabled
|
|
divider: root.divider && !root.expanded
|
|
opacity: root.enabled ? 1 : 0.5
|
|
controlWidth: 210
|
|
onActivated: root.expanded = !root.expanded
|
|
|
|
Row {
|
|
anchors.right: parent.right
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
spacing: 9
|
|
|
|
Text {
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
text: root.value
|
|
color: Theme.fgDim
|
|
font.family: Theme.fontFamily
|
|
font.features: Theme.tabularFigures
|
|
font.pixelSize: Theme.fontSize
|
|
elide: Text.ElideRight
|
|
}
|
|
|
|
Text {
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
text: root.expanded ? "▴" : "▾"
|
|
color: Theme.fgMuted
|
|
font.family: Theme.fontFamily
|
|
font.pixelSize: Theme.fontSizeSmall
|
|
}
|
|
}
|
|
}
|
|
|
|
Column {
|
|
id: body
|
|
width: parent.width
|
|
visible: root.expanded
|
|
}
|
|
}
|