Modul:Languages

Aus Wikivoyage
Zur Navigation springen Zur Suche springen
Template-info.png Dokumentation für das Modul Languages[Ansicht] [Bearbeiten] [Versionsgeschichte] [Aktualisieren]

Der Modul enthält Angaben zur Typumwandlung vom Wikidata qualifyer zum ISO-639-1-Sprachcode.

Arrays

  • id2code – liefert den ISO 639-1-Code für einen Wikidata-Qualifier.
  • lngProps – liefert für einen ISO 639-1-Code ein Array mit Spracheigenschaften:
    • q: Language entity id
    • n: German name of the language
    • e: English name of the language
    • w: Writing entity id
    • s: Writing/script label
    • d: Direction if rtl (right-to-left)
    • c: Wikipedia edits in millions per 2018/7/1 as a measure of importance

Funktionen

function lg.getProperty( lng, p )

Liefert für den ISO-639-1-Sprachcode lng aus dem Array lngProps den Wert für den Arrayindex p (c, d, e, n, s, q, w) zurück. Wenn es den Sprachcode oder den Arrayindex nicht gibt, wird eine leere Zeichenkette zurückgegeben.

function lg.isR2L( lng )

Liefert für den ISO-639-1-Sprachcode lng die Angabe zurück, ob es eine Rechts-nach-links-Schrift ist (true) oder nicht (false).

Wartungskategorien

Verwendung in anderen Modulen

Dieses Modul ist notwendig für die Ausführung folgender Module. Bei Anpassungen sollte die Funktionstüchtigkeit der folgenden Module geprüft werden. Benutze dazu auch diese Tracking-Kategorie um Fehler zu finden, die sich dann auf Artikel auswirken:

Hinweise
-- using ISO 639-1 code of the languages

-- array indexes:
-- q: Language entity id
-- n: German name of the language
-- e: English name of the language
-- w: Writing entity id
-- s: Writing/script label
-- d: Direction if rtl (right-to-left)
-- c: Wikipedia edits in millions per 2018/7/1 as a measure of importance
--    from https://de.wikipedia.org/wiki/Wikipedia:Sprachen

-- Wikidata SPARQL query at https://query.wikidata.org/

-- #Languages
-- SELECT ?code ?item ?itemLabel ?writing ?writingLabel ?directionLabel
-- WHERE 
-- {
--  ?item wdt:P31 wd:Q34770 ;
--        wdt:P218 ?code ;
--        wdt:P282 ?writing .
--  OPTIONAL {
--   ?writing wdt:P1406 ?direction .
--  }
--  SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
-- }
-- ORDER BY ASC(?code)
-- LIMIT 300

-- some languages manually added

local lg = {}

lg.id2code = {
	Q27811  = 'aa',
	Q5111   = 'ab',
	Q14196  = 'af',
	Q28026  = 'ak',
	Q28244  = 'am',
	Q8765   = 'an',
	Q13955  = 'ar',
	Q29401  = 'as',
	Q29561  = 'av',
	Q4627   = 'ay',
	Q9292   = 'az',
	Q13389  = 'ba',
	Q9091   = 'be',
	Q7918   = 'bg',
	Q35452  = 'bi',
	Q33243  = 'bm',
	Q9610   = 'bn',
	Q34271  = 'bo',
	Q12107  = 'br',
	Q9303   = 'bs',
	Q7026   = 'ca',
	Q33350  = 'ce',
	Q33262  = 'ch',
	Q33111  = 'co',
	Q33390  = 'cr',
	Q9056   = 'cs',
	Q33348  = 'cv',
	Q9309   = 'cy',
	Q9035   = 'da',
	Q188    = 'de',
	Q32656  = 'dv',
	Q33081  = 'dz',
	Q30005  = 'ee',
	Q36510  = 'el', -- Modern Greek
	Q9129   = 'el', -- Greek
	Q1860   = 'en',
	Q7979   = 'en-gb',
	Q7976   = 'en-us',
	Q1321   = 'es',
	Q9072   = 'et',
	Q8752   = 'eu',
	Q9168   = 'fa',
	Q33454  = 'ff',
	Q1412   = 'fi',
	Q33298  = 'fil',
	Q33295  = 'fj',
	Q25258  = 'fo',
	Q150    = 'fr',
	Q27175  = 'fy',
	Q9142   = 'ga',
	Q9314   = 'gd',
	Q9307   = 'gl',
	Q35876  = 'gn',
	Q5137   = 'gu',
	Q12175  = 'gv',
	Q56475  = 'ha',
	Q9288   = 'he',
	Q1568   = 'hi',
	Q33617  = 'ho',
	Q6654   = 'hr',
	Q33491  = 'ht',
	Q9067   = 'hu',
	Q8785   = 'hy',
	Q33315  = 'hz',
	Q9240   = 'id',
	Q33578  = 'ig',
	Q34235  = 'ii',
	Q27183  = 'ik',
	Q294    = 'is',
	Q652    = 'it',
	Q29921  = 'iu',
	Q5287   = 'ja',
	Q33549  = 'jv',
	Q8108   = 'ka',
	Q33702  = 'kg',
	Q33587  = 'ki',
	Q1405077 = 'kj',
	Q9252   = 'kk',
	Q25355  = 'kl',
	Q9205   = 'km',
	Q33673  = 'kn',
	Q9176   = 'ko',
	Q36094  = 'kr',
	Q33552  = 'ks',
	Q36368  = 'ku',
	Q36126  = 'kv',
	Q25289  = 'kw',
	Q9255   = 'ky',
	Q9051   = 'lb',
	Q33368  = 'lg',
	Q102172 = 'li',
	Q36217  = 'ln',
	Q9211   = 'lo',
	Q9083   = 'lt',
	Q36157  = 'lu',
	Q9078   = 'lv',
	Q7930   = 'mg',
	Q36280  = 'mh',
	Q36451  = 'mi',
	Q9296   = 'mk',
	Q36236  = 'ml',
	Q9246   = 'mn',
	Q36392  = 'mo',
	Q1571   = 'mr',
	Q9237   = 'ms',
	Q9166   = 'mt',
	Q9228   = 'my',
	Q13307  = 'na',
	Q25167  = 'nb',
	Q35613  = 'nd',
	Q33823  = 'ne',
	Q33900  = 'ng',
	Q7411   = 'nl',
	Q25164  = 'nn',
	Q9043   = 'no',
	Q36785  = 'nr',
	Q33273  = 'ny',
	Q14185  = 'oc',
	Q33875  = 'oj',
	Q33864  = 'om',
	Q33810  = 'or',
	Q33968  = 'os',
	Q58635  = 'pa',
	Q36727  = 'pi',
	Q809    = 'pl',
	Q58680  = 'ps',
	Q5146   = 'pt',
	Q13199  = 'rm',
	Q33583  = 'rn',
	Q7913   = 'ro',
	Q7737   = 'ru',
	Q33573  = 'rw',
	Q11059  = 'sa',
	Q33976  = 'sc',
	Q33997  = 'sd',
	Q33947  = 'se',
	Q33954  = 'sg',
	Q13267  = 'si',
	Q9058   = 'sk',
	Q9063   = 'sl',
	Q34011  = 'sm',
	Q34004  = 'sn',
	Q13275  = 'so',
	Q8748   = 'sq',
	Q9299   = 'sr',
	Q8821   = 'sr-me',
	Q34014  = 'ss',
	Q34340  = 'st',
	Q34002  = 'su',
	Q9027   = 'sv',
	Q7838   = 'sw',
	Q5885   = 'ta',
	Q8097   = 'te',
	Q9260   = 'tg',
	Q9217   = 'th',
	Q34124  = 'ti',
	Q9267   = 'tk',
	Q34057  = 'tl',
	Q34137  = 'tn',
	Q34094  = 'to',
	Q256    = 'tr',
	Q34327  = 'ts',
	Q25285  = 'tt',
	Q34055  = 'tvl',
	Q36850  = 'tw',
	Q34128  = 'ty',
	Q13263  = 'ug',
	Q8798   = 'uk',
	Q1617   = 'ur',
	Q9264   = 'uz',
	Q32704  = 've',
	Q9199   = 'vi',
	Q34219  = 'wa',
	Q34257  = 'wo',
	Q13218  = 'xh',
	Q8641   = 'yi',
	Q34311  = 'yo',
	Q13216  = 'za',
	Q7850   = 'zh', -- Chinese
	Q727694 = 'zh', -- Standard Chinese
	Q10179  = 'zu'
}

lg.lngProps = {
	aa = { q = 'Q27811', n = 'Afar', e = 'Afar', w = 'Q8229', s = 'Latin script', c = 0 },
	ab = { q = 'Q5111', n = 'Abchasisch', e = 'Abkhaz', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	af = { q = 'Q14196', n = 'Afrikaans', e = 'Afrikaans', w = 'Q8229', s = 'Latin script', c = 0 },
	ak = { q = 'Q28026', n = 'Akan', e = 'Akan', w = 'Q8229', s = 'Latin script', c = 0 },
	am = { q = 'Q28244', n = 'Amharisch', e = 'Amharic', w = 'Q257634', s = "Ge'ez script", c = 0  },
	an = { q = 'Q8765', n = 'Aragonesisch', e = 'Aragonese', w = 'Q8229', s = 'Latin script', c = 0 },
	ar = { q = 'Q13955', n = 'Arabisch', e = 'Arabic', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 29 },
	as = { q = 'Q29401', n = 'Assamesisch', e = 'Assamese', w = 'Q191272', s = 'Assamese alphabet', c = 0 },
	av = { q = 'Q29561', n = 'Awarisch', e = 'Avar', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	ay = { q = 'Q4627', n = 'Aymara', e = 'Aymara', w = 'Q8229', s = 'Latin script', c = 0 },
	az = { q = 'Q9292', n = 'Aserbaidschanisch', e = 'Azerbaijani', w = 'Q8229', s = 'Latin script', c = 0 },
	ba = { q = 'Q13389', n = 'Baschkirisch', e = 'Bashkir', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	be = { q = 'Q9091', n = 'Weißrussisch', e = 'Belarusian', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	bg = { q = 'Q7918', n = 'Bulgarisch', e = 'Bulgarian', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	bi = { q = 'Q35452', n = 'Bislama', e = 'Bislama', w = 'Q8229', s = 'Latin script', c = 0 },
	bm = { q = 'Q33243', n = 'Bambara', e = 'Bambara', w = 'Q8229', s = 'Latin script', c = 0 },
	bn = { q = 'Q9610', n = 'Bengali', e = 'Bengali', w = 'Q756802', s = 'Bengali alphabet', c = 0 },
	bo = { q = 'Q34271', n = 'Tibetisch', e = 'Tibetan', w = 'Q46861', s = 'Tibetan alphabet', c = 0 },
	br = { q = 'Q12107', n = 'Bretonisch', e = 'Breton', w = 'Q8229', s = 'Latin script', c = 0 },
	bs = { q = 'Q9303', n = 'Bosnisch', e = 'Bosnian', w = 'Q8229', s = 'Latin script', c = 0 },
	ca = { q = 'Q7026', n = 'Katalanisch', e = 'Catalan', w = 'Q8229', s = 'Latin script', c = 20 },
	ce = { q = 'Q33350', n = 'Tschetschenisch', e = 'Chechen', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	ch = { q = 'Q33262', n = 'Chamorro', e = 'Chamorro', w = 'Q8229', s = 'Latin script', c = 0 },
	co = { q = 'Q33111', n = 'Korsisch', e = 'Corsican', w = 'Q8229', s = 'Latin script', c = 0 },
	cr = { q = 'Q33390', n = 'Cree', e = 'Cree', w = 'Q8229', s = 'Latin script', c = 0 },
	cs = { q = 'Q9056', n = 'Tschechisch', e = 'Czech', w = 'Q8229', s = 'Latin script', c = 0 },
	cv = { q = 'Q33348', n = 'Tschuwaschisch', e = 'Chuvash', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	cy = { q = 'Q9309', n = 'Walisisch', e = 'Welsh', w = 'Q8229', s = 'Latin script', c = 0 },
	da = { q = 'Q9035', n = 'Dänisch', e = 'Danish', w = 'Q8229', s = 'Latin script', c = 0 },
	de = { q = 'Q188', n = 'Deutsch', e = 'German', w = 'Q8229', s = 'Latin script', c = 178 },
	dv = { q = 'Q32656', n = 'Dhivehi', e = 'Maldivian', w = 'Q877906', s = 'Thaana', d = 'rtl', c = 0 },
	dz = { q = 'Q33081', n = 'Dzongkha', e = 'Dzongkha', w = 'Q46861', s = 'Tibetan alphabet', c = 0 },
	ee = { q = 'Q30005', n = 'Ewe', e = 'Ewe', w = 'Q8229', s = 'Latin script', c = 0 },
	el = { q = 'Q9129', n = 'Griechisch', e = 'Greek', w = 'Q8216', s = 'Greek alphabet', c = 0 },
	en = { q = 'Q1860', n = 'Englisch', e = 'English', w = 'Q8229', s = 'Latin script', c = 844 },
	['en-gb'] = { q = 'Q7979', n = 'Britisches Englisch', e = 'British English', w = 'Q8229', s = 'Latin script', c = 0 },
	['en-us'] = { q = 'Q7976', n = 'Amerikanisches Englisch', e = 'American English', w = 'Q8229', s = 'Latin script', c = 0 },
	es = { q = 'Q1321', n = 'Spanisch', e = 'Spanish', w = 'Q285126', s = 'Spanish alphabet', c = 109 },
	et = { q = 'Q9072', n = 'Estnisch', e = 'Estonian', w = 'Q8229', s = 'Latin script', c = 0 },
	eu = { q = 'Q8752', n = 'Baskisch', e = 'Basque', w = 'Q8229', s = 'Latin script', c = 0 },
	fa = { q = 'Q9168', n = 'Persisch', e = 'Persian', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 24 },
	ff = { q = 'Q33454', n = 'Fulfulde', e = 'Fula', w = 'Q8229', s = 'Latin script', c = 0 },
	fi = { q = 'Q1412', n = 'Finnisch', e = 'Finnish', w = 'Q8229', s = 'Latin script', c = 0 },
	fil = { q = 'Q33298', n = 'Filipino', e = 'Filipino', w = 'Q8229', s = 'Latin script', c = 0 },
	fj = { q = 'Q33295', n = 'Fidschi', e = 'Fijian', w = 'Q8229', s = 'Latin script', c = 0 },
	fo = { q = 'Q25258', n = 'Färöisch', e = 'Faroese', w = 'Q8229', s = 'Latin script', c = 0 },
	fr = { q = 'Q150', n = 'Französisch', e = 'French', w = 'Q8229', s = 'Latin script', c = 150 },
	fy = { q = 'Q27175', n = 'Westfriesisch', e = 'West Frisian', w = 'Q8229', s = 'Latin script', c = 0 },
	ga = { q = 'Q9142', n = 'Irisch', e = 'Irish', w = 'Q8229', s = 'Latin script', c = 0 },
	gd = { q = 'Q9314', n = 'Schottisch-Gälisch', e = 'Scottish Gaelic', w = 'Q8229', s = 'Latin script', c = 0 },
	gl = { q = 'Q9307', n = 'Galicisch', e = 'Galician', w = 'Q8229', s = 'Latin script', c = 0 },
	gn = { q = 'Q35876', n = 'Guaraní', e = 'Guarani', w = 'Q8229', s = 'Latin script', c = 0 },
	gu = { q = 'Q5137', n = 'Gujarati', e = 'Gujarati', w = 'Q733944', s = 'Gujarati alphabet', c = 0 },
	gv = { q = 'Q12175', n = 'Manx', e = 'Manx', w = 'Q8229', s = 'Latin script', c = 0 },
	ha = { q = 'Q56475', n = 'Hausa', e = 'Hausa', w = 'Q8229', s = 'Latin script', c = 0 },
	he = { q = 'Q9288', n = 'Hebräisch', e = 'Hebrew', w = 'Q33513', s = 'Hebrew alphabet', d = 'rtl', c = 0 },
	hi = { q = 'Q1568', n = 'Hindi', e = 'Hindi', w = 'Q38592', s = 'Devanagari', c = 0 },
	ho = { q = 'Q33617', n = 'Hiri Motu', e = 'Hiri Motu', w = 'Q8229', s = 'Latin script', c = 0 },
	hr = { q = 'Q6654', n = 'Kroatisch', e = 'Croatian', w = 'Q8229', s = 'Latin script', c = 0 },
	ht = { q = 'Q33491', n = 'Haitianisch', e = 'Haitian Creole', w = 'Q8229', s = 'Latin script', c = 0 },
	hu = { q = 'Q9067', n = 'Ungarisch', e = 'Hungarian', w = 'Q8229', s = 'Latin script', c = 0 },
	hy = { q = 'Q8785', n = 'Armenisch', e = 'Armenian', w = 'Q11932', s = 'Armenian alphabet', c = 0 },
	hz = { q = 'Q33315', n = 'Otjiherero', e = 'Herero', w = 'Q8229', s = 'Latin script', c = 0 },
	id = { q = 'Q9240', n = 'Indonesisch', e = 'Indonesian', w = 'Q8229', s = 'Latin script', c = 0 },
	ig = { q = 'Q33578', n = 'Igbo', e = 'Igbo', w = 'Q8229', s = 'Latin script', c = 0 },
	ii = { q = 'Q34235', n = 'Nuosu', e = 'Nuosu language', w = 'Q1197646', s = 'Yi script', c = 0 },
	ik = { q = 'Q27183', n = 'Inupiaq', e = 'Inupiat', w = 'Q8229', s = 'Latin script', c = 0 },
	is = { q = 'Q294', n = 'Isländisch', e = 'Icelandic', w = 'Q8229', s = 'Latin script', c = 0 },
	it = { q = 'Q652', n = 'Italienisch', e = 'Italian', w = 'Q8229', s = 'Latin script', c = 98 },
	iu = { q = 'Q29921', n = 'Inuktitut', e = 'Inuktitut', w = 'Q2274646', s = 'Inuktitut syllabics', c = 0 },
	ja = { q = 'Q5287', n = 'Japanisch', e = 'Japanese', w = 'Q82772', s = 'Kanji', c = 69 },
	jv = { q = 'Q33549', n = 'Javanisch', e = 'Javanese', w = 'Q8229', s = 'Latin script', c = 0 },
	ka = { q = 'Q8108', n = 'Georgisch', e = 'Georgian', w = 'Q161428', s = 'Georgian alphabet', c = 0 },
	kg = { q = 'Q33702', n = 'Kikongo', e = 'Kongo', w = 'Q8229', s = 'Latin script', c = 0 },
	ki = { q = 'Q33587', n = 'Kikuyu', e = 'Gikuyu', w = 'Q8229', s = 'Latin script', c = 0 },
	kj = { q = 'Q1405077', n = 'Kwanyama', e = 'Kwanyama', w = 'Q8229', s = 'Latin script', c = 0 },
	kk = { q = 'Q9252', n = 'Kasachisch', e = 'Kazakh', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	kl = { q = 'Q25355', n = 'Grönländisch', e = 'Greenlandic', w = 'Q8229', s = 'Latin script', c = 0 },
	km = { q = 'Q9205', n = 'Khmer', e = 'Khmer', w = 'Q1054190', s = 'Khmer alphabet', c = 0 },
	kn = { q = 'Q33673', n = 'Kannada', e = 'Kannada', w = 'Q839666', s = 'Kannada alphabet', c = 0 },
	ko = { q = 'Q9176', n = 'Koreanisch', e = 'Korean', w = 'Q8222', s = 'Hangul', c = 0 },
	kr = { q = 'Q36094', n = 'Kanuri', e = 'Kanuri', w = 'Q8229', s = 'Latin script', c = 0 },
	ks = { q = 'Q33552', n = 'Kashmiri', e = 'Kashmiri', w = 'Q38592', s = 'Devanagari', c = 0 },
	ku = { q = 'Q36368', n = 'Kurdisch', e = 'Kurdish', w = 'Q8229', s = 'Latin script', c = 0 },
	kv = { q = 'Q36126', n = 'Komi', e = 'Komi', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	kw = { q = 'Q25289', n = 'Kornisch', e = 'Cornish', w = 'Q8229', s = 'Latin script', c = 0 },
	ky = { q = 'Q9255', n = 'Kirgisisch', e = 'Kyrgyz', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	lb = { q = 'Q9051', n = 'Luxemburgisch', e = 'Luxembourgish', w = 'Q8229', s = 'Latin script', c = 0 },
	lg = { q = 'Q33368', n = 'Luganda', e = 'Luganda', w = 'Q8229', s = 'Latin script', c = 0 },
	li = { q = 'Q102172', n = 'Limburgisch', e = 'Limburgish', w = 'Q8229', s = 'Latin script', c = 0 },
	ln = { q = 'Q36217', n = 'Lingála', e = 'Lingala', w = 'Q8229', s = 'Latin script', c = 0 },
	lo = { q = 'Q9211', n = 'Laotisch', e = 'Lao', w = 'Q1815229', s = 'Lao alphabet', c = 0 },
	lt = { q = 'Q9083', n = 'Litauisch', e = 'Lithuanian', w = 'Q8229', s = 'Latin script', c = 0 },
	lu = { q = 'Q36157', n = 'Kiluba', e = 'Luba-Katanga', w = 'Q8229', s = 'Latin script', c = 0 },
	lv = { q = 'Q9078', n = 'Lettisch', e = 'Latvian', w = 'Q8229', s = 'Latin script', c = 0 },
	mg = { q = 'Q7930', n = 'Malagasy', e = 'Malagasy', w = 'Q8229', s = 'Latin script', c = 0 },
	mh = { q = 'Q36280', n = 'Marshallesisch', e = 'Marshallese', w = 'Q8229', s = 'Latin script', c = 0 },
	mi = { q = 'Q36451', n = 'Maorisch', e = 'Māori', w = 'Q8229', s = 'Latin script', c = 0 },
	mk = { q = 'Q9296', n = 'Mazedonisch', e = 'Macedonian', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	ml = { q = 'Q36236', n = 'Malayalam', e = 'Malayalam', w = 'Q1164129', s = 'Malayalam script', c = 0 },
	mn = { q = 'Q9246', n = 'Mongolisch', e = 'Mongolian', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	mo = { q = 'Q36392', n = 'Moldawisch', e = 'Moldovan', w = 'Q8229', s = 'Latin script', c = 0 },
	mr = { q = 'Q1571', n = 'Marathi', e = 'Marathi', w = 'Q38592', s = 'Devanagari', c = 0 },
	ms = { q = 'Q9237', n = 'Malaiisch', e = 'Malay', w = 'Q8229', s = 'Latin script', c = 0 },
	mt = { q = 'Q9166', n = 'Maltesisch', e = 'Maltese', w = 'Q8229', s = 'Latin script', c = 0 },
	my = { q = 'Q9228', n = 'Birmanisch', e = 'Burmese', w = 'Q854968', s = 'Burmese alphabet', c = 0 },
	na = { q = 'Q13307', n = 'Nauruisch', e = 'Nauruan', w = 'Q8229', s = 'Latin script', c = 0 },
	nb = { q = 'Q25167', n = 'Bokmål', e = 'Bokmål', w = 'Q8229', s = 'Latin script', c = 0 },
	nd = { q = 'Q35613', n = 'Nord-Ndebele', e = 'Northern Ndebele', w = 'Q8229', s = 'Latin script', c = 0 },
	ne = { q = 'Q33823', n = 'Nepali', e = 'Nepali', w = 'Q38592', s = 'Devanagari', c = 0 },
	ng = { q = 'Q33900', n = 'Ndonga', e = 'Ndonga', w = 'Q8229', s = 'Latin script', c = 0 },
	nl = { q = 'Q7411', n = 'Niederländisch', e = 'Dutch', w = 'Q8229', s = 'Latin script', c = 52 },
	nn = { q = 'Q25164', n = 'Nynorsk', e = 'Nynorsk', w = 'Q8229', s = 'Latin script', c = 0 },
	no = { q = 'Q9043', n = 'Norwegisch', e = 'Norwegian', w = 'Q8229', s = 'Latin script', c = 0 },
	nr = { q = 'Q36785', n = 'Süd-Ndebele', e = 'Southern Ndebele', w = 'Q8229', s = 'Latin script', c = 0 },
	ny = { q = 'Q33273', n = 'Chichewa', e = 'Chewa', w = 'Q8229', s = 'Latin script', c = 0 },
	oc = { q = 'Q14185', n = 'Okzitanisch', e = 'Occitan', w = 'Q8229', s = 'Latin script', c = 0 },
	oj = { q = 'Q33875', n = 'Ojibwe', e = 'Ojibwe', w = 'Q8229', s = 'Latin script', c = 0 },
	om = { q = 'Q33864', n = 'Oromo', e = 'Oromo', w = 'Q8229', s = 'Latin script', c = 0 },
	['or'] = { q = 'Q33810', n = 'Oriya', e = 'Odia', w = 'Q1760127', s = 'Odia alphabet', c = 0 },
	['os'] = { q = 'Q33968', n = 'Ossetisch', e = 'Ossetian', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	pa = { q = 'Q58635', n = 'Panjabi', e = 'Punjabi', w = 'Q38592', s = 'Devanagari', c = 0 },
	pi = { q = 'Q36727', n = 'Pali', e = 'Pali', w = 'Q185083', s = 'Brahmi script', c = 0 },
	pl = { q = 'Q809', n = 'Polnisch', e = 'Polish', w = 'Q8229', s = 'Latin script', c = 54 },
	ps = { q = 'Q58680', n = 'Paschtunisch', e = 'Pashto', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 0 },
	pt = { q = 'Q5146', n = 'Portugiesisch', e = 'Portuguese', w = 'Q8229', s = 'Latin script', c = 52 },
	rm = { q = 'Q13199', n = 'Bünderromanisch', e = 'Romansh', w = 'Q8229', s = 'Latin script', c = 0 },
	rn = { q = 'Q33583', n = 'Kirundi', e = 'Kirundi', w = 'Q8229', s = 'Latin script', c = 0 },
	ro = { q = 'Q7913', n = 'Rumänisch', e = 'Romanian', w = 'Q8229', s = 'Latin script', c = 0 },
	ru = { q = 'Q7737', n = 'Russisch', e = 'Russian', w = 'Q8209', s = 'Cyrillic script', c = 93 },
	rw = { q = 'Q33573', n = 'Kinyarwanda', e = 'Kinyarwanda', w = 'Q8229', s = 'Latin script', c = 0 },
	sa = { q = 'Q11059', n = 'Sanskrit', e = 'Sanskrit', w = 'Q38592', s = 'Devanagari', c = 0 },
	sc = { q = 'Q33976', n = 'Sardisch', e = 'Sardinian', w = 'Q8229', s = 'Latin script', c = 0 },
	sd = { q = 'Q33997', n = 'Sindhi', e = 'Sindhi', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 0 },
	se = { q = 'Q33947', n = 'nordsamisch', e = 'Northern Sami', w = 'Q8229', s = 'Latin script', c = 0 },
	sg = { q = 'Q33954', n = 'Sango', e = 'Sango', w = 'Q8229', s = 'Latin script', c = 0 },
	si = { q = 'Q13267', n = 'Singhalesisch', e = 'Sinhala', w = 'Q1574992', s = 'Sinhala script', c = 0 },
	sk = { q = 'Q9058', n = 'Slowakisch', e = 'Slovak', w = 'Q8229', s = 'Latin script', c = 0 },
	sl = { q = 'Q9063', n = 'Slowenisch', e = 'Slovene', w = 'Q8229', s = 'Latin script', c = 0 },
	sm = { q = 'Q34011', n = 'Samoanisch', e = 'Samoan', w = 'Q8229', s = 'Latin script', c = 0 },
	sn = { q = 'Q34004', n = 'Shona', e = 'Shona', w = 'Q8229', s = 'Latin script', c = 0 },
	so = { q = 'Q13275', n = 'Somali', e = 'Somali', w = 'Q8229', s = 'Latin script', c = 0 },
	sq = { q = 'Q8748', n = 'Albanisch', e = 'Albanian', w = 'Q8229', s = 'Latin script', c = 0 },
	sr = { q = 'Q9299', n = 'Serbisch', e = 'Serbian', w = 'Q8209', s = 'Cyrillic script', c = 21 },
	['sr-me'] = { q = 'Q8821', n = 'Montenegrinisch', e = 'Montenegrin', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	ss = { q = 'Q34014', n = 'Siswati', e = 'Swazi', w = 'Q8229', s = 'Latin script', c = 0 },
	st = { q = 'Q34340', n = 'Sesotho', e = 'Sotho', w = 'Q8229', s = 'Latin script', c = 0 },
	su = { q = 'Q34002', n = 'Sunda', e = 'Sundanese', w = 'Q8229', s = 'Latin script', c = 0 },
	sv = { q = 'Q9027', n = 'Schwedisch', e = 'Swedish', w = 'Q8229', s = 'Latin script', c = 43 },
	sw = { q = 'Q7838', n = 'Swahili', e = 'Swahili', w = 'Q8229', s = 'Latin script', c = 0 },
	ta = { q = 'Q5885', n = 'Tamil', e = 'Tamil', w = 'Q26803', s = 'Tamil script', c = 0 },
	te = { q = 'Q8097', n = 'Telugu', e = 'Telugu', w = 'Q570450', s = 'Telugu script', c = 0 },
	tg = { q = 'Q9260', n = 'Tadschikisch', e = 'Tajik', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	th = { q = 'Q9217', n = 'Thailändisch', e = 'Thai', w = 'Q236376', s = 'Thai alphabet', c = 0 },
	ti = { q = 'Q34124', n = 'Tigrinya', e = 'Tigrinya', w = 'Q257634', s = "Ge'ez script" },
	tk = { q = 'Q9267', n = 'Turkmenisch', e = 'Turkmen', w = 'Q8229', s = 'Latin script', c = 0 },
	tl = { q = 'Q34057', n = 'Tagalog', e = 'Tagalog', w = 'Q8229', s = 'Latin script', c = 0 },
	tn = { q = 'Q34137', n = 'Setswana', e = 'Tswana', w = 'Q8229', s = 'Latin script', c = 0 },
	to = { q = 'Q34094', n = 'Tongaisch', e = 'Tongan', w = 'Q8229', s = 'Latin script', c = 0 },
	tr = { q = 'Q256', n = 'Türkisch', e = 'Turkish', w = 'Q8229', s = 'Latin script', c = 0 },
	ts = { q = 'Q34327', n = 'Xitsonga', e = 'Tsonga', w = 'Q8229', s = 'Latin script', c = 0 },
	tt = { q = 'Q25285', n = 'Tatarisch', e = 'Tatar', w = 'Q8209', s = 'Cyrillic script', c = 0 },
	tvl = { q = 'Q34055', n = 'Tuvaluisch', e = 'Tuvaluan', w = 'Q8229', s = 'Latin script', c = 0 },
	tw = { q = 'Q36850', n = 'Twi', e = 'Twi', w = 'Q8229', s = 'Latin script', c = 0 },
	ty = { q = 'Q34128', n = 'Tahitianisch', e = 'Tahitian', w = 'Q8229', s = 'Latin script', c = 0 },
	ug = { q = 'Q13263', n = 'Uigurisch', e = 'Uyghur', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 0 },
	uk = { q = 'Q8798', n = 'Ukrainisch', e = 'Ukrainian', w = 'Q8209', s = 'Cyrillic script', c = 23 },
	ur = { q = 'Q1617', n = 'Urdu', e = 'Urdu', w = 'Q8196', s = 'Arabic alphabet', d = 'rtl', c = 0 },
	uz = { q = 'Q9264', n = 'Usbekisch', e = 'Uzbek', w = 'Q8229', s = 'Latin script', c = 0 },
	ve = { q = 'Q32704', n = 'Tshivenda', e = 'Venda', w = 'Q8229', s = 'Latin script', c = 0 },
	vi = { q = 'Q9199', n = 'Vietnamesisch', e = 'Vietnamese', w = 'Q8229', s = 'Latin script', c = 41 },
	wa = { q = 'Q34219', n = 'Wallonisch', e = 'Walloon', w = 'Q8229', s = 'Latin script', c = 0 },
	wo = { q = 'Q34257', n = 'Wolof', e = 'Wolof', w = 'Q8229', s = 'Latin script', c = 0 },
	xh = { q = 'Q13218', n = 'IsiXhosa', e = 'Xhosa', w = 'Q33513', s = 'Hebrew alphabet', d = 'rtl', c = 0 },
	yi = { q = 'Q8641', n = 'Jiddisch', e = 'Yiddish', w = 'Q8229', s = 'Latin script', c = 0 },
	yo = { q = 'Q34311', n = 'Yoruba', e = 'Yoruba', w = 'Q8229', s = 'Latin script', c = 0 },
	za = { q = 'Q13216', n = 'Zhuang', e = 'Zhuang', w = 'Q8229', s = 'Latin script', c = 0 },
	zh = { q = 'Q7850', n = 'Chinesisch', e = 'Chinese', w = 'Q8201', s = 'Chinese characters', c = 50 },
	zu = { q = 'Q10179', n = 'IsiZulu', e = 'Zulu', w = 'Q8229', s = 'Latin script', c = 0 }
}

function lg.getProperty( lng, p )
	if not lng or lng == '' or not p or p == '' then
		return ''
	end

	local item = lg.lngProps[ lng ], hyphen
	if not item then
		hyphen = lng:find( '-' )
		if not hyphen or hyphen == 1 then
			return ''
		else
			item = lg.lngProps[ lng:sub( 1, hyphen - 1 ) ]
			if not item then
				return ''
			end
		end
	end
	return item[ p ] or ''
end

function lg.isR2L( lng )
	return lg.getProperty( lng, 'd' ) == 'rtl'
end

return lg