1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-27 06:52:50 -05:00

workspaces: add icon size offset

This commit is contained in:
bbedward
2026-01-25 22:49:46 -05:00
parent ad458dfece
commit 83d9808536
4 changed files with 14 additions and 1 deletions

View File

@@ -242,6 +242,7 @@ Singleton {
property bool showWorkspaceApps: false
property bool groupWorkspaceApps: true
property int maxWorkspaceIcons: 3
property int workspaceAppIconSizeOffset: 0
property bool workspaceFollowFocus: false
property bool showOccupiedWorkspacesOnly: false
property bool reverseScrolling: false

View File

@@ -98,6 +98,7 @@ var SPEC = {
workspaceScrolling: { def: false },
showWorkspaceApps: { def: false },
maxWorkspaceIcons: { def: 3 },
workspaceAppIconSizeOffset: { def: 0 },
groupWorkspaceApps: { def: true },
workspaceFollowFocus: { def: false },
showOccupiedWorkspacesOnly: { def: false },

View File

@@ -504,7 +504,7 @@ Item {
readonly property real padding: Math.max(Theme.spacingXS, Theme.spacingS * (widgetHeight / 30))
readonly property real visualWidth: isVertical ? widgetHeight : (workspaceRow.implicitWidth + padding * 2)
readonly property real visualHeight: isVertical ? (workspaceRow.implicitHeight + padding * 2) : widgetHeight
readonly property real appIconSize: Theme.barIconSize(barThickness, -6, root.barConfig?.noBackground)
readonly property real appIconSize: Theme.barIconSize(barThickness, -6 + SettingsData.workspaceAppIconSizeOffset, root.barConfig?.noBackground)
function getRealWorkspaces() {
return root.workspaceList.filter(ws => {

View File

@@ -104,6 +104,17 @@ Item {
}
}
SettingsSliderRow {
visible: SettingsData.showWorkspaceApps
text: I18n.tr("Icon Size")
value: SettingsData.workspaceAppIconSizeOffset
minimum: 0
maximum: 10
unit: "px"
defaultValue: 0
onSliderValueChanged: newValue => SettingsData.set("workspaceAppIconSizeOffset", newValue)
}
SettingsToggleRow {
settingKey: "groupWorkspaceApps"
tags: ["workspace", "apps", "icons", "group", "grouped", "collapse"]