harmony 鸿蒙styled_string.h
styled_string.h
Overview
Provides styled string APIs of ArkUI on the native side.
Library: libace_ndk.z.so
File to include:
System capability: SystemCapability.ArkUI.ArkUI.Full
Since: 12
Related module: ArkUI_NativeModule
Summary
Types
Name | Description |
---|---|
typedef struct ArkUI_StyledString ArkUI_StyledString | Defines a styled string object supported by the text component. |
Functions
Name | Description |
---|---|
ArkUI_StyledString * OH_ArkUI_StyledString_Create (OH_Drawing_TypographyStyle *style, OH_Drawing_FontCollection *collection) | Creates an ArkUI_StyledString object. |
void OH_ArkUI_StyledString_Destroy (ArkUI_StyledString *handle) | Destroys an ArkUI_StyledString object and reclaims the memory occupied by the object. |
void OH_ArkUI_StyledString_PushTextStyle (ArkUI_StyledString *handle, OH_Drawing_TextStyle *style) | Pushes a text style to the top of the style stack of a styled string. |
void OH_ArkUI_StyledString_AddText (ArkUI_StyledString *handle, const char *content) | Adds text for a styled string. |
void OH_ArkUI_StyledString_PopTextStyle (ArkUI_StyledString *handle) | Pops the style at the top of the style stack of a styled string. |
OH_Drawing_Typography * OH_ArkUI_StyledString_CreateTypography (ArkUI_StyledString *handle) | Creates an OH_Drawing_Typography object based on an ArkUI_StyledString object. |
void OH_ArkUI_StyledString_AddPlaceholder (ArkUI_StyledString *handle, OH_Drawing_PlaceholderSpan *placeholder) | Adds a placeholder. |
ArkUI_StyledString_Descriptor * OH_ArkUI_StyledString_Descriptor_Create (void) | Creates an ArkUI_StyledString_Descriptor object. |
void OH_ArkUI_StyledString_Descriptor_Destroy (ArkUI_StyledString_Descriptor *descriptor) | Destroys an ArkUI_StyledString_Descriptor object and reclaims the memory occupied by the object. |
int32_t OH_ArkUI_UnmarshallStyledStringDescriptor (uint8_t *buffer, size_t bufferSize, ArkUI_StyledString_Descriptor *descriptor, size_t *resultSize) | Unmarshals a byte array containing styled string information into a styled string. |
int32_t OH_ArkUI_MarshallStyledStringDescriptor (uint8_t *buffer, size_t bufferSize, ArkUI_StyledString_Descriptor *descriptor) | Marshals the styled string information into a byte array. |
const char * OH_ArkUI_ConvertToHtml (ArkUI_StyledString_Descriptor *descriptor) | Converts styled string information into HTML. |
你可能感兴趣的鸿蒙文章
harmony 鸿蒙ARKUI_TextPickerCascadeRangeContent
harmony 鸿蒙ARKUI_TextPickerRangeContent
harmony 鸿蒙ArkUI_AnimateCompleteCallback
harmony 鸿蒙ArkUI_ContextCallback
0
赞
- 所属分类: 后端技术
- 本文标签:
热门推荐
-
2、 - 优质文章
-
3、 gate.io
-
8、 golang
-
9、 openharmony
-
10、 Vue中input框自动聚焦