Icons: huge cleanup

This commit is contained in:
LemmyCook 2025-09-08 22:05:57 -04:00
parent ccdb4e0664
commit 1f8c55d581
53 changed files with 155 additions and 174 deletions

View file

@ -31,7 +31,7 @@ NBox {
}
NIcon {
text: Bootstrap.icons["album"]
text: "album"
font.pointSize: Style.fontSizeXXXL * 2.5 * scaling
color: Color.mPrimary
Layout.alignment: Qt.AlignHCenter
@ -89,7 +89,7 @@ NBox {
indicator: NIcon {
x: playerSelector.width - width
y: playerSelector.topPadding + (playerSelector.availableHeight - height) / 2
text: Bootstrap.icons["arrow_drop_down"]
text: "arrow_drop_down"
font.pointSize: Style.fontSizeXXL * scaling
color: Color.mOnSurface
horizontalAlignment: Text.AlignRight
@ -162,14 +162,14 @@ NBox {
anchors.fill: parent
anchors.margins: Style.marginXS * scaling
imagePath: MediaService.trackArtUrl
fallbackIcon: Bootstrap.icons["album"]
fallbackIcon: "album"
borderColor: Color.mOutline
borderWidth: Math.max(1, Style.borderS * scaling)
}
// Fallback icon when no album art available
NIcon {
text: Bootstrap.icons["album"]
icon: "album"
color: Color.mPrimary
font.pointSize: Style.fontSizeL * 12 * scaling
visible: !trackArt.visible
@ -307,7 +307,7 @@ NBox {
// Previous button
NIconButton {
icon: Bootstrap.icons["prev"]
icon: "skip-start"
tooltipText: "Previous Media"
visible: MediaService.canGoPrevious
onClicked: MediaService.canGoPrevious ? MediaService.previous() : {}
@ -315,7 +315,7 @@ NBox {
// Play/Pause button
NIconButton {
icon: MediaService.isPlaying ? Bootstrap.icons["pause"] : Bootstrap.icons["play"]
icon: MediaService.isPlaying ? "pause" : "play"
tooltipText: MediaService.isPlaying ? "Pause" : "Play"
visible: (MediaService.canPlay || MediaService.canPause)
onClicked: (MediaService.canPlay || MediaService.canPause) ? MediaService.playPause() : {}
@ -323,7 +323,7 @@ NBox {
// Next button
NIconButton {
icon: Bootstrap.icons["next"]
icon: "skip-end"
tooltipText: "Next media"
visible: MediaService.canGoNext
onClicked: MediaService.canGoNext ? MediaService.next() : {}

View file

@ -28,7 +28,7 @@ NBox {
}
// Performance
NIconButton {
icon: Bootstrap.icons["speedometer2"]
icon: "speedometer2"
tooltipText: "Set performance power profile."
enabled: hasPP
opacity: enabled ? Style.opacityFull : Style.opacityMedium
@ -42,7 +42,7 @@ NBox {
}
// Balanced
NIconButton {
icon: Bootstrap.icons["yin-yang"]
icon: "yin-yang"
tooltipText: "Set balanced power profile."
enabled: hasPP
opacity: enabled ? Style.opacityFull : Style.opacityMedium
@ -56,7 +56,7 @@ NBox {
}
// Eco
NIconButton {
icon: Bootstrap.icons["leaf"]
icon: "leaf"
tooltipText: "Set eco power profile."
enabled: hasPP
opacity: enabled ? Style.opacityFull : Style.opacityMedium

View file

@ -32,7 +32,7 @@ NBox {
width: Style.baseWidgetSize * 1.25 * scaling
height: Style.baseWidgetSize * 1.25 * scaling
imagePath: Settings.data.general.avatarImage
fallbackIcon: Bootstrap.icons["person"]
fallbackIcon: "person"
borderColor: Color.mPrimary
borderWidth: Math.max(1, Style.borderM * scaling)
}
@ -58,7 +58,7 @@ NBox {
Layout.fillWidth: true
}
NIconButton {
icon: Bootstrap.icons["gear"]
icon: "gear"
tooltipText: "Open settings."
onClicked: {
settingsPanel.requestedTab = SettingsPanel.Tab.General
@ -68,7 +68,7 @@ NBox {
NIconButton {
id: powerButton
icon: Bootstrap.icons["power"]
icon: "power"
tooltipText: "Power menu."
onClicked: {
powerPanel.open(screen)
@ -78,7 +78,7 @@ NBox {
NIconButton {
id: closeButton
icon: Bootstrap.icons["x-lg"]
icon: "x-lg"
tooltipText: "Close side panel."
onClicked: {
sidePanel.close()

View file

@ -24,7 +24,7 @@ NBox {
NCircleStat {
value: SystemStatService.cpuUsage
icon: Bootstrap.icons["speedometer2"]
icon: "speedometer2"
flat: true
contentScale: 0.8
width: 72 * scaling
@ -33,7 +33,7 @@ NBox {
NCircleStat {
value: SystemStatService.cpuTemp
suffix: "°C"
icon: Bootstrap.icons["fire"]
icon: "fire"
flat: true
contentScale: 0.8
width: 72 * scaling
@ -41,7 +41,7 @@ NBox {
}
NCircleStat {
value: SystemStatService.memPercent
icon: Bootstrap.icons["memory"]
icon: "memory"
flat: true
contentScale: 0.8
width: 72 * scaling
@ -49,7 +49,7 @@ NBox {
}
NCircleStat {
value: SystemStatService.diskPercent
icon: Bootstrap.icons["drive"]
icon: "hdd"
flat: true
contentScale: 0.8
width: 72 * scaling

View file

@ -25,7 +25,7 @@ NBox {
}
// Screen Recorder
NIconButton {
icon: Bootstrap.icons["camera-video"]
icon: "camera-video"
tooltipText: ScreenRecorderService.isRecording ? "Stop screen recording." : "Start screen recording."
colorBg: ScreenRecorderService.isRecording ? Color.mPrimary : Color.mSurfaceVariant
colorFg: ScreenRecorderService.isRecording ? Color.mOnPrimary : Color.mPrimary
@ -41,7 +41,7 @@ NBox {
// Idle Inhibitor
NIconButton {
icon: Bootstrap.icons["cup-hot"]
icon: "cup-hot"
tooltipText: IdleInhibitorService.isInhibited ? "Disable keep awake." : "Enable keep awake."
colorBg: IdleInhibitorService.isInhibited ? Color.mPrimary : Color.mSurfaceVariant
colorFg: IdleInhibitorService.isInhibited ? Color.mOnPrimary : Color.mPrimary
@ -53,7 +53,7 @@ NBox {
// Wallpaper
NIconButton {
visible: Settings.data.wallpaper.enabled
icon: Bootstrap.icons["image"]
icon: "image"
tooltipText: "Left click: Open wallpaper selector.\nRight click: Set random wallpaper."
onClicked: {
var settingsPanel = PanelService.getPanel("settingsPanel")

View file

@ -98,7 +98,7 @@ NBox {
color: Color.mOnSurface
}
NIcon {
text: LocationService.weatherSymbolFromCode(LocationService.data.weather.daily.weathercode[index])
icon: LocationService.weatherSymbolFromCode(LocationService.data.weather.daily.weathercode[index])
font.pointSize: Style.fontSizeXXL * scaling
color: Color.mPrimary
}