mirror of
https://github.com/johrpan/musicus.git
synced 2025-10-26 11:47:25 +01:00
Improve player bar layout
This commit is contained in:
parent
7110401f61
commit
f16a27e343
2 changed files with 78 additions and 28 deletions
|
|
@ -1,3 +1,11 @@
|
||||||
|
.playerbar .title {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.playerbar .subtitle {
|
||||||
|
font-size: smaller;
|
||||||
|
}
|
||||||
|
|
||||||
.searchbar .searchtag {
|
.searchbar .searchtag {
|
||||||
background-color: alpha(currentColor, 0.1);
|
background-color: alpha(currentColor, 0.1);
|
||||||
border-radius: 100px;
|
border-radius: 100px;
|
||||||
|
|
|
||||||
|
|
@ -24,47 +24,89 @@ template $MusicusWindow : Adw.ApplicationWindow {
|
||||||
transition-type: slide_up;
|
transition-type: slide_up;
|
||||||
|
|
||||||
Gtk.Box {
|
Gtk.Box {
|
||||||
|
styles ["playerbar"]
|
||||||
|
orientation: vertical;
|
||||||
margin-start: 6;
|
margin-start: 6;
|
||||||
margin-end: 6;
|
margin-end: 6;
|
||||||
margin-top: 6;
|
margin-top: 12;
|
||||||
margin-bottom: 6;
|
margin-bottom: 12;
|
||||||
spacing: 6;
|
spacing: 6;
|
||||||
|
|
||||||
Gtk.Button play_button {
|
Gtk.Box {
|
||||||
styles ["circular"]
|
spacing: 6;
|
||||||
valign: center;
|
|
||||||
icon-name: "media-playback-start-symbolic";
|
Gtk.Box {
|
||||||
|
valign: center;
|
||||||
|
hexpand: true;
|
||||||
|
margin-start: 10;
|
||||||
|
orientation: vertical;
|
||||||
|
|
||||||
|
Gtk.Label title_label {
|
||||||
|
styles ["title"]
|
||||||
|
halign: start;
|
||||||
|
label: _("Title");
|
||||||
|
ellipsize: end;
|
||||||
|
}
|
||||||
|
|
||||||
|
Gtk.Label subtitle_label {
|
||||||
|
styles ["subtitle", "dim-label"]
|
||||||
|
halign: start;
|
||||||
|
label: _("Subtitle");
|
||||||
|
ellipsize: end;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Gtk.Button back_button {
|
||||||
|
styles ["circular", "flat"]
|
||||||
|
valign: center;
|
||||||
|
icon-name: "media-skip-backward-symbolic";
|
||||||
|
}
|
||||||
|
|
||||||
|
Gtk.ToggleButton playlist_button {
|
||||||
|
styles ["flat", "circular"]
|
||||||
|
valign: center;
|
||||||
|
icon-name: "playlist-symbolic";
|
||||||
|
toggled => $show_playlist() swapped;
|
||||||
|
}
|
||||||
|
|
||||||
|
Gtk.Button forward_button {
|
||||||
|
styles ["circular", "flat"]
|
||||||
|
valign: center;
|
||||||
|
icon-name: "media-skip-forward-symbolic";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Gtk.Box {
|
Gtk.Box {
|
||||||
hexpand: true;
|
spacing: 6;
|
||||||
valign: center;
|
|
||||||
orientation: vertical;
|
|
||||||
|
|
||||||
Gtk.Label title_label {
|
Gtk.Button play_button {
|
||||||
styles ["caption-heading"]
|
styles ["circular", "flat"]
|
||||||
halign: start;
|
valign: center;
|
||||||
label: _("Title");
|
icon-name: "media-playback-start-symbolic";
|
||||||
}
|
}
|
||||||
|
|
||||||
Gtk.Label subtitle_label {
|
Gtk.Label current_time_label {
|
||||||
styles ["caption"]
|
styles ["caption", "numeric"]
|
||||||
halign: start;
|
valign: center;
|
||||||
label: _("Subtitle");
|
label: "00:00";
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
Gtk.Label {
|
Gtk.Scale slider {
|
||||||
styles ["caption", "numeric"]
|
valign: center;
|
||||||
valign: center;
|
hexpand: true;
|
||||||
label: "00:00 / 01:00";
|
adjustment: Gtk.Adjustment {
|
||||||
}
|
lower: 0;
|
||||||
|
upper: 1;
|
||||||
|
value: 0.2;
|
||||||
|
step-increment: 0.01;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
Gtk.ToggleButton playlist_button {
|
Gtk.Label remaining_time_label {
|
||||||
styles ["flat"]
|
styles ["caption", "numeric"]
|
||||||
valign: center;
|
valign: center;
|
||||||
icon-name: "playlist-symbolic";
|
label: "01:00";
|
||||||
toggled => $show_playlist() swapped;
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue