From 6d32618529a0d0149488610268889b3da0f2b4b0 Mon Sep 17 00:00:00 2001 From: Lem0nC Date: Tue, 9 Sep 2025 19:37:36 +0800 Subject: [PATCH 1/2] url Signed-off-by: Lem0nC --- api/@ohos.graphics.text.d.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/api/@ohos.graphics.text.d.ts b/api/@ohos.graphics.text.d.ts index bbe8e55b08..bfd2421dbe 100755 --- a/api/@ohos.graphics.text.d.ts +++ b/api/@ohos.graphics.text.d.ts @@ -2849,6 +2849,18 @@ declare namespace text { * @since 20 */ function setTextUndefinedGlyphDisplay(noGlyphShow: TextUndefinedGlyphDisplay): void; + + + /** + * Obtains the font descriptor array based on the provided font file path or resource. + * @param { string | Resource } path - Path or resource of the font file. + * The value must be **file://**absolute path of the font file or **rawfile/**directory or file name. + * @returns { Promise> } Promise used to return all parsed font descriptors, and an empty array will + * be returned if no fonts are found, invalid path, no permission, or non-font file. + * @syscap SystemCapability.Graphics.Drawing + * @since 22 + */ + function getFontDescriptorsFromPath(path: string | Resource): Promise>; } export default text; -- Gitee From 739cd7bbf6ae46608cb93dcbdf09ad814eb607d5 Mon Sep 17 00:00:00 2001 From: Lem0nC Date: Tue, 9 Sep 2025 19:41:50 +0800 Subject: [PATCH 2/2] url Signed-off-by: Lem0nC --- api/@ohos.graphics.text.d.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/api/@ohos.graphics.text.d.ts b/api/@ohos.graphics.text.d.ts index bfd2421dbe..b6f0b9d891 100755 --- a/api/@ohos.graphics.text.d.ts +++ b/api/@ohos.graphics.text.d.ts @@ -2850,7 +2850,6 @@ declare namespace text { */ function setTextUndefinedGlyphDisplay(noGlyphShow: TextUndefinedGlyphDisplay): void; - /** * Obtains the font descriptor array based on the provided font file path or resource. * @param { string | Resource } path - Path or resource of the font file. -- Gitee