From f1f4fb1f2c035153b8eafd53689910cd4b301b25 Mon Sep 17 00:00:00 2001 From: ferreo Date: Sun, 17 Nov 2024 22:16:58 +0000 Subject: [PATCH] Update changelog for v1.0.0-101pika7; improve ActiveWindow icon retrieval and adjust image dimensions for better display --- .github/release-nest-v3 | 2 +- pikabar/debian/changelog | 2 +- .../share/pikabar/widgets/ActiveWindow.qml | 20 ++++++++++--------- 3 files changed, 13 insertions(+), 11 deletions(-) diff --git a/.github/release-nest-v3 b/.github/release-nest-v3 index 56a6051..d8263ee 100644 --- a/.github/release-nest-v3 +++ b/.github/release-nest-v3 @@ -1 +1 @@ -1 \ No newline at end of file +2 \ No newline at end of file diff --git a/pikabar/debian/changelog b/pikabar/debian/changelog index e8e8acf..9f205ef 100644 --- a/pikabar/debian/changelog +++ b/pikabar/debian/changelog @@ -1,4 +1,4 @@ -pikabar (1.0.0-101pika6) pika; urgency=medium +pikabar (1.0.0-101pika7) pika; urgency=medium * Font fixes and icon fixes diff --git a/pikabar/usr/share/pikabar/widgets/ActiveWindow.qml b/pikabar/usr/share/pikabar/widgets/ActiveWindow.qml index 34bd582..f1f819d 100644 --- a/pikabar/usr/share/pikabar/widgets/ActiveWindow.qml +++ b/pikabar/usr/share/pikabar/widgets/ActiveWindow.qml @@ -2,32 +2,34 @@ import QtQuick import QtQuick.Layouts import Quickshell import Quickshell.Wayland +import Quickshell.Widgets import "root:/" Row { spacing: 10 function getIcon() { - var icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId.toLowerCase()) + var icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId.toLowerCase()); if (!icon) { - icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId) + icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId); } if (!icon) { - icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title) + icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title); } if (!icon) { - icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title.toLowerCase()) + icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title.toLowerCase()); } if (!icon) { - icon = Quickshell.iconPath("application-x-executable") + icon = Quickshell.iconPath("application-x-executable"); } - return icon + + return icon; } - SimpleImage { + IconImage { height: 42 Layout.fillHeight: true - implicitWidth: parent.height / 2 + implicitWidth: parent.height * 0.6 source: ToplevelManager.activeToplevel ? getIcon() : "" } @@ -43,4 +45,4 @@ Row { horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter } -} \ No newline at end of file +}