Commit c6e9ccf2 authored by krb's avatar krb Committed by Commit bot

Spellchecking: Added use of Persian dictionary

And see codereview/1810993003

BUG=565069, 568673

Review URL: https://codereview.chromium.org/1814503003

Cr-Commit-Position: refs/heads/master@{#383908}
parent b3435f53
...@@ -138,7 +138,7 @@ deps = { ...@@ -138,7 +138,7 @@ deps = {
Var('chromium_git') + '/chromium/deps/icu.git' + '@' + '0d572d65aae621e13d6863fe470c9c8cee71043d', Var('chromium_git') + '/chromium/deps/icu.git' + '@' + '0d572d65aae621e13d6863fe470c9c8cee71043d',
'src/third_party/hunspell_dictionaries': 'src/third_party/hunspell_dictionaries':
Var('chromium_git') + '/chromium/deps/hunspell_dictionaries.git' + '@' + 'c106afdcec5d3de2622e19f1b3294c47bbd8bd72', Var('chromium_git') + '/chromium/deps/hunspell_dictionaries.git' + '@' + 'b53f0de2762f982117be3bd986a221cee2f6769c',
'src/third_party/safe_browsing/testing': 'src/third_party/safe_browsing/testing':
Var('chromium_git') + '/external/google-safe-browsing/testing.git' + '@' + '9d7e8064f3ca2e45891470c9b5b1dce54af6a9d6', Var('chromium_git') + '/external/google-safe-browsing/testing.git' + '@' + '9d7e8064f3ca2e45891470c9b5b1dce54af6a9d6',
......
...@@ -38,12 +38,13 @@ static const LanguageRegion g_supported_spellchecker_languages[] = { ...@@ -38,12 +38,13 @@ static const LanguageRegion g_supported_spellchecker_languages[] = {
{"da", "da-DK"}, {"da", "da-DK"},
{"de", "de-DE"}, {"de", "de-DE"},
{"el", "el-GR"}, {"el", "el-GR"},
{"en-AU", "en-AU"}, {"en-AU", "en-GB"},
{"en-CA", "en-CA"}, {"en-CA", "en-CA"},
{"en-GB", "en-GB"}, {"en-GB", "en-GB"},
{"en-US", "en-US"}, {"en-US", "en-US"},
{"es", "es-ES"}, {"es", "es-ES"},
{"et", "et-EE"}, {"et", "et-EE"},
{"fa", "fa-IR"},
{"fo", "fo-FO"}, {"fo", "fo-FO"},
{"fr", "fr-FR"}, {"fr", "fr-FR"},
{"he", "he-IL"}, {"he", "he-IL"},
...@@ -113,13 +114,14 @@ base::FilePath GetVersionedFileName(const std::string& input_language, ...@@ -113,13 +114,14 @@ base::FilePath GetVersionedFileName(const std::string& input_language,
// crash. // crash.
{"tg-TG", "-5-0"}, // Mar 4, 2014: Add Tajik dictionary. {"tg-TG", "-5-0"}, // Mar 4, 2014: Add Tajik dictionary.
// Oct 28, 2014: Update from upstream, add new words. // March 2016: Update from upstream
{"en-AU", "-4-0"}, {"en-AU", "-7-0"},
{"en-GB", "-4-0"}, {"en-CA", "-7-0"},
{"en-GB", "-7-0"},
{"en-US", "-7-0"},
// March 10, 2015: Update from upstream, enable typographical apostrophe. // March 2016: Initial check-in of Persian
{"en-CA", "-6-1"}, {"fa-IR", "-7-0"},
{"en-US", "-6-1"},
}; };
// Generate the bdict file name using default version string or special // Generate the bdict file name using default version string or special
......
...@@ -504,6 +504,21 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) { ...@@ -504,6 +504,21 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) {
"af-ZA", "af-ZA",
L"Google se missie is om die w\x00EAreld se inligting te organiseer en " L"Google se missie is om die w\x00EAreld se inligting te organiseer en "
L"dit bruikbaar en toeganklik te maak." L"dit bruikbaar en toeganklik te maak."
}, {
// Bulgarian
"bg-BG",
L"\x041c\x0438\x0441\x0438\x044f\x0442\x0430 "
L"\x043d\x0430 Google \x0435 \x0434\x0430 \x043e"
L"\x0440\x0433\x0430\x043d\x0438\x0437\x0438\x0440"
L"\x0430 \x0441\x0432\x0435\x0442\x043e\x0432"
L"\x043d\x0430\x0442\x0430 \x0438\x043d\x0444"
L"\x043e\x0440\x043c\x0430\x0446\x0438\x044f "
L"\x0438 \x0434\x0430 \x044f \x043d"
L"\x0430\x043f\x0440\x0430\x0432\x0438 \x0443"
L"\x043d\x0438\x0432\x0435\x0440\x0441\x0430\x043b"
L"\x043d\x043e \x0434\x043e\x0441\x0442\x044a"
L"\x043f\x043d\x0430 \x0438 \x043f\x043e"
L"\x043b\x0435\x0437\x043d\x0430."
}, { }, {
// Catalan // Catalan
"ca-ES", "ca-ES",
...@@ -561,21 +576,6 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) { ...@@ -561,21 +576,6 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) {
"en-US", "en-US",
L"Google's mission is to organize the world's information and make it " L"Google's mission is to organize the world's information and make it "
L"universally accessible and useful." L"universally accessible and useful."
}, {
// Bulgarian
"bg-BG",
L"\x041c\x0438\x0441\x0438\x044f\x0442\x0430 "
L"\x043d\x0430 Google \x0435 \x0434\x0430 \x043e"
L"\x0440\x0433\x0430\x043d\x0438\x0437\x0438\x0440"
L"\x0430 \x0441\x0432\x0435\x0442\x043e\x0432"
L"\x043d\x0430\x0442\x0430 \x0438\x043d\x0444"
L"\x043e\x0440\x043c\x0430\x0446\x0438\x044f "
L"\x0438 \x0434\x0430 \x044f \x043d"
L"\x0430\x043f\x0440\x0430\x0432\x0438 \x0443"
L"\x043d\x0438\x0432\x0435\x0440\x0441\x0430\x043b"
L"\x043d\x043e \x0434\x043e\x0441\x0442\x044a"
L"\x043f\x043d\x0430 \x0438 \x043f\x043e"
L"\x043b\x0435\x0437\x043d\x0430."
}, { }, {
// Spanish // Spanish
"es-ES", "es-ES",
...@@ -589,6 +589,11 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) { ...@@ -589,6 +589,11 @@ TEST_F(SpellCheckTest, MAYBE_SpellCheckText) {
// L"Google'ile " - to be added. // L"Google'ile " - to be added.
L"\x00FClesanne on korraldada maailma teavet ja teeb selle " L"\x00FClesanne on korraldada maailma teavet ja teeb selle "
L"k\x00F5igile k\x00E4ttesaadavaks ja kasulikuks.", L"k\x00F5igile k\x00E4ttesaadavaks ja kasulikuks.",
}, {
// Persian
"fa",
L"\x0686\x0647 \x0637\x0648\x0631 \x0622\x06cc\x0627 \x0634\x0645\x0627 "
L"\x0627\x06cc\x0631\x0627\x0646\x06cc \x0647\x0633\x062a\x06cc\x062f"
}, { }, {
// Faroese // Faroese
"fo-FO", "fo-FO",
...@@ -874,6 +879,10 @@ TEST_F(SpellCheckTest, MisspelledWords) { ...@@ -874,6 +879,10 @@ TEST_F(SpellCheckTest, MisspelledWords) {
// A misspelled word for Greek. // A misspelled word for Greek.
"el-GR", "el-GR",
L"\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1", L"\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1\x03B1",
}, {
// A misspelled word for Persian.
"fa",
L"\x06cc\x06a9\x06cc\x0634\x0627\x0646",
}, { }, {
// A misspelled word for Hebrew // A misspelled word for Hebrew
"he-IL", "he-IL",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment