Files
qbz/scripts/test-settings-fieldset-qml.sh
T
vicrodh 7ca6c9fa80 fix(qt): a theme's options sit under its picker, boxed and collapsible
In Settings > Appearance the rows that exist only for one theme trailed the
whole THEME group: the Custom editor and the Auto source rows came after
Album header gradient, Compact header and Dynamic background. With a
Wallpaper background, Background image then ran straight into the Custom
editor and read as one of its options.

Each choice's options now follow their own picker inside a SettingsFieldset:
a bordered group with a header whose chevron folds it (> folded, v open).
The Custom and Auto theme options sit right under Theme, Custom starting at
"Start from current theme", and the Wallpaper background's Background image
sits under Dynamic background. The rows themselves are unchanged.

Each box keeps its folded state across restarts through settingsBool and
ui_prefs, the way the sidebar sections do (theme-custom-collapsed,
theme-auto-collapsed, ambient-options-collapsed; default open). Folding the
Custom box also closes an open color picker.

tst_settings_fieldset covers the rows inside the border, the header click
and keys, the settings below moving up, and a row click not toggling.

cc
2026-09-14 13:08:25 -06:00

21 lines
826 B
Bash
Executable File

#!/usr/bin/env bash
# SettingsFieldset regression: the collapsible options box of Appearance >
# Theme shows its rows inside the border, folds them on a header click or key,
# moves the settings below, and leaves the persisted state to its host. Same
# run in CI and locally.
set -euo pipefail
cd "$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/.."
if [[ -n "${QT_ROOT_DIR:-}" ]]; then
qt_fieldset_bins="$QT_ROOT_DIR/bin"
else
qt_fieldset_qmake="${QMAKE:-}"
if [[ -z "$qt_fieldset_qmake" ]]; then
qt_fieldset_qmake="$(command -v qmake6 || command -v qmake)"
fi
qt_fieldset_bins="$("$qt_fieldset_qmake" -query QT_INSTALL_BINS)"
fi
QT_QPA_PLATFORM=offscreen QT_QUICK_BACKEND=software \
"$qt_fieldset_bins/qmltestrunner" \
-input scripts/qml-tests/tst_settings_fieldset.qml \
-import scripts/qml-tests/imports