Add keyboard layouts and timezones

pull/6/head
axtloss 2 years ago
parent 79d9d8d904
commit d15c590dca

@ -0,0 +1,24 @@
# keymap.py
#
# Copyright 2022 user
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
class keymap:
def __init__(self, layout, variant, backend_layout):
self.layout = layout
self.variant = variant
self.backend_layout = backend_layout

@ -0,0 +1,24 @@
# locale.py
#
# Copyright 2022 user
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
class locale:
def __init__(self, locales, region, location):
self.locales = locales
self.region = region
self.location = location

@ -0,0 +1,9 @@
pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), meson.project_name())
classesdir = join_paths(pkgdatadir, 'jade_gui/classes')
jade_gui_sources = [
'__init__.py',
'locale.py',
'keymap.py',
]
install_data(jade_gui_sources, install_dir: classesdir)

@ -25,42 +25,61 @@ from gettext import gettext as _
class KeyboardScreen(Adw.Bin):
__gtype_name__ = 'KeyboardScreen'
event_controller = Gtk.EventControllerKey.new()
#carousel = Gtk.Template.Child()
layout_event_controller = Gtk.EventControllerKey.new()
variant_event_controller = Gtk.EventControllerKey.new()
### Page and widgets for keyboard screen
# keyboard_page = Gtk.Template.Child()
keyboard_entry_search = Gtk.Template.Child()
keyboard_search = Gtk.Template.Child()
keyboard_carousel = Gtk.Template.Child()
list_keyboard_layouts = Gtk.Template.Child()
list_keyboard_variants = Gtk.Template.Child()
keyboard_layouts = Gtk.Template.Child()
keyboard_variants = Gtk.Template.Child()
layout_search = Gtk.Template.Child()
layout_entry_search = Gtk.Template.Child()
variant_search = Gtk.Template.Child()
variant_entry_search = Gtk.Template.Child()
def __init__(self, window, main_carousel, next_page, application, **kwargs):
super().__init__(**kwargs)
self.window = window
self.carousel = main_carousel
self.next_page = next_page
### Widgets for third page (keyboard layout)
self.keyboard_search.set_key_capture_widget(self)
self.list_keyboard_layouts.connect("row-selected", self.selected_layout)
self.list_keyboard_variants.connect("row-selected", self.selected_variant)
self.layout_event_controller.connect("key-released", self.search_layouts)
self.variant_event_controller.connect("key-released", self.search_variants)
self.layout_entry_search.add_controller(self.layout_event_controller)
self.variant_entry_search.add_controller(self.variant_event_controller)
def search_keyboards(self, *args):
pass
def search_layouts(self, *args):
terms = self.layout_entry_search.get_text()
self.list_keyboard_layouts.set_filter_func(self.filter_text, terms)
def search_variants(self, *args):
print("in variant")
terms = self.variant_entry_search.get_text()
self.list_keyboard_variants.set_filter_func(self.filter_text, terms)
def selected_layout(self, widget, row):
if row is not None:
if row is not None or row is not self.layout_entry_search:
self.keyboard_carousel.scroll_to(self.keyboard_variants, True)
else:
print("row is none!! layout")
def selected_variant(self, widget, row):
if row is not None:
if row is not None or row is not self.variant_entry_search:
print("variant selected")
self.carousel.scroll_to(self.next_page, True)
else:
print("row is none!! variant")
@staticmethod
def filter_text(row, terms=None):
try:
text = row.get_title()
text = text.lower() + row.get_subtitle().lower()
if terms.lower() in text:
return True
except:
print("exception")
return True
return False

@ -26,10 +26,8 @@ class TimezoneScreen(Adw.Bin):
__gtype_name__ = 'TimezoneScreen'
event_controller = Gtk.EventControllerKey.new()
#carousel = Gtk.Template.Child()
### Page and widgets on timezone screen
#timezone_page = Gtk.Template.Child()
list_timezones = Gtk.Template.Child()
timezone_entry_search = Gtk.Template.Child()
timezone_search = Gtk.Template.Child()
@ -40,29 +38,29 @@ class TimezoneScreen(Adw.Bin):
self.carousel = main_carousel
self.next_page = next_page
### Widgets for second page (timezone selection)
self.event_controller.connect("key-released", self.search_timezones)
self.timezone_entry_search.add_controller(self.event_controller)
self.timezone_search.set_key_capture_widget(self)
self.list_timezones.connect("row-selected", self.selected_timezone)
### ---------
def selected_timezone(self, widget, row):
if row is not None:
print(row)
if row is not None or row is not self.timezone_search:
print(row.get_title())
self.carousel.scroll_to(self.next_page, True)
else:
print("row is none!!")
def search_timezones(self, *args):
terms = self.entry_search.get_text()
terms = self.timezone_entry_search.get_text()
self.list_timezones.set_filter_func(self.filter_timezones, terms)
@staticmethod
def filter_timezones(row, terms=None):
try:
text = row.get_title()
text = text.lower() + row.get_subtitle().lower()
if terms.lower() in text:
return True
except:
return True
return False

File diff suppressed because it is too large Load Diff

@ -0,0 +1,270 @@
from jade_gui.classes.locale import locale
africa = [
locale(
region="Africa",
location="Abidjan",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Accra",
locales="en_GH.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Addis_Ababa",
locales="en_ET.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Algiers",
locales="ar_DZ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Asmara",
locales="en_ER.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Bamako",
locales="fr_ML.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Bangui",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Banjul",
locales="en_GM.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Bissau",
locales="pt_GW.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Blantyre",
locales="en_MW.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Brazzaville",
locales="fr_CD.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Bujumbura",
locales="fr_BI.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Cairo",
locales="ar_EG.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Casablanca",
locales="ar_MA.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Ceuta",
locales="es_ES.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Conakry",
locales="fr_GN.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Dakar",
locales="fr_SN.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Dar_es_Salaam",
locales="en_TZ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Djibouti",
locales="fr_DJ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Douala",
locales="fr_CM.UTF-8 UTF-8",
),
locale(
region="Africa",
location="El_Aaiun",
locales="ar_EH.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Freetown",
locales="en_SL.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Gaborone",
locales="en_BW.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Harare",
locales="en_ZW.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Johannesburg",
locales="en_ZA.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Juba",
locales="en_SS.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Kampala",
locales="en_UG.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Khartoum",
locales="",
),
locale(
region="Africa",
location="Kigali",
locales="en_RW.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Kinshasa",
locales="fr_CD.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Lagos",
locales="en_NG.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Libreville",
locales="fr_GA.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Lome",
locales="fr_TG.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Luanda",
locales="pt_AO.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Lubumbashi",
locales="fr_CD.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Lusaka",
locales="en_ZM.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Malabo",
locales="fr_GQ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Maputo",
locales="en_MZ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Maseru",
locales="en_LS.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Mbabane",
locales="en_SZ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Mogadishu",
locales="en_SO.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Monrovia",
locales="en_LR.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Nairobi",
locales="en_KE.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Ndjamena",
locales="fr_TD.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Niamey",
locales="fr_NE.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Nouakchott",
locales="ar_MR.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Ouagadougou",
locales="fr_BF.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Porto-Novo",
locales="fr_BJ.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Sao_Tome",
locales="pt_ST.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Timbuktu",
locales="fr_ML.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Tripoli",
locales="ar_LY.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Tunis",
locales="fr_TN.UTF-8 UTF-8",
),
locale(
region="Africa",
location="Windhoek",
locales="en_NA.UTF-8 UTF-8",
),
]

@ -0,0 +1,725 @@
from jade_gui.classes.locale import locale
america = [
locale(
region="America",
location="Adak",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Anchorage",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Antigua",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Araguaina",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Argentina",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Aruba",
locales="nl_NL.UTF-8 UTF-8",
),
locale(
region="America",
location="Asuncion",
locales="es_PY.UTF-8 UTF-8",
),
locale(
region="America",
location="Atikokan",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Atka",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Bahia",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Bahia_Banderas",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Barbados",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="America",
location="Belem",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Belize",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Blanc-Sablon",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Boa_Vista",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Bogota",
locales="es_CO.UTF-8 UTF-8",
),
locale(
region="America",
location="Boise",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Buenos_Aires",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Cambridge_Bay",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Campo_Grande",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Cancun",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Caracas",
locales="es_VE.UTF-8 UTF-8",
),
locale(
region="America",
location="Catamarca",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Cayenne",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="America",
location="Cayman",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="America",
location="Chicago",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Chihuahua",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Coral_Harbour",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Cordoba",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Costa_Rica",
locales="es_ES.UTF-8 UTF-8",
),
locale(
region="America",
location="Creston",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Cuiaba",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Curacao",
locales="nl_NL.UTF-8 UTF-8",
),
locale(
region="America",
location="Danmarkshavn",
locales="da_DK.UTF-8 UTF-8",
),
locale(
region="America",
location="Dawson",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Dawson_Creek",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Denver",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Detroit",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Dominica",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="America",
location="Edmonton",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Eirunepe",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="El_Salvador",
locales="es_SV.UTF-8 UTF-8",
),
locale(
region="America",
location="Ensenada",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Fort_Nelson",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Fort_Wayne",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Fortaleza",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Glace_Bay",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Godthab",
locales="da_DK.UTF-8 UTF-8",
),
locale(
region="America",
location="Goose_Bay",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Grand_Turk",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Grenada",
locales="en_GD.UTF-8 UTF-8",
),
locale(
region="America",
location="Guadeloupe",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="America",
location="Guatemala",
locales="es_GT.UTF-8 UTF-8",
),
locale(
region="America",
location="Guayaquil",
locales="es_EC.UTF-8 UTF-8",
),
locale(
region="America",
location="Guyana",
locales="en_GY.UTF-8 UTF-8",
),
locale(
region="America",
location="Halifax",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Havana",
locales="es_CU.UTF-8 UTF-8",
),
locale(
region="America",
location="Hermosillo",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Indianapolis",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Inuvik",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Iqaluit",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Jamaica",
locales="en_JM.UTF-8 UTF-8",
),
locale(
region="America",
location="Jujuy",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Juneau",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Kentucky/Louisville",
locales="en_US.UTF.8 UTF-8"
),
locale(
region="America",
location="Knox_IN",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Kralendijk",
locales="nl_NL.UTF-8 UTF-8",
),
locale(
region="America",
location="La_Paz",
locales="es_BO.UTF-8 UTF-8",
),
locale(
region="America",
location="Lima",
locales="es_PE.UTF-8 UTF-8",
),
locale(
region="America",
location="Los_Angeles",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Lower_Princes",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Maceio",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Managua",
locales="es_NI.UTF-8 UTF-8",
),
locale(
region="America",
location="Manaus",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Marigot",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="America",
location="Martinique",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="America",
location="Matamoros",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Mazatlan",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Mendoza",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Menominee",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Merida",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Metlakatla",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Mexico_City",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Miquelon",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="America",
location="Moncton",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Monterrey",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Montevideo",
locales="es_UY.UTF-8 UTF-8",
),
locale(
region="America",
location="Montreal",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Montserrat",
locales="en_MS.UTF-8 UTF-8",
),
locale(
region="America",
location="Nassau",
locales="en_BS.UTF-8 UTF-8",
),
locale(
region="America",
location="New_York",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Nipigon",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Nome",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Noronha",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="North_Dakota/Beulah",
locales="en_US.UTF-8 UTF-8"
),
locale(
region="America",
location="North_Dakota/Center",
locales="en_US.UTF-8 UTF-8"
),
locale(
region="America",
location="North_Dakota/New_Salem",
locales="en_US.UTF-8 UTF-8"
),
locale(
region="America",
location="Nuuk",
locales="en_GL.UTF-8 UTF-8",
),
locale(
region="America",
location="Ojinaga",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Panama",
locales="es_PA.UTF-8 UTF-8",
),
locale(
region="America",
location="Pangnirtung",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Paramaribo",
locales="nl_SR.UTF-8 UTF-8",
),
locale(
region="America",
location="Phoenix",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Port-au-Prince",
locales="fr_HT.UTF-8 UTF-8",
),
locale(
region="America",
location="Porto_Acre",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Port_of_Spain",
locales="en_TT.UTF-8 UTF-8",
),
locale(
region="America",
location="Porto_Velho",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Puerto_Rico",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Punta_Arenas",
locales="es_CL.UTF-8 UTF-8",
),
locale(
region="America",
location="Rainy_River",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Rankin_Inlet",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Recife",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Regina",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Resolute",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Rio_Branco",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Rosario",
locales="es_AR.UTF-8 UTF-8",
),
locale(
region="America",
location="Santa_Isabel",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Santarem",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Santiago",
locales="es_CL.UTF-8 UTF-8",
),
locale(
region="America",
location="Santo_Domingo",
locales="es_DO.UTF-8 UTF-8",
),
locale(
region="America",
location="Sao_Paulo",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="America",
location="Scoresbysund",
locales="da_DK.UTF-8 UTF-8",
),
locale(
region="America",
location="Shiprock",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Sitka",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Barthelemy",
locales="fr_BL.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Johns",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Kitts",
locales="en_KN.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Lucia",
locales="en_LC.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Thomas",
locales="en_VI.UTF-8 UTF-8",
),
locale(
region="America",
location="St_Vincent",
locales="en_VC.UTF-8 UTF-8",
),
locale(
region="America",
location="Swift_Current",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Tegucigalpa",
locales="es_HN.UTF-8 UTF-8",
),
locale(
region="America",
location="Thule",
locales="en_GL.UTF-8 UTF-8",
),
locale(
region="America",
location="Thunder_Bay",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Tijuana",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="America",
location="Toronto",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Tortola",
locales="en_VG.UTF-8 UTF-8",
),
locale(
region="America",
location="Vancouver",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Virgin",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Whitehorse",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Winnipeg",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="America",
location="Yakutat",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="America",
location="Yellowknife",
locales="en_CA.UTF-8 UTF-8",
),
]

@ -0,0 +1,65 @@
from jade_gui.classes.locale import locale
antarctica = [
locale(
region="Antarctica",
location="Casey",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Davis",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="DumontDurville",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Macquarie",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Mawson",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="McMurdo",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Palmer",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Rothera",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="South_Pole",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Syowa",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Troll",
locales="en_AQ.UTF-8 UTF-8",
),
locale(
region="Antarctica",
location="Vostok",
locales="en_AQ.UTF-8 UTF-8",
),
]

@ -0,0 +1,10 @@
from jade_gui.classes.locale import locale
arctic = [
locale(
region="Arctic",
location="Longyearbyen",
locales="no_NO.UTF-8 UTF-8",
)
]

@ -0,0 +1,495 @@
from jade_gui.classes.locale import locale
asia = [
locale(
region="Asia",
location="Aden",
locales="ar_SA.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Almaty",
locales="kk_KZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Amman",
locales="ar_JO.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Anadyr",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Aqtau",
locales="kk_KZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Aqtobe",
locales="kk_KZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ashgabat",
locales="tk_TM.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ashkhabad",
locales="tk_TM.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Atyrau",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Baghdad",
locales="ar_IQ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Bahrain",
locales="ar_BH.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Baku",
locales="az_AZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Bangkok",
locales="th_TH.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Barnaul",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Beirut",
locales="ar_LB.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Bishkek",
locales="ky_KG.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Brunei",
locales="ms_BN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Chita",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Choibalsan",
locales="mn_MN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Chongqing",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Chungking",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Colombo",
locales="si_LK.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Dacca",
locales="bn_BD.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Damascus",
locales="ar_SY.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Dhaka",
locales="bn_BD.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Dili",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Dubai",
locales="ar_AE.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Dushanbe",
locales="tg_TJ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Famagusta",
locales="tr_TR.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Gaza",
locales="ar_PS.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Harbin",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Hebron",
locales="ar_PS.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ho_Chi_Minh",
locales="vi_VN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Hong_Kong",
locales="zh_HK.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Hovd",
locales="mn_MN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Irkutsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Istanbul",
locales="tr_TR.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Jakarta",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Jayapura",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Jerusalem",
locales="he_IL.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kabul",
locales="fa_AF.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kamchatka",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Karachi",
locales="ur_PK.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kashgar",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kathmandu",
locales="ne_NP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Katmandu",
locales="ne_NP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Khandyga",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kolkata",
locales="hi_IN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Krasnoyarsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kuala_Lumpur",
locales="ms_MY.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kuching",
locales="ms_MY.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Kuwait",
locales="ar_KW.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Macao",
locales="zh_MO.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Macau",
locales="zh_MO.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Magadan",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Makassar",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Manila",
locales="tl_PH.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Muscat",
locales="ar_OM.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Nicosia",
locales="el_CY.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Novokuznetsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Novosibirsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Omsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Oral",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Phnom_Penh",
locales="kh_KH.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Pontianak",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Pyongyang",
locales="ko_KP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Qatar",
locales="ar_QA.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Qostanay",
locales="kk_KZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Qyzylorda",
locales="kk_KZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Rangoon",
locales="my_MM.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Riyadh",
locales="ar_SA.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Saigon",
locales="vi_VN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Sakhalin",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Samarkand",
locales="uz_UZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Seoul",
locales="ko_KR.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Shanghai",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Singapore",
locales="en_SG.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Srednekolymsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Taipei",
locales="zh_TW.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tashkent",
locales="uz_UZ.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tbilisi",
locales="ka_GE.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tehran",
locales="fa_IR.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tel_Aviv",
locales="he_IL.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Thimbu",
locales="ne_NP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Thimphu",
locales="ne_NP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tokyo",
locales="ja_JP.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Tomsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ujung_Pandang",
locales="id_ID.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ulaanbaatar",
locales="mn_MN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ulan_Bator",
locales="mn_MN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Urumqi",
locales="zh_CN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Ust-Nera",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Vientiane",
locales="vi_VN.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Vladivostok",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Yakutsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Yangon",
locales="my_MM.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Yekaterinburg",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Asia",
location="Yerevan",
locales="hy_AM.UTF-8 UTF-8",
),
]

@ -0,0 +1,65 @@
from jade_gui.classes.locale import locale
atlantic = [
locale(
region="atlantic",
location="Azores",
locales="pt_PT.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Bermuda",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Canary",
locales="es_ES.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Cape_Verde",
locales="pt_PT.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Faeroe",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Faroe",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Jan_Mayen",
locales="nb_NO.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Madeira",
locales="pt_PT.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Reykjavik",
locales="is_IS.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="South_Georgia",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="Stanley",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="atlantic",
location="St_Helena",
locales="en_GB.UTF-8 UTF-8",
),
]

@ -0,0 +1,90 @@
from jade_gui.classes.locale import locale
australia = [
locale(
region="Australia",
location="Adelaide",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Brisbane",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Broken_Hill",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Canberra",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Currie",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Darwin",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Eucla",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Hobart",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Lindeman",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Lord_Howe",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Melbourne",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Perth",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Queensland",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Sydney",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Tasmania",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Victoria",
locales="en_AU.UTF-8 UTF-8",
),
locale(
region="Australia",
location="Yancowinna",
locales="en_AU.UTF-8 UTF-8",
),
]

@ -0,0 +1,15 @@
from jade_gui.classes.locale import locale
brazil = [
locale(
region="Brazil",
location="Acre",
locales="pt_BR.UTF-8 UTF-8",
),
locale(
region="Brazil",
location="DeNoronha",
locales="pt_BR.UTF-8 UTF-8",
),
]

@ -0,0 +1,40 @@
from jade_gui.classes.locale import locale
canada = [
locale(
region="canada",
location="Atlantic",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Central",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Eastern",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Mountain",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Newfoundland",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Pacific",
locales="en_CA.UTF-8 UTF-8",
),
locale(
region="canada",
location="Yukon",
locales="en_CA.UTF-8 UTF-8",
),
]

@ -0,0 +1,15 @@
from jade_gui.classes.locale import locale
chile = [
locale(
region="Chile",
location="Continental",
locales="es_CL.UTF-8 UTF-8",
),
locale(
region="Chile",
location="EasterIsland",
locales="es_CL.UTF-8 UTF-8",
),
]

@ -0,0 +1,315 @@
from jade_gui.classes.locale import locale
europe = [
locale(
region="Europe",
location="Amsterdam",
locales="nl_NL.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Andorra",
locales="ca_ES.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Athens",
locales="el_GR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Belfast",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Belgrade",
locales="sr_RS.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Berlin",
locales="de_DE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Bratislava",
locales="sk_SK.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Brussels",
locales="nl_BE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Bucharest",
locales="ro_RO.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Budapest",
locales="hu_HU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Busingen",
locales="de_DE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Chisinau",
locales="ro_RO.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Copenhagen",
locales="da_DK.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Dublin",
locales="en_IE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Gibraltar",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Guernsey",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Helsinki",
locales="fi_FI.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Isle_of_Man",
locales="en_IM.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Istanbul",
locales="tr_TR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Jersey",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Kaliningrad",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Kiev",
locales="uk_UA.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Kirov",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Lisbon",
locales="pt_PT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Ljubljana",
locales="sl_SI.UTF-8 UTF-8",
),
locale(
region="Europe",
location="London",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Luxembourg",
locales="fr_LU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Madrid",
locales="es_ES.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Malta",
locales="en_GB.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Mariehamn",
locales="sv_SE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Minsk",
locales="be_BY.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Monaco",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Moscow",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Nicosia",
locales="el_GR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Oslo",
locales="no_NO.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Paris",
locales="fr_FR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Podgorica",
locales="sr_RS.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Prague",
locales="cs_CZ.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Riga",
locales="lv_LV.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Rome",
locales="it_IT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Samara",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="San_Marino",
locales="it_IT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Sarajevo",
locales="bs_BA.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Saratov",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Simferopol",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Skopje",
locales="mk_MK.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Sofia",
locales="bg_BG.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Stockholm",
locales="sv_SE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Tallinn",
locales="et_EE.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Tirane",
locales="sq_AL.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Tiraspol",
locales="ro_RO.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Ulyanovsk",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Uzhgorod",
locales="uk_UA.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Vaduz",
locales="de_AT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Vatican",
locales="it_IT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Vienna",
locales="de_AT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Vilnius",
locales="lt_LT.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Volgograd",
locales="ru_RU.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Warsaw",
locales="pl_PL.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Zagreb",
locales="hr_HR.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Zaporozhye",
locales="uk_UA.UTF-8 UTF-8",
),
locale(
region="Europe",
location="Zurich",
locales="de_CH.UTF-8 UTF-8",
),
]

@ -0,0 +1,60 @@
from jade_gui.classes.locale import locale
indian = [
locale(
region="Indian",
location="Antananarivo",
locales="fr_MG.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Chagos",
locales="en_IO.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Christmas",
locales="en_CX.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Cocos",
locales="en_CC.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Comoro",
locales="fr_KM.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Kerguelen",
locales="fr_TF.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Mahe",
locales="en_SC.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Maldives",
locales="en_MV.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Mauritius",
locales="en_MU.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Mayotte",
locales="fr_YT.UTF-8 UTF-8",
),
locale(
region="Indian",
location="Reunion",
locales="fr_RE.UTF-8 UTF-8",
),
]

@ -0,0 +1,50 @@
# locales.py
#
# Copyright 2022 user
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from jade_gui.locales.africa import africa
from jade_gui.locales.america import america
from jade_gui.locales.antarctica import antarctica
from jade_gui.locales.arctic import arctic
from jade_gui.locales.asia import asia
from jade_gui.locales.atlantic import atlantic
from jade_gui.locales.australia import australia
from jade_gui.locales.brazil import brazil
from jade_gui.locales.canada import canada
from jade_gui.locales.chile import chile
from jade_gui.locales.europe import europe
from jade_gui.locales.indian import indian
from jade_gui.locales.mexico import mexico
from jade_gui.locales.pacific import pacific
locations = [
africa,
america,
antarctica,
arctic,
asia,
atlantic,
australia,
brazil,
canada,
chile,
europe,
indian,
mexico,
pacific
]

@ -0,0 +1,22 @@
pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), meson.project_name())
localesdir = join_paths(pkgdatadir, 'jade_gui/locales')
jade_gui_sources = [
'__init__.py',
'africa.py',
'america.py',
'antarctica.py',
'arctic.py',
'asia.py',
'atlantic.py',
'australia.py',
'brazil.py',
'canada.py',
'chile.py',
'europe.py',
'indian.py',
'mexico.py',
'pacific.py',
'locales_list.py',
]
install_data(jade_gui_sources, install_dir: localesdir)

@ -0,0 +1,20 @@
from jade_gui.classes.locale import locale
mexico = [
locale(
region="Mexico",
location="BajaNorte",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="Mexico",
location="BajaSur",
locales="es_MX.UTF-8 UTF-8",
),
locale(
region="Mexico",
location="General",
locales="es_MX.UTF-8 UTF-8",
),
]

@ -0,0 +1,220 @@
from jade_gui.classes.locale import locale
pacific = [
locale(
region="Pacific",
location="Apia",
locales="en_WS.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Auckland",
locales="en_NZ.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Bougainville",
locales="en_PG.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Chatham",
locales="en_NZ.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Chuuk",
locales="en_FM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Easter",
locales="en_CL.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Efate",
locales="en_VU.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Enderbury",
locales="en_KI.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Fakaofo",
locales="en_TK.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Fiji",
locales="en_FJ.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Funafuti",
locales="en_TV.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Galapagos",
locales="en_EC.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Gambier",
locales="en_PF.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Guadalcanal",
locales="en_SB.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Guam",
locales="en_GU.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Honolulu",
locales="en_US.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Johnston",
locales="en_UM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Kiritimati",
locales="en_KI.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Kosrae",
locales="en_FM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Kwajalein",
locales="en_MH.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Majuro",
locales="en_MH.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Marquesas",
locales="en_PF.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Midway",
locales="en_UM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Nauru",
locales="en_NR.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Niue",
locales="en_NU.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Norfolk",
locales="en_NF.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Noumea",
locales="en_NC.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Pago_Pago",
locales="en_AS.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Palau",
locales="en_PW.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Pitcairn",
locales="en_PN.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Pohnpei",
locales="en_FM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Ponape",
locales="en_FM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Port_Moresby",
locales="en_PG.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Rarotonga",
locales="en_CK.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Saipan",
locales="en_MP.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Samoa",
locales="en_AS.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Tahiti",
locales="en_PF.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Tarawa",
locales="en_KI.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Tongatapu",
locales="en_TO.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Truk",
locales="en_FM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Wake",
locales="en_UM.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Wallis",
locales="en_WF.UTF-8 UTF-8",
),
locale(
region="Pacific",
location="Yap",
locales="en_FM.UTF-8 UTF-8",
),
]

@ -61,11 +61,14 @@ configure_file(
subdir('widgets')
subdir('functions')
subdir('classes')
subdir('locales')
jade_gui_sources = [
'__init__.py',
'main.py',
'window.py',
'keymaps.py',
]
install_data(jade_gui_sources, install_dir: moduledir)

@ -14,14 +14,6 @@ template KeyboardScreen : Adw.Bin {
vexpand: true;
title: "Next question: keyboard layout?";
description: "What is it? Huh?";
Gtk.Box {
orientation: vertical;
Gtk.SearchBar keyboard_search {
Gtk.SearchEntry keyboard_entry_search {
placeholder-text: "Search for a timezone...";
}
}
}
Adw.PreferencesPage {
Adw.Carousel keyboard_carousel {
orientation: horizontal;
@ -29,24 +21,29 @@ template KeyboardScreen : Adw.Bin {
hexpand: true;
Adw.PreferencesGroup keyboard_layouts {
hexpand: true;
vexpand: true;
margin-end: 5;
margin-end: 20;
margin-start: 20;
Gtk.ListBox list_keyboard_layouts {
//selection-mode: none;
Gtk.Box layout_search {
Gtk.SearchEntry layout_entry_search {
hexpand: true;
vexpand: true;
// margin-end: 5;
placeholder-text: _("Search for a keyboard layout");
}
}
styles ["boxed-list"]
}
}
Adw.PreferencesGroup keyboard_variants {
hexpand: true;
vexpand: true;
margin-start: 5;
margin-end: 20;
margin-start: 20;
Gtk.ListBox list_keyboard_variants {
Gtk.Box variant_search {
Gtk.SearchEntry variant_entry_search {
hexpand: true;
vexpand: true;
// margin-start: 5;
placeholder-text: _("Search for a keyboard variant");
}
}
styles ["boxed-list"]
}
}

@ -7,8 +7,6 @@ template TimezoneScreen : Adw.Bin {
Gtk.Box {
vexpand: true;
hexpand: true;
//valign: center;
//halign: center;
Adw.StatusPage {
hexpand: true;
vexpand: true;
@ -16,14 +14,15 @@ template TimezoneScreen : Adw.Bin {
description: "What's your curent timezone?";
Gtk.Box {
orientation: vertical;
Gtk.SearchBar timezone_search {
Gtk.SearchEntry timezone_entry_search {
placeholder-text: "Search for a timezone...";
}
}
Adw.PreferencesPage {
Adw.PreferencesGroup {
Gtk.ListBox list_timezones {
Gtk.Box timezone_search {
Gtk.SearchEntry timezone_entry_search {
hexpand: true;
placeholder-text: _("Search for a timezone");
}
}
styles ["boxed-list"]
}
}

@ -3,7 +3,6 @@ using Adw 1;
template TimezoneEntry : Adw.ActionRow {
title: "region/location";
subtitle: "timezone UTC +XX:XX";
Gtk.Box {
spacing: 6;
Gtk.Label time_label {

@ -28,15 +28,14 @@ class TimezoneEntry(Adw.ActionRow):
time_label = Gtk.Template.Child()
def __init__(self, window, location, region, locale, timezone, application, **kwargs):
def __init__(self, window, region, location, locale, application, **kwargs):
super().__init__(**kwargs)
self.set_title(region+"/"+location)
self.set_subtitle(timezone)
if location != "Argentina": # TODO: pytz for some reason doesn't like America/Argentina, fix this
self.time_label.set_text(self.calculate_time(location=location, region=region))
self.time_label.set_text(self.calculate_time(location, region))
def calculate_time(widget, location, region):
timezone = pytz.timezone(location+"/"+region)
def calculate_time(self, location, region):
timezone = pytz.timezone(region+"/"+location)
datetime_timezone = datetime.now(timezone)
return datetime_timezone.strftime('%H:%M')

@ -33,6 +33,8 @@ from .functions.partition_screen import PartitionScreen
from .functions.summary_screen import SummaryScreen
from .functions.install_screen import InstallScreen
from .functions.finished_screen import FinishedScreen
from .locales.locales_list import locations
from .keymaps import keymaps
@Gtk.Template(resource_path='/al/getcryst/jadegui/window.ui')
class JadeGuiWindow(Gtk.ApplicationWindow):
@ -74,21 +76,19 @@ class JadeGuiWindow(Gtk.ApplicationWindow):
### ---------
### Test timezones
timezone_test = TimezoneEntry(window=self, location="Europe", region="Berlin", timezone="CEST UTC+2", locale="en_US.UTF-8", **kwargs)
timezone_test_two = TimezoneEntry(window=self, location="Europe", region="London", timezone="BST UTC+1", locale="en_US.UTF-8", **kwargs)
timezone_test_three = TimezoneEntry(window=self, location="America", region="Chihuahua", timezone="MDT UTC-6", locale="en_MX.UTF-8", **kwargs)
self.timezone_screen.list_timezones.append(timezone_test)
self.timezone_screen.list_timezones.append(timezone_test_two)
self.timezone_screen.list_timezones.append(timezone_test_three)
for i in locations:
for locale in i:
print(locale.region)
print(locale.location)
print(locale.locales)
self.timezone_screen.list_timezones.append(TimezoneEntry(window=self, region=locale.region, location=locale.location, locale=locale.locales, **kwargs))
### ---------
### Test layouts
layout_test = KeyboardLayout(window=self, country="Germany", country_shorthand="DE", **kwargs)
layout_test_two = KeyboardLayout(window=self, country="United Kingdom", country_shorthand="GB", **kwargs)
layout_test_three = KeyboardLayout(window=self, country="United States", country_shorthand="US", **kwargs)
self.keyboard_screen.list_keyboard_layouts.append(layout_test)
self.keyboard_screen.list_keyboard_layouts.append(layout_test_two)
self.keyboard_screen.list_keyboard_layouts.append(layout_test_three)
for keymap in keymaps:
print(keymap.layout)
print(keymap.backend_layout)
self.keyboard_screen.list_keyboard_layouts.append(KeyboardLayout(window=self, country=keymap.layout, country_shorthand=keymap.backend_layout, **kwargs))
### ---------
### Test variants

Loading…
Cancel
Save