ICU-4189 Remove some dependencies on the conversion API.
X-SVN-Rev: 16915
This commit is contained in:
parent
db0f035859
commit
c4d892bdd7
@ -1463,7 +1463,7 @@ UBool Transliterator::initializeRegistry() {
|
||||
for (row = 0; row < maxRows; row++) {
|
||||
colBund = ures_getByIndex(transIDs, row, 0, &status);
|
||||
if (U_SUCCESS(status)) {
|
||||
UnicodeString id(ures_getKey(colBund));
|
||||
UnicodeString id(ures_getKey(colBund), -1, US_INV);
|
||||
UResourceBundle* res = ures_getNextResource(colBund, NULL, &status);
|
||||
const char* typeStr = ures_getKey(res);
|
||||
UChar type;
|
||||
|
@ -218,7 +218,7 @@ Spec::Spec(const UnicodeString& theSpec) : top(theSpec) {
|
||||
UScriptCode script[capacity]={USCRIPT_INVALID_CODE};
|
||||
int32_t num = uscript_getCode(topch,script,capacity, &status);
|
||||
if (num > 0 && script[0] != USCRIPT_INVALID_CODE) {
|
||||
scriptName = UnicodeString(uscript_getName(script[0]), "");
|
||||
scriptName = UnicodeString(uscript_getName(script[0]), -1, US_INV);
|
||||
}
|
||||
|
||||
// Canonicalize top
|
||||
|
@ -98,7 +98,7 @@ void UnicodeNameTransliterator::handleTransliterate(Replaceable& text, UTransPos
|
||||
status = U_ZERO_ERROR;
|
||||
if ((len = u_charName(c, U_EXTENDED_CHAR_NAME, buf, maxLen, &status)) >0 && !U_FAILURE(status)) {
|
||||
str.truncate(OPEN_DELIM_LEN);
|
||||
str.append(UnicodeString(buf, len, "")).append(CLOSE_DELIM);
|
||||
str.append(UnicodeString(buf, len, US_INV)).append(CLOSE_DELIM);
|
||||
text.handleReplaceBetween(cursor, cursor+clen, str);
|
||||
len += OPEN_DELIM_LEN + 1; // adjust for delimiters
|
||||
cursor += len; // advance cursor and adjust for new text
|
||||
|
Loading…
Reference in New Issue
Block a user