diff --git a/arkui/ace_engine/native/native_node.h b/arkui/ace_engine/native/native_node.h index 3c85e8617f571f7d45f1a33b4a0d5aa86fe848ed..83f78efb591d3291eb277a4056071de161252a4e 100644 --- a/arkui/ace_engine/native/native_node.h +++ b/arkui/ace_engine/native/native_node.h @@ -2444,6 +2444,22 @@ typedef enum { */ NODE_TEXT_RADIAL_GRADIENT = 1034, + /** + * @brief Sets the vertical alignment of the text content. + * This attribute can be set, reset, and obtained as required through APIs. + * + * Format of the {@link ArkUI_AttributeItem} parameter for setting the attribute:\n + * .value[0].i32: vertical alignment of the text content, specified using the {@link ArkUI_TextVerticalAlignment} + * enum. The default value is ARKUI_TEXT_VERTICAL_ALIGNMENT_BASELINE. \n + * \n + * Format of the return value {@link ArkUI_AttributeItem}:\n + * .value[0].i32: vertical alignment of the text content, specified using the {@link ArkUI_TextVerticalAlignment} + * enum. \n + * + * @since 20 + */ + NODE_TEXT_VERTICAL_ALIGN = 1035, + /** * @brief Defines the text content attribute, which can be set, reset, and obtained as required through APIs. * diff --git a/arkui/ace_engine/native/native_type.h b/arkui/ace_engine/native/native_type.h index 828ba5b7d30727b121c7536c4bc4bf9731f6fec9..b94eb2080da69f1101bfdccf4797377aa35e8f93 100644 --- a/arkui/ace_engine/native/native_type.h +++ b/arkui/ace_engine/native/native_type.h @@ -389,6 +389,22 @@ typedef enum { ARKUI_TEXT_ALIGNMENT_JUSTIFY, } ArkUI_TextAlignment; +/** + * @brief Enumerates text vertical alignment styles. + * + * @since 20 + */ +typedef enum { + /** Aligned to the baseline. */ + ARKUI_TEXT_VERTICAL_ALIGNMENT_BASELINE = 0, + /** Bottom aligned. */ + ARKUI_TEXT_VERTICAL_ALIGNMENT_BOTTOM, + /** Center aligned. */ + ARKUI_TEXT_VERTICAL_ALIGNMENT_CENTER, + /** Top aligned. */ + ARKUI_TEXT_VERTICAL_ALIGNMENT_TOP, +} ArkUI_TextVerticalAlignment; + /** * @brief Enumerates the types of the Enter key for a single-line text box. * @@ -1273,6 +1289,12 @@ typedef enum { ARKUI_IMAGE_SPAN_ALIGNMENT_CENTER, /** The image is top aligned with the text. */ ARKUI_IMAGE_SPAN_ALIGNMENT_TOP, + /** + * The image alignment mode follows the text component's alignment mode. + * + * @since 20 + */ + ARKUI_IMAGE_SPAN_ALIGNMENT_FOLLOW_PARAGRAPH, } ArkUI_ImageSpanAlignment; /**