mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-04-13 01:02:18 -04:00
feat: Refactor DankBar w/New granular options - New background toggles - New maxIcon & maxText widget sizes (global) - Dedicated M3 padding slider - New independent icon scale options - Updated logic to improve performance on single & dual bar modes
This commit is contained in:
@@ -572,6 +572,10 @@ Singleton {
|
|||||||
"widgetTransparency": 1.0,
|
"widgetTransparency": 1.0,
|
||||||
"squareCorners": false,
|
"squareCorners": false,
|
||||||
"noBackground": false,
|
"noBackground": false,
|
||||||
|
"maximizeWidgetIcons": false,
|
||||||
|
"maximizeWidgetText": false,
|
||||||
|
"removeWidgetPadding": false,
|
||||||
|
"widgetPadding": 12,
|
||||||
"gothCornersEnabled": false,
|
"gothCornersEnabled": false,
|
||||||
"gothCornerRadiusOverride": false,
|
"gothCornerRadiusOverride": false,
|
||||||
"gothCornerRadiusValue": 12,
|
"gothCornerRadiusValue": 12,
|
||||||
@@ -584,6 +588,7 @@ Singleton {
|
|||||||
"widgetOutlineOpacity": 1.0,
|
"widgetOutlineOpacity": 1.0,
|
||||||
"widgetOutlineThickness": 1,
|
"widgetOutlineThickness": 1,
|
||||||
"fontScale": 1.0,
|
"fontScale": 1.0,
|
||||||
|
"iconScale": 1.0,
|
||||||
"autoHide": false,
|
"autoHide": false,
|
||||||
"autoHideDelay": 250,
|
"autoHideDelay": 250,
|
||||||
"showOnWindowsOpen": false,
|
"showOnWindowsOpen": false,
|
||||||
|
|||||||
@@ -1169,21 +1169,23 @@ Singleton {
|
|||||||
return (0.299 * c.r + 0.587 * c.g + 0.114 * c.b) < 0.5;
|
return (0.299 * c.r + 0.587 * c.g + 0.114 * c.b) < 0.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
function barIconSize(barThickness, offset, noBackground) {
|
function barIconSize(barThickness, offset, maximizeIcon, iconScale) {
|
||||||
const defaultOffset = offset !== undefined ? offset : -6;
|
const defaultOffset = offset !== undefined ? offset : -6;
|
||||||
const size = (noBackground ?? false) ? iconSizeLarge : iconSize;
|
const size = (maximizeIcon ?? false) ? iconSizeLarge : iconSize;
|
||||||
|
const s = iconScale !== undefined ? iconScale : 1.0;
|
||||||
|
|
||||||
return Math.round((barThickness / 48) * (size + defaultOffset));
|
return Math.round((barThickness / 48) * (size + defaultOffset) * s);
|
||||||
}
|
}
|
||||||
|
|
||||||
function barTextSize(barThickness, fontScale) {
|
function barTextSize(barThickness, fontScale, maximizeText) {
|
||||||
const scale = barThickness / 48;
|
const scale = barThickness / 48;
|
||||||
const dankBarScale = fontScale !== undefined ? fontScale : 1.0;
|
const dankBarScale = fontScale !== undefined ? fontScale : 1.0;
|
||||||
|
const maxScale = (maximizeText ?? false) ? 1.5 : 1.0;
|
||||||
if (scale <= 0.75)
|
if (scale <= 0.75)
|
||||||
return Math.round(fontSizeSmall * 0.9 * dankBarScale);
|
return Math.round(fontSizeSmall * 0.9 * dankBarScale * maxScale);
|
||||||
if (scale >= 1.25)
|
if (scale >= 1.25)
|
||||||
return Math.round(fontSizeMedium * dankBarScale);
|
return Math.round(fontSizeMedium * dankBarScale * maxScale);
|
||||||
return Math.round(fontSizeSmall * dankBarScale);
|
return Math.round(fontSizeSmall * dankBarScale * maxScale);
|
||||||
}
|
}
|
||||||
|
|
||||||
function getBatteryIcon(level, isCharging, batteryAvailable) {
|
function getBatteryIcon(level, isCharging, batteryAvailable) {
|
||||||
|
|||||||
@@ -395,6 +395,10 @@ var SPEC = {
|
|||||||
widgetTransparency: 1.0,
|
widgetTransparency: 1.0,
|
||||||
squareCorners: false,
|
squareCorners: false,
|
||||||
noBackground: false,
|
noBackground: false,
|
||||||
|
maximizeWidgetIcons: false,
|
||||||
|
maximizeWidgetText: false,
|
||||||
|
removeWidgetPadding: false,
|
||||||
|
widgetPadding: 12,
|
||||||
gothCornersEnabled: false,
|
gothCornersEnabled: false,
|
||||||
gothCornerRadiusOverride: false,
|
gothCornerRadiusOverride: false,
|
||||||
gothCornerRadiusValue: 12,
|
gothCornerRadiusValue: 12,
|
||||||
@@ -407,6 +411,7 @@ var SPEC = {
|
|||||||
widgetOutlineOpacity: 1.0,
|
widgetOutlineOpacity: 1.0,
|
||||||
widgetOutlineThickness: 1,
|
widgetOutlineThickness: 1,
|
||||||
fontScale: 1.0,
|
fontScale: 1.0,
|
||||||
|
iconScale: 1.0,
|
||||||
autoHide: false,
|
autoHide: false,
|
||||||
autoHideDelay: 250,
|
autoHideDelay: 250,
|
||||||
showOnWindowsOpen: false,
|
showOnWindowsOpen: false,
|
||||||
|
|||||||
@@ -400,7 +400,7 @@ BasePill {
|
|||||||
Component.onCompleted: updateModel()
|
Component.onCompleted: updateModel()
|
||||||
|
|
||||||
visible: dockItems.length > 0
|
visible: dockItems.length > 0
|
||||||
readonly property real iconCellSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground) + 6
|
readonly property real iconCellSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale) + 6
|
||||||
|
|
||||||
content: Component {
|
content: Component {
|
||||||
Item {
|
Item {
|
||||||
@@ -597,7 +597,7 @@ BasePill {
|
|||||||
readonly property bool enlargeEnabled: (widgetData?.appsDockEnlargeOnHover !== undefined ? widgetData.appsDockEnlargeOnHover : SettingsData.appsDockEnlargeOnHover)
|
readonly property bool enlargeEnabled: (widgetData?.appsDockEnlargeOnHover !== undefined ? widgetData.appsDockEnlargeOnHover : SettingsData.appsDockEnlargeOnHover)
|
||||||
readonly property real enlargeScale: enlargeEnabled && mouseArea.containsMouse ? (widgetData?.appsDockEnlargePercentage !== undefined ? widgetData.appsDockEnlargePercentage : SettingsData.appsDockEnlargePercentage) / 100.0 : 1.0
|
readonly property real enlargeScale: enlargeEnabled && mouseArea.containsMouse ? (widgetData?.appsDockEnlargePercentage !== undefined ? widgetData.appsDockEnlargePercentage : SettingsData.appsDockEnlargePercentage) / 100.0 : 1.0
|
||||||
readonly property real baseIconSizeMultiplier: (widgetData?.appsDockIconSizePercentage !== undefined ? widgetData.appsDockIconSizePercentage : SettingsData.appsDockIconSizePercentage) / 100.0
|
readonly property real baseIconSizeMultiplier: (widgetData?.appsDockIconSizePercentage !== undefined ? widgetData.appsDockIconSizePercentage : SettingsData.appsDockIconSizePercentage) / 100.0
|
||||||
readonly property real effectiveIconSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground) * baseIconSizeMultiplier
|
readonly property real effectiveIconSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale) * baseIconSizeMultiplier
|
||||||
|
|
||||||
readonly property color activeOverlayColor: {
|
readonly property color activeOverlayColor: {
|
||||||
switch (SettingsData.appsDockActiveColorMode) {
|
switch (SettingsData.appsDockActiveColorMode) {
|
||||||
@@ -795,7 +795,7 @@ BasePill {
|
|||||||
anchors.rightMargin: Theme.spacingS
|
anchors.rightMargin: Theme.spacingS
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: appItem.windowTitle || appItem.appId
|
text: appItem.windowTitle || appItem.appId
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: BatteryService.getBatteryIcon()
|
name: BatteryService.getBatteryIcon()
|
||||||
size: Theme.barIconSize(battery.barThickness, undefined, battery.barConfig?.noBackground)
|
size: Theme.barIconSize(battery.barThickness, undefined, battery.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (!BatteryService.batteryAvailable) {
|
if (!BatteryService.batteryAvailable) {
|
||||||
return Theme.widgetIconColor;
|
return Theme.widgetIconColor;
|
||||||
@@ -63,7 +63,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: BatteryService.batteryLevel.toString()
|
text: BatteryService.batteryLevel.toString()
|
||||||
font.pixelSize: Theme.barTextSize(battery.barThickness, battery.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(battery.barThickness, battery.barConfig?.fontScale, battery.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
visible: BatteryService.batteryAvailable
|
visible: BatteryService.batteryAvailable
|
||||||
@@ -78,7 +78,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: BatteryService.getBatteryIcon()
|
name: BatteryService.getBatteryIcon()
|
||||||
size: Theme.barIconSize(battery.barThickness, -4, battery.barConfig?.noBackground)
|
size: Theme.barIconSize(battery.barThickness, -4, battery.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (!BatteryService.batteryAvailable) {
|
if (!BatteryService.batteryAvailable) {
|
||||||
return Theme.widgetIconColor;
|
return Theme.widgetIconColor;
|
||||||
@@ -99,7 +99,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: `${BatteryService.batteryLevel}%`
|
text: `${BatteryService.batteryLevel}%`
|
||||||
font.pixelSize: Theme.barTextSize(battery.barThickness, battery.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(battery.barThickness, battery.barConfig?.fontScale, battery.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: BatteryService.batteryAvailable
|
visible: BatteryService.batteryAvailable
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "shift_lock"
|
name: "shift_lock"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "content_paste"
|
name: "content_paste"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ BasePill {
|
|||||||
const display = hours === 0 ? 12 : hours > 12 ? hours - 12 : hours;
|
const display = hours === 0 ? 12 : hours > 12 ? hours - 12 : hours;
|
||||||
return String(display).padStart(2, '0').charAt(0);
|
return String(display).padStart(2, '0').charAt(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -53,7 +53,7 @@ BasePill {
|
|||||||
const display = hours === 0 ? 12 : hours > 12 ? hours - 12 : hours;
|
const display = hours === 0 ? 12 : hours > 12 ? hours - 12 : hours;
|
||||||
return String(display).padStart(2, '0').charAt(1);
|
return String(display).padStart(2, '0').charAt(1);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -67,7 +67,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: String(systemClock?.date?.getMinutes()).padStart(2, '0').charAt(0)
|
text: String(systemClock?.date?.getMinutes()).padStart(2, '0').charAt(0)
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -76,7 +76,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: String(systemClock?.date?.getMinutes()).padStart(2, '0').charAt(1)
|
text: String(systemClock?.date?.getMinutes()).padStart(2, '0').charAt(1)
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -91,7 +91,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: String(systemClock?.date?.getSeconds()).padStart(2, '0').charAt(0)
|
text: String(systemClock?.date?.getSeconds()).padStart(2, '0').charAt(0)
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -100,7 +100,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: String(systemClock?.date?.getSeconds()).padStart(2, '0').charAt(1)
|
text: String(systemClock?.date?.getSeconds()).padStart(2, '0').charAt(1)
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -135,7 +135,7 @@ BasePill {
|
|||||||
const value = dayFirst ? String(systemClock?.date?.getDate()).padStart(2, '0') : String(systemClock?.date?.getMonth() + 1).padStart(2, '0');
|
const value = dayFirst ? String(systemClock?.date?.getDate()).padStart(2, '0') : String(systemClock?.date?.getMonth() + 1).padStart(2, '0');
|
||||||
return value.charAt(0);
|
return value.charAt(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -150,7 +150,7 @@ BasePill {
|
|||||||
const value = dayFirst ? String(systemClock?.date?.getDate()).padStart(2, '0') : String(systemClock?.date?.getMonth() + 1).padStart(2, '0');
|
const value = dayFirst ? String(systemClock?.date?.getDate()).padStart(2, '0') : String(systemClock?.date?.getMonth() + 1).padStart(2, '0');
|
||||||
return value.charAt(1);
|
return value.charAt(1);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -171,7 +171,7 @@ BasePill {
|
|||||||
const value = dayFirst ? String(systemClock?.date?.getMonth() + 1).padStart(2, '0') : String(systemClock?.date?.getDate()).padStart(2, '0');
|
const value = dayFirst ? String(systemClock?.date?.getMonth() + 1).padStart(2, '0') : String(systemClock?.date?.getDate()).padStart(2, '0');
|
||||||
return value.charAt(0);
|
return value.charAt(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -186,7 +186,7 @@ BasePill {
|
|||||||
const value = dayFirst ? String(systemClock?.date?.getMonth() + 1).padStart(2, '0') : String(systemClock?.date?.getDate()).padStart(2, '0');
|
const value = dayFirst ? String(systemClock?.date?.getMonth() + 1).padStart(2, '0') : String(systemClock?.date?.getDate()).padStart(2, '0');
|
||||||
return value.charAt(1);
|
return value.charAt(1);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
width: Math.round(font.pixelSize * 0.6)
|
width: Math.round(font.pixelSize * 0.6)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
@@ -201,7 +201,7 @@ BasePill {
|
|||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
spacing: Theme.spacingS
|
spacing: Theme.spacingS
|
||||||
|
|
||||||
property real fontSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
property real fontSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
property real digitWidth: fontSize * 0.6
|
property real digitWidth: fontSize * 0.6
|
||||||
|
|
||||||
property string hoursStr: {
|
property string hoursStr: {
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "palette"
|
name: "palette"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.isActive ? Theme.primary : Theme.surfaceText
|
color: root.isActive ? Theme.primary : Theme.surfaceText
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ BasePill {
|
|||||||
property real micAccumulator: 0
|
property real micAccumulator: 0
|
||||||
property real volumeAccumulator: 0
|
property real volumeAccumulator: 0
|
||||||
property real brightnessAccumulator: 0
|
property real brightnessAccumulator: 0
|
||||||
readonly property real vIconSize: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
readonly property real vIconSize: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
property var _hRow: null
|
property var _hRow: null
|
||||||
property var _vCol: null
|
property var _vCol: null
|
||||||
property var _hAudio: null
|
property var _hAudio: null
|
||||||
@@ -394,7 +394,7 @@ BasePill {
|
|||||||
id: audioPercentV
|
id: audioPercentV
|
||||||
visible: root.showAudioPercent
|
visible: root.showAudioPercent
|
||||||
text: Math.round((AudioService.sink?.audio?.volume ?? 0) * 100) + "%"
|
text: Math.round((AudioService.sink?.audio?.volume ?? 0) * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.top: audioIconV.bottom
|
anchors.top: audioIconV.bottom
|
||||||
@@ -420,7 +420,7 @@ BasePill {
|
|||||||
id: micPercentV
|
id: micPercentV
|
||||||
visible: root.showMicPercent
|
visible: root.showMicPercent
|
||||||
text: Math.round((AudioService.source?.audio?.volume ?? 0) * 100) + "%"
|
text: Math.round((AudioService.source?.audio?.volume ?? 0) * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.top: micIconV.bottom
|
anchors.top: micIconV.bottom
|
||||||
@@ -446,7 +446,7 @@ BasePill {
|
|||||||
id: brightnessPercentV
|
id: brightnessPercentV
|
||||||
visible: root.showBrightnessPercent
|
visible: root.showBrightnessPercent
|
||||||
text: Math.round(getBrightness() * 100) + "%"
|
text: Math.round(getBrightness() * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.top: brightnessIconV.bottom
|
anchors.top: brightnessIconV.bottom
|
||||||
@@ -502,7 +502,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "screen_record"
|
name: "screen_record"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: NiriService.hasActiveCast ? Theme.primary : Theme.surfaceText
|
color: NiriService.hasActiveCast ? Theme.primary : Theme.surfaceText
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showScreenSharingIcon && NiriService.hasCasts
|
visible: root.showScreenSharingIcon && NiriService.hasCasts
|
||||||
@@ -511,7 +511,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: networkIcon
|
id: networkIcon
|
||||||
name: root.getNetworkIconName()
|
name: root.getNetworkIconName()
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.getNetworkIconColor()
|
color: root.getNetworkIconColor()
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showNetworkIcon && NetworkService.networkAvailable
|
visible: root.showNetworkIcon && NetworkService.networkAvailable
|
||||||
@@ -520,7 +520,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: vpnIcon
|
id: vpnIcon
|
||||||
name: "vpn_lock"
|
name: "vpn_lock"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: NetworkService.vpnConnected ? Theme.primary : Theme.surfaceText
|
color: NetworkService.vpnConnected ? Theme.primary : Theme.surfaceText
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showVpnIcon && NetworkService.vpnAvailable && NetworkService.vpnConnected
|
visible: root.showVpnIcon && NetworkService.vpnAvailable && NetworkService.vpnConnected
|
||||||
@@ -529,7 +529,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: bluetoothIcon
|
id: bluetoothIcon
|
||||||
name: "bluetooth"
|
name: "bluetooth"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: BluetoothService.connected ? Theme.primary : Theme.surfaceText
|
color: BluetoothService.connected ? Theme.primary : Theme.surfaceText
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showBluetoothIcon && BluetoothService.available && BluetoothService.enabled
|
visible: root.showBluetoothIcon && BluetoothService.available && BluetoothService.enabled
|
||||||
@@ -545,7 +545,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: audioIcon
|
id: audioIcon
|
||||||
name: root.getVolumeIconName()
|
name: root.getVolumeIconName()
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -556,7 +556,7 @@ BasePill {
|
|||||||
id: audioPercent
|
id: audioPercent
|
||||||
visible: root.showAudioPercent
|
visible: root.showAudioPercent
|
||||||
text: Math.round((AudioService.sink?.audio?.volume ?? 0) * 100) + "%"
|
text: Math.round((AudioService.sink?.audio?.volume ?? 0) * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: audioIcon.right
|
anchors.left: audioIcon.right
|
||||||
@@ -574,7 +574,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: micIcon
|
id: micIcon
|
||||||
name: root.getMicIconName()
|
name: root.getMicIconName()
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.getMicIconColor()
|
color: root.getMicIconColor()
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -585,7 +585,7 @@ BasePill {
|
|||||||
id: micPercent
|
id: micPercent
|
||||||
visible: root.showMicPercent
|
visible: root.showMicPercent
|
||||||
text: Math.round((AudioService.source?.audio?.volume ?? 0) * 100) + "%"
|
text: Math.round((AudioService.source?.audio?.volume ?? 0) * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: micIcon.right
|
anchors.left: micIcon.right
|
||||||
@@ -603,7 +603,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: brightnessIcon
|
id: brightnessIcon
|
||||||
name: root.getBrightnessIconName()
|
name: root.getBrightnessIconName()
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -614,7 +614,7 @@ BasePill {
|
|||||||
id: brightnessPercent
|
id: brightnessPercent
|
||||||
visible: root.showBrightnessPercent
|
visible: root.showBrightnessPercent
|
||||||
text: Math.round(getBrightness() * 100) + "%"
|
text: Math.round(getBrightness() * 100) + "%"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.left: brightnessIcon.right
|
anchors.left: brightnessIcon.right
|
||||||
@@ -625,7 +625,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: batteryIcon
|
id: batteryIcon
|
||||||
name: Theme.getBatteryIcon(BatteryService.batteryLevel, BatteryService.isCharging, BatteryService.batteryAvailable)
|
name: Theme.getBatteryIcon(BatteryService.batteryLevel, BatteryService.isCharging, BatteryService.batteryAvailable)
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.getBatteryIconColor()
|
color: root.getBatteryIconColor()
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showBatteryIcon && BatteryService.batteryAvailable
|
visible: root.showBatteryIcon && BatteryService.batteryAvailable
|
||||||
@@ -634,7 +634,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: printerIcon
|
id: printerIcon
|
||||||
name: "print"
|
name: "print"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.primary
|
color: Theme.primary
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.showPrinterIcon && CupsService.cupsAvailable && root.hasPrintJobs()
|
visible: root.showPrinterIcon && CupsService.cupsAvailable && root.hasPrintJobs()
|
||||||
@@ -642,7 +642,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "settings"
|
name: "settings"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.isActive ? Theme.primary : Theme.widgetIconColor
|
color: root.isActive ? Theme.primary : Theme.widgetIconColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: root.hasNoVisibleIcons()
|
visible: root.hasNoVisibleIcons()
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "memory"
|
name: "memory"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.cpuUsage > 80) {
|
if (DgopService.cpuUsage > 80) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -59,7 +59,7 @@ BasePill {
|
|||||||
|
|
||||||
return DgopService.cpuUsage.toFixed(0);
|
return DgopService.cpuUsage.toFixed(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -74,7 +74,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: cpuIcon
|
id: cpuIcon
|
||||||
name: "memory"
|
name: "memory"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.cpuUsage > 80) {
|
if (DgopService.cpuUsage > 80) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -101,7 +101,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: cpuBaseline
|
id: cpuBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "88%"
|
text: "88%"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -114,7 +114,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return v.toFixed(0) + "%";
|
return v.toFixed(0) + "%";
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "device_thermostat"
|
name: "device_thermostat"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.cpuTemperature > 85) {
|
if (DgopService.cpuTemperature > 85) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -59,7 +59,7 @@ BasePill {
|
|||||||
|
|
||||||
return Math.round(DgopService.cpuTemperature).toString();
|
return Math.round(DgopService.cpuTemperature).toString();
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -74,7 +74,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: cpuTempIcon
|
id: cpuTempIcon
|
||||||
name: "device_thermostat"
|
name: "device_thermostat"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.cpuTemperature > 85) {
|
if (DgopService.cpuTemperature > 85) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -101,7 +101,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: tempBaseline
|
id: tempBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "88°"
|
text: "88°"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -114,7 +114,7 @@ BasePill {
|
|||||||
|
|
||||||
return Math.round(DgopService.cpuTemperature) + "°";
|
return Math.round(DgopService.cpuTemperature) + "°";
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|||||||
@@ -57,14 +57,14 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: layout.getLayoutIcon(layout.currentLayoutSymbol)
|
name: layout.getLayoutIcon(layout.currentLayoutSymbol)
|
||||||
size: Theme.barIconSize(layout.barThickness, undefined, layout.barConfig?.noBackground)
|
size: Theme.barIconSize(layout.barThickness, undefined, layout.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: layout.currentLayoutSymbol
|
text: layout.currentLayoutSymbol
|
||||||
font.pixelSize: Theme.barTextSize(layout.barThickness, layout.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(layout.barThickness, layout.barConfig?.fontScale, layout.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -78,14 +78,14 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: layout.getLayoutIcon(layout.currentLayoutSymbol)
|
name: layout.getLayoutIcon(layout.currentLayoutSymbol)
|
||||||
size: Theme.barIconSize(layout.barThickness, -4, layout.barConfig?.noBackground)
|
size: Theme.barIconSize(layout.barThickness, -4, layout.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: layout.currentLayoutSymbol
|
text: layout.currentLayoutSymbol
|
||||||
font.pixelSize: Theme.barTextSize(layout.barThickness, layout.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(layout.barThickness, layout.barConfig?.fontScale, layout.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "storage"
|
name: "storage"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (root.diskUsagePercent > 90) {
|
if (root.diskUsagePercent > 90) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -132,7 +132,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return root.diskUsagePercent.toFixed(0);
|
return root.diskUsagePercent.toFixed(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -146,7 +146,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "storage"
|
name: "storage"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (root.diskUsagePercent > 90) {
|
if (root.diskUsagePercent > 90) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -166,7 +166,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return root.selectedMount.mount;
|
return root.selectedMount.mount;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
horizontalAlignment: Text.AlignLeft
|
horizontalAlignment: Text.AlignLeft
|
||||||
@@ -180,7 +180,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return root.diskUsagePercent.toFixed(0) + "%";
|
return root.diskUsagePercent.toFixed(0) + "%";
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
horizontalAlignment: Text.AlignLeft
|
horizontalAlignment: Text.AlignLeft
|
||||||
@@ -188,7 +188,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: diskBaseline
|
id: diskBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "100%"
|
text: "100%"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -189,7 +189,7 @@ BasePill {
|
|||||||
return "";
|
return "";
|
||||||
return Paths.getAppName(activeWindow.appId, activeDesktopEntry);
|
return Paths.getAppName(activeWindow.appId, activeDesktopEntry);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
@@ -200,7 +200,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: "•"
|
text: "•"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.outlineButton
|
color: Theme.outlineButton
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: !compactMode && appText.text && titleText.text
|
visible: !compactMode && appText.text && titleText.text
|
||||||
@@ -225,7 +225,7 @@ BasePill {
|
|||||||
|
|
||||||
return title;
|
return title;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "auto_awesome_mosaic"
|
name: "auto_awesome_mosaic"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (root.displayTemp > 80) {
|
if (root.displayTemp > 80) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -127,7 +127,7 @@ BasePill {
|
|||||||
|
|
||||||
return Math.round(root.displayTemp).toString();
|
return Math.round(root.displayTemp).toString();
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -142,7 +142,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: gpuTempIcon
|
id: gpuTempIcon
|
||||||
name: "auto_awesome_mosaic"
|
name: "auto_awesome_mosaic"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (root.displayTemp > 80) {
|
if (root.displayTemp > 80) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -169,7 +169,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: gpuTempBaseline
|
id: gpuTempBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "88°"
|
text: "88°"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -182,7 +182,7 @@ BasePill {
|
|||||||
|
|
||||||
return Math.round(root.displayTemp) + "°";
|
return Math.round(root.displayTemp) + "°";
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: SessionService.idleInhibited ? "motion_sensor_active" : "motion_sensor_idle"
|
name: SessionService.idleInhibited ? "motion_sensor_active" : "motion_sensor_idle"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -131,7 +131,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "keyboard"
|
name: "keyboard"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -144,7 +144,7 @@ BasePill {
|
|||||||
const code = root.langCodes[lang] || lang.substring(0, 2);
|
const code = root.langCodes[lang] || lang.substring(0, 2);
|
||||||
return code.toUpperCase();
|
return code.toUpperCase();
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -177,7 +177,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return root.currentLayout;
|
return root.currentLayout;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,15 +21,15 @@ BasePill {
|
|||||||
visible: SettingsData.launcherLogoMode === "apps"
|
visible: SettingsData.launcherLogoMode === "apps"
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "apps"
|
name: "apps"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
}
|
}
|
||||||
|
|
||||||
SystemLogo {
|
SystemLogo {
|
||||||
visible: SettingsData.launcherLogoMode === "os"
|
visible: SettingsData.launcherLogoMode === "os"
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
colorOverride: Theme.effectiveLogoColor
|
colorOverride: Theme.effectiveLogoColor
|
||||||
brightnessOverride: SettingsData.launcherLogoBrightness
|
brightnessOverride: SettingsData.launcherLogoBrightness
|
||||||
contrastOverride: SettingsData.launcherLogoContrast
|
contrastOverride: SettingsData.launcherLogoContrast
|
||||||
@@ -38,8 +38,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
visible: SettingsData.launcherLogoMode === "dank"
|
visible: SettingsData.launcherLogoMode === "dank"
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
smooth: true
|
smooth: true
|
||||||
mipmap: true
|
mipmap: true
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
@@ -57,8 +57,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
visible: SettingsData.launcherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle || CompositorService.isLabwc)
|
visible: SettingsData.launcherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle || CompositorService.isLabwc)
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
smooth: true
|
smooth: true
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
source: {
|
source: {
|
||||||
@@ -96,8 +96,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
visible: SettingsData.launcherLogoMode === "custom" && SettingsData.launcherLogoCustomPath !== ""
|
visible: SettingsData.launcherLogoMode === "custom" && SettingsData.launcherLogoCustomPath !== ""
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
smooth: true
|
smooth: true
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
source: SettingsData.launcherLogoCustomPath ? "file://" + SettingsData.launcherLogoCustomPath.replace("file://", "") : ""
|
source: SettingsData.launcherLogoCustomPath ? "file://" + SettingsData.launcherLogoCustomPath.replace("file://", "") : ""
|
||||||
|
|||||||
@@ -284,7 +284,7 @@ BasePill {
|
|||||||
|
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: textContainer.displayText
|
text: textContainer.displayText
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
wrapMode: Text.NoWrap
|
wrapMode: Text.NoWrap
|
||||||
x: needsScrolling ? -scrollOffset : 0
|
x: needsScrolling ? -scrollOffset : 0
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "network_check"
|
name: "network_check"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -53,7 +53,7 @@ BasePill {
|
|||||||
if (rate < 1024 * 1024) return (rate / 1024).toFixed(0) + "K"
|
if (rate < 1024 * 1024) return (rate / 1024).toFixed(0) + "K"
|
||||||
return (rate / (1024 * 1024)).toFixed(0) + "M"
|
return (rate / (1024 * 1024)).toFixed(0) + "M"
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.info
|
color: Theme.info
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -65,7 +65,7 @@ BasePill {
|
|||||||
if (rate < 1024 * 1024) return (rate / 1024).toFixed(0) + "K"
|
if (rate < 1024 * 1024) return (rate / 1024).toFixed(0) + "K"
|
||||||
return (rate / (1024 * 1024)).toFixed(0) + "M"
|
return (rate / (1024 * 1024)).toFixed(0) + "M"
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.error
|
color: Theme.error
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -79,7 +79,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "network_check"
|
name: "network_check"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
@@ -90,13 +90,13 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: "↓"
|
text: "↓"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.info
|
color: Theme.info
|
||||||
}
|
}
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: DgopService.networkRxRate > 0 ? root.formatNetworkSpeed(DgopService.networkRxRate) : "0 B/s"
|
text: DgopService.networkRxRate > 0 ? root.formatNetworkSpeed(DgopService.networkRxRate) : "0 B/s"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
horizontalAlignment: Text.AlignLeft
|
horizontalAlignment: Text.AlignLeft
|
||||||
@@ -105,7 +105,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: rxBaseline
|
id: rxBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "88.8 MB/s"
|
text: "88.8 MB/s"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -119,13 +119,13 @@ BasePill {
|
|||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: "↑"
|
text: "↑"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.error
|
color: Theme.error
|
||||||
}
|
}
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: DgopService.networkTxRate > 0 ? root.formatNetworkSpeed(DgopService.networkTxRate) : "0 B/s"
|
text: DgopService.networkTxRate > 0 ? root.formatNetworkSpeed(DgopService.networkTxRate) : "0 B/s"
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
horizontalAlignment: Text.AlignLeft
|
horizontalAlignment: Text.AlignLeft
|
||||||
@@ -134,7 +134,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: txBaseline
|
id: txBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: "88.8 MB/s"
|
text: "88.8 MB/s"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ BasePill {
|
|||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "assignment"
|
name: "assignment"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: root.isActive ? Theme.primary : Theme.surfaceText
|
color: root.isActive ? Theme.primary : Theme.surfaceText
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ BasePill {
|
|||||||
id: notifIcon
|
id: notifIcon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: SessionData.doNotDisturb ? "notifications_off" : "notifications"
|
name: SessionData.doNotDisturb ? "notifications_off" : "notifications"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: SessionData.doNotDisturb ? Theme.primary : (root.isActive ? Theme.primary : Theme.widgetIconColor)
|
color: SessionData.doNotDisturb ? Theme.primary : (root.isActive ? Theme.primary : Theme.widgetIconColor)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: "power_settings_new"
|
name: "power_settings_new"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ BasePill {
|
|||||||
id: tooltipText
|
id: tooltipText
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
text: PrivacyService.getPrivacySummary()
|
text: PrivacyService.getPrivacySummary()
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: "developer_board"
|
name: "developer_board"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.memoryUsage > 90) {
|
if (DgopService.memoryUsage > 90) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -61,7 +61,7 @@ BasePill {
|
|||||||
|
|
||||||
return DgopService.memoryUsage.toFixed(0);
|
return DgopService.memoryUsage.toFixed(0);
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -69,7 +69,7 @@ BasePill {
|
|||||||
StyledText {
|
StyledText {
|
||||||
visible: root.showSwap && DgopService.totalSwapKB > 0
|
visible: root.showSwap && DgopService.totalSwapKB > 0
|
||||||
text: root.swapUsage.toFixed(0)
|
text: root.swapUsage.toFixed(0)
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.surfaceVariantText
|
color: Theme.surfaceVariantText
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -84,7 +84,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
id: ramIcon
|
id: ramIcon
|
||||||
name: "developer_board"
|
name: "developer_board"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (DgopService.memoryUsage > 90) {
|
if (DgopService.memoryUsage > 90) {
|
||||||
return Theme.tempDanger;
|
return Theme.tempDanger;
|
||||||
@@ -111,7 +111,7 @@ BasePill {
|
|||||||
|
|
||||||
StyledTextMetrics {
|
StyledTextMetrics {
|
||||||
id: ramBaseline
|
id: ramBaseline
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
text: {
|
text: {
|
||||||
if (!root.showSwap) {
|
if (!root.showSwap) {
|
||||||
return "88%";
|
return "88%";
|
||||||
@@ -136,7 +136,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
return ramText;
|
return ramText;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
readonly property int windowCount: _groupByApp ? (groupedWindows?.length || 0) : (sortedToplevels?.length || 0)
|
readonly property int windowCount: _groupByApp ? (groupedWindows?.length || 0) : (sortedToplevels?.length || 0)
|
||||||
readonly property real iconCellSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground) + 6
|
readonly property real iconCellSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale) + 6
|
||||||
|
|
||||||
readonly property string focusedAppId: {
|
readonly property string focusedAppId: {
|
||||||
if (!sortedToplevels || sortedToplevels.length === 0)
|
if (!sortedToplevels || sortedToplevels.length === 0)
|
||||||
@@ -277,10 +277,10 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
id: iconImg
|
id: iconImg
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)) / 2) : Theme.spacingXS
|
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)) / 2) : Theme.spacingXS
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
source: {
|
source: {
|
||||||
root._desktopEntriesUpdateTrigger;
|
root._desktopEntriesUpdateTrigger;
|
||||||
root._appIdSubstitutionsTrigger;
|
root._appIdSubstitutionsTrigger;
|
||||||
@@ -306,9 +306,9 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)) / 2) : Theme.spacingXS
|
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)) / 2) : Theme.spacingXS
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
name: "sports_esports"
|
name: "sports_esports"
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
visible: !iconImg.visible && Paths.isSteamApp(appId)
|
visible: !iconImg.visible && Paths.isSteamApp(appId)
|
||||||
@@ -359,7 +359,7 @@ BasePill {
|
|||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: !(widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode)
|
visible: !(widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode)
|
||||||
text: windowTitle
|
text: windowTitle
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
@@ -531,10 +531,10 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
id: iconImg
|
id: iconImg
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)) / 2) : Theme.spacingXS
|
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)) / 2) : Theme.spacingXS
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
source: {
|
source: {
|
||||||
root._desktopEntriesUpdateTrigger;
|
root._desktopEntriesUpdateTrigger;
|
||||||
root._appIdSubstitutionsTrigger;
|
root._appIdSubstitutionsTrigger;
|
||||||
@@ -560,9 +560,9 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)) / 2) : Theme.spacingXS
|
anchors.leftMargin: (widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode) ? Math.round((parent.width - Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)) / 2) : Theme.spacingXS
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
name: "sports_esports"
|
name: "sports_esports"
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
visible: !iconImg.visible && Paths.isSteamApp(appId)
|
visible: !iconImg.visible && Paths.isSteamApp(appId)
|
||||||
@@ -613,7 +613,7 @@ BasePill {
|
|||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
visible: !(widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode)
|
visible: !(widgetData?.runningAppsCompactMode !== undefined ? widgetData.runningAppsCompactMode : SettingsData.runningAppsCompactMode)
|
||||||
text: windowTitle
|
text: windowTitle
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
|
|||||||
@@ -137,7 +137,7 @@ BasePill {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
readonly property real trayItemSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground) + 6
|
readonly property real trayItemSize: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale) + 6
|
||||||
|
|
||||||
readonly property real minTooltipY: {
|
readonly property real minTooltipY: {
|
||||||
if (!parentScreen || !isVerticalOrientation) {
|
if (!parentScreen || !isVerticalOrientation) {
|
||||||
@@ -277,8 +277,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
id: iconImg
|
id: iconImg
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
source: delegateRoot.iconSource
|
source: delegateRoot.iconSource
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
smooth: true
|
smooth: true
|
||||||
@@ -405,7 +405,7 @@ BasePill {
|
|||||||
DankIcon {
|
DankIcon {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
name: root.menuOpen ? "expand_less" : "expand_more"
|
name: root.menuOpen ? "expand_less" : "expand_more"
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -534,8 +534,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
id: iconImg
|
id: iconImg
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
source: delegateRoot.iconSource
|
source: delegateRoot.iconSource
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
smooth: true
|
smooth: true
|
||||||
@@ -669,7 +669,7 @@ BasePill {
|
|||||||
return root.menuOpen ? "chevron_right" : "chevron_left";
|
return root.menuOpen ? "chevron_right" : "chevron_left";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1029,8 +1029,8 @@ BasePill {
|
|||||||
IconImage {
|
IconImage {
|
||||||
id: menuIconImg
|
id: menuIconImg
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
width: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.noBackground)
|
height: Theme.barIconSize(root.barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
source: parent.iconSource
|
source: parent.iconSource
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
smooth: true
|
smooth: true
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ BasePill {
|
|||||||
return "system_update_alt";
|
return "system_update_alt";
|
||||||
return "check_circle";
|
return "check_circle";
|
||||||
}
|
}
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (SystemUpdateService.hasError)
|
if (SystemUpdateService.hasError)
|
||||||
return Theme.error;
|
return Theme.error;
|
||||||
@@ -106,8 +106,8 @@ BasePill {
|
|||||||
color: Theme.error
|
color: Theme.error
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.rightMargin: (barConfig?.noBackground ?? false) ? 0 : 6
|
anchors.rightMargin: (barConfig?.removeWidgetPadding ?? false) ? 0 : 6
|
||||||
anchors.topMargin: (barConfig?.noBackground ?? false) ? 0 : 6
|
anchors.topMargin: (barConfig?.removeWidgetPadding ?? false) ? 0 : 6
|
||||||
visible: root.isVerticalOrientation && root.hasUpdates && !root.isChecking
|
visible: root.isVerticalOrientation && root.hasUpdates && !root.isChecking
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -129,7 +129,7 @@ BasePill {
|
|||||||
return "system_update_alt";
|
return "system_update_alt";
|
||||||
return "check_circle";
|
return "check_circle";
|
||||||
}
|
}
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: {
|
color: {
|
||||||
if (SystemUpdateService.hasError)
|
if (SystemUpdateService.hasError)
|
||||||
return Theme.error;
|
return Theme.error;
|
||||||
@@ -160,7 +160,7 @@ BasePill {
|
|||||||
id: countText
|
id: countText
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: SystemUpdateService.updateCount.toString()
|
text: SystemUpdateService.updateCount.toString()
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
visible: root.hasUpdates && !root.isChecking
|
visible: root.hasUpdates && !root.isChecking
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ BasePill {
|
|||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
name: DMSNetworkService.connected ? "vpn_lock" : "vpn_key_off"
|
name: DMSNetworkService.connected ? "vpn_lock" : "vpn_key_off"
|
||||||
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: DMSNetworkService.connected ? Theme.primary : Theme.widgetIconColor
|
color: DMSNetworkService.connected ? Theme.primary : Theme.widgetIconColor
|
||||||
opacity: DMSNetworkService.isBusy ? 0.5 : 1.0
|
opacity: DMSNetworkService.isBusy ? 0.5 : 1.0
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: WeatherService.getWeatherIcon(WeatherService.weather.wCode)
|
name: WeatherService.getWeatherIcon(WeatherService.weather.wCode)
|
||||||
size: Theme.barIconSize(root.barThickness, -6, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -6, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -43,7 +43,7 @@ BasePill {
|
|||||||
const temp = SettingsData.useFahrenheit ? WeatherService.weather.tempF : WeatherService.weather.temp;
|
const temp = SettingsData.useFahrenheit ? WeatherService.weather.tempF : WeatherService.weather.temp;
|
||||||
return temp;
|
return temp;
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
}
|
}
|
||||||
@@ -57,7 +57,7 @@ BasePill {
|
|||||||
|
|
||||||
DankIcon {
|
DankIcon {
|
||||||
name: WeatherService.getWeatherIcon(WeatherService.weather.wCode)
|
name: WeatherService.getWeatherIcon(WeatherService.weather.wCode)
|
||||||
size: Theme.barIconSize(root.barThickness, -6, root.barConfig?.noBackground)
|
size: Theme.barIconSize(root.barThickness, -6, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
color: Theme.widgetIconColor
|
color: Theme.widgetIconColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
@@ -70,7 +70,7 @@ BasePill {
|
|||||||
const temp = SettingsData.useFahrenheit ? WeatherService.weather.tempF : WeatherService.weather.temp;
|
const temp = SettingsData.useFahrenheit ? WeatherService.weather.tempF : WeatherService.weather.temp;
|
||||||
return temp + "°" + (SettingsData.useFahrenheit ? "F" : "C");
|
return temp + "°" + (SettingsData.useFahrenheit ? "F" : "C");
|
||||||
}
|
}
|
||||||
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(root.barThickness, root.barConfig?.fontScale, root.barConfig?.maximizeWidgetText)
|
||||||
color: Theme.widgetTextColor
|
color: Theme.widgetTextColor
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -515,10 +515,11 @@ Item {
|
|||||||
return activeWs ? (activeWs.id || activeWs.name || "1") : "1";
|
return activeWs ? (activeWs.id || activeWs.name || "1") : "1";
|
||||||
}
|
}
|
||||||
|
|
||||||
readonly property real padding: Math.max(Theme.spacingXS, Theme.spacingS * (widgetHeight / 30))
|
readonly property real dpr: parentScreen ? CompositorService.getScreenScale(parentScreen) : 1
|
||||||
|
readonly property real padding: (root.barConfig?.removeWidgetPadding ?? false) ? 0 : Theme.snap((root.barConfig?.widgetPadding ?? 12) * (widgetHeight / 30), dpr)
|
||||||
readonly property real visualWidth: isVertical ? widgetHeight : (workspaceRow.implicitWidth + padding * 2)
|
readonly property real visualWidth: isVertical ? widgetHeight : (workspaceRow.implicitWidth + padding * 2)
|
||||||
readonly property real visualHeight: isVertical ? (workspaceRow.implicitHeight + padding * 2) : widgetHeight
|
readonly property real visualHeight: isVertical ? (workspaceRow.implicitHeight + padding * 2) : widgetHeight
|
||||||
readonly property real appIconSize: Theme.barIconSize(barThickness, -6 + SettingsData.workspaceAppIconSizeOffset, root.barConfig?.noBackground)
|
readonly property real appIconSize: Theme.barIconSize(barThickness, -6 + SettingsData.workspaceAppIconSizeOffset, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
|
|
||||||
function getRealWorkspaces() {
|
function getRealWorkspaces() {
|
||||||
return root.workspaceList.filter(ws => {
|
return root.workspaceList.filter(ws => {
|
||||||
@@ -925,9 +926,11 @@ Item {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
readonly property var loadedIconData: {
|
readonly property var loadedIconData: {
|
||||||
if (isPlaceholder) return null;
|
if (isPlaceholder)
|
||||||
|
return null;
|
||||||
const name = modelData?.name;
|
const name = modelData?.name;
|
||||||
if (!name) return null;
|
if (!name)
|
||||||
|
return null;
|
||||||
return SettingsData.getWorkspaceNameIcon(name);
|
return SettingsData.getWorkspaceNameIcon(name);
|
||||||
}
|
}
|
||||||
readonly property bool loadedHasIcon: loadedIconData !== null
|
readonly property bool loadedHasIcon: loadedIconData !== null
|
||||||
@@ -987,12 +990,12 @@ Item {
|
|||||||
return (SettingsData.groupWorkspaceApps && !isActive) ? groupedCount : totalCount;
|
return (SettingsData.groupWorkspaceApps && !isActive) ? groupedCount : totalCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
readonly property real baseWidth: root.isVertical ? (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5) : (isActive ? root.widgetHeight * 1.05 : root.widgetHeight * 0.7)
|
readonly property real baseWidth: root.isVertical ? (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5) : (isActive ? Math.max(root.widgetHeight * 1.05, root.appIconSize * 1.6) : Math.max(root.widgetHeight * 0.7, root.appIconSize * 1.2))
|
||||||
readonly property real baseHeight: root.isVertical ? (isActive ? root.widgetHeight * 1.05 : root.widgetHeight * 0.7) : (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5)
|
readonly property real baseHeight: root.isVertical ? (isActive ? Math.max(root.widgetHeight * 1.05, root.appIconSize * 1.6) : Math.max(root.widgetHeight * 0.7, root.appIconSize * 1.2)) : (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5)
|
||||||
readonly property bool hasWorkspaceName: SettingsData.showWorkspaceName && modelData?.name && modelData.name !== ""
|
readonly property bool hasWorkspaceName: SettingsData.showWorkspaceName && modelData?.name && modelData.name !== ""
|
||||||
readonly property bool workspaceNamesEnabled: SettingsData.showWorkspaceName && (CompositorService.isNiri || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
readonly property bool workspaceNamesEnabled: SettingsData.showWorkspaceName && (CompositorService.isNiri || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||||
readonly property real contentImplicitWidth: hasWorkspaceName ? (appIconsLoader.item?.contentWidth ?? 0) : 0
|
readonly property real contentImplicitWidth: appIconsLoader.item?.contentWidth ?? 0
|
||||||
readonly property real contentImplicitHeight: workspaceNamesEnabled ? (appIconsLoader.item?.contentHeight ?? 0) : 0
|
readonly property real contentImplicitHeight: appIconsLoader.item?.contentHeight ?? 0
|
||||||
|
|
||||||
readonly property real iconsExtraWidth: {
|
readonly property real iconsExtraWidth: {
|
||||||
if (!root.isVertical && SettingsData.showWorkspaceApps && stableIconCount > 0) {
|
if (!root.isVertical && SettingsData.showWorkspaceApps && stableIconCount > 0) {
|
||||||
@@ -1423,7 +1426,7 @@ Item {
|
|||||||
id: wsIcon
|
id: wsIcon
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
name: loadedIconData?.value ?? ""
|
name: loadedIconData?.value ?? ""
|
||||||
size: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
size: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
weight: (isActive && !isPlaceholder) ? 500 : 400
|
weight: (isActive && !isPlaceholder) ? 500 : 400
|
||||||
}
|
}
|
||||||
@@ -1439,7 +1442,7 @@ Item {
|
|||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: loadedIconData?.value ?? ""
|
text: loadedIconData?.value ?? ""
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1454,7 +1457,7 @@ Item {
|
|||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: loadedHasIcon ? (modelData?.name ?? "") : root.getWorkspaceIndex(modelData, index)
|
text: loadedHasIcon ? (modelData?.name ?? "") : root.getWorkspaceIndex(modelData, index)
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1555,7 +1558,7 @@ Item {
|
|||||||
visible: loadedHasIcon && loadedIconData?.type === "icon"
|
visible: loadedHasIcon && loadedIconData?.type === "icon"
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
name: loadedIconData?.value ?? ""
|
name: loadedIconData?.value ?? ""
|
||||||
size: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
size: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
weight: (isActive && !isPlaceholder) ? 500 : 400
|
weight: (isActive && !isPlaceholder) ? 500 : 400
|
||||||
}
|
}
|
||||||
@@ -1565,7 +1568,7 @@ Item {
|
|||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
text: loadedIconData?.value ?? ""
|
text: loadedIconData?.value ?? ""
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1574,7 +1577,7 @@ Item {
|
|||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
text: loadedHasIcon ? (root.isVertical ? (modelData?.name ?? "").charAt(0) : (modelData?.name ?? "")) : root.getWorkspaceIndex(modelData, index)
|
text: loadedHasIcon ? (root.isVertical ? (modelData?.name ?? "").charAt(0) : (modelData?.name ?? "")) : root.getWorkspaceIndex(modelData, index)
|
||||||
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
color: (isActive || isUrgent) ? Qt.rgba(Theme.surfaceContainer.r, Theme.surfaceContainer.g, Theme.surfaceContainer.b, 0.95) : isPlaceholder ? Theme.surfaceTextAlpha : Theme.surfaceTextMedium
|
||||||
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale)
|
font.pixelSize: Theme.barTextSize(barThickness, barConfig?.fontScale, barConfig?.maximizeWidgetText)
|
||||||
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
font.weight: (isActive && !isPlaceholder) ? Font.DemiBold : Font.Normal
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1665,7 +1668,6 @@ Item {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Component.onCompleted: updateAllData()
|
Component.onCompleted: updateAllData()
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ Item {
|
|||||||
property bool isTopBarEdge: false
|
property bool isTopBarEdge: false
|
||||||
property bool isBottomBarEdge: false
|
property bool isBottomBarEdge: false
|
||||||
readonly property real dpr: parentScreen ? CompositorService.getScreenScale(parentScreen) : 1
|
readonly property real dpr: parentScreen ? CompositorService.getScreenScale(parentScreen) : 1
|
||||||
readonly property real horizontalPadding: (barConfig?.noBackground ?? false) ? 0 : Theme.snap(Math.max(Theme.spacingXS, Theme.spacingS * (widgetThickness / 30)), dpr)
|
readonly property real horizontalPadding: (barConfig?.removeWidgetPadding ?? false) ? 0 : Theme.snap((barConfig?.widgetPadding ?? 12) * (widgetThickness / 30), dpr)
|
||||||
readonly property real visualWidth: Theme.snap(isVerticalOrientation ? widgetThickness : (contentLoader.item ? (contentLoader.item.implicitWidth + horizontalPadding * 2) : 0), dpr)
|
readonly property real visualWidth: Theme.snap(isVerticalOrientation ? widgetThickness : (contentLoader.item ? (contentLoader.item.implicitWidth + horizontalPadding * 2) : 0), dpr)
|
||||||
readonly property real visualHeight: Theme.snap(isVerticalOrientation ? (contentLoader.item ? (contentLoader.item.implicitHeight + horizontalPadding * 2) : 0) : widgetThickness, dpr)
|
readonly property real visualHeight: Theme.snap(isVerticalOrientation ? (contentLoader.item ? (contentLoader.item.implicitHeight + horizontalPadding * 2) : 0) : widgetThickness, dpr)
|
||||||
readonly property alias visualContent: visualContent
|
readonly property alias visualContent: visualContent
|
||||||
|
|||||||
@@ -59,8 +59,8 @@ Item {
|
|||||||
readonly property bool hasVerticalPill: verticalBarPill !== null
|
readonly property bool hasVerticalPill: verticalBarPill !== null
|
||||||
readonly property bool hasPopout: popoutContent !== null
|
readonly property bool hasPopout: popoutContent !== null
|
||||||
|
|
||||||
readonly property int iconSize: Theme.barIconSize(barThickness, -4, root.barConfig?.noBackground)
|
readonly property int iconSize: Theme.barIconSize(barThickness, -4, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
readonly property int iconSizeLarge: Theme.barIconSize(barThickness, undefined, root.barConfig?.noBackground)
|
readonly property int iconSizeLarge: Theme.barIconSize(barThickness, undefined, root.barConfig?.maximizeWidgetIcons, root.barConfig?.iconScale)
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
loadPluginData();
|
loadPluginData();
|
||||||
|
|||||||
@@ -28,174 +28,7 @@ Item {
|
|||||||
return pos === SettingsData.Position.Left || pos === SettingsData.Position.Right;
|
return pos === SettingsData.Position.Left || pos === SettingsData.Position.Right;
|
||||||
}
|
}
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: horizontalBarChangeDebounce
|
|
||||||
interval: 500
|
|
||||||
repeat: false
|
|
||||||
onTriggered: {
|
|
||||||
const verticalBars = SettingsData.barConfigs.filter(cfg => {
|
|
||||||
const pos = cfg.position ?? SettingsData.Position.Top;
|
|
||||||
return pos === SettingsData.Position.Left || pos === SettingsData.Position.Right;
|
|
||||||
});
|
|
||||||
|
|
||||||
verticalBars.forEach(bar => {
|
|
||||||
if (!bar.enabled)
|
|
||||||
return;
|
|
||||||
SettingsData.updateBarConfig(bar.id, {
|
|
||||||
enabled: false
|
|
||||||
});
|
|
||||||
Qt.callLater(() => SettingsData.updateBarConfig(bar.id, {
|
|
||||||
enabled: true
|
|
||||||
}));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: edgeSpacingDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 4
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
spacing: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: exclusiveZoneDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 0
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
bottomGap: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: sizeDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 4
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
innerPadding: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: popupGapsManualDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 4
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
popupGapsManual: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: gothCornerRadiusDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 12
|
|
||||||
onTriggered: SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
gothCornerRadiusValue: pendingValue
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: borderOpacityDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1.0
|
|
||||||
onTriggered: SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
borderOpacity: pendingValue
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: borderThicknessDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1
|
|
||||||
onTriggered: SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
borderThickness: pendingValue
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: widgetOutlineOpacityDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1.0
|
|
||||||
onTriggered: SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
widgetOutlineOpacity: pendingValue
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: widgetOutlineThicknessDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1
|
|
||||||
onTriggered: SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
widgetOutlineThickness: pendingValue
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: barTransparencyDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1.0
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
transparency: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: widgetTransparencyDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1.0
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
widgetTransparency: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: fontScaleDebounce
|
|
||||||
interval: 100
|
|
||||||
repeat: false
|
|
||||||
property real pendingValue: 1.0
|
|
||||||
onTriggered: {
|
|
||||||
SettingsData.updateBarConfig(selectedBarId, {
|
|
||||||
fontScale: pendingValue
|
|
||||||
});
|
|
||||||
notifyHorizontalBarChange();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function notifyHorizontalBarChange() {
|
function notifyHorizontalBarChange() {
|
||||||
if (selectedBarIsVertical)
|
|
||||||
return;
|
|
||||||
horizontalBarChangeDebounce.restart();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function createNewBar() {
|
function createNewBar() {
|
||||||
@@ -917,9 +750,11 @@ Item {
|
|||||||
minimum: 0
|
minimum: 0
|
||||||
maximum: 32
|
maximum: 32
|
||||||
defaultValue: 4
|
defaultValue: 4
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
edgeSpacingDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
edgeSpacingDebounce.restart();
|
spacing: finalValue
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -937,9 +772,11 @@ Item {
|
|||||||
minimum: -50
|
minimum: -50
|
||||||
maximum: 50
|
maximum: 50
|
||||||
defaultValue: 0
|
defaultValue: 0
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
exclusiveZoneDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
exclusiveZoneDebounce.restart();
|
bottomGap: finalValue
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -957,9 +794,11 @@ Item {
|
|||||||
minimum: -8
|
minimum: -8
|
||||||
maximum: 24
|
maximum: 24
|
||||||
defaultValue: 4
|
defaultValue: 4
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
sizeDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
sizeDebounce.restart();
|
innerPadding: finalValue
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -970,6 +809,31 @@ Item {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SettingsSliderRow {
|
||||||
|
id: widgetPaddingSlider
|
||||||
|
text: I18n.tr("Widget Padding Base")
|
||||||
|
description: I18n.tr("Material 3 Expressive padding")
|
||||||
|
value: selectedBarConfig?.widgetPadding ?? 12
|
||||||
|
minimum: 0
|
||||||
|
maximum: 32
|
||||||
|
unit: "px"
|
||||||
|
defaultValue: 12
|
||||||
|
opacity: (selectedBarConfig?.removeWidgetPadding ?? false) ? 0.5 : 1.0
|
||||||
|
enabled: !(selectedBarConfig?.removeWidgetPadding ?? false)
|
||||||
|
onSliderValueChanged: newValue => {
|
||||||
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
|
widgetPadding: newValue
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
Binding {
|
||||||
|
target: widgetPaddingSlider
|
||||||
|
property: "value"
|
||||||
|
value: selectedBarConfig?.widgetPadding ?? 12
|
||||||
|
restoreMode: Binding.RestoreBinding
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: 1
|
height: 1
|
||||||
@@ -1009,9 +873,11 @@ Item {
|
|||||||
minimum: 0
|
minimum: 0
|
||||||
maximum: 50
|
maximum: 50
|
||||||
defaultValue: 4
|
defaultValue: 4
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
popupGapsManualDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
popupGapsManualDebounce.restart();
|
popupGapsManual: finalValue
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1048,6 +914,30 @@ Item {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SettingsToggleRow {
|
||||||
|
text: I18n.tr("Maximize Widget Icons")
|
||||||
|
checked: selectedBarConfig?.maximizeWidgetIcons ?? false
|
||||||
|
onToggled: checked => SettingsData.updateBarConfig(selectedBarId, {
|
||||||
|
maximizeWidgetIcons: checked
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
SettingsToggleRow {
|
||||||
|
text: I18n.tr("Maximize Widget Text")
|
||||||
|
checked: selectedBarConfig?.maximizeWidgetText ?? false
|
||||||
|
onToggled: checked => SettingsData.updateBarConfig(selectedBarId, {
|
||||||
|
maximizeWidgetText: checked
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
SettingsToggleRow {
|
||||||
|
text: I18n.tr("Remove Widget Padding")
|
||||||
|
checked: selectedBarConfig?.removeWidgetPadding ?? false
|
||||||
|
onToggled: checked => SettingsData.updateBarConfig(selectedBarId, {
|
||||||
|
removeWidgetPadding: checked
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: 1
|
height: 1
|
||||||
@@ -1086,9 +976,10 @@ Item {
|
|||||||
minimum: 0
|
minimum: 0
|
||||||
maximum: 64
|
maximum: 64
|
||||||
defaultValue: 12
|
defaultValue: 12
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
gothCornerRadiusDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
gothCornerRadiusDebounce.restart();
|
gothCornerRadiusValue: finalValue
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1282,9 +1173,10 @@ Item {
|
|||||||
maximum: 100
|
maximum: 100
|
||||||
unit: "%"
|
unit: "%"
|
||||||
defaultValue: 100
|
defaultValue: 100
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
borderOpacityDebounce.pendingValue = newValue / 100;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
borderOpacityDebounce.restart();
|
borderOpacity: finalValue / 100
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1303,9 +1195,10 @@ Item {
|
|||||||
maximum: 10
|
maximum: 10
|
||||||
unit: "px"
|
unit: "px"
|
||||||
defaultValue: 1
|
defaultValue: 1
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
borderThicknessDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
borderThicknessDebounce.restart();
|
borderThickness: finalValue
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1370,9 +1263,10 @@ Item {
|
|||||||
maximum: 100
|
maximum: 100
|
||||||
unit: "%"
|
unit: "%"
|
||||||
defaultValue: 100
|
defaultValue: 100
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
widgetOutlineOpacityDebounce.pendingValue = newValue / 100;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
widgetOutlineOpacityDebounce.restart();
|
widgetOutlineOpacity: finalValue / 100
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1391,9 +1285,10 @@ Item {
|
|||||||
maximum: 10
|
maximum: 10
|
||||||
unit: "px"
|
unit: "px"
|
||||||
defaultValue: 1
|
defaultValue: 1
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
widgetOutlineThicknessDebounce.pendingValue = newValue;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
widgetOutlineThicknessDebounce.restart();
|
widgetOutlineThickness: finalValue
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1419,9 +1314,11 @@ Item {
|
|||||||
maximum: 100
|
maximum: 100
|
||||||
unit: "%"
|
unit: "%"
|
||||||
defaultValue: 100
|
defaultValue: 100
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
barTransparencyDebounce.pendingValue = newValue / 100;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
barTransparencyDebounce.restart();
|
transparency: finalValue / 100
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1440,9 +1337,11 @@ Item {
|
|||||||
maximum: 100
|
maximum: 100
|
||||||
unit: "%"
|
unit: "%"
|
||||||
defaultValue: 100
|
defaultValue: 100
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
widgetTransparencyDebounce.pendingValue = newValue / 100;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
widgetTransparencyDebounce.restart();
|
widgetTransparency: finalValue / 100
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1465,9 +1364,11 @@ Item {
|
|||||||
value: Math.round((selectedBarConfig?.fontScale ?? 1.0) * 100)
|
value: Math.round((selectedBarConfig?.fontScale ?? 1.0) * 100)
|
||||||
unit: "%"
|
unit: "%"
|
||||||
defaultValue: 100
|
defaultValue: 100
|
||||||
onSliderValueChanged: newValue => {
|
onSliderDragFinished: finalValue => {
|
||||||
fontScaleDebounce.pendingValue = newValue / 100;
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
fontScaleDebounce.restart();
|
fontScale: finalValue / 100
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
}
|
}
|
||||||
|
|
||||||
Binding {
|
Binding {
|
||||||
@@ -1477,6 +1378,32 @@ Item {
|
|||||||
restoreMode: Binding.RestoreBinding
|
restoreMode: Binding.RestoreBinding
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SettingsSliderCard {
|
||||||
|
id: iconScaleSliderCard
|
||||||
|
iconName: "interests"
|
||||||
|
title: I18n.tr("Icon Scale")
|
||||||
|
description: I18n.tr("Scale DankBar icon sizes independently")
|
||||||
|
visible: selectedBarConfig?.enabled
|
||||||
|
minimum: 50
|
||||||
|
maximum: 200
|
||||||
|
value: Math.round((selectedBarConfig?.iconScale ?? 1.0) * 100)
|
||||||
|
unit: "%"
|
||||||
|
defaultValue: 100
|
||||||
|
onSliderDragFinished: finalValue => {
|
||||||
|
SettingsData.updateBarConfig(selectedBarId, {
|
||||||
|
iconScale: finalValue / 100
|
||||||
|
});
|
||||||
|
notifyHorizontalBarChange();
|
||||||
|
}
|
||||||
|
|
||||||
|
Binding {
|
||||||
|
target: iconScaleSliderCard
|
||||||
|
property: "value"
|
||||||
|
value: Math.round((selectedBarConfig?.iconScale ?? 1.0) * 100)
|
||||||
|
restoreMode: Binding.RestoreBinding
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ StyledRect {
|
|||||||
property int defaultValue: -1
|
property int defaultValue: -1
|
||||||
|
|
||||||
signal sliderValueChanged(int newValue)
|
signal sliderValueChanged(int newValue)
|
||||||
|
signal sliderDragFinished(int finalValue)
|
||||||
width: parent?.width ?? 0
|
width: parent?.width ?? 0
|
||||||
height: Theme.spacingL * 2 + contentColumn.height
|
height: Theme.spacingL * 2 + contentColumn.height
|
||||||
radius: Theme.cornerRadius
|
radius: Theme.cornerRadius
|
||||||
@@ -89,6 +89,7 @@ StyledRect {
|
|||||||
onClicked: {
|
onClicked: {
|
||||||
slider.value = root.defaultValue;
|
slider.value = root.defaultValue;
|
||||||
root.sliderValueChanged(root.defaultValue);
|
root.sliderValueChanged(root.defaultValue);
|
||||||
|
root.sliderDragFinished(root.defaultValue);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -101,6 +102,7 @@ StyledRect {
|
|||||||
wheelEnabled: false
|
wheelEnabled: false
|
||||||
thumbOutlineColor: Theme.surfaceContainerHigh
|
thumbOutlineColor: Theme.surfaceContainerHigh
|
||||||
onSliderValueChanged: newValue => root.sliderValueChanged(newValue)
|
onSliderValueChanged: newValue => root.sliderValueChanged(newValue)
|
||||||
|
onSliderDragFinished: finalValue => root.sliderDragFinished(finalValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ Item {
|
|||||||
property int defaultValue: -1
|
property int defaultValue: -1
|
||||||
|
|
||||||
signal sliderValueChanged(int newValue)
|
signal sliderValueChanged(int newValue)
|
||||||
|
signal sliderDragFinished(int finalValue)
|
||||||
width: parent?.width ?? 0
|
width: parent?.width ?? 0
|
||||||
height: headerRow.height + Theme.spacingXS + slider.height
|
height: headerRow.height + Theme.spacingXS + slider.height
|
||||||
|
|
||||||
@@ -128,6 +128,7 @@ Item {
|
|||||||
onClicked: {
|
onClicked: {
|
||||||
slider.value = root.defaultValue;
|
slider.value = root.defaultValue;
|
||||||
root.sliderValueChanged(root.defaultValue);
|
root.sliderValueChanged(root.defaultValue);
|
||||||
|
root.sliderDragFinished(root.defaultValue);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -141,6 +142,7 @@ Item {
|
|||||||
wheelEnabled: false
|
wheelEnabled: false
|
||||||
thumbOutlineColor: Theme.surfaceContainerHigh
|
thumbOutlineColor: Theme.surfaceContainerHigh
|
||||||
onSliderValueChanged: newValue => root.sliderValueChanged(newValue)
|
onSliderValueChanged: newValue => root.sliderValueChanged(newValue)
|
||||||
|
onSliderDragFinished: finalValue => root.sliderDragFinished(finalValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user