move titles to individual pages
This commit is contained in:
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template ConfirmPage : Box {
|
||||
name: _("Confirmation");
|
||||
orientation: vertical;
|
||||
spacing: 18;
|
||||
|
||||
Label {
|
||||
label: _("Confirmation");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
valign: end;
|
||||
orientation: vertical;
|
||||
|
||||
@@ -2,11 +2,17 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template DiskPage : Box {
|
||||
name: _("Disk Selection");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
vexpand:true;
|
||||
|
||||
Label {
|
||||
label: _("Disk Selection");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
vexpand:true;
|
||||
|
||||
|
||||
@@ -1,9 +1,15 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template DonePage : Box {
|
||||
name: _("Installation Complete");
|
||||
orientation: vertical;
|
||||
|
||||
Label {
|
||||
label: _("Installation Complete");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
halign: center;
|
||||
orientation: vertical;
|
||||
|
||||
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template EncryptPage : Box {
|
||||
name: _("Disk Encryption");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("Disk Encryption");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
orientation: vertical;
|
||||
|
||||
|
||||
@@ -1,10 +1,16 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template FailedPage : Box {
|
||||
name: _("Installation Failed");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("Installation Failed");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
overflow: hidden;
|
||||
|
||||
|
||||
@@ -1,10 +1,16 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template InstallPage : Box {
|
||||
name: _("Installing");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("Installing");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Stack stack {
|
||||
vexpand: true;
|
||||
transition-type: crossfade;
|
||||
|
||||
@@ -1,15 +1,21 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template InternetPage : Box {
|
||||
name: _("Internet Connection Check");
|
||||
orientation: vertical;
|
||||
margin-top: 12;
|
||||
spacing: 18;
|
||||
|
||||
Label {
|
||||
label: _("Internet Connection Check");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Label {
|
||||
label:_("No connection.");
|
||||
justify: center;
|
||||
styles ["title-4"]
|
||||
styles ["heading"]
|
||||
}
|
||||
|
||||
Button {
|
||||
|
||||
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template KeyboardLayoutPage : Box {
|
||||
name: _("Keyboard Layout Selection");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("Keyboard Layout Selection");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Entry {
|
||||
focusable: true;
|
||||
valign: start;
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template LanguagePage : Box {
|
||||
name: "";
|
||||
|
||||
Stack stack {
|
||||
vhomogeneous: false;
|
||||
transition-type: crossfade;
|
||||
|
||||
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template LocalePage : Stack {
|
||||
name: _("Adapt to Location");
|
||||
vhomogeneous: false;
|
||||
transition-type: crossfade;
|
||||
|
||||
Label {
|
||||
label: _("Adapt to Location");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
StackPage {
|
||||
name: "overview";
|
||||
child:
|
||||
|
||||
@@ -1,10 +1,16 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template RestartPage : Box {
|
||||
name: _("Restarting");
|
||||
orientation: vertical;
|
||||
spacing: 18;
|
||||
|
||||
Label {
|
||||
label: _("Restarting");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Spinner spinner {
|
||||
valign: center;
|
||||
margin-top: 18;
|
||||
|
||||
@@ -1,10 +1,16 @@
|
||||
using Gtk 4.0;
|
||||
|
||||
template SoftwarePage : Box {
|
||||
name: _("Additional Software");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("Additional Software");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Box {
|
||||
overflow: hidden;
|
||||
styles ["card", "scrollable-container"]
|
||||
|
||||
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template UserPage : Box {
|
||||
name: _("User Account");
|
||||
orientation: vertical;
|
||||
spacing: 12;
|
||||
|
||||
Label {
|
||||
label: _("User Account");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
ListBox {
|
||||
selection-mode: none;
|
||||
styles ["boxed-list"]
|
||||
|
||||
@@ -2,10 +2,16 @@ using Gtk 4.0;
|
||||
using Adw 1;
|
||||
|
||||
template WelcomePage : Box {
|
||||
name: _("Welcome");
|
||||
orientation: vertical;
|
||||
spacing: 30;
|
||||
|
||||
Label {
|
||||
label: _("Welcome");
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Adw.Clamp {
|
||||
margin-top: 18;
|
||||
maximum-size: 280;
|
||||
|
||||
@@ -11,12 +11,6 @@ template PageWrapper : Box {
|
||||
spacing: 12;
|
||||
styles ["clamped"]
|
||||
|
||||
Label title {
|
||||
justify: center;
|
||||
wrap: true;
|
||||
styles ["title-4"]
|
||||
}
|
||||
|
||||
Adw.Bin content {
|
||||
hexpand: true;
|
||||
}
|
||||
|
||||
@@ -49,17 +49,11 @@ class LanguageRow(Adw.ActionRow):
|
||||
class PageWrapper(Gtk.Box):
|
||||
__gtype_name__ = 'PageWrapper'
|
||||
|
||||
title = Gtk.Template.Child()
|
||||
content = Gtk.Template.Child()
|
||||
|
||||
def __init__(self, page, **kwargs):
|
||||
super().__init__(**kwargs)
|
||||
|
||||
page_name = page.get_name()
|
||||
if page_name and len(page_name) > 0:
|
||||
self.title.set_label(page_name)
|
||||
else:
|
||||
self.title.set_visible(False)
|
||||
self.content.set_child(page)
|
||||
|
||||
def get_page(self):
|
||||
|
||||
Reference in New Issue
Block a user