Gradience/data/ui/window.blp

196 lines
4 KiB
Text
Raw Normal View History

using Gtk 4.0;
using Adw 1;
2022-08-19 19:14:05 +00:00
template GradienceMainWindow : Adw.ApplicationWindow {
title: _("Gradience");
2022-08-30 17:07:30 +00:00
default-width: 1000;
default-height: 700;
ShortcutController {
Shortcut {
trigger: "<primary>q";
action: "action(window.close)";
}
}
2022-08-10 15:05:47 +00:00
Adw.ToastOverlay toast_overlay {
Adw.Leaflet leaflet {
can-navigate-back: true;
can-unfold: false;
Gtk.Box main_view {
orientation: vertical;
Adw.HeaderBar titlebar {
centering-policy: strict;
Button apply-button {
styles ["suggested-action"]
label: _("Apply");
tooltip-text: _("Apply Preset");
2022-08-10 15:05:47 +00:00
action-name: "app.apply_color_scheme";
}
2022-11-23 15:01:45 +00:00
[start]
Button {
2022-11-23 15:01:45 +00:00
icon-name: "applications-science-symbolic";
tooltip-text: _("Show Preview Window");
visible: false;
2022-11-23 15:01:45 +00:00
}
2022-08-10 15:05:47 +00:00
[title]
Adw.ViewSwitcherTitle title {
stack: view_stack;
}
2022-08-12 09:30:51 +00:00
[end]
Gtk.MenuButton {
tooltip-text: _("Main Menu");
2022-08-12 09:30:51 +00:00
icon-name: "open-menu-symbolic";
menu-model: main-menu;
}
2022-08-10 15:05:47 +00:00
[end]
2022-09-13 21:01:29 +00:00
MenuButton presets-dropdown {
menu-model: presets-menu;
2022-08-10 15:05:47 +00:00
label: _("Presets");
tooltip-text: _("Presets Menu");
2022-08-10 15:05:47 +00:00
icon-name: "palette-symbolic";
}
2022-08-10 09:30:32 +00:00
2022-08-10 15:05:47 +00:00
[end]
Button save-preset-button {
action-name: "app.save_preset";
tooltip-text: _("Save Preset");
Adw.ButtonContent {
icon-name: "drive-symbolic";
2022-08-10 15:05:47 +00:00
}
}
2022-08-10 13:07:25 +00:00
2022-08-10 15:05:47 +00:00
[end]
MenuButton errors-button {
styles ["raised", "error"]
tooltip-text: _("CSS Errors");
2022-08-10 15:05:47 +00:00
icon-name: "dialog-warning-symbolic";
popover: errors-popover;
2022-08-10 10:17:28 +00:00
}
}
2022-08-10 15:05:47 +00:00
Gtk.Box {
orientation: vertical;
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
Adw.ViewStack view_stack {
vexpand: true;
hexpand: true;
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
Adw.ViewStackPage {
name: "colors";
2022-08-19 18:23:30 +00:00
title: _("Colors");
2022-08-10 15:05:47 +00:00
icon-name: "larger-brush-symbolic";
2022-09-13 21:01:29 +00:00
2022-08-10 15:05:47 +00:00
child: Adw.PreferencesPage content { };
}
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
Adw.ViewStackPage {
name: "monet";
2022-08-19 18:23:30 +00:00
title: _("Monet");
2022-08-10 15:05:47 +00:00
icon-name: "color-picker-symbolic";
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
child: Adw.PreferencesPage content_monet { };
}
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
Adw.ViewStackPage {
name: "plugins";
2022-08-19 18:23:30 +00:00
title: _("Advanced");
2022-08-10 15:05:47 +00:00
icon-name: "settings-symbolic";
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
child: Adw.PreferencesPage content_plugins { };
}
}
2022-08-10 10:17:28 +00:00
2022-08-10 15:05:47 +00:00
Adw.ViewSwitcherBar {
stack: view_stack;
reveal: bind title.title-visible;
}
}
}
}
2022-08-10 09:30:32 +00:00
}
}
2022-08-10 10:17:28 +00:00
menu main-menu {
2022-08-10 10:17:28 +00:00
section {
item {
2022-09-01 13:09:34 +00:00
label: _("Restore Applied Color Scheme");
action: "app.restore_color_scheme";
}
2022-08-10 10:17:28 +00:00
item {
label: _("Reset Applied Color Scheme");
action: "app.reset_color_scheme";
}
}
section {
item {
label: _("Preferences");
action: "app.preferences";
}
2022-08-10 10:17:28 +00:00
item {
label: _("About Gradience");
2022-08-10 10:17:28 +00:00
action: "app.about";
}
}
2022-07-18 19:20:02 +00:00
}
2022-09-13 21:01:29 +00:00
menu presets-menu {
section {
label: _("Built-In Presets");
2022-09-13 21:01:29 +00:00
item {
label: "Adwaita";
action: "app.load_preset";
target: "adwaita";
}
2022-09-13 21:01:29 +00:00
item {
label: "Adwaita Dark";
action: "app.load_preset";
target: "adwaita-dark";
}
2022-09-13 21:01:29 +00:00
item {
label: "Pretty Purple";
2022-09-13 21:01:29 +00:00
action: "app.load_preset";
target: "pretty-purple";
}
2022-09-13 21:01:29 +00:00
item {
label: _("Manage Presets");
2022-09-13 21:01:29 +00:00
action: "app.manage_presets";
}
}
}
2022-07-18 19:20:02 +00:00
Popover errors-popover {
ListBox errors-list {
selection-mode: none;
2022-07-18 19:20:02 +00:00
[placeholder]
Label {
margin-top: 6;
margin-bottom: 6;
margin-start: 12;
margin-end: 12;
halign: start;
styles ["dim-label"]
max-width-chars: 50;
wrap: true;
justify: left;
}
}
}
2022-11-23 15:01:45 +00:00