GUI: default for often used languages from Wikipedia's languages by native speakers

The prior selection was pretty Western-centric with a couple of
additions from Asia. However, there are so many more languages, and
for a lot of them there are many more native speakers than for those
which were on the list before this change.

The new list simply mirrors Wikipedia's "List of languages by number
of native speakers" found at
https://en.wikipedia.org/wiki/List_of_languages_by_number_of_native_speakers

Additionally the GUI will only show the often used languages in
drop-down boxes by default.

Both can still be changed in the preferences.
This commit is contained in:
Moritz Bunkus 2019-08-12 18:32:06 +02:00
parent 79803bf65d
commit a6fd6a05e9
No known key found for this signature in database
GPG Key ID: 74AF00ADF2E32C85
3 changed files with 76 additions and 2 deletions

View File

@ -1,3 +1,12 @@
# Version ?
## New features and enhancements
* MKVToolNix GUI: the list of often used languages now contains those from
Wikipedia's "List of languages by native speakers" by default. Also by
default only those languages will be shown in the language drop-down boxes.
# Version 36.0.0 "Is That Jazz?" 2019-08-10
## New features and enhancements

View File

@ -520,7 +520,72 @@ static std::unordered_map<std::string, std::string> s_deprecated_1_and_2_codes{
{ "mol", "rum" },
};
std::vector<std::string> const g_popular_language_codes{ "chi", "dut", "eng", "fin", "fre", "ger", "ita", "jpn", "mul", "nor", "por", "rus", "spa", "swe", "und", "zxx" };
std::vector<std::string> const g_popular_language_codes{
// Derived from the list of spoken languages sorted by native speakers available at
// https://en.wikipedia.org/wiki/List_of_languages_by_number_of_native_speakers
"amh",
"ara",
"aze",
"ben",
"bho",
"bur",
"ceb",
"khm",
"chi",
"cze",
"dut",
"eng",
"fre",
"ger",
"gre",
"guj",
"hau",
"hin",
"hun",
"ibo",
"ind",
"ita",
"jpn",
"jav",
"kan",
"kaz",
"kin",
"kor",
"kur",
"mag",
"mai",
"may",
"mal",
"mar",
"nep",
"ori",
"pan",
"per",
"pol",
"por",
"pus",
"rum",
"run",
"rus",
"snd",
"sin",
"som",
"spa",
"sun",
"tam",
"tel",
"tha",
"tur",
"ukr",
"urd",
"uzb",
"vie",
"yor",
"zul",
// "Undetermined" & "No linguistic content"
"und", "zxx",
};
bool
is_valid_iso639_2_code(std::string const &iso639_2_code) {

View File

@ -271,7 +271,7 @@ Settings::load() {
m_oftenUsedCountries = reg.value(s_valOftenUsedCountries).toStringList();
m_oftenUsedCharacterSets = reg.value(s_valOftenUsedCharacterSets).toStringList();
m_oftenUsedLanguagesOnly = reg.value(s_valOftenUsedLanguagesOnly, false).toBool();;
m_oftenUsedLanguagesOnly = reg.value(s_valOftenUsedLanguagesOnly, true).toBool();;
m_oftenUsedCountriesOnly = reg.value(s_valOftenUsedCountriesOnly, false).toBool();;
m_oftenUsedCharacterSetsOnly = reg.value(s_valOftenUsedCharacterSetsOnly, false).toBool();;