diff options
Diffstat (limited to 'modules/bar/popouts/ActiveWindow.qml')
| -rw-r--r-- | modules/bar/popouts/ActiveWindow.qml | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/modules/bar/popouts/ActiveWindow.qml b/modules/bar/popouts/ActiveWindow.qml index 06ad52c..d9e9b9e 100644 --- a/modules/bar/popouts/ActiveWindow.qml +++ b/modules/bar/popouts/ActiveWindow.qml @@ -1,9 +1,8 @@ - - import "root:/widgets" import "root:/services" import "root:/utils" import "root:/config" +import Quickshell.Widgets import Quickshell.Wayland import QtQuick @@ -17,17 +16,35 @@ Item { id: child anchors.centerIn: parent + spacing: Appearance.spacing.normal StyledText { text: Hyprland.activeClient?.title ?? "" + + elide: Text.ElideRight + width: preview.implicitWidth } StyledText { text: Hyprland.activeClient?.wmClass ?? "" + + elide: Text.ElideRight + width: preview.implicitWidth } - ScreencopyView { - + ClippingWrapperRectangle { + color: "transparent" + radius: Appearance.rounding.small + + ScreencopyView { + id: preview + + captureSource: ToplevelManager.toplevels.values.find(t => t.title === Hyprland.activeClient?.title) ?? null + live: true + + constraintSize.width: BarConfig.sizes.windowPreviewSize + constraintSize.height: BarConfig.sizes.windowPreviewSize + } } } } |