idk
This commit is contained in:
parent
b0faa05918
commit
89079b6de4
@ -1,3 +1,4 @@
|
|||||||
|
use gtk::pango::Language;
|
||||||
// Use libraries
|
// Use libraries
|
||||||
/// Use all gtk4 libraries (gtk4 -> gtk because cargo)
|
/// Use all gtk4 libraries (gtk4 -> gtk because cargo)
|
||||||
/// Use all libadwaita libraries (libadwaita -> adw because cargo)
|
/// Use all libadwaita libraries (libadwaita -> adw because cargo)
|
||||||
@ -22,7 +23,7 @@ pub fn language_page(content_stack: >k::Stack) {
|
|||||||
|
|
||||||
// the header text for the language page
|
// the header text for the language page
|
||||||
let language_header_text = gtk::Label::builder()
|
let language_header_text = gtk::Label::builder()
|
||||||
.label("language to PikaOS")
|
.label("Select a language")
|
||||||
.halign(gtk::Align::End)
|
.halign(gtk::Align::End)
|
||||||
.hexpand(true)
|
.hexpand(true)
|
||||||
.margin_top(15)
|
.margin_top(15)
|
||||||
@ -34,7 +35,7 @@ pub fn language_page(content_stack: >k::Stack) {
|
|||||||
|
|
||||||
// the header icon for the language icon
|
// the header icon for the language icon
|
||||||
let language_header_icon = gtk::Image::builder()
|
let language_header_icon = gtk::Image::builder()
|
||||||
.icon_name("debian-swirl")
|
.icon_name("locale")
|
||||||
.halign(gtk::Align::Start)
|
.halign(gtk::Align::Start)
|
||||||
.hexpand(true)
|
.hexpand(true)
|
||||||
.pixel_size(78)
|
.pixel_size(78)
|
||||||
@ -46,8 +47,7 @@ pub fn language_page(content_stack: >k::Stack) {
|
|||||||
|
|
||||||
// make language selection box for choosing installation or live media
|
// make language selection box for choosing installation or live media
|
||||||
let language_selection_box = gtk::Box::builder()
|
let language_selection_box = gtk::Box::builder()
|
||||||
.orientation(Orientation::Horizontal)
|
.orientation(Orientation::Vertical)
|
||||||
.spacing(200)
|
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
// / language_header_box appends
|
// / language_header_box appends
|
||||||
@ -61,11 +61,47 @@ pub fn language_page(content_stack: >k::Stack) {
|
|||||||
//// Add the language selection/page content box to language main box
|
//// Add the language selection/page content box to language main box
|
||||||
language_main_box.append(&language_selection_box);
|
language_main_box.append(&language_selection_box);
|
||||||
|
|
||||||
|
// text above language selection box
|
||||||
|
let language_selection_text = gtk::Label::builder()
|
||||||
|
.label("Please select a locale for the system to use")
|
||||||
|
.halign(gtk::Align::Center)
|
||||||
|
.hexpand(true)
|
||||||
|
.margin_top(15)
|
||||||
|
.margin_bottom(15)
|
||||||
|
.margin_start(15)
|
||||||
|
.margin_end(15)
|
||||||
|
.build();
|
||||||
|
language_selection_text.add_css_class("medium_sized_text");
|
||||||
|
|
||||||
|
let language_selection_expander_row = adw::ExpanderRow::builder()
|
||||||
|
.margin_top(15)
|
||||||
|
.margin_bottom(15)
|
||||||
|
.margin_start(15)
|
||||||
|
.margin_end(15)
|
||||||
|
.title("Locale")
|
||||||
|
.build();
|
||||||
|
|
||||||
|
let locales = ["en_US", "russian", "en_GB"];
|
||||||
|
let null_checkbutton = gtk::CheckButton::builder()
|
||||||
|
.label("No locale selected")
|
||||||
|
.build();
|
||||||
|
language_selection_expander_row.add_row(&null_checkbutton);
|
||||||
|
|
||||||
|
for locale in locales {
|
||||||
|
let locale_label = gtk::CheckButton::builder()
|
||||||
|
.label(locale)
|
||||||
|
.build();
|
||||||
|
locale_label.set_group(Some(&null_checkbutton));
|
||||||
|
language_selection_expander_row.add_row(&locale_label);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// / language_selection_box appends
|
// / language_selection_box appends
|
||||||
//// add live and install media button to language page selections
|
//// add text and and entry to language page selections
|
||||||
// language_selection_box.append(&live_media_button);
|
language_selection_box.append(&language_selection_text);
|
||||||
// language_selection_box.append(&install_media_button);
|
language_selection_box.append(&language_selection_expander_row);
|
||||||
|
|
||||||
// / language_header_box appends
|
// / language_header_box appends
|
||||||
//// Add the language page header text and icon
|
//// Add the language page header text and icon
|
||||||
|
Loading…
Reference in New Issue
Block a user