Home
last modified time | relevance | path

Searched refs:utf16 (Results 1 – 11 of 11) sorted by relevance

/frameworks/base/libs/androidfw/
DUtil.cpp52 std::u16string utf16; in Utf8ToUtf16() local
53 utf16.resize(utf16_length); in Utf8ToUtf16()
54 utf8_to_utf16(reinterpret_cast<const uint8_t*>(utf8.data()), utf8.length(), &*utf16.begin(), in Utf8ToUtf16()
56 return utf16; in Utf8ToUtf16()
59 std::string Utf16ToUtf8(const StringPiece16& utf16) { in Utf16ToUtf8() argument
60 ssize_t utf8_length = utf16_to_utf8_length(utf16.data(), utf16.length()); in Utf16ToUtf8()
67 utf16_to_utf8(utf16.data(), utf16.length(), &*utf8.begin(), utf8_length + 1); in Utf16ToUtf8()
/frameworks/base/libs/hwui/tests/common/
DTestUtils.cpp83 auto utf16 = asciiToUtf16(text); in drawUtf8ToCanvas() local
86 canvas->drawText(utf16.get(), length, // text buffer in drawUtf8ToCanvas()
94 auto utf16 = asciiToUtf16(text); in drawUtf8ToCanvas() local
95 canvas->drawTextOnPath(utf16.get(), strlen(text), minikin::Bidi::LTR, path, 0, 0, paint, in drawUtf8ToCanvas()
115 std::unique_ptr<uint16_t[]> utf16(new uint16_t[length]); in asciiToUtf16() local
117 utf16.get()[i] = str[i]; in asciiToUtf16()
119 return utf16; in asciiToUtf16()
/frameworks/base/tools/aapt2/util/
DUtil.cpp428 std::u16string utf16; in Utf8ToUtf16() local
429 utf16.resize(utf16_length); in Utf8ToUtf16()
431 &*utf16.begin(), utf16_length + 1); in Utf8ToUtf16()
432 return utf16; in Utf8ToUtf16()
435 std::string Utf16ToUtf8(const StringPiece16& utf16) { in Utf16ToUtf8() argument
436 ssize_t utf8_length = utf16_to_utf8_length(utf16.data(), utf16.length()); in Utf16ToUtf8()
443 utf16_to_utf8(utf16.data(), utf16.length(), &*utf8.begin(), utf8_length + 1); in Utf16ToUtf8()
DUtil.h212 std::string Utf16ToUtf8(const android::StringPiece16& utf16);
/frameworks/minikin/tests/unittest/
DLayoutSplitterTest.cpp30 auto utf16 = utf8ToUtf16(text); in parseTestString() local
33 for (uint16_t c : utf16) { in parseTestString()
49 auto utf16 = utf8ToUtf16(text); in parseExpectString() local
53 for (uint16_t c : utf16) { in parseExpectString()
DLayoutCoreTest.cpp31 auto utf16 = utf8ToUtf16(text); in buildLayout() local
32 return LayoutPiece(utf16, Range(0, utf16.size()), false /* rtl */, paint, in buildLayout()
DGraphemeBreakTests.cpp45 TEST(GraphemeBreak, utf16) { in TEST() argument
/frameworks/base/tools/aapt2/cmd/
DConvert.cpp49 virtual bool SerializeXml(const xml::XmlResource* xml, const std::string& path, bool utf16,
70 bool SerializeXml(const xml::XmlResource* xml, const std::string& path, bool utf16, in SerializeXml() argument
73 xml_flattener_options_.use_utf16 = utf16; in SerializeXml()
152 bool SerializeXml(const xml::XmlResource* xml, const std::string& path, bool utf16, in SerializeXml() argument
DLink.cpp215 const StringPiece& path, bool keep_raw_values, bool utf16, in FlattenXml() argument
229 options.use_utf16 = utf16; in FlattenXml()
/frameworks/base/libs/androidfw/include/androidfw/
DUtil.h118 std::string Utf16ToUtf8(const StringPiece16& utf16);
/frameworks/base/core/jni/
Dandroid_database_CursorWindow.cpp261 String16 utf16(value, sizeIncludingNull - 1); in nativeGetString() local
262 return env->NewString(reinterpret_cast<const jchar*>(utf16.string()), utf16.size()); in nativeGetString()