wip
This commit is contained in:
parent
32edcff102
commit
0296117901
110 changed files with 9713 additions and 5 deletions
75
modules/bar/popouts/ActiveWindow.qml
Normal file
75
modules/bar/popouts/ActiveWindow.qml
Normal file
|
@ -0,0 +1,75 @@
|
|||
import "root:/widgets"
|
||||
import "root:/services"
|
||||
import "root:/utils"
|
||||
import "root:/config"
|
||||
import Quickshell.Widgets
|
||||
import Quickshell.Wayland
|
||||
import QtQuick
|
||||
|
||||
Item {
|
||||
id: root
|
||||
|
||||
implicitWidth: Hyprland.activeClient ? child.implicitWidth : -Appearance.padding.large * 2
|
||||
implicitHeight: child.implicitHeight
|
||||
|
||||
Column {
|
||||
id: child
|
||||
|
||||
anchors.centerIn: parent
|
||||
spacing: Appearance.spacing.normal
|
||||
|
||||
Row {
|
||||
id: detailsRow
|
||||
|
||||
spacing: Appearance.spacing.normal
|
||||
|
||||
IconImage {
|
||||
id: icon
|
||||
|
||||
implicitSize: details.implicitHeight
|
||||
source: Icons.getAppIcon(Hyprland.activeClient?.wmClass ?? "", "image-missing")
|
||||
}
|
||||
|
||||
Column {
|
||||
id: details
|
||||
|
||||
StyledText {
|
||||
text: Hyprland.activeClient?.title ?? ""
|
||||
font.pointSize: Appearance.font.size.normal
|
||||
|
||||
elide: Text.ElideRight
|
||||
width: preview.implicitWidth - icon.implicitWidth - detailsRow.spacing
|
||||
}
|
||||
|
||||
StyledText {
|
||||
text: Hyprland.activeClient?.wmClass ?? ""
|
||||
color: Colours.palette.m3onSurfaceVariant
|
||||
|
||||
elide: Text.ElideRight
|
||||
width: preview.implicitWidth - icon.implicitWidth - detailsRow.spacing
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ClippingWrapperRectangle {
|
||||
color: "transparent"
|
||||
radius: Appearance.rounding.small
|
||||
|
||||
ScreencopyView {
|
||||
id: preview
|
||||
|
||||
captureSource: ToplevelManager.toplevels.values.find(t => t.title === Hyprland.activeClient?.title) ?? null
|
||||
live: visible
|
||||
|
||||
constraintSize.width: BarConfig.sizes.windowPreviewSize
|
||||
constraintSize.height: BarConfig.sizes.windowPreviewSize
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
component Anim: NumberAnimation {
|
||||
duration: Appearance.anim.durations.normal
|
||||
easing.type: Easing.BezierSpline
|
||||
easing.bezierCurve: Appearance.anim.curves.emphasized
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue