Migrate window.ui to window.blp

This commit is contained in:
Florian RICHER 2023-10-18 18:56:01 +02:00
parent d9a1433cc2
commit a5bd793693

View file

@ -1,47 +1,44 @@
using Gtk 4.0;
using Adw 1;
template TutorialWindow : Adw.ApplicationWindow {
title: _("My Application");
default-width: 800;
default-height: 600;
template $TutorialWindow : Adw.ApplicationWindow {
default-width: 600;
default-height: 300;
Adw.ToolbarView {
content: Adw.ToolbarView {
[top]
Adw.HeaderBar header_bar {
[end]
Gtk.MenuButton {
menu-model: primary_menu;
primary: True;
icon: "open-menu-symbolic";
primary: true;
icon-name: "open-menu-symbolic";
tooltip-text: _("Menu");
}
}
Gtk.Label {
content: Gtk.Label label {
styles ["title-1"]
label: "Hello, World!";
}
}
};
};
}
menu primary_menu {
section {
item {
label: _("Preferences");
label: _("_Preferences");
action: "app.preferences";
}
item {
label: _("Keyboard Shortcuts");
label: _("_Keyboard Shortcuts");
action: "win.show-help-overlay";
}
item {
label: _("About");
label: _("_About Tutorial");
action: "app.about";
}
}