/usr/lib/gdesklets/Displays/Calendar/lang.script is in gdesklets 0.36.1-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | # Default language is english
lang = "en"
LANG_LIST = [ ("Brazilian Portuguese", "pt_BR"), ("Czech", "cz"), ("English", "en"), ("French", "fr"), ("German", "de"), ("Greek", "el"), ("Italian", "it"), ("Polish", "pl"), ("Slovak", "sk"), ("Spanish", "es"), (u"\u4e2d\u6587", "zh")]
# List of days of the week
DAY_LIST = [ ("Segunda","Terça","Quarta","Quinta","Sexta","Sábado","Domingo"),
("Pondělí","Úterý","Středa","Čtvrtek","Pátek","Sobota","Neděle"),
("Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"),
("Lundi","Mardi","Mecredi","Jeudi","Vendredi","Samedi","Dimanche"),
("Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag","Sonntag"),
("Δευτέρα","Τρίτη","Τετάρτη","Πέμπτη","Παρασκευή","Σάββατο","Κυριακή"),
("Lunedi","Martedi","Mercoledi","Giovedi","Venerdi","Sabato","Domenica"),
("Poniedziałek","Wtorek","Środa","Czwartek","Piątek","Sobota","Niedziela"),
("Pondelok","Utorok","Streda","Štvrtok","Piatok","Sobota","Nedeľa"),
("Lunes","Martes","Miercoles","Jueves","Viernes","Sabado","Domingo"),
(u"\u661f\u671f\u4e00",u"\u661f\u671f\u4e8c",u"\u661f\u671f\u4e09",u"\u661f\u671f\u56db",u"\u661f\u671f\u4e94",u"\u661f\u671f\u516d",u"\u661f\u671f\u65e5")]
# List of weekday abbreviations
DAY_ABBR_LIST = [ ("Seg","Ter","Qua","Qui","Sex","Sab","Dom"),
("Po",u"\xdat","St",u"\u010ct",u"P\xe1","So","Ne"),
("Mon","Tue","Wed","Thu","Fri","Sat","Sun"),
("Lun","Mar","Mer","Jeu","Ven","Sam","Dim"),
("Mo","Di","Mi","Do","Fr","Sa","So"),
("Δευ","Τρι","Τετ","Πεμ","Παρ","Σαβ","Κυρ"),
("Lun","Mar","Mer","Gio","Ven","Sam","Dom"),
("Pn","Wt","Śr","Czw","Pt","Sob","Ndz"),
("Po","Ut","St",u"\u0160t","Pi","So","Ne"),
("Lu","Ma","Mi","Ju","Vi","Sa","Do"),
(u"\u4e00",u"\u4e8c",u"\u4e09",u"\u56db",u"\u4e94",u"\u516d",u"\u65e5")]
# List of months
MONTH_LIST = [("","Janeiro","Fevereiro","Março","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"),
("","Leden","Únor","Březen","Duben","Květen","Červen","Červenec","Srpen","Září","Říjen","Listopad","Prosinec"),
("","January","February","March","April","May","June","July","August","September","October","November","December"),
("","Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Août","Septembre","Octobre","Novembre","Décembre"),
("","Januar","Februar","März","April","Mai","Juni","July","August","September","Oktober","November","Dezember"),
("","Ιανουάριος","Φεβρουάριος","Μάρτιος","Απρίλιος","Μάιος","Ιούνιος","Ιούλιος","Αύγουστος","Σεπτέμβριος","Οκτώβριος","Νοέμβριος","Δεκέμβριος"),
("","Gennaio","Febbraio","Marzo","Aprile","Maggio","Giugno","Luglio","Agosto","Settembre","Ottobre","Novembre","Dicembre"),
("","Styczen","Luty","Marzec","Kwiecień","Maj","Czerwiec","Lipiec","Sierpień","Wrzesień","Październik","Listopad","Grudzień"),
("","Január","Február","Marec","Apríl","Máj","Jún","Júl","August","September","Octóber","November","December"),
("","Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"),
("",u"\u4e00\u6708",u"\u4e8c\u6708",u"\u4e09\u6708",u"\u56db\u6708",u"\u4e94\u6708",u"\u516d\u6708",u"\u4e03\u6708",u"\u516b\u6708",u"\u4e5d\u6708",u"\u5341\u6708",u"\u5341\u4e00\u6708",u"\u5341\u4e8c\u6708")]
# Load the language options into the dropdown list box
Prefs.language.items = [ name for name in LANG_LIST ]
# This wants an integer (0-6)
# Returns (Monday-Sunday) in the language set
def day_i18n(day_no):
for i in range( len(LANG_LIST) ):
if lang == LANG_LIST[i][1]: return DAY_LIST[i][day_no]
# If for some reason there's a failure
return ""
# This wants an integer (0-6)
# Returns (Mo-Su) in the language set
def day_abbr_i18n(day_no):
for i in range( len(LANG_LIST) ):
if lang == LANG_LIST[i][1]: return DAY_ABBR_LIST[i][day_no]
# If for some reason there's a failure
return ""
# This wants an integer (1-12)
# Returns (January-December) in the language set
def month_i18n(month_no):
for i in range( len(LANG_LIST) ):
if lang == LANG_LIST[i][1]: return MONTH_LIST[i][month_no]
# If for some reason there's a failure
return ""
def translate(day_name):
for i in range( len(DAY_LIST) ):
for j in range( 7 ):
if day_name == DAY_LIST[i][j]:
for k in range( len(LANG_LIST) ):
if lang == LANG_LIST[k][1]:
return DAY_LIST[k][j]
|