/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/drawing_ndk/src/ |
H A D | drawing_text_run.cpp | 129 auto glyphs = reinterpret_cast<AdapterTxt::RunImpl*>(run)->GetGlyphs(start, length); in OH_Drawing_GetRunGlyphs() local 130 if (glyphs.size() == 0) { in OH_Drawing_GetRunGlyphs() 137 uint16_t* glyphsArr = new (std::nothrow) uint16_t[glyphs.size()]; in OH_Drawing_GetRunGlyphs() 142 for (size_t i = 0; i < glyphs.size() ; ++i) { in OH_Drawing_GetRunGlyphs() 143 glyphsArr[i] = glyphs[i]; in OH_Drawing_GetRunGlyphs() 146 array->num = glyphs.size(); in OH_Drawing_GetRunGlyphs() 153 ObjectArray* glyphs = reinterpret_cast<ObjectArray*>(glyphsArray); in OH_Drawing_GetRunGlyphsByIndex() local 154 if (glyphs && glyphs->type == ObjectType::TEXT_RUN && in OH_Drawing_GetRunGlyphsByIndex() 155 index < glyphs in OH_Drawing_GetRunGlyphsByIndex() 163 ObjectArray* glyphs = reinterpret_cast<ObjectArray*>(glyphsArray); OH_Drawing_DestroyRunGlyphs() local [all...] |
H A D | drawing_font.cpp | 217 OH_Drawing_TextEncoding encoding, uint16_t* glyphs, int maxGlyphCount) in OH_Drawing_FontTextToGlyphs() 219 if (cFont == nullptr || text == nullptr || glyphs == nullptr || byteLength == 0 || maxGlyphCount <= 0) { in OH_Drawing_FontTextToGlyphs() 224 static_cast<TextEncoding>(encoding), glyphs, maxGlyphCount); in OH_Drawing_FontTextToGlyphs() 227 void OH_Drawing_FontGetWidths(const OH_Drawing_Font* cFont, const uint16_t* glyphs, int count, float* widths) in OH_Drawing_FontGetWidths() argument 229 if (cFont == nullptr || glyphs == nullptr || widths == nullptr || count <= 0) { in OH_Drawing_FontGetWidths() 233 CastToFont(*cFont).GetWidths(glyphs, count, widths); in OH_Drawing_FontGetWidths() 402 OH_Drawing_ErrorCode OH_Drawing_FontGetBounds(const OH_Drawing_Font* cFont, const uint16_t* glyphs, uint32_t count, in OH_Drawing_FontGetBounds() argument 405 if (cFont == nullptr || glyphs == nullptr || bounds == nullptr || count <= 0) { in OH_Drawing_FontGetBounds() 422 CastToFont(*cFont).GetWidths(glyphs, count, nullptr, reinterpret_cast<Drawing::Rect*>(rectArr)); in OH_Drawing_FontGetBounds() 216 OH_Drawing_FontTextToGlyphs(const OH_Drawing_Font* cFont, const void* text, uint32_t byteLength, OH_Drawing_TextEncoding encoding, uint16_t* glyphs, int maxGlyphCount) OH_Drawing_FontTextToGlyphs() argument
|
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/unittest/ndk/ |
H A D | drawing_font_test.cpp | 127 uint16_t glyphs[50] = {0}; // 50 means glyphs array number in HWTEST_F() local 128 OH_Drawing_FontTextToGlyphs(nullptr, str, 0, OH_Drawing_TextEncoding::TEXT_ENCODING_UTF8, glyphs, 0); in HWTEST_F() 130 OH_Drawing_FontTextToGlyphs(font, nullptr, 0, OH_Drawing_TextEncoding::TEXT_ENCODING_UTF8, glyphs, 0); in HWTEST_F() 134 OH_Drawing_FontTextToGlyphs(font, str, strlen(str), OH_Drawing_TextEncoding::TEXT_ENCODING_UTF8, glyphs, 0); in HWTEST_F() 138 OH_Drawing_TextEncoding::TEXT_ENCODING_UTF8, glyphs, 0); in HWTEST_F() 143 OH_Drawing_TextEncoding::TEXT_ENCODING_UTF8, glyphs, count); in HWTEST_F() 147 OH_Drawing_FontGetWidths(nullptr, glyphs, glyphsCount, widths); in HWTEST_F() 151 OH_Drawing_FontGetWidths(font, glyphs, 0, widths); in HWTEST_F() 153 OH_Drawing_FontGetWidths(font, glyphs, glyphsCoun in HWTEST_F() 436 uint16_t glyphs[count]; HWTEST_F() local 466 uint16_t glyphs[count]; HWTEST_F() local 494 uint16_t glyphs[count]; HWTEST_F() local 543 uint16_t glyphs[count]; HWTEST_F() local 578 uint16_t glyphs[count]; HWTEST_F() local 612 uint16_t glyphs[count]; HWTEST_F() local 781 uint16_t glyphs[count]; HWTEST_F() local [all...] |
H A D | drawing_text_run_test.cpp | 178 OH_Drawing_Array* glyphs = OH_Drawing_GetRunGlyphs(run, 0, count); in HWTEST_F() local 179 EXPECT_TRUE(glyphs != nullptr); in HWTEST_F() 180 size_t glyphSize = OH_Drawing_GetDrawingArraySize(glyphs); in HWTEST_F() 182 EXPECT_TRUE(OH_Drawing_GetRunGlyphsByIndex(glyphs, glyphsIndex) > 0); in HWTEST_F() 184 OH_Drawing_DestroyRunGlyphs(glyphs); in HWTEST_F() 276 OH_Drawing_Array* glyphs = OH_Drawing_GetRunGlyphs(run, 0, count); in HWTEST_F() local 277 size = OH_Drawing_GetDrawingArraySize(glyphs); in HWTEST_F() 278 EXPECT_TRUE(glyphs != nullptr); in HWTEST_F() 280 EXPECT_TRUE(OH_Drawing_GetRunGlyphsByIndex(glyphs, glyphsIndex) > 0); in HWTEST_F() 282 OH_Drawing_DestroyRunGlyphs(glyphs); in HWTEST_F() 376 OH_Drawing_Array* glyphs = OH_Drawing_GetRunGlyphs(run, -1, -100); HWTEST_F() local 476 OH_Drawing_Array* glyphs = OH_Drawing_GetRunGlyphs(run, 0, 0); HWTEST_F() local [all...] |
H A D | drawing_canvas_test.cpp | 1023 runBuffer->glyphs[0] = 65; in HWTEST_F() 1026 runBuffer->glyphs[1] = 227; in HWTEST_F() 1029 runBuffer->glyphs[2] = 283; in HWTEST_F() 1032 runBuffer->glyphs[3] = 283; in HWTEST_F() 1035 runBuffer->glyphs[4] = 299; in HWTEST_F() 1038 runBuffer->glyphs[5] = 2; in HWTEST_F() 1041 runBuffer->glyphs[6]= 94; in HWTEST_F() 1044 runBuffer->glyphs[7] = 37; in HWTEST_F() 1047 runBuffer->glyphs[8] = 84; in HWTEST_F()
|
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/fuzztest/text/font_fuzzer/ |
H A D | font_fuzzer.cpp | 128 uint16_t* glyphs = new uint16_t[count]; in FontFuzzTest004() local 130 glyphs[i] = GetObject<uint16_t>(); in FontFuzzTest004() 136 font.GetWidths(glyphs, count, widths); in FontFuzzTest004() 137 if (glyphs != nullptr) { in FontFuzzTest004() 138 delete [] glyphs; in FontFuzzTest004() 139 glyphs = nullptr; in FontFuzzTest004() 160 uint16_t* glyphs = new uint16_t[count]; in FontFuzzTest005() local 162 glyphs[i] = GetObject<uint16_t>(); in FontFuzzTest005() 173 font.GetWidths(glyphs, count, widths, bounds); in FontFuzzTest005() 174 if (glyphs ! in FontFuzzTest005() 206 uint16_t* glyphs = new uint16_t[count]; FontFuzzTest006() local [all...] |
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/drawing_ndk/cpp/interface/ |
H A D | text_blob_test.cpp | 40 uint16_t glyphs[9] = { 65, 227, 283, 283, 299, 2, 94, 37, in OnTestPerformance() local 60 buffer->glyphs[idx] = glyphs[idx]; in OnTestPerformance() 148 uint16_t glyphs[9] = { 65, 227, 283, 283, 299, 2, 94, 37, 84 }; // 65, 227, 283, 283, 299, 2, 94, 37, 84字形符号数组 in OnTestPerformance() local 159 buffer->glyphs[idx] = glyphs[idx]; in OnTestPerformance()
|
/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/src/drawing/text/ |
H A D | font.cpp | 98 void Font::GetWidths(const uint16_t glyphs[], int count, scalar widths[]) const in GetWidths() argument 100 fontImpl_->GetWidths(glyphs, count, widths); in GetWidths() 103 void Font::GetWidths(const uint16_t glyphs[], int count, scalar widths[], Rect bounds[]) const in GetWidths() argument 105 fontImpl_->GetWidths(glyphs, count, widths, bounds); in GetWidths() 174 uint16_t glyphs[], int maxGlyphCount) const in TextToGlyphs() 176 return fontImpl_->TextToGlyphs(text, byteLength, encoding, glyphs, maxGlyphCount); in TextToGlyphs() 173 TextToGlyphs(const void* text, size_t byteLength, TextEncoding encoding, uint16_t glyphs[], int maxGlyphCount) const TextToGlyphs() argument
|
/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/src/drawing/engine_adapter/skia_adapter/ |
H A D | skia_font.cpp | 145 void SkiaFont::GetWidths(const uint16_t glyphs[], int count, scalar widths[]) const in GetWidths() argument 147 skFont_.getWidths(glyphs, count, widths); in GetWidths() 150 void SkiaFont::GetWidths(const uint16_t glyphs[], int count, scalar widths[], Rect bounds[]) const in GetWidths() argument 153 skFont_.getWidths(glyphs, count, widths, nullptr); in GetWidths() 168 skFont_.getWidths(glyphs, count, widths, skBounds); in GetWidths() 241 uint16_t glyphs[], int maxGlyphCount) const in TextToGlyphs() 244 return skFont_.textToGlyphs(text, byteLength, skEncoding, glyphs, maxGlyphCount); in TextToGlyphs() 240 TextToGlyphs(const void* text, size_t byteLength, TextEncoding encoding, uint16_t glyphs[], int maxGlyphCount) const TextToGlyphs() argument
|
H A D | skia_font.h | 57 void GetWidths(const uint16_t glyphs[], int count, scalar widths[]) const override; 58 void GetWidths(const uint16_t glyphs[], int count, scalar widths[], Rect bounds[]) const override; 75 uint16_t glyphs[], int maxGlyphCount) const override;
|
H A D | skia_convert_utils.h | 103 runBuffer.glyphs = skRunBuffer.glyphs; in SkRunBufferCastToDrawingRunBuffer()
|
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/unittest/skia_adapter/ |
H A D | skia_font_test.cpp | 163 uint16_t glyphs[] = { 0, 0 }; in HWTEST_F() local 165 skiaFont->GetWidths(glyphs, 2, widths); // 2:count in HWTEST_F() 166 skiaFont->GetWidths(glyphs, 2, widths, nullptr); // 2:count in HWTEST_F() 170 skiaFont->GetWidths(glyphs, 2, widths, bounds); in HWTEST_F()
|
/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/drawing_ndk/include/ |
H A D | drawing_text_run.h | 158 * @param glyphs The run of glyph array object <b>OH_Drawing_Array</b>. 164 uint16_t OH_Drawing_GetRunGlyphsByIndex(OH_Drawing_Array* glyphs, size_t index); 170 * @param glyphs The run of glyph array object <b>OH_Drawing_Array</b>. 174 void OH_Drawing_DestroyRunGlyphs(OH_Drawing_Array* glyphs);
|
H A D | drawing_font.h | 200 * @brief Calculate number of glyphs represented by text. 221 * @param glyphs Indicates the storage for glyph indices. 228 OH_Drawing_TextEncoding encoding, uint16_t* glyphs, int maxGlyphCount); 231 * @brief Retrieves the advance for each glyph in glyphs. 235 * @param glyphs Indicates the array of glyph indices to be measured. 236 * @param count Indicates the number of glyphs. 241 void OH_Drawing_FontGetWidths(const OH_Drawing_Font*, const uint16_t* glyphs, int count, float* widths); 507 * @param glyphs Indicates the array of glyph indices to be measured. 508 * @param count Indicates the number of glyphs. 512 * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of font, glyphs [all...] |
H A D | drawing_text_blob.h | 124 * @brief Defines a run, supplies storage for glyphs and positions. 131 uint16_t* glyphs; member 141 * @brief Alloc run with storage for glyphs and positions. The returned pointer does not need to be managed 147 * @param count Indicates the number of glyphs.
|
/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/include/text/ |
H A D | font.h | 59 * @brief Set glyphs are drawn at sub-pixel offsets. 120 * @brief Retrieves the advance and bounds for each glyph in glyphs. 121 * @param glyphs Array of glyph indices to be measured 122 * @param count Number of glyphs 125 void GetWidths(const uint16_t glyphs[], int count, scalar widths[]) const; 128 * @brief Retrieves the advance and bounds for each glyph in glyphs. 129 * @param glyphs Array of glyph indices to be measured 130 * @param count Number of glyphs 134 void GetWidths(const uint16_t glyphs[], int count, scalar widths[], Rect bounds[]) const; 197 * @brief Returns true if glyphs ma [all...] |
H A D | text_blob_builder.h | 41 uint16_t* glyphs; member 54 * @brief Alloc run with storage for glyphs and point positions. 56 * @param count Number of glyphs 58 * @return Run with storage for glyphs and point positions. 64 * @brief Alloc run with storage for glyphs and affine matrix. 66 * @param count Number of glyphs 67 * @return Run with storage for glyphs and affine matrix.
|
/foundation/graphic/graphic_2d/rosen/modules/2d_graphics/src/drawing/engine_adapter/impl_interface/ |
H A D | font_impl.h | 53 virtual void GetWidths(const uint16_t glyphs[], int count, scalar widths[]) const = 0; 54 virtual void GetWidths(const uint16_t glyphs[], int count, scalar widths[], Rect bounds[]) const = 0; 71 uint16_t glyphs[], int maxGlyphCount) const = 0;
|
/foundation/graphic/graphic_2d/interfaces/kits/napi/graphic/drawing/ |
H A D | js_common.h | 39 uint16_t glyphs; member
|
/foundation/graphic/graphic_3d/lume/LumeFont/src/ |
H A D | font.cpp | 65 void Font::DrawGlyphs(BASE_NS::array_view<const GlyphInfo> glyphs, const FontDefs::RenderData& renderData) in DrawGlyphs() argument 67 GetData()->DrawGlyphs(glyphs, renderData); in DrawGlyphs()
|
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/fuzztest/ndk/ndktextblob_fuzzer/ |
H A D | ndktextblob_fuzzer.cpp | 108 uint16_t glyphs[count]; in NativeDrawingTextBlobTest002() local 111 OH_Drawing_FontTextToGlyphs(font, str, strlen(str), TEXT_ENCODING_UTF8, glyphs, count); in NativeDrawingTextBlobTest002()
|
/foundation/graphic/graphic_2d/rosen/test/2d_graphics/fuzztest/ndk/ndkfont_fuzzer/ |
H A D | ndkfont_fuzzer.cpp | 227 uint16_t glyphs[count]; in NativeDrawingFontTest006() local 228 OH_Drawing_FontTextToGlyphs(font, str, strlen(str), TEXT_ENCODING_UTF8, glyphs, count); in NativeDrawingFontTest006() 229 OH_Drawing_FontTextToGlyphs(nullptr, str, strlen(str), TEXT_ENCODING_UTF8, glyphs, count); in NativeDrawingFontTest006()
|
/foundation/graphic/graphic_2d/rosen/test/2d_engine/unittest/rosen_text/skia_txt/ |
H A D | run_test.cpp | 100 auto glyphs = runs_[0]->GetGlyphs(); in HWTEST_F() local 101 EXPECT_NE(glyphs[0], 0); in HWTEST_F()
|
/foundation/graphic/graphic_2d/rosen/test/2d_engine/unittest/rosen_text/adapter/skia_txt/ |
H A D | run_test.cpp | 99 auto glyphs = runs_[0]->GetGlyphs(); in HWTEST_F() local 100 EXPECT_NE(glyphs[0], 0); in HWTEST_F()
|
/foundation/graphic/graphic_2d/interfaces/kits/napi/graphic/text/run_napi/ |
H A D | js_run.cpp | 170 std::vector<uint16_t> glyphs = run_->GetGlyphs(start, end);
in OnGetGlyphs() local 173 size_t glyphSize = glyphs.size();
in OnGetGlyphs() 176 CreateJsNumber(env, static_cast<uint32_t>(glyphs.at(index)))));
in OnGetGlyphs()
|