From 3a30125248745c053b63718cb3a895e979b10c62 Mon Sep 17 00:00:00 2001 From: FTL1ght Date: Thu, 28 Aug 2025 14:57:02 +0800 Subject: [PATCH 1/3] Sync code for text engine sdk c Signed-off-by: FTL1ght Change-Id: Iaf40a62ff43778c2db1ed8a73c9ee1c137c7e7cf --- .../native_drawing/drawing_text_typography.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/graphic/graphic_2d/native_drawing/drawing_text_typography.h b/graphic/graphic_2d/native_drawing/drawing_text_typography.h index 9bdf581f61d..e9be40beb1f 100644 --- a/graphic/graphic_2d/native_drawing/drawing_text_typography.h +++ b/graphic/graphic_2d/native_drawing/drawing_text_typography.h @@ -589,11 +589,11 @@ typedef enum OH_Drawing_FontWidth { * @version 1.0 */ typedef enum OH_Drawing_TextBadgeType { - /* No badge */ + /** No badge */ TEXT_BADGE_NONE, - /* Superscript */ + /** Superscript */ TEXT_SUPERSCRIPT, - /* Subscript */ + /** Subscript */ TEXT_SUBSCRIPT, } OH_Drawing_TextBadgeType; @@ -2480,7 +2480,7 @@ bool OH_Drawing_TextStyleIsEqualByFont(const OH_Drawing_TextStyle* style, const /** * @brief Gets whether two TextStyle objects match attributes * - * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing + * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing. * @param style Indicates enumerates of text style type. * @param comparedStyle Indicates source of comparison OH_Drawing_TextStyle object. * @param textStyleType Indicates comparison OH_Drawing_TextStyle object. @@ -2706,7 +2706,7 @@ void OH_Drawing_TypographyUpdateDecorationThicknessScale(OH_Drawing_Typography* double decorationThicknessScale); /** - * @brief Update the decoration style of the typography. + * @brief Update the decoration style of typography. * * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing * @param typography Indicates the pointer to the text OH_Drawing_Typography object. -- Gitee From 94e6ae35604b4b5fd3665ea696a622900a3a0565 Mon Sep 17 00:00:00 2001 From: FTL1ght Date: Thu, 28 Aug 2025 15:13:11 +0800 Subject: [PATCH 2/3] Fix Signed-off-by: FTL1ght Change-Id: Idb023a64f965e19f821f28b5700be029bc024527 --- graphic/graphic_2d/native_drawing/drawing_text_typography.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/graphic/graphic_2d/native_drawing/drawing_text_typography.h b/graphic/graphic_2d/native_drawing/drawing_text_typography.h index e9be40beb1f..c3c5da15554 100644 --- a/graphic/graphic_2d/native_drawing/drawing_text_typography.h +++ b/graphic/graphic_2d/native_drawing/drawing_text_typography.h @@ -2480,7 +2480,7 @@ bool OH_Drawing_TextStyleIsEqualByFont(const OH_Drawing_TextStyle* style, const /** * @brief Gets whether two TextStyle objects match attributes * - * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing. + * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing * @param style Indicates enumerates of text style type. * @param comparedStyle Indicates source of comparison OH_Drawing_TextStyle object. * @param textStyleType Indicates comparison OH_Drawing_TextStyle object. @@ -2671,7 +2671,7 @@ int32_t OH_Drawing_TypographyGetUnresolvedGlyphsCount(OH_Drawing_Typography* typ void OH_Drawing_TypographyUpdateFontSize(OH_Drawing_Typography* typography, size_t from, size_t to, float fontSize); /** - * @brief Update the font color of the typography. + * @brief Update the font color of the typography * * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing * @param typography Indicates the pointer to the text OH_Drawing_Typography object. -- Gitee From 6586e98661d5204ef8e10c541d6c14379e8c686b Mon Sep 17 00:00:00 2001 From: FTL1ght Date: Thu, 28 Aug 2025 15:16:35 +0800 Subject: [PATCH 3/3] Fix optimize space Signed-off-by: FTL1ght Change-Id: Ia22d33ddff55d0ff714825863043d28a4ca73b4e --- .../native_drawing/drawing_text_typography.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/graphic/graphic_2d/native_drawing/drawing_text_typography.h b/graphic/graphic_2d/native_drawing/drawing_text_typography.h index c3c5da15554..f95f8f81171 100644 --- a/graphic/graphic_2d/native_drawing/drawing_text_typography.h +++ b/graphic/graphic_2d/native_drawing/drawing_text_typography.h @@ -3031,15 +3031,15 @@ void OH_Drawing_SetTypographyTextTab(OH_Drawing_TypographyStyle* style, OH_Drawi size_t OH_Drawing_GetDrawingArraySize(OH_Drawing_Array* drawingArray); /** -* @brief Sets whether to optimize whitespace at the end of each line for text typography. -* -* @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing -* @param style Indicates the pointer to an OH_Drawing_TypographyStyle object. -* @param trailingSpaceOptimized Boolean value indicating whether to optimize whitespace at the end of each line -* for text typography to set. -* @since 20 -* @version 1.0 -*/ + * @brief Sets whether to optimize whitespace at the end of each line for text typography. + * + * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing + * @param style Indicates the pointer to an OH_Drawing_TypographyStyle object. + * @param trailingSpaceOptimized Boolean value indicating whether to optimize whitespace at the end of each line + * for text typography to set. + * @since 20 + * @version 1.0 + */ void OH_Drawing_SetTypographyTextTrailingSpaceOptimized(OH_Drawing_TypographyStyle* style, bool trailingSpaceOptimized); /** -- Gitee