fix(qt): the player bar is one chrome band like the header, with its layout inset
The bottom band is now NowPlayingBar.qml's root: full width, flush on the window's bottom edge, surface-card @ 0.5 over the ambient field like the HeaderBar, opaque surface-card otherwise. The bar layout (PlayerBar / NowPlayingBarSmall) paints no background of its own and mounts inset by the gutter on its left, right and bottom, so the bar's ends still line up with the content pane's while nothing around it shows the raw field. Both rejected shapes are documented in place: an inset plate over the raw field (three sides of raw background, the only zone of the shell without chrome) and a frame slab behind an inset plate (a bar glued onto a slab). A future layout inherits the band and the gutter from the seam instead of carrying either. cc
This commit is contained in:
4 files changed
+54
-29
No files matched your search
@@ -69,7 +69,10 @@ import "../theme"
|
||||
|
||||
Rectangle {
|
||||
id: root
|
||||
color: ambientOn ? theme.surfaceCardA50 : theme.surfaceCard
|
||||
// No background of its own: the chrome band is NowPlayingBar.qml's root
|
||||
// (surface-card @ 0.5 under the ambient background, opaque surface-card
|
||||
// otherwise), full width behind this inset layout — see THE BAND there.
|
||||
color: "transparent"
|
||||
readonly property bool ambientOn: theme.ambientOn
|
||||
readonly property bool largeActive: QbzShell.npbMode === 3 && QbzShell.sidebarState === 0
|
||||
readonly property bool isClassic: QbzShell.npbMode === 1
|
||||
@@ -103,7 +106,7 @@ Rectangle {
|
||||
// are the SHARED theme token (QbzTheme.npbSideFrac) — the Small bar reads
|
||||
// the same one, so the two bars cannot drift apart.
|
||||
// `root.width` is the window width minus the two side gutters
|
||||
// (AppShell `npbGutter`): the bar is anchored left-to-right on the shell
|
||||
// (NowPlayingBar.qml `gutter`): the bar is anchored left-to-right on the shell
|
||||
// root, exactly like PlayerBar.slint reads its own root.
|
||||
property real sideFrac: theme.npbSideFrac(root.width)
|
||||
property real colSide: isClassic ? 0.324 : sideFrac
|
||||
|
||||
Reference in new issue
Block a user