diff options
author | 2013-01-10 22:05:52 -0800 | |
---|---|---|
committer | 2013-01-10 22:05:52 -0800 | |
commit | 93fd1ac4fcf43001295151d62ad4733c37041c5a (patch) | |
tree | 6286393d243f359df3789efb18be894b26b6ca8a /java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java | |
parent | 9f962af541edf66cf582585a93660ab670feb75d (diff) | |
parent | d8590857bdff7f30a93af07aef0362d9f7460a5a (diff) | |
download | latinime-93fd1ac4fcf43001295151d62ad4733c37041c5a.tar.gz latinime-93fd1ac4fcf43001295151d62ad4733c37041c5a.tar.xz latinime-93fd1ac4fcf43001295151d62ad4733c37041c5a.zip |
am d8590857: Fix spell checker subtype list.
* commit 'd8590857bdff7f30a93af07aef0362d9f7460a5a':
Fix spell checker subtype list.
Diffstat (limited to 'java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java b/java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java index 470943be1..6581978c9 100644 --- a/java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java +++ b/java/src/com/android/inputmethod/latin/spellcheck/AndroidWordLevelSpellCheckerSession.java @@ -143,8 +143,17 @@ public abstract class AndroidWordLevelSpellCheckerSession extends Session { case AndroidSpellCheckerService.SCRIPT_CYRILLIC: // All Cyrillic characters are in the 400~52F block. There are some in the upper // Unicode range, but they are archaic characters that are not used in modern - // russian and are not used by our dictionary. + // Russian and are not used by our dictionary. return codePoint >= 0x400 && codePoint <= 0x52F && Character.isLetter(codePoint); + case AndroidSpellCheckerService.SCRIPT_GREEK: + // Greek letters are either in the 370~3FF range (Greek & Coptic), or in the + // 1F00~1FFF range (Greek extended). Our dictionary contains both sort of characters. + // Our dictionary also contains a few words with 0xF2; it would be best to check + // if that's correct, but a Google search does return results for these words so + // they are probably okay. + return (codePoint >= 0x370 && codePoint <= 0x3FF) + || (codePoint >= 0x1F00 && codePoint <= 0x1FFF) + || codePoint == 0xF2; default: // Should never come here throw new RuntimeException("Impossible value of script: " + script); |