diff options
Diffstat (limited to 'bar/ActiveWindow.qml')
| -rw-r--r-- | bar/ActiveWindow.qml | 40 |
1 files changed, 26 insertions, 14 deletions
diff --git a/bar/ActiveWindow.qml b/bar/ActiveWindow.qml index 25e87e2..915ee25 100644 --- a/bar/ActiveWindow.qml +++ b/bar/ActiveWindow.qml @@ -11,22 +11,34 @@ Item { property var toplevel: ToplevelManager.activeToplevel property var icon: Quickshell.iconPath(AppSearch.guessIcon(toplevel?.appId), "image-missing") - RowLayout { + Rectangle { + // use IRect + implicitWidth: rowLayout.implicitWidth + General.rectMargin * 2 + implicitHeight: rowLayout.implicitHeight + General.rectMargin * 2 anchors.centerIn: parent - spacing: Bar.resourceIconTextSpacing + color: Colors.alt + radius: Style.rounding.smaller - anchors.verticalCenter: parent.verticalCenter - IconImage { - source: root.icon - implicitWidth: Bar.appIconSize - implicitHeight: Bar.appIconSize - Layout.fillHeight: true - Layout.fillWidth: false - Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter - } - Text { - // TOOD: if not exist, use lazyloader or something hide this - text: root.toplevel?.title + RowLayout { + id: rowLayout + anchors.centerIn: parent + spacing: Bar.resourceIconTextSpacing + + anchors.verticalCenter: parent.verticalCenter + IconImage { + source: root.icon + implicitWidth: Bar.appIconSize + implicitHeight: Bar.appIconSize + Layout.fillHeight: true + Layout.fillWidth: false + Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter + } + Text { + // TOOD: if not exist, use lazyloader or something hide this + // TODO: use IText + font.pixelSize: General.fontSize + text: root.toplevel?.title + } } } } |
