Hyprland: - Windows round at 8px, concentric with the porthole's 18px corners at the 10px gap, instead of square corners inside a rounded opening. - Group tabs are solid hull slabs; the titles used to float over the wallpaper. The current tab is lifted a step with its title in the light. - Motion rewritten to glide and settle: no overshoot curve, gentler popin, workspaces slide-fade a short way instead of sweeping the whole screen, and layers only fade so they never stack on quickshell's own slides. Quickshell: - Album art in the bar and the media popout is square in a hairline frame, not masked to a leaning chamfered shape; the accent slab under the popout art is gone, and a track change dips the title instead of tilting the art. - The bar's equaliser is a five-hairline signal meter that rests as dots. - Segment meters (system, battery, OSD) are 4px rows instead of 10-12px blocks; the toast fuse is a hairline; the clock's accent slab is a neutral divider. - No hover pops: rail icons, tray icons, media transport buttons and P5Button no longer scale up or lunge sideways; the icon bump is reduced. Terminal: ANSI bright black drops to #464d44. TUIs use it as a panel fill, and at the outline grey it read as a flat light slab. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
125 lines
3.9 KiB
QML
125 lines
3.9 KiB
QML
import QtQuick
|
|
import Quickshell
|
|
import "root:/config"
|
|
import "root:/components"
|
|
import "root:/popouts"
|
|
import "root:/services"
|
|
|
|
// Centre-stage clock. Hovering drops the calendar; clicking drops the
|
|
// dashboard, which carries the calendar too.
|
|
BarPill {
|
|
id: root
|
|
|
|
required property var screenRef
|
|
|
|
accent: Theme.accent
|
|
slash: true
|
|
padding: Theme.padS
|
|
implicitWidth: layout.implicitWidth + contentPad * 2
|
|
|
|
SystemClock {
|
|
id: clock
|
|
precision: SystemClock.Minutes
|
|
}
|
|
|
|
onClicked: Actions.toggleDashboard()
|
|
|
|
Row {
|
|
id: layout
|
|
anchors.centerIn: parent
|
|
spacing: Theme.padM
|
|
|
|
Column {
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
spacing: -1
|
|
|
|
Text {
|
|
text: Qt.formatDateTime(clock.date, "ddd").toUpperCase()
|
|
color: Theme.accent
|
|
font.family: Theme.fontMono
|
|
font.pixelSize: Theme.fsMicro
|
|
font.weight: Font.Bold
|
|
font.letterSpacing: 3
|
|
renderType: Text.NativeRendering
|
|
}
|
|
|
|
Text {
|
|
text: Qt.formatDateTime(clock.date, "dd MMM").toUpperCase()
|
|
color: Theme.subtext
|
|
font.family: Theme.fontMono
|
|
font.pixelSize: Theme.fsMicro
|
|
font.letterSpacing: 1
|
|
renderType: Text.NativeRendering
|
|
}
|
|
}
|
|
|
|
// A hairline between the date and the time.
|
|
Rectangle {
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
width: 1
|
|
height: 18
|
|
color: Theme.alpha(Theme.outline, 0.6)
|
|
}
|
|
|
|
// The display face's digits are not all the same width, so a clock sized to
|
|
// its own text changed width as the minutes rolled over — 11:11 is
|
|
// several px narrower than 08:48 — and shoved the rest of the bar
|
|
// around. Reserve the widest possible reading and centre inside it.
|
|
TextMetrics {
|
|
id: timeMetrics
|
|
text: "88:88"
|
|
font.family: Theme.fontDisplay
|
|
font.pixelSize: Theme.fsTitle
|
|
font.weight: Theme.weightDisplay
|
|
font.letterSpacing: 0.5
|
|
}
|
|
|
|
// Archivo Black reserves descender room the time never uses — "12:04"
|
|
// is all cap height — so centring the line box left the digits sitting
|
|
// above everything beside them. Centre the ink instead.
|
|
// `tightBoundingRect` is measured from the baseline, so the ink's top
|
|
// inside the line box is `ascent + ink.y`.
|
|
readonly property real timeInkOffset: {
|
|
const ink = timeMetrics.tightBoundingRect;
|
|
if (ink.height <= 0) return 0;
|
|
const inkCentre = timeFont.ascent + ink.y + ink.height / 2;
|
|
return Math.round(timeMetrics.boundingRect.height / 2 - inkCentre);
|
|
}
|
|
|
|
FontMetrics {
|
|
id: timeFont
|
|
font: timeMetrics.font
|
|
}
|
|
|
|
SplitText {
|
|
id: timeText
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
anchors.verticalCenterOffset: layout.timeInkOffset
|
|
width: timeMetrics.advanceWidth
|
|
text: Qt.formatDateTime(clock.date, "HH:mm")
|
|
pixelSize: Theme.fsTitle
|
|
horizontalAlignment: Text.AlignHCenter
|
|
}
|
|
|
|
}
|
|
|
|
// Glitch the time on the hour, because it should feel like something happened.
|
|
property int lastHour: -1
|
|
Connections {
|
|
target: clock
|
|
function onDateChanged() {
|
|
const h = clock.date.getHours();
|
|
if (root.lastHour !== -1 && h !== root.lastHour) timeText.glitch();
|
|
root.lastHour = h;
|
|
}
|
|
}
|
|
|
|
CalendarPopout {
|
|
id: calendar
|
|
anchorItem: root
|
|
// Not while the dashboard is down: it already shows the month.
|
|
triggerHovered: root.hovered && !Actions.dashboardOpen
|
|
clockDate: clock.date
|
|
}
|
|
}
|