Home
last modified time | relevance | path

Searched refs:codePoint (Results 1 – 25 of 41) sorted by relevance

12

/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/utils/
DScriptUtils.java84 public static boolean isLetterPartOfScript(final int codePoint, final int scriptId) { in isLetterPartOfScript() argument
93 return (codePoint >= 0x600 && codePoint <= 0x6FF) in isLetterPartOfScript()
94 || (codePoint >= 0x750 && codePoint <= 0x7BF) in isLetterPartOfScript()
95 || (codePoint >= 0x8A0 && codePoint <= 0x8FF) in isLetterPartOfScript()
96 || (codePoint >= 0xFB50 && codePoint <= 0xFDFF) in isLetterPartOfScript()
97 || (codePoint >= 0xFE70 && codePoint <= 0xFEFF); in isLetterPartOfScript()
102 return (codePoint >= 0x530 && codePoint <= 0x58F in isLetterPartOfScript()
103 || codePoint >= 0xFB13 && codePoint <= 0xFB17); in isLetterPartOfScript()
106 return (codePoint >= 0x980 && codePoint <= 0x9FF); in isLetterPartOfScript()
111 return codePoint >= 0x400 && codePoint <= 0x52F && Character.isLetter(codePoint); in isLetterPartOfScript()
[all …]
DStringUtils.java57 public static String newSingleCodePointString(int codePoint) { in newSingleCodePointString() argument
58 if (Character.charCount(codePoint) == 1) { in newSingleCodePointString()
61 return String.valueOf((char) codePoint); in newSingleCodePointString()
64 return new String(Character.toChars(codePoint)); in newSingleCodePointString()
210 final int codePoint = Character.codePointAt(charSequence, index); in copyCodePointsAndReturnCodePointCount() local
213 destination[destIndex] = downCase ? Character.toLowerCase(codePoint) : codePoint; in copyCodePointsAndReturnCodePointCount()
263 final int codePoint = text.codePointAt(index); in getCapitalizationType() local
264 if (Character.isUpperCase(codePoint)) { in getCapitalizationType()
267 } else if (Character.isLetter(codePoint)) { in getCapitalizationType()
284 final int codePoint = text.codePointAt(i); in isIdenticalAfterUpcase() local
[all …]
DDictionaryInfoUtils.java96 private static boolean isFileNameCharacter(int codePoint) { in isFileNameCharacter() argument
97 if (codePoint >= 0x30 && codePoint <= 0x39) return true; // Digit in isFileNameCharacter()
98 if (codePoint >= 0x41 && codePoint <= 0x5A) return true; // Uppercase in isFileNameCharacter()
99 if (codePoint >= 0x61 && codePoint <= 0x7A) return true; // Lowercase in isFileNameCharacter()
100 return codePoint == '_'; // Underscore in isFileNameCharacter()
117 final int codePoint = name.codePointAt(i); in replaceFileNameDangerousCharacters() local
118 if (DictionaryInfoUtils.isFileNameCharacter(codePoint)) { in replaceFileNameDangerousCharacters()
119 sb.appendCodePoint(codePoint); in replaceFileNameDangerousCharacters()
122 codePoint)); in replaceFileNameDangerousCharacters() local
149 final int codePoint = fname.codePointAt(i); in getWordListIdFromFileName() local
[all …]
DCapsModeUtils.java73 private static boolean isStartPunctuation(final int codePoint) { in isStartPunctuation() argument
74 return (codePoint == Constants.CODE_DOUBLE_QUOTE || codePoint == Constants.CODE_SINGLE_QUOTE in isStartPunctuation()
75 || codePoint == Constants.CODE_INVERTED_QUESTION_MARK in isStartPunctuation()
76 || codePoint == Constants.CODE_INVERTED_EXCLAMATION_MARK in isStartPunctuation()
77 || Character.getType(codePoint) == Character.START_PUNCTUATION); in isStartPunctuation()
/packages/inputmethods/LatinIME/native/jni/src/
Ddefines.h54 const int codePoint = source[si++]; in intArrayToCharArray() local
55 if (codePoint < 0x7F) { // One byte in intArrayToCharArray()
56 dest[di++] = codePoint; in intArrayToCharArray()
57 } else if (codePoint < 0x7FF) { // Two bytes in intArrayToCharArray()
59 dest[di++] = 0xC0 + (codePoint >> 6); in intArrayToCharArray()
60 dest[di++] = 0x80 + (codePoint & 0x3F); in intArrayToCharArray()
61 } else if (codePoint < 0xFFFF) { // Three bytes in intArrayToCharArray()
63 dest[di++] = 0xE0 + (codePoint >> 12); in intArrayToCharArray()
64 dest[di++] = 0x80 + ((codePoint >> 6) & 0x3F); in intArrayToCharArray()
65 dest[di++] = 0x80 + (codePoint & 0x3F); in intArrayToCharArray()
[all …]
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/utils/
Dbyte_array_utils.h178 int codePoint = readCodePointAndAdvancePosition(buffer, pos); in readStringAndAdvancePosition() local
179 while (NOT_A_CODE_POINT != codePoint && length < maxLength) { in readStringAndAdvancePosition()
180 outBuffer[length++] = codePoint; in readStringAndAdvancePosition()
181 codePoint = readCodePointAndAdvancePosition(buffer, pos); in readStringAndAdvancePosition()
190 int codePoint = readCodePointAndAdvancePosition(buffer, pos); in advancePositionToBehindString() local
191 while (NOT_A_CODE_POINT != codePoint && length < maxLength) { in advancePositionToBehindString()
192 codePoint = readCodePointAndAdvancePosition(buffer, pos); in advancePositionToBehindString()
205 const int codePoint = codePoints[i]; in writeCodePointsAndAdvancePosition() local
206 if (codePoint == NOT_A_CODE_POINT || codePoint == CHARACTER_ARRAY_TERMINATOR) { in writeCodePointsAndAdvancePosition()
208 } else if (codePoint < MINIMUM_ONE_BYTE_CHARACTER_VALUE in writeCodePointsAndAdvancePosition()
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/inputlogic/
DInputLogic.java803 final int codePoint = event.mCodePoint; in handleNonSpecialCharacterEvent() local
805 if (inputTransaction.mSettingsValues.isWordSeparator(codePoint) in handleNonSpecialCharacterEvent()
806 || Character.getType(codePoint) == Character.OTHER_SYMBOL) { in handleNonSpecialCharacterEvent()
831 final int codePoint = event.mCodePoint; in handleNonSeparatorEvent() local
841 && !settingsValues.isWordConnector(codePoint)) { in handleNonSeparatorEvent()
863 && settingsValues.isWordCodePoint(codePoint) in handleNonSeparatorEvent()
874 isComposingWord = !settingsValues.mSpacingAndPunctuations.isWordConnector(codePoint); in handleNonSeparatorEvent()
895 sendKeyCodePoint(settingsValues, codePoint); in handleNonSeparatorEvent()
909 final int codePoint = event.mCodePoint; in handleSeparatorEvent() local
913 final boolean shouldAvoidSendingCode = Constants.CODE_SPACE == codePoint in handleSeparatorEvent()
[all …]
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/makedict/
DBinaryDictDecoderUtils.java165 for (int codePoint : codePoints) { in writeCharArray()
166 if (1 == getCharSize(codePoint)) { in writeCharArray()
167 buffer[index++] = (byte)codePoint; in writeCharArray()
169 buffer[index++] = (byte)(0xFF & (codePoint >> 16)); in writeCharArray()
170 buffer[index++] = (byte)(0xFF & (codePoint >> 8)); in writeCharArray()
171 buffer[index++] = (byte)(0xFF & codePoint); in writeCharArray()
191 final int codePoint = word.codePointAt(i); in writeString() local
192 if (1 == getCharSize(codePoint)) { in writeString()
193 buffer[index++] = (byte)codePoint; in writeString()
195 buffer[index++] = (byte)(0xFF & (codePoint >> 16)); in writeString()
[all …]
DFusionDictionary.java304 int codePoint = Character.codePointAt(characters, 0); in getCodePoints() local
306 for (int srci = Character.charCount(codePoint); in getCodePoints()
307 srci < length; srci += Character.charCount(codePoint), ++dsti) { in getCodePoints()
308 codePoints[dsti] = codePoint; in getCodePoints()
309 codePoint = Character.codePointAt(characters, srci); in getCodePoints()
311 codePoints[dsti] = codePoint; in getCodePoints()
/packages/apps/ContactsCommon/src/com/android/contacts/common/util/
DSearchUtil.java103 final int codePoint = Character.codePointAt(substring, i); in contains() local
104 substringCodePoints[substringLength] = codePoint; in contains()
106 i += Character.charCount(codePoint); in contains()
144 final int codePoint = line.codePointAt(index); in findNextTokenStart() local
145 if (!Character.isLetterOrDigit(codePoint)) { in findNextTokenStart()
148 index += Character.charCount(codePoint); in findNextTokenStart()
156 final int codePoint = line.codePointAt(index); in findNextTokenStart() local
157 if (Character.isLetterOrDigit(codePoint)) { in findNextTokenStart()
160 index += Character.charCount(codePoint); in findNextTokenStart()
176 int codePoint = query.codePointAt(start); in cleanStartAndEndOfSearchQuery() local
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/event/
DMyanmarReordering.java73 private static boolean isConsonant(final int codePoint) { in isConsonant() argument
74 return (codePoint >= 0x1000 && codePoint <= 0x1020) || 0x103F == codePoint; in isConsonant()
88 private static boolean isMedial(final int codePoint) { in isMedial() argument
89 return Arrays.binarySearch(MEDIAL_LIST, codePoint) >= 0; in isMedial()
92 private static boolean isConsonantOrMedial(final int codePoint) { in isConsonantOrMedial() argument
93 return isConsonant(codePoint) || isMedial(codePoint); in isConsonantOrMedial()
136 final int codePoint = newEvent.mCodePoint; in processEvent() local
137 if (VOWEL_E == codePoint) { in processEvent()
153 } if (isConsonant(codePoint)) { in processEvent()
184 } else if (isMedial(codePoint)) { in processEvent()
DEvent.java109 private Event(final int type, final CharSequence text, final int codePoint, final int keyCode, in Event() argument
114 mCodePoint = codePoint; in Event()
136 public static Event createSoftwareKeypressEvent(final int codePoint, final int keyCode, in createSoftwareKeypressEvent() argument
138 return new Event(EVENT_TYPE_INPUT_KEYPRESS, null /* text */, codePoint, keyCode, x, y, in createSoftwareKeypressEvent()
142 public static Event createHardwareKeypressEvent(final int codePoint, final int keyCode, in createHardwareKeypressEvent() argument
144 return new Event(EVENT_TYPE_INPUT_KEYPRESS, null /* text */, codePoint, keyCode, in createHardwareKeypressEvent()
150 public static Event createDeadEvent(final int codePoint, final int keyCode, final Event next) { in createDeadEvent() argument
152 return new Event(EVENT_TYPE_INPUT_KEYPRESS, null /* text */, codePoint, keyCode, in createDeadEvent()
164 public static Event createEventForCodePointFromUnknownSource(final int codePoint) { in createEventForCodePointFromUnknownSource() argument
166 return new Event(EVENT_TYPE_INPUT_KEYPRESS, null /* text */, codePoint, NOT_A_KEY_CODE, in createEventForCodePointFromUnknownSource()
[all …]
/packages/apps/UnifiedEmail/src/com/google/android/mail/common/base/
DStringUtil.java1523 for (int codePoint, charCount, i = 0; i < len; i += charCount) { in escapeStringBody()
1524 codePoint = Character.codePointAt(plainText, i); in escapeStringBody()
1525 charCount = Character.charCount(codePoint); in escapeStringBody()
1527 if (!shouldEscapeChar(codePoint, escapeToAscii, jsEscapingMode)) { in escapeStringBody()
1533 switch (codePoint) { in escapeStringBody()
1541 if (jsEscapingMode == JsEscapingMode.JSON && '\'' == codePoint) { in escapeStringBody()
1544 out.append((char) codePoint); in escapeStringBody()
1547 out.append('\\').append((char) codePoint); in escapeStringBody()
1552 if (codePoint >= 0x100 || jsEscapingMode == JsEscapingMode.JSON) { in escapeStringBody()
1553 appendHexJavaScriptRepresentation(codePoint, out); in escapeStringBody()
[all …]
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/layout/
Dproximity_info_state.cpp170 const int inputIndex, const int codePoint) const { in getPointToKeyLength()
171 const int keyId = mProximityInfo->getKeyIndexOf(codePoint); in getPointToKeyLength()
176 if (CharUtils::isIntentionalOmissionCodePoint(codePoint)) { in getPointToKeyLength()
200 ProximityType ProximityInfoState::getProximityType(const int index, const int codePoint, in getProximityType() argument
204 const int baseLowerC = CharUtils::toBaseLowerCase(codePoint); in getProximityType()
208 if (firstCodePoint == baseLowerC || firstCodePoint == codePoint) { in getProximityType()
225 || currentCodePoints[j] == codePoint); in getProximityType()
240 || currentCodePoints[j] == codePoint); in getProximityType()
254 ProximityType ProximityInfoState::getProximityTypeG(const int index, const int codePoint) const { in getProximityTypeG()
262 sampledSearchKeyVectorsSize, codePoint); in getProximityTypeG()
[all …]
/packages/providers/ContactsProvider/src/com/android/providers/contacts/
DContactLocaleUtils.java128 int codePoint = Character.codePointAt(name, offset); in getBucketIndex() local
131 if (Character.isDigit(codePoint)) { in getBucketIndex()
134 } else if (!Character.isSpaceChar(codePoint) && in getBucketIndex()
135 codePoint != '+' && codePoint != '(' && in getBucketIndex()
136 codePoint != ')' && codePoint != '.' && in getBucketIndex()
137 codePoint != '-' && codePoint != '#') { in getBucketIndex()
140 offset += Character.charCount(codePoint); in getBucketIndex()
255 private static boolean isChineseOrJapanese(int codePoint) { in isChineseOrJapanese() argument
256 return CJ_BLOCKS.contains(UnicodeBlock.of(codePoint)); in isChineseOrJapanese()
DNameSplitter.java987 int codePoint = Character.codePointAt(name, offset); in guessFullNameStyle() local
988 if (Character.isLetter(codePoint)) { in guessFullNameStyle()
989 UnicodeBlock unicodeBlock = UnicodeBlock.of(codePoint); in guessFullNameStyle()
996 return guessCJKNameStyle(name, offset + Character.charCount(codePoint)); in guessFullNameStyle()
1009 offset += Character.charCount(codePoint); in guessFullNameStyle()
1017 int codePoint = Character.codePointAt(name, offset); in guessCJKNameStyle() local
1018 if (Character.isLetter(codePoint)) { in guessCJKNameStyle()
1019 UnicodeBlock unicodeBlock = UnicodeBlock.of(codePoint); in guessCJKNameStyle()
1027 offset += Character.charCount(codePoint); in guessCJKNameStyle()
1072 int codePoint = Character.codePointAt(name, offset); in guessPhoneticNameStyle() local
[all …]
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/
DInputTestsBase.java257 protected void typeInternal(final int codePoint, final boolean isKeyRepeat) { in typeInternal() argument
265 final Key key = mKeyboard.getKey(codePoint); in typeInternal()
267 mLatinIME.onCodeInput(codePoint, Constants.NOT_A_COORDINATE, Constants.NOT_A_COORDINATE, in typeInternal()
272 mLatinIME.onCodeInput(codePoint, x, y, isKeyRepeat); in typeInternal()
278 protected void type(final int codePoint) { in type() argument
279 typeInternal(codePoint, false /* isKeyRepeat */); in type()
282 protected void repeatKey(final int codePoint) { in repeatKey() argument
283 typeInternal(codePoint, true /* isKeyRepeat */); in repeatKey()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/accessibility/
DKeyCodeDescriptionMapper.java262 public String getDescriptionForCodePoint(final Context context, final int codePoint) { in getDescriptionForCodePoint() argument
264 final int index = mKeyCodeMap.indexOfKey(codePoint); in getDescriptionForCodePoint()
268 final String accentedLetter = getSpokenAccentedLetterDescription(context, codePoint); in getDescriptionForCodePoint()
273 final String unsupportedSymbol = getSpokenSymbolDescription(context, codePoint); in getDescriptionForCodePoint()
277 final String emojiDescription = getSpokenEmojiDescription(context, codePoint); in getDescriptionForCodePoint()
281 if (Character.isDefined(codePoint) && !Character.isISOControl(codePoint)) { in getDescriptionForCodePoint()
282 return StringUtils.newSingleCodePointString(codePoint); in getDescriptionForCodePoint()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
DRichInputConnection.java629 private static boolean isPartOfCompositionForScript(final int codePoint, in isPartOfCompositionForScript() argument
632 return spacingAndPunctuations.isWordConnector(codePoint) in isPartOfCompositionForScript()
634 || (!spacingAndPunctuations.isWordSeparator(codePoint) in isPartOfCompositionForScript()
635 && ScriptUtils.isLetterPartOfScript(codePoint, scriptId)); in isPartOfCompositionForScript()
662 final int codePoint = Character.codePointBefore(before, startIndexInBefore); in getWordRangeAtCursor() local
663 if (!isPartOfCompositionForScript(codePoint, spacingAndPunctuations, scriptId)) { in getWordRangeAtCursor()
667 if (Character.isSupplementaryCodePoint(codePoint)) { in getWordRangeAtCursor()
675 final int codePoint = Character.codePointAt(after, endIndexInAfter); in getWordRangeAtCursor() local
676 if (!isPartOfCompositionForScript(codePoint, spacingAndPunctuations, scriptId)) { in getWordRangeAtCursor()
679 if (Character.isSupplementaryCodePoint(codePoint)) { in getWordRangeAtCursor()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/spellcheck/
DSentenceLevelAdapter.java93 final int codePoint = Character.codePointAt(sequence, index); in getEndOfWord()
94 if (mSpacingAndPunctuations.isWordSeparator(codePoint)) { in getEndOfWord()
97 if (Constants.CODE_PERIOD == codePoint) { in getEndOfWord()
109 index += Character.charCount(codePoint); in getEndOfWord()
121 final int codePoint = Character.codePointAt(sequence, index);
122 if (!mSpacingAndPunctuations.isWordSeparator(codePoint)) {
125 index += Character.charCount(codePoint);
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/dicnode/
Ddic_node.h130 const int codePoint = in initAsPassingChild() local
133 mDicNodeProperties.init(&parentDicNode->mDicNodeProperties, codePoint); in initAsPassingChild()
345 const int codePoint = mDicNodeProperties.getDicNodeCodePoint(); in getNodeCodePoint() local
349 return codePoint; in getNodeCodePoint()
351 return DigraphUtils::getDigraphCodePointForIndex(codePoint, digraphIndex); in getNodeCodePoint()
450 const int codePoint = mDicNodeState.mDicNodeStateOutput.getCurrentWordCodePointAt(i); in compare() local
453 if (codePoint != rightCodePoint) { in compare()
454 return rightCodePoint > codePoint; in compare()
/packages/inputmethods/LatinIME/native/jni/src/utils/
Dchar_utils.h58 static AK_FORCE_INLINE bool isIntentionalOmissionCodePoint(const int codePoint) { in isIntentionalOmissionCodePoint() argument
60 return codePoint == KEYCODE_SINGLE_QUOTE || codePoint == KEYCODE_HYPHEN_MINUS; in isIntentionalOmissionCodePoint()
90 static AK_FORCE_INLINE int isInUnicodeSpace(const int codePoint) { in isInUnicodeSpace() argument
91 return codePoint >= MIN_UNICODE_CODE_POINT && codePoint <= MAX_UNICODE_CODE_POINT; in isInUnicodeSpace()
Djni_data_utils.h77 const int codePoint = codePoints[i]; in outputCodePoints() local
78 int codePointToOutput = codePoint; in outputCodePoints()
79 if (!CharUtils::isInUnicodeSpace(codePoint)) { in outputCodePoints()
80 if (codePoint == CODE_POINT_BEGINNING_OF_SENTENCE) { in outputCodePoints()
85 } else if (codePoint >= 0x01 && codePoint <= 0x1F) { in outputCodePoints()
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/dictionary/
Ddictionary_utils.cpp44 const int codePoint = CharUtils::toBaseLowerCase(codePoints[i]); in getMaxProbabilityOfExactMatches() local
46 if (dicNode.isInDigraph() && dicNode.getNodeCodePoint() == codePoint) { in getMaxProbabilityOfExactMatches()
51 processChildDicNodes(dictionaryStructurePolicy, codePoint, &dicNode, &next); in getMaxProbabilityOfExactMatches()
76 const int codePoint = CharUtils::toBaseLowerCase(childDicNode->getNodeCodePoint()); in processChildDicNodes() local
77 if (inputCodePoint == codePoint) { in processChildDicNodes()
88 if (childDicNode->getNodeCodePoint() == codePoint) { in processChildDicNodes()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/internal/
DCodesArrayParser.java61 final int codePoint = Integer.parseInt(codeInHex, BASE_HEX); in parseLabel() local
62 sb.appendCodePoint(codePoint); in parseLabel()
102 final int codePoint = Integer.parseInt(codeInHex, BASE_HEX); in parseOutputText() local
103 sb.appendCodePoint(codePoint); in parseOutputText()

12