matrix-client/resources/window.blp

168 lines
4.0 KiB
Plaintext

using Gtk 4.0;
using Adw 1;
menu main-menu {
}
template MainWindow : Adw.ApplicationWindow {
default-width: 1280;
default-height: 720;
title: _("Matrix Client");
content: Box {
orientation: vertical;
Adw.HeaderBar {
decoration-layout: "icon:minimize,maximize,close";
[end]
MenuButton {
icon-name: "open-menu-symbolic";
menu-model: main-menu;
tooltip-text: _("Main Menu");
}
}
Adw.Flap {
separator:Separator { };
[flap]
Stack {
vexpand: true;
transition-type: over_up;
Box roomlist {
orientation: vertical;
spacing: 7;
margin-top: 12;
margin-bottom: 12;
margin-start: 12;
margin-end: 12;
valign: start;
halign: center;
Button {
has-frame: false;
child: Box {
orientation: horizontal;
spacing: 8;
valign: start;
halign: start;
width-request: 160;
Adw.Avatar {
text: "Fluffychat";
show-initials: true;
size: 24;
}
Label {
label: "Placeholder";
ellipsize: end;
}
};
}
}
}
Box room {
orientation: vertical;
vexpand: true;
hexpand: true;
ScrolledWindow {
vexpand: true;
hexpand: true;
child: Box {
hexpand: true;
vexpand: true;
orientation: vertical;
spacing: 7;
ListBox {
hexpand: true;
selection-mode: single;
show-separators: false;
activate-on-single-click: true;
ListBoxRow {
activatable: false;
selectable: true;
hexpand: true;
child: Box {
hexpand: true;
orientation: horizontal;
spacing: 8;
valign: start;
halign: start;
margin-top: 12;
margin-bottom: 12;
margin-start: 12;
margin-end: 12;
Adw.Avatar {
text: "User A";
show-initials: true;
size: 24;
}
Label {
label: "Left";
ellipsize: end;
}
};
}
ListBoxRow {
activatable: false;
selectable: true;
hexpand: true;
child: Box {
hexpand: true;
orientation: horizontal;
spacing: 12;
valign: start;
halign: end;
margin-top: 12;
margin-bottom: 12;
margin-start: 12;
margin-end: 12;
Label {
label: "Right";
ellipsize: end;
}
Adw.Avatar {
text: "User B";
show-initials: true;
size: 24;
}
};
}
}
};
}
Box {
hexpand: true;
orientation: vertical;
margin-top: 12;
margin-bottom: 12;
margin-start: 12;
margin-end: 12;
spacing: 12;
Adw.EntryRow entry {
title: _("Enter a Message…");
input-purpose: free_form;
input-hints: spellcheck;
enable-emoji-completion: true;
show-apply-button: true;
}
}
}
}
};
}