Watch
1
0
Fork
You've already forked souveraine
0
souveraine/surfaces/quickshell/ii-base/modules/settings/QuickConfig.qml
Fimeg 8f42fc953d publish: the public projection begins here
This is a projection, not a development branch. The tree above was constructed
from the internal source named below under a manifest that decides which paths
may leave, then scanned as a whole tree rather than as a series of patches, and
only then published.

Public history starts here because the history before it was not admissible,
and neither was the tree. What used to stand in this repository included a
rescue copy of another machine, a directory of phone handoffs, deployment
wired to one house, and a submodule pointing at a forge no stranger can reach.
None of that was ever the product. It stays in the private forge, which is
allowed to hold the whole working organism, and this is what was deliberately
sent out instead.

Three mechanisms produced this tree, in decreasing order of trust. A top-level
path the manifest does not name never arrives at all, which is the one that
catches directories nobody has thought of yet. Named internal files inside
admitted roots are dropped. A short, reviewed table replaces deployment
defaults that a public build must not carry -- an endpoint aimed at one LAN, a
VPN profile belonging to one phone, packaging built from one checkout path.

Everything after this commit is an ordinary publication with the same three
trailers, so a force push stops being routine and starts meaning that
something deliberate happened. The trailers bind the projection to its source
without pretending the public SHA is the private one: same lineage, different
tree, and the record says so.

Source-Sha: 8f27b1e76a8fef560a336aba18e6990713ff1047
Policy-Sha: 6b261d2f3e6e1fb19874846ba4bb1dfe15565d25b8618c1c1afba0419c101d27
Tree-Digest: 18ec3563c5e5ef9a414993a9f6734b251ff9ed3cd56eebdd6cac01e45c6e3067
2026-09-04 15:55:48 -04:00

359 lines
14 KiB
QML

import QtQuick
import QtQuick.Layouts
import Qt5Compat.GraphicalEffects
import Quickshell
import Quickshell.Io
import qs.services
import qs.modules.common
import qs.modules.common.widgets
import qs.modules.common.functions
ContentPage {
forceWidth: true
Process {
id: randomWallProc
property string status: ""
property string scriptPath: `${Directories.scriptPath}/colors/random/random_konachan_wall.sh`
command: ["bash", "-c", FileUtils.trimFileProtocol(randomWallProc.scriptPath)]
stdout: SplitParser {
onRead: data => {
randomWallProc.status = data.trim();
}
}
}
component SmallLightDarkPreferenceButton: RippleButton {
id: smallLightDarkPreferenceButton
required property bool dark
property color colText: toggled ? Appearance.colors.colOnPrimary : Appearance.colors.colOnLayer2
padding: 5
Layout.fillWidth: true
toggled: Appearance.m3colors.darkmode === dark
colBackground: Appearance.colors.colLayer2
onClicked: {
Quickshell.execDetached(["bash", "-c", `${Directories.wallpaperSwitchScriptPath} --mode ${dark ? "dark" : "light"} --noswitch`]);
}
contentItem: Item {
anchors.centerIn: parent
ColumnLayout {
anchors.centerIn: parent
spacing: 0
MaterialSymbol {
Layout.alignment: Qt.AlignHCenter
iconSize: 30
text: dark ? "dark_mode" : "light_mode"
color: smallLightDarkPreferenceButton.colText
}
StyledText {
Layout.alignment: Qt.AlignHCenter
text: dark ? Translation.tr("Dark") : Translation.tr("Light")
font.pixelSize: Appearance.font.pixelSize.smaller
color: smallLightDarkPreferenceButton.colText
}
}
}
}
// Wallpaper selection
ContentSection {
icon: "format_paint"
title: Translation.tr("Wallpaper & Colors")
Layout.fillWidth: true
RowLayout {
Layout.fillWidth: true
Item {
implicitWidth: 340
implicitHeight: 200
StyledImage {
id: wallpaperPreview
anchors.fill: parent
fillMode: Image.PreserveAspectCrop
source: Config.options.background.wallpaperPath
cache: false
layer.enabled: true
layer.effect: OpacityMask {
maskSource: Rectangle {
width: 360
height: 200
radius: Appearance.rounding.normal
}
}
}
}
ColumnLayout {
RippleButtonWithIcon {
enabled: !randomWallProc.running
visible: Config.options.policies.weeb === 1
Layout.fillWidth: true
buttonRadius: Appearance.rounding.small
materialIcon: "ifl"
mainText: randomWallProc.running ? Translation.tr("Be patient...") : Translation.tr("Random: Konachan")
onClicked: {
randomWallProc.scriptPath = `${Directories.scriptPath}/colors/random/random_konachan_wall.sh`;
randomWallProc.running = true;
}
StyledToolTip {
text: Translation.tr("Random SFW Anime wallpaper from Konachan\nImage is saved to ~/Pictures/Wallpapers")
}
}
RippleButtonWithIcon {
enabled: !randomWallProc.running
visible: Config.options.policies.weeb === 1
Layout.fillWidth: true
buttonRadius: Appearance.rounding.small
materialIcon: "ifl"
mainText: randomWallProc.running ? Translation.tr("Be patient...") : Translation.tr("Random: osu! seasonal")
onClicked: {
randomWallProc.scriptPath = `${Directories.scriptPath}/colors/random/random_osu_wall.sh`;
randomWallProc.running = true;
}
StyledToolTip {
text: Translation.tr("Random osu! seasonal background\nImage is saved to ~/Pictures/Wallpapers")
}
}
RippleButtonWithIcon {
Layout.fillWidth: true
materialIcon: "wallpaper"
StyledToolTip {
text: Translation.tr("Pick wallpaper image on your system")
}
onClicked: {
Quickshell.execDetached(`${Directories.wallpaperSwitchScriptPath}`);
}
mainContentComponent: Component {
RowLayout {
spacing: 10
StyledText {
font.pixelSize: Appearance.font.pixelSize.small
text: Translation.tr("Choose file")
color: Appearance.colors.colOnSecondaryContainer
}
RowLayout {
spacing: 3
KeyboardKey {
key: "Ctrl"
}
KeyboardKey {
key: Config.options.cheatsheet.superKey ?? "󰖳"
}
StyledText {
Layout.alignment: Qt.AlignVCenter
text: "+"
}
KeyboardKey {
key: "T"
}
}
}
}
}
RowLayout {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
Layout.fillHeight: true
uniformCellSizes: true
SmallLightDarkPreferenceButton {
Layout.fillHeight: true
dark: false
}
SmallLightDarkPreferenceButton {
Layout.fillHeight: true
dark: true
}
}
}
}
ConfigSelectionArray {
currentValue: Config.options.appearance.palette.type
onSelected: newValue => {
Config.options.appearance.palette.type = newValue;
Quickshell.execDetached(["bash", "-c", `${Directories.wallpaperSwitchScriptPath} --noswitch`]);
}
options: [
{
"value": "auto",
"displayName": Translation.tr("Auto")
},
{
"value": "scheme-content",
"displayName": Translation.tr("Content")
},
{
"value": "scheme-expressive",
"displayName": Translation.tr("Expressive")
},
{
"value": "scheme-fidelity",
"displayName": Translation.tr("Fidelity")
},
{
"value": "scheme-fruit-salad",
"displayName": Translation.tr("Fruit Salad")
},
{
"value": "scheme-monochrome",
"displayName": Translation.tr("Monochrome")
},
{
"value": "scheme-neutral",
"displayName": Translation.tr("Neutral")
},
{
"value": "scheme-rainbow",
"displayName": Translation.tr("Rainbow")
},
{
"value": "scheme-tonal-spot",
"displayName": Translation.tr("Tonal Spot")
}
]
}
ConfigSwitch {
buttonIcon: "ev_shadow"
text: Translation.tr("Transparency")
checked: Config.options.appearance.transparency.enable
onCheckedChanged: {
Config.options.appearance.transparency.enable = checked;
}
}
}
ContentSection {
icon: "screenshot_monitor"
title: Translation.tr("Bar & screen")
ConfigRow {
ContentSubsection {
title: Translation.tr("Bar position")
ConfigSelectionArray {
currentValue: (Config.options.bar.bottom ? 1 : 0) | (Config.options.bar.vertical ? 2 : 0)
onSelected: newValue => {
Config.options.bar.bottom = (newValue & 1) !== 0;
Config.options.bar.vertical = (newValue & 2) !== 0;
}
options: [
{
displayName: Translation.tr("Top"),
icon: "arrow_upward",
value: 0 // bottom: false, vertical: false
},
{
displayName: Translation.tr("Left"),
icon: "arrow_back",
value: 2 // bottom: false, vertical: true
},
{
displayName: Translation.tr("Bottom"),
icon: "arrow_downward",
value: 1 // bottom: true, vertical: false
},
{
displayName: Translation.tr("Right"),
icon: "arrow_forward",
value: 3 // bottom: true, vertical: true
}
]
}
}
ContentSubsection {
title: Translation.tr("Bar style")
ConfigSelectionArray {
currentValue: Config.options.bar.cornerStyle
onSelected: newValue => {
Config.options.bar.cornerStyle = newValue; // Update local copy
}
options: [
{
displayName: Translation.tr("Hug"),
icon: "line_curve",
value: 0
},
{
displayName: Translation.tr("Float"),
icon: "page_header",
value: 1
},
{
displayName: Translation.tr("Rect"),
icon: "toolbar",
value: 2
}
]
}
}
}
ConfigRow {
ContentSubsection {
title: Translation.tr("Screen round corner")
ConfigSelectionArray {
currentValue: Config.options.appearance.fakeScreenRounding
onSelected: newValue => {
Config.options.appearance.fakeScreenRounding = newValue;
}
options: [
{
displayName: Translation.tr("No"),
icon: "close",
value: 0
},
{
displayName: Translation.tr("Yes"),
icon: "check",
value: 1
},
{
displayName: Translation.tr("When not fullscreen"),
icon: "fullscreen_exit",
value: 2
}
]
}
}
}
}
NoticeBox {
Layout.fillWidth: true
text: Translation.tr('Not all options are available in this app. You should also check the config file by hitting the "Config file" button on the topleft corner or opening %1 manually.').arg(Directories.shellConfigPath)
Item {
Layout.fillWidth: true
}
RippleButtonWithIcon {
id: copyPathButton
property bool justCopied: false
Layout.fillWidth: false
buttonRadius: Appearance.rounding.small
materialIcon: justCopied ? "check" : "content_copy"
mainText: justCopied ? Translation.tr("Path copied") : Translation.tr("Copy path")
onClicked: {
copyPathButton.justCopied = true
Quickshell.clipboardText = FileUtils.trimFileProtocol(`${Directories.config}/illogical-impulse/config.json`);
revertTextTimer.restart();
}
colBackground: ColorUtils.transparentize(Appearance.colors.colPrimaryContainer)
colBackgroundHover: Appearance.colors.colPrimaryContainerHover
colRipple: Appearance.colors.colPrimaryContainerActive
Timer {
id: revertTextTimer
interval: 1500
onTriggered: {
copyPathButton.justCopied = false
}
}
}
}
}