arkui_sys/native_node/native_node_ffi.rs
1// automatically generated by rust-bindgen 0.71.1
2
3#![allow(non_upper_case_globals)]
4#![allow(non_camel_case_types)]
5#![allow(non_snake_case)]
6use crate::native_type::*;
7use crate::ui_input_event::ArkUI_UIInputEvent;
8#[cfg(feature = "api-15")]
9use ohos_sys_opaque_types::OH_PixelmapNative;
10
11#[cfg(feature = "api-12")]
12#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
13impl ArkUI_NodeType {
14 /// Custom node.
15 pub const ARKUI_NODE_CUSTOM: ArkUI_NodeType = ArkUI_NodeType(0);
16 /// Text.
17 pub const ARKUI_NODE_TEXT: ArkUI_NodeType = ArkUI_NodeType(1);
18 /// Text span.
19 pub const ARKUI_NODE_SPAN: ArkUI_NodeType = ArkUI_NodeType(2);
20 /// Image span.
21 pub const ARKUI_NODE_IMAGE_SPAN: ArkUI_NodeType = ArkUI_NodeType(3);
22 /// Image.
23 pub const ARKUI_NODE_IMAGE: ArkUI_NodeType = ArkUI_NodeType(4);
24 /// Toggle.
25 pub const ARKUI_NODE_TOGGLE: ArkUI_NodeType = ArkUI_NodeType(5);
26 /// Loading icon.
27 pub const ARKUI_NODE_LOADING_PROGRESS: ArkUI_NodeType = ArkUI_NodeType(6);
28 /// Single-line text input.
29 pub const ARKUI_NODE_TEXT_INPUT: ArkUI_NodeType = ArkUI_NodeType(7);
30 /// Multi-line text input.
31 pub const ARKUI_NODE_TEXT_AREA: ArkUI_NodeType = ArkUI_NodeType(8);
32 /// Button.
33 pub const ARKUI_NODE_BUTTON: ArkUI_NodeType = ArkUI_NodeType(9);
34 /// Progress indicator.
35 pub const ARKUI_NODE_PROGRESS: ArkUI_NodeType = ArkUI_NodeType(10);
36 /// Check box.
37 pub const ARKUI_NODE_CHECKBOX: ArkUI_NodeType = ArkUI_NodeType(11);
38 /// XComponent.
39 pub const ARKUI_NODE_XCOMPONENT: ArkUI_NodeType = ArkUI_NodeType(12);
40 /// Date picker.
41 pub const ARKUI_NODE_DATE_PICKER: ArkUI_NodeType = ArkUI_NodeType(13);
42 /// Time picker.
43 pub const ARKUI_NODE_TIME_PICKER: ArkUI_NodeType = ArkUI_NodeType(14);
44 /// Text picker.
45 pub const ARKUI_NODE_TEXT_PICKER: ArkUI_NodeType = ArkUI_NodeType(15);
46 /// Calendar picker.
47 pub const ARKUI_NODE_CALENDAR_PICKER: ArkUI_NodeType = ArkUI_NodeType(16);
48 /// Slider.
49 pub const ARKUI_NODE_SLIDER: ArkUI_NodeType = ArkUI_NodeType(17);
50 /// Radio
51 pub const ARKUI_NODE_RADIO: ArkUI_NodeType = ArkUI_NodeType(18);
52 /// Image animator.
53 pub const ARKUI_NODE_IMAGE_ANIMATOR: ArkUI_NodeType = ArkUI_NodeType(19);
54 /// XComponent of type TEXTURE.
55 ///
56 /// Available since API-level: 18
57 #[cfg(feature = "api-18")]
58 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
59 pub const ARKUI_NODE_XCOMPONENT_TEXTURE: ArkUI_NodeType = ArkUI_NodeType(20);
60 /// Check box group.
61 ///
62 /// Available since API-level: 15
63 #[cfg(feature = "api-15")]
64 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
65 pub const ARKUI_NODE_CHECKBOX_GROUP: ArkUI_NodeType = ArkUI_NodeType(21);
66 /// Stack container.
67 pub const ARKUI_NODE_STACK: ArkUI_NodeType = ArkUI_NodeType(1000);
68 /// Swiper.
69 pub const ARKUI_NODE_SWIPER: ArkUI_NodeType = ArkUI_NodeType(1001);
70 /// Scrolling container.
71 pub const ARKUI_NODE_SCROLL: ArkUI_NodeType = ArkUI_NodeType(1002);
72 /// List.
73 pub const ARKUI_NODE_LIST: ArkUI_NodeType = ArkUI_NodeType(1003);
74 /// List item.
75 pub const ARKUI_NODE_LIST_ITEM: ArkUI_NodeType = ArkUI_NodeType(1004);
76 /// List item group.
77 pub const ARKUI_NODE_LIST_ITEM_GROUP: ArkUI_NodeType = ArkUI_NodeType(1005);
78 /// Column container.
79 pub const ARKUI_NODE_COLUMN: ArkUI_NodeType = ArkUI_NodeType(1006);
80 /// Row container.
81 pub const ARKUI_NODE_ROW: ArkUI_NodeType = ArkUI_NodeType(1007);
82 /// Flex container.
83 pub const ARKUI_NODE_FLEX: ArkUI_NodeType = ArkUI_NodeType(1008);
84 /// Refresh component.
85 pub const ARKUI_NODE_REFRESH: ArkUI_NodeType = ArkUI_NodeType(1009);
86 /// Water flow container.
87 pub const ARKUI_NODE_WATER_FLOW: ArkUI_NodeType = ArkUI_NodeType(1010);
88 /// Water flow item.
89 pub const ARKUI_NODE_FLOW_ITEM: ArkUI_NodeType = ArkUI_NodeType(1011);
90 /// Relative layout component.
91 pub const ARKUI_NODE_RELATIVE_CONTAINER: ArkUI_NodeType = ArkUI_NodeType(1012);
92 /// Grid.
93 pub const ARKUI_NODE_GRID: ArkUI_NodeType = ArkUI_NodeType(1013);
94 /// Grid item.
95 pub const ARKUI_NODE_GRID_ITEM: ArkUI_NodeType = ArkUI_NodeType(1014);
96 /// Custom span.
97 pub const ARKUI_NODE_CUSTOM_SPAN: ArkUI_NodeType = ArkUI_NodeType(1015);
98}
99#[repr(transparent)]
100/// Enumerates ArkUI component types that can be created on the native side.
101///
102///
103/// Available since API-level: 12
104#[cfg(feature = "api-12")]
105#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
106#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
107pub struct ArkUI_NodeType(pub ::core::ffi::c_uint);
108/// Defines the general input parameter structure of the [`setAttribute`] function.
109///
110///
111/// Available since API-level: 12
112#[cfg(feature = "api-12")]
113#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
114#[repr(C)]
115#[derive(Debug, Copy, Clone)]
116pub struct ArkUI_AttributeItem {
117 /// Numeric array.
118 pub value: *const ArkUI_NumberValue,
119 /// Size of the numeric array.
120 pub size: i32,
121 /// String type.
122 pub string: *const ::core::ffi::c_char,
123 /// Object type.
124 pub object: *mut ::core::ffi::c_void,
125}
126#[cfg(feature = "api-12")]
127#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
128impl ArkUI_NodeAttributeType {
129 /// Defines the width attribute, which can be set, reset, and obtained as required through APIs.
130 ///
131 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
132 ///
133 /// .value[0].f32: width, in vp.
134 ///
135 ///
136 ///
137 /// Format of the return value [`ArkUI_AttributeItem`]:
138 ///
139 /// .value[0].f32: width, in vp.
140 pub const NODE_WIDTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(0);
141 /// Defines the height attribute, which can be set, reset, and obtained as required through APIs.
142 ///
143 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
144 ///
145 /// .value[0].f32: height, in vp.
146 ///
147 ///
148 ///
149 /// Format of the return value [`ArkUI_AttributeItem`]:
150 ///
151 /// .value[0].f32: height, in vp.
152 pub const NODE_HEIGHT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1);
153 /// Defines the background color attribute, which can be set, reset, and obtained as required through APIs.
154 ///
155 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
156 ///
157 /// .value[0].u32: background color. The value is in 0xARGB format. For example, 0xFFFF0000 indicates red.
158 ///
159 ///
160 ///
161 /// Format of the return value [`ArkUI_AttributeItem`]:
162 ///
163 /// .value[0].u32: background color. The value is in 0xARGB format. For example, 0xFFFF0000 indicates red.
164 pub const NODE_BACKGROUND_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(2);
165 /// Defines the background image attribute, which can be set, reset, and obtained as required through APIs.
166 ///
167 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
168 ///
169 /// .string: image address;
170 ///
171 /// .value[0]?.i32: whether to repeat the image. Optional. The parameter type is [`ArkUI_ImageRepeat`].
172 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`]. Either .string or .object must be set.
173 ///
174 /// The default value is <b>ARKUI_IMAGE_REPEAT_NONE</b>.
175 ///
176 ///
177 ///
178 /// Format of the return value [`ArkUI_AttributeItem`]:
179 ///
180 /// .string: image address;
181 ///
182 /// .value[0].i32: whether to repeat the image. The parameter type is [`ArkUI_ImageRepeat`].
183 ///
184 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`].
185 pub const NODE_BACKGROUND_IMAGE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(3);
186 /// Defines the padding attribute, which can be set, reset, and obtained as required through APIs.
187 ///
188 /// There are two formats of [`ArkUI_AttributeItem`] for setting the attribute value:
189 ///
190 /// 1: Specify the same padding for the four directions.
191 ///
192 /// .value[0].f32: padding, in vp.
193 ///
194 /// 2: Specify different paddings for different directions.
195 ///
196 /// .value[0].f32: top padding, in vp.
197 ///
198 /// .value[1].f32: right padding, in vp.
199 ///
200 /// .value[2].f32: bottom padding, in vp.
201 ///
202 /// .value[3].f32: left padding, in vp.
203 ///
204 ///
205 ///
206 /// Format of the return value [`ArkUI_AttributeItem`]:
207 ///
208 /// .value[0].f32: top padding, in vp.
209 ///
210 /// .value[1].f32: right padding, in vp.
211 ///
212 /// .value[2].f32: bottom padding, in vp.
213 ///
214 /// .value[3].f32: left padding, in vp.
215 pub const NODE_PADDING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4);
216 /// Defines the component ID attribute, which can be set, reset, and obtained as required through APIs.
217 ///
218 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
219 ///
220 /// .string: component ID.
221 ///
222 ///
223 ///
224 /// Format of the return value [`ArkUI_AttributeItem`]:
225 ///
226 /// .string: component ID.
227 pub const NODE_ID: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(5);
228 /// Defines the interactivity attribute, which can be set, reset, and obtained as required through APIs.
229 ///
230 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
231 ///
232 /// .value[0].i32: The value <b>true</b> means that the component can interact with users, and <b>false</b> means the opposite.
233 ///
234 ///
235 ///
236 /// Format of the return value [`ArkUI_AttributeItem`]:
237 ///
238 /// .value[0].i32: The value <b>1</b> means that the component can interact with users, and <b>0</b> means the opposite.
239 pub const NODE_ENABLED: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(6);
240 /// Defines the margin attribute, which can be set, reset, and obtained as required through APIs.
241 ///
242 /// There are two formats of [`ArkUI_AttributeItem`] for setting the attribute value:
243 ///
244 /// 1: Specify the same margin for the four directions.
245 ///
246 /// .value[0].f32: margin, in vp.
247 ///
248 /// 2: Specify different margins for different directions.
249 ///
250 /// .value[0].f32: top margin, in vp.
251 ///
252 /// .value[1].f32: right margin, in vp.
253 ///
254 /// .value[2].f32: bottom margin, in vp.
255 ///
256 /// .value[3].f32: left margin, in vp.
257 ///
258 ///
259 ///
260 /// Format of the return value [`ArkUI_AttributeItem`]:
261 ///
262 /// .value[0].f32: top margin, in vp.
263 ///
264 /// .value[1].f32: right margin, in vp.
265 ///
266 /// .value[2].f32: bottom margin, in vp.
267 ///
268 /// .value[3].f32: left margin, in vp.
269 pub const NODE_MARGIN: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7);
270 /// Defines the translate attribute, which can be set, reset, and obtained as required through APIs.
271 ///
272 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
273 ///
274 /// .value[0].f32: distance to translate along the x-axis, in vp. The default value is <b>0</b>.
275 ///
276 /// .value[1].f32: distance to translate along the y-axis, in vp. The default value is <b>0</b>.
277 ///
278 /// .value[2].f32: distance to translate along the z-axis, in vp. The default value is <b>0</b>.
279 ///
280 ///
281 ///
282 /// Format of the return value [`ArkUI_AttributeItem`]:
283 ///
284 /// .value[0].f32: distance to translate along the x-axis, in vp.
285 ///
286 /// .value[1].f32: distance to translate along the y-axis, in vp.
287 ///
288 /// .value[2].f32: distance to translate along the z-axis, in vp.
289 pub const NODE_TRANSLATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8);
290 /// Defines the scale attribute, which can be set, reset, and obtained as required through APIs.
291 ///
292 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
293 ///
294 /// .value[0].f32: scale factor along the x-axis. The default value is <b>1</b>.
295 ///
296 /// .value[1].f32: scale factor along the y-axis. The default value is <b>1</b>.
297 ///
298 ///
299 ///
300 /// Format of the return value [`ArkUI_AttributeItem`]:
301 ///
302 /// .value[0].f32: scale factor along the x-axis.
303 ///
304 /// .value[1].f32: scale factor along the y-axis.
305 pub const NODE_SCALE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(9);
306 /// Defines the rotate attribute, which can be set, reset, and obtained as required through APIs.
307 ///
308 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
309 ///
310 /// .value[0].f32: X coordinate of the rotation axis vector. The default value is <b>0</b>.
311 ///
312 /// .value[1].f32: Y coordinate of the rotation axis vector. The default value is <b>0</b>.
313 ///
314 /// .value[2].f32: Z coordinate of the rotation axis vector. The default value is <b>0</b>.
315 ///
316 /// .value[3].f32: rotation angle. The default value is <b>0</b>.
317 ///
318 /// .value[4].f32: line of sight, that is, the distance from the viewpoint to the z=0 plane, in vp.
319 /// The default value is <b>0</b>.
320 ///
321 ///
322 ///
323 /// Format of the return value [`ArkUI_AttributeItem`]:
324 ///
325 /// .value[0].f32: X coordinate of the rotation axis vector.
326 ///
327 /// .value[1].f32: Y coordinate of the rotation axis vector.
328 ///
329 /// .value[2].f32: Z coordinate of the rotation axis vector.
330 ///
331 /// .value[3].f32: rotation angle.
332 ///
333 /// .value[4].f32: line of sight, that is, the distance from the viewpoint to the z=0 plane, in vp.
334 pub const NODE_ROTATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10);
335 /// Sets the brightness attribute, which can be set, reset, and obtained as required through APIs.
336 ///
337 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
338 ///
339 /// .value[0].f32: brightness value. The default value is <b>1.0</b>, and the recommended value range is [0, 2].
340 ///
341 ///
342 ///
343 /// Format of the return value [`ArkUI_AttributeItem`]:
344 ///
345 /// .value[0].f32: brightness value.
346 pub const NODE_BRIGHTNESS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11);
347 /// Sets the saturation attribute, which can be set, reset, and obtained as required through APIs.
348 ///
349 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
350 ///
351 /// .value[0].f32: saturation value. The default value is <b>1.0</b>, and the recommended value range is [0, 50).
352 ///
353 ///
354 ///
355 /// Format of the return value [`ArkUI_AttributeItem`]:
356 ///
357 /// .value[0].f32: saturation value.
358 pub const NODE_SATURATION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(12);
359 /// Sets the blur attribute, which can be set, reset, and obtained as required through APIs.
360 ///
361 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
362 ///
363 /// .value[0].f32: blur radius. A larger value indicates a higher blur degree. If the value is <b>0</b>,
364 /// the component is not blurred. The unit is vp. The default value is <b>0.0</b>.
365 ///
366 ///
367 ///
368 /// Format of the return value [`ArkUI_AttributeItem`]:
369 ///
370 /// .value[0].f32: blur radius. The larger the fuzzy radius, the more blurred the image. If the value is <b>0</b>,
371 /// the image is not blurred. The unit is vp.
372 pub const NODE_BLUR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13);
373 /// Sets the gradient attribute, which can be set, reset, and obtained as required through APIs.
374 ///
375 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
376 ///
377 /// .value[0].f32: start angle of the linear gradient. This attribute takes effect only when
378 /// [`ArkUI_LinearGradientDirection`] is set to <b>ARKUI_LINEAR_GRADIENT_DIRECTION_CUSTOM</b>.
379 /// A positive value indicates a clockwise rotation from the origin, (0, 0). The default value is <b>180</b>.
380 ///
381 /// .value[1].i32: direction of the linear gradient. When it is set, the <b>angle</b> attribute does not take effect.
382 /// The parameter type is [`ArkUI_LinearGradientDirection`]:
383 ///
384 /// .value[2].i32: whether the colors are repeated. The default value is <b>false</b>.
385 ///
386 /// .object: array of color stops, each of which consists of a color and its stop position.
387 /// Invalid colors are automatically skipped.
388 ///
389 /// colors: colors of the color stops.
390 ///
391 /// stops: stop positions of the color stops.
392 ///
393 /// size: number of colors.
394 ///
395 ///
396 ///
397 /// Format of the return value [`ArkUI_AttributeItem`]:
398 ///
399 /// .value[0].f32: start angle of the linear gradient.
400 ///
401 /// .value[1].i32: direction of the linear gradient. It does not take effect when <b>angle</b> is set.
402 ///
403 /// .value[2].i32: whether the colors are repeated.
404 ///
405 /// .object: array of color stops, each of which consists of a color and its stop position.
406 /// Invalid colors are automatically skipped.
407 ///
408 /// colors: colors of the color stops.
409 ///
410 /// stops: stop positions of the color stops.
411 ///
412 /// size: number of colors.
413 pub const NODE_LINEAR_GRADIENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(14);
414 /// Sets the alignment attribute, which can be set, reset, and obtained as required through APIs.
415 ///
416 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
417 ///
418 /// .value[0].i32: alignment mode. The data type is [`ArkUI_Alignment`].
419 /// The default value is <b>ARKUI_ALIGNMENT_CENTER</b>.
420 ///
421 ///
422 ///
423 /// Format of the return value [`ArkUI_AttributeItem`]:
424 ///
425 /// .value[0].i32: alignment mode. The data type is [`ArkUI_Alignment`].
426 pub const NODE_ALIGNMENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(15);
427 /// Defines the opacity attribute, which can be set, reset, and obtained as required through APIs.
428 ///
429 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
430 ///
431 /// .value[0].f32: opacity value. The value ranges from 0 to 1.
432 ///
433 ///
434 ///
435 /// Format of the return value [`ArkUI_AttributeItem`]:
436 ///
437 /// .value[0].f32: opacity value. The value ranges from 0 to 1.
438 pub const NODE_OPACITY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(16);
439 /// Defines the border width attribute, which can be set, reset, and obtained as required through APIs.
440 ///
441 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
442 ///
443 /// 1: .value[0].f32: width of the four borders.
444 ///
445 /// 2: .value[0].f32: width of the top border.
446 ///
447 /// .value[1].f32: width of the right border.
448 ///
449 /// .value[2].f32: width of the bottom border.
450 ///
451 /// .value[3].f32: width of the left border.
452 ///
453 ///
454 ///
455 /// Format of the return value [`ArkUI_AttributeItem`]:
456 ///
457 /// .value[0].f32: width of the top border.
458 ///
459 /// .value[1].f32: width of the right border.
460 ///
461 /// .value[2].f32: width of the bottom border.
462 ///
463 /// .value[3].f32: width of the left border.
464 pub const NODE_BORDER_WIDTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17);
465 /// Defines the border corner radius attribute, which can be set, reset, and obtained as required through APIs.
466 ///
467 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
468 ///
469 /// 1: .value[0].f32: radius of the four corners.
470 ///
471 /// 2: .value[0].f32: radius of the upper left corner.
472 ///
473 /// .value[1].f32: radius of the upper right corner.
474 ///
475 /// .value[2].f32: radius of the lower left corner.
476 ///
477 /// .value[3].f32: radius of the lower right corner.
478 ///
479 ///
480 ///
481 /// Format of the return value [`ArkUI_AttributeItem`]:
482 ///
483 /// .value[0].f32: radius of the upper left corner.
484 ///
485 /// .value[1].f32: radius of the upper right corner.
486 ///
487 /// .value[2].f32: radius of the lower left corner.
488 ///
489 /// .value[3].f32: radius of the lower right corner.
490 pub const NODE_BORDER_RADIUS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(18);
491 /// Defines the border color attribute, which can be set, reset, and obtained as required through APIs.
492 ///
493 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
494 ///
495 /// 1: .value[0].u32: color of the four borders, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
496 ///
497 /// 2: .value[0].u32: color of the top border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
498 ///
499 /// .value[1].u32: color of the right border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
500 ///
501 /// .value[2].u32: color of the lower border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
502 ///
503 /// .value[3].u32: color of the left border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
504 ///
505 ///
506 ///
507 /// Format of the return value [`ArkUI_AttributeItem`]:
508 ///
509 /// .value[0].u32: color of the top border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
510 ///
511 /// .value[1].u32: color of the right border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
512 ///
513 /// .value[2].u32: color of the lower border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
514 ///
515 /// .value[3].u32: color of the left border, in 0xARGB format, for example, <b>0xFFFF11FF</b>.
516 pub const NODE_BORDER_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(19);
517 /// Defines the border line style attribute, which can be set, reset, and obtained as required through APIs.
518 ///
519 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
520 ///
521 /// 1: .value[0].i32: line style of the four borders. The parameter type is [`ArkUI_BorderStyle`].
522 /// The default value is <b>ARKUI_BORDER_STYLE_SOLID</b>.
523 ///
524 /// 2: .value[0].i32: line style of the top border. The parameter type is [`ArkUI_BorderStyle`].
525 /// The default value is <b>ARKUI_BORDER_STYLE_SOLID</b>.
526 ///
527 /// .value[1].i32: line style of the right border. The parameter type is [`ArkUI_BorderStyle`].
528 /// The default value is <b>ARKUI_BORDER_STYLE_SOLID</b>.
529 ///
530 /// .value[2].i32: line style of the bottom border. The parameter type is [`ArkUI_BorderStyle`].
531 /// The default value is <b>ARKUI_BORDER_STYLE_SOLID</b>.
532 ///
533 /// .value[3].i32: line style of the left border. The parameter type is [`ArkUI_BorderStyle`].
534 /// The default value is <b>ARKUI_BORDER_STYLE_SOLID</b>.
535 ///
536 ///
537 ///
538 /// Format of the return value [`ArkUI_AttributeItem`]:
539 ///
540 /// .value[0].i32: line style of the top border.
541 ///
542 /// .value[1].i32: line style of the right border.
543 ///
544 /// .value[2].i32: line style of the bottom border.
545 ///
546 /// .value[3].i32: line style of the left border.
547 pub const NODE_BORDER_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(20);
548 /// Defines the z-index attribute for the stack sequence.
549 /// This attribute can be set, reset, and obtained as required through APIs.
550 ///
551 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
552 ///
553 /// .value[0].i32: z-index value.
554 ///
555 ///
556 ///
557 /// Format of the return value [`ArkUI_AttributeItem`]:
558 ///
559 /// .value[0].i32: z-index value.
560 pub const NODE_Z_INDEX: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(21);
561 /// Defines the visibility attribute, which can be set, reset, and obtained as required through APIs.
562 ///
563 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
564 ///
565 /// .value[0].i32: whether to show or hide the component. The parameter type is [`ArkUI_Visibility`].
566 /// The default value is <b>ARKUI_VISIBILITY_VISIBLE</b>.
567 ///
568 ///
569 ///
570 /// Format of the return value [`ArkUI_AttributeItem`]:
571 ///
572 /// .value[0].i32: whether to show or hide the component. The parameter type is [`ArkUI_Visibility`].
573 /// The default value is <b>ARKUI_VISIBILITY_VISIBLE</b>.
574 pub const NODE_VISIBILITY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(22);
575 /// Defines the clipping and masking attribute, which can be set, reset, and obtained as required through
576 /// APIs.
577 ///
578 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
579 ///
580 /// .value[0].i32: whether to clip the component based on the parent container bounds.
581 /// The value <b>1</b> means to clip the component, and <b>0</b> means the opposite.
582 ///
583 ///
584 ///
585 /// Format of the return value [`ArkUI_AttributeItem`]:
586 ///
587 /// .value[0].i32: whether to clip the component based on the parent container bounds.
588 /// The value <b>1</b> means to clip the component, and <b>0</b> means the opposite.
589 pub const NODE_CLIP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(23);
590 /// Defines the clipping region on the component.
591 /// This attribute can be set and obtained as required through APIs.
592 ///
593 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute,
594 /// which supports five types of shapes:
595 ///
596 /// 1. Rectangle:
597 ///
598 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
599 /// The value is <b>ARKUI_CLIP_TYPE_RECTANGLE</b> for the rectangle shape.
600 ///
601 /// .value[1].f32: width of the rectangle.
602 ///
603 /// .value[2].f32: height of rectangle.
604 ///
605 /// .value[3].f32: width of the rounded corner of the rectangle.
606 ///
607 /// .value[4].f32: height of the rounded corner of the rectangle.
608 ///
609 /// .value[5]?.f32: radius of the top left corner of the rectangular shape.
610 ///
611 /// .value[6]?.f32: radius of the bottom left corner of the rectangular shape.
612 ///
613 /// .value[7]?.f32: radius of the top right corner of the rectangular shape.
614 ///
615 /// .value[8]?.f32: radius of the bottom right corner of the rectangular shape.
616 ///
617 /// 2. Circle:
618 ///
619 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
620 /// The value is <b>ARKUI_CLIP_TYPE_CIRCLE</b> for the circle shape.
621 ///
622 /// .value[1].f32: width of the circle.
623 ///
624 /// .value[2].f32: height of the circle.
625 ///
626 /// 3.Ellipse:
627 ///
628 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
629 /// The value is <b>ARKUI_CLIP_TYPE_ELLIPSE</b> for the ellipse shape.
630 ///
631 /// .value[1].f32: width of the ellipse.
632 ///
633 /// .value[2].f32: height of the ellipse.
634 ///
635 /// 4. Path:
636 ///
637 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
638 /// The value is <b>ARKUI_CLIP_TYPE_PATH</b> for the path shape.
639 ///
640 /// .value[1].f32: width of the path.
641 ///
642 /// .value[2].f32: height of the path.
643 ///
644 /// .string: command for drawing the path.
645 ///
646 /// Format of the return value [`ArkUI_AttributeItem`], which supports five types of shapes:
647 ///
648 /// 1. Rectangle:
649 ///
650 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
651 /// The value is <b>ARKUI_CLIP_TYPE_RECTANGLE</b> for the rectangle shape.
652 ///
653 /// .value[1].f32: width of the rectangle.
654 ///
655 /// .value[2].f32: height of rectangle.
656 ///
657 /// .value[3].f32: width of the rounded corner of the rectangle.
658 ///
659 /// .value[4].f32: height of the rounded corner of the rectangle.
660 ///
661 /// .value[5].f32: radius of the top left corner of the rectangular shape;
662 ///
663 /// .value[6].f32: radius of the bottom left corner of the rectangular shape;
664 ///
665 /// .value[7].f32: radius of the top right corner of the rectangular shape;
666 ///
667 /// .value[8].f32: radius of the bottom right corner of the rectangular shape;
668 ///
669 /// 2. Circle:
670 ///
671 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
672 /// The value is <b>ARKUI_CLIP_TYPE_CIRCLE</b> for the circle shape.
673 ///
674 /// .value[1].f32: width of the circle.
675 ///
676 /// .value[2].f32: height of the circle.
677 ///
678 /// 3.Ellipse:
679 ///
680 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
681 /// The value is <b>ARKUI_CLIP_TYPE_ELLIPSE</b> for the ellipse shape.
682 ///
683 /// .value[1].f32: width of the ellipse.
684 ///
685 /// .value[2].f32: height of the ellipse.
686 ///
687 /// 4. Path:
688 ///
689 /// .value[0].i32: type of shape. The parameter type is [`ArkUI_ClipType`].
690 /// The value is <b>ARKUI_CLIP_TYPE_PATH</b> for the path shape.
691 ///
692 /// .value[1].f32: width of the path.
693 ///
694 /// .value[2].f32: height of the path.
695 ///
696 /// .string: command for drawing the path.
697 pub const NODE_CLIP_SHAPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(24);
698 /// Defines the transform attribute, which can be used to translate, rotate, and scale images.
699 /// This attribute can be set, reset, and obtained as required through APIs.
700 ///
701 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
702 ///
703 /// .value[0...15].f32: 16 floating-point numbers.
704 ///
705 ///
706 ///
707 /// Format of the return value [`ArkUI_AttributeItem`]:
708 ///
709 /// .value[0...15].f32: 16 floating-point numbers.
710 pub const NODE_TRANSFORM: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(25);
711 /// Defines the hit test behavior attribute, which can be set, reset, and obtained as required through APIs.
712 ///
713 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
714 ///
715 /// .value[0].i32: hit test mode. The parameter type is [`ArkUI_HitTestMode`].
716 /// The default value is <b>ARKUI_HIT_TEST_MODE_DEFAULT</b>.
717 ///
718 ///
719 ///
720 /// Format of the return value [`ArkUI_AttributeItem`]:
721 ///
722 /// .value[0].i32: hit test mode. The parameter type is [`ArkUI_HitTestMode`].
723 /// The default value is <b>ARKUI_HIT_TEST_MODE_DEFAULT</b>.
724 pub const NODE_HIT_TEST_BEHAVIOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(26);
725 /// Defines the offset attribute, which specifies the offset of the component's upper left corner relative
726 /// to the parent container's. This attribute can be set, reset, and obtained as required through APIs.
727 ///
728 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
729 ///
730 /// .value[0].f32: X coordinate.
731 ///
732 /// .value[1].f32: Y coordinate.
733 ///
734 ///
735 ///
736 /// Format of the return value [`ArkUI_AttributeItem`]:
737 ///
738 /// .value[0].f32: X coordinate.
739 ///
740 /// .value[1].f32: Y coordinate.
741 pub const NODE_POSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(27);
742 /// Defines the shadow attribute, which can be set, reset, and obtained as required through APIs.
743 ///
744 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
745 ///
746 /// .value[0].i32: shadow effect. The parameter type is [`ArkUI_ShadowStyle`].
747 ///
748 ///
749 ///
750 /// Format of the return value [`ArkUI_AttributeItem`]:
751 ///
752 /// .value[0].i32: shadow effect. The parameter type is [`ArkUI_ShadowStyle`].
753 pub const NODE_SHADOW: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(28);
754 /// Defines the custom shadow effect. This attribute can be set, reset, and obtained as required through APIs.
755 ///
756 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
757 ///
758 /// .value[0]?.f32: blur radius of the shadow, in vp.
759 ///
760 /// .value[1]?.i32: whether to enable the coloring strategy. The value <b>1</b> means to enable the coloring
761 /// strategy, and <b>0</b> (default value) means the opposite.
762 ///
763 /// .value[2]?.f32: offset of the shadow along the x-axis, in px.
764 ///
765 /// .value[3]?.f32: offset of the shadow along the y-axis, in px.
766 ///
767 /// .value[4]?.i32: shadow type [`ArkUI_ShadowType`]. The default value is <b>ARKUI_SHADOW_TYPE_COLOR</b>.
768 ///
769 /// .value[5]?.u32: shadow color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
770 ///
771 /// .value[6]?.u32: whether to fill the shadow. The value <b>1</b> means to fill the shadow, and <b>0</b>
772 /// means the opposite.
773 ///
774 ///
775 ///
776 ///
777 /// Format of the return value [`ArkUI_AttributeItem`]:
778 ///
779 /// .value[0].f32: blur radius of the shadow, in vp.
780 ///
781 /// .value[1].i32: whether to enable the coloring strategy.
782 ///
783 /// .value[2].f32: offset of the shadow along the x-axis, in px.
784 ///
785 /// .value[3].f32: offset of the shadow along the y-axis, in px.
786 ///
787 /// .value[4].i32: shadow type [`ArkUI_ShadowType`]. The default value is <b>ARKUI_SHADOW_TYPE_COLOR</b>.
788 ///
789 /// .value[5].u32: shadow color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
790 ///
791 /// .value[6].u32: whether to fill the shadow. The value <b>1</b> means to fill the shadow, and <b>0</b>
792 /// means the opposite.
793 pub const NODE_CUSTOM_SHADOW: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(29);
794 /// Defines the background image width and height.
795 /// This attribute can be set, reset, and obtained as required through APIs.
796 ///
797 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
798 ///
799 /// .value[0].f32: width of the image. The value range is [0, +∞), and the unit is vp.
800 ///
801 /// .value[1].f32: height of the image. The value range is [0, +∞), and the unit is vp.
802 ///
803 ///
804 ///
805 /// Format of the return value [`ArkUI_AttributeItem`]:
806 ///
807 /// .value[0].f32: width of the image, in vp.
808 ///
809 /// .value[1].f32: height of the image, in vp.
810 pub const NODE_BACKGROUND_IMAGE_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(30);
811 /// Defines the background image size.
812 /// This attribute can be set, reset, and obtained as required through APIs.
813 ///
814 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
815 ///
816 /// .value[0].i32: size of the background image. The value is an enum of [`ArkUI_ImageSize`].
817 ///
818 ///
819 ///
820 /// Format of the return value [`ArkUI_AttributeItem`]:
821 ///
822 /// .value[0].i32: size of the background image. The value is an enum of [`ArkUI_ImageSize`].
823 pub const NODE_BACKGROUND_IMAGE_SIZE_WITH_STYLE: ArkUI_NodeAttributeType =
824 ArkUI_NodeAttributeType(31);
825 /// Defines the background blur attribute, which can be set, reset, and obtained as required through APIs.
826 ///
827 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
828 ///
829 /// .value[0].i32: blue type. The value is an enum of [`ArkUI_BlurStyle`].
830 ///
831 /// .value[1]?.i32: color mode. The value is an enum of [`ArkUI_ColorMode`].
832 ///
833 /// .value[2]?.i32: adaptive color mode. The value is an enum of [`ArkUI_AdaptiveColor`].
834 ///
835 /// .value[3]?.f32: blur degree. The value range is [0.0, 1.0].
836 ///
837 /// .value[4]?.f32: start boundary of grayscale blur.
838 ///
839 /// .value[5]?.f32: end boundary of grayscale blur.
840 ///
841 ///
842 ///
843 /// Format of the return value [`ArkUI_AttributeItem`]:
844 ///
845 /// .value[0].i32: blue type. The value is an enum of [`ArkUI_BlurStyle`].
846 ///
847 /// .value[1].i32: color mode. The value is an enum of [`ArkUI_ColorMode`].
848 ///
849 /// .value[2].i32: adaptive color mode. The value is an enum of [`ArkUI_AdaptiveColor`].
850 ///
851 /// .value[3].f32: blur degree. The value range is [0.0, 1.0].
852 ///
853 /// .value[4].f32: start boundary of grayscale blur.
854 ///
855 /// .value[5].f32: end boundary of grayscale blur.
856 pub const NODE_BACKGROUND_BLUR_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(32);
857 /// Defines the transform center attribute, which can be set, reset, and obtained as required through APIs.
858 ///
859 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
860 ///
861 /// .value[0]?.f32: X coordinate of the center point, in vp.
862 ///
863 /// .value[1]?.f32: Y coordinate of the center point, in vp.
864 ///
865 /// .value[2]?.f32: Z coordinate of the center point, in vp.
866 ///
867 /// .value[3]?.f32 : X coordinate of the center point, expressed in a number that represents a percentage.
868 /// For example, 0.2 indicates 20%. This attribute overwrites value[0].f32. The default value is <b>0.5f</b>.
869 ///
870 /// .value[4]?.f32 : Y coordinate of the center point, expressed in a number that represents a percentage.
871 /// For example, 0.2 indicates 20%. This attribute overwrites value[1].f32. The default value is <b>0.5f</b>.
872 ///
873 /// .value[5]?.f32 : Z coordinate of the center point, expressed in a number that represents a percentage.
874 /// For example, 0.2 indicates 20%. This attribute overwrites value[2].f32. The default value is <b>0.0f</b>.
875 ///
876 ///
877 ///
878 /// Format of the return value [`ArkUI_AttributeItem`]:
879 ///
880 /// .value[0].f32: X coordinate of the center point, in vp.
881 ///
882 /// .value[1].f32: Y coordinate of the center point, in vp.
883 ///
884 /// .value[2].f32: Z coordinate of the center point, in vp.
885 ///
886 /// Note: If the coordinate is expressed in a number that represents a percentage, the attribute obtaining API
887 /// returns the calculated value in vp.
888 pub const NODE_TRANSFORM_CENTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(33);
889 /// Defines the transition opacity attribute, which can be set, reset, and obtained as required through APIs.
890 ///
891 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
892 ///
893 /// .value[0].f32: opacity values of the start and end points.
894 ///
895 /// .value[1].i32: animation duration, in milliseconds.
896 ///
897 /// .value[2].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
898 ///
899 /// .value[3]?.i32: animation delay duration, in milliseconds.
900 ///
901 /// .value[4]?.i32: number of times that the animation is played.
902 ///
903 /// .value[5]?.i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
904 ///
905 /// .value[6]?.f32: animation playback speed.
906 ///
907 ///
908 ///
909 /// Format of the return value [`ArkUI_AttributeItem`]:
910 ///
911 /// .value[0].f32: opacity values of the start and end points.
912 ///
913 /// .value[1].i32: animation duration, in milliseconds.
914 ///
915 /// .value[2].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
916 ///
917 /// .value[3].i32: animation delay duration, in milliseconds.
918 ///
919 /// .value[4].i32: number of times that the animation is played.
920 ///
921 /// .value[5].i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
922 ///
923 /// .value[6].f32: animation playback speed.
924 pub const NODE_OPACITY_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(34);
925 /// Defines the transition rotation attribute, which can be set, reset, and obtained as required through APIs.
926 ///
927 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
928 ///
929 /// .value[0].f32: X-component of the rotation vector.
930 ///
931 /// .value[1].f32: Y-component of the rotation vector.
932 ///
933 /// .value[2].f32: Z-component of the rotation vector
934 ///
935 /// .value[3].f32: angle.
936 ///
937 /// .value[4].f32: line of sight. The default value is <b>0.0f</b>.
938 ///
939 /// .value[5].i32: animation duration, in milliseconds.
940 ///
941 /// .value[6].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
942 ///
943 ///
944 /// .value[7]?.i32: animation delay duration, in milliseconds.
945 ///
946 /// .value[8]?.i32: number of times that the animation is played.
947 ///
948 /// .value[9]?.i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
949 ///
950 /// .value[10]?.f32: animation playback speed.
951 ///
952 ///
953 ///
954 /// Format of the return value [`ArkUI_AttributeItem`]:
955 ///
956 /// .value[0].f32: X-component of the rotation vector.
957 ///
958 /// .value[1].f32: Y-component of the rotation vector.
959 ///
960 /// .value[2].f32: Z-component of the rotation vector
961 ///
962 /// .value[3].f32: angle.
963 ///
964 /// .value[4].f32: line of sight.
965 ///
966 /// .value[5].i32: animation duration, in milliseconds.
967 ///
968 /// .value[6].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
969 ///
970 ///
971 /// .value[7].i32: animation delay duration, in milliseconds.
972 ///
973 /// .value[8].i32: number of times that the animation is played.
974 ///
975 /// .value[9].i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
976 ///
977 /// .value[10].f32: animation playback speed.
978 pub const NODE_ROTATE_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(35);
979 /// Defines the transition scaling attribute, which can be set, reset, and obtained as required through APIs.
980 ///
981 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
982 ///
983 /// .value[0].f32: scale factor along the x-axis.
984 ///
985 /// .value[1].f32: scale factor along the y-axis.
986 ///
987 /// .value[2].f32: scale factor along the z-axis.
988 ///
989 /// .value[3].i32: animation duration, in milliseconds.
990 ///
991 /// .value[4].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
992 ///
993 ///
994 /// .value[5]?.i32: animation delay duration, in milliseconds.
995 ///
996 /// .value[6]?.i32: number of times that the animation is played.
997 ///
998 /// .value[7]?.i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
999 ///
1000 /// .value[8]?.f32: animation playback speed.
1001 ///
1002 ///
1003 ///
1004 /// Format of the return value [`ArkUI_AttributeItem`]:
1005 ///
1006 /// .value[0].f32: scale factor along the x-axis.
1007 ///
1008 /// .value[1].f32: scale factor along the y-axis.
1009 ///
1010 /// .value[2].f32: scale factor along the z-axis.
1011 ///
1012 /// .value[3].i32: animation duration, in milliseconds.
1013 ///
1014 /// .value[4].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
1015 ///
1016 ///
1017 /// .value[5].i32: animation delay duration, in milliseconds.
1018 ///
1019 /// .value[6].i32: number of times that the animation is played.
1020 ///
1021 /// .value[7].i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
1022 ///
1023 /// .value[8].f32: animation playback speed.
1024 pub const NODE_SCALE_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(36);
1025 /// Defines the transition translation attribute.
1026 /// This attribute can be set, reset, and obtained as required through APIs.
1027 ///
1028 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1029 ///
1030 /// value[0].f32: translation distance along the x-axis, in vp.
1031 ///
1032 /// value[1].f32: translation distance along the y-axis, in vp.
1033 ///
1034 /// value[2].f32: translation distance along the z-axis, in vp.
1035 ///
1036 /// value[3].i32: animation duration, in milliseconds.
1037 ///
1038 /// value[4].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
1039 ///
1040 ///
1041 /// value[5]?.i32: animation delay duration, in milliseconds.
1042 ///
1043 /// value[6]?.i32: number of times that the animation is played.
1044 ///
1045 /// value[7]?.i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
1046 ///
1047 /// value[8]?.f32: animation playback speed.
1048 ///
1049 ///
1050 ///
1051 /// Format of the return value [`ArkUI_AttributeItem`]:
1052 ///
1053 /// value[0].f32: translation distance along the x-axis, in vp.
1054 ///
1055 /// value[1].f32: translation distance along the y-axis, in vp.
1056 ///
1057 /// value[2].f32: translation distance along the z-axis, in vp.
1058 ///
1059 /// value[3].i32: animation duration, in milliseconds.
1060 ///
1061 /// value[4].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
1062 ///
1063 ///
1064 /// value[5].i32: animation delay duration, in milliseconds.
1065 ///
1066 /// value[6].i32: number of times that the animation is played.
1067 ///
1068 /// value[7].i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
1069 ///
1070 /// value[8].f32: animation playback speed.
1071 pub const NODE_TRANSLATE_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(37);
1072 /// Defines the slide-in and slide-out of the component from the screen edge during transition.
1073 /// This attribute can be set, reset, and obtained as required through APIs.
1074 ///
1075 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1076 ///
1077 /// .value[0].i32: The parameter type is [`ArkUI_TransitionEdge`].
1078 ///
1079 /// .value[1].i32: animation duration, in milliseconds.
1080 ///
1081 /// .value[2].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
1082 ///
1083 /// .value[3]?.i32: animation delay duration, in milliseconds.
1084 ///
1085 /// .value[4]?.i32: number of times that the animation is played.
1086 ///
1087 /// .value[5]?.i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
1088 ///
1089 /// .value[6]?.f32: animation playback speed.
1090 ///
1091 ///
1092 ///
1093 /// Format of the return value [`ArkUI_AttributeItem`]:
1094 ///
1095 /// .value[0].i32: The parameter type is [`ArkUI_TransitionEdge`].
1096 ///
1097 /// .value[1].i32: animation duration, in milliseconds.
1098 ///
1099 /// .value[2].i32: animation curve type. The value is an enum of [`ArkUI_AnimationCurve`].
1100 ///
1101 /// .value[3].i32: animation delay duration, in milliseconds.
1102 ///
1103 /// .value[4].i32: number of times that the animation is played.
1104 ///
1105 /// .value[5].i32: animation playback mode. The value is an enum of [`ArkUI_AnimationPlayMode`].
1106 ///
1107 /// .value[6].f32: animation playback speed.
1108 pub const NODE_MOVE_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(38);
1109 /// Defines the focus attribute, which can be set, reset, and obtained as required through APIs.
1110 ///
1111 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1112 ///
1113 /// .value[0].i32: The parameter type is 1 or 0.
1114 ///
1115 ///
1116 /// Format of the return value [`ArkUI_AttributeItem`]:
1117 ///
1118 /// .value[0].i32: The parameter type is 1 or 0.
1119 pub const NODE_FOCUSABLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(39);
1120 /// Defines the default focus attribute, which can be set, reset, and obtained as required through APIs.
1121 ///
1122 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1123 ///
1124 /// value[0].i32: The parameter type is 1 or 0.
1125 ///
1126 ///
1127 /// Format of the return value [`ArkUI_AttributeItem`]:
1128 ///
1129 /// value[0].i32: The parameter type is 1 or 0.
1130 pub const NODE_DEFAULT_FOCUS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(40);
1131 /// Defines the touch target attribute, which can be set, reset, and obtained as required through APIs.
1132 ///
1133 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1134 ///
1135 /// .data[0].f32: X coordinate of the touch point relative to the upper left corner of the component, in vp.
1136 ///
1137 /// .data[1].f32: Y coordinate of the touch point relative to the upper left corner of the component, in vp.
1138 ///
1139 /// .data[2].f32: width of the touch target, in %.
1140 ///
1141 /// .data[3].f32: height of the touch target, in %.
1142 ///
1143 /// .data[4...].f32: Multiple touch targets can be set. The sequence of the parameters is the same as the preceding.
1144 ///
1145 ///
1146 /// Format of the return value [`ArkUI_AttributeItem`]:
1147 ///
1148 /// .data[0].f32: X coordinate of the touch point relative to the upper left corner of the component, in vp.
1149 ///
1150 /// .data[1].f32: Y coordinate of the touch point relative to the upper left corner of the component, in vp.
1151 ///
1152 /// .data[2].f32: width of the touch target, in %.
1153 ///
1154 /// .data[3].f32: height of the touch target, in %.
1155 ///
1156 /// .data[4...].f32: Multiple touch targets can be set. The sequence of the parameters is the same as the preceding.
1157 pub const NODE_RESPONSE_REGION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(41);
1158 /// Defines the overlay attribute, which can be set, reset, and obtained as required through APIs.
1159 ///
1160 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1161 ///
1162 /// .string: mask text.
1163 ///
1164 /// .value[0]?.i32: position of the overlay relative to the component. Optional.
1165 /// The parameter type is [`ArkUI_Alignment`].
1166 /// The default value is <b>ARKUI_ALIGNMENT_TOP_START.</b>
1167 ///
1168 /// .value[1]?.f32: offset of the overlay relative to the upper left corner of itself on the x-axis, in vp. Optional.
1169 ///
1170 /// .value[2]?.f32: offset of the overlay relative to the upper left corner of itself on the y-axis, in vp. Optional.
1171 ///
1172 ///
1173 /// Format of the return value [`ArkUI_AttributeItem`]:
1174 ///
1175 /// .string: mask text.
1176 ///
1177 /// .value[0].i32: position of the overlay relative to the component.
1178 /// The parameter type is [`ArkUI_Alignment`].
1179 /// The default value is <b>ARKUI_ALIGNMENT_TOP_START.</b>
1180 ///
1181 /// .value[1].f32: offset of the overlay relative to the upper left corner of itself on the x-axis, in vp.
1182 ///
1183 /// .value[2].f32: offset of the overlay relative to the upper left corner of itself on the y-axis, in vp.
1184 pub const NODE_OVERLAY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(42);
1185 /// Defines the sweep gradient effect.
1186 /// This attribute can be set, reset, and obtained as required through APIs.
1187 ///
1188 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1189 ///
1190 /// .value[0]?.f32: X coordinate of the sweep gradient center relative to the upper left corner of the component.
1191 ///
1192 /// .value[1]?.f32: Y coordinate of the sweep gradient center relative to the upper left corner of the component.
1193 ///
1194 /// .value[2]?.f32: start point of the sweep gradient. The default value is <b>0</b>.
1195 ///
1196 /// .value[3]?.f32: end point of the sweep gradient. The default value is <b>0</b>.
1197 ///
1198 /// .value[4]?.f32: rotation angle of the sweep gradient. The default value is <b>0</b>.
1199 ///
1200 /// .value[5]?.i32: whether the colors are repeated. The value <b>1</b> means that the colors are repeated,
1201 /// and <b>0</b> means the opposite.
1202 ///
1203 /// .object: array of color stops, each of which consists of a color and its stop position. Invalid colors are
1204 /// automatically skipped.
1205 ///
1206 /// colors: colors of the color stops.
1207 ///
1208 /// stops: stop positions of the color stops.
1209 ///
1210 /// size: number of colors.
1211 ///
1212 ///
1213 ///
1214 /// Format of the return value [`ArkUI_AttributeItem`]:
1215 ///
1216 /// .value[0].f32: X coordinate of the sweep gradient center relative to the upper left corner of the component.
1217 ///
1218 /// .value[1].f32: Y coordinate of the sweep gradient center relative to the upper left corner of the component.
1219 ///
1220 /// .value[2].f32: start point of the sweep gradient. The default value is <b>0</b>.
1221 ///
1222 /// .value[3].f32: end point of the sweep gradient. The default value is <b>0</b>.
1223 ///
1224 /// .value[4].f32: rotation angle of the sweep gradient. The default value is <b>0</b>.
1225 ///
1226 /// .value[5].i32: whether the colors are repeated. The value <b>1</b> means that the colors are repeated,
1227 /// and <b>0</b> means the opposite.
1228 ///
1229 /// .object: array of color stops, each of which consists of a color and its stop position. Invalid colors are
1230 /// automatically skipped.
1231 ///
1232 /// colors: colors of the color stops.
1233 ///
1234 /// stops: stop positions of the color stops.
1235 ///
1236 /// size: number of colors.
1237 pub const NODE_SWEEP_GRADIENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(43);
1238 /// Defines the radial gradient effect.
1239 /// This attribute can be set, reset, and obtained as required through APIs.
1240 ///
1241 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1242 ///
1243 /// .value[0]?.f32: X coordinate of the radial gradient center relative to the upper left corner of the component.
1244 ///
1245 /// .value[1]?.f32: Y coordinate of the radial gradient center relative to the upper left corner of the component.
1246 ///
1247 /// .value[2]?.f32: radius of the radial gradient. The default value is <b>0</b>.
1248 ///
1249 /// .value[3]?.i32: whether the colors are repeated. The value <b>1</b> means that the colors are repeated,
1250 /// and <b>0</b> means the opposite.
1251 ///
1252 /// .object: array of color stops, each of which consists of a color and its stop position. Invalid colors are
1253 /// automatically skipped.
1254 ///
1255 /// colors: colors of the color stops.
1256 ///
1257 /// stops: stop positions of the color stops.
1258 ///
1259 /// size: number of colors.
1260 ///
1261 ///
1262 ///
1263 /// Format of the return value [`ArkUI_AttributeItem`]:
1264 ///
1265 /// .value[0].f32: X coordinate of the radial gradient center relative to the upper left corner of the component.
1266 ///
1267 /// .value[1].f32: Y coordinate of the radial gradient center relative to the upper left corner of the component.
1268 ///
1269 /// .value[2].f32: radius of the radial gradient. The default value is <b>0</b>.
1270 ///
1271 /// .value[3].i32: whether the colors are repeated. The value <b>1</b> means that the colors are repeated,
1272 /// and <b>0</b> means the opposite.
1273 ///
1274 /// .object: array of color stops, each of which consists of a color and its stop position. Invalid colors are
1275 /// automatically skipped.
1276 ///
1277 /// colors: colors of the color stops.
1278 ///
1279 /// stops: stop positions of the color stops.
1280 ///
1281 /// size: number of colors.
1282 pub const NODE_RADIAL_GRADIENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(44);
1283 /// Adds a mask of the specified shape to the component.
1284 /// This attribute can be set, reset, and obtained as required through APIs.
1285 ///
1286 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute, which supports five types of
1287 /// shapes:
1288 ///
1289 /// 1. Rectangle:
1290 ///
1291 /// .value[0].u32 fill color, in 0xARGB format.
1292 ///
1293 /// .value[1].u32: stroke color, in 0xARGB format.
1294 ///
1295 /// .value[2].f32: stroke width, in vp.
1296 ///
1297 /// .value[3].i32: mask type. The parameter type is [`ArkUI_MaskType`].
1298 /// The value is <b>ARKUI_MASK_TYPE_RECTANGLE</b> for the rectangle shape.
1299 ///
1300 /// .value[4].f32: width of the rectangle.
1301 ///
1302 /// .value[5].f32: height of the rectangle.
1303 ///
1304 /// .value[6].f32: width of the rounded corner of the rectangle.
1305 ///
1306 /// .value[7].f32: height of the rounded corner of the rectangle.
1307 ///
1308 /// .value[8]?.f32: radius of the top left corner of the rectangular shape.
1309 ///
1310 /// .value[9]?.f32: radius of the bottom left corner of the rectangular shape.
1311 ///
1312 /// .value[10]?.f32: radius of the top right corner of the rectangular shape.
1313 ///
1314 /// .value[11]?.f32: radius of the bottom right corner of the rectangular shape.
1315 ///
1316 /// 2. Circle:
1317 ///
1318 /// .value[0].u32 fill color, in 0xARGB format.
1319 ///
1320 /// .value[1].u32: stroke color, in 0xARGB format.
1321 ///
1322 /// .value[2].f32: stroke width, in vp.
1323 ///
1324 /// .value[3].i32: mask type. The parameter type is [`ArkUI_MaskType`].
1325 /// The value is <b>ARKUI_MASK_TYPE_CIRCLE</b> for the circle shape.
1326 ///
1327 /// .value[4].f32: width of the circle.
1328 ///
1329 /// .value[5].f32: height of the circle.
1330 ///
1331 /// 3. Ellipse:
1332 ///
1333 /// .value[0].u32 fill color, in 0xARGB format.
1334 ///
1335 /// .value[1].u32: stroke color, in 0xARGB format.
1336 ///
1337 /// .value[2].f32: stroke width, in vp.
1338 ///
1339 /// .value[3].i32: mask type. The parameter type is [`ArkUI_MaskType`].
1340 /// The value is <b>ARKUI_MASK_TYPE_ELLIPSE</b> for the ellipse shape.
1341 ///
1342 /// .value[4].f32: width of the ellipse.
1343 ///
1344 /// .value[5].f32: height of the ellipse.
1345 ///
1346 /// 4. Path:
1347 ///
1348 /// .value[0].u32 fill color, in 0xARGB format.
1349 ///
1350 /// .value[1].u32: stroke color, in 0xARGB format.
1351 ///
1352 /// .value[2].f32: stroke width, in vp.
1353 ///
1354 /// .value[3].i32: mask type. The parameter type is [`ArkUI_MaskType`].
1355 /// The value is <b>ARKUI_MASK_TYPE_PATH</b> for the path shape.
1356 ///
1357 /// .value[4].f32: width of the path.
1358 ///
1359 /// .value[5].f32: height of the path.
1360 ///
1361 /// .string: command for drawing the path.
1362 ///
1363 /// 5. Progress:
1364 ///
1365 /// .value[0].i32: mask type. The parameter type is [`ArkUI_MaskType`].
1366 /// The value is <b>ARKUI_MASK_TYPE_PROGRESS</b> for the progress shape.
1367 ///
1368 /// .value[1].f32: current value of the progress indicator.
1369 ///
1370 /// .value[2].f32: maximum value of the progress indicator.
1371 ///
1372 /// .value[3].u32: color of the progress indicator, in 0xARGB format.
1373 ///
1374 ///
1375 ///
1376 /// Format of the return value [`ArkUI_AttributeItem`], which supports five types of shapes:
1377 ///
1378 /// 1. Rectangle:
1379 ///
1380 /// .value[0].u32 fill color, in 0xARGB format.
1381 ///
1382 /// .value[1].u32: stroke color, in 0xARGB format.
1383 ///
1384 /// .value[2].f32: stroke width, in vp.
1385 ///
1386 /// .value[3].i32: mask type.
1387 ///
1388 /// .value[4].f32: width of the rectangle.
1389 ///
1390 /// .value[5].f32: height of the rectangle.
1391 ///
1392 /// .value[6].f32: width of the rounded corner of the rectangle.
1393 ///
1394 /// .value[7].f32: height of the rounded corner of the rectangle.
1395 ///
1396 /// .value[8].f32: radius of the top left corner of the rectangular shape.
1397 ///
1398 /// .value[9].f32: radius of the bottom left corner of the rectangular shape.
1399 ///
1400 /// .value[10].f32: radius of the top right corner of the rectangular shape.
1401 ///
1402 /// .value[11].f32: radius of the bottom right corner of the rectangular shape.
1403 ///
1404 /// 2. Circle:
1405 ///
1406 /// .value[0].u32 fill color, in 0xARGB format.
1407 ///
1408 /// .value[1].u32: stroke color, in 0xARGB format.
1409 ///
1410 /// .value[2].f32: stroke width, in vp.
1411 ///
1412 /// .value[3].i32: mask type.
1413 ///
1414 /// .value[4].f32: width of the circle.
1415 ///
1416 /// .value[5].f32: height of the circle.
1417 ///
1418 /// 3. Ellipse:
1419 ///
1420 /// .value[0].u32 fill color, in 0xARGB format.
1421 ///
1422 /// .value[1].u32: stroke color, in 0xARGB format.
1423 ///
1424 /// .value[2].f32: stroke width, in vp.
1425 ///
1426 /// .value[3].i32: mask type.
1427 ///
1428 /// .value[4].f32: width of the ellipse.
1429 ///
1430 /// .value[5].f32: height of the ellipse.
1431 ///
1432 /// 4. Path:
1433 ///
1434 /// .value[0].u32 fill color, in 0xARGB format.
1435 ///
1436 /// .value[1].u32: stroke color, in 0xARGB format.
1437 ///
1438 /// .value[2].f32: stroke width, in vp.
1439 ///
1440 /// .value[3].i32: mask type.
1441 ///
1442 /// .value[4].f32: width of the path.
1443 ///
1444 /// .value[5].f32: height of the path.
1445 ///
1446 /// .string: command for drawing the path.
1447 ///
1448 /// 5. Progress:
1449 ///
1450 /// .value[0].i32: mask type.
1451 ///
1452 /// .value[1].f32: current value of the progress indicator.
1453 ///
1454 /// .value[2].f32: maximum value of the progress indicator.
1455 ///
1456 /// .value[3].u32: color of the progress indicator.
1457 pub const NODE_MASK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(45);
1458 /// Blends the component's background with the content of the component's child node.
1459 /// This attribute can be set, reset, and obtained as required through APIs.
1460 ///
1461 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1462 ///
1463 /// .value[0].i32: blend mode. The parameter type is [`ArkUI_BlendMode`]. The default value is
1464 /// <b>ARKUI_BLEND_MODE_NONE</b>.
1465 ///
1466 /// .value[1].?i32: how the specified blend mode is applied. The parameter type is [`ArkUI_BlendApplyType`].
1467 /// The default value is <b>ARKUI_BLEND_APPLY_TYPE_FAST</b>.
1468 ///
1469 ///
1470 ///
1471 /// Format of the return value [`ArkUI_AttributeItem`]:
1472 ///
1473 /// .value[0].i32: blend mode. The parameter type is [`ArkUI_BlendMode`]. The default value is
1474 /// <b>ARKUI_BLEND_MODE_NONE</b>.
1475 ///
1476 /// .value[1].i32: how the specified blend mode is applied. The parameter type is [`ArkUI_BlendApplyType`].
1477 /// The default value is <b>ARKUI_BLEND_APPLY_TYPE_FAST</b>.
1478 pub const NODE_BLEND_MODE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(46);
1479 /// Sets the direction of the main axis.
1480 /// This attribute can be set, reset, and obtained as required through APIs.
1481 ///
1482 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1483 ///
1484 /// .value[0].i32: direction of the main axis.
1485 ///
1486 /// The parameter type is [`ArkUI_Direction`]. The default value is <b>ARKUI_DIRECTION_AUTO</b>.
1487 ///
1488 ///
1489 ///
1490 /// Format of the return value [`ArkUI_AttributeItem`]:
1491 ///
1492 /// .value[0].i32: direction of the main axis.
1493 ///
1494 /// The parameter type is [`ArkUI_Direction`]. The default value is <b>ARKUI_DIRECTION_AUTO</b>.
1495 pub const NODE_DIRECTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(47);
1496 /// Defines the size constraints.
1497 /// This attribute can be set, reset, and obtained as required through APIs.
1498 ///
1499 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1500 ///
1501 /// .value[0].f32: minimum width, in vp.
1502 ///
1503 /// .value[1].f32: maximum width, in vp.
1504 ///
1505 /// .value[2].f32: minimum height, in vp.
1506 ///
1507 /// .value[3].f32: maximum height, in vp.
1508 ///
1509 ///
1510 ///
1511 /// Format of the return value [`ArkUI_AttributeItem`]:
1512 ///
1513 /// .value[0].f32: minimum width, in vp.
1514 ///
1515 /// .value[1].f32: maximum width, in vp.
1516 ///
1517 /// .value[2].f32: minimum height, in vp.
1518 ///
1519 /// .value[3].f32: maximum height, in vp.
1520 pub const NODE_CONSTRAINT_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(48);
1521 /// Defines the grayscale effect.
1522 /// This attribute can be set, reset, and obtained as required through APIs.
1523 ///
1524 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1525 ///
1526 /// .value[0].f32: grayscale conversion ratio. The value ranges from 0 to 1.
1527 /// For example, 0.5 indicates a 50% grayscale conversion ratio.
1528 ///
1529 ///
1530 ///
1531 /// Format of the return value [`ArkUI_AttributeItem`]:
1532 ///
1533 /// .value[0].f32: grayscale conversion ratio. The value ranges from 0 to 1.
1534 pub const NODE_GRAY_SCALE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(49);
1535 /// Inverts the image.
1536 /// This attribute can be set, reset, and obtained as required through APIs.
1537 ///
1538 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1539 ///
1540 /// .value[0].f32: image inversion ratio. The value ranges from 0 to 1.
1541 /// For example, 0.5 indicates a 50% image inversion ratio.
1542 ///
1543 ///
1544 ///
1545 /// Format of the return value [`ArkUI_AttributeItem`]:
1546 ///
1547 /// .value[0].f32: image inversion ratio. The value ranges from 0 to 1.
1548 pub const NODE_INVERT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(50);
1549 /// Defines the sepia conversion ratio.
1550 /// This attribute can be set, reset, and obtained as required through APIs.
1551 ///
1552 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1553 ///
1554 /// .value[0].f32: sepia conversion ratio. The value ranges from 0 to 1.
1555 /// For example, 0.5 indicates that a 50% sepia conversion ratio.
1556 ///
1557 ///
1558 ///
1559 /// Format of the return value [`ArkUI_AttributeItem`]:
1560 ///
1561 /// .value[0].f32: sepia conversion ratio. The value ranges from 0 to 1.
1562 pub const NODE_SEPIA: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(51);
1563 /// Defines the contrast attribute, which can be set, reset, and obtained as required through APIs.
1564 ///
1565 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1566 ///
1567 /// .value[0].f32: contrast. If the value is <b>1</b>, the source image is displayed.
1568 /// A larger value indicates a higher contrast. Value range: [0, 10).
1569 ///
1570 ///
1571 ///
1572 /// Format of the return value [`ArkUI_AttributeItem`]:
1573 ///
1574 /// .value[0].f32: contrast. Value range: [0, 10).
1575 pub const NODE_CONTRAST: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(52);
1576 /// Defines the foreground color attribute, which can be set, reset, and obtained as required through APIs.
1577 ///
1578 /// There are two formats of [`ArkUI_AttributeItem`] for setting the attribute value:
1579 ///
1580 /// 1: .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
1581 ///
1582 /// 2: .value[0].i32: color enum [`ArkUI_ColoringStrategy`].
1583 ///
1584 ///
1585 ///
1586 /// Format of the return value [`ArkUI_AttributeItem`]:
1587 ///
1588 /// .value[0].u32: color value, in 0xARGB format.
1589 pub const NODE_FOREGROUND_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(53);
1590 /// Defines the offset of the component's child relative to the component.
1591 /// This attribute can be set, reset, and obtained as required through APIs.
1592 ///
1593 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1594 ///
1595 /// .value[0].f32 : offset along the x-axis, in vp.
1596 ///
1597 /// .value[1].f32 : offset along the y-axis, in vp.
1598 ///
1599 ///
1600 ///
1601 /// Format of the return value [`ArkUI_AttributeItem`]:
1602 ///
1603 /// .value[0].f32 : offset along the x-axis, in vp.
1604 ///
1605 /// .value[1].f32 : offset along the y-axis, in vp.
1606 pub const NODE_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(54);
1607 /// Sets the anchor for locating the component's child.
1608 /// This attribute can be set, reset, and obtained as required through APIs.
1609 ///
1610 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1611 ///
1612 /// .value[0].f32: X coordinate of the anchor, in vp.
1613 ///
1614 /// .value[1].f32: Y coordinate of the anchor, in vp.
1615 ///
1616 ///
1617 ///
1618 /// Format of the return value [`ArkUI_AttributeItem`]:
1619 ///
1620 /// .value[0].f32: X coordinate of the anchor, in vp.
1621 ///
1622 /// .value[1].f32: Y coordinate of the anchor, in vp.
1623 pub const NODE_MARK_ANCHOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(55);
1624 /// Defines the position of the background image in the component, that is, the coordinates relative to
1625 /// the upper left corner of the component. This attribute can be set, reset, and obtained as required through APIs.
1626 ///
1627 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1628 ///
1629 /// .value[0].f32: position along the x-axis, in px.
1630 ///
1631 /// .value[1].f32: position along the y-axis, in px.
1632 ///
1633 ///
1634 ///
1635 /// Format of the return value [`ArkUI_AttributeItem`]:
1636 ///
1637 /// .value[0].f32: position along the x-axis, in px.
1638 ///
1639 /// .value[1].f32: position along the y-axis, in px.
1640 pub const NODE_BACKGROUND_IMAGE_POSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(56);
1641 /// Sets the alignment rules in the relative container.
1642 /// This attribute can be set, reset, and obtained as required through APIs.
1643 ///
1644 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1645 ///
1646 /// .object: Use the [`ArkUI_AlignmentRuleOption`] object as the component’s alignment rule.
1647 ///
1648 ///
1649 ///
1650 /// Format of the return value [`ArkUI_AttributeItem`]:
1651 ///
1652 /// .object: Use the [`ArkUI_AlignmentRuleOption`] object as the component’s alignment rule.
1653 pub const NODE_ALIGN_RULES: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(57);
1654 /// Sets the alignment mode of the child components along the cross axis of the parent container.
1655 /// This attribute can be set, reset, and obtained as required through APIs.
1656 ///
1657 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1658 ///
1659 /// .value[0].i32: alignment mode of the child components along the cross axis of the parent container.
1660 ///
1661 /// The parameter type is [`ArkUI_ItemAlignment`]. The default value is <b>ARKUI_ITEM_ALIGNMENT_AUTO</b>.
1662 ///
1663 ///
1664 ///
1665 /// Format of the return value [`ArkUI_AttributeItem`]:
1666 ///
1667 /// .value[0].i32: alignment mode of the child components along the cross axis of the parent container.
1668 ///
1669 /// The parameter type is [`ArkUI_ItemAlignment`]. The default value is <b>ARKUI_ITEM_ALIGNMENT_AUTO</b>.
1670 pub const NODE_ALIGN_SELF: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(58);
1671 /// Sets the percentage of the parent container's remaining space that is allocated to the component.
1672 /// This attribute can be set, reset, and obtained as required through APIs.
1673 ///
1674 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1675 ///
1676 /// .value[0].f32: percentage of the parent container's remaining space that is allocated to the component.
1677 ///
1678 ///
1679 ///
1680 /// Format of the return value [`ArkUI_AttributeItem`]:
1681 ///
1682 /// .value[0].f32: percentage of the parent container's remaining space that is allocated to the component.
1683 pub const NODE_FLEX_GROW: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(59);
1684 /// Sets the percentage of the parent container's shrink size that is allocated to the component.
1685 /// This attribute can be set, reset, and obtained as required through APIs.
1686 ///
1687 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1688 ///
1689 /// .value[0].f32: percentage of the parent container's shrink size that is allocated to the component.
1690 ///
1691 ///
1692 ///
1693 /// Format of the return value [`ArkUI_AttributeItem`]:
1694 ///
1695 /// .value[0].f32: percentage of the parent container's shrink size that is allocated to the component.
1696 pub const NODE_FLEX_SHRINK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(60);
1697 /// Sets the base size of the component.
1698 /// This attribute can be set, reset, and obtained as required through APIs.
1699 ///
1700 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1701 ///
1702 /// .value[0].f32: percentage of the parent container's remaining space that is allocated to the component.
1703 ///
1704 ///
1705 ///
1706 /// Format of the return value [`ArkUI_AttributeItem`]:
1707 ///
1708 /// .value[0].f32: percentage of the parent container's remaining space that is allocated to the component.
1709 pub const NODE_FLEX_BASIS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(61);
1710 /// Sets the accessibility group. This attribute can be set, reset, and obtained as required through APIs.
1711 ///
1712 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1713 ///
1714 /// .value[0].i32: Accessibility group. The value <b>1</b> means that the component and all its child components
1715 /// form an entire selectable component.
1716 /// In this case, the accessibility service will no longer be available for the content of its child components.
1717 /// The value is <b>1</b> or <b>0</b>.
1718 ///
1719 ///
1720 /// Format of the return value [`ArkUI_AttributeItem`]:
1721 ///
1722 /// .value[0].i32: Accessibility group. The value <b>1</b> means that the component and all its child components
1723 /// form an entire selectable component.
1724 /// In this case, the accessibility service will no longer be available for the content of its child components.
1725 /// The value is <b>1</b> or <b>0</b>.
1726 pub const NODE_ACCESSIBILITY_GROUP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(62);
1727 /// Sets the accessibility text. This attribute can be set, reset, and obtained as required through APIs.
1728 ///
1729 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1730 ///
1731 /// .string: accessibility text.
1732 ///
1733 ///
1734 /// Format of the return value [`ArkUI_AttributeItem`]:
1735 ///
1736 /// .string: accessibility text.
1737 pub const NODE_ACCESSIBILITY_TEXT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(63);
1738 /// Sets the accessibility service model. This attribute can be set, reset, and obtained as required through APIs.
1739 ///
1740 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1741 ///
1742 /// .value[0].i32: accessibility service model. The parameter type is [`ArkUI_AccessibilityMode`].
1743 ///
1744 ///
1745 /// Format of the return value [`ArkUI_AttributeItem`]:
1746 ///
1747 /// .value[0].i32: accessibility service model. The parameter type is [`ArkUI_AccessibilityMode`].
1748 pub const NODE_ACCESSIBILITY_MODE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(64);
1749 /// Sets the accessibility description.
1750 /// This attribute can be set, reset, and obtained as required through APIs.
1751 ///
1752 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1753 ///
1754 /// .string: accessibility description.
1755 ///
1756 ///
1757 /// Format of the return value [`ArkUI_AttributeItem`]:
1758 ///
1759 /// .string: accessibility description.
1760 pub const NODE_ACCESSIBILITY_DESCRIPTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(65);
1761 /// Defines the focused state. This attribute can be set and obtained as required through APIs.
1762 ///
1763 /// **Note:** Setting the parameter to <b>0</b> shifts focus from the currently focused component on the current level
1764 /// of the page to the root container.
1765 ///
1766 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1767 ///
1768 /// .value[0].i32: The parameter type is 1 or 0.
1769 ///
1770 ///
1771 /// Format of the return value [`ArkUI_AttributeItem`]:
1772 ///
1773 /// .value[0].i32: The parameter type is 1 or 0.
1774 pub const NODE_FOCUS_STATUS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(66);
1775 /// Defines the aspect ratio attribute, which can be set, reset, and obtained as required through APIs.
1776 ///
1777 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1778 ///
1779 /// .value[0].f32: aspect ratio of the component, in width/height format.
1780 ///
1781 ///
1782 ///
1783 /// Format of the return value [`ArkUI_AttributeItem`]:
1784 ///
1785 /// .value[0].f32: aspect ratio of the component, in width/height format.
1786 pub const NODE_ASPECT_RATIO: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(67);
1787 /// Defines the weight of the component within its row, column, or flex container for proportional
1788 /// distribution of available space within the container.
1789 /// This attribute can be set, reset, and obtained as required through APIs.
1790 ///
1791 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1792 ///
1793 /// .value[0].u32: weight of the component along the main axis.
1794 ///
1795 ///
1796 ///
1797 /// Format of the return value [`ArkUI_AttributeItem`]:
1798 ///
1799 /// .value[0].u32: weight of the component along the main axis.
1800 pub const NODE_LAYOUT_WEIGHT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(68);
1801 /// Sets the display priority for the component in the row, column, or flex (single-line) container.
1802 /// This attribute can be set, reset, and obtained as required through APIs.
1803 ///
1804 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1805 ///
1806 /// .value[0].u32: display priority of the component in the container.
1807 ///
1808 ///
1809 ///
1810 /// Format of the return value [`ArkUI_AttributeItem`]:
1811 ///
1812 /// .value[0].u32: display priority of the component in the container.
1813 pub const NODE_DISPLAY_PRIORITY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(69);
1814 /// Sets the thickness of an element's outline.
1815 ///
1816 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1817 ///
1818 /// .value[0].f32: thickness of the left outline.
1819 ///
1820 /// .value[1].f32: thickness of the top outline.
1821 ///
1822 /// .value[2].f32: thickness of the right outline.
1823 ///
1824 /// .value[3].f32: thickness of the bottom outline.
1825 ///
1826 ///
1827 ///
1828 /// Format of the return value [`ArkUI_AttributeItem`]:
1829 ///
1830 /// .value[0].f32: thickness of the left outline.
1831 ///
1832 /// .value[1].f32: thickness of the top outline.
1833 ///
1834 /// .value[2].f32: thickness of the right outline.
1835 ///
1836 /// .value[3].f32: thickness of the bottom outline.
1837 pub const NODE_OUTLINE_WIDTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(70);
1838 /// Defines the width attribute, which can be set, reset, and obtained as required through APIs.
1839 ///
1840 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1841 ///
1842 /// .value[0].f32: width, in percentage.
1843 ///
1844 ///
1845 ///
1846 /// Format of the return value [`ArkUI_AttributeItem`]:
1847 ///
1848 /// .value[0].f32: width, in percentage.
1849 pub const NODE_WIDTH_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(71);
1850 /// Defines the height attribute, which can be set, reset, and obtained as required through APIs.
1851 ///
1852 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1853 ///
1854 /// .value[0].f32: height, in percentage.
1855 ///
1856 ///
1857 ///
1858 /// Format of the return value [`ArkUI_AttributeItem`]:
1859 ///
1860 /// .value[0].f32: height, in percentage.
1861 pub const NODE_HEIGHT_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(72);
1862 /// Defines the padding attribute, which can be set, reset, and obtained as required through APIs.
1863 ///
1864 /// There are two formats of [`ArkUI_AttributeItem`] for setting the attribute value:
1865 ///
1866 /// 1: Specify the same padding for the four directions.
1867 ///
1868 /// .value[0].f32: padding, in percentage.
1869 ///
1870 /// 2: Specify different paddings for different directions.
1871 ///
1872 /// .value[0].f32: top padding, in percentage.
1873 ///
1874 /// .value[1].f32: right padding, in percentage.
1875 ///
1876 /// .value[2].f32: bottom padding, in percentage.
1877 ///
1878 /// .value[3].f32: left padding, in percentage.
1879 ///
1880 ///
1881 ///
1882 /// Format of the return value [`ArkUI_AttributeItem`]:
1883 ///
1884 /// .value[0].f32: top padding, in percentage.
1885 ///
1886 /// .value[1].f32: right padding, in percentage.
1887 ///
1888 /// .value[2].f32: bottom padding, in percentage.
1889 ///
1890 /// .value[3].f32: left padding, in percentage.
1891 pub const NODE_PADDING_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(73);
1892 /// Defines the margin attribute, which can be set, reset, and obtained as required through APIs.
1893 ///
1894 /// There are two formats of [`ArkUI_AttributeItem`] for setting the attribute value:
1895 ///
1896 /// 1: Specify the same margin for the four directions.
1897 ///
1898 /// .value[0].f32: margin, in percentage.
1899 ///
1900 /// 2: Specify different margins for different directions.
1901 ///
1902 /// .value[0].f32: top margin, in percentage.
1903 ///
1904 /// .value[1].f32: right margin, in percentage.
1905 ///
1906 /// .value[2].f32: bottom margin, in percentage.
1907 ///
1908 /// .value[3].f32: left margin, in percentage.
1909 ///
1910 ///
1911 ///
1912 /// Format of the return value [`ArkUI_AttributeItem`]:
1913 ///
1914 /// .value[0].f32: top margin, in percentage.
1915 ///
1916 /// .value[1].f32: right margin, in percentage.
1917 ///
1918 /// .value[2].f32: bottom margin, in percentage.
1919 ///
1920 /// .value[3].f32: left margin, in percentage.
1921 pub const NODE_MARGIN_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(74);
1922 /// The implicit shared element transition within the component supports attribute setting,
1923 /// attribute reset, and attribute acquisition interfaces.
1924 ///
1925 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
1926 ///
1927 /// .value[0]?.i32: The parameter type is 1 or 0. 2 components that share element bindings,
1928 /// Whether to continue to participate in the shared element animation when the appearance element is not deleted,
1929 /// the default is false, and the original position will remain unchanged if not involved.
1930 ///
1931 /// .string is used to set the binding relationship. Set the id to "" to
1932 /// clear the binding relationship to avoid participating in sharing behavior.
1933 ///
1934 /// The id can be changed and the binding relationship re-established.
1935 /// The same ID can only be bound to two components and they are in/out roles of different types.
1936 /// Multiple components cannot be bound to the same id.
1937 ///
1938 ///
1939 ///
1940 /// Attribute acquisition method return value [`ArkUI_AttributeItem`] format:
1941 ///
1942 /// .value[0].i32: The parameter type is 1 or 0. 2 components that share element bindings,
1943 /// Whether to continue to participate in the shared element animation when the appearance element is not deleted,
1944 /// the default is not false, if not involved, the original position will remain unchanged.
1945 ///
1946 /// .string is used to set the binding relationship. Set the id to "" to
1947 /// clear the binding relationship to avoid participating in sharing behavior.
1948 ///
1949 /// The id can be changed and the binding relationship re-established.
1950 /// The same ID can only be bound to two components and they are in/out roles of different types.
1951 /// Multiple components cannot be bound to the same id.
1952 pub const NODE_GEOMETRY_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(75);
1953 /// specifies the parameters of the chain formed by this component as the chain head,
1954 /// and supports attribute setting, attribute reset and attribute acquisition interfaces.
1955 ///
1956 /// Only takes effect when the parent container is RelativeContainer
1957 ///
1958 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
1959 ///
1960 /// .value[0].i32: The direction of the chain. Enum [`ArkUI_Axis`].
1961 ///
1962 /// .value[1].i32: Chain style. Enum [`ArkUI_RelativeLayoutChainStyle`].
1963 ///
1964 ///
1965 ///
1966 /// .value[0].i32: The direction of the chain. Enum [`ArkUI_Axis`].
1967 ///
1968 /// .value[1].i32: Chain style. Enum [`ArkUI_RelativeLayoutChainStyle`].
1969 pub const NODE_RELATIVE_LAYOUT_CHAIN_MODE: ArkUI_NodeAttributeType =
1970 ArkUI_NodeAttributeType(76);
1971 /// Set the component content filling method in the process of width and height animation,
1972 /// support property setting, property reset, property acquisition interface.
1973 ///
1974 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1975 ///
1976 /// .value[0].i32 Content filling mode [`ArkUI_RenderFit`].
1977 ///
1978 ///
1979 ///
1980 /// Format of the return value [`ArkUI_AttributeItem`]:
1981 ///
1982 /// .value[0].i32 Content filling mode [`ArkUI_RenderFit`].
1983 pub const NODE_RENDER_FIT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(77);
1984 /// External stroke color properties, support property setting,
1985 /// property reset and property acquisition interface.
1986 ///
1987 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
1988 ///
1989 /// 1: .value[0].u32: Set the border color of the four sides uniformly, using 0xargb, such as 0xFFFF11FF.
1990 ///
1991 /// 2: .value[0].u32: Set the top border color, represented by 0xargb, such as 0xFFFF11FF.
1992 ///
1993 /// .value[1].u32: Set the right border color, represented by 0xargb, such as 0xFFFF11FF.
1994 ///
1995 /// .value[2].u32: Set the lower side box color, denoted by 0xargb, such as 0xFFFF11FF.
1996 ///
1997 /// .value[3].u32: Set the left border color, denoted by 0xargb, such as 0xFFFF11FF.
1998 ///
1999 ///
2000 ///
2001 /// Format of the return value [`ArkUI_AttributeItem`]:
2002 ///
2003 /// .value[0].u32: Set the top border color, represented by 0xargb, such as 0xFFFF11FF.
2004 ///
2005 /// .value[1].u32: Set the right border color, represented by 0xargb, such as 0xFFFF11FF.
2006 ///
2007 /// .value[2].u32: Set the lower side box color, denoted by 0xargb, such as 0xFFFF11FF.
2008 ///
2009 /// .value[3].u32: Set the left border color, denoted by 0xargb, such as 0xFFFF11FF.
2010 pub const NODE_OUTLINE_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(78);
2011 /// Set the height and width dimensions, support property setting,
2012 /// property reset and property acquisition interface.
2013 ///
2014 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2015 ///
2016 /// .value[0].f32: Width value, unit is vp;
2017 ///
2018 /// .value[1].f32: Height value, unit is vp;
2019 ///
2020 ///
2021 ///
2022 /// Format of the return value [`ArkUI_AttributeItem`]:
2023 ///
2024 /// .value[0].f32: Width value, unit is vp;
2025 ///
2026 /// .value[1].f32: Height value, unit is vp;
2027 pub const NODE_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(79);
2028 /// Set whether the current component and child component are
2029 /// rendered off the screen first and then fused with the parent control,
2030 /// supporting property setting, property reset and property acquisition.
2031 ///
2032 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2033 ///
2034 /// .value[0].i32: The parameter type is 1 or 0.
2035 ///
2036 ///
2037 /// Format of the return value [`ArkUI_AttributeItem`]:
2038 ///
2039 /// .value[0].i32: The parameter type is 1 or 0.
2040 pub const NODE_RENDER_GROUP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(80);
2041 /// Add color overlay effect to components, support property setting,
2042 /// property reset and property acquisition interface.
2043 ///
2044 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2045 ///
2046 /// .value[0].u32: The color of the overlay is represented by 0xargb, such as 0xFFFF11FF.
2047 ///
2048 ///
2049 ///
2050 /// Format of the return value [`ArkUI_AttributeItem`]:
2051 ///
2052 /// .value[0].u32: The color of the overlay is represented by 0xargb, such as 0xFFFF11FF.
2053 pub const NODE_COLOR_BLEND: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(81);
2054 /// Provide content ambiguity capability for the current component,
2055 /// support property setting, property reset, property acquisition interface.
2056 ///
2057 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2058 ///
2059 /// .value[0].i32 Represents the content blurring style, and uses the [`ArkUI_BlurStyle`] enumeration value.
2060 ///
2061 /// .value[1]?.i32 Represents the dark and light mode used by the content blur effect,
2062 ///
2063 /// with the [`ArkUI_ThemeColorMode`] enumeration value.
2064 ///
2065 /// .value[2]?.i32 The color extraction mode used to represent the content blur effect takes
2066 ///
2067 /// the [`ArkUI_AdaptiveColor`] enumeration value.
2068 ///
2069 /// .value[3]?.f32: blur degree. The value range is [0.0, 1.0].
2070 ///
2071 /// .value[4]?.f32 It is a gray-level fuzzy parameter. The value range is [0,127].
2072 ///
2073 /// .value[5]?.f32 It is a gray-level fuzzy parameter. The value range is [0,127].
2074 ///
2075 ///
2076 ///
2077 /// Format of the return value [`ArkUI_AttributeItem`]:
2078 ///
2079 /// .value[0].i32 Represents the content blurring style, and uses the [`ArkUI_BlurStyle`] enumeration value.
2080 ///
2081 /// .value[1].i32 Represents the dark and light mode used by the content blur effect,
2082 ///
2083 /// with the [`ArkUI_ThemeColorMode`] enumeration value.
2084 ///
2085 /// .value[2].i32 The color extraction mode used to represent the content blur effect takes
2086 ///
2087 /// the [`ArkUI_AdaptiveColor`] enumeration value.
2088 ///
2089 /// .value[3].f32: blur degree. The value range is [0.0, 1.0].
2090 ///
2091 /// .value[4].f32 It is a gray-level fuzzy parameter. The value range is [0,127].
2092 ///
2093 /// .value[5].f32 It is a gray-level fuzzy parameter. The value range is [0,127].
2094 pub const NODE_FOREGROUND_BLUR_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(82);
2095 /// Defines the component size and position for layout.
2096 /// This attribute can be set, reset, and obtained as required through APIs.
2097 ///
2098 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2099 ///
2100 /// .value[0].i32: X coordinate of the component, in px.
2101 ///
2102 /// .value[1].i32: Y coordinate of the component, in px.
2103 ///
2104 /// .value[2].i32: width of the component, in px.
2105 ///
2106 /// .value[3].i32: height of the component, in px.
2107 ///
2108 ///
2109 ///
2110 /// Format of the return value [`ArkUI_AttributeItem`]:
2111 ///
2112 /// .value[0].i32: X coordinate of the component, in px.
2113 ///
2114 /// .value[1].i32: Y coordinate of the component, in px.
2115 ///
2116 /// .value[2].i32: width of the component, in px.
2117 ///
2118 /// .value[3].i32: height of the component, in px.
2119 pub const NODE_LAYOUT_RECT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(83);
2120 /// Whether the current component supports click-to-focus capability,
2121 /// which can be set, reset, and obtained as required through APIs.
2122 ///
2123 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2124 ///
2125 /// .value[0].i32: The parameter type is 1 or 0.
2126 ///
2127 ///
2128 /// Format of the return value [`ArkUI_AttributeItem`]:
2129 ///
2130 /// .value[0].i32: The parameter type is 1 or 0.
2131 pub const NODE_FOCUS_ON_TOUCH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(84);
2132 /// Defines the border width attribute, which can be set, reset, and obtained as required through APIs.
2133 ///
2134 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2135 ///
2136 /// 1: .value[0].f32: width of the four borders, in percentage.
2137 ///
2138 /// 2: .value[0].f32: width of the top border, in percentage.
2139 ///
2140 /// .value[1].f32: width of the right border, in percentage.
2141 ///
2142 /// .value[2].f32: width of the bottom border, in percentage.
2143 ///
2144 /// .value[3].f32: width of the left border, in percentage.
2145 ///
2146 ///
2147 ///
2148 /// Format of the return value [`ArkUI_AttributeItem`]:
2149 ///
2150 /// .value[0].f32: width of the top border, in percentage.
2151 ///
2152 /// .value[1].f32: width of the right border, in percentage.
2153 ///
2154 /// .value[2].f32: width of the bottom border, in percentage.
2155 ///
2156 /// .value[3].f32: width of the left border, in percentage.
2157 pub const NODE_BORDER_WIDTH_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(85);
2158 /// Defines the border corner radius attribute, which can be set, reset, and obtained as required through APIs.
2159 ///
2160 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2161 ///
2162 /// 1: .value[0].f32: radius of the four corners, in percentage.
2163 ///
2164 /// 2: .value[0].f32: radius of the upper left corner, in percentage.
2165 ///
2166 /// .value[1].f32: radius of the upper right corner, in percentage.
2167 ///
2168 /// .value[2].f32: radius of the lower left corner, in percentage.
2169 ///
2170 /// .value[3].f32: radius of the lower right corner, in percentage.
2171 ///
2172 ///
2173 ///
2174 /// Format of the return value [`ArkUI_AttributeItem`]:
2175 ///
2176 /// .value[0].f32: radius of the upper left corner, in percentage.
2177 ///
2178 /// .value[1].f32: radius of the upper right corner, in percentage.
2179 ///
2180 /// .value[2].f32: radius of the lower left corner, in percentage.
2181 ///
2182 /// .value[3].f32: radius of the lower right corner, in percentage.
2183 pub const NODE_BORDER_RADIUS_PERCENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(86);
2184 /// Accessible ID, which can be obtained as required through APIs.
2185 ///
2186 /// Format of the return value [`ArkUI_AttributeItem`]:
2187 ///
2188 /// .value[0].i32:Accessible ID。
2189 pub const NODE_ACCESSIBILITY_ID: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(87);
2190 /// Define accessible actions, which can be set, reset, and obtained as required through APIs.
2191 ///
2192 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2193 ///
2194 /// .value[0].u32:accessible action types,and uses the [`ArkUI_AccessibilityActionType`] enumeration value.
2195 ///
2196 ///
2197 ///
2198 /// Format of the return value [`ArkUI_AttributeItem`]:
2199 ///
2200 /// .value[0].u32:accessible action types,and uses the [`ArkUI_AccessibilityActionType`] enumeration value.
2201 pub const NODE_ACCESSIBILITY_ACTIONS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(88);
2202 /// Define accessible role, which can be set, reset, and obtained as required through APIs.
2203 ///
2204 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2205 ///
2206 /// .value[0].u32:accessible role type,and uses the [`ArkUI_NodeType`] enumeration value.
2207 ///
2208 ///
2209 ///
2210 /// Format of the return value [`ArkUI_AttributeItem`]:
2211 ///
2212 /// .value[0].u32:accessible role type,and uses the [`ArkUI_NodeType`] enumeration value.
2213 pub const NODE_ACCESSIBILITY_ROLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(89);
2214 /// Define accessible state, which can be set, reset, and obtained as required through APIs.
2215 ///
2216 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2217 ///
2218 /// .object:the parameter type is [`ArkUI_AccessibilityState`].
2219 ///
2220 ///
2221 ///
2222 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2223 ///
2224 /// .object:the parameter type is [`ArkUI_AccessibilityState`].
2225 pub const NODE_ACCESSIBILITY_STATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(90);
2226 /// Define accessible value, which can be set, reset, and obtained as required through APIs.
2227 ///
2228 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2229 ///
2230 /// .object:the parameter type is [`ArkUI_AccessibilityValue`].
2231 ///
2232 ///
2233 ///
2234 /// Format of the return value [`ArkUI_AttributeItem`]:
2235 ///
2236 /// .object:the parameter type is [`ArkUI_AccessibilityValue`].
2237 pub const NODE_ACCESSIBILITY_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(91);
2238 /// defines control components to extend their security zones,
2239 /// supporting property setting, property reset, and property fetching.
2240 ///
2241 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
2242 ///
2243 /// .value[0]? .u32: Set of extended security zone enumerated values [`ArkUI_SafeAreaType`],
2244 /// For example, ARKUI_SAFE_AREA_TYPE_SYSTEM | ARKUI_SAFE_AREA_TYPE_CUTOUT;
2245 ///
2246 /// .value[1]? .u32: set of directional enum values for extended security zones [`ArkUI_SafeAreaEdge`];
2247 ///
2248 /// For example: ARKUI_SAFE_AREA_EDGE_TOP | ARKUI_SAFE_AREA_EDGE_BOTTOM;
2249 ///
2250 ///
2251 ///
2252 /// Attribute fetch method return value [`ArkUI_AttributeItem`] format:
2253 ///
2254 /// .value[0].u32: extends the security zone.
2255 /// .
2256 ///
2257 /// .value[1].u32: indicates the direction to extend the security zone.
2258 /// .
2259 pub const NODE_EXPAND_SAFE_AREA: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(92);
2260 /// Defines the visible area ratio (visible area/total area of the component) threshold for invoking the
2261 /// visible area change event of the component.
2262 ///
2263 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2264 ///
2265 /// .value[...].f32: threshold array. The value range is 0 to 1.
2266 ///
2267 ///
2268 /// Format of the return value [`ArkUI_AttributeItem`]:
2269 ///
2270 /// .value[...].f32: threshold array.
2271 pub const NODE_VISIBLE_AREA_CHANGE_RATIO: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(93);
2272 /// Sets the transition effect when the component is inserted or deleted.
2273 /// This attribute can be set, and obtained as required through APIs.
2274 ///
2275 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2276 ///
2277 /// .object: transition effect. The parameter type is [`ArkUI_TransitionEffect`].
2278 ///
2279 ///
2280 ///
2281 /// Format of the return value [`ArkUI_AttributeItem`]:
2282 ///
2283 /// .object: transition effect. The parameter type is [`ArkUI_TransitionEffect`].
2284 pub const NODE_TRANSITION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(94);
2285 /// Defines the component ID.
2286 /// This attribute can be obtained through APIs.
2287 ///
2288 /// Format of the [`ArkUI_AttributeItem`] parameter for obtaining the attribute:
2289 ///
2290 /// .value[0].i32: component ID.
2291 pub const NODE_UNIQUE_ID: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(95);
2292 /// Set the current component system focus box style.
2293 ///
2294 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2295 ///
2296 /// .value[0].f32: The distance between the focus box and the edge of the component.
2297 ///
2298 /// Positive numbers represent the outer side, negative numbers represent the inner side.
2299 ///
2300 /// Percentage is not supported.
2301 ///
2302 /// .value[1].f32: Focus box width. Negative numbers and percentages are not supported.
2303 ///
2304 /// .value[2].u32: Focus box color.
2305 ///
2306 ///
2307 pub const NODE_FOCUS_BOX: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(96);
2308 /// Defines the moving distance limit for the component-bound tap gesture.
2309 /// This attribute can be set as required through APIs.
2310 ///
2311 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2312 ///
2313 /// .value[0].f32: allowed moving distance of a finger, in vp.
2314 pub const NODE_CLICK_DISTANCE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(97);
2315 /// Sets whether the focus can be placed on this component.
2316 /// This attribute can be set, reset, and obtained as required through APIs.
2317 ///
2318 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2319 ///
2320 /// .value[0].i32: whether the focus can be placed on the current component. The parameter type is 1 or 0.
2321 ///
2322 ///
2323 /// Format of the return value [`ArkUI_AttributeItem`]:
2324 ///
2325 /// .value[0].i32: whether the focus can be placed on the current component. The parameter type is 1 or 0.
2326 ///
2327 ///
2328 /// Available since API-level: 14
2329 #[cfg(feature = "api-14")]
2330 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2331 pub const NODE_TAB_STOP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(98);
2332 /// Defines the backdrop blur attribute, which can be set, reset, and obtained as required through APIs.
2333 ///
2334 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2335 ///
2336 /// .value[0].f32:backdrop blur radius, in px. The value range is [0, +∞).
2337 ///
2338 /// .value[1]?.f32:grayscale blur settings that control the brightness of the black color.
2339 ///
2340 /// The value range is [0, 127].
2341 ///
2342 /// .value[2]?.f32:grayscale blur settings that control the darkness of the white color.
2343 ///
2344 /// The value range is [0, 127].
2345 ///
2346 ///
2347 ///
2348 /// Format of the return value [`ArkUI_AttributeItem`]:
2349 ///
2350 /// .value[0].f32:backdrop blur radius, in px. The value range is [0, +∞).
2351 ///
2352 /// .value[1].f32:grayscale blur settings that control the brightness of the black color.
2353 ///
2354 /// The value range is [0, 127].
2355 ///
2356 /// .value[2].f32:grayscale blur settings that control the darkness of the white color.
2357 ///
2358 /// The value range is [0, 127].
2359 ///
2360 ///
2361 ///
2362 /// Available since API-level: 15
2363 #[cfg(feature = "api-15")]
2364 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
2365 pub const NODE_BACKDROP_BLUR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(99);
2366 /// Sets the next focus node.
2367 ///
2368 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2369 ///
2370 /// .value[0].i32: focus movement direction, as defined in [`ArkUI_FocusMove`].
2371 /// .object: next focus node. The parameter type is [`ArkUI_NodeHandle`].
2372 ///
2373 ///
2374 ///
2375 ///
2376 ///
2377 /// Available since API-level: 18
2378 #[cfg(feature = "api-18")]
2379 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
2380 pub const NODE_NEXT_FOCUS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(101);
2381 /// Sets the parameters for visible area change events.
2382 ///
2383 ///
2384 /// **Note:** The visible area change callback is not a real-time callback. The actual callback interval may differ from
2385 /// the expected interval due to system load and other factors.
2386 /// The interval between two visible area change callbacks will not be less than the expected update interval. If the
2387 /// provided expected interval is too short, the actual callback interval will be determined by the system load.
2388 /// By default, the interval threshold of the visible area change callback includes 0. This means that,
2389 /// if the provided threshold is [0.5], the effective threshold will be [0.0, 0.5].
2390 ///
2391 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2392 ///
2393 /// .object: parameters for visible area change events.
2394 /// The parameter type is [`ArkUI_VisibleAreaEventOptions`].
2395 ///
2396 ///
2397 ///
2398 /// Format of the return value [`ArkUI_AttributeItem`]:
2399 ///
2400 /// .object: parameters for visible area change events.
2401 /// The parameter type is [`ArkUI_VisibleAreaEventOptions`].
2402 ///
2403 ///
2404 ///
2405 /// Available since API-level: 17
2406 #[cfg(feature = "api-17")]
2407 #[cfg_attr(docsrs, doc(cfg(feature = "api-17")))]
2408 pub const NODE_VISIBLE_AREA_APPROXIMATE_CHANGE_RATIO: ArkUI_NodeAttributeType =
2409 ArkUI_NodeAttributeType(102);
2410 /// Defines the text content attribute, which can be set, reset, and obtained as required through APIs.
2411 ///
2412 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2413 ///
2414 /// .string: text content.
2415 ///
2416 ///
2417 ///
2418 /// Format of the return value [`ArkUI_AttributeItem`]:
2419 ///
2420 /// .string: text content.
2421 pub const NODE_TEXT_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1000);
2422 /// Defines the font color attribute, which can be set, reset, and obtained as required through APIs.
2423 ///
2424 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2425 ///
2426 /// .value[0].u32: font color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
2427 ///
2428 ///
2429 ///
2430 /// Format of the return value [`ArkUI_AttributeItem`]:
2431 ///
2432 /// .value[0].u32: font color value, in 0xARGB format.
2433 pub const NODE_FONT_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001);
2434 /// Defines the font size attribute, which can be set, reset, and obtained as required through APIs.
2435 ///
2436 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2437 ///
2438 /// .value[0].f32: font size, in fp.
2439 ///
2440 ///
2441 ///
2442 /// Format of the return value [`ArkUI_AttributeItem`]:
2443 ///
2444 /// .value[0].f32: font size, in fp.
2445 pub const NODE_FONT_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002);
2446 /// Defines the font style attribute, which can be set, reset, and obtained as required through APIs.
2447 ///
2448 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2449 ///
2450 /// .value[0].i32: font style [`ArkUI_FontStyle`]. The default value is <b>ARKUI_FONT_STYLE_NORMAL</b>.
2451 ///
2452 ///
2453 ///
2454 /// Format of the return value [`ArkUI_AttributeItem`]:
2455 ///
2456 /// .value[0].i32: font style [`ArkUI_FontStyle`].
2457 pub const NODE_FONT_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003);
2458 /// Defines the font weight attribute, which can be set, reset, and obtained as required through APIs.
2459 ///
2460 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2461 ///
2462 /// .value[0].i32: font weight [`ArkUI_FontWeight`]. The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
2463 ///
2464 ///
2465 ///
2466 /// Format of the return value [`ArkUI_AttributeItem`]:
2467 ///
2468 /// .value[0].i32: font weight [`ArkUI_FontWeight`].
2469 pub const NODE_FONT_WEIGHT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1004);
2470 /// Defines the text line height attribute, which can be set, reset, and obtained as required through APIs.
2471 ///
2472 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2473 ///
2474 /// .value[0].f32: line height, in fp.
2475 ///
2476 ///
2477 ///
2478 /// Format of the return value [`ArkUI_AttributeItem`]:
2479 ///
2480 /// .value[0].f32: line height, in fp.
2481 pub const NODE_TEXT_LINE_HEIGHT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1005);
2482 /// Defines the text decoration style and color.
2483 /// This attribute can be set, reset, and obtained as required through APIs.
2484 ///
2485 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2486 ///
2487 /// .value[0].i32: text decoration type [`ArkUI_TextDecorationType`].
2488 /// The default value is <b>ARKUI_TEXT_DECORATION_TYPE_NONE</b>.
2489 ///
2490 /// .value[1]?.u32: text decoration color, in 0xARGB format. For example, 0xFFFF0000 indicates red. Optional.
2491 ///
2492 /// .value[2]?.i32: text decoration style [`ArkUI_TextDecorationStyle`].
2493 ///
2494 ///
2495 ///
2496 /// Format of the return value [`ArkUI_AttributeItem`]:
2497 ///
2498 /// .value[0].i32: text decoration type [`ArkUI_TextDecorationType`].
2499 ///
2500 /// .value[1].u32: text decoration color, in 0xARGB format.
2501 ///
2502 /// .value[2].i32: text decoration style [`ArkUI_TextDecorationStyle`].
2503 pub const NODE_TEXT_DECORATION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1006);
2504 /// Defines the text case attribute, which can be set, reset, and obtained as required through APIs.
2505 ///
2506 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2507 ///
2508 /// .value[0].i32: text case.
2509 ///
2510 ///
2511 ///
2512 /// Format of the return value [`ArkUI_AttributeItem`]:
2513 ///
2514 /// .value[0].i32: text case.
2515 pub const NODE_TEXT_CASE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1007);
2516 /// Defines the letter spacing attribute, which can be set, reset, and obtained as required through APIs.
2517 ///
2518 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2519 ///
2520 /// .value[0].f32: letter spacing, in fp.
2521 ///
2522 ///
2523 ///
2524 /// Format of the return value [`ArkUI_AttributeItem`]:
2525 ///
2526 /// .value[0].f32: letter spacing, in fp.
2527 pub const NODE_TEXT_LETTER_SPACING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1008);
2528 /// Sets the maximum number of lines in the text.
2529 /// This attribute can be set, reset, and obtained as required through APIs.
2530 ///
2531 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2532 ///
2533 /// .value[0].i32: maximum number of lines in the text.
2534 ///
2535 ///
2536 ///
2537 /// Format of the return value [`ArkUI_AttributeItem`]:
2538 ///
2539 /// .value[0].i32: maximum number of lines in the text.
2540 pub const NODE_TEXT_MAX_LINES: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1009);
2541 /// Horizontal alignment mode of the text.
2542 /// This attribute can be set, reset, and obtained as required through APIs.
2543 ///
2544 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2545 ///
2546 /// .value[0].i32: horizontal alignment mode of the text. The value is an enum of [`ArkUI_TextAlignment`].
2547 ///
2548 ///
2549 ///
2550 /// Format of the return value [`ArkUI_AttributeItem`]:
2551 ///
2552 /// .value[0].i32: horizontal alignment mode of the text. The value is an enum of [`ArkUI_TextAlignment`].
2553 pub const NODE_TEXT_ALIGN: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1010);
2554 /// Defines the text overflow attribute, which can be set, reset, and obtained as required through APIs.
2555 ///
2556 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2557 ///
2558 /// .value[0].i32: display mode when the text is too long. [`ArkUI_TextOverflow`]
2559 ///
2560 ///
2561 ///
2562 /// Format of the return value [`ArkUI_AttributeItem`]:
2563 ///
2564 /// .value[0].i32: display mode when the text is too long. [`ArkUI_TextOverflow`]
2565 pub const NODE_TEXT_OVERFLOW: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1011);
2566 /// Defines the font family attribute, which can be set, reset, and obtained as required through APIs.
2567 ///
2568 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2569 ///
2570 /// .string: fonts, separated by commas (,).
2571 ///
2572 ///
2573 /// Format of the return value [`ArkUI_AttributeItem`]:
2574 ///
2575 /// .string: fonts, separated by commas (,).
2576 pub const NODE_FONT_FAMILY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1012);
2577 /// Defines the copy option attribute, which can be set, reset, and obtained as required through APIs.
2578 ///
2579 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2580 ///
2581 /// .value[0].i32: copy option [`ArkUI_CopyOptions`]. The default value is <b>ARKUI_COPY_OPTIONS_NONE</b>.
2582 ///
2583 ///
2584 ///
2585 /// Format of the return value [`ArkUI_AttributeItem`]:
2586 ///
2587 /// .value[0].i32: copy option [`ArkUI_CopyOptions.`]
2588 pub const NODE_TEXT_COPY_OPTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013);
2589 /// Defines the text baseline offset attribute
2590 /// This attribute can be set, reset, and obtained as required through APIs.
2591 ///
2592 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2593 ///
2594 /// .value[0].f32: baseline offset, in fp.
2595 ///
2596 ///
2597 ///
2598 /// Format of the return value [`ArkUI_AttributeItem`]:
2599 ///
2600 /// .value[0].f32: baseline offset, in fp.
2601 pub const NODE_TEXT_BASELINE_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1014);
2602 /// Defines the text shadow attribute, which can be set, reset, and obtained as required through APIs.
2603 ///
2604 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2605 ///
2606 /// .value[0].f32: blur radius of the shadow, in vp.
2607 ///
2608 /// .value[1].i32: shadow type [`ArkUI_ShadowType`]. The default value is <b>ARKUI_SHADOW_TYPE_COLOR</b>.
2609 ///
2610 /// .value[2].u32: shadow color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
2611 ///
2612 /// .value[3].f32: offset of the shadow along the x-axis, in vp.
2613 ///
2614 /// .value[4].f32: offset of the shadow along the y-axis, in vp.
2615 ///
2616 ///
2617 ///
2618 /// Format of the return value [`ArkUI_AttributeItem`]:
2619 ///
2620 /// .value[0].f32: blur radius of the shadow, in vp.
2621 ///
2622 /// .value[1].i32: shadow type [`ArkUI_ShadowType`].
2623 ///
2624 /// .value[2].u32: shadow color, in 0xARGB format.
2625 ///
2626 /// .value[3].f32: offset of the shadow along the x-axis, in vp.
2627 ///
2628 /// .value[4].f32: offset of the shadow along the y-axis, in vp.
2629 pub const NODE_TEXT_TEXT_SHADOW: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1015);
2630 /// Defines the minimum font size attribute, which can be set, reset, and obtained as required through APIs.
2631 ///
2632 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2633 ///
2634 /// .value[0].f32: minimum font size, in fp.
2635 ///
2636 ///
2637 /// Format of the return value [`ArkUI_AttributeItem`]:
2638 ///
2639 /// .value[0].f32: minimum font size, in fp.
2640 pub const NODE_TEXT_MIN_FONT_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1016);
2641 /// Defines the maximum font size attribute, which can be set, reset, and obtained as required through APIs.
2642 ///
2643 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2644 ///
2645 /// .value[0].f32: maximum font size, in fp.
2646 ///
2647 ///
2648 /// Format of the return value [`ArkUI_AttributeItem`]:
2649 ///
2650 /// .value[0].f32: maximum font size, in fp.
2651 pub const NODE_TEXT_MAX_FONT_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1017);
2652 /// Defines the text style attribute, which can be set, reset, and obtained as required through APIs.
2653 ///
2654 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2655 ///
2656 /// .string?: font family. Optional. Use commas (,) to separate multiple fonts.
2657 ///
2658 /// .value[0].f32: font size, in fp.
2659 ///
2660 /// .value[1]?.i32: font weight. Optional. The parameter type is [`ArkUI_FontWeight`].
2661 /// The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
2662 ///
2663 /// .value[2]?.i32: font style. Optional. The parameter type is [`ArkUI_FontStyle`].
2664 /// The default value is <b>ARKUI_FONT_STYLE_NORMAL</b>.
2665 ///
2666 ///
2667 /// Format of the return value [`ArkUI_AttributeItem`]:
2668 ///
2669 /// .string: font family. Use commas (,) to separate multiple fonts.
2670 ///
2671 /// .value[0].f32: font size, in fp.
2672 ///
2673 /// .value[1].i32: font weight. The parameter type is [`ArkUI_FontWeight`].
2674 /// The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
2675 ///
2676 /// .value[2].i32: font style. The parameter type is [`ArkUI_FontStyle`].
2677 /// The default value is <b>ARKUI_FONT_STYLE_NORMAL</b>.
2678 pub const NODE_TEXT_FONT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1018);
2679 /// Defines how the adaptive height is determined for the text.
2680 /// This attribute can be set, reset, and obtained as required through APIs.
2681 ///
2682 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2683 ///
2684 /// .value[0].i32: how the adaptive height is determined for the text.
2685 /// The parameter type is [`ArkUI_TextHeightAdaptivePolicy`].
2686 ///
2687 ///
2688 /// Format of the return value [`ArkUI_AttributeItem`]:
2689 ///
2690 /// .value[0].i32: how the adaptive height is determined for the text.
2691 /// The parameter type is [`ArkUI_TextHeightAdaptivePolicy`]
2692 pub const NODE_TEXT_HEIGHT_ADAPTIVE_POLICY: ArkUI_NodeAttributeType =
2693 ArkUI_NodeAttributeType(1019);
2694 /// Defines the indentation of the first line.
2695 /// This attribute can be set, reset, and obtained as required through APIs.
2696 ///
2697 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2698 ///
2699 /// .value[0].f32: indentation of the first line.
2700 ///
2701 ///
2702 ///
2703 /// Format of the return value [`ArkUI_AttributeItem`]:
2704 ///
2705 /// .value[0].f32: indentation of the first line.
2706 pub const NODE_TEXT_INDENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1020);
2707 /// Defines the line break rule. This attribute can be set, reset, and obtained as required through APIs.
2708 ///
2709 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2710 ///
2711 /// .value[0].i32: The parameter type is [`ArkUI_WordBreak`].
2712 ///
2713 ///
2714 ///
2715 /// Format of the return value [`ArkUI_AttributeItem`]:
2716 ///
2717 /// .value[0].i32: The parameter type is [`ArkUI_WordBreak`].
2718 pub const NODE_TEXT_WORD_BREAK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1021);
2719 /// Defines the ellipsis position. This attribute can be set, reset, and obtained as required through APIs.
2720 ///
2721 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2722 ///
2723 /// .value[0].i32: The parameter type is [`ArkUI_EllipsisMode`].
2724 ///
2725 ///
2726 ///
2727 /// Format of the return value [`ArkUI_AttributeItem`]:
2728 ///
2729 /// .value[0].i32: The parameter type is [`ArkUI_EllipsisMode`].
2730 pub const NODE_TEXT_ELLIPSIS_MODE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1022);
2731 /// Defines the text line spacing attribute, which can be set, reset, and obtained as required through APIs.
2732 ///
2733 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2734 ///
2735 /// .value[0].f32: line spacing, in fp.
2736 ///
2737 ///
2738 ///
2739 /// Format of the return value [`ArkUI_AttributeItem`]:
2740 ///
2741 /// .value[0].f32: line spacing, in fp.
2742 pub const NODE_TEXT_LINE_SPACING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1023);
2743 /// Set the text feature effect and the NODE_FONT_FEATURE attribute,
2744 /// NODE_FONT_FEATURE is the advanced typesetting capability of OpenType
2745 /// Features such as ligatures and equal-width digits are generally used in customized fonts.
2746 ///
2747 /// The capabilities need to be supported by the fonts,
2748 ///
2749 /// Interfaces for setting, resetting, and obtaining attributes are supported.
2750 ///
2751 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
2752 ///
2753 /// .string: complies with the text feature format. The format is normal |
2754 ///
2755 /// is in the format of [ | on | off],
2756 /// .
2757 /// There can be multiple values separated by commas (,).
2758 ///
2759 /// For example, the input format of a number with the same width is ss01 on.
2760 ///
2761 ///
2762 ///
2763 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
2764 ///
2765 /// .string indicates the content of the text feature. Multiple text features are separated by commas (,).
2766 pub const NODE_FONT_FEATURE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1024);
2767 /// Setting Enable Text Recognition.
2768 ///
2769 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2770 ///
2771 /// .value[0].i32:Enable text recognition, default value false.
2772 ///
2773 ///
2774 ///
2775 /// Format of the return value [`ArkUI_AttributeItem`]:
2776 ///
2777 /// .value[0].i32:Enable Text Recognition
2778 pub const NODE_TEXT_ENABLE_DATA_DETECTOR: ArkUI_NodeAttributeType =
2779 ArkUI_NodeAttributeType(1025);
2780 /// Set the text recognition configuration.
2781 ///
2782 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2783 ///
2784 /// .value[0...].i32: Array of entity types, parameter types[`ArkUI_TextDataDetectorType`]。
2785 ///
2786 ///
2787 ///
2788 /// Format of the return value [`ArkUI_AttributeItem`]:
2789 ///
2790 /// .value[0...].i32:Array of entity types, parameter types[`ArkUI_TextDataDetectorType`]。
2791 pub const NODE_TEXT_ENABLE_DATA_DETECTOR_CONFIG: ArkUI_NodeAttributeType =
2792 ArkUI_NodeAttributeType(1026);
2793 /// Defines the background color of the selected text.
2794 /// This attribute can be set, reset, and obtained as required through APIs.
2795 ///
2796 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2797 ///
2798 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
2799 ///
2800 ///
2801 ///
2802 /// Format of the return value [`ArkUI_AttributeItem`]:
2803 ///
2804 /// .value[0].u32: color value, in 0xARGB format.
2805 pub const NODE_TEXT_SELECTED_BACKGROUND_COLOR: ArkUI_NodeAttributeType =
2806 ArkUI_NodeAttributeType(1027);
2807 /// The text component uses a formatted string object to set text content properties,
2808 /// and supports property setting, property reset, and property acquisition interfaces.
2809 ///
2810 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2811 ///
2812 /// .object indicates ArkUI_StyledString formatted string data. The parameter type is [`ArkUI_StyledString`].
2813 ///
2814 ///
2815 ///
2816 /// Format of the return value [`ArkUI_AttributeItem`]:
2817 ///
2818 /// .object indicates ArkUI_StyledString formatted string data. The parameter type is [`ArkUI_StyledString`].
2819 pub const NODE_TEXT_CONTENT_WITH_STYLED_STRING: ArkUI_NodeAttributeType =
2820 ArkUI_NodeAttributeType(1028);
2821 /// Sets whether to center text vertically in the text component.
2822 ///
2823 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2824 ///
2825 /// .value[0].i32: whether to center text vertically. The default value is <b>false</b>.
2826 ///
2827 ///
2828 ///
2829 /// Format of the return value [`ArkUI_AttributeItem`]:
2830 ///
2831 /// .value[0].i32: whether to center text vertically.
2832 pub const NODE_TEXT_HALF_LEADING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1029);
2833 /// Defines the font weight attribute, which can be set, reset, and obtained as required through APIs.
2834 /// The font weight specified by this API is not affected by any changes in the system font weight settings.
2835 ///
2836 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2837 ///
2838 /// .value[0].i32: font weight [`ArkUI_FontWeight`]. The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
2839 ///
2840 ///
2841 ///
2842 /// Format of the return value [`ArkUI_AttributeItem`]:
2843 ///
2844 /// .value[0].i32: font weight [`ArkUI_FontWeight`].
2845 ///
2846 ///
2847 ///
2848 /// Available since API-level: 15
2849 #[cfg(feature = "api-15")]
2850 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
2851 pub const NODE_IMMUTABLE_FONT_WEIGHT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1030);
2852 /// Defines the text content attribute, which can be set, reset, and obtained as required through APIs.
2853 ///
2854 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2855 ///
2856 /// .string: content of the text span.
2857 ///
2858 ///
2859 ///
2860 /// Format of the return value [`ArkUI_AttributeItem`]:
2861 ///
2862 /// .string: content of the text span.
2863 pub const NODE_SPAN_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(2000);
2864 /// Defines the text background style.
2865 /// This attribute can be set, reset, and obtained as required through APIs.
2866 ///
2867 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2868 ///
2869 /// .value[0].u32: color of the text background, in 0xARGB format, for example, <b>0xFFFF0000</b> indicating red.
2870 ///
2871 /// The second parameter indicates the rounded corners of the text background. Two setting modes are available:
2872 ///
2873 /// 1: .value[1].f32: radius of the four corners, in vp.
2874 ///
2875 /// 2: .value[1].f32: radius of the upper left corner, in vp.
2876 ///
2877 /// .value[2].f32: radius of the upper right corner, in vp.
2878 ///
2879 /// .value[3].f32: radius of the lower left corner, in vp.
2880 ///
2881 /// .value[4].f32: radius of the lower right corner, in vp.
2882 ///
2883 ///
2884 ///
2885 /// Format of the return value [`ArkUI_AttributeItem`]:
2886 ///
2887 /// .value[0].u32: color of the text background, in 0xARGB format.
2888 ///
2889 /// .value[1].f32: radius of the upper left corner, in vp.
2890 ///
2891 /// .value[2].f32: radius of the upper right corner, in vp.
2892 ///
2893 /// .value[3].f32: radius of the lower left corner, in vp.
2894 ///
2895 /// .value[4].f32: radius of the lower right corner, in vp.
2896 pub const NODE_SPAN_TEXT_BACKGROUND_STYLE: ArkUI_NodeAttributeType =
2897 ArkUI_NodeAttributeType(2001);
2898 /// Defines the text baseline offset attribute
2899 /// This attribute can be set, reset, and obtained as required through APIs.
2900 ///
2901 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2902 ///
2903 /// .value[0].f32: baseline offset, in fp.
2904 ///
2905 ///
2906 ///
2907 /// Format of the return value [`ArkUI_AttributeItem`]:
2908 ///
2909 /// .value[0].f32: baseline offset, in fp.
2910 pub const NODE_SPAN_BASELINE_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(2002);
2911 /// Defines the image source of the image span.
2912 /// This attribute can be set, reset, and obtained as required through APIs.
2913 ///
2914 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2915 ///
2916 /// .string: image address of the image span.
2917 ///
2918 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`]. Either .string or .object must be set.
2919 ///
2920 ///
2921 ///
2922 /// Format of the return value [`ArkUI_AttributeItem`]:
2923 ///
2924 /// .string: image address of the image span.
2925 ///
2926 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`].
2927 pub const NODE_IMAGE_SPAN_SRC: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(3000);
2928 /// Defines the alignment mode of the image with the text.
2929 /// This attribute can be set, reset, and obtained as required through APIs.
2930 ///
2931 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2932 ///
2933 /// .value[0].i32: alignment mode of the image with the text.
2934 /// The value is an enum of [`ArkUI_ImageSpanAlignment`].
2935 ///
2936 ///
2937 ///
2938 /// Format of the return value [`ArkUI_AttributeItem`]:
2939 ///
2940 /// .value[0].i32: alignment mode of the image with the text.
2941 /// The value is an enum of [`ArkUI_ImageSpanAlignment`].
2942 pub const NODE_IMAGE_SPAN_VERTICAL_ALIGNMENT: ArkUI_NodeAttributeType =
2943 ArkUI_NodeAttributeType(3001);
2944 /// Defines the placeholder image source.
2945 /// This attribute can be set, reset, and obtained as required through APIs.
2946 ///
2947 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2948 ///
2949 /// .string: placeholder image source.
2950 ///
2951 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`]. Either .string or .object must be set.
2952 ///
2953 ///
2954 ///
2955 /// Format of the return value [`ArkUI_AttributeItem`]:
2956 ///
2957 /// .string: placeholder image source.
2958 ///
2959 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`].
2960 pub const NODE_IMAGE_SPAN_ALT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(3002);
2961 /// Defines the baseline offset attribute of the <b>ImageSpan</b> component.
2962 /// This attribute can be set, reset, and obtained as required through APIs.
2963 /// A positive value means an upward offset, while a negative value means a downward offset.
2964 /// The default value is <b>0</b>, and the unit is fp.
2965 ///
2966 ///
2967 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2968 ///
2969 /// .value[0].f32: baseline offset, in fp.
2970 ///
2971 ///
2972 ///
2973 /// Format of the return value [`ArkUI_AttributeItem`]:
2974 ///
2975 /// .value[0].f32: baseline offset, in fp.
2976 ///
2977 ///
2978 ///
2979 /// Available since API-level: 13
2980 #[cfg(feature = "api-13")]
2981 #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2982 pub const NODE_IMAGE_SPAN_BASELINE_OFFSET: ArkUI_NodeAttributeType =
2983 ArkUI_NodeAttributeType(3003);
2984 /// Defines the image source of the <Image> component.
2985 /// This attribute can be set, reset, and obtained as required through APIs.
2986 ///
2987 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
2988 ///
2989 /// .string: image source.
2990 ///
2991 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`]. Either .string or .object must be set.
2992 ///
2993 ///
2994 ///
2995 /// Format of the return value [`ArkUI_AttributeItem`]:
2996 ///
2997 /// .string: image source.
2998 ///
2999 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`].
3000 pub const NODE_IMAGE_SRC: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4000);
3001 /// Defines how the image is resized to fit its container.
3002 /// This attribute can be set, reset, and obtained as required through APIs.
3003 ///
3004 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3005 ///
3006 /// .value[0].i32: how the image is resized to fit its container. The value is an enum of [`ArkUI_ObjectFit`].
3007 ///
3008 ///
3009 ///
3010 /// Format of the return value [`ArkUI_AttributeItem`]:
3011 ///
3012 /// .value[0].i32: how the image is resized to fit its container. The value is an enum of [`ArkUI_ObjectFit`].
3013 pub const NODE_IMAGE_OBJECT_FIT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4001);
3014 /// Defines the interpolation effect of the image.
3015 /// This attribute can be set, reset, and obtained as required through APIs.
3016 ///
3017 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3018 ///
3019 /// .value[0].i32: interpolation effect of the image. The value is an enum of [`ArkUI_ImageInterpolation`].
3020 ///
3021 ///
3022 ///
3023 /// Format of the return value [`ArkUI_AttributeItem`]:
3024 ///
3025 /// .value[0].i32: interpolation effect of the image. The value is an enum of [`ArkUI_ImageInterpolation`].
3026 pub const NODE_IMAGE_INTERPOLATION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4002);
3027 /// Defines how the image is repeated.
3028 /// This attribute can be set, reset, and obtained as required through APIs.
3029 ///
3030 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3031 ///
3032 /// .value[0].i32: how the image is repeated. The value is an enum of [`ArkUI_ImageRepeat`].
3033 ///
3034 ///
3035 ///
3036 /// Format of the return value [`ArkUI_AttributeItem`]:
3037 ///
3038 /// .value[0].i32: how the image is repeated. The value is an enum of [`ArkUI_ImageRepeat`].
3039 pub const NODE_IMAGE_OBJECT_REPEAT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4003);
3040 /// Defines the color filter of the image.
3041 /// This attribute can be set, reset, and obtained as required through APIs.
3042 ///
3043 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3044 ///
3045 /// .value[0].f32 to .value[19].f32: filter matrix array.
3046 ///
3047 /// .size: 5 x 4 filter array size.
3048 ///
3049 /// .object: the pointer to OH_Drawing_ColorFilter. Either .value or .object is set.
3050 ///
3051 ///
3052 ///
3053 /// Format of the return value [`ArkUI_AttributeItem`]:
3054 ///
3055 /// .value[0].f32 to .value[19].f32: filter matrix array.
3056 ///
3057 /// .size: 5 x 4 filter array size.
3058 ///
3059 /// .object: the pointer to OH_Drawing_ColorFilter.
3060 pub const NODE_IMAGE_COLOR_FILTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4004);
3061 /// Defines the auto resize attribute, which can be set, reset, and obtained as required through APIs.
3062 ///
3063 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3064 ///
3065 /// .value[0].i32 : whether to resize the image source.
3066 ///
3067 ///
3068 ///
3069 /// Format of the return value [`ArkUI_AttributeItem`]:
3070 ///
3071 /// .value[0].i32 : whether to resize the image source.
3072 pub const NODE_IMAGE_AUTO_RESIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4005);
3073 /// Defines the placeholder image source.
3074 /// This attribute can be set, reset, and obtained as required through APIs.
3075 ///
3076 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3077 ///
3078 /// .string: placeholder image source.
3079 ///
3080 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`]. Either .string or .object must be set.
3081 ///
3082 ///
3083 ///
3084 /// Format of the return value [`ArkUI_AttributeItem`]:
3085 ///
3086 /// .string: placeholder image source.
3087 ///
3088 /// .object: The parameter type is [`ArkUI_DrawableDescriptor`].
3089 pub const NODE_IMAGE_ALT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4006);
3090 /// Defines whether the image is draggable.
3091 /// This attribute can be set, reset, and obtained as required through APIs.
3092 ///
3093 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3094 ///
3095 /// .value[0].i32: whether the image is draggable. The value <b>true</b> means that the image is draggable.
3096 ///
3097 ///
3098 ///
3099 /// Format of the return value [`ArkUI_AttributeItem`]:
3100 ///
3101 /// .value[0].i32: whether the image is draggable.
3102 pub const NODE_IMAGE_DRAGGABLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4007);
3103 /// Defines the image rendering mode. This attribute can be set, reset, and obtained as required through APIs.
3104 ///
3105 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3106 ///
3107 /// .value[0].i32: The parameter type is [`ArkUI_ImageRenderMode`].
3108 ///
3109 ///
3110 ///
3111 /// Format of the return value [`ArkUI_AttributeItem`]:
3112 ///
3113 /// .value[0].i32: The parameter type is [`ArkUI_ImageRenderMode`].
3114 pub const NODE_IMAGE_RENDER_MODE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4008);
3115 /// Defines whether the image display size follows the image source size.
3116 /// This attribute can be set, reset, and obtained as required through APIs.
3117 ///
3118 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3119 ///
3120 /// .value[0].i32: wheter to follow, true means to follow.
3121 ///
3122 ///
3123 ///
3124 /// Format of the return value [`ArkUI_AttributeItem`]:
3125 ///
3126 /// .value[0].i32: wheter to follow, true means to follow.
3127 pub const NODE_IMAGE_FIT_ORIGINAL_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4009);
3128 /// Defines the fill color of the swiper.
3129 /// This attribute can be set, reset, and obtained as required through APIs.
3130 ///
3131 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3132 ///
3133 /// .value[0].u32: fill color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3134 ///
3135 ///
3136 ///
3137 /// Format of the return value [`ArkUI_AttributeItem`]:
3138 ///
3139 /// .value[0].u32: fill color, in 0xARGB format.
3140 pub const NODE_IMAGE_FILL_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4010);
3141 /// Sets the resizable image options.
3142 ///
3143 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3144 ///
3145 /// .value[0].f32: width of the left edge. The unit is vp.
3146 ///
3147 /// .value[1].f32: width of the top edge. The unit is vp.
3148 ///
3149 /// .value[2].f32: width of the right edge. The unit is vp.
3150 ///
3151 /// .value[3].f32: width of the bottom edge. The unit is vp.
3152 ///
3153 ///
3154 ///
3155 /// Format of the return value [`ArkUI_AttributeItem`]:
3156 ///
3157 /// .value[0].f32: width of the left edge. The unit is vp.
3158 ///
3159 /// .value[1].f32: width of the top edge. The unit is vp.
3160 ///
3161 /// .value[2].f32: width of the right edge. The unit is vp.
3162 ///
3163 /// .value[3].f32: width of the bottom edge. The unit is vp.
3164 pub const NODE_IMAGE_RESIZABLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(4011);
3165 /// Defines the color of the component when it is selected.
3166 /// This attribute can be set, reset, and obtained as required through APIs.
3167 ///
3168 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3169 ///
3170 /// .value[0].u32: background color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3171 ///
3172 ///
3173 ///
3174 /// Format of the return value [`ArkUI_AttributeItem`]:
3175 ///
3176 /// .value[0].u32: background color, in 0xARGB format.
3177 pub const NODE_TOGGLE_SELECTED_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(5000);
3178 /// Defines the color of the circular slider for the component of the switch type.
3179 /// This attribute can be set, reset, and obtained as required through APIs.
3180 ///
3181 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3182 ///
3183 /// .value[0].u32: color of the circular slider, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3184 ///
3185 ///
3186 ///
3187 /// Format of the return value [`ArkUI_AttributeItem`]:
3188 ///
3189 /// .value[0].u32: color of the circular slider, in 0xARGB format.
3190 pub const NODE_TOGGLE_SWITCH_POINT_COLOR: ArkUI_NodeAttributeType =
3191 ArkUI_NodeAttributeType(5001);
3192 /// Defines the toggle switch value. This attribute can be set, reset, and obtained as required through APIs.
3193 ///
3194 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3195 ///
3196 /// .value[0].i32: whether to enable the toggle. The value <b>true</b> means to enable the toggle.
3197 ///
3198 ///
3199 ///
3200 /// Format of the return value [`ArkUI_AttributeItem`]:
3201 ///
3202 /// .value[0].i32: whether to enable the toggle.
3203 pub const NODE_TOGGLE_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(5002);
3204 /// Defines the color of the component when it is deselected.
3205 /// This attribute can be set, reset, and obtained as required through APIs.
3206 ///
3207 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3208 ///
3209 /// .value[0].u32: background color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3210 ///
3211 ///
3212 ///
3213 /// Format of the return value [`ArkUI_AttributeItem`]:
3214 ///
3215 /// .value[0].u32: background color, in 0xARGB format.
3216 pub const NODE_TOGGLE_UNSELECTED_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(5003);
3217 /// Defines the foreground color of the loading progress bar.
3218 /// This attribute can be set, reset, and obtained as required through APIs.
3219 ///
3220 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3221 ///
3222 /// .value[0].u32: foreground color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3223 ///
3224 ///
3225 ///
3226 /// Format of the return value [`ArkUI_AttributeItem`]:
3227 ///
3228 /// .value[0].u32: foreground color, in 0xARGB format.
3229 pub const NODE_LOADING_PROGRESS_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(6000);
3230 /// Defines whether to show the loading animation for the <LoadingProgress> component.
3231 /// This attribute can be set, reset, and obtained as required through APIs.
3232 ///
3233 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3234 ///
3235 /// .value[0].i32: whether to show the loading animation.
3236 /// The value <b>true</b> means to show the loading animation, and <b>false</b> means the opposite.
3237 ///
3238 ///
3239 ///
3240 /// Format of the return value [`ArkUI_AttributeItem`]:
3241 ///
3242 /// .value[0].i32: The value <b>1</b> means to show the loading animation, and <b>0</b> means the opposite.
3243 pub const NODE_LOADING_PROGRESS_ENABLE_LOADING: ArkUI_NodeAttributeType =
3244 ArkUI_NodeAttributeType(6001);
3245 /// Defines the default placeholder text of the single-line text box.
3246 /// This attribute can be set, reset, and obtained as required through APIs.
3247 ///
3248 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3249 ///
3250 /// .string: default placeholder text.
3251 ///
3252 ///
3253 ///
3254 /// Format of the return value [`ArkUI_AttributeItem`]:
3255 ///
3256 /// .string: default placeholder text.
3257 pub const NODE_TEXT_INPUT_PLACEHOLDER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7000);
3258 /// Defines the default text content of the single-line text box.
3259 /// This attribute can be set, reset, and obtained as required through APIs.
3260 ///
3261 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3262 ///
3263 /// .string: default text content.
3264 ///
3265 ///
3266 ///
3267 /// Format of the return value [`ArkUI_AttributeItem`]:
3268 ///
3269 /// .string: default text content.
3270 pub const NODE_TEXT_INPUT_TEXT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7001);
3271 /// Defines the caret color attribute.
3272 /// This attribute can be set, reset, and obtained as required through APIs.
3273 ///
3274 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3275 ///
3276 /// .value[0].u32: caret color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3277 ///
3278 ///
3279 ///
3280 /// Format of the return value [`ArkUI_AttributeItem`]:
3281 ///
3282 /// .value[0].u32: caret color, in 0xARGB format.
3283 pub const NODE_TEXT_INPUT_CARET_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7002);
3284 /// Defines the caret style attribute.
3285 /// This attribute can be set, reset, and obtained as required through APIs.
3286 ///
3287 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3288 ///
3289 /// .value[0].f32: caret width, in vp.
3290 ///
3291 ///
3292 ///
3293 /// Format of the return value [`ArkUI_AttributeItem`]:
3294 ///
3295 /// .value[0].f32: caret width, in vp.
3296 pub const NODE_TEXT_INPUT_CARET_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7003);
3297 /// Defines the underline attribute of the single-line text box.
3298 /// This attribute can be set, reset, and obtained as required through APIs.
3299 ///
3300 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3301 ///
3302 /// .value[0].i32: whether to show an underline.
3303 /// The value <b>true</b> means to show an underline, and <b>false</b> means the opposite.
3304 ///
3305 ///
3306 ///
3307 /// Format of the return value [`ArkUI_AttributeItem`]:
3308 ///
3309 /// .value[0].i32: The value <b>1</b> means to show an underline, and <b>0</b> means the opposite.
3310 pub const NODE_TEXT_INPUT_SHOW_UNDERLINE: ArkUI_NodeAttributeType =
3311 ArkUI_NodeAttributeType(7004);
3312 /// Defines the maximum number of characters in the text input.
3313 /// This attribute can be set, reset, and obtained as required through APIs.
3314 ///
3315 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3316 ///
3317 /// .value[0].i32: maximum number of characters in the text input, without a unit.
3318 ///
3319 ///
3320 ///
3321 /// Format of the return value [`ArkUI_AttributeItem`]:
3322 ///
3323 /// .value[0].i32: maximum number of characters in the text input.
3324 pub const NODE_TEXT_INPUT_MAX_LENGTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7005);
3325 /// Defines the type of the Enter key.
3326 /// This attribute can be set, reset, and obtained as required through APIs.
3327 ///
3328 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3329 ///
3330 /// .value[0].i32: type of the Enter key[`ArkUI_EnterKeyType`]. The default value is <b>ARKUI_ENTER_KEY_TYPE_DONE</b>.
3331 ///
3332 ///
3333 ///
3334 /// Format of the return value [`ArkUI_AttributeItem`]:
3335 ///
3336 /// .value[0].i32: type of the Enter key[`ArkUI_EnterKeyType`].
3337 pub const NODE_TEXT_INPUT_ENTER_KEY_TYPE: ArkUI_NodeAttributeType =
3338 ArkUI_NodeAttributeType(7006);
3339 /// Defines the placeholder text color.
3340 /// This attribute can be set, reset, and obtained as required through APIs.
3341 ///
3342 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3343 ///
3344 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3345 ///
3346 ///
3347 ///
3348 /// Format of the return value [`ArkUI_AttributeItem`]:
3349 ///
3350 /// .value[0].u32: color value, in 0xARGB format.
3351 pub const NODE_TEXT_INPUT_PLACEHOLDER_COLOR: ArkUI_NodeAttributeType =
3352 ArkUI_NodeAttributeType(7007);
3353 /// Defines the placeholder text font.
3354 /// This attribute can be set, reset, and obtained as required through APIs.
3355 ///
3356 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3357 ///
3358 /// .value[0]?.f32: font size, in fp. Optional. The default value is <b>16.0</b>.
3359 ///
3360 /// .value[1]?.i32: font style [`ArkUI_FontStyle`]. Optional.
3361 /// The default value is <b>ARKUI_FONT_STYLE_NORMAL</b>.
3362 ///
3363 /// .value[2]?.i32: font weight [`ArkUI_FontWeight`]. Optional.
3364 /// The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
3365 ///
3366 /// ?.string: font family. Multiple font families are separated by commas (,).
3367 /// Example: "font weight; font family 1, font family 2".
3368 ///
3369 ///
3370 ///
3371 /// Format of the return value [`ArkUI_AttributeItem`]:
3372 ///
3373 /// .value[0].f32: font size, in fp.
3374 ///
3375 /// .value[1].i32: font style [`ArkUI_FontStyle`].
3376 ///
3377 /// .value[2].i32: font weight [`ArkUI_FontWeight`].
3378 ///
3379 /// .string: font family. Multiple font families are separated by commas (,).
3380 pub const NODE_TEXT_INPUT_PLACEHOLDER_FONT: ArkUI_NodeAttributeType =
3381 ArkUI_NodeAttributeType(7008);
3382 /// Defines whether to enable the input method when the component obtains focus.
3383 /// This attribute can be set, reset, and obtained as required through APIs.
3384 ///
3385 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3386 ///
3387 /// .value[0].i32: whether to enable the input method when the component obtains focus.
3388 /// The value <b>true</b> means to enable the input method, and <b>false</b> means the opposite.
3389 ///
3390 ///
3391 ///
3392 ///
3393 /// Format of the return value [`ArkUI_AttributeItem`]:
3394 ///
3395 /// .value[0].i32: The value <b>1</b> means to enable the input method when the component obtains focus,
3396 /// and <b>0</b> means the opposite.
3397 pub const NODE_TEXT_INPUT_ENABLE_KEYBOARD_ON_FOCUS: ArkUI_NodeAttributeType =
3398 ArkUI_NodeAttributeType(7009);
3399 /// Defines the text box type. This attribute can be set, reset, and obtained as required through APIs.
3400 ///
3401 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3402 ///
3403 /// .value[0].i32: text box type [`ArkUI_TextInputType`].
3404 /// The default value is <b>ARKUI_TEXTINPUT_TYPE_NORMAL</b>.
3405 ///
3406 ///
3407 ///
3408 /// Format of the return value [`ArkUI_AttributeItem`]:
3409 ///
3410 /// .value[0].i32: text box type [`ArkUI_TextInputType`].
3411 pub const NODE_TEXT_INPUT_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7010);
3412 /// Defines the background color of the selected text.
3413 /// This attribute can be set, reset, and obtained as required through APIs.
3414 ///
3415 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3416 ///
3417 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3418 ///
3419 ///
3420 ///
3421 /// Format of the return value [`ArkUI_AttributeItem`]:
3422 ///
3423 /// .value[0].u32: color value, in 0xARGB format.
3424 pub const NODE_TEXT_INPUT_SELECTED_BACKGROUND_COLOR: ArkUI_NodeAttributeType =
3425 ArkUI_NodeAttributeType(7011);
3426 /// Defines whether to display the password icon at the end of the password text box.
3427 /// This attribute can be set, reset, and obtained as required through APIs.
3428 ///
3429 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3430 ///
3431 /// .value[0].i32: whether to display the password icon at the end of the password text box.
3432 /// The value <b>true</b> means to display the password icon, and <b>false</b> means the opposite.
3433 ///
3434 ///
3435 ///
3436 /// Format of the return value [`ArkUI_AttributeItem`]:
3437 ///
3438 /// .value[0].i32: The value <b>1</b> means to display the password icon at the end of the password text box,
3439 /// and <b>0</b> means the opposite.
3440 pub const NODE_TEXT_INPUT_SHOW_PASSWORD_ICON: ArkUI_NodeAttributeType =
3441 ArkUI_NodeAttributeType(7012);
3442 /// Defines the editable state for the single-line text box.
3443 /// This attribute can be set as required through APIs.
3444 ///
3445 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3446 ///
3447 /// .value[0].i32: whether to remain in the editable state. The value
3448 /// <b>true</b> means to remain in the editable state, and <b>false</b> means to exit the editable state.
3449 ///
3450 ///
3451 ///
3452 /// Format of the [`ArkUI_AttributeItem`] parameter for obtaining the attribute:
3453 /// .value[0].i32: whether to remain in the editable state. The value <b>true</b> means to remain in the editable
3454 /// state, and <b>false</b> means to exit the editable state.
3455 pub const NODE_TEXT_INPUT_EDITING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7013);
3456 /// Defines the style of the cancel button on the right of the single-line text box.
3457 /// This attribute can be set, reset, and obtained as required through APIs.
3458 ///
3459 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3460 ///
3461 /// .value[0].i32: button style [`ArkUI_CancelButtonStyle`].
3462 /// The default value is <b>ARKUI_CANCELBUTTON_STYLE_INPUT</b>.
3463 ///
3464 /// .value[1]?.f32: button icon size, in vp.
3465 ///
3466 /// .value[2]?.u32: button icon color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3467 ///
3468 /// ?.string: button icon image source. The value is the local address of the image, for example, /pages/icon.png.
3469 ///
3470 ///
3471 ///
3472 /// Format of the return value [`ArkUI_AttributeItem`]:
3473 ///
3474 /// .value[0].i32: button style [`ArkUI_CancelButtonStyle`].
3475 ///
3476 /// .value[1].f32: icon size, in vp.
3477 ///
3478 /// .value[2].u32: button icon color, in 0xARGB format.
3479 ///
3480 /// .string: button icon image source.
3481 pub const NODE_TEXT_INPUT_CANCEL_BUTTON: ArkUI_NodeAttributeType =
3482 ArkUI_NodeAttributeType(7014);
3483 /// Sets the text selection area, which will be highlighted.
3484 /// This attribute can be set, reset, and obtained as required through APIs.
3485 ///
3486 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3487 ///
3488 /// .value[0].i32: start position of the text selection.
3489 ///
3490 /// .value[1].i32: end position of the text selection.
3491 ///
3492 ///
3493 ///
3494 /// Format of the return value [`ArkUI_AttributeItem`]:
3495 ///
3496 /// .value[0].i32: start position of the text selection.
3497 ///
3498 /// .value[1].i32: end position of the text selection.
3499 pub const NODE_TEXT_INPUT_TEXT_SELECTION: ArkUI_NodeAttributeType =
3500 ArkUI_NodeAttributeType(7015);
3501 /// Sets the color of the text underline when it is enabled.
3502 ///
3503 /// The default underline color configured for the theme is <b>'0x33182431'</b>.
3504 ///
3505 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3506 ///
3507 /// .value[0].u32: color of the underline applied to the text being typed in.
3508 /// The value is in 0xARGB format.
3509 ///
3510 /// .value[1].u32: color of the underline applied to the text in the normal state.
3511 /// The value is in 0xARGB format.
3512 ///
3513 /// .value[2].u32: color of the underline applied to the text when an error is detected.
3514 /// The value is in 0xARGB format.
3515 ///
3516 /// .value[3].u32: color of the underline applied to the text when it is disabled.
3517 /// The value is in 0xARGB format.
3518 ///
3519 ///
3520 ///
3521 /// Format of the return value [`ArkUI_AttributeItem`]:
3522 ///
3523 /// .value[0].u32: color of the underline applied to the text being typed in. The value is in 0xARGB format.
3524 ///
3525 /// .value[1].u32: color of the underline applied to the text in the normal state. The value is in 0xARGB format.
3526 ///
3527 /// .value[2].u32: color of the underline applied to the text when an error is detected.
3528 /// The value is in 0xARGB format.
3529 ///
3530 /// .value[3].u32: color of the underline applied to the text when it is disabled. The value is in 0xARGB format.
3531 pub const NODE_TEXT_INPUT_UNDERLINE_COLOR: ArkUI_NodeAttributeType =
3532 ArkUI_NodeAttributeType(7016);
3533 /// Sets whether to enable autofill.
3534 ///
3535 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3536 ///
3537 /// .value[0].i32: whether to enable autofill. The default value is <b>true</b>.
3538 ///
3539 ///
3540 ///
3541 /// Format of the return value [`ArkUI_AttributeItem`]:
3542 ///
3543 /// .value[0].i32: whether to enable autofill.
3544 pub const NODE_TEXT_INPUT_ENABLE_AUTO_FILL: ArkUI_NodeAttributeType =
3545 ArkUI_NodeAttributeType(7017);
3546 /// Sets the autofill type.
3547 ///
3548 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3549 ///
3550 /// .value[0].i32: autofill type. The parameter type is [`ArkUI_TextInputContentType`].
3551 ///
3552 ///
3553 ///
3554 /// Format of the return value [`ArkUI_AttributeItem`]:
3555 ///
3556 /// .value[0].i32: autofill type. The parameter type is [`ArkUI_TextInputContentType`].
3557 pub const NODE_TEXT_INPUT_CONTENT_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7018);
3558 /// Defines the rules for generating passwords. When autofill is used, these rules are transparently
3559 /// transmitted to Password Vault for generating a new password.
3560 ///
3561 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3562 ///
3563 /// .string: rules for generating passwords.
3564 ///
3565 ///
3566 ///
3567 /// Format of the return value [`ArkUI_AttributeItem`]:
3568 ///
3569 /// .string: rules for generating passwords.
3570 pub const NODE_TEXT_INPUT_PASSWORD_RULES: ArkUI_NodeAttributeType =
3571 ArkUI_NodeAttributeType(7019);
3572 /// Sets whether to select all text in the initial state. The inline mode is not supported.
3573 ///
3574 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3575 ///
3576 /// .value[0].i32: whether to select all text in the initial state. The default value is b>false</b>.
3577 ///
3578 ///
3579 ///
3580 /// Format of the return value [`ArkUI_AttributeItem`]:
3581 ///
3582 /// .value[0].i32: whether to select all text in the initial state.
3583 pub const NODE_TEXT_INPUT_SELECT_ALL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7020);
3584 /// Sets the regular expression for input filtering.
3585 /// Only inputs that comply with the regular expression can be displayed.
3586 /// Other inputs are filtered out. The specified regular expression can match single characters,
3587 /// but not strings.
3588 ///
3589 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3590 ///
3591 /// .string: regular expression.
3592 ///
3593 ///
3594 ///
3595 /// Format of the return value [`ArkUI_AttributeItem`]:
3596 ///
3597 /// .string: regular expression.
3598 pub const NODE_TEXT_INPUT_INPUT_FILTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7021);
3599 /// Sets the text box to the default style or inline input style.
3600 ///
3601 /// For the inline input style, only <b>InputType.Normal</b> is supported.
3602 ///
3603 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3604 ///
3605 /// .value[0].i32: text input style. The parameter type is [`ArkUI_TextInputStyle`].
3606 ///
3607 ///
3608 ///
3609 /// Format of the return value [`ArkUI_AttributeItem`]:
3610 ///
3611 /// .value[0].i32: text input style. The parameter type is [`ArkUI_TextInputStyle`].
3612 pub const NODE_TEXT_INPUT_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7022);
3613 /// Sets or obtains the caret position.
3614 ///
3615 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3616 ///
3617 /// In the case of setting the caret position:
3618 /// .value[0].i32: character count from the beginning of a string to the caret position.
3619 ///
3620 ///
3621 /// Format of the return value [`ArkUI_AttributeItem`]:
3622 ///
3623 /// In the case of obtaining the caret position: If this API is called when the caret position is updated in the
3624 /// current frame, it will not take effect.
3625 /// .value[0].i32: index of the caret position.
3626 ///
3627 /// .value[1].f32: X coordinate of the caret relative to the text box.
3628 ///
3629 /// .value[2].f32: Y coordinate of the caret relative to the text box.
3630 pub const NODE_TEXT_INPUT_CARET_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7023);
3631 /// Obtains the position of the edited text area relative to the component and its size.
3632 ///
3633 /// Format of the return value [`ArkUI_AttributeItem`]:
3634 ///
3635 /// .value[0].f32: horizontal coordinate.
3636 ///
3637 /// .value[1].f32: vertical coordinate.
3638 ///
3639 /// .value[2].f32: content width.
3640 ///
3641 /// .value[3].f32: content height.
3642 pub const NODE_TEXT_INPUT_CONTENT_RECT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7024);
3643 /// Obtains the number of lines of the edited text.
3644 ///
3645 /// Format of the return value [`ArkUI_AttributeItem`]:
3646 ///
3647 /// .value[0].i32: number of lines of the edited text.
3648 pub const NODE_TEXT_INPUT_CONTENT_LINE_COUNT: ArkUI_NodeAttributeType =
3649 ArkUI_NodeAttributeType(7025);
3650 /// Sets whether to hide the text selection menu when the text box is long-pressed, double-click, or
3651 /// right-clicked. This attribute can be set, reset, and obtained as required through APIs.
3652 ///
3653 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3654 ///
3655 /// .value[0].i32: whether to hide the text selection menu when the text box is long-pressed, double-click, or
3656 /// right-clicked. The default value is <b>false</b>.
3657 ///
3658 ///
3659 ///
3660 /// Format of the return value [`ArkUI_AttributeItem`]:
3661 ///
3662 /// .value[0].i32: whether to hide the text selection menu when the text box is long-pressed, double-click, or
3663 /// right-clicked.
3664 pub const NODE_TEXT_INPUT_SELECTION_MENU_HIDDEN: ArkUI_NodeAttributeType =
3665 ArkUI_NodeAttributeType(7026);
3666 /// Sets whether the text box loses focus after the Enter key is pressed to submit information.
3667 ///
3668 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3669 ///
3670 /// .value[0].i32: whether the text box loses focus.
3671 ///
3672 ///
3673 ///
3674 /// Format of the return value [`ArkUI_AttributeItem`]:
3675 ///
3676 /// .value[0].i32: whether the text box loses focus.
3677 pub const NODE_TEXT_INPUT_BLUR_ON_SUBMIT: ArkUI_NodeAttributeType =
3678 ArkUI_NodeAttributeType(7027);
3679 /// Set up a custom keyboard.
3680 ///
3681 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3682 ///
3683 /// .object:custom keyboard,The parameter type is[`ArkUI_NodeHandle`]。
3684 ///
3685 /// .value[0]?.i32:Sets whether the custom keyboard supports the avoidance feature, default value false.
3686 ///
3687 ///
3688 ///
3689 /// Format of the return value [`ArkUI_AttributeItem`]:
3690 ///
3691 /// .object:custom keyboard,The parameter type is[`ArkUI_NodeHandle`]。
3692 ///
3693 /// .value[0].i32:Set whether the custom keyboard supports the avoidance function.
3694 pub const NODE_TEXT_INPUT_CUSTOM_KEYBOARD: ArkUI_NodeAttributeType =
3695 ArkUI_NodeAttributeType(7028);
3696 /// Defines the line break rule. This attribute can be set, reset, and obtained as required through APIs.
3697 ///
3698 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3699 ///
3700 /// .value[0].i32: The parameter type is [`ArkUI_WordBreak`].
3701 ///
3702 ///
3703 ///
3704 /// Format of the return value [`ArkUI_AttributeItem`]:
3705 ///
3706 /// .value[0].i32: The parameter type is [`ArkUI_WordBreak`].
3707 pub const NODE_TEXT_INPUT_WORD_BREAK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7029);
3708 /// Sets whether the keyboard pops up when the input box gains focus.
3709 /// It supports property setting, property reset and property acquisition interfaces.
3710 ///
3711 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
3712 ///
3713 /// .value[0].i32: Whether to pop up the keyboard.
3714 ///
3715 ///
3716 ///
3717 /// Attribute acquisition method return value [`ArkUI_AttributeItem`] format:
3718 ///
3719 /// .value[0].i32: Whether to pop up the keyboard.
3720 pub const NODE_TEXT_INPUT_SHOW_KEYBOARD_ON_FOCUS: ArkUI_NodeAttributeType =
3721 ArkUI_NodeAttributeType(7030);
3722 /// When this property is set, the height of the textInput component is calculated using this property.
3723 ///
3724 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3725 ///
3726 /// .value[0].i32: set the value of numberOfLines.
3727 ///
3728 ///
3729 ///
3730 /// Format of the return value [`ArkUI_AttributeItem`]:
3731 ///
3732 /// .value[0].i32: the value of numberOfLines.
3733 pub const NODE_TEXT_INPUT_NUMBER_OF_LINES: ArkUI_NodeAttributeType =
3734 ArkUI_NodeAttributeType(7031);
3735 /// Sets the letter spacing of the <b>TextInput</b> component.
3736 /// This attribute can be set, reset, and obtained as required through APIs.
3737 ///
3738 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3739 ///
3740 /// .value[0].f32: letter spacing. The default unit is fp.
3741 ///
3742 ///
3743 ///
3744 /// Format of the return value [`ArkUI_AttributeItem`]:
3745 ///
3746 /// .value[0].f32: letter spacing. The default unit is fp.
3747 ///
3748 ///
3749 ///
3750 /// Available since API-level: 15
3751 #[cfg(feature = "api-15")]
3752 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
3753 pub const NODE_TEXT_INPUT_LETTER_SPACING: ArkUI_NodeAttributeType =
3754 ArkUI_NodeAttributeType(7032);
3755 /// Sets whether to enable preview text for the <b>TextInput</b> component.
3756 /// This attribute can be set, reset, and obtained as required through APIs.
3757 ///
3758 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3759 ///
3760 /// .value[0].i32: whether to enable preview tex.
3761 ///
3762 ///
3763 ///
3764 /// Format of the return value [`ArkUI_AttributeItem`]:
3765 ///
3766 /// .value[0].i32: whether to enable preview tex.
3767 ///
3768 ///
3769 ///
3770 /// Available since API-level: 15
3771 #[cfg(feature = "api-15")]
3772 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
3773 pub const NODE_TEXT_INPUT_ENABLE_PREVIEW_TEXT: ArkUI_NodeAttributeType =
3774 ArkUI_NodeAttributeType(7033);
3775 /// Sets whether to center text vertically in the textInput component.
3776 ///
3777 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3778 ///
3779 /// .value[0].i32: whether to center text vertically. The default value is <b>false</b>.
3780 ///
3781 ///
3782 ///
3783 /// Format of the return value [`ArkUI_AttributeItem`]:
3784 ///
3785 /// .value[0].i32: whether to center text vertically.
3786 ///
3787 ///
3788 ///
3789 /// Available since API-level: 18
3790 #[cfg(feature = "api-18")]
3791 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
3792 pub const NODE_TEXT_INPUT_HALF_LEADING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(7034);
3793 /// Set the keyboard style of textInput
3794 ///
3795 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3796 ///
3797 /// .value[0].i32:keyboard style,the parameter type is [`ArkUI_KeyboardAppearanceType`]。
3798 ///
3799 ///
3800 ///
3801 /// Format of the return value [`ArkUI_AttributeItem`]:
3802 ///
3803 /// .value[0].i32:keyboard style,the parameter type is [`ArkUI_KeyboardAppearanceType`]。
3804 ///
3805 ///
3806 ///
3807 /// Available since API-level: 15
3808 #[cfg(feature = "api-15")]
3809 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
3810 pub const NODE_TEXT_INPUT_KEYBOARD_APPEARANCE: ArkUI_NodeAttributeType =
3811 ArkUI_NodeAttributeType(7035);
3812 /// Defines the default placeholder text for the multi-line text box.
3813 /// This attribute can be set, reset, and obtained as required through APIs.
3814 ///
3815 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3816 ///
3817 /// .string: default placeholder text.
3818 ///
3819 ///
3820 ///
3821 /// Format of the return value [`ArkUI_AttributeItem`]:
3822 ///
3823 /// .string: default placeholder text.
3824 pub const NODE_TEXT_AREA_PLACEHOLDER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8000);
3825 /// Defines the default text content for the multi-line text box.
3826 /// This attribute can be set, reset, and obtained as required through APIs.
3827 ///
3828 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3829 ///
3830 /// .string: default text content.
3831 ///
3832 ///
3833 ///
3834 /// Format of the return value [`ArkUI_AttributeItem`]:
3835 ///
3836 /// .string: default text content.
3837 pub const NODE_TEXT_AREA_TEXT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8001);
3838 /// Defines the maximum number of characters in the text input.
3839 /// This attribute can be set, reset, and obtained as required through APIs.
3840 ///
3841 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3842 ///
3843 /// .value[0].i32: maximum number of characters in the text input.
3844 ///
3845 ///
3846 ///
3847 /// Format of the return value [`ArkUI_AttributeItem`]:
3848 ///
3849 /// .value[0].i32: maximum number of characters in the text input.
3850 pub const NODE_TEXT_AREA_MAX_LENGTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8002);
3851 /// Defines the placeholder text color.
3852 /// This attribute can be set, reset, and obtained as required through APIs.
3853 ///
3854 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3855 ///
3856 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3857 ///
3858 ///
3859 ///
3860 /// Format of the return value [`ArkUI_AttributeItem`]:
3861 ///
3862 /// .value[0].u32: color value, in 0xARGB format.
3863 pub const NODE_TEXT_AREA_PLACEHOLDER_COLOR: ArkUI_NodeAttributeType =
3864 ArkUI_NodeAttributeType(8003);
3865 /// Defines the placeholder text font.
3866 /// This attribute can be set, reset, and obtained as required through APIs.
3867 ///
3868 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3869 ///
3870 /// .value[0]?.f32: font size, in fp. Optional. The default value is <b>16.0</b>.
3871 ///
3872 /// .value[1]?.i32: font style [`ArkUI_FontStyle`]. Optional. The default value is <b>ARKUI_FONT_STYLE_NORMAL</b>.
3873 ///
3874 /// .value[2]?.i32: font weight [`ArkUI_FontWeight`]. Optional. The default value is <b>ARKUI_FONT_WEIGHT_NORMAL</b>.
3875 ///
3876 /// ?.string: font family. Multiple font families are separated by commas (,). For example, "font weight; font family 1, font family 2".
3877 ///
3878 ///
3879 ///
3880 /// Format of the return value [`ArkUI_AttributeItem`]:
3881 ///
3882 /// .value[0].f32: font size, in fp.
3883 ///
3884 /// .value[1].i32: font style [`ArkUI_FontStyle`].
3885 ///
3886 /// .value[2].i32: font weight [`ArkUI_FontWeight`].
3887 ///
3888 /// .string: font family. Multiple font families are separated by commas (,).
3889 pub const NODE_TEXT_AREA_PLACEHOLDER_FONT: ArkUI_NodeAttributeType =
3890 ArkUI_NodeAttributeType(8004);
3891 /// Defines the caret color attribute.
3892 /// This attribute can be set, reset, and obtained as required through APIs.
3893 ///
3894 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3895 ///
3896 /// .value[0].u32: background color, in 0xARGB format. For example, 0xFFFF0000 indicates red.
3897 ///
3898 ///
3899 ///
3900 /// Format of the return value [`ArkUI_AttributeItem`]:
3901 ///
3902 /// .value[0].u32: background color, in 0xARGB format.
3903 pub const NODE_TEXT_AREA_CARET_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8005);
3904 /// Defines the editable state for the multi-line text box.
3905 /// This attribute can be set as required through APIs.
3906 ///
3907 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3908 ///
3909 /// .value[0].i32: whether to remain in the editable state. The value <b>true</b> means to remain in the
3910 /// editable state, and <b>false</b> means to exit the editable state.
3911 ///
3912 ///
3913 ///
3914 ///
3915 /// Format of the [`ArkUI_AttributeItem`] parameter for obtaining the attribute:
3916 /// .value[0].i32: whether to remain in the editable state. The value <b>true</b> means to remain in the editable
3917 /// state, and <b>false</b> means to exit the editable state.
3918 ///
3919 pub const NODE_TEXT_AREA_EDITING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8006);
3920 /// Defines the text box type. This attribute can be set, reset, and obtained as required through APIs.
3921 ///
3922 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3923 ///
3924 /// .value[0].i32: text box type [`ArkUI_TextAreaType`].
3925 /// The default value is <b>ARKUI_TEXTAREA_TYPE_NORMAL</b>.
3926 ///
3927 ///
3928 ///
3929 /// Format of the return value [`ArkUI_AttributeItem`]:
3930 ///
3931 /// .value[0].i32: text box type [`ArkUI_TextAreaType`].
3932 pub const NODE_TEXT_AREA_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8007);
3933 /// Defines the counter settings. This attribute can be set, reset, and obtained as required through APIs.
3934 ///
3935 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3936 ///
3937 /// .value[0].i32: whether to show a character counter. The value <b>true</b> means to show a character counter.
3938 ///
3939 /// .value[1]?.f32: threshold percentage for displaying the character counter. The character counter is displayed
3940 /// when the number of characters that have been entered is greater than the maximum number of characters multiplied
3941 /// by the threshold percentage value. The value range is 1 to 100. If the value is a decimal, it is rounded down.
3942 ///
3943 /// .value[2]?.i32: whether to highlight the border when the number of entered characters reaches the maximum.
3944 ///
3945 ///
3946 ///
3947 /// Format of the return value [`ArkUI_AttributeItem`]:
3948 ///
3949 /// .value[0].i32: whether to show a character counter.
3950 ///
3951 /// .value[1].f32: threshold percentage for displaying the character counter. The character counter is displayed
3952 /// when the number of characters that have been entered is greater than the maximum number of characters multiplied
3953 /// by the threshold percentage value. The value range is 1 to 100.
3954 ///
3955 /// .value[2].i32: whether to highlight the border when the number of entered characters reaches the maximum.
3956 /// The default value is <b>true</b>.
3957 pub const NODE_TEXT_AREA_SHOW_COUNTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8008);
3958 /// Sets whether to hide the text selection menu when the text box is long-pressed, double-click,
3959 /// or right-clicked. This attribute can be set, reset, and obtained as required through APIs.
3960 ///
3961 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3962 ///
3963 /// .value[0].i32: whether to hide the text selection menu when the text box is long-pressed, double-click,
3964 /// or right-clicked. The default value is <b>false</b>.
3965 ///
3966 ///
3967 ///
3968 /// Format of the return value [`ArkUI_AttributeItem`]:
3969 ///
3970 /// .value[0].i32: whether to hide the text selection menu when the text box is long-pressed, double-click,
3971 /// or right-clicked.
3972 pub const NODE_TEXT_AREA_SELECTION_MENU_HIDDEN: ArkUI_NodeAttributeType =
3973 ArkUI_NodeAttributeType(8009);
3974 /// Sets whether the multi-line text box loses focus after the Enter key is pressed to submit information.
3975 ///
3976 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3977 ///
3978 /// .value[0].i32: whether the text box loses focus.
3979 ///
3980 ///
3981 ///
3982 /// Format of the return value [`ArkUI_AttributeItem`]:
3983 ///
3984 /// .value[0].i32: whether the text box loses focus.
3985 pub const NODE_TEXT_AREA_BLUR_ON_SUBMIT: ArkUI_NodeAttributeType =
3986 ArkUI_NodeAttributeType(8010);
3987 /// Sets the regular expression for input filtering.
3988 /// Only inputs that comply with the regular expression can be displayed.
3989 /// Other inputs are filtered out. The specified regular expression can match single characters,
3990 /// but not strings.
3991 ///
3992 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
3993 ///
3994 /// .string: regular expression.
3995 ///
3996 ///
3997 ///
3998 /// Format of the return value [`ArkUI_AttributeItem`]:
3999 ///
4000 /// .string: regular expression.
4001 pub const NODE_TEXT_AREA_INPUT_FILTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8011);
4002 /// Defines the background color of the selected text.
4003 /// This attribute can be set, reset, and obtained as required through APIs.
4004 ///
4005 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4006 ///
4007 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
4008 ///
4009 ///
4010 ///
4011 /// Format of the return value [`ArkUI_AttributeItem`]:
4012 ///
4013 /// .value[0].u32: color value, in 0xARGB format.
4014 pub const NODE_TEXT_AREA_SELECTED_BACKGROUND_COLOR: ArkUI_NodeAttributeType =
4015 ArkUI_NodeAttributeType(8012);
4016 /// Defines the type of the Enter key.
4017 /// This attribute can be set, reset, and obtained as required through APIs.
4018 ///
4019 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4020 ///
4021 /// .value[0].i32: type of the Enter key[`ArkUI_EnterKeyType`]. The default value is <b>ARKUI_ENTER_KEY_TYPE_DONE</b>.
4022 ///
4023 ///
4024 ///
4025 /// Format of the return value [`ArkUI_AttributeItem`]:
4026 ///
4027 /// .value[0].i32: type of the Enter key[`ArkUI_EnterKeyType`].
4028 pub const NODE_TEXT_AREA_ENTER_KEY_TYPE: ArkUI_NodeAttributeType =
4029 ArkUI_NodeAttributeType(8013);
4030 /// Defines whether to enable the input method when the component obtains focus.
4031 /// This attribute can be set, reset, and obtained as required through APIs.
4032 ///
4033 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4034 ///
4035 /// .value[0].i32: whether to enable the input method when the component obtains focus.
4036 /// The value <b>true</b> means to enable the input method, and <b>false</b> means the opposite.
4037 ///
4038 ///
4039 ///
4040 ///
4041 /// Format of the return value [`ArkUI_AttributeItem`]:
4042 ///
4043 /// .value[0].i32: The value <b>1</b> means to enable the input method when the component obtains focus,
4044 /// and <b>0</b> means the opposite.
4045 pub const NODE_TEXT_AREA_ENABLE_KEYBOARD_ON_FOCUS: ArkUI_NodeAttributeType =
4046 ArkUI_NodeAttributeType(8014);
4047 /// Defines whether to enable the input method when the component obtains focus.
4048 /// This attribute can be set, reset, and obtained as required through APIs.
4049 ///
4050 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4051 ///
4052 /// .value[0].i32: whether to enable the input method when the component obtains focus.
4053 /// The value <b>true</b> means to enable the input method, and <b>false</b> means the opposite.
4054 ///
4055 ///
4056 ///
4057 ///
4058 /// Format of the return value [`ArkUI_AttributeItem`]:
4059 ///
4060 /// .value[0].i32: The value <b>1</b> means to enable the input method when the component obtains focus,
4061 /// and <b>0</b> means the opposite.
4062 pub const NODE_TEXT_AREA_CARET_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8015);
4063 /// Obtains the position of the edited text area relative to the component and its size.
4064 ///
4065 /// Format of the return value [`ArkUI_AttributeItem`]:
4066 ///
4067 /// .value[0].f32: horizontal coordinate.
4068 ///
4069 /// .value[1].f32: vertical coordinate.
4070 ///
4071 /// .value[2].f32: content width.
4072 ///
4073 /// .value[3].f32: content height.
4074 pub const NODE_TEXT_AREA_CONTENT_RECT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8016);
4075 /// Obtains the number of lines of the edited text.
4076 ///
4077 /// Format of the return value [`ArkUI_AttributeItem`]:
4078 ///
4079 /// .value[0].i32: number of lines of the edited text.
4080 pub const NODE_TEXT_AREA_CONTENT_LINE_COUNT: ArkUI_NodeAttributeType =
4081 ArkUI_NodeAttributeType(8017);
4082 /// Sets the text selection area, which will be highlighted.
4083 /// This attribute can be set, reset, and obtained as required through APIs.
4084 ///
4085 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4086 ///
4087 /// .value[0].i32: start position of the text selection.
4088 ///
4089 /// .value[1].i32: end position of the text selection.
4090 ///
4091 ///
4092 ///
4093 /// Format of the return value [`ArkUI_AttributeItem`]:
4094 ///
4095 /// .value[0].i32: start position of the text selection.
4096 ///
4097 /// .value[1].i32: end position of the text selection.
4098 pub const NODE_TEXT_AREA_TEXT_SELECTION: ArkUI_NodeAttributeType =
4099 ArkUI_NodeAttributeType(8018);
4100 /// Sets whether to enable autofill.
4101 ///
4102 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4103 ///
4104 /// .value[0].i32: whether to enable autofill. The default value is <b>true</b>.
4105 ///
4106 ///
4107 ///
4108 /// Format of the return value [`ArkUI_AttributeItem`]:
4109 ///
4110 /// .value[0].i32: whether to enable autofill.
4111 pub const NODE_TEXT_AREA_ENABLE_AUTO_FILL: ArkUI_NodeAttributeType =
4112 ArkUI_NodeAttributeType(8019);
4113 /// Sets the autofill type.
4114 ///
4115 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4116 ///
4117 /// .value[0].i32: autofill type. The parameter type is [`ArkUI_TextInputContentType`].
4118 ///
4119 ///
4120 ///
4121 /// Format of the return value [`ArkUI_AttributeItem`]:
4122 ///
4123 /// .value[0].i32: autofill type. The parameter type is [`ArkUI_TextInputContentType`].
4124 pub const NODE_TEXT_AREA_CONTENT_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8020);
4125 /// Sets whether the keyboard pops up when the input box gains focus.
4126 /// It supports property setting, property reset and property acquisition interfaces.
4127 ///
4128 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
4129 ///
4130 /// .value[0].i32: Whether to pop up the keyboard.
4131 ///
4132 ///
4133 ///
4134 /// Attribute acquisition method return value [`ArkUI_AttributeItem`] format:
4135 ///
4136 /// .value[0].i32: Whether to pop up the keyboard.
4137 pub const NODE_TEXT_AREA_SHOW_KEYBOARD_ON_FOCUS: ArkUI_NodeAttributeType =
4138 ArkUI_NodeAttributeType(8021);
4139 /// When this property is set, the height of the textArea component is calculated using this property.
4140 ///
4141 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4142 ///
4143 /// .value[0].i32: set the value of numberOfLines.
4144 ///
4145 ///
4146 ///
4147 /// Format of the return value [`ArkUI_AttributeItem`]:
4148 ///
4149 /// .value[0].i32: Set the value of numberOfLines
4150 pub const NODE_TEXT_AREA_NUMBER_OF_LINES: ArkUI_NodeAttributeType =
4151 ArkUI_NodeAttributeType(8022);
4152 /// Sets the letter spacing of the <b>TextArea</b> component.
4153 /// This attribute can be set, reset, and obtained as required through APIs.
4154 ///
4155 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4156 ///
4157 /// .value[0].f32: letter spacing. The default unit is fp.
4158 ///
4159 ///
4160 ///
4161 /// Format of the return value [`ArkUI_AttributeItem`]:
4162 ///
4163 /// .value[0].f32: letter spacing. The default unit is fp.
4164 ///
4165 ///
4166 ///
4167 /// Available since API-level: 15
4168 #[cfg(feature = "api-15")]
4169 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4170 pub const NODE_TEXT_AREA_LETTER_SPACING: ArkUI_NodeAttributeType =
4171 ArkUI_NodeAttributeType(8023);
4172 /// Sets whether to enable preview text for the <b>TextArea</b> component.
4173 /// This attribute can be set, reset, and obtained as required through APIs.
4174 ///
4175 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4176 ///
4177 /// .value[0].i32: whether to enable preview tex.
4178 ///
4179 ///
4180 ///
4181 /// Format of the return value [`ArkUI_AttributeItem`]:
4182 ///
4183 /// .value[0].i32: whether to enable preview tex.
4184 ///
4185 ///
4186 ///
4187 /// Available since API-level: 15
4188 #[cfg(feature = "api-15")]
4189 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4190 pub const NODE_TEXT_AREA_ENABLE_PREVIEW_TEXT: ArkUI_NodeAttributeType =
4191 ArkUI_NodeAttributeType(8024);
4192 /// Sets whether to center text vertically in the textArea component.
4193 ///
4194 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4195 ///
4196 /// .value[0].i32: whether to center text vertically. The default value is <b>false</b>.
4197 ///
4198 ///
4199 ///
4200 /// Format of the return value [`ArkUI_AttributeItem`]:
4201 ///
4202 /// .value[0].i32: whether to center text vertically.
4203 ///
4204 ///
4205 ///
4206 /// Available since API-level: 18
4207 #[cfg(feature = "api-18")]
4208 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4209 pub const NODE_TEXT_AREA_HALF_LEADING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(8025);
4210 /// Set the keyboard style of textArea
4211 ///
4212 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4213 ///
4214 /// .value[0].i32:keyboard style,the parameter type is [`ArkUI_KeyboardAppearanceType`]。
4215 ///
4216 ///
4217 ///
4218 /// Format of the return value [`ArkUI_AttributeItem`]:
4219 ///
4220 /// .value[0].i32:keyboard style,the parameter type is [`ArkUI_KeyboardAppearanceType`]。
4221 ///
4222 ///
4223 ///
4224 /// Available since API-level: 15
4225 #[cfg(feature = "api-15")]
4226 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4227 pub const NODE_TEXT_AREA_KEYBOARD_APPEARANCE: ArkUI_NodeAttributeType =
4228 ArkUI_NodeAttributeType(8026);
4229 /// Defines the button text content. This attribute can be set, reset, and obtained as required through APIs.
4230 ///
4231 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4232 ///
4233 /// .string: default text content.
4234 ///
4235 ///
4236 ///
4237 /// Format of the return value [`ArkUI_AttributeItem`]:
4238 ///
4239 /// .string: default text content.
4240 pub const NODE_BUTTON_LABEL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(9000);
4241 /// Sets the button type. This attribute can be set, reset, and obtained as required through APIs.
4242 ///
4243 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4244 ///
4245 /// .value[0].i32: button type. The parameter type is [`ArkUI_ButtonType`].
4246 /// The default value is <b>ARKUI_BUTTON_TYPE_CAPSULE</b>.
4247 ///
4248 ///
4249 ///
4250 /// Format of the return value [`ArkUI_AttributeItem`]:
4251 ///
4252 /// .value[0].i32: button type. The parameter type is [`ArkUI_ButtonType`].
4253 /// The default value is <b>ARKUI_BUTTON_TYPE_CAPSULE</b>.
4254 pub const NODE_BUTTON_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(9001);
4255 /// Defines the minimum font scale attribute, which can be set, reset, and obtained as required through APIs.
4256 ///
4257 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4258 ///
4259 /// .value[0].f32: minimum font scale, in fp.
4260 ///
4261 ///
4262 /// Format of the return value [`ArkUI_AttributeItem`]:
4263 ///
4264 /// .value[0].f32: minimum font scale, in fp.
4265 ///
4266 ///
4267 /// Available since API-level: 18
4268 #[cfg(feature = "api-18")]
4269 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4270 pub const NODE_BUTTON_MIN_FONT_SCALE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(9002);
4271 /// Defines the maximum font scale attribute, which can be set, reset, and obtained as required through APIs.
4272 ///
4273 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4274 ///
4275 /// .value[0].f32: maximum font scale, in fp.
4276 ///
4277 ///
4278 /// Format of the return value [`ArkUI_AttributeItem`]:
4279 ///
4280 /// .value[0].f32: maximum font scale, in fp.
4281 ///
4282 ///
4283 /// Available since API-level: 18
4284 #[cfg(feature = "api-18")]
4285 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4286 pub const NODE_BUTTON_MAX_FONT_SCALE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(9003);
4287 /// Defines the current value of the progress indicator.
4288 /// This attribute can be set, reset, and obtained as required through APIs.
4289 ///
4290 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4291 ///
4292 /// .value[0].f32: current value of the progress indicator.
4293 ///
4294 ///
4295 ///
4296 /// Format of the return value [`ArkUI_AttributeItem`]:
4297 ///
4298 /// .value[0].f32: current value of the progress indicator.
4299 pub const NODE_PROGRESS_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10000);
4300 /// Defines the total value of the progress indicator.
4301 /// This attribute can be set, reset, and obtained as required through APIs.
4302 ///
4303 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4304 ///
4305 /// .value[0].f32: total value of the progress indicator.
4306 ///
4307 ///
4308 ///
4309 /// Format of the return value [`ArkUI_AttributeItem`]:
4310 ///
4311 /// .value[0].f32: total value of the progress indicator.
4312 pub const NODE_PROGRESS_TOTAL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10001);
4313 /// Defines the color for the progress value on the progress indicator.
4314 /// This attribute can be set, reset, and obtained as required through APIs.
4315 ///
4316 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4317 ///
4318 /// .value[0].u32: color value, in 0xARGB format. For example, 0xFFFF0000 indicates red.
4319 ///
4320 ///
4321 ///
4322 /// Format of the return value [`ArkUI_AttributeItem`]:
4323 ///
4324 /// .value[0].u32: color value, in 0xARGB format.
4325 pub const NODE_PROGRESS_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10002);
4326 /// Defines the type of the progress indicator.
4327 /// This attribute can be set, reset, and obtained as required through APIs.
4328 ///
4329 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4330 ///
4331 /// .value[0].i32: type of the progress indicator [`ArkUI_ProgressType`].
4332 /// The default value is <b>ARKUI_PROGRESS_TYPE_LINEAR</b>.
4333 ///
4334 ///
4335 ///
4336 /// Format of the return value [`ArkUI_AttributeItem`]:
4337 ///
4338 /// .value[0].i32: type of the progress indicator [`ArkUI_ProgressType`].
4339 pub const NODE_PROGRESS_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10003);
4340 /// Sets the style of the linear progress indicator.
4341 /// This attribute can be set, reset, and obtained as required through APIs.
4342 /// If the progress indicator type is not linear, it will not take effect.
4343 ///
4344 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4345 ///
4346 /// .object: Use the [`ArkUI_ProgressLinearStyleOption`] object to set the style.
4347 ///
4348 ///
4349 ///
4350 /// Format of the return value [`ArkUI_AttributeItem`]:
4351 ///
4352 /// .object: Use the [`ArkUI_ProgressLinearStyleOption`] object to get the style.
4353 ///
4354 ///
4355 ///
4356 /// Available since API-level: 15
4357 #[cfg(feature = "api-15")]
4358 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4359 pub const NODE_PROGRESS_LINEAR_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(10004);
4360 /// Defines whether the check box is selected.
4361 /// This attribute can be set, reset, and obtained as required through APIs.
4362 ///
4363 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4364 ///
4365 /// .value[0].i32: whether the check box is selected.
4366 /// The value <b>1</b> means that the check box is selected, and <b>0</b> means the opposite.
4367 ///
4368 ///
4369 ///
4370 /// Format of the return value [`ArkUI_AttributeItem`]:
4371 ///
4372 /// .value[0].i32: The value <b>1</b> means that the check box is selected, and <b>0</b> means the opposite.
4373 pub const NODE_CHECKBOX_SELECT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11000);
4374 /// Defines the color of the check box when it is selected.
4375 /// This attribute can be set, reset, and obtained as required through APIs.
4376 ///
4377 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4378 ///
4379 /// .value[0].u32: color of the check box when it is selected, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4380 ///
4381 ///
4382 ///
4383 /// Format of the return value [`ArkUI_AttributeItem`]:
4384 ///
4385 /// .value[0].u32: color of the check box when it is selected, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4386 pub const NODE_CHECKBOX_SELECT_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11001);
4387 /// Defines the border color of the check box when it is not selected.
4388 /// This attribute can be set, reset, and obtained as required through APIs.
4389 ///
4390 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4391 ///
4392 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4393 ///
4394 ///
4395 ///
4396 /// Format of the return value [`ArkUI_AttributeItem`]:
4397 ///
4398 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4399 pub const NODE_CHECKBOX_UNSELECT_COLOR: ArkUI_NodeAttributeType =
4400 ArkUI_NodeAttributeType(11002);
4401 /// Defines the internal icon style of the check box.
4402 /// This attribute can be set, reset, and obtained as required through APIs.
4403 ///
4404 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4405 ///
4406 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4407 ///
4408 /// .value[1]?.f32: size of the internal mark, in vp. Optional.
4409 ///
4410 /// .value[2]?.f32: stroke width of the internal mark, in vp. Optional. The default value is <b>2</b>.
4411 ///
4412 ///
4413 ///
4414 /// Format of the return value [`ArkUI_AttributeItem`]:
4415 ///
4416 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
4417 ///
4418 /// .value[1].f32: size of the internal mark, in vp.
4419 ///
4420 /// .value[2].f32: stroke width of the internal mark, in vp. The default value is <b>2</b>.
4421 pub const NODE_CHECKBOX_MARK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11003);
4422 /// Defines the shape of the check box.
4423 /// This attribute can be set, reset, and obtained as required through APIs.
4424 ///
4425 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4426 ///
4427 /// .value[0].i32: component shape. The parameter type is [`ArkUI_CheckboxShape`].
4428 ///
4429 ///
4430 ///
4431 /// Format of the return value [`ArkUI_AttributeItem`]:
4432 ///
4433 /// .value[0].i32: component shape. The parameter type is [`ArkUI_CheckboxShape`].
4434 pub const NODE_CHECKBOX_SHAPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11004);
4435 /// Defines the name of the checkbox.
4436 /// This attribute can be set, reset, and obtained as required through APIs.
4437 ///
4438 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4439 ///
4440 /// .string: component name.
4441 ///
4442 ///
4443 ///
4444 /// Format of the return value [`ArkUI_AttributeItem`]:
4445 ///
4446 /// .string: component name.
4447 ///
4448 ///
4449 ///
4450 /// Available since API-level: 15
4451 #[cfg(feature = "api-15")]
4452 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4453 pub const NODE_CHECKBOX_NAME: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11005);
4454 /// Defines the name of the checkbox.
4455 /// This attribute can be set, reset, and obtained as required through APIs.
4456 ///
4457 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4458 ///
4459 /// .string: component name.
4460 ///
4461 ///
4462 ///
4463 /// Format of the return value [`ArkUI_AttributeItem`]:
4464 ///
4465 /// .string: component name.
4466 ///
4467 ///
4468 ///
4469 /// Available since API-level: 15
4470 #[cfg(feature = "api-15")]
4471 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
4472 pub const NODE_CHECKBOX_GROUP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(11006);
4473 /// Defines the ID of the <b><XComponent></b> component.
4474 /// This attribute can be set and obtained as required through APIs.
4475 ///
4476 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4477 ///
4478 /// .string: component ID.
4479 ///
4480 ///
4481 ///
4482 /// Format of the return value [`ArkUI_AttributeItem`]:
4483 ///
4484 /// .string: component ID.
4485 pub const NODE_XCOMPONENT_ID: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(12000);
4486 /// Defines the type of the <b><XComponent></b> component.
4487 /// This attribute can be set, reset, and obtained as required through APIs.
4488 ///
4489 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4490 ///
4491 /// .value[0].i32: type [`ArkUI_XComponentType`]. The default value is <b>ARKUI_XCOMPONENT_TYPE_SURFACE</b>.
4492 ///
4493 ///
4494 ///
4495 /// Format of the return value [`ArkUI_AttributeItem`]:
4496 ///
4497 /// .value[0].i32: type [`ArkUI_XComponentType`].
4498 pub const NODE_XCOMPONENT_TYPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(12001);
4499 /// Defines the width and height of the <b><XComponent></b> component.
4500 /// This attribute can be set and obtained as required through APIs.
4501 ///
4502 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4503 ///
4504 /// .value[0].u32: width, in px.
4505 ///
4506 /// .value[1].u32: height, in px.
4507 ///
4508 ///
4509 ///
4510 /// Format of the return value [`ArkUI_AttributeItem`]:
4511 ///
4512 /// .value[0].u32: width, in px.
4513 ///
4514 /// .value[1].u32: height, in px.
4515 pub const NODE_XCOMPONENT_SURFACE_SIZE: ArkUI_NodeAttributeType =
4516 ArkUI_NodeAttributeType(12002);
4517 /// Defines the rectangle information of surface created by the <b><XComponent></b> component.
4518 /// This attribute can be set and obtained as required through APIs.
4519 ///
4520 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4521 ///
4522 /// .value[0].i32: The horizontal offset of the surface relative to XComponent, in pixels.
4523 ///
4524 /// .value[1].i32: The vertical offset of the surface relative to XComponent, in pixels.
4525 ///
4526 /// .value[2].i32: The width of the surface created by XComponent, in pixels.
4527 ///
4528 /// .value[3].i32: The height of the surface created by XComponent, in pixels.
4529 ///
4530 ///
4531 ///
4532 /// Format of the return value [`ArkUI_AttributeItem`]:
4533 ///
4534 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4535 ///
4536 /// .value[0].i32: The horizontal offset of the surface relative to XComponent, in pixels.
4537 ///
4538 /// .value[1].i32: The vertical offset of the surface relative to XComponent, in pixels.
4539 ///
4540 /// .value[2].i32: The width of the surface created by XComponent, in pixels.
4541 ///
4542 /// .value[3].i32: The height of the surface created by XComponent, in pixels.
4543 ///
4544 ///
4545 /// Available since API-level: 18
4546 #[cfg(feature = "api-18")]
4547 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4548 pub const NODE_XCOMPONENT_SURFACE_RECT: ArkUI_NodeAttributeType =
4549 ArkUI_NodeAttributeType(12003);
4550 /// Defines whether to enable the AI analyzer for the <b><XComponent></b> component.
4551 /// This attribute can be set and obtained as required through APIs.
4552 ///
4553 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4554 ///
4555 /// value[0].i32: The parameter type is 1 or 0.
4556 ///
4557 ///
4558 /// Format of the return value [`ArkUI_AttributeItem`]:
4559 ///
4560 /// value[0].i32: The parameter type is 1 or 0.
4561 ///
4562 /// Available since API-level: 18
4563 #[cfg(feature = "api-18")]
4564 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4565 pub const NODE_XCOMPONENT_ENABLE_ANALYZER: ArkUI_NodeAttributeType =
4566 ArkUI_NodeAttributeType(12004);
4567 /// Defines whether to display the lunar calendar in the date picker.
4568 /// This attribute can be set, reset, and obtained as required through APIs.
4569 ///
4570 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4571 ///
4572 /// .value[0].i32: whether to display the lunar calendar in the date picker. The default value is <b>false</b>.
4573 ///
4574 ///
4575 ///
4576 /// Format of the return value [`ArkUI_AttributeItem`]:
4577 ///
4578 /// .value[0].i32: whether to display the lunar calendar in the date picker.
4579 pub const NODE_DATE_PICKER_LUNAR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13000);
4580 /// Defines the start date of the date picker.
4581 /// This attribute can be set, reset, and obtained as required through APIs.
4582 ///
4583 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4584 ///
4585 /// .string: date. The default value is <b>"1970-1-1"</b>.
4586 ///
4587 ///
4588 ///
4589 /// Format of the return value [`ArkUI_AttributeItem`]:
4590 ///
4591 /// .string: date.
4592 pub const NODE_DATE_PICKER_START: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13001);
4593 /// Defines the end date of the date picker.
4594 /// This attribute can be set, reset, and obtained as required through APIs.
4595 ///
4596 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4597 ///
4598 /// .string: date. The default value is <b>"2100-12-31"</b>.
4599 ///
4600 ///
4601 ///
4602 /// Format of the return value [`ArkUI_AttributeItem`]:
4603 ///
4604 /// .string: date.
4605 pub const NODE_DATE_PICKER_END: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13002);
4606 /// Defines the selected date of the date picker.
4607 /// This attribute can be set, reset, and obtained as required through APIs.
4608 ///
4609 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4610 ///
4611 /// .string: date. The default value is <b>"2024-01-22"</b>.
4612 ///
4613 ///
4614 ///
4615 /// Format of the return value [`ArkUI_AttributeItem`]:
4616 ///
4617 /// .string: date.
4618 pub const NODE_DATE_PICKER_SELECTED: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13003);
4619 /// Defines the font color, font size, and font weight for the top and bottom items in the date picker.
4620 /// This attribute can be set, reset, and obtained as required through APIs.
4621 ///
4622 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4623 ///
4624 /// .string: array of five parameters of the string type, separated by semicolons (;).
4625 ///
4626 /// Parameter 1: font color, in #ARGB format.
4627 ///
4628 /// Parameter 2: font size, in fp. The value is a number.
4629 ///
4630 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4631 /// .
4632 /// Parameter 4: fonts, separated by commas (,).
4633 ///
4634 /// Parameter 5: font style. Available options are ("normal", "italic").
4635 ///
4636 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4637 ///
4638 ///
4639 ///
4640 /// Format of the return value [`ArkUI_AttributeItem`]:
4641 ///
4642 /// .string: array of five parameters of the string type, separated by semicolons (;).
4643 ///
4644 /// Parameter 1: font color, in #ARGB format.
4645 ///
4646 /// Parameter 2: font size, in fp. The value is a number.
4647 ///
4648 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4649 /// .
4650 /// Parameter 4: fonts, separated by commas (,).
4651 ///
4652 /// Parameter 5: font style. Available options are ("normal", "italic").
4653 ///
4654 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4655 pub const NODE_DATE_PICKER_DISAPPEAR_TEXT_STYLE: ArkUI_NodeAttributeType =
4656 ArkUI_NodeAttributeType(13004);
4657 /// Defines the font color, font size, and font weight of all items except the top, bottom, and selected
4658 /// items in the date picker. This attribute can be set, reset, and obtained as required through APIs.
4659 ///
4660 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4661 ///
4662 /// .string: array of five parameters of the string type, separated by semicolons (;).
4663 ///
4664 /// Parameter 1: font color, in #ARGB format.
4665 ///
4666 /// Parameter 2: font size, in fp. The value is a number.
4667 ///
4668 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4669 /// .
4670 /// Parameter 4: fonts, separated by commas (,).
4671 ///
4672 /// Parameter 5: font style. Available options are ("normal", "italic").
4673 ///
4674 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4675 ///
4676 ///
4677 ///
4678 /// Format of the return value [`ArkUI_AttributeItem`]:
4679 ///
4680 /// .string: array of five parameters of the string type, separated by semicolons (;).
4681 ///
4682 /// Parameter 1: font color, in #ARGB format.
4683 ///
4684 /// Parameter 2: font size, in fp. The value is a number.
4685 ///
4686 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4687 /// .
4688 /// Parameter 4: fonts, separated by commas (,).
4689 ///
4690 /// Parameter 5: font style. Available options are ("normal", "italic").
4691 ///
4692 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4693 pub const NODE_DATE_PICKER_TEXT_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13005);
4694 /// Defines the font color, font size, and font weight of the selected item in the date picker.
4695 /// This attribute can be set, reset, and obtained as required through APIs.
4696 ///
4697 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4698 ///
4699 /// .string: array of five parameters of the string type, separated by semicolons (;).
4700 ///
4701 /// Parameter 1: font color, in #ARGB format.
4702 ///
4703 /// Parameter 2: font size, in fp. The value is a number.
4704 ///
4705 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4706 /// .
4707 /// Parameter 4: fonts, separated by commas (,).
4708 ///
4709 /// Parameter 5: font style. Available options are ("normal", "italic").
4710 ///
4711 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4712 ///
4713 ///
4714 ///
4715 /// Format of the return value [`ArkUI_AttributeItem`]:
4716 ///
4717 /// .string: array of five parameters of the string type, separated by semicolons (;).
4718 ///
4719 /// Parameter 1: font color, in #ARGB format.
4720 ///
4721 /// Parameter 2: font size, in fp. The value is a number.
4722 ///
4723 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4724 /// .
4725 /// Parameter 4: fonts, separated by commas (,).
4726 ///
4727 /// Parameter 5: font style. Available options are ("normal", "italic").
4728 ///
4729 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4730 pub const NODE_DATE_PICKER_SELECTED_TEXT_STYLE: ArkUI_NodeAttributeType =
4731 ArkUI_NodeAttributeType(13006);
4732 /// Defines the mode of the date picker.
4733 /// This attribute can be set, reset, and obtained as required through APIs.
4734 ///
4735 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4736 ///
4737 /// value[0].i32: the mode. The value is and enum of [`ArkUI_DatePickerMode`].
4738 /// .
4739 ///
4740 ///
4741 /// Format of the return value [`ArkUI_AttributeItem`]:
4742 ///
4743 /// value[0].i32: the mode. The value is and enum of [`ArkUI_DatePickerMode`].
4744 /// .
4745 ///
4746 ///
4747 /// Available since API-level: 18
4748 #[cfg(feature = "api-18")]
4749 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4750 pub const NODE_DATE_PICKER_MODE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(13007);
4751 /// Defines whether haptic feedback.
4752 /// This attribute can be set, reset, and obtained as required through APIs.
4753 ///
4754 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4755 ///
4756 /// .value[0].i32: whether to feedback. The value <b>true</b> means to feedback, and
4757 /// <b>false</b> means the opposite.
4758 ///
4759 ///
4760 ///
4761 /// Format of the return value [`ArkUI_AttributeItem`]:
4762 ///
4763 /// value[0].i32: whether to feedback.
4764 ///
4765 ///
4766 ///
4767 /// Available since API-level: 18
4768 #[cfg(feature = "api-18")]
4769 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4770 pub const NODE_DATE_PICKER_ENABLE_HAPTIC_FEEDBACK: ArkUI_NodeAttributeType =
4771 ArkUI_NodeAttributeType(13008);
4772 /// Defines the time of the selected item. in the timer picker.
4773 /// This attribute can be set, reset, and obtained as required through APIs.
4774 ///
4775 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4776 ///
4777 /// .string: time. The default value is the current system time.
4778 ///
4779 ///
4780 ///
4781 /// Format of the return value [`ArkUI_AttributeItem`]:
4782 ///
4783 /// .string: time.
4784 pub const NODE_TIME_PICKER_SELECTED: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(14000);
4785 /// Defines whether the display time is in 24-hour format.
4786 /// This attribute can be set, reset, and obtained as required through APIs.
4787 ///
4788 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4789 ///
4790 /// .value[0].i32: whether the display time is in 24-hour format. The default value is <b>false</b>.
4791 ///
4792 ///
4793 ///
4794 /// Format of the return value [`ArkUI_AttributeItem`]:
4795 ///
4796 /// .value[0].i32: whether the display time is in 24-hour format.
4797 pub const NODE_TIME_PICKER_USE_MILITARY_TIME: ArkUI_NodeAttributeType =
4798 ArkUI_NodeAttributeType(14001);
4799 /// Defines the font color, font size, and font weight for the top and bottom items in the time picker.
4800 /// This attribute can be set, reset, and obtained as required through APIs.
4801 ///
4802 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4803 ///
4804 /// .string: array of five parameters of the string type, separated by semicolons (;).
4805 ///
4806 /// Parameter 1: font color, in #ARGB format.
4807 ///
4808 /// Parameter 2: font size, in fp. The value is a number.
4809 ///
4810 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4811 /// .
4812 /// Parameter 4: fonts, separated by commas (,).
4813 ///
4814 /// Parameter 5: font style. Available options are ("normal", "italic").
4815 ///
4816 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4817 ///
4818 ///
4819 ///
4820 /// Format of the return value [`ArkUI_AttributeItem`]:
4821 ///
4822 /// .string: array of five parameters of the string type, separated by semicolons (;).
4823 ///
4824 /// Parameter 1: font color, in #ARGB format.
4825 ///
4826 /// Parameter 2: font size, in fp. The value is a number.
4827 ///
4828 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4829 /// .
4830 /// Parameter 4: fonts, separated by commas (,).
4831 ///
4832 /// Parameter 5: font style. Available options are ("normal", "italic").
4833 ///
4834 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4835 pub const NODE_TIME_PICKER_DISAPPEAR_TEXT_STYLE: ArkUI_NodeAttributeType =
4836 ArkUI_NodeAttributeType(14002);
4837 /// Defines the font color, font size, and font weight of all items except the top, bottom, and selected items
4838 /// in the time picker. This attribute can be set, reset, and obtained as required through APIs.
4839 ///
4840 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4841 ///
4842 /// .string: array of five parameters of the string type, separated by semicolons (;).
4843 ///
4844 /// Parameter 1: font color, in #ARGB format.
4845 ///
4846 /// Parameter 2: font size, in fp. The value is a number.
4847 ///
4848 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4849 /// .
4850 /// Parameter 4: fonts, separated by commas (,).
4851 ///
4852 /// Parameter 5: font style. Available options are ("normal", "italic").
4853 ///
4854 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4855 ///
4856 ///
4857 ///
4858 /// Format of the return value [`ArkUI_AttributeItem`]:
4859 ///
4860 /// .string: array of five parameters of the string type, separated by semicolons (;).
4861 ///
4862 /// Parameter 1: font color, in #ARGB format.
4863 ///
4864 /// Parameter 2: font size, in fp. The value is a number.
4865 ///
4866 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4867 /// .
4868 /// Parameter 4: fonts, separated by commas (,).
4869 ///
4870 /// Parameter 5: font style. Available options are ("normal", "italic").
4871 ///
4872 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4873 pub const NODE_TIME_PICKER_TEXT_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(14003);
4874 /// Defines the font color, font size, and font weight of the selected item in the time picker.
4875 /// This attribute can be set, reset, and obtained as required through APIs.
4876 ///
4877 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4878 ///
4879 /// .string: array of five parameters of the string type, separated by semicolons (;).
4880 ///
4881 /// Parameter 1: font color, in #ARGB format.
4882 ///
4883 /// Parameter 2: font size, in fp. The value is a number.
4884 ///
4885 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4886 /// .
4887 /// Parameter 4: fonts, separated by commas (,).
4888 ///
4889 /// Parameter 5: font style. Available options are ("normal", "italic").
4890 ///
4891 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4892 ///
4893 ///
4894 ///
4895 /// Format of the return value [`ArkUI_AttributeItem`]:
4896 ///
4897 /// .string: array of five parameters of the string type, separated by semicolons (;).
4898 ///
4899 /// Parameter 1: font color, in #ARGB format.
4900 ///
4901 /// Parameter 2: font size, in fp. The value is a number.
4902 ///
4903 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
4904 /// .
4905 /// Parameter 4: fonts, separated by commas (,).
4906 ///
4907 /// Parameter 5: font style. Available options are ("normal", "italic").
4908 ///
4909 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
4910 pub const NODE_TIME_PICKER_SELECTED_TEXT_STYLE: ArkUI_NodeAttributeType =
4911 ArkUI_NodeAttributeType(14004);
4912 /// Defines the start time of the time picker.
4913 /// This attribute can be set, reset, and obtained as required through APIs.
4914 ///
4915 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4916 ///
4917 /// .string: time. The default value is <b>"00:00:00"</b>.
4918 ///
4919 ///
4920 ///
4921 /// Format of the return value [`ArkUI_AttributeItem`]:
4922 ///
4923 /// .string: time. The default value is <b>"00:00:00"</b>.
4924 ///
4925 ///
4926 ///
4927 /// Available since API-level: 18
4928 #[cfg(feature = "api-18")]
4929 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4930 pub const NODE_TIME_PICKER_START: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(14005);
4931 /// Defines the end time of the time picker.
4932 /// This attribute can be set, reset, and obtained as required through APIs.
4933 ///
4934 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4935 ///
4936 /// .string: time. The default value is <b>"23:59:59"</b>.
4937 ///
4938 ///
4939 ///
4940 /// Format of the return value [`ArkUI_AttributeItem`]:
4941 ///
4942 /// .string: time. The default value is <b>"23:59:59"</b>.
4943 ///
4944 ///
4945 ///
4946 /// Available since API-level: 18
4947 #[cfg(feature = "api-18")]
4948 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4949 pub const NODE_TIME_PICKER_END: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(14006);
4950 /// Defines whether the AM/PM option is cascaded with the time in 12-hour mode.
4951 /// This attribute can be set, reset, and obtained as required through APIs.
4952 ///
4953 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4954 ///
4955 /// .value[0].i32: whether to enable cascade. The default value is <b>false</b>.
4956 ///
4957 ///
4958 ///
4959 /// Format of the return value [`ArkUI_AttributeItem`]:
4960 ///
4961 /// .value[0].i32: whether to enable cascade.
4962 ///
4963 ///
4964 ///
4965 /// Available since API-level: 18
4966 #[cfg(feature = "api-18")]
4967 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
4968 pub const NODE_TIME_PICKER_ENABLE_CASCADE: ArkUI_NodeAttributeType =
4969 ArkUI_NodeAttributeType(14007);
4970 /// Defines the data selection range of the text picker.
4971 /// This attribute can be set, reset, and obtained as required through APIs.
4972 ///
4973 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
4974 ///
4975 /// .value[0].i32: type of the text picker [`ArkUI_TextPickerRangeType`].
4976 /// The default value is <b>ARKUI_TEXTPICKER_RANGETYPE_SINGLE</b>.
4977 ///
4978 /// ?.string: string input, whose format varies by picker type.
4979 ///
4980 /// 1: single-column picker. The input format is a group of strings separated by semicolons (;).
4981 ///
4982 /// 2: multi-column picker. Multiple pairs of plain text strings are supported. The pairs are separated by
4983 /// semicolons (;), and strings within each pair are separated by commas (,).
4984 ///
4985 /// ?.object: Object input, whose format varies by picker type.
4986 ///
4987 /// 1: single-column picker with image support. The input structure is [`ARKUI_TextPickerRangeContent`].
4988 ///
4989 /// 2: multi-column interconnected picker. The input structure is [`ARKUI_TextPickerCascadeRangeContent`].
4990 ///
4991 ///
4992 ///
4993 /// Format of the return value [`ArkUI_AttributeItem`]:
4994 ///
4995 /// .value[0].i32: type of the text picker [`ArkUI_TextPickerRangeType`].
4996 ///
4997 /// ?.string: string output, whose format varies by picker type.
4998 ///
4999 /// 1: single-column picker. The output format is a group of strings separated by semicolons (;).
5000 ///
5001 /// 2: multi-column picker. Multiple pairs of plain text strings are supported. The pairs are separated by
5002 /// semicolons (;), and strings within each pair are separated by commas (,).
5003 ///
5004 /// ?.string: Object output, whose format varies by picker type.
5005 ///
5006 /// 1: single-column picker with image support. The output structure is [`ARKUI_TextPickerRangeContent`].
5007 ///
5008 /// 2: multi-column interconnected picker. The output structure is [`ARKUI_TextPickerCascadeRangeContent`].
5009 pub const NODE_TEXT_PICKER_OPTION_RANGE: ArkUI_NodeAttributeType =
5010 ArkUI_NodeAttributeType(15000);
5011 /// Defines the index of the default selected item in the data selection range of the text picker.
5012 /// This attribute can be set, reset, and obtained as required through APIs.
5013 ///
5014 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5015 ///
5016 /// .value[0].u32: index. If there are multiple index values, add them one by one.
5017 ///
5018 ///
5019 ///
5020 /// Format of the return value [`ArkUI_AttributeItem`]:
5021 ///
5022 /// .value[0].u32: index. If there are multiple index values, add them one by one.
5023 pub const NODE_TEXT_PICKER_OPTION_SELECTED: ArkUI_NodeAttributeType =
5024 ArkUI_NodeAttributeType(15001);
5025 /// Defines the value of the default selected item in the text picker.
5026 /// This attribute can be set, reset, and obtained as required through APIs.
5027 ///
5028 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5029 ///
5030 /// .string: value of the selected item. If there are multiple values, add them one by one and
5031 /// separate them with semicolons (;).
5032 ///
5033 ///
5034 ///
5035 /// Format of the return value [`ArkUI_AttributeItem`]:
5036 ///
5037 /// .string: value of the selected item. If there are multiple values, add them one by one and
5038 /// separate them with semicolons (;).
5039 pub const NODE_TEXT_PICKER_OPTION_VALUE: ArkUI_NodeAttributeType =
5040 ArkUI_NodeAttributeType(15002);
5041 /// Defines the font color, font size, and font weight for the top and bottom items in the text picker.
5042 /// This attribute can be set, reset, and obtained as required through APIs.
5043 ///
5044 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5045 ///
5046 /// .string: array of five parameters of the string type, separated by semicolons (;).
5047 ///
5048 /// Parameter 1: font color, in #ARGB format.
5049 ///
5050 /// Parameter 2: font size, in fp. The value is a number.
5051 ///
5052 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5053 /// .
5054 /// Parameter 4: fonts, separated by commas (,).
5055 ///
5056 /// Parameter 5: font style. Available options are ("normal", "italic").
5057 ///
5058 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5059 ///
5060 ///
5061 ///
5062 /// Format of the return value [`ArkUI_AttributeItem`]:
5063 ///
5064 /// .string: array of five parameters of the string type, separated by semicolons (;).
5065 ///
5066 /// Parameter 1: font color, in #ARGB format.
5067 ///
5068 /// Parameter 2: font size, in fp. The value is a number.
5069 ///
5070 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5071 /// .
5072 /// Parameter 4: fonts, separated by commas (,).
5073 ///
5074 /// Parameter 5: font style. Available options are ("normal", "italic").
5075 ///
5076 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5077 pub const NODE_TEXT_PICKER_DISAPPEAR_TEXT_STYLE: ArkUI_NodeAttributeType =
5078 ArkUI_NodeAttributeType(15003);
5079 /// Defines the font color, font size, and font weight for all items except the top, bottom, and selected
5080 /// items in the text picker. This attribute can be set, reset, and obtained as required through APIs.
5081 ///
5082 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5083 ///
5084 /// .string: array of five parameters of the string type, separated by semicolons (;).
5085 ///
5086 /// Parameter 1: font color, in #ARGB format.
5087 ///
5088 /// Parameter 2: font size, in fp. The value is a number.
5089 ///
5090 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5091 /// .
5092 /// Parameter 4: fonts, separated by commas (,).
5093 ///
5094 /// Parameter 5: font style. Available options are ("normal", "italic").
5095 ///
5096 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5097 ///
5098 ///
5099 ///
5100 /// Format of the return value [`ArkUI_AttributeItem`]:
5101 ///
5102 /// .string: array of five parameters of the string type, separated by semicolons (;).
5103 ///
5104 /// Parameter 1: font color, in #ARGB format.
5105 ///
5106 /// Parameter 2: font size, in fp. The value is a number.
5107 ///
5108 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5109 /// .
5110 /// Parameter 4: fonts, separated by commas (,).
5111 ///
5112 /// Parameter 5: font style. Available options are ("normal", "italic").
5113 ///
5114 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5115 pub const NODE_TEXT_PICKER_TEXT_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(15004);
5116 /// Defines the font color, font size, and font weight for the selected item in the text picker.
5117 /// This attribute can be set, reset, and obtained as required through APIs.
5118 ///
5119 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5120 ///
5121 /// .string: array of five parameters of the string type, separated by semicolons (;).
5122 ///
5123 /// Parameter 1: font color, in #ARGB format.
5124 ///
5125 /// Parameter 2: font size, in fp. The value is a number.
5126 ///
5127 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5128 /// .
5129 /// Parameter 4: fonts, separated by commas (,).
5130 ///
5131 /// Parameter 5: font style. Available options are ("normal", "italic").
5132 ///
5133 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5134 ///
5135 ///
5136 ///
5137 /// Format of the return value [`ArkUI_AttributeItem`]:
5138 ///
5139 /// .string: array of five parameters of the string type, separated by semicolons (;).
5140 ///
5141 /// Parameter 1: font color, in #ARGB format.
5142 ///
5143 /// Parameter 2: font size, in fp. The value is a number.
5144 ///
5145 /// Parameter 3: font weight. Available options are ("bold", "normal", "bolder", "lighter", "medium", "regular").
5146 /// .
5147 /// Parameter 4: fonts, separated by commas (,).
5148 ///
5149 /// Parameter 5: font style. Available options are ("normal", "italic").
5150 ///
5151 /// Example: "#ff182431;14;normal;Arial,HarmonyOS Sans;normal".
5152 pub const NODE_TEXT_PICKER_SELECTED_TEXT_STYLE: ArkUI_NodeAttributeType =
5153 ArkUI_NodeAttributeType(15005);
5154 /// Defines the index of the default selected item in the data selection range of the text picker.
5155 /// This attribute can be set, reset, and obtained as required through APIs.
5156 ///
5157 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5158 ///
5159 /// .value[0...].i32: index of the default item in the data selection range.
5160 pub const NODE_TEXT_PICKER_SELECTED_INDEX: ArkUI_NodeAttributeType =
5161 ArkUI_NodeAttributeType(15006);
5162 /// Defines whether to support scroll looping for the text picker.
5163 /// This attribute can be set, reset, and obtained as required through APIs.
5164 ///
5165 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5166 ///
5167 /// .value[0].i32: whether to support scroll looping. The value <b>true</b> means to support scroll looping, and
5168 /// <b>false</b> means the opposite.
5169 ///
5170 ///
5171 ///
5172 ///
5173 /// Format of the return value [`ArkUI_AttributeItem`]:
5174 ///
5175 /// value[0].i32: The value <b>1</b> means to support scroll looping, and <b>0</b> means the opposite.
5176 pub const NODE_TEXT_PICKER_CAN_LOOP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(15007);
5177 /// Defines the height of each item in the picker. This attribute can be set, reset, and obtained as required
5178 /// through APIs.
5179 ///
5180 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5181 ///
5182 /// .value[0].f32: item height, in vp.
5183 ///
5184 ///
5185 ///
5186 /// Format of the return value [`ArkUI_AttributeItem`]:
5187 ///
5188 /// value[0].f32: item height, in vp.
5189 pub const NODE_TEXT_PICKER_DEFAULT_PICKER_ITEM_HEIGHT: ArkUI_NodeAttributeType =
5190 ArkUI_NodeAttributeType(15008);
5191 /// Defines whether haptic feedback.
5192 /// This attribute can be set, reset, and obtained as required through APIs.
5193 ///
5194 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5195 ///
5196 /// .value[0].i32: whether to feedback. The value <b>true</b> means to feedback, and
5197 /// <b>false</b> means the opposite.
5198 ///
5199 ///
5200 ///
5201 /// Format of the return value [`ArkUI_AttributeItem`]:
5202 ///
5203 /// value[0].i32: whether to feedback.
5204 ///
5205 ///
5206 ///
5207 /// Available since API-level: 18
5208 #[cfg(feature = "api-18")]
5209 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
5210 pub const NODE_TEXT_PICKER_ENABLE_HAPTIC_FEEDBACK: ArkUI_NodeAttributeType =
5211 ArkUI_NodeAttributeType(15010);
5212 /// Defines the style of the background in the selected state of the calendar picker.
5213 /// This attribute can be set, reset, and obtained as required through APIs.
5214 ///
5215 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5216 ///
5217 /// .value[0].f32: style of the background in the selected state of the calendar picker.
5218 /// The value range is [0, +∞). If the value is <b>0</b>, the background is a rectangle with square corners.
5219 /// If the value is in the 0–16 range, the background is a rectangle with rounded corners. If the value is equal to
5220 /// or greater than 16, the background is a circle.
5221 ///
5222 ///
5223 ///
5224 /// Format of the return value [`ArkUI_AttributeItem`]:
5225 ///
5226 /// .value[0].f32: style of the background in the selected state of the calendar picker. The value range is [0, +∞).
5227 /// If the value is <b>0</b>, the background is a rectangle with square corners.
5228 /// If the value is in the 0–16 range, the background is a rectangle with rounded corners. If the value is equal to or
5229 /// greater than 16, the background is a circle.
5230 pub const NODE_CALENDAR_PICKER_HINT_RADIUS: ArkUI_NodeAttributeType =
5231 ArkUI_NodeAttributeType(16000);
5232 /// Defines the date of the selected item in the calendar picker.
5233 /// This attribute can be set, reset, and obtained as required through APIs.
5234 ///
5235 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5236 ///
5237 /// .value[0].u32: year of the selected date.
5238 ///
5239 /// .value[1].u32: month of the selected date.
5240 ///
5241 /// .value[2].u32: day of the selected date.
5242 ///
5243 ///
5244 ///
5245 /// Format of the return value [`ArkUI_AttributeItem`]:
5246 ///
5247 /// .value[0].u32: year of the selected date.
5248 ///
5249 /// .value[1].u32: month of the selected date.
5250 ///
5251 /// .value[2].u32: day of the selected date.
5252 pub const NODE_CALENDAR_PICKER_SELECTED_DATE: ArkUI_NodeAttributeType =
5253 ArkUI_NodeAttributeType(16001);
5254 /// Defines how the calendar picker is aligned with the entry component.
5255 /// This attribute can be set, reset, and obtained as required through APIs.
5256 ///
5257 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5258 ///
5259 /// .value[0].i32: alignment mode. The parameter type is [`ArkUI_CalendarAlignment`].
5260 ///
5261 /// .value[1]?.f32: offset of the picker relative to the entry component along the x-axis after alignment based on
5262 /// the specified alignment mode.
5263 ///
5264 /// .value[2]?.f32: offset of the picker relative to the entry component along the y-axis after alignment based on
5265 /// the specified alignment mode.
5266 ///
5267 ///
5268 ///
5269 /// Format of the return value [`ArkUI_AttributeItem`]:
5270 ///
5271 /// .value[0].i32: alignment mode. The parameter type is [`ArkUI_CalendarAlignment`].
5272 ///
5273 /// .value[1]?.f32: offset of the picker relative to the entry component along the x-axis after alignment based on
5274 /// the specified alignment mode.
5275 ///
5276 /// .value[2]?.f32: offset of the picker relative to the entry component along the y-axis after alignment based on
5277 /// the specified alignment mode.
5278 pub const NODE_CALENDAR_PICKER_EDGE_ALIGNMENT: ArkUI_NodeAttributeType =
5279 ArkUI_NodeAttributeType(16002);
5280 /// Defines the font color, font size, and font weight in the entry area of the calendar picker.
5281 ///
5282 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5283 ///
5284 /// .value[0]?.u32: font color of the entry area.
5285 ///
5286 /// .value[1]?.f32: font size of the entry area, in fp.
5287 ///
5288 /// .value[2]?.i32: font weight of the entry area. The parameter type is [`ArkUI_FontWeight`].
5289 ///
5290 ///
5291 ///
5292 /// Format of the return value [`ArkUI_AttributeItem`]:
5293 ///
5294 /// .value[0].u32: font color of the entry area.
5295 ///
5296 /// .value[1].f32: font size of the entry area, in fp.
5297 ///
5298 /// .value[2].i32: font weight of the entry area. The parameter type is [`ArkUI_FontWeight`].
5299 pub const NODE_CALENDAR_PICKER_TEXT_STYLE: ArkUI_NodeAttributeType =
5300 ArkUI_NodeAttributeType(16003);
5301 /// Defines the start date of the calendar picker.
5302 /// This attribute can be set, reset, and obtained as required through APIs.
5303 ///
5304 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5305 ///
5306 /// .string: date. The value like <b>"1970-1-1"</b>.
5307 ///
5308 ///
5309 ///
5310 /// Format of the return value [`ArkUI_AttributeItem`]:
5311 ///
5312 /// .string: date.
5313 ///
5314 ///
5315 ///
5316 /// Available since API-level: 18
5317 #[cfg(feature = "api-18")]
5318 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
5319 pub const NODE_CALENDAR_PICKER_START: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(16004);
5320 /// Defines the end date of the calendar picker.
5321 /// This attribute can be set, reset, and obtained as required through APIs.
5322 ///
5323 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5324 ///
5325 /// .string: date. The value like <b>"2100-12-31"</b>.
5326 ///
5327 ///
5328 ///
5329 /// Format of the return value [`ArkUI_AttributeItem`]:
5330 ///
5331 /// .string: date.
5332 ///
5333 ///
5334 ///
5335 /// Available since API-level: 18
5336 #[cfg(feature = "api-18")]
5337 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
5338 pub const NODE_CALENDAR_PICKER_END: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(16005);
5339 /// Defines the color of the slider. This attribute can be set, reset, and obtained as required through APIs.
5340 ///
5341 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5342 ///
5343 /// .value[0].u32: color of the slider, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5344 ///
5345 ///
5346 /// Format of the return value [`ArkUI_AttributeItem`]:
5347 ///
5348 /// .value[0].u32: color of the slider, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5349 pub const NODE_SLIDER_BLOCK_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17000);
5350 /// Defines the background color of the slider. This attribute can be set, reset, and obtained as required
5351 /// through APIs.
5352 ///
5353 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5354 ///
5355 /// .value[0].u32: background color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5356 ///
5357 ///
5358 ///
5359 /// Format of the return value [`ArkUI_AttributeItem`]:
5360 ///
5361 /// .value[0].u32: background color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5362 pub const NODE_SLIDER_TRACK_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17001);
5363 /// Defines the color of the selected part of the slider track. This attribute can be set, reset, and obtained
5364 /// as required through APIs.
5365 ///
5366 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5367 ///
5368 /// .value[0].u32: color of the selected part of the slider track, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5369 ///
5370 ///
5371 ///
5372 /// Format of the return value [`ArkUI_AttributeItem`]:
5373 ///
5374 /// .value[0].u32: color of the selected part of the slider track, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5375 pub const NODE_SLIDER_SELECTED_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17002);
5376 /// Sets whether to display the stepping value. This attribute can be set, reset, and obtained as required
5377 /// through APIs.
5378 ///
5379 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5380 ///
5381 /// .value[0].i32: whether to display the stepping value. The value <b>1</b> means to display the stepping value,
5382 /// and <b>0</b> (default value) means the opposite.
5383 ///
5384 ///
5385 ///
5386 /// Format of the return value [`ArkUI_AttributeItem`]:
5387 ///
5388 /// .value[0].i32: whether to display the stepping value. The value <b>1</b> means to display the stepping value,
5389 /// and <b>0</b> (default value) means the opposite.
5390 pub const NODE_SLIDER_SHOW_STEPS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17003);
5391 /// Defines the slider shape, which can be set, reset, and obtained as required through APIs.
5392 ///
5393 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5394 ///
5395 /// .value[0].i32: shape. The parameter type is [`ArkUI_SliderBlockStyle`].
5396 ///
5397 /// .string?: depending on the shape. Optional.
5398 ///
5399 /// ARKUI_SLIDER_BLOCK_STYLE_IMAGE: image resource of the slider. Example: /pages/common/icon.png.
5400 ///
5401 /// ARKUI_SLIDER_BLOCK_STYLE_SHAPE: custom shape of the slider.
5402 ///
5403 /// There are five types:
5404 ///
5405 /// 1. Rectangle:
5406 ///
5407 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5408 /// The value is <b>ARKUI_SHAPE_TYPE_RECTANGLE</b> for the rectangle shape.
5409 ///
5410 /// .value[2].f32: width of the rectangle.
5411 ///
5412 /// .value[3].f32: height of the rectangle.
5413 ///
5414 /// .value[4].f32: width of the rounded corner of the rectangle.
5415 ///
5416 /// .value[5].f32: height of the rounded corner of the rectangle.
5417 ///
5418 /// 2. Circle:
5419 ///
5420 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5421 /// The value is <b>ARKUI_SHAPE_TYPE_CIRCLE</b> for the circle shape.
5422 ///
5423 /// .value[2].f32: width of the circle.
5424 ///
5425 /// .value[3].f32: height of the circle.
5426 ///
5427 /// 3.Ellipse:
5428 ///
5429 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5430 /// The value is <b>ARKUI_SHAPE_TYPE_ELLIPSE</b> for the ellipse shape.
5431 ///
5432 /// .value[2].f32: width of the ellipse.
5433 ///
5434 /// .value[3].f32: height of the ellipse;
5435 ///
5436 /// 4. Path:
5437 ///
5438 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5439 /// The value is <b>ARKUI_SHAPE_TYPE_PATH</b> for the path shape.
5440 ///
5441 /// .value[2].f32: width of the path.
5442 ///
5443 /// .value[3].f32: height of the path.
5444 ///
5445 /// .string: command for drawing the path.
5446 ///
5447 ///
5448 ///
5449 /// Format of the return value [`ArkUI_AttributeItem`]:
5450 ///
5451 /// .value[0].i32: shape. The parameter type is [`ArkUI_SliderBlockStyle`].
5452 ///
5453 /// .string?: depending on the shape. Optional.
5454 ///
5455 /// ARKUI_SLIDER_BLOCK_STYLE_IMAGE: image resource of the slider. Example: /pages/common/icon.png.
5456 ///
5457 /// ARKUI_SLIDER_BLOCK_STYLE_SHAPE: custom shape of the slider.
5458 ///
5459 /// There are five types:
5460 ///
5461 /// 1. Rectangle:
5462 ///
5463 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5464 /// The value is <b>ARKUI_SHAPE_TYPE_RECTANGLE</b> for the rectangle shape.
5465 ///
5466 /// .value[2].f32: width of the rectangle.
5467 ///
5468 /// .value[3].f32: height of the rectangle.
5469 ///
5470 /// .value[4].f32: width of the rounded corner of the rectangle.
5471 ///
5472 /// .value[5].f32: height of the rounded corner of the rectangle.
5473 ///
5474 /// 2. Circle:
5475 ///
5476 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5477 /// The value is <b>ARKUI_SHAPE_TYPE_CIRCLE</b> for the circle shape.
5478 ///
5479 /// .value[2].f32: width of the circle.
5480 ///
5481 /// .value[3].f32: height of the circle.
5482 ///
5483 /// 3.Ellipse:
5484 ///
5485 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5486 /// The value is <b>ARKUI_SHAPE_TYPE_ELLIPSE</b> for the ellipse shape.
5487 ///
5488 /// .value[2].f32: width of the ellipse.
5489 ///
5490 /// .value[3].f32: height of the ellipse;
5491 ///
5492 /// 4. Path:
5493 ///
5494 /// .value[1].i32: type of shape. The parameter type is [`ArkUI_ShapeType`].
5495 /// The value is <b>ARKUI_SHAPE_TYPE_PATH</b> for the path shape.
5496 ///
5497 /// .value[2].f32: width of the path.
5498 ///
5499 /// .value[3].f32: height of the path.
5500 ///
5501 /// .string: command for drawing the path.
5502 pub const NODE_SLIDER_BLOCK_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17004);
5503 /// Defines the current value of the slider. This attribute can be set, reset, and obtained as required
5504 /// through APIs.
5505 ///
5506 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5507 ///
5508 /// .value[0].f32: current value.
5509 ///
5510 ///
5511 ///
5512 /// Format of the return value [`ArkUI_AttributeItem`]:
5513 ///
5514 /// .value[0].f32: current value.
5515 pub const NODE_SLIDER_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17005);
5516 /// Defines the minimum value of the slider. This attribute can be set, reset, and obtained as required
5517 /// through APIs.
5518 ///
5519 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5520 ///
5521 /// .value[0].f32: minimum value.
5522 ///
5523 ///
5524 ///
5525 /// Format of the return value [`ArkUI_AttributeItem`]:
5526 ///
5527 /// .value[0].f32: minimum value.
5528 pub const NODE_SLIDER_MIN_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17006);
5529 /// Defines the maximum value of the slider. This attribute can be set, reset, and obtained as required
5530 /// through APIs.
5531 ///
5532 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5533 ///
5534 /// .value[0].f32: maximum value.
5535 ///
5536 ///
5537 ///
5538 /// Format of the return value [`ArkUI_AttributeItem`]:
5539 ///
5540 /// .value[0].f32: maximum value.
5541 pub const NODE_SLIDER_MAX_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17007);
5542 /// Defines the step of the slider. This attribute can be set, reset, and obtained as required through APIs.
5543 ///
5544 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5545 ///
5546 /// .value[0].f32: step. The value range is [0.01, 100].
5547 ///
5548 ///
5549 ///
5550 /// Format of the return value [`ArkUI_AttributeItem`]:
5551 ///
5552 /// .value[0].f32: step. The value range is [0.01, 100].
5553 pub const NODE_SLIDER_STEP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17008);
5554 /// Defines whether the slider moves horizontally or vertically. This attribute can be set, reset, and
5555 /// obtained as required through APIs.
5556 ///
5557 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5558 ///
5559 /// .value[0].i32: whether the slider moves horizontally or vertically.
5560 /// The parameter type is [`ArkUI_SliderDirection`].
5561 ///
5562 ///
5563 ///
5564 /// Format of the return value [`ArkUI_AttributeItem`]:
5565 ///
5566 /// .value[0].i32: whether the slider moves horizontally or vertically.
5567 pub const NODE_SLIDER_DIRECTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17009);
5568 /// Defines whether the slider values are reversed. This attribute can be set, reset, and obtained as required
5569 /// through APIs.
5570 ///
5571 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5572 ///
5573 /// .value[0].i32: whether the slider values are reversed. The value <b>1</b> means that the slider values are
5574 /// reversed, and <b>0</b> means the opposite.
5575 ///
5576 ///
5577 ///
5578 /// Format of the return value [`ArkUI_AttributeItem`]:
5579 ///
5580 /// .value[0].i32: whether the slider values are reversed. The value <b>1</b> means that the slider values are
5581 /// reversed, and <b>0</b> means the opposite.
5582 pub const NODE_SLIDER_REVERSE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17010);
5583 /// Defines the style of the slider thumb and track. This attribute can be set, reset, and obtained
5584 /// as required through APIs.
5585 ///
5586 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5587 ///
5588 /// .value[0].i32: style of the slider thumb and track. The parameter type is [`ArkUI_SliderStyle`].
5589 ///
5590 ///
5591 ///
5592 /// Format of the return value [`ArkUI_AttributeItem`]:
5593 ///
5594 /// .value[0].i32: style of the slider thumb and track. The parameter type is [`ArkUI_SliderStyle`].
5595 pub const NODE_SLIDER_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17011);
5596 /// Sets the track thickness of the slider.
5597 /// This attribute can be set, reset, and obtained as required through APIs.
5598 ///
5599 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5600 ///
5601 /// .value[0].f32: track thickness of the slider, in vp. The default value is 4.0 vp when <b>NODE_SLIDER_STYLE</b>
5602 /// is set to <b>ARKUI_SLIDER_STYLE_OUT_SET</b> and 20.0 vp when <b>NODE_SLIDER_STYLE</b> is set to
5603 /// <b>ARKUI_SLIDER_STYLE_IN_SET</b>.
5604 ///
5605 ///
5606 ///
5607 /// Format of the return value [`ArkUI_AttributeItem`]:
5608 ///
5609 /// .value[0].f32: track thickness of the slider, in vp.
5610 pub const NODE_SLIDER_TRACK_THICKNESS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(17012);
5611 /// Defines whether haptic feedback.
5612 /// This attribute can be set, reset, and obtained as required through APIs.
5613 ///
5614 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5615 ///
5616 /// .value[0].i32: whether to feedback. The value <b>true</b> means to feedback, and
5617 /// <b>false</b> means the opposite.
5618 ///
5619 ///
5620 ///
5621 /// Format of the return value [`ArkUI_AttributeItem`]:
5622 ///
5623 /// value[0].i32: whether to feedback.
5624 ///
5625 /// When enabling haptic feedback, you need to add "ohos.permission.VIBRATE" in the
5626 /// requestPermissions field of the module.json5 file to enable vibration permission.
5627 ///
5628 ///
5629 ///
5630 /// Available since API-level: 18
5631 #[cfg(feature = "api-18")]
5632 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
5633 pub const NODE_SLIDER_ENABLE_HAPTIC_FEEDBACK: ArkUI_NodeAttributeType =
5634 ArkUI_NodeAttributeType(17013);
5635 /// Set the selection status of an option button. Attribute setting,
5636 /// attribute resetting, and attribute obtaining are supported.
5637 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5638 ///
5639 /// .value[0].i32: check status of an option button. The default value is false.
5640 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5641 ///
5642 /// .value[0].i32: selection status of an option button.
5643 pub const NODE_RADIO_CHECKED: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(18000);
5644 /// Set the styles of the selected and deselected states of the option button.
5645 /// The attribute setting, attribute resetting, and attribute obtaining are supported.
5646 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5647 ///
5648 /// .value[0]?. u32: color of the mother board in enabled state.
5649 ///
5650 /// The type is 0xARGB, and the default value is 0xFF007DFF.
5651 ///
5652 /// .value[1]?. u32: stroke color in the close state. The type is 0xARGB,
5653 ///
5654 /// and the default value is 0xFF182431.
5655 ///
5656 /// .value[2]?. u32: color of the internal round pie in the enabled state.
5657 ///
5658 /// The type is 0xARGB, and the default value is 0xFFFFFFFF.
5659 ///
5660 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5661 ///
5662 /// .value[0]. u32: color of the mother board in enabled state.
5663 ///
5664 /// The type is 0xARGB, and the default value is 0xFF007DFF.
5665 ///
5666 /// .value[1]. u32: stroke color in the close state. The type is 0xARGB,
5667 ///
5668 /// and the default value is 0xFF182431.
5669 ///
5670 /// .value[2]. u32: color of the internal round pie in the enabled state.
5671 ///
5672 /// The type is 0xARGB, and the default value is 0xFFFFFFF.
5673 pub const NODE_RADIO_STYLE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(18001);
5674 /// Sets the value of the current radio.
5675 /// This attribute can be set, reset, and obtained as required through APIs.
5676 ///
5677 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5678 ///
5679 /// .string: radio value.
5680 ///
5681 ///
5682 ///
5683 /// Format of the return value [`ArkUI_AttributeItem`]:
5684 ///
5685 /// .string: radio value.
5686 pub const NODE_RADIO_VALUE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(18002);
5687 /// Set the group name of the current Radio group, only one radio of the same group can be selected.
5688 /// This attribute can be set, reset, and obtained as required through APIs.
5689 ///
5690 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5691 ///
5692 /// .string: name of the group to which the current option box belongs.
5693 ///
5694 ///
5695 ///
5696 /// Format of the return value [`ArkUI_AttributeItem`]:
5697 ///
5698 /// .string: name of the group to which the current option box belongs.
5699 pub const NODE_RADIO_GROUP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(18003);
5700 /// Set the image frames for the image animator. Dynamic updates is not supported.
5701 /// This attribute can be set, reset, and obtained as required through APIs.
5702 ///
5703 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5704 ///
5705 /// .size: number of the images.
5706 ///
5707 /// .object: array of the images, the type is [`ArkUI_ImageAnimatorFrameInfo`] array.
5708 ///
5709 ///
5710 ///
5711 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5712 ///
5713 /// .size: number of the images.
5714 ///
5715 /// .object: array of the images, the type is [`ArkUI_ImageAnimatorFrameInfo`] array.
5716 pub const NODE_IMAGE_ANIMATOR_IMAGES: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(19000);
5717 /// Set the playback status of the animation for the image animator.
5718 /// This attribute can be set, reset, and obtained as required through APIs.
5719 ///
5720 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5721 ///
5722 /// .value[0].i32: the playback status of the animation, the type is [`ArkUI_AnimationStatus`],
5723 /// and the default value is ARKUI_ANIMATION_STATUS_INITIAL.
5724 ///
5725 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5726 ///
5727 /// .value[0].i32: the playback status of the animation, the type is [`ArkUI_AnimationStatus`].
5728 pub const NODE_IMAGE_ANIMATOR_STATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(19001);
5729 /// Set the playback duration for the image animator. When the duration is 0, no image is played.
5730 /// The value change takes effect only at the beginning of the next cycle.
5731 /// When a separate duration is set in images, the setting of this attribute is invalid.
5732 /// This attribute can be set, reset, and obtained as required through APIs.
5733 ///
5734 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5735 ///
5736 /// .value[0].i32: the playback duration, the unit is ms and the default value is 1000.
5737 ///
5738 ///
5739 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5740 ///
5741 /// .value[0].i32: the playback duration, the unit is ms.
5742 pub const NODE_IMAGE_ANIMATOR_DURATION: ArkUI_NodeAttributeType =
5743 ArkUI_NodeAttributeType(19002);
5744 /// Set the playback direction for the image animator.
5745 /// This attribute can be set, reset, and obtained as required through APIs.
5746 ///
5747 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5748 ///
5749 /// .value[0].i32: the playback direction. 0 indicates that images are played from the first one to the last one,
5750 /// and 1 indicates that images are played from the last one to the first one.
5751 ///
5752 ///
5753 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5754 ///
5755 /// .value[0].i32: the playback direction. 0 indicates that images are played from the first one to the last one,
5756 /// and 1 indicates that images are played from the last one to the first one.
5757 pub const NODE_IMAGE_ANIMATOR_REVERSE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(19003);
5758 /// Set whether the image size is the same as the component size.
5759 /// This attribute can be set, reset, and obtained as required through APIs.
5760 ///
5761 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5762 ///
5763 /// .value[0].i32: whether the image size is the same as the component size.
5764 /// 1 indicates the image size is the same as the component size.
5765 /// In this case, the width, height, top, and left attributes of the image are invalid.
5766 /// 0 indicates the image size is customized.
5767 /// The width, height, top, and left attributes of each image must be set separately.
5768 ///
5769 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5770 ///
5771 /// .value[0].i32: whether the image size is the same as the component size.
5772 /// 1 indicates the image size is the same as the component size.
5773 /// 0 indicates the image size is customized.
5774 pub const NODE_IMAGE_ANIMATOR_FIXED_SIZE: ArkUI_NodeAttributeType =
5775 ArkUI_NodeAttributeType(19004);
5776 /// Set the status before and after execution of the animation in the current playback direction.
5777 /// This attribute can be set, reset, and obtained as required through APIs.
5778 ///
5779 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5780 ///
5781 /// .value[0].i32: the status before and after execution of the animation in the current playback direction,
5782 /// the type is {ArkUI_AnimationFillMode} and the default value is ARKUI_ANIMATION_FILL_MODE_FORWARDS.
5783 ///
5784 ///
5785 /// Attribute obtaining method return value [`ArkUI_AttributeItem`] format:
5786 ///
5787 /// .value[0].i32: the status before and after execution of the animation in the current playback direction,
5788 /// the type is {ArkUI_AnimationFillMode}.
5789 pub const NODE_IMAGE_ANIMATOR_FILL_MODE: ArkUI_NodeAttributeType =
5790 ArkUI_NodeAttributeType(19005);
5791 /// Set the number of times that the animation is played.
5792 /// This attribute can be set, reset, and obtained as required through APIs.
5793 ///
5794 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5795 ///
5796 /// .value[0].i32: the number of times that the animation is played.
5797 ///
5798 ///
5799 /// Attribute setting method [`ArkUI_AttributeItem`] Parameter format:
5800 ///
5801 /// .value[0].i32: the number of times that the animation is played.
5802 pub const NODE_IMAGE_ANIMATOR_ITERATION: ArkUI_NodeAttributeType =
5803 ArkUI_NodeAttributeType(19006);
5804 /// Defines the name of the checkboxgroup.
5805 /// This attribute can be set, reset, and obtained as required through APIs.
5806 ///
5807 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5808 ///
5809 /// .string: component name.
5810 ///
5811 ///
5812 ///
5813 /// Format of the return value [`ArkUI_AttributeItem`]:
5814 ///
5815 /// .string: component name.
5816 ///
5817 ///
5818 ///
5819 /// Available since API-level: 15
5820 #[cfg(feature = "api-15")]
5821 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5822 pub const NODE_CHECKBOX_GROUP_NAME: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(21000);
5823 /// Defines whether the checkboxgroup is selected.
5824 /// This attribute can be set, reset, and obtained as required through APIs.
5825 ///
5826 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5827 ///
5828 /// .value[0].i32: whether the checkboxgroup is selected.
5829 /// The value <b>1</b> means that the checkboxgroup is selected, and <b>0</b> means the opposite.
5830 ///
5831 ///
5832 ///
5833 /// Format of the return value [`ArkUI_AttributeItem`]:
5834 ///
5835 /// .value[0].i32: The value <b>1</b> means that the checkboxgroup is selected, and <b>0</b> means the opposite.
5836 ///
5837 ///
5838 ///
5839 /// Available since API-level: 15
5840 #[cfg(feature = "api-15")]
5841 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5842 pub const NODE_CHECKBOX_GROUP_SELECT_ALL: ArkUI_NodeAttributeType =
5843 ArkUI_NodeAttributeType(21001);
5844 /// Defines the color of the checkboxgroup when it is selected.
5845 /// This attribute can be set, reset, and obtained as required through APIs.
5846 ///
5847 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5848 ///
5849 /// .value[0].u32: color of the checkboxgroup when it is selected, in 0xARGB format,
5850 /// for example, <b>0xFF1122FF</b>.
5851 ///
5852 ///
5853 ///
5854 /// Format of the return value [`ArkUI_AttributeItem`]:
5855 ///
5856 /// .value[0].u32: color of the checkboxgroup when it is selected, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5857 ///
5858 ///
5859 /// Available since API-level: 15
5860 #[cfg(feature = "api-15")]
5861 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5862 pub const NODE_CHECKBOX_GROUP_SELECTED_COLOR: ArkUI_NodeAttributeType =
5863 ArkUI_NodeAttributeType(21002);
5864 /// Defines the border color of the checkboxgroup when it is not selected.
5865 /// This attribute can be set, reset, and obtained as required through APIs.
5866 ///
5867 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5868 ///
5869 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5870 ///
5871 ///
5872 ///
5873 /// Format of the return value [`ArkUI_AttributeItem`]:
5874 ///
5875 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5876 ///
5877 ///
5878 /// Available since API-level: 15
5879 #[cfg(feature = "api-15")]
5880 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5881 pub const NODE_CHECKBOX_GROUP_UNSELECTED_COLOR: ArkUI_NodeAttributeType =
5882 ArkUI_NodeAttributeType(21003);
5883 /// Defines the internal icon style of the checkboxgroup.
5884 /// This attribute can be set, reset, and obtained as required through APIs.
5885 ///
5886 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5887 ///
5888 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5889 ///
5890 /// .value[1]?.f32: size of the internal mark, in vp. Optional.
5891 ///
5892 /// .value[2]?.f32: stroke width of the internal mark, in vp. Optional. The default value is <b>2</b>.
5893 ///
5894 ///
5895 ///
5896 /// Format of the return value [`ArkUI_AttributeItem`]:
5897 ///
5898 /// .value[0].u32: border color, in 0xARGB format, for example, <b>0xFF1122FF</b>.
5899 ///
5900 /// .value[1].f32: size of the internal mark, in vp.
5901 ///
5902 /// .value[2].f32: stroke width of the internal mark, in vp. The default value is <b>2</b>.
5903 ///
5904 ///
5905 ///
5906 /// Available since API-level: 15
5907 #[cfg(feature = "api-15")]
5908 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5909 pub const NODE_CHECKBOX_GROUP_MARK: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(21004);
5910 /// Defines the shape of the checkboxgroup.
5911 /// This attribute can be set, reset, and obtained as required through APIs.
5912 ///
5913 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5914 ///
5915 /// .value[0].i32: component shape. The parameter type is [`ArkUI_CheckboxShape`].
5916 ///
5917 ///
5918 ///
5919 /// Format of the return value [`ArkUI_AttributeItem`]:
5920 ///
5921 /// .value[0].i32: component shape. The parameter type is [`ArkUI_CheckboxShape`].
5922 ///
5923 ///
5924 /// Available since API-level: 15
5925 #[cfg(feature = "api-15")]
5926 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
5927 pub const NODE_CHECKBOX_GROUP_SHAPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(21005);
5928 /// Defines the alignment mode of the child components in the container. This attribute can be set, reset,
5929 /// and obtained as required through APIs.
5930 ///
5931 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5932 ///
5933 /// .value[0].i32: alignment mode. The data type is [`ArkUI_Alignment`].
5934 /// The default value is <b>ARKUI_ALIGNMENT_CENTER</b>.
5935 ///
5936 ///
5937 ///
5938 /// Format of the return value [`ArkUI_AttributeItem`]:
5939 ///
5940 /// .value[0].i32: alignment mode. The data type is [`ArkUI_Alignment`].
5941 pub const NODE_STACK_ALIGN_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1000000);
5942 /// Defines the scrollbar status. This attribute can be set, reset, and obtained as required through APIs.
5943 ///
5944 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5945 ///
5946 /// .value[0].i32: scrollbar status. The parameter type is [`ArkUI_ScrollBarDisplayMode`]. The default value is
5947 /// <b>ARKUI_SCROLL_BAR_DISPLAY_MODE_AUTO</b>.
5948 ///
5949 ///
5950 ///
5951 /// Format of the return value [`ArkUI_AttributeItem`]:
5952 ///
5953 /// .value[0].i32: scrollbar status. The parameter type is [`ArkUI_ScrollBarDisplayMode`].
5954 pub const NODE_SCROLL_BAR_DISPLAY_MODE: ArkUI_NodeAttributeType =
5955 ArkUI_NodeAttributeType(1002000);
5956 /// Defines the width of the scrollbar. This attribute can be set, reset, and obtained as required
5957 /// through APIs.
5958 ///
5959 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5960 ///
5961 /// .value[0].f32: width of the scrollbar, in vp. The default value is <b>4</b>.
5962 ///
5963 ///
5964 ///
5965 /// Format of the return value [`ArkUI_AttributeItem`]:
5966 ///
5967 /// .value[0].f32: width of the scrollbar, in vp.
5968 pub const NODE_SCROLL_BAR_WIDTH: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002001);
5969 /// Defines the color of the scrollbar. This attribute can be set, reset, and obtained as required
5970 /// through APIs.
5971 ///
5972 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5973 ///
5974 /// .data[0].u32: color of the scrollbar, in 0xARGB format.
5975 ///
5976 ///
5977 ///
5978 /// Format of the return value [`ArkUI_AttributeItem`]:
5979 ///
5980 /// .data[0].u32: color of the scrollbar, in 0xARGB format.
5981 pub const NODE_SCROLL_BAR_COLOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002002);
5982 /// Defines the scroll direction. This attribute can be set, reset, and obtained as required through APIs.
5983 ///
5984 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
5985 ///
5986 /// .value[0].i32: scroll direction. The parameter type is [`ArkUI_ScrollDirection`].
5987 /// The default value is <b>ARKUI_SCROLL_DIRECTION_VERTICAL</b>.
5988 ///
5989 ///
5990 ///
5991 /// Format of the return value [`ArkUI_AttributeItem`]:
5992 ///
5993 /// .value[0].i32: scroll direction. The parameter type is [`ArkUI_ScrollDirection`].
5994 pub const NODE_SCROLL_SCROLL_DIRECTION: ArkUI_NodeAttributeType =
5995 ArkUI_NodeAttributeType(1002003);
5996 /// Defines the effect used at the edges of the component when the boundary of the scrollable content is
5997 /// reached. This attribute can be set, reset, and obtained as required through APIs.
5998 ///
5999 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6000 ///
6001 /// .value[0].i32: effect used at the edges of the component when the boundary of the scrollable content is reached.
6002 /// The parameter type is [`ArkUI_EdgeEffect`]. The default value is <b>ARKUI_EDGE_EFFECT_NONE</b>.
6003 ///
6004 /// .value[1]?.i32: whether to enable the scroll effect when the component content size is smaller than the
6005 /// component itself. Optional. The value <b>1</b> means to enable the scroll effect, and <b>0</b> means the
6006 /// opposite. The default value is <b>1</b>.
6007 ///
6008 /// .value[2]?.i32: direction in which the effect takes effect. The parameter type is [`ArkUI_EffectEdge`].
6009 /// The default value is <b>ARKUI_EFFECT_EDGE_START | ARKUI_EFFECT_EDGE_END</b>. This parameter is supported since
6010 /// API version 16.
6011 ///
6012 ///
6013 ///
6014 /// Format of the return value [`ArkUI_AttributeItem`]:
6015 ///
6016 /// .value[0].i32: effect used at the edges of the component when the boundary of the scrollable content is reached.
6017 /// The parameter type is [`ArkUI_EdgeEffect`].
6018 ///
6019 /// .value[1].i32: whether to enable the scroll effect when the component content size is smaller than the component
6020 /// itself. Optional. The value <b>1</b> means to enable the scroll effect, and <b>0</b> means the opposite.
6021 ///
6022 /// .value[2].i32: edge for which the effect takes effect when the boundary of the scrollable content is reached.
6023 /// The parameter type is [`ArkUI_EffectEdge`]. This parameter is supported since API version 16.
6024 pub const NODE_SCROLL_EDGE_EFFECT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002004);
6025 /// Defines whether to support scroll gestures. When this attribute is set to <b>false</b>, scrolling by
6026 /// finger or mouse is not supported, but the scroll controller API is not affected.
6027 ///
6028 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6029 ///
6030 /// .value[0].i32: whether to support scroll gestures. The default value is <b>true</b>.
6031 ///
6032 ///
6033 ///
6034 /// Format of the return value [`ArkUI_AttributeItem`]:
6035 ///
6036 /// .value[0].i32: whether to support scroll gestures.
6037 pub const NODE_SCROLL_ENABLE_SCROLL_INTERACTION: ArkUI_NodeAttributeType =
6038 ArkUI_NodeAttributeType(1002005);
6039 /// Defines the friction coefficient. It applies only to gestures in the scrolling area, and it affects only
6040 /// indirectly the scroll chaining during the inertial scrolling process.
6041 ///
6042 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6043 ///
6044 /// .value[0].f32: friction coefficient. The default value is <b>0.6</b> for non-wearable devices and <b>0.9</b>
6045 /// for wearable devices.
6046 ///
6047 ///
6048 ///
6049 /// Format of the return value [`ArkUI_AttributeItem`]:
6050 ///
6051 /// .value[0].f32: friction coefficient.
6052 pub const NODE_SCROLL_FRICTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002006);
6053 /// Defines the scroll snapping mode. This attribute can be set, reset, and obtained as required through APIs.
6054 ///
6055 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6056 ///
6057 /// .value[0].i32: alignment mode for the scroll snap position. The parameter type is [`ArkUI_ScrollSnapAlign`].
6058 /// The default value is <b>ARKUI_SCROLL_SNAP_ALIGN_NONE</b>.
6059 ///
6060 /// .value[1].i32: whether to enable the snap to start feature. When scroll snapping is defined for the
6061 /// <b><Scroll></b> component, setting this attribute to <b>false</b> enables the component to scroll between the
6062 /// start edge and the first snap point. The default value is <b>true</b>. It is valid only when there are multiple
6063 /// snap points.
6064 ///
6065 /// .value[2].i32: Whether to enable the snap to end feature. When scroll snapping is defined for the
6066 /// <b><Scroll></b> component, setting this attribute to <b>false</b> enables the component to scroll between the
6067 /// end edge and the last snap point. The default value is <b>true</b>. It is valid only when there are multiple
6068 /// snap points.
6069 ///
6070 /// .value[3...].f32: snap points for the <b><Scroll></b> component. Each snap point defines the offset from an
6071 /// edge to which the <b><Scroll></b> component can scroll.
6072 ///
6073 ///
6074 ///
6075 /// Format of the return value [`ArkUI_AttributeItem`]:
6076 ///
6077 /// .value[0].i32: alignment mode for the scroll snap position. The parameter type is [`ArkUI_ScrollSnapAlign`].
6078 ///
6079 /// .value[1].i32: whether to enable the snap to start feature. When scroll snapping is defined for the
6080 /// <b><Scroll></b> component, setting this attribute to <b>false</b> enables the component to scroll between the
6081 /// start edge and the first snap point.
6082 ///
6083 /// .value[2].i32: Whether to enable the snap to end feature. When scroll snapping is defined for the
6084 /// <b><Scroll></b> component, setting this attribute to <b>false</b> enables the component to scroll between the
6085 /// end edge and the last snap point.
6086 ///
6087 /// .value[3...].f32: snap points for the <b><Scroll></b> component. Each snap point defines the offset from an edge
6088 /// to which the <b><Scroll></b> component can scroll.
6089 pub const NODE_SCROLL_SNAP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002007);
6090 /// Defines the nested scrolling options. This attribute can be set, reset, and obtained as required
6091 /// through APIs.
6092 ///
6093 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6094 ///
6095 /// .value[0].i32: nested scrolling option when the component scrolls forward.
6096 /// The parameter type is [`ArkUI_ScrollNestedMode`].
6097 ///
6098 /// .value[1].i32: nested scrolling option when the component scrolls backward.
6099 /// The parameter type is [`ArkUI_ScrollNestedMode`].
6100 ///
6101 ///
6102 ///
6103 /// Format of the return value [`ArkUI_AttributeItem`]:
6104 ///
6105 /// .value[0].i32: nested scrolling option when the component scrolls forward.
6106 /// The parameter type is [`ArkUI_ScrollNestedMode`].
6107 ///
6108 /// .value[1].i32: nested scrolling option when the component scrolls backward.
6109 /// The parameter type is [`ArkUI_ScrollNestedMode`].
6110 pub const NODE_SCROLL_NESTED_SCROLL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002008);
6111 /// Defines the specified position to scroll to. This attribute can be set, reset, and obtained as required
6112 /// through APIs.
6113 ///
6114 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6115 ///
6116 /// .value[0].f32: horizontal scrolling offset, in vp.
6117 ///
6118 /// .value[1].f32: vertical scrolling offset, in vp.
6119 ///
6120 /// .value[2]?.i32: scrolling duration, in milliseconds. Optional.
6121 ///
6122 /// .value[3]?.i32: scrolling curve. Optional. The parameter type is [`ArkUI_AnimationCurve`].
6123 /// The default value is <b>ARKUI_CURVE_EASE</b>.
6124 ///
6125 /// .value[4]?.i32: whether to enable the default spring animation. Optional. The default value <b>0</b> means not
6126 /// to enable the default spring animation.
6127 ///
6128 /// .value[5]?.i32: Optional value, sets whether scrolling can cross the boundary.
6129 ///
6130 ///
6131 ///
6132 /// Format of the return value [`ArkUI_AttributeItem`]:
6133 ///
6134 /// .value[0].f32: horizontal scrolling offset, in vp.
6135 ///
6136 /// .value[1].f32: vertical scrolling offset, in vp.
6137 pub const NODE_SCROLL_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002009);
6138 /// Defines the edge position to scroll to. This attribute can be set and obtained as required through APIs.
6139 ///
6140 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6141 ///
6142 /// .value[0].i32: edge position to scroll to. The parameter type is [`ArkUI_ScrollEdge`].
6143 ///
6144 ///
6145 ///
6146 /// Format of the return value [`ArkUI_AttributeItem`]:
6147 ///
6148 /// .value[0].i32: whether the container at the edge position. The value <b>-1</b> means that the container is not
6149 /// at the edge position. If the container is at the edge position, the parameter type is [`ArkUI_ScrollEdge`].
6150 pub const NODE_SCROLL_EDGE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002010);
6151 /// Defines whether to enable the swipe-to-turn-pages feature. This attribute can be set, reset, and obtained
6152 /// as required through APIs.
6153 ///
6154 /// If both <b>enablePaging</b> and <b>scrollSnap</b> are set, <b>scrollSnap</b> takes effect, but
6155 /// <b>enablePaging</b> does not.
6156 ///
6157 ///
6158 ///
6159 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6160 ///
6161 /// .value[0].i32: whether to enable the swipe-to-turn-pages feature. The default value is <b>false</b>.
6162 ///
6163 ///
6164 ///
6165 /// Format of the return value [`ArkUI_AttributeItem`]:
6166 ///
6167 /// .value[0].i32: whether to enable the swipe-to-turn-pages feature.
6168 pub const NODE_SCROLL_ENABLE_PAGING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002011);
6169 /// Scroll to the next or previous page.
6170 ///
6171 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6172 ///
6173 /// .value[0].i32 Indicates whether to scroll to next page. Value 0 indicates scroll to next page and value 1
6174 /// indicates scroll to previous page.
6175 ///
6176 /// .value[1]?.i32 Indicates whether to enable animation. Value 1 indicates enable and 0 indicates disable.
6177 pub const NODE_SCROLL_PAGE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002012);
6178 /// Scroll a specified distance.
6179 ///
6180 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6181 ///
6182 /// .value[0].f32:Horizontal scrolling distance in vp;
6183 ///
6184 /// .value[1].f32: Vertical scrolling distance in vp;
6185 pub const NODE_SCROLL_BY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002013);
6186 /// Performs inertial scrolling based on the initial velocity passed in.
6187 ///
6188 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6189 ///
6190 /// .value[0].f32: Initial velocity of inertial scrolling. Unit: vp/s. If the value specified is 0, it is
6191 /// considered as invalid, and the scrolling for this instance will not take effect. If the value is positive,
6192 /// the scroll will move downward; if the value is negative, the scroll will move upward.
6193 ///
6194 ///
6195 ///
6196 /// Available since API-level: 13
6197 #[cfg(feature = "api-13")]
6198 #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
6199 pub const NODE_SCROLL_FLING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002014);
6200 /// Sets the fading effect for the edges of scrollable components.
6201 ///
6202 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6203 /// .value[0].i32: whether to enable the fading effect on edges. The value 0 means to disable the fading effect,
6204 /// and 1 means to enable it.
6205 /// .value[1]?.f32: length of the fading effect on edges, in vp. Default value: 32.
6206 ///
6207 /// Format of the return value [`ArkUI_AttributeItem`]:
6208 /// .value[0].i32: whether the fading effect on edges is enabled. The value 0 means that the fading effect is
6209 /// disabled, and 1 means that it is enabled.
6210 /// .value[1].f32: length of the fading effect on edges, in vp.
6211 ///
6212 ///
6213 /// Available since API-level: 14
6214 #[cfg(feature = "api-14")]
6215 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
6216 pub const NODE_SCROLL_FADING_EDGE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002015);
6217 /// Obtains the total size of all child components when fully expanded in the scrollable component.
6218 ///
6219 /// Format of the return value [`ArkUI_AttributeItem`]:
6220 ///
6221 /// .value[0].f32: total width of all child components when fully expanded in the scrollable component.
6222 /// The default unit is vp.
6223 ///
6224 /// .value[1].f32: total height of all child components when fully expanded in the scrollable component.
6225 /// The default unit is vp.
6226 ///
6227 /// When <b>NODE_PADDING</b>, <b>NODE_MARGIN</b>, or <b>NODE_BORDER_WIDTH</b> is set, the values are rounded to the
6228 /// nearest pixel when being converted from vp to px.
6229 /// The returned values are calculated based on these rounded pixel values.
6230 ///
6231 ///
6232 ///
6233 /// Available since API-level: 14
6234 #[cfg(feature = "api-14")]
6235 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
6236 pub const NODE_SCROLL_SIZE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002016);
6237 /// Sets the offset from the start of the scrollable components content.
6238 ///
6239 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6240 ///
6241 /// .value[0].f32: offset from the start of the content, in vp.
6242 ///
6243 ///
6244 ///
6245 /// Format of the return value [`ArkUI_AttributeItem`]:
6246 ///
6247 /// .value[0].f32: offset from the start of the content, in vp.
6248 ///
6249 ///
6250 ///
6251 /// Available since API-level: 15
6252 #[cfg(feature = "api-15")]
6253 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6254 pub const NODE_SCROLL_CONTENT_START_OFFSET: ArkUI_NodeAttributeType =
6255 ArkUI_NodeAttributeType(1002017);
6256 /// Sets the offset from the end of the scrollable components content.
6257 ///
6258 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6259 ///
6260 /// .value[0].f32: offset from the end of the content, in vp.
6261 ///
6262 ///
6263 ///
6264 /// Format of the return value [`ArkUI_AttributeItem`]:
6265 ///
6266 /// .value[0].f32: offset from the end of the content, in vp.
6267 ///
6268 ///
6269 ///
6270 /// Available since API-level: 15
6271 #[cfg(feature = "api-15")]
6272 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6273 pub const NODE_SCROLL_CONTENT_END_OFFSET: ArkUI_NodeAttributeType =
6274 ArkUI_NodeAttributeType(1002018);
6275 /// Defines the maximum starting fling speed of the scrollable when the fling animation starts.
6276 /// This attribute can be set, reset, and obtained as required through APIs.
6277 ///
6278 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6279 ///
6280 /// .value[0].f32: maximum starting fling speed, Unit: vp/s
6281 ///
6282 ///
6283 ///
6284 /// Format of the return value [`ArkUI_AttributeItem`]:
6285 ///
6286 /// .value[0].f32: maximum starting fling speed, Unit: vp/s
6287 ///
6288 ///
6289 ///
6290 /// Available since API-level: 18
6291 #[cfg(feature = "api-18")]
6292 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
6293 pub const NODE_SCROLL_FLING_SPEED_LIMIT: ArkUI_NodeAttributeType =
6294 ArkUI_NodeAttributeType(1002019);
6295 /// Defines the clip mode of the scrollable.
6296 /// This attribute can be set, reset, and obtained as required through APIs.
6297 ///
6298 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6299 ///
6300 /// .value[0].i32: clip content mode, The parameter type is [`ArkUI_ContentClipMode`].
6301 ///
6302 ///
6303 ///
6304 /// Format of the return value [`ArkUI_AttributeItem`]:
6305 ///
6306 /// .value[0].i32: clip content mode, The parameter type is [`ArkUI_ContentClipMode`].
6307 ///
6308 ///
6309 ///
6310 /// Available since API-level: 18
6311 #[cfg(feature = "api-18")]
6312 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
6313 pub const NODE_SCROLL_CLIP_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002020);
6314 /// Defines whether the scrollable scrolls back to top when status bar is clicked.
6315 /// This attribute can be set, reset, and obtained as required through APIs.
6316 ///
6317 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6318 ///
6319 /// .value[0].i32: whether the scrollable scrolls back to top when status bar is clicked.
6320 /// The value <b>1</b> means to scroll back to top, and <b>0</b> means the opposite. The default value is <b>0/b>.
6321 ///
6322 ///
6323 ///
6324 /// Format of the return value [`ArkUI_AttributeItem`]:
6325 ///
6326 /// .value[0].i32: whether the scrollable scrolls back to top when status bar is clicked.
6327 ///
6328 ///
6329 ///
6330 /// Available since API-level: 15
6331 #[cfg(feature = "api-15")]
6332 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6333 pub const NODE_SCROLL_BACK_TO_TOP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1002021);
6334 /// Defines the direction in which the list items are arranged. This attribute can be set, reset, and
6335 /// obtained as required through APIs.
6336 ///
6337 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6338 ///
6339 /// .value[0].i32: direction in which the list items are arranged. The parameter type is [`ArkUI_Axis`].
6340 /// The default value is <b>ARKUI_AXIS_VERTICAL</b>.
6341 ///
6342 ///
6343 ///
6344 /// Format of the return value [`ArkUI_AttributeItem`]:
6345 ///
6346 /// .value[0].i32: direction in which the list items are arranged. The parameter type is [`ArkUI_Axis`].
6347 pub const NODE_LIST_DIRECTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003000);
6348 /// Defines whether to pin the header to the top or the footer to the bottom in the <b><ListItemGroup></b>
6349 /// component. This attribute can be set, reset, and obtained as required through APIs.
6350 ///
6351 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6352 ///
6353 /// .value[0].i32: whether to pin the header to the top or the footer to the bottom in the <b><ListItemGroup></b>
6354 /// component. It is used together with the <b><ListItemGroup></b> component. The parameter type is
6355 /// [`ArkUI_StickyStyle`]. The default value is <b>ARKUI_STICKY_STYLE_NONE</b>.
6356 ///
6357 ///
6358 ///
6359 /// Format of the return value [`ArkUI_AttributeItem`]:
6360 ///
6361 /// .value[0].i32: whether to pin the header to the top or the footer to the bottom in the <b><ListItemGroup></b>
6362 /// component. It is used together with the <b><ListItemGroup></b> component. The parameter type is
6363 /// [`ArkUI_StickyStyle`].
6364 pub const NODE_LIST_STICKY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003001);
6365 /// Defines the spacing between list items. This attribute can be set, reset, and obtained as required
6366 /// through APIs.
6367 ///
6368 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6369 ///
6370 /// .value[0].f32: spacing between list items along the main axis. The default value is <b>0</b>.
6371 ///
6372 ///
6373 ///
6374 /// Format of the return value [`ArkUI_AttributeItem`]:
6375 ///
6376 /// .value[0].f32: spacing between list items along the main axis.
6377 pub const NODE_LIST_SPACE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003002);
6378 /// Defines the list adapter. The attribute can be set, reset, and obtained as required through APIs.
6379 ///
6380 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6381 ///
6382 /// .object: [`ArkUI_NodeAdapter`] object as the adapter.
6383 pub const NODE_LIST_NODE_ADAPTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003003);
6384 /// Sets the number of cached items in the list adapter.
6385 /// This attribute can be set, reset, and obtained as required through APIs.
6386 ///
6387 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6388 ///
6389 /// .value[0].i32: number of cached items in the list adapter.
6390 ///
6391 /// .value[1]?.i32: whether to show cached items. The value <b>0</b> means to hide cached items, and <b>0</b> means
6392 /// to show cached items. The default value is <b>0</b>. This parameter is supported since API version 15.
6393 ///
6394 ///
6395 ///
6396 /// Format of the return value [`ArkUI_AttributeItem`]:
6397 ///
6398 /// .value[0].i32: number of cached items in the list adapter.
6399 ///
6400 /// .value[1].i32: whether to show cached items. The value <b>0</b> means to hide cached items, and <b>0</b> means
6401 /// to show cached items. This parameter is supported since API version 15.
6402 pub const NODE_LIST_CACHED_COUNT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003004);
6403 /// Scroll to the specified index.
6404 ///
6405 /// When activating the smooth animation, all items passed through will be loaded and layout calculated, which can
6406 /// lead to performance issues when loading a large number of items.
6407 ///
6408 ///
6409 ///
6410 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6411 ///
6412 /// .value[0].i32:The index value of the target element to be slid to in the current container.
6413 ///
6414 /// .value[1]?.i32:Set whether there is an action when sliding to the index value of a list item in the list, where
6415 /// 1 indicates an action and 0 indicates no action. Default value: 0。
6416 ///
6417 /// .value[2]?.i32:Specify the alignment of the sliding element with the current container,The parameter type is
6418 /// [`ArkUI_ScrollAlignment`], default value is ARKUI_SCROLL_ALIGNMENT_START.
6419 ///
6420 /// .value[3]?.f32: extra offset, in vp. The default value is <b>0</b>.
6421 /// This parameter is supported since API version 15.
6422 pub const NODE_LIST_SCROLL_TO_INDEX: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003005);
6423 /// Sets the alignment mode of list items along the cross axis when the cross-axis width of the list is
6424 /// greater than the cross-axis width of list items multiplied by the value of lanes.
6425 /// This attribute can be set, reset, and obtained as required through APIs.
6426 ///
6427 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6428 ///
6429 /// .value[0].i32: alignment mode of list items along the cross axis.
6430 /// The parameter type is [`ArkUI_ListItemAlignment`].
6431 ///
6432 ///
6433 ///
6434 /// Format of the return value [`ArkUI_AttributeItem`]:
6435 ///
6436 /// .value[0].i32: alignment mode of list items along the cross axis.
6437 /// The parameter type is [`ArkUI_ListItemAlignment`].
6438 pub const NODE_LIST_ALIGN_LIST_ITEM: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003006);
6439 /// Set the default spindle size for the List subcomponent.
6440 ///
6441 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6442 ///
6443 /// .object: The parameter format is [`ArkUI-ListChildrenMainSize`]
6444 ///
6445 ///
6446 ///
6447 /// Format of the return value [`ArkUI_AttributeItem`]:
6448 ///
6449 /// .object: The parameter format is [`ArkUI-ListChildrenMainSize`]
6450 pub const NODE_LIST_CHILDREN_MAIN_SIZE: ArkUI_NodeAttributeType =
6451 ArkUI_NodeAttributeType(1003007);
6452 /// Set the index value of the item displayed at the start of the viewport
6453 /// when the current List is first loaded.This attribute can be set, reset, and obtained as required through APIs.
6454 ///
6455 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6456 ///
6457 /// .value[0].i32: index value of the item displayed at
6458 /// the start of the viewport when the current List is loaded for the first time. Default value: 0.
6459 ///
6460 ///
6461 ///
6462 /// Format of the return value [`ArkUI_AttributeItem`]:
6463 ///
6464 /// .value[0].i32: index value of the item displayed at
6465 /// the start of the viewport when the current List is loaded for the first time. Default value: 0.
6466 pub const NODE_LIST_INITIAL_INDEX: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003008);
6467 /// sets the ListItem splitter style. By default, there is no splitter.
6468 /// This attribute can be set, reset, and obtained as required through APIs.
6469 ///
6470 /// Attribute setting method parameter [`ArkUI_AttributeItem`] Format:
6471 ///
6472 /// .value[0].u32: divider color, type 0xargb;
6473 ///
6474 /// .value[1].f32: dividing line width;
6475 ///
6476 /// .value[2].f32: the distance between the divider and the beginning of the side of the list, unit vp;
6477 ///
6478 /// .value[3].f32: the distance between the divider and the end of the side of the list (unit: vp).
6479 ///
6480 ///
6481 ///
6482 /// Attribute fetch method return value [`ArkUI_AttributeItem`] format:
6483 ///
6484 /// .value[0].u32: divider color, type 0xargb;
6485 ///
6486 /// .value[1].f32: dividing line width;
6487 ///
6488 /// .value[2].f32: the distance between the divider and the beginning of the side of the list, unit vp;
6489 ///
6490 /// .value[3].f32: the distance between the divider and the end of the side of the list (unit: vp).
6491 pub const NODE_LIST_DIVIDER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003009);
6492 /// Scrolls to the item with the specified index in the specified list item group.
6493 ///
6494 /// When <b>smooth</b> is set to <b>true</b>, all passed items are loaded and counted in layout calculation.
6495 /// This may result in performance issues if a large number of items are involved.
6496 ///
6497 ///
6498 ///
6499 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6500 ///
6501 /// .value[0].i32: index of the target list item group in the current list.
6502 ///
6503 /// .value[1].i32: index of the target list item in the list item group.
6504 ///
6505 /// .value[2]?.i32: whether to enable the smooth animation for scrolling to the item with the specified index.
6506 /// The value <b>1</b> means to enable the animation, and <b>0</b> means the opposite.
6507 /// The default value is <b>0</b>.
6508 ///
6509 /// .value[3]?.i32: how the item to scroll to is aligned with the container. The parameter type is
6510 /// [`ArkUI_ScrollAlignment`]. The default value is <b>ARKUI_SCROLL_ALIGNMENT_START</b>.
6511 ///
6512 ///
6513 ///
6514 /// Available since API-level: 15
6515 #[cfg(feature = "api-15")]
6516 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6517 pub const NODE_LIST_SCROLL_TO_INDEX_IN_GROUP: ArkUI_NodeAttributeType =
6518 ArkUI_NodeAttributeType(1003010);
6519 /// Sets the number of lanes in the list.
6520 /// This attribute can be set, reset, and obtained as required through APIs.
6521 ///
6522 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6523 ///
6524 /// .value[0].u32: number of lanes in the list. If the maximum and minimum lane widths are set, setting the number
6525 /// of lanes will not take effect.
6526 ///
6527 /// .value[1]?.f32: minimum lane width, in vp.
6528 ///
6529 /// .value[2]?.f32: maximum column width, in vp.
6530 ///
6531 /// .value[3]?.f32: lane spacing, in vp.
6532 ///
6533 ///
6534 ///
6535 /// Format of the return value [`ArkUI_AttributeItem`]:
6536 ///
6537 /// .value[0].u32: number of lanes in the list.
6538 ///
6539 /// .value[1].f32: minimum lane width, in vp.
6540 ///
6541 /// .value[2].f32: maximum column width, in vp.
6542 ///
6543 /// .value[3].f32: lane spacing, in vp.
6544 ///
6545 ///
6546 ///
6547 ///
6548 /// Available since API-level: 15
6549 #[cfg(feature = "api-15")]
6550 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6551 pub const NODE_LIST_LANES: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1003011);
6552 /// Sets the list snap alignment mode.
6553 ///
6554 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6555 ///
6556 /// .value[0].i32: alignment mode for the list snap position. The parameter type is [`ArkUI_ScrollSnapAlign`].
6557 /// The default value is <b>ARKUI_SCROLL_SNAP_ALIGN_NONE</b>.
6558 ///
6559 ///
6560 ///
6561 /// Format of the return value [`ArkUI_AttributeItem`]:
6562 ///
6563 /// .value[0].i32: alignment mode for the list snap position. The parameter type is [`ArkUI_ScrollSnapAlign`].
6564 ///
6565 ///
6566 ///
6567 /// Available since API-level: 15
6568 #[cfg(feature = "api-15")]
6569 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6570 pub const NODE_LIST_SCROLL_SNAP_ALIGN: ArkUI_NodeAttributeType =
6571 ArkUI_NodeAttributeType(1003012);
6572 /// Sets whether to maintain the visible content's position when data is inserted or deleted outside the
6573 /// display area of the <b>List</b> component.
6574 ///
6575 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6576 ///
6577 /// .value[0].i32: whether to maintain the visible content's position when data is inserted or deleted outside the
6578 /// display area of the <b>List</b> component. The value <b>0</b> means not to maintain the visible content's
6579 /// position, and <b>1</b> means the opposite. The default value is <b>0</b>.
6580 ///
6581 ///
6582 ///
6583 /// Format of the return value [`ArkUI_AttributeItem`]:
6584 ///
6585 /// .value[0].i32: whether to maintain the visible content's position when data is inserted or deleted outside the
6586 /// display area of the <b>List</b> component. The value <b>0</b> means not to maintain the visible content's
6587 /// position, and <b>1</b> means the opposite. The default value is <b>0</b>.
6588 ///
6589 ///
6590 ///
6591 /// Available since API-level: 15
6592 #[cfg(feature = "api-15")]
6593 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6594 pub const NODE_LIST_MAINTAIN_VISIBLE_CONTENT_POSITION: ArkUI_NodeAttributeType =
6595 ArkUI_NodeAttributeType(1003013);
6596 /// Defines whether to enable loop playback for the swiper.
6597 /// This attribute can be set, reset, and obtained as required through APIs.
6598 ///
6599 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6600 ///
6601 /// .value[0].i32: whether to enable loop playback. The value <b>1</b> means to enable loop playback, and <b>0</b>
6602 /// means the opposite. The default value is <b>1/b>.
6603 ///
6604 ///
6605 ///
6606 /// Format of the return value [`ArkUI_AttributeItem`]:
6607 ///
6608 /// .value[0].i32: whether to enable loop playback. The value <b>1</b> means to enable loop playback, and <b>0</b>
6609 /// means the opposite. The default value is <b>1</b>.
6610 pub const NODE_SWIPER_LOOP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001000);
6611 /// Defines whether to enable automatic playback for child component switching in the swiper.
6612 /// This attribute can be set, reset, and obtained as required through APIs.
6613 ///
6614 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6615 ///
6616 /// .value[0].i32: whether to enable automatic playback for child component switching. The value <b>1</b>
6617 /// means to enable automatic playback, and <b>0</b> means the opposite. The default value is <b>0</b>.
6618 ///
6619 ///
6620 ///
6621 /// .value[1]?.i32: whether to stop automatic playback when the user touches the screen. The value <b>1</b> means
6622 /// to stop automatic playback, and <b>0</b> means the opposite. The default value is <b>1</b>. This parameter is
6623 /// supported since API version 16.
6624 ///
6625 ///
6626 ///
6627 /// Format of the return value [`ArkUI_AttributeItem`]:
6628 ///
6629 /// .value[0].i32: whether to enable automatic playback for child component switching. The value <b>1</b> means
6630 /// to enable automatic playback, and <b>0</b> means the opposite. The default value is <b>0</b>.
6631 ///
6632 /// .value[1].i32: whether to stop automatic playback when the user touches the screen. The value <b>1</b> means to
6633 /// stop automatic playback, and <b>0</b> means the opposite. This parameter is supported since API version 16.
6634 pub const NODE_SWIPER_AUTO_PLAY: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001001);
6635 /// Defines whether to enable the navigation point indicator for the swiper. This attribute can be set,
6636 /// reset, and obtained as required through APIs.
6637 ///
6638 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6639 ///
6640 /// .value[0].i32: whether to enable the navigation point indicator. The value <b>1</b> means to enable the
6641 /// navigation point indicator, and <b>0</b> means the opposite. The default value is <b>1</b>.
6642 ///
6643 ///
6644 ///
6645 /// Format of the return value [`ArkUI_AttributeItem`]:
6646 ///
6647 /// .value[0].i32: whether to enable the navigation point indicator. The value <b>1</b> means to enable the
6648 /// navigation point indicator, and <b>0</b> means the opposite. The default value is <b>1</b>.
6649 pub const NODE_SWIPER_SHOW_INDICATOR: ArkUI_NodeAttributeType =
6650 ArkUI_NodeAttributeType(1001002);
6651 /// Defines the interval for automatic playback. This attribute can be set, reset, and obtained as required
6652 /// through APIs.
6653 ///
6654 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6655 ///
6656 /// .value[0].f32: interval for automatic playback, in milliseconds.
6657 ///
6658 ///
6659 ///
6660 /// Format of the return value [`ArkUI_AttributeItem`]:
6661 ///
6662 /// .value[0].f32: interval for automatic playback, in milliseconds.
6663 pub const NODE_SWIPER_INTERVAL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001003);
6664 /// Defines whether vertical swiping is used for the swiper. This attribute can be set, reset, and obtained
6665 /// as required through APIs.
6666 ///
6667 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6668 ///
6669 /// .value[0].i32: whether vertical swiping is used. The value <b>1</b> means that vertical swiping is used, and
6670 /// <b>0</b> means the opposite. The default value is <b>0</b>.
6671 ///
6672 ///
6673 ///
6674 /// Format of the return value [`ArkUI_AttributeItem`]:
6675 ///
6676 /// .value[0].i32: whether vertical swiping is used. The value <b>1</b> means that vertical swiping is used, and
6677 /// <b>0</b> means the opposite. The default value is <b>0</b>.
6678 pub const NODE_SWIPER_VERTICAL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001004);
6679 /// Defines the duration of the animation for switching child components. This attribute can be set, reset,
6680 /// and obtained as required through APIs.
6681 ///
6682 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6683 ///
6684 /// .value[0].f32: duration of the animation for switching child components, in milliseconds. The default value is
6685 /// <b>400</b>.
6686 ///
6687 ///
6688 ///
6689 /// Format of the return value [`ArkUI_AttributeItem`]:
6690 ///
6691 /// .value[0].f32: duration of the animation for switching child components, in milliseconds. The default value is
6692 /// <b>400</b>.
6693 pub const NODE_SWIPER_DURATION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001005);
6694 /// Defines the animation curve for the swiper. This attribute can be set, reset, and obtained as required
6695 /// through APIs.
6696 ///
6697 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6698 ///
6699 /// .value[0].i32: animation curve. The parameter type is [`ArkUI_AnimationCurve`].
6700 /// The default value is <b>ARKUI_CURVE_LINEAR</b>.
6701 ///
6702 ///
6703 ///
6704 /// Format of the return value [`ArkUI_AttributeItem`]:
6705 ///
6706 /// .value[0].i32: animation curve. The parameter type is [`ArkUI_AnimationCurve`].
6707 /// The default value is <b>ARKUI_CURVE_LINEAR</b>.
6708 pub const NODE_SWIPER_CURVE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001006);
6709 /// Defines the spacing between child components in the swiper.
6710 /// This attribute can be set, reset, and obtained as required through APIs.
6711 ///
6712 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6713 ///
6714 /// .value[0].f32: spacing between child components.
6715 ///
6716 ///
6717 ///
6718 /// Format of the return value [`ArkUI_AttributeItem`]:
6719 ///
6720 /// .value[0].f32: spacing between child components.
6721 pub const NODE_SWIPER_ITEM_SPACE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001007);
6722 /// Defines the index of the child component currently displayed in the swiper.
6723 /// This attribute can be set, reset, and obtained as required through APIs.
6724 ///
6725 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6726 ///
6727 /// .value[0].i32: index value of the child component.
6728 ///
6729 /// .value[1]?.i32: animation mode, the parameter type is [`ArkUI_SwiperAnimationMode`].
6730 ///
6731 /// The default value is ARKUI_SWIPER_NO_ANIMATION. This parameter is valid only for the current call.
6732 ///
6733 /// This parameter is supported since API version 15.
6734 ///
6735 ///
6736 ///
6737 /// Format of the return value [`ArkUI_AttributeItem`]:
6738 ///
6739 /// .value[0].i32: index value of the child component.
6740 pub const NODE_SWIPER_INDEX: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001008);
6741 /// Defines the number of elements to display per page.
6742 /// This attribute can be set, reset, and obtained as required through APIs.
6743 ///
6744 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6745 ///
6746 /// .value[0].i32: index value of the child component.
6747 ///
6748 ///
6749 ///
6750 /// Format of the return value [`ArkUI_AttributeItem`]:
6751 ///
6752 /// .value[0].i32: index value of the child component.
6753 pub const NODE_SWIPER_DISPLAY_COUNT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001009);
6754 /// Defines whether to disable the swipe feature.
6755 /// This attribute can be set, reset, and obtained as required through APIs.
6756 ///
6757 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6758 ///
6759 /// .value[0].i32: whether to disable the swipe feature. The value <b>1</b> means to disable
6760 /// the swipe feature, and <b>0</b> means the opposite. The default value is <b>0</b>.
6761 ///
6762 ///
6763 ///
6764 /// Format of the return value [`ArkUI_AttributeItem`]:
6765 ///
6766 /// .value[0].i32: whether to disable the swipe feature. The value <b>1</b> means to disable the swipe
6767 /// feature, and <b>0</b> means the opposite. The default value is <b>0</b>.
6768 pub const NODE_SWIPER_DISABLE_SWIPE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001010);
6769 /// Defines whether to show the arrow when the mouse pointer hovers over the navigation point indicator.
6770 /// This attribute can be set, reset, and obtained as required through APIs.
6771 ///
6772 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6773 ///
6774 /// .value[0].i32: whether to show the arrow when the mouse pointer hovers over the navigation point indicator.
6775 /// The parameter type is [`ArkUI_SwiperArrow`].
6776 ///
6777 /// The default value is <b>ARKUI_SWIPER_ARROW_HIDE</b>.
6778 ///
6779 ///
6780 ///
6781 /// Format of the return value [`ArkUI_AttributeItem`]:
6782 ///
6783 /// .value[0].i32: whether to show the arrow when the mouse pointer hovers over the navigation point indicator.
6784 /// The parameter type is [`ArkUI_SwiperArrow`].
6785 ///
6786 /// The default value is <b>ARKUI_SWIPER_ARROW_HIDE</b>.
6787 pub const NODE_SWIPER_SHOW_DISPLAY_ARROW: ArkUI_NodeAttributeType =
6788 ArkUI_NodeAttributeType(1001011);
6789 /// Defines the effect used at the edges of the swiper when the boundary of the scrollable content is reached.
6790 /// This attribute can be set, reset, and obtained as required through APIs.
6791 ///
6792 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6793 ///
6794 /// .value[0].i32: effect used at the edges of the swiper when the boundary of the scrollable content is reached.
6795 /// The parameter type is [`ArkUI_EdgeEffect`].
6796 ///
6797 /// The default value is <b>ARKUI_EDGE_EFFECT_SPRING</b>.
6798 ///
6799 ///
6800 ///
6801 /// Format of the return value [`ArkUI_AttributeItem`]:
6802 ///
6803 /// .value[0].i32: effect used at the edges of the swiper when the boundary of the scrollable content is reached.
6804 /// The parameter type is [`ArkUI_EdgeEffect`].
6805 pub const NODE_SWIPER_EDGE_EFFECT_MODE: ArkUI_NodeAttributeType =
6806 ArkUI_NodeAttributeType(1001012);
6807 /// Defines the swiper adapter. The attribute can be set, reset, and obtained as required through APIs.
6808 ///
6809 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6810 ///
6811 /// .object: [`ArkUI_NodeAdapter`] object as the adapter.
6812 pub const NODE_SWIPER_NODE_ADAPTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001013);
6813 /// Sets the number of cached items in the swiper adapter.
6814 /// This attribute can be set, reset, and obtained as required through APIs.
6815 ///
6816 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6817 ///
6818 /// .value[0].i32: number of cached items in the swiper adapter.
6819 pub const NODE_SWIPER_CACHED_COUNT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001014);
6820 /// Defines the front margin of the wiper.
6821 /// The attribute can be set, reset, and obtained as required through APIs.
6822 ///
6823 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6824 ///
6825 /// .value[0].f32: the front margin. The unit is vp. The default value is <b>0.0</b>
6826 ///
6827 /// .value[1]?.i32: whether to ignore blanks, the default value is 0.
6828 /// The value <b>1</b> means to ignore blank areas, and <b>0</b> means the opposite.
6829 ///
6830 /// Format of the return value [`ArkUI_AttributeItem`]:
6831 ///
6832 /// .value[0].f32: the front margin, the unit is vp.
6833 ///
6834 /// .value[1].i32: whether to ignore blank areas. The value <b>1</b> means to ignore blank areas, and <b>0</b> means
6835 /// the opposite.
6836 pub const NODE_SWIPER_PREV_MARGIN: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001015);
6837 /// Defines the back margin of the wiper.
6838 /// The attribute can be set, reset, and obtained as required through APIs.
6839 ///
6840 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6841 ///
6842 /// .value[0].f32: the back margin. The unit is vp. The default value is <b>0.0</b>
6843 ///
6844 /// .value[1]?.i32: whether to ignore blanks, the default value is 0.
6845 /// The value <b>1</b> means to ignore blank areas, and <b>0</b> means the opposite.
6846 ///
6847 /// Format of the return value [`ArkUI_AttributeItem`]:
6848 ///
6849 /// .value[0].f32: the back margin, the unit is vp.
6850 ///
6851 /// .value[1].i32: whether to ignore blank areas. The value <b>1</b> means to ignore blank areas, and <b>0</b> means
6852 /// the opposite.
6853 pub const NODE_SWIPER_NEXT_MARGIN: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001016);
6854 /// Defines the navigation indicator type of the swiper.
6855 /// The attribute can be set, reset, and obtained as required through APIs.
6856 ///
6857 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6858 ///
6859 /// .value[0].i32: navigation indicator type, the parameter type is [`ArkUI_SwiperIndicatorType`].
6860 ///
6861 /// .object: The parameter type is [`ArkUI_SwiperIndicator`].
6862 ///
6863 /// Format of the return value [`ArkUI_AttributeItem`]:
6864 ///
6865 /// .value[0].i32: navigation indicator type, the parameter type is [`ArkUI_SwiperIndicatorType`].
6866 ///
6867 /// .object: The parameter type is [`ArkUI_SwiperIndicator`].
6868 pub const NODE_SWIPER_INDICATOR: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001017);
6869 /// Set the nested scrolling mode for the Swiper component and parent component.
6870 ///
6871 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6872 ///
6873 /// .value[0].i32:Nested scrolling patterns for Swiper components and parent components. The parameter type is
6874 /// [`ArkUI_SwiperNestedScrollMode`]
6875 ///
6876 /// The default value is <b>ARKUI_SWIPER_NESTED_SRCOLL_SELF_ONLY<b>
6877 ///
6878 ///
6879 ///
6880 /// Format of the return value [`ArkUI_AttributeItem`]:
6881 ///
6882 /// .value[0].i32:Nested scrolling patterns for Swiper components and parent components. The parameter type is
6883 /// [`ArkUI_SwiperNestedScrollMode`]
6884 pub const NODE_SWIPER_NESTED_SCROLL: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1001018);
6885 /// Set the switcher component to flip to the specified page.
6886 ///
6887 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6888 ///
6889 /// .value[0].i32:Specify the index value of the page in Swiper.
6890 ///
6891 /// .value[1]?.i32:Set whether there is an animation effect when flipping to the specified page. 1 indicates active
6892 /// effect, 0 indicates no active effect, default value is 0。
6893 pub const NODE_SWIPER_SWIPE_TO_INDEX: ArkUI_NodeAttributeType =
6894 ArkUI_NodeAttributeType(1001019);
6895 /// Set to disable component navigation point interaction function。
6896 ///
6897 /// Property setting method parameter [`ArkUI-AttributeItem`] format:
6898 ///
6899 /// .value[0].i32:Set to disable the interaction function of component navigation points. When set to true, it
6900 /// indicates that the navigation points are interactive. The default value is true.
6901 ///
6902 /// The return value of the attribute acquisition method is in the format of [`ArkUI-AttributeItem`]:
6903 ///
6904 /// .value[0].i32:Set to disable component navigation point interaction.
6905 pub const NODE_SWIPER_INDICATOR_INTERACTIVE: ArkUI_NodeAttributeType =
6906 ArkUI_NodeAttributeType(1001020);
6907 /// Sets the page flipping mode using the mouse wheel.
6908 ///
6909 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6910 ///
6911 /// .value[0].i32: page flipping mode using the mouse wheel. The parameter type is [`ArkUI_PageFlipMode`].
6912 ///
6913 ///
6914 ///
6915 /// Format of the return value [`ArkUI_PageFlipMode`]:
6916 ///
6917 /// .value[0].i32: page flipping mode using the mouse wheel.
6918 ///
6919 ///
6920 ///
6921 /// Available since API-level: 15
6922 #[cfg(feature = "api-15")]
6923 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
6924 pub const NODE_SWIPER_PAGE_FLIP_MODE: ArkUI_NodeAttributeType =
6925 ArkUI_NodeAttributeType(1001021);
6926 /// Set the delineation component of the ListItem, supporting property settings, property resets, and
6927 /// property acquisition interfaces.
6928 ///
6929 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
6930 ///
6931 /// .object: Construct using the [`ArkUI_ListitemSwipeActionOption`] object.
6932 ///
6933 ///
6934 ///
6935 /// The return value of the attribute acquisition method [`ArkUI_AttributeItem`] format:
6936 ///
6937 /// .object: Construct using the [`ArkUI_ListitemSwipeActionOption`] object.
6938 pub const NODE_LIST_ITEM_SWIPE_ACTION: ArkUI_NodeAttributeType =
6939 ArkUI_NodeAttributeType(1004000);
6940 /// Defines the header of the list item group.
6941 /// This attribute can be set, reset, and obtained as required through APIs.
6942 ///
6943 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6944 ///
6945 /// .object: [`ArkUI_NodeHandle`] object to be used as the header of the list item group.
6946 ///
6947 ///
6948 ///
6949 /// Format of the return value [`ArkUI_AttributeItem`]:
6950 ///
6951 /// .object: [`ArkUI_NodeHandle`] object to be used as the header of the list item group.
6952 pub const NODE_LIST_ITEM_GROUP_SET_HEADER: ArkUI_NodeAttributeType =
6953 ArkUI_NodeAttributeType(1005000);
6954 /// Defines the footer of the list item group. This attribute can be set, reset, and obtained as
6955 /// required through APIs.
6956 ///
6957 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6958 ///
6959 /// .object: [`ArkUI_NodeHandle`] object to be used as the footer of the list item group.
6960 ///
6961 ///
6962 ///
6963 /// Format of the return value [`ArkUI_AttributeItem`]:
6964 ///
6965 /// .object: [`ArkUI_NodeHandle`] object to be used as the footer of the list item group.
6966 pub const NODE_LIST_ITEM_GROUP_SET_FOOTER: ArkUI_NodeAttributeType =
6967 ArkUI_NodeAttributeType(1005001);
6968 /// Defines the style of the divider for the list items. This attribute can be set, reset, and obtained
6969 /// as required through APIs.
6970 ///
6971 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6972 ///
6973 /// .value[0].u32: color of the divider, in 0xARGB format.
6974 ///
6975 /// .value[1].f32: stroke width of the divider, in vp.
6976 ///
6977 /// .value[2].f32: distance between the divider and the start of the list, in vp.
6978 ///
6979 /// .value[3].f32: distance between the divider and the end of the list, in vp.
6980 ///
6981 ///
6982 ///
6983 ///
6984 /// Format of the return value [`ArkUI_AttributeItem`]:
6985 ///
6986 /// .value[0].u32: color of the divider, in 0xARGB format.
6987 ///
6988 /// .value[1].f32: stroke width of the divider, in vp.
6989 ///
6990 /// .value[2].f32: distance between the divider and the start of the list, in vp.
6991 ///
6992 /// .value[3].f32: distance between the divider and the end of the list, in vp.
6993 ///
6994 pub const NODE_LIST_ITEM_GROUP_SET_DIVIDER: ArkUI_NodeAttributeType =
6995 ArkUI_NodeAttributeType(1005002);
6996 /// Set the default spindle size for the ListItem Group subcomponent.
6997 ///
6998 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
6999 ///
7000 /// .object: The parameter format is [`ArkUI-ListChildrenMainSize`]
7001 ///
7002 ///
7003 ///
7004 /// Format of the return value [`ArkUI_AttributeItem`]:
7005 ///
7006 /// .object: The parameter format is [`ArkUI-ListChildrenMainSize`]
7007 pub const NODE_LIST_ITEM_GROUP_CHILDREN_MAIN_SIZE: ArkUI_NodeAttributeType =
7008 ArkUI_NodeAttributeType(1005003);
7009 /// Defines the list item group adapter.
7010 /// This attribute can be set, reset, and obtained as required through APIs.
7011 ///
7012 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7013 ///
7014 /// .object: [`ArkUI_NodeAdapter`] object as the adapter.
7015 ///
7016 ///
7017 ///
7018 /// Format of the return value [`ArkUI_AttributeItem`]:
7019 ///
7020 /// .object: [`ArkUI_NodeAdapter`] object.
7021 ///
7022 ///
7023 ///
7024 /// Available since API-level: 15
7025 #[cfg(feature = "api-15")]
7026 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
7027 pub const NODE_LIST_ITEM_GROUP_NODE_ADAPTER: ArkUI_NodeAttributeType =
7028 ArkUI_NodeAttributeType(1005004);
7029 /// Defines the horizontal alignment mode of child components in the column.
7030 /// This attribute can be set, reset, and obtained as required through APIs.
7031 ///
7032 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7033 ///
7034 /// .value[0].i32: horizontal alignment mode of child components.
7035 /// The parameter type is [`ArkUI_HorizontalAlignment`].
7036 ///
7037 /// Default value: <b>ARKUI_HORIZONTAL_ALIGNMENT_CENTER</b>.
7038 ///
7039 ///
7040 ///
7041 /// Format of the return value [`ArkUI_AttributeItem`]:
7042 ///
7043 /// .value[0].i32: horizontal alignment mode of child components.
7044 /// The parameter type is [`ArkUI_HorizontalAlignment`].
7045 pub const NODE_COLUMN_ALIGN_ITEMS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1006000);
7046 /// Defines the vertical alignment mode of child components in the column.
7047 /// This attribute can be set, reset, and obtained as required through APIs.
7048 ///
7049 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7050 ///
7051 /// .value[0].i32: vertical alignment mode of child components. The parameter type is [`ArkUI_FlexAlignment`].
7052 ///
7053 /// Default value: <b>ARKUI_FLEX_ALIGNMENT_START</b>.
7054 ///
7055 ///
7056 ///
7057 /// Format of the return value [`ArkUI_AttributeItem`]:
7058 ///
7059 /// .value[0].i32: vertical alignment mode of child components. The parameter type is [`ArkUI_FlexAlignment`].
7060 pub const NODE_COLUMN_JUSTIFY_CONTENT: ArkUI_NodeAttributeType =
7061 ArkUI_NodeAttributeType(1006001);
7062 /// Defines the vertical alignment mode of child components in the row.
7063 /// This attribute can be set, reset, and obtained as required through APIs.
7064 ///
7065 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7066 ///
7067 /// .value[0].i32: vertical alignment mode of child components.
7068 /// The parameter type is [`ArkUI_VerticalAlignment`].
7069 ///
7070 /// Default value: <b>ARKUI_VERTICAL_ALIGNMENT_CENTER</b>.
7071 ///
7072 ///
7073 ///
7074 /// Format of the return value [`ArkUI_AttributeItem`]:
7075 ///
7076 /// .value[0].i32: vertical alignment mode of child components.
7077 /// The parameter type is [`ArkUI_VerticalAlignment`].
7078 pub const NODE_ROW_ALIGN_ITEMS: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1007000);
7079 /// Defines the horizontal alignment mode of child components in the row.
7080 /// This attribute can be set, reset, and obtained as required through APIs.
7081 ///
7082 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7083 ///
7084 /// .value[0].i32: horizontal alignment mode of child components.
7085 /// The parameter type is [`ArkUI_FlexAlignment`].
7086 ///
7087 /// Default value: <b>ARKUI_FLEX_ALIGNMENT_START</b>.
7088 ///
7089 ///
7090 ///
7091 /// Format of the return value [`ArkUI_AttributeItem`]:
7092 ///
7093 /// .value[0].i32: horizontal alignment mode of child components.
7094 /// The parameter type is [`ArkUI_FlexAlignment`].
7095 pub const NODE_ROW_JUSTIFY_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1007001);
7096 /// Defines the flex attribute. This attribute can be set, reset, and obtained as required through APIs.
7097 ///
7098 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7099 ///
7100 /// .value[0]?.i32: direction in which flex items are arranged. The parameter type is [`ArkUI_FlexDirection`].
7101 /// The default value is <b>ARKUI_FLEX_DIRECTION_ROW</b>.
7102 ///
7103 /// .value[1]?.i32: how the flex items are wrapped. The parameter type is [`ArkUI_FlexWrap`].
7104 /// The default value is <b>ARKUI_FLEX_WRAP_NO_WRAP</b>.
7105 ///
7106 /// .value[2]?.i32: alignment mode along the main axis. The parameter type is [`ArkUI_FlexAlignment`].
7107 /// The default value is <b>ARKUI_FLEX_ALIGNMENT_START</b>.
7108 ///
7109 /// .value[3]?.i32: alignment mode along the cross axis. The parameter type is [`ArkUI_ItemAlignment`].
7110 /// The default value is <b>ARKUI_ITEM_ALIGNMENT_START</b>.
7111 ///
7112 /// .value[4]?.i32: alignment mode along the cross axis for multi-line content. The parameter type is
7113 /// [`ArkUI_FlexAlignment`]. The default value is <b>ARKUI_FLEX_ALIGNMENT_START</b>.
7114 ///
7115 ///
7116 ///
7117 /// Format of the return value [`ArkUI_AttributeItem`]:
7118 ///
7119 /// .value[0].i32: direction in which flex items are arranged.
7120 ///
7121 /// .value[1].i32: how the flex items are wrapped.
7122 ///
7123 /// .value[2].i32: alignment mode along the main axis.
7124 ///
7125 /// .value[3].i32: alignment mode along the cross axis.
7126 ///
7127 /// .value[4].i32: alignment mode along the cross axis for multi-line content.
7128 pub const NODE_FLEX_OPTION: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1008000);
7129 /// Sets whether the component is being refreshed.
7130 /// This attribute can be set and obtained as required through APIs.
7131 ///
7132 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7133 ///
7134 /// .value[0].i32: The parameter type is 1 or 0.
7135 ///
7136 ///
7137 /// Format of the return value [`ArkUI_AttributeItem`]:
7138 ///
7139 /// .value[0].i32: The parameter type is 1 or 0.
7140 pub const NODE_REFRESH_REFRESHING: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1009000);
7141 /// Sets the custom content in the pull-down area.
7142 /// This attribute can be set, reset, and obtained as required through APIs.
7143 ///
7144 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7145 ///
7146 /// .object: The parameter type is [`ArkUI_NodeHandle`].
7147 pub const NODE_REFRESH_CONTENT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1009001);
7148 /// Set the pull-down hand coefficient.
7149 /// This attribute can be set, reset, and obtained as required through APIs.
7150 ///
7151 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7152 ///
7153 /// .value[0].f32:Pull-down hand coefficient, valid value between 0 and 1.
7154 ///
7155 ///
7156 /// Format of the return value [`ArkUI_AttributeItem`]:
7157 ///
7158 /// .value[0].f32:Pull-down hand coefficient, valid value between 0 and 1.
7159 pub const NODE_REFRESH_PULL_DOWN_RATIO: ArkUI_NodeAttributeType =
7160 ArkUI_NodeAttributeType(1009002);
7161 /// Sets the pull-down offset that initiates a refresh.
7162 /// This attribute can be set, reset, and obtained as required through APIs.
7163 ///
7164 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7165 ///
7166 /// .value[0].f32: pull-down offset, in vp. The default value is <b>64vp</b>.
7167 ///
7168 ///
7169 /// Format of the return value [`ArkUI_AttributeItem`]:
7170 ///
7171 /// .value[0].f32: pull-down offset, in vp. The default value is <b>64vp</b>.
7172 pub const NODE_REFRESH_OFFSET: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1009003);
7173 /// Sets whether to initiate a refresh when the pull-down distance exceeds the value of <b>refreshOffset</b>.
7174 /// This attribute can be set, reset, and obtained as required through APIs.
7175 ///
7176 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7177 ///
7178 /// .value[0].i32: whether to initiate a refresh. The value <b>true</b> means to initiate a refresh, and
7179 /// <b>false</b> means the opposite.
7180 ///
7181 ///
7182 /// Format of the return value [`ArkUI_AttributeItem`]:
7183 ///
7184 /// .value[0].i32: whether to initiate a refresh. The value <b>1</b> means to initiate a refresh, and
7185 /// <b>0</b> means the opposite.
7186 pub const NODE_REFRESH_PULL_TO_REFRESH: ArkUI_NodeAttributeType =
7187 ArkUI_NodeAttributeType(1009004);
7188 /// Defines the main axis direction of the <b><WaterFlow></b> component layout.
7189 /// This attribute can be set, reset, and obtained as required through APIs.
7190 ///
7191 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7192 ///
7193 /// .value[0].i32: main axis direction. The parameter type is [`ArkUI_FlexDirection`].
7194 ///
7195 ///
7196 /// Format of the return value [`ArkUI_AttributeItem`]:
7197 ///
7198 /// .value[0].i32: main axis direction. The parameter type is [`ArkUI_FlexDirection`].
7199 pub const NODE_WATER_FLOW_LAYOUT_DIRECTION: ArkUI_NodeAttributeType =
7200 ArkUI_NodeAttributeType(1010000);
7201 /// Sets the number of columns in the water flow layout. If this parameter is not set, one column is used
7202 /// by default. This attribute can be set, reset, and obtained as required through APIs.
7203 /// For example, <b>'1fr 1fr 2fr'</b> indicates three columns, with the first column taking up 1/4 of the parent
7204 /// component's full width, the second column 1/4, and the third column 2/4.
7205 /// You can use <b>columnsTemplate('repeat(auto-fill,track-size)')</b> to automatically calculate the number of
7206 /// columns based on the specified column width <b>track-size</b>.
7207 /// <b>repeat</b> and <b>auto-fill</b> are keywords. The units for <b>track-size</b> can be px, vp (default), %,
7208 /// or a valid number.
7209 ///
7210 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7211 ///
7212 /// .string: number of columns in the layout.
7213 ///
7214 ///
7215 ///
7216 /// Format of the return value [`ArkUI_AttributeItem`]:
7217 ///
7218 /// .string: number of columns in the layout.
7219 pub const NODE_WATER_FLOW_COLUMN_TEMPLATE: ArkUI_NodeAttributeType =
7220 ArkUI_NodeAttributeType(1010001);
7221 /// Sets the number of rows in the water flow layout. If this parameter is not set, one row is used
7222 /// by default. This attribute can be set, reset, and obtained as required through APIs.
7223 /// For example, <b>'1fr 1fr 2fr'</b> indicates three rows, with the first row taking up 1/4 of the parent
7224 /// component's full height, the second row 1/4, and the third row 2/4.
7225 /// You can use <b>rowsTemplate('repeat(auto-fill,track-size)')</b> to automatically calculate the number of rows
7226 /// based on the specified row height <b>track-size</b>.
7227 /// <b>repeat</b> and <b>auto-fill</b> are keywords. The units for <b>track-size</b> can be px, vp (default), %,
7228 /// or a valid number.
7229 ///
7230 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7231 ///
7232 /// .string: number of rows in the layout.
7233 ///
7234 ///
7235 ///
7236 /// Format of the return value [`ArkUI_AttributeItem`]:
7237 ///
7238 /// .string: number of rows in the layout.
7239 pub const NODE_WATER_FLOW_ROW_TEMPLATE: ArkUI_NodeAttributeType =
7240 ArkUI_NodeAttributeType(1010002);
7241 /// Sets the gap between columns.
7242 /// This attribute can be set, reset, and obtained as required through APIs.
7243 ///
7244 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7245 ///
7246 /// .value[0].f32: gap between columns, in vp.
7247 ///
7248 ///
7249 ///
7250 /// Format of the return value [`ArkUI_AttributeItem`]:
7251 ///
7252 /// .value[0].f32: gap between columns, in vp.
7253 pub const NODE_WATER_FLOW_COLUMN_GAP: ArkUI_NodeAttributeType =
7254 ArkUI_NodeAttributeType(1010003);
7255 /// Sets the gap between rows.
7256 /// This attribute can be set, reset, and obtained as required through APIs.
7257 ///
7258 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7259 ///
7260 /// .value[0].f32: gap between lines, in vp.
7261 ///
7262 ///
7263 ///
7264 /// Format of the return value [`ArkUI_AttributeItem`]:
7265 ///
7266 /// .value[0].f32: gap between lines, in vp.
7267 pub const NODE_WATER_FLOW_ROW_GAP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1010004);
7268 /// Defines the water flow section configuration.
7269 /// This attribute can be set, reset, and obtained as required through APIs.
7270 ///
7271 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7272 ///
7273 /// .value[0].i32: An index calculated from 0 is converted to an integer,
7274 /// indicating that you want to start changing the position of the group.
7275 /// .object: [`ArkUI_WaterFlowSectionOption`] object.
7276 ///
7277 ///
7278 ///
7279 /// Format of the return value [`ArkUI_AttributeItem`]:
7280 ///
7281 /// .object: [`ArkUI_WaterFlowSectionOption`] object.
7282 pub const NODE_WATER_FLOW_SECTION_OPTION: ArkUI_NodeAttributeType =
7283 ArkUI_NodeAttributeType(1010005);
7284 /// Defines the water flow adapter. The attribute can be set, reset, and obtained as required through APIs.
7285 ///
7286 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7287 ///
7288 /// .object: [`ArkUI_NodeAdapter`] object as the adapter.
7289 pub const NODE_WATER_FLOW_NODE_ADAPTER: ArkUI_NodeAttributeType =
7290 ArkUI_NodeAttributeType(1010006);
7291 /// Sets the number of cached items in the water flow adapter.
7292 /// This attribute can be set, reset, and obtained as required through APIs.
7293 ///
7294 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7295 ///
7296 /// value[0].i32:number of cached items in the water flow adapter.
7297 ///
7298 /// .value[1]?.i32:whether to the cached items will be displayed, 0: not displayed, 1: displayed, default value: 0.
7299 /// This parameter is supported since API version 16.
7300 ///
7301 ///
7302 ///
7303 /// Format of the return value [`ArkUI_AttributeItem`]:
7304 ///
7305 /// .value[0].i32: number of cached items in the water flow adapter.
7306 ///
7307 /// .value[1].i32: whether to the cached items will be displayed, 0: not displayed, 1: displayed, default value: 0.
7308 /// This parameter is supported since API version 16.
7309 pub const NODE_WATER_FLOW_CACHED_COUNT: ArkUI_NodeAttributeType =
7310 ArkUI_NodeAttributeType(1010007);
7311 /// Set the custom display component at the end of the waterfall flow component.
7312 ///
7313 /// Attribute setting method [`ArkUI_AttributeItem`] parameter format:
7314 ///
7315 /// .object: Parameter type [`ArkUI_NodeHandle`].
7316 pub const NODE_WATER_FLOW_FOOTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1010008);
7317 /// Scroll to the specified index.
7318 ///
7319 /// When activating the smooth animation, all items passed through will be loaded and layout calculated, which can
7320 /// lead to performance issues when loading a large number of items.
7321 ///
7322 ///
7323 ///
7324 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7325 ///
7326 /// .value[0].i32:The index value of the target element to be slid to in the current container.
7327 ///
7328 /// .value[1]?.i32:Set whether there is an action when sliding to the index value of a list item in the list, where
7329 /// 1 indicates an action and 0 indicates no action. Default value is 0。
7330 ///
7331 /// .value[2]?.i32:Specify the alignment of the sliding element with the current container,The parameter type is
7332 /// [`ArkUI_ScrollAlignment`]. Default value is </b>ARKUI_SCROLL_ALIGNMENT_START</b>。
7333 pub const NODE_WATER_FLOW_SCROLL_TO_INDEX: ArkUI_NodeAttributeType =
7334 ArkUI_NodeAttributeType(1010009);
7335 /// Defines the size constraints to apply to water flow items.
7336 /// This attribute can be set, reset, and obtained as required through APIs.
7337 ///
7338 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7339 ///
7340 /// .value[0].f32: minimum width, in vp.
7341 ///
7342 /// .value[1].f32: maximum width, in vp.
7343 ///
7344 /// .value[2].f32: minimum height, in vp.
7345 ///
7346 /// .value[3].f32: maximum height, in vp.
7347 ///
7348 ///
7349 ///
7350 /// Format of the return value [`ArkUI_AttributeItem`]:
7351 ///
7352 /// .value[0].f32: minimum width, in vp.
7353 ///
7354 /// .value[1].f32: maximum width, in vp.
7355 ///
7356 /// .value[2].f32: minimum height, in vp.
7357 ///
7358 /// .value[3].f32: maximum height, in vp.
7359 pub const NODE_WATER_FLOW_ITEM_CONSTRAINT_SIZE: ArkUI_NodeAttributeType =
7360 ArkUI_NodeAttributeType(1010010);
7361 /// Defines the layout mode of the <b><WaterFlow></b> component.
7362 /// This attribute can be set, reset, and obtained as required through APIs.
7363 ///
7364 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7365 ///
7366 /// .value[0].i32: waterflow layout mode. The parameter type is [`ArkUI_WaterFlowLayoutMode`].
7367 ///
7368 ///
7369 /// Format of the return value [`ArkUI_AttributeItem`]:
7370 ///
7371 /// .value[0].i32: waterflow layout mode. The parameter type is [`ArkUI_WaterFlowLayoutMode`].
7372 ///
7373 /// Available since API-level: 18
7374 #[cfg(feature = "api-18")]
7375 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
7376 pub const NODE_WATER_FLOW_LAYOUT_MODE: ArkUI_NodeAttributeType =
7377 ArkUI_NodeAttributeType(1010011);
7378 /// Set the auxiliary line in the RelativeContaine container, supporting property setting,
7379 /// property reset and property acquisition interfaces.
7380 ///
7381 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
7382 ///
7383 /// .object: Auxiliary lines within the RelativeContaine container:
7384 ///
7385 ///
7386 ///
7387 /// Attribute acquisition method return value [`ArkUI_AttributeItem`] format:
7388 ///
7389 /// .object: Auxiliary lines within the RelativeContaine container:
7390 pub const NODE_RELATIVE_CONTAINER_GUIDE_LINE: ArkUI_NodeAttributeType =
7391 ArkUI_NodeAttributeType(1012000);
7392 /// Sets the barrier within the RelativeContaine container and supports property setting,
7393 /// property reset and property acquisition interfaces.
7394 ///
7395 /// Attribute setting method parameter [`ArkUI_AttributeItem`] format:
7396 ///
7397 /// .object: Auxiliary lines within the RelativeContaine container:
7398 ///
7399 ///
7400 ///
7401 /// Attribute acquisition method return value [`ArkUI_AttributeItem`] format:
7402 ///
7403 /// .object: Barrier within the RelativeContaine container:
7404 pub const NODE_RELATIVE_CONTAINER_BARRIER: ArkUI_NodeAttributeType =
7405 ArkUI_NodeAttributeType(1012001);
7406 /// Sets the number of columns in the grid layout. If this parameter is not set, one column is used
7407 /// by default. This attribute can be set, reset, and obtained as required through APIs.
7408 /// For example, <b>'1fr 1fr 2fr'</b> indicates three columns, with the first column taking up 1/4 of the parent
7409 /// component's full width, the second column 1/4, and the third column 2/4.
7410 /// You can use <b>columnsTemplate('repeat(auto-fill,track-size)')</b> to automatically calculate the number of
7411 /// columns based on the specified column width <b>track-size</b>.
7412 /// <b>repeat</b> and <b>auto-fill</b> are keywords. The units for <b>track-size</b> can be px, vp (default), %,
7413 /// or a valid number.
7414 ///
7415 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7416 ///
7417 /// .string: number of columns in the layout.
7418 ///
7419 ///
7420 ///
7421 /// Format of the return value [`ArkUI_AttributeItem`]:
7422 ///
7423 /// .string: number of columns in the layout.
7424 pub const NODE_GRID_COLUMN_TEMPLATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013000);
7425 /// Sets the number of rows in the grid layout. If this parameter is not set, one row is used
7426 /// by default. This attribute can be set, reset, and obtained as required through APIs.
7427 /// For example, <b>'1fr 1fr 2fr'</b> indicates three rows, with the first row taking up 1/4 of the parent
7428 /// component's full height, the second row 1/4, and the third row 2/4.
7429 /// You can use <b>rowsTemplate('repeat(auto-fill,track-size)')</b> to automatically calculate the number of rows
7430 /// based on the specified row height <b>track-size</b>.
7431 /// <b>repeat</b> and <b>auto-fill</b> are keywords. The units for <b>track-size</b> can be px, vp (default), %,
7432 /// or a valid number.
7433 ///
7434 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7435 ///
7436 /// .string: number of rows in the layout.
7437 ///
7438 ///
7439 ///
7440 /// Format of the return value [`ArkUI_AttributeItem`]:
7441 ///
7442 /// .string: number of rows in the layout.
7443 pub const NODE_GRID_ROW_TEMPLATE: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013001);
7444 /// Sets the gap between columns. This attribute can be set, reset, and obtained as required through APIs.
7445 ///
7446 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7447 ///
7448 /// .value[0].f32: gap between columns, in vp.
7449 ///
7450 ///
7451 ///
7452 /// Format of the return value [`ArkUI_AttributeItem`]:
7453 ///
7454 /// .value[0].f32: gap between columns, in vp.
7455 pub const NODE_GRID_COLUMN_GAP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013002);
7456 /// Sets the gap between rows. This attribute can be set, reset, and obtained as required through APIs.
7457 ///
7458 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7459 ///
7460 /// .value[0].f32: gap between lines, in vp.
7461 ///
7462 ///
7463 ///
7464 /// Format of the return value [`ArkUI_AttributeItem`]:
7465 ///
7466 /// .value[0].f32: gap between lines, in vp.
7467 pub const NODE_GRID_ROW_GAP: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013003);
7468 /// Defines the grid adapter. The attribute can be set, reset, and obtained as required through APIs.
7469 ///
7470 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7471 ///
7472 /// .object: [`ArkUI_NodeAdapter`] object as the adapter.
7473 pub const NODE_GRID_NODE_ADAPTER: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013004);
7474 /// Sets the number of cached items in the grid adapter.
7475 /// This attribute can be set, reset, and obtained as required through APIs.
7476 ///
7477 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7478 ///
7479 /// .value[0].i32: number of cached items in the grid adapter.
7480 pub const NODE_GRID_CACHED_COUNT: ArkUI_NodeAttributeType = ArkUI_NodeAttributeType(1013005);
7481 /// Defines the column width of the text picker.
7482 /// This attribute can be set, reset, and obtained as required through APIs.
7483 ///
7484 /// Format of the [`ArkUI_AttributeItem`] parameter for setting the attribute:
7485 ///
7486 /// .value[0].f32: percentage of total width. The default value is that all colulmns are equal width.
7487 ///
7488 /// .value[1]?.f32: percentage of total width. The default value is that all colulmns are equal width.
7489 ///
7490 /// .value[2]?.f32: percentage of total width. The default value is that all colulmns are equal width.
7491 ///
7492 /// ...
7493 ///
7494 /// .value[n]?.f32: percentage of total width. The default value is that all colulmns are equal width.
7495 ///
7496 ///
7497 ///
7498 /// Format of the return value [`ArkUI_AttributeItem`]:
7499 ///
7500 /// value[0].f32: percentage of total width.
7501 ///
7502 /// value[1].f32: percentage of total width.
7503 ///
7504 /// value[2].f32: percentage of total width.
7505 ///
7506 /// ...
7507 ///
7508 /// value[n].f32: percentage of total width.
7509 ///
7510 ///
7511 ///
7512 /// Available since API-level: 18
7513 #[cfg(feature = "api-18")]
7514 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
7515 pub const NODE_TEXT_PICKER_COLUMN_WIDTHS: ArkUI_NodeAttributeType =
7516 ArkUI_NodeAttributeType(15009);
7517}
7518#[repr(transparent)]
7519/// Defines the ArkUI style attributes that can be set on the native side.
7520///
7521///
7522/// Available since API-level: 12
7523#[cfg(feature = "api-12")]
7524#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
7525#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
7526pub struct ArkUI_NodeAttributeType(pub ::core::ffi::c_uint);
7527/// Defines the parameter type of the component callback event.
7528///
7529///
7530/// Available since API-level: 12
7531#[cfg(feature = "api-12")]
7532#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
7533#[repr(C)]
7534pub struct ArkUI_NodeComponentEvent {
7535 /// Data array object.
7536 pub data: [ArkUI_NumberValue; 12usize],
7537}
7538/// Defines the string type parameter used by the component callback event.
7539///
7540///
7541/// Available since API-level: 12
7542#[cfg(feature = "api-12")]
7543#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
7544#[repr(C)]
7545#[derive(Debug, Copy, Clone)]
7546pub struct ArkUI_StringAsyncEvent {
7547 /// String.
7548 pub pStr: *const ::core::ffi::c_char,
7549}
7550/// Defines a hybrid data structure for component events.
7551///
7552///
7553/// Available since API-level: 15
7554#[cfg(feature = "api-15")]
7555#[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
7556#[repr(C)]
7557#[derive(Debug, Copy, Clone)]
7558pub struct ArkUI_TextChangeEvent {
7559 /// String data
7560 pub pStr: *const ::core::ffi::c_char,
7561 /// Extended string data
7562 pub pExtendStr: *const ::core::ffi::c_char,
7563 /// Numeric data
7564 pub number: i32,
7565}
7566#[cfg(feature = "api-12")]
7567#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
7568impl ArkUI_NodeEventType {
7569 /// Defines the gesture event type.
7570 ///
7571 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7572 /// [`ArkUI_UIInputEvent`].
7573 pub const NODE_TOUCH_EVENT: ArkUI_NodeEventType = ArkUI_NodeEventType(0);
7574 /// Defines the mount event.
7575 ///
7576 /// This event is triggered when the component is mounted and displayed.
7577 ///
7578 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7579 /// [`ArkUI_NodeComponentEvent`].
7580 ///
7581 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7582 pub const NODE_EVENT_ON_APPEAR: ArkUI_NodeEventType = ArkUI_NodeEventType(1);
7583 /// Defines the unmount event.
7584 ///
7585 /// This event is triggered when the component is unmounted and hidden.
7586 ///
7587 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7588 /// [`ArkUI_NodeComponentEvent`].
7589 ///
7590 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7591 pub const NODE_EVENT_ON_DISAPPEAR: ArkUI_NodeEventType = ArkUI_NodeEventType(2);
7592 /// Defines the area change event.
7593 ///
7594 /// This event is triggered when the component's size, position, or any other attribute that may
7595 /// affect its display area changes.
7596 ///
7597 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7598 /// [`ArkUI_NodeComponentEvent`].
7599 ///
7600 /// [`ArkUI_NodeComponentEvent`] contains 12 parameters:
7601 ///
7602 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: original width of the target element, in vp.
7603 /// The value type is number.
7604 ///
7605 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: original height of the target element, in vp.
7606 /// The value type is number.
7607 ///
7608 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b>: original X coordinate of the target element's upper left corner
7609 /// relative to the parent element's, in vp. The value type is number.
7610 ///
7611 /// <b>ArkUI_NodeComponentEvent.data[3].f32</b>: original Y coordinate of the target element's upper left corner
7612 /// relative to the parent element's, in vp. The value type is number.
7613 ///
7614 /// <b>ArkUI_NodeComponentEvent.data[4].f32</b>: original X coordinate of the target element's upper left corner
7615 /// relative to the page's, in vp. The value type is number.
7616 ///
7617 /// <b>ArkUI_NodeComponentEvent.data[5].f32</b>: original Y coordinate of the target element's upper left corner
7618 /// relative to the page's, in vp. The value type is number.
7619 ///
7620 /// <b>ArkUI_NodeComponentEvent.data[6].f32</b>: new width of the target element, in vp. The value is a number.
7621 ///
7622 /// <b>ArkUI_NodeComponentEvent.data[7].f32</b>: new height of the target element, in vp. The value is a number.
7623 ///
7624 /// <b>ArkUI_NodeComponentEvent.data[8].f32</b>: new X coordinate of the target element's upper left corner relative
7625 /// to the parent element's, in vp. The value type is number.
7626 ///
7627 /// <b>ArkUI_NodeComponentEvent.data[9].f32</b>: new Y coordinate of the target element's upper left corner relative
7628 /// to the parent element's, in vp. The value type is number.
7629 ///
7630 /// <b>ArkUI_NodeComponentEvent.data[10].f32</b>: new X coordinate of the target element's upper left corner relative
7631 /// to the page's, in vp. The value type is number.
7632 ///
7633 /// <b>ArkUI_NodeComponentEvent.data[11].f32</b>: new Y coordinate of the target element's upper left corner relative
7634 /// to the page's, in vp. The value type is number.
7635 pub const NODE_EVENT_ON_AREA_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(3);
7636 /// Defines the focus event.
7637 ///
7638 /// This event is triggered when the component obtains the focus.
7639 ///
7640 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7641 /// [`ArkUI_NodeComponentEvent`].
7642 ///
7643 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7644 pub const NODE_ON_FOCUS: ArkUI_NodeEventType = ArkUI_NodeEventType(4);
7645 /// Defines the blur event.
7646 ///
7647 /// This event is triggered when the component loses the focus.
7648 ///
7649 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7650 /// [`ArkUI_NodeComponentEvent`].
7651 ///
7652 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7653 pub const NODE_ON_BLUR: ArkUI_NodeEventType = ArkUI_NodeEventType(5);
7654 /// Defines the click event.
7655 ///
7656 /// This event is triggered when the component is clicked.
7657 ///
7658 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7659 /// [`ArkUI_NodeComponentEvent`].
7660 ///
7661 /// [`ArkUI_NodeComponentEvent`] contains 12 parameters:
7662 ///
7663 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: X coordinate of the click relative to the upper left corner of the
7664 /// clicked component's original area, in vp.
7665 ///
7666 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: Y coordinate of the click relative to the upper left corner of the
7667 /// clicked component's original area, in vp.
7668 ///
7669 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b>: event timestamp. It is the interval between the time when the event
7670 /// is triggered and the time when the system starts, in microseconds.
7671 ///
7672 /// <b>ArkUI_NodeComponentEvent.data[3].i32</b>: event input device. The value <b>1</b> indicates the mouse,
7673 /// <b>2</b> indicates the touchscreen, and <b>4</b> indicates the key.
7674 ///
7675 /// <b>ArkUI_NodeComponentEvent.data[4].f32</b>: X coordinate of the click relative to the upper left corner of the
7676 /// application window, in vp.
7677 ///
7678 /// <b>ArkUI_NodeComponentEvent.data[5].f32</b>: Y coordinate of the click relative to the upper left corner of the
7679 /// application window, in vp.
7680 ///
7681 /// <b>ArkUI_NodeComponentEvent.data[6].f32</b>: X coordinate of the click relative to the upper left corner of the
7682 /// application screen, in vp.
7683 ///
7684 /// <b>ArkUI_NodeComponentEvent.data[7].f32</b>: Y coordinate of the click relative to the upper left corner of the
7685 /// application screen, in vp.
7686 pub const NODE_ON_CLICK: ArkUI_NodeEventType = ArkUI_NodeEventType(6);
7687 /// Defines event interception.
7688 ///
7689 /// This event is triggered when the component is touched.
7690 ///
7691 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7692 /// [`ArkUI_UIInputEvent`].
7693 pub const NODE_ON_TOUCH_INTERCEPT: ArkUI_NodeEventType = ArkUI_NodeEventType(7);
7694 /// Defines the visible area change event.
7695 ///
7696 /// This event is triggered when the ratio of the component's visible area to its total area is greater than or less
7697 /// than the threshold.
7698 /// Before registering this event, you must set <b>NODE_VISIBLE_AREA_CHANGE_RATIO</b>.
7699 ///
7700 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7701 /// [`ArkUI_NodeComponentEvent`].
7702 ///
7703 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
7704 ///
7705 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: how the ratio of the component's visible area to its total area
7706 /// changes compared to the previous one. The value <b>1</b> indicates an increase, and <b>0</b> indicates a
7707 /// decrease.
7708 ///
7709 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: ratio of the component's visible area to its total area when this
7710 /// callback is invoked.
7711 pub const NODE_EVENT_ON_VISIBLE_AREA_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(8);
7712 /// Defines the event triggered when the mouse pointer is moved over or away from the component.
7713 ///
7714 ///
7715 ///
7716 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7717 /// [`ArkUI_NodeComponentEvent`].
7718 ///
7719 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
7720 ///
7721 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: whether the mouse pointer is hovered over the component.
7722 /// The value <b>1</b> indicates that the mouse pointer is hovered over the component, and <b>0</b> indicates that
7723 /// the mouse pointer is moved away from the component.
7724 pub const NODE_ON_HOVER: ArkUI_NodeEventType = ArkUI_NodeEventType(9);
7725 /// Defines the click event.
7726 ///
7727 /// This event is triggered when the component is clicked by a mouse device button or when the mouse pointer moves
7728 /// within the component.
7729 ///
7730 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7731 /// [`ArkUI_UIInputEvent`].
7732 pub const NODE_ON_MOUSE: ArkUI_NodeEventType = ArkUI_NodeEventType(10);
7733 /// Defines the attach event.
7734 ///
7735 /// This event is triggered when the component is attached.
7736 ///
7737 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7738 /// [`ArkUI_NodeComponentEvent`].
7739 ///
7740 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7741 pub const NODE_EVENT_ON_ATTACH: ArkUI_NodeEventType = ArkUI_NodeEventType(11);
7742 /// Defines the detach event.
7743 ///
7744 /// This event is triggered when the component is detached.
7745 ///
7746 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7747 /// [`ArkUI_NodeComponentEvent`].
7748 ///
7749 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
7750 pub const NODE_EVENT_ON_DETACH: ArkUI_NodeEventType = ArkUI_NodeEventType(12);
7751 /// Defines the accessibility action event.
7752 ///
7753 /// This event is triggered when The accessibility operation type has been set and
7754 /// corresponding operations have been carried out.
7755 ///
7756 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7757 /// [`ArkUI_NodeComponentEvent`].
7758 ///
7759 /// [`ArkUI_NodeComponentEvent`] contains one parameters:
7760 ///
7761 /// <b>ArkUI_NodeComponentEvent.data[0].u32</b>: accessibility action type,the union type is
7762 /// [`ArkUI_AccessibilityActionType`]
7763 pub const NODE_ON_ACCESSIBILITY_ACTIONS: ArkUI_NodeEventType = ArkUI_NodeEventType(13);
7764 /// Notifies the listener of the interaction state prior to a drop and drop operation.
7765 ///
7766 /// This event is triggered when a drag operation is about to start on a draggable item.
7767 ///
7768 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7769 /// [`ArkUI_NodeComponentEvent`].
7770 ///
7771 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
7772 ///
7773 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: corresponds to [`ArkUI_PreDragStatus`].
7774 pub const NODE_ON_PRE_DRAG: ArkUI_NodeEventType = ArkUI_NodeEventType(14);
7775 /// Called when the user starts to drag an ite
7776 ///
7777 /// A drag operation is recognized only when the dragged item is moved far enough.
7778 ///
7779 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7780 /// [`ArkUI_NodeEvent`] object.
7781 pub const NODE_ON_DRAG_START: ArkUI_NodeEventType = ArkUI_NodeEventType(15);
7782 /// Called when a dragged item enters the boundaries of the current component.
7783 ///
7784 /// The current component refers to the component that listens for this event.
7785 ///
7786 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7787 /// [`ArkUI_NodeEvent`] object.
7788 pub const NODE_ON_DRAG_ENTER: ArkUI_NodeEventType = ArkUI_NodeEventType(16);
7789 /// Called when a dragged item moves in the current component.
7790 ///
7791 /// The current component refers to the component that listens for this event.
7792 ///
7793 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7794 /// [`ArkUI_NodeEvent`] object.
7795 pub const NODE_ON_DRAG_MOVE: ArkUI_NodeEventType = ArkUI_NodeEventType(17);
7796 /// Called when a dragged item leaves the boundaries of the current component.
7797 ///
7798 /// The current component refers to the component that listens for this event.
7799 ///
7800 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7801 /// [`ArkUI_NodeEvent`] object.
7802 pub const NODE_ON_DRAG_LEAVE: ArkUI_NodeEventType = ArkUI_NodeEventType(18);
7803 /// Called when a dragged item is dropped on the current component.
7804 /// The component can obtain the drag data for processing through the callback.
7805 ///
7806 /// The current component refers to the component that listens for this event.
7807 ///
7808 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7809 /// [`ArkUI_NodeEvent`] object.
7810 pub const NODE_ON_DROP: ArkUI_NodeEventType = ArkUI_NodeEventType(19);
7811 /// Called when a drag operation ends.
7812 /// The drag source can obtain the drag result by registering this callback.
7813 ///
7814 /// A drag operation ends when the dragged item is released.
7815 /// When the event callback occurs, the [`ArkUI_DragEvent`] object can be obtained from the
7816 /// [`ArkUI_NodeEvent`] object.
7817 pub const NODE_ON_DRAG_END: ArkUI_NodeEventType = ArkUI_NodeEventType(20);
7818 /// Defines the event triggered when a key event occurs.
7819 ///
7820 /// The callback can be triggered during interactions with a focused window using an external keyboard or other input
7821 /// device.
7822 ///
7823 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7824 /// [`ArkUI_NodeComponentEvent`].
7825 ///
7826 ///
7827 ///
7828 /// Available since API-level: 14
7829 #[cfg(feature = "api-14")]
7830 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
7831 pub const NODE_ON_KEY_EVENT: ArkUI_NodeEventType = ArkUI_NodeEventType(21);
7832 /// Defines the event triggered before the input method responds to the key action.
7833 ///
7834 /// If the return value of this callback is <b>true</b>, it is considered that the key event has been consumed, and
7835 /// subsequent event callbacks (<b>keyboardShortcut</b>, input method events, <b>onKeyEvent</b>) will be intercepted
7836 /// and no longer triggered.
7837 /// The callback can be triggered during interactions with a focused window using an external keyboard or other input
7838 /// device.
7839 ///
7840 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7841 /// [`ArkUI_NodeComponentEvent`].
7842 ///
7843 ///
7844 ///
7845 /// Available since API-level: 14
7846 #[cfg(feature = "api-14")]
7847 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
7848 pub const NODE_ON_KEY_PRE_IME: ArkUI_NodeEventType = ArkUI_NodeEventType(22);
7849 /// Defines the event triggered when the bound component receives a focus axis event after gaining focus.
7850 ///
7851 /// The event callback is triggered by interactions with a joystick and a focused component.
7852 ///
7853 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7854 /// [`ArkUI_UIInputEvent`].
7855 ///
7856 ///
7857 ///
7858 /// Available since API-level: 15
7859 #[cfg(feature = "api-15")]
7860 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
7861 pub const NODE_ON_FOCUS_AXIS: ArkUI_NodeEventType = ArkUI_NodeEventType(23);
7862 /// Dispatch key event on the component node.
7863 ///
7864 /// When the component node receives a key event, this callback will be triggered instead of dispatching event to its
7865 /// children.
7866 ///
7867 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7868 /// [`ArkUI_NodeComponentEvent`].
7869 ///
7870 ///
7871 ///
7872 /// Available since API-level: 15
7873 #[cfg(feature = "api-15")]
7874 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
7875 pub const NODE_DISPATCH_KEY_EVENT: ArkUI_NodeEventType = ArkUI_NodeEventType(24);
7876 /// Defines the event triggered when the bound component receives an axis event.
7877 ///
7878 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7879 /// [`ArkUI_UIInputEvent`].
7880 ///
7881 ///
7882 ///
7883 /// Available since API-level: 17
7884 #[cfg(feature = "api-17")]
7885 #[cfg_attr(docsrs, doc(cfg(feature = "api-17")))]
7886 pub const NODE_ON_AXIS: ArkUI_NodeEventType = ArkUI_NodeEventType(25);
7887 /// Defines the event triggered when the bound component is clicked.
7888 ///
7889 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7890 /// [`ArkUI_UIInputEvent`].
7891 ///
7892 ///
7893 ///
7894 /// Available since API-level: 18
7895 #[cfg(feature = "api-18")]
7896 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
7897 pub const NODE_ON_CLICK_EVENT: ArkUI_NodeEventType = ArkUI_NodeEventType(26);
7898 /// Defines the event triggered when the mouse pointer hovers over or moves away from a component.
7899 ///
7900 /// This event is triggered when the mouse pointer enters or leaves the component's bounding box.
7901 ///
7902 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7903 /// [`ArkUI_UIInputEvent`].
7904 ///
7905 ///
7906 ///
7907 /// Available since API-level: 17
7908 #[cfg(feature = "api-17")]
7909 #[cfg_attr(docsrs, doc(cfg(feature = "api-17")))]
7910 pub const NODE_ON_HOVER_EVENT: ArkUI_NodeEventType = ArkUI_NodeEventType(27);
7911 /// Sets the callback for the NODE_EVENT_ON_VISIBLE_AREA_CHANGE event, which limits the callback interval.
7912 ///
7913 /// The callback is triggered when the ratio of the component's visible area to its total area is greater than or
7914 /// less than the threshold. Before registering the callback, you must configure the threshold and update interval
7915 /// using <b>NODE_VISIBLE_AREA_APPROXIMATE_CHANGE_RATIO</b>.
7916 ///
7917 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7918 /// [`ArkUI_NodeComponentEvent`].
7919 ///
7920 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
7921 ///
7922 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: how the ratio of the component's visible area to its total area
7923 /// changes compared to the previous one. The value <b>1</b> indicates an increase, and <b>0</b> indicates
7924 /// a decrease.
7925 ///
7926 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: ratio of the component's visible area to its total area
7927 /// when this callback is invoked.
7928 ///
7929 ///
7930 ///
7931 /// Available since API-level: 17
7932 #[cfg(feature = "api-17")]
7933 #[cfg_attr(docsrs, doc(cfg(feature = "api-17")))]
7934 pub const NODE_VISIBLE_AREA_APPROXIMATE_CHANGE_EVENT: ArkUI_NodeEventType =
7935 ArkUI_NodeEventType(28);
7936 /// Defines the hover event.
7937 ///
7938 /// The event is triggered when the pointer is hovered by a pen device.
7939 /// within the component.
7940 ///
7941 /// When the event callback occurs, the [`ArkUI_NodeEvent`] object can be obtained from the
7942 /// [`ArkUI_UIInputEvent`] object.
7943 ///
7944 ///
7945 /// Available since API-level: 15
7946 #[cfg(feature = "api-15")]
7947 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
7948 pub const NODE_ON_HOVER_MOVE: ArkUI_NodeEventType = ArkUI_NodeEventType(29);
7949 /// Triggers onDetectResultUpdate callback
7950 /// when the text is set to TextDataDetectorConfig and recognized successfully.
7951 ///
7952 /// Trigger this event when TextDataDetectorConfig is set and recognized successfully.
7953 ///
7954 /// When the event callback occurs, the event parameter[`ArkUI_NodeEvent`]The union type in the object is
7955 /// [`ArkUI_StringAsyncEvent`].
7956 ///
7957 /// [`ArkUI_StringAsyncEvent`]contains 1 parameter
7958 ///
7959 /// <b>ArkUI_StringAsyncEvent.pStr</b>:Indicates the result of text recognition, in Json format.
7960 pub const NODE_TEXT_ON_DETECT_RESULT_UPDATE: ArkUI_NodeEventType = ArkUI_NodeEventType(1000);
7961 /// Defines the image loading success event.
7962 ///
7963 /// This event is triggered when an image is successfully loaded or decoded.
7964 ///
7965 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7966 /// [`ArkUI_NodeComponentEvent`].
7967 ///
7968 /// [`ArkUI_NodeComponentEvent`] contains nine parameters:
7969 ///
7970 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: loading status. The value <b>0</b> indicates that the image is
7971 /// loaded successfully, and the value <b>1</b> indicates that the image is decoded successfully.
7972 ///
7973 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: width of the image, in px.
7974 ///
7975 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b>: height of the image, in px.
7976 ///
7977 /// <b>ArkUI_NodeComponentEvent.data[3].f32</b>: width of the component, in px.
7978 ///
7979 /// <b>ArkUI_NodeComponentEvent.data[4].f32</b>: height of the component, in px.
7980 ///
7981 /// <b>ArkUI_NodeComponentEvent.data[5].f32</b>: offset of the rendered content relative to the component on the
7982 /// x-axis, in px.
7983 ///
7984 /// <b>ArkUI_NodeComponentEvent.data[6].f32</b>: offset of the rendered content relative to the component on the
7985 /// y-axis, in px.
7986 ///
7987 /// <b>ArkUI_NodeComponentEvent.data[7].f32</b>: actual rendered width of the image, in px.
7988 ///
7989 /// <b>ArkUI_NodeComponentEvent.data[8].f32</b>: actual rendered height of the image, in px.
7990 pub const NODE_IMAGE_ON_COMPLETE: ArkUI_NodeEventType = ArkUI_NodeEventType(4000);
7991 /// Defines the image loading failure event.
7992 ///
7993 /// This event is triggered when an error occurs during image loading.
7994 ///
7995 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
7996 /// [`ArkUI_NodeComponentEvent`].
7997 ///
7998 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
7999 ///
8000 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>error code:
8001 ///
8002 /// 401: The image could not be obtained because the image path is invalid.
8003 ///
8004 /// 103101: The image format is not supported.
8005 pub const NODE_IMAGE_ON_ERROR: ArkUI_NodeEventType = ArkUI_NodeEventType(4001);
8006 /// Defines the SVG animation playback completion event.
8007 ///
8008 /// This event is triggered when the animation playback in the loaded SVG image is complete.
8009 ///
8010 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8011 /// [`ArkUI_NodeComponentEvent`].
8012 ///
8013 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
8014 pub const NODE_IMAGE_ON_SVG_PLAY_FINISH: ArkUI_NodeEventType = ArkUI_NodeEventType(4002);
8015 /// Defines image download process event.
8016 ///
8017 /// This event is triggered when downloading webpage images from page components.
8018 ///
8019 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8020 /// [`ArkUI_NodeComponentEvent`].
8021 ///
8022 /// [`ArkUI_NodeComponentEvent`] contains two parameter:
8023 ///
8024 /// <b>ArkUI_NodeComponentEvent.data[0].u32</b>: the num of bytes downloaded.
8025 ///
8026 /// <b>ArkUI_NodeComponentEvent.data[1].u32</b>: the total number of bytes to download.
8027 pub const NODE_IMAGE_ON_DOWNLOAD_PROGRESS: ArkUI_NodeEventType = ArkUI_NodeEventType(4003);
8028 /// Defines the event triggered when the toggle status changes.
8029 ///
8030 ///
8031 ///
8032 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8033 /// [`ArkUI_NodeComponentEvent`].
8034 ///
8035 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8036 ///
8037 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: toggle status. <b>1</b>: on; <b>0</b>: off.
8038 pub const NODE_TOGGLE_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(5000);
8039 /// Defines the event triggered when the text input content changes.
8040 ///
8041 ///
8042 ///
8043 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8044 /// [`ArkUI_StringAsyncEvent`].
8045 ///
8046 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8047 ///
8048 /// <b>ArkUI_StringAsyncEvent.pStr</b>: text input.
8049 pub const NODE_TEXT_INPUT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(7000);
8050 /// Defines the event triggered when the Enter key of the text input method is pressed.
8051 ///
8052 ///
8053 ///
8054 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8055 /// [`ArkUI_NodeComponentEvent`].
8056 ///
8057 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8058 ///
8059 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: Enter key type of the input method.
8060 pub const NODE_TEXT_INPUT_ON_SUBMIT: ArkUI_NodeEventType = ArkUI_NodeEventType(7001);
8061 /// Defines the event triggered when the cut button on the pasteboard, which displays when the text box
8062 /// is long pressed, is clicked.
8063 ///
8064 ///
8065 ///
8066 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8067 /// [`ArkUI_StringAsyncEvent`].
8068 ///
8069 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8070 ///
8071 /// <b>ArkUI_StringAsyncEvent.pStr</b>: text that is cut.
8072 pub const NODE_TEXT_INPUT_ON_CUT: ArkUI_NodeEventType = ArkUI_NodeEventType(7002);
8073 /// Defines the event triggered when the paste button on the pasteboard, which displays when the text box
8074 /// is long pressed, is clicked.
8075 ///
8076 ///
8077 ///
8078 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8079 /// [`ArkUI_StringAsyncEvent`].
8080 ///
8081 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8082 ///
8083 /// <b>ArkUI_StringAsyncEvent.pStr</b>: text that is pasted
8084 pub const NODE_TEXT_INPUT_ON_PASTE: ArkUI_NodeEventType = ArkUI_NodeEventType(7003);
8085 /// Defines the event triggered when the text selection position changes.
8086 ///
8087 ///
8088 ///
8089 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8090 /// [`ArkUI_NodeComponentEvent`].
8091 ///
8092 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8093 ///
8094 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: start position of the text selection area.
8095 ///
8096 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: end position of the text selection area.
8097 pub const NODE_TEXT_INPUT_ON_TEXT_SELECTION_CHANGE: ArkUI_NodeEventType =
8098 ArkUI_NodeEventType(7004);
8099 /// Defines the event triggered when the input status changes.
8100 ///
8101 ///
8102 ///
8103 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8104 /// [`ArkUI_NodeComponentEvent`].
8105 ///
8106 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8107 ///
8108 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: <b>true</b> indicates that text input is in progress.
8109 pub const NODE_TEXT_INPUT_ON_EDIT_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(7005);
8110 /// textInput This event is triggered when the input content changes.
8111 ///
8112 /// Conditions for triggering this event: When the input content changes.
8113 ///
8114 /// When the event callback occurs, the union type in the event parameter
8115 /// [`ArkUI_NodeEvent`] object is [`ArkUI_NodeComponentEvent`].
8116 ///
8117 /// [`ArkUI_NodeComponentEvent`] contains 2 parameters:
8118 ///
8119 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: Indicates the width of the text.
8120 ///
8121 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: Indicates the height of the text.
8122 pub const NODE_TEXT_INPUT_ON_CONTENT_SIZE_CHANGE: ArkUI_NodeEventType =
8123 ArkUI_NodeEventType(7006);
8124 /// Defines the event triggered when matching with the regular expression specified by
8125 /// <b>NODE_TEXT_INPUT_INPUT_FILTER</b> fails.
8126 ///
8127 ///
8128 ///
8129 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8130 /// [`ArkUI_StringAsyncEvent`].
8131 ///
8132 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8133 ///
8134 /// <b>ArkUI_StringAsyncEvent.pStr</b>: content that is filtered out when regular expression matching fails.
8135 pub const NODE_TEXT_INPUT_ON_INPUT_FILTER_ERROR: ArkUI_NodeEventType =
8136 ArkUI_NodeEventType(7007);
8137 /// This callback is triggered when the text content is scrolled.
8138 ///
8139 ///
8140 ///
8141 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8142 /// [`ArkUI_NodeComponentEvent`].
8143 ///
8144 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8145 ///
8146 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: Indicates the horizontal offset of the text in the content area.
8147 ///
8148 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: Indicates the vertical coordinate offset of
8149 ///
8150 /// the text in the content area.
8151 pub const NODE_TEXT_INPUT_ON_CONTENT_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(7008);
8152 /// Defines the event triggered when text is about to be entered.
8153 ///
8154 /// The event parameter is [`ArkUI_NodeEvent`].
8155 ///
8156 /// value.f32: position of the text, with the index of <b>0</b>; obtained using
8157 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8158 ///
8159 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8160 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8161 ///
8162 /// # Returns
8163 ///
8164 /// * Returns <b>true</b> if the text is entered; returns <b>false</b> otherwise.
8165 /// You can set the return value using <b>OH_ArkUI_NodeEvent_SetReturnNumberValue</b>.
8166 pub const NODE_TEXT_INPUT_ON_WILL_INSERT: ArkUI_NodeEventType = ArkUI_NodeEventType(7009);
8167 /// Defines the event triggered when text is entered.
8168 ///
8169 /// The event parameter is [`ArkUI_NodeEvent`].
8170 ///
8171 /// value.f32: position of the text, with the index of <b>0</b>; obtained using
8172 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8173 ///
8174 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8175 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8176 pub const NODE_TEXT_INPUT_ON_DID_INSERT: ArkUI_NodeEventType = ArkUI_NodeEventType(7010);
8177 /// Defines the event triggered when text is about to be deleted.
8178 ///
8179 /// The event parameter is [`ArkUI_NodeEvent`].
8180 ///
8181 /// value.f32: position of the text to delete, with the index of <b>0</b>; obtained using
8182 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8183 ///
8184 /// value.i32: direction for deleting the text, with the index of <b>1</b>; obtained using
8185 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>. The value <b>0</b> indicates backward-delete, and <b>1</b> indicates
8186 /// forward-delete.
8187 ///
8188 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8189 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8190 ///
8191 /// # Returns
8192 ///
8193 /// * Returns <b>true</b> if the text is deleted; returns <b>false</b> otherwise.
8194 ///
8195 /// You can set the return value using <b>OH_ArkUI_NodeEvent_SetReturnNumberValue</b>.
8196 pub const NODE_TEXT_INPUT_ON_WILL_DELETE: ArkUI_NodeEventType = ArkUI_NodeEventType(7011);
8197 /// Defines the event triggered when text is deleted.
8198 ///
8199 /// The event parameter is [`ArkUI_NodeEvent`].
8200 ///
8201 /// value.f32: position of the text deleted, with the index of <b>0</b>; obtained using
8202 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8203 ///
8204 /// value.i32: direction for deleting the text, with the index of <b>1</b>; obtained using
8205 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>. The value <b>0</b> indicates backward-delete, and <b>1</b> indicates
8206 /// forward-delete.
8207 ///
8208 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8209 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8210 pub const NODE_TEXT_INPUT_ON_DID_DELETE: ArkUI_NodeEventType = ArkUI_NodeEventType(7012);
8211 /// Defines the event triggered when content (including preview text) changes in the <b>TextInput</b>
8212 /// component.
8213 ///
8214 /// When the event callback occurs, the union type [`ArkUI_NodeEvent`] is [`ArkUI_TextChangeEvent`].
8215 ///
8216 /// [`ArkUI_TextChangeEvent`] contains the following parameters:
8217 ///
8218 /// <b>ArkUI_TextChangeEvent.pStr</b>: content in the <b>TextInput</b> component.
8219 /// <b>ArkUI_TextChangeEvent.pExtendStr</b>: content of the preview text in the <b>TextInput</b> component.
8220 /// <b>ArkUI_TextChangeEvent.number</b>: start position of the preview text in the <b>TextInput</b> component.
8221 ///
8222 ///
8223 /// Available since API-level: 15
8224 #[cfg(feature = "api-15")]
8225 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
8226 pub const NODE_TEXT_INPUT_ON_CHANGE_WITH_PREVIEW_TEXT: ArkUI_NodeEventType =
8227 ArkUI_NodeEventType(7013);
8228 /// Defines the event triggered when the input in the text box changes.
8229 ///
8230 ///
8231 ///
8232 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8233 /// [`ArkUI_StringAsyncEvent`].
8234 ///
8235 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8236 ///
8237 /// <b>ArkUI_StringAsyncEvent.pStr</b>: text entered.
8238 pub const NODE_TEXT_AREA_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(8000);
8239 /// Defines the event triggered when the paste button on the pasteboard, which displays when the text box is
8240 /// long pressed, is clicked.
8241 ///
8242 ///
8243 ///
8244 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8245 /// [`ArkUI_StringAsyncEvent`].
8246 ///
8247 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8248 ///
8249 /// <b>ArkUI_StringAsyncEvent.pStr</b>: text that is pasted
8250 pub const NODE_TEXT_AREA_ON_PASTE: ArkUI_NodeEventType = ArkUI_NodeEventType(8001);
8251 /// Defines the event triggered when the text selection position changes.
8252 ///
8253 ///
8254 ///
8255 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8256 /// [`ArkUI_NodeComponentEvent`].
8257 ///
8258 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8259 ///
8260 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: start position of the text selection area.
8261 ///
8262 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: end position of the text selection area.
8263 pub const NODE_TEXT_AREA_ON_TEXT_SELECTION_CHANGE: ArkUI_NodeEventType =
8264 ArkUI_NodeEventType(8002);
8265 /// Defines the event triggered when matching with the regular expression specified by
8266 /// <b>NODE_TEXT_AREA_INPUT_FILTER</b> fails.
8267 ///
8268 ///
8269 ///
8270 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8271 /// [`ArkUI_StringAsyncEvent`].
8272 ///
8273 /// [`ArkUI_StringAsyncEvent`] contains one parameter:
8274 ///
8275 /// <b>ArkUI_StringAsyncEvent.pStr</b>: content that is filtered out when regular expression matching fails.
8276 pub const NODE_TEXT_AREA_ON_INPUT_FILTER_ERROR: ArkUI_NodeEventType = ArkUI_NodeEventType(8003);
8277 /// This callback is triggered when the text content is scrolled.
8278 ///
8279 ///
8280 ///
8281 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8282 /// [`ArkUI_NodeComponentEvent`].
8283 ///
8284 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8285 ///
8286 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: Indicates the horizontal offset of the text in the content area.
8287 ///
8288 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: Indicates the vertical coordinate offset of
8289 ///
8290 /// the text in the content area.
8291 pub const NODE_TEXT_AREA_ON_CONTENT_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(8004);
8292 /// Defines the event triggered when the input status changes.
8293 ///
8294 ///
8295 ///
8296 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8297 ///
8298 /// [`ArkUI_NodeComponentEvent`].
8299 ///
8300 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8301 ///
8302 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: <b>true</b> indicates that text input is in progress.
8303 pub const NODE_TEXT_AREA_ON_EDIT_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(8005);
8304 /// Defines the event triggered when the Enter key on the keyboard is pressed for the multi-line text box.
8305 ///
8306 /// This event is not triggered when <b>keyType</b> is <b>ARKUI_ENTER_KEY_TYPE_NEW_LINE</b>.
8307 ///
8308 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8309 ///
8310 /// [`ArkUI_NodeComponentEvent`].
8311 ///
8312 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8313 ///
8314 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: type of the Enter key.
8315 pub const NODE_TEXT_AREA_ON_SUBMIT: ArkUI_NodeEventType = ArkUI_NodeEventType(8006);
8316 /// textArea This event is triggered when the input content changes.
8317 ///
8318 /// Conditions for triggering this event: When the input content changes.
8319 ///
8320 /// When the event callback occurs, the union type in the event parameter [`ArkUI_NodeEvent`] object is
8321 ///
8322 /// [`ArkUI_NodeComponentEvent`].
8323 ///
8324 /// [`ArkUI_NodeComponentEvent`] contains 2 parameters:
8325 ///
8326 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: Indicates the width of the text.
8327 ///
8328 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: Indicates the height of the text.
8329 pub const NODE_TEXT_AREA_ON_CONTENT_SIZE_CHANGE: ArkUI_NodeEventType =
8330 ArkUI_NodeEventType(8007);
8331 /// Defines the event triggered when text is about to be entered.
8332 ///
8333 /// The event parameter is [`ArkUI_NodeEvent`].
8334 ///
8335 /// value.f32: position of the text, with the index of <b>0</b>; obtained using
8336 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8337 ///
8338 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8339 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8340 ///
8341 /// # Returns
8342 ///
8343 /// * Returns <b>true</b> if the text is entered; returns <b>false</b> otherwise.
8344 /// You can set the return value using <b>OH_ArkUI_NodeEvent_SetReturnNumberValue</b>.
8345 pub const NODE_TEXT_AREA_ON_WILL_INSERT: ArkUI_NodeEventType = ArkUI_NodeEventType(8008);
8346 /// Defines the event triggered when text is entered.
8347 ///
8348 /// The event parameter is [`ArkUI_NodeEvent`].
8349 ///
8350 /// value.f32: position of the text, with the index of <b>0</b>; obtained using
8351 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8352 ///
8353 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8354 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8355 pub const NODE_TEXT_AREA_ON_DID_INSERT: ArkUI_NodeEventType = ArkUI_NodeEventType(8009);
8356 /// Defines the event triggered when text is about to be deleted.
8357 ///
8358 /// The event parameter is [`ArkUI_NodeEvent`].
8359 ///
8360 /// value.f32: position of the text to delete, with the index of <b>0</b>; obtained using
8361 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8362 ///
8363 /// value.i32: direction for deleting the text, with the index of <b>1</b>; obtained using
8364 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>. The value <b>0</b> indicates backward-delete, and <b>1</b> indicates
8365 /// forward-delete.
8366 ///
8367 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8368 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8369 ///
8370 /// # Returns
8371 ///
8372 /// * Returns <b>true</b> if the text is deleted; returns <b>false</b> otherwise.
8373 ///
8374 /// You can set the return value using <b>OH_ArkUI_NodeEvent_SetReturnNumberValue</b>.
8375 pub const NODE_TEXT_AREA_ON_WILL_DELETE: ArkUI_NodeEventType = ArkUI_NodeEventType(8010);
8376 /// Defines the event triggered when text is deleted.
8377 ///
8378 /// The event parameter is [`ArkUI_NodeEvent`].
8379 ///
8380 /// value.f32: position of the text deleted, with the index of <b>0</b>; obtained using
8381 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>.
8382 ///
8383 /// value.i32: direction for deleting the text, with the index of <b>1</b>; obtained using
8384 /// <b>OH_ArkUI_NodeEvent_GetNumberValue</b>. The value <b>0</b> indicates backward-delete, and <b>1</b> indicates
8385 /// forward-delete.
8386 ///
8387 /// buffer: string value of the text, with the index of <b>0</b>; obtained using
8388 /// <b>OH_ArkUI_NodeEvent_GetStringValue</b>.
8389 pub const NODE_TEXT_AREA_ON_DID_DELETE: ArkUI_NodeEventType = ArkUI_NodeEventType(8011);
8390 /// Defines the event triggered when content (including preview text) changes in the <b>TextArea</b>
8391 /// component.
8392 ///
8393 /// When the event callback occurs, the union type [`ArkUI_NodeEvent`] is [`ArkUI_TextChangeEvent`].
8394 ///
8395 /// [`ArkUI_TextChangeEvent`] contains the following parameters:
8396 ///
8397 /// <b>ArkUI_TextChangeEvent.pStr</b>: content in the <b>TextArea</b> component.
8398 /// <b>ArkUI_TextChangeEvent.pExtendStr</b>: content of the preview text in the <b>TextArea</b> component.
8399 /// <b>ArkUI_TextChangeEvent.number</b>: start position of the preview text in the <b>TextArea</b> component.
8400 ///
8401 ///
8402 /// Available since API-level: 15
8403 #[cfg(feature = "api-15")]
8404 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
8405 pub const NODE_TEXT_AREA_ON_CHANGE_WITH_PREVIEW_TEXT: ArkUI_NodeEventType =
8406 ArkUI_NodeEventType(8012);
8407 /// Defines the event triggered when the selected status of the <b>ARKUI_NODE_CHECKBOX</b> component changes.
8408 ///
8409 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8410 /// [`ArkUI_NodeComponentEvent`].
8411 ///
8412 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b><b>1</b>: selected; <b>0</b>: not selected.
8413 pub const NODE_CHECKBOX_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(11000);
8414 /// Defines the event triggered when a date is selected in the <b>ARKUI_NODE_DATE_PICKER</b> component.
8415 ///
8416 ///
8417 ///
8418 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8419 /// [`ArkUI_NodeComponentEvent`].
8420 ///
8421 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
8422 ///
8423 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: year of the selected date.
8424 ///
8425 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: month of the selected date. Value range: [0-11].
8426 ///
8427 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: day of the selected date.
8428 pub const NODE_DATE_PICKER_EVENT_ON_DATE_CHANGE: ArkUI_NodeEventType =
8429 ArkUI_NodeEventType(13000);
8430 /// Defines the event triggered when a time is selected in the <b>ARKUI_NODE_TIME_PICKER</b> component.
8431 ///
8432 ///
8433 ///
8434 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8435 /// [`ArkUI_NodeComponentEvent`].
8436 ///
8437 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8438 ///
8439 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: hour of the selected time. Value range: [0-23].
8440 ///
8441 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: minute of the selected time. Value range: [0-59].
8442 pub const NODE_TIME_PICKER_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(14000);
8443 /// Defines the event triggered when an item is selected in the <b>ARKUI_NODE_TEXT_PICKER</b> component.
8444 ///
8445 ///
8446 ///
8447 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8448 /// [`ArkUI_NodeComponentEvent`].
8449 ///
8450 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8451 ///
8452 /// <b>ArkUI_NodeComponentEvent.data[0...11].i32</b>: value of the selected item.
8453 pub const NODE_TEXT_PICKER_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(15000);
8454 /// Defines the event triggered when an item is selected and scrolling has stopped in the
8455 /// <b>ARKUI_NODE_TEXT_PICKER</b> component.
8456 ///
8457 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8458 /// [`ArkUI_NodeComponentEvent`].
8459 ///
8460 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8461 ///
8462 /// <b>ArkUI_NodeComponentEvent.data[0...11].i32</b>: value of the selected item.
8463 ///
8464 ///
8465 ///
8466 /// Available since API-level: 14
8467 #[cfg(feature = "api-14")]
8468 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
8469 pub const NODE_TEXT_PICKER_EVENT_ON_SCROLL_STOP: ArkUI_NodeEventType =
8470 ArkUI_NodeEventType(15001);
8471 /// Defines the event triggered when a date is selected in the <b>NODE_CALENDAR_PICKER</b>.
8472 ///
8473 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8474 /// [`ArkUI_NodeComponentEvent`].
8475 ///
8476 /// <b>ArkUI_NodeComponent.data[0].u32</b>: year of the selected date.
8477 ///
8478 /// <b>ArkUI_NodeComponent.data[1].u32</b>: month of the selected date.
8479 ///
8480 /// <b>ArkUI_NodeComponent.data[2].u32</b>: day of the selected date.
8481 pub const NODE_CALENDAR_PICKER_EVENT_ON_CHANGE: ArkUI_NodeEventType =
8482 ArkUI_NodeEventType(16000);
8483 /// Defines the event triggered when the <b>ARKUI_NODE_SLIDER</b> component is dragged or clicked.
8484 ///
8485 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8486 /// [`ArkUI_NodeComponentEvent`].
8487 ///
8488 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8489 ///
8490 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: current slider value.
8491 ///
8492 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: state triggered by the event.
8493 pub const NODE_SLIDER_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(17000);
8494 /// Defines the event callback function triggered when an object is dragged or clicked by ARKUI_NODE_RADIO.
8495 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8496 ///
8497 /// [`ArkUI_NodeComponentEvent`].
8498 ///
8499 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8500 ///
8501 /// ArkUI_NodeComponentEvent.data[0].i32: option button status.
8502 pub const NODE_RADIO_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(18000);
8503 /// Defines the event callback function triggered when the animation starts to play.
8504 ///
8505 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8506 ///
8507 /// [`ArkUI_NodeComponentEvent`].
8508 ///
8509 /// [`ArkUI_NodeComponentEvent`] contains no parameter:
8510 pub const NODE_IMAGE_ANIMATOR_EVENT_ON_START: ArkUI_NodeEventType = ArkUI_NodeEventType(19000);
8511 /// Defines the event callback function triggered when the animation playback is paused.
8512 ///
8513 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8514 ///
8515 /// [`ArkUI_NodeComponentEvent`].
8516 ///
8517 /// [`ArkUI_NodeComponentEvent`] contains no parameter:
8518 pub const NODE_IMAGE_ANIMATOR_EVENT_ON_PAUSE: ArkUI_NodeEventType = ArkUI_NodeEventType(19001);
8519 /// Defines the event callback function triggered when the animation playback is repeated.
8520 ///
8521 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8522 ///
8523 /// [`ArkUI_NodeComponentEvent`].
8524 ///
8525 /// [`ArkUI_NodeComponentEvent`] contains no parameter:
8526 pub const NODE_IMAGE_ANIMATOR_EVENT_ON_REPEAT: ArkUI_NodeEventType = ArkUI_NodeEventType(19002);
8527 /// Defines the event callback function when the animation playback returns to the initial state.
8528 ///
8529 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8530 ///
8531 /// [`ArkUI_NodeComponentEvent`].
8532 ///
8533 /// [`ArkUI_NodeComponentEvent`] contains no parameter:
8534 pub const NODE_IMAGE_ANIMATOR_EVENT_ON_CANCEL: ArkUI_NodeEventType = ArkUI_NodeEventType(19003);
8535 /// Defines the event callback function triggered when the animation playback is complete or stopped.
8536 ///
8537 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8538 ///
8539 /// [`ArkUI_NodeComponentEvent`].
8540 ///
8541 /// [`ArkUI_NodeComponentEvent`] contains no parameter:
8542 pub const NODE_IMAGE_ANIMATOR_EVENT_ON_FINISH: ArkUI_NodeEventType = ArkUI_NodeEventType(19004);
8543 /// Defines the callback triggered when the selected status of the <b>ARKUI_NODE_CHECKBOX_GROOUP</b>
8544 /// or checkbox changes.
8545 ///
8546 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8547 /// [`ArkUI_StringAsyncEvent`].
8548 ///
8549 /// <b>ArkUI_StringAsyncEvent.pStr</b>
8550 /// Name: The names of the selected checkboxes;
8551 /// Status:
8552 /// 0: All checkboxes are selected.
8553 /// 1: Some checkboxes are selected.
8554 /// 2: No checkboxes are selected.
8555 ///
8556 ///
8557 ///
8558 /// Available since API-level: 15
8559 #[cfg(feature = "api-15")]
8560 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
8561 pub const NODE_CHECKBOX_GROUP_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(21000);
8562 /// Defines the event triggered when the index of the currently displayed element of this
8563 /// <b>ARKUI_NODE_SWIPER</b> instance changes.
8564 ///
8565 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8566 /// [`ArkUI_NodeComponentEvent`].
8567 ///
8568 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8569 ///
8570 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the currently displayed element.
8571 pub const NODE_SWIPER_EVENT_ON_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(1001000);
8572 /// Defines the event triggered when the switching animation of this <b>ARKUI_NODE_SWIPER</b> instance starts.
8573 ///
8574 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8575 /// [`ArkUI_NodeComponentEvent`].
8576 ///
8577 /// [`ArkUI_NodeComponentEvent`] contains five parameters:
8578 ///
8579 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the currently displayed element.
8580 ///
8581 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: index of the target element to switch to.
8582 ///
8583 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b>: offset of the currently displayed element relative to the
8584 /// start position of the swiper along the main axis.
8585 ///
8586 /// <b>ArkUI_NodeComponentEvent.data[3].f32</b>: offset of the target element relative to the start position
8587 /// of the swiper along the main axis.
8588 ///
8589 /// <b>ArkUI_NodeComponentEvent.data[4].f32</b>: hands-off velocity.
8590 pub const NODE_SWIPER_EVENT_ON_ANIMATION_START: ArkUI_NodeEventType =
8591 ArkUI_NodeEventType(1001001);
8592 /// Defines the event triggered when the switching animation of this <b>ARKUI_NODE_SWIPER</b> instance ends.
8593 ///
8594 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8595 /// [`ArkUI_NodeComponentEvent`].
8596 ///
8597 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8598 ///
8599 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the currently displayed element.
8600 ///
8601 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: offset of the currently displayed element relative to the
8602 /// start position of the swiper along the main axis.
8603 pub const NODE_SWIPER_EVENT_ON_ANIMATION_END: ArkUI_NodeEventType =
8604 ArkUI_NodeEventType(1001002);
8605 /// Defines the event triggered on a frame-by-frame basis when the page is turned by a swipe in this
8606 /// <b>ARKUI_NODE_SWIPER</b> instance.
8607 ///
8608 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8609 /// [`ArkUI_NodeComponentEvent`].
8610 ///
8611 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8612 ///
8613 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the currently displayed element.
8614 ///
8615 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: offset of the currently displayed element relative to the
8616 /// start position of the swiper along the main axis.
8617 pub const NODE_SWIPER_EVENT_ON_GESTURE_SWIPE: ArkUI_NodeEventType =
8618 ArkUI_NodeEventType(1001003);
8619 /// Define the <b>ARKUI_NODE_SWIPER</b> to listen for Swiper page slide events.
8620 /// Instruction:
8621 ///
8622 /// 1. If the [`ArkUI_SwiperDisplayModeType`] attribute is set to
8623 ///
8624 /// ARKUI_SWIPER_DISPLAY_MODE_AUTO_LINEAR, the interface does not take effect.
8625 ///
8626 /// 2, circular scenario, set prevMargin and nextMargin attributes,
8627 ///
8628 /// so that Swiper front and back end display the same page, the interface does not take effect.
8629 ///
8630 /// 3. During page sliding, the ContentDidScrollCallback callback is
8631 ///
8632 /// triggered frame-by-frame for all pages in the window.
8633 ///
8634 /// For example, when there are two pages in the window with subscripts 0 and 1,
8635 ///
8636 /// callbacks with index values 0 and 1 are triggered twice per frame.
8637 ///
8638 /// 4, set the swipeByGroup parameter of the displayCount property to
8639 ///
8640 /// true if at least one page in the same group is in the window,
8641 ///
8642 /// A callback is triggered for all pages in the group.
8643 ///
8644 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8645 /// [`ArkUI_NodeComponentEvent`].
8646 ///
8647 /// [`ArkUI_NodeComponentEvent`] contains four parameters:
8648 ///
8649 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b> : indicates the index of the Swiper component,
8650 ///
8651 /// which is consistent with the index change in the onChange event.
8652 ///
8653 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b> : The index of a page in the window.
8654 ///
8655 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b> : The proportion of page movement relative to
8656 ///
8657 /// the start position of the Swiper spindle (selectedIndex corresponds to the start position of the page).
8658 ///
8659 /// <b>ArkUI_NodeComponentEvent.data[3].f32</b> : The length of the page in the axis direction.
8660 pub const NODE_SWIPER_EVENT_ON_CONTENT_DID_SCROLL: ArkUI_NodeEventType =
8661 ArkUI_NodeEventType(1001004);
8662 /// Defines the event triggered when content in the swiper component will scroll.
8663 /// Instructions: Before page scrolling, the </b>ContentWillScrollCallback</b> callback is invoked.
8664 ///
8665 ///
8666 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8667 /// [`ArkUI_NodeComponentEvent`].
8668 ///
8669 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
8670 ///
8671 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: the index value of the current child page.
8672 ///
8673 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: the index value of the child page that will display.
8674 ///
8675 /// <b>ArkUI_NodeComponentEvent.data[2].f32</b>: the sliding offset of each frame.
8676 /// Positive numbers indicating slide backward(e.g. from index=1 to index=0), negative numbers indicating
8677 /// slide forward(e.g. from index=0 to index=1).
8678 ///
8679 ///
8680 ///
8681 /// Available since API-level: 15
8682 #[cfg(feature = "api-15")]
8683 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
8684 pub const NODE_SWIPER_EVENT_ON_CONTENT_WILL_SCROLL: ArkUI_NodeEventType =
8685 ArkUI_NodeEventType(1001007);
8686 /// Defines the event triggered when the selected index of the <b>ARKUI_NODE_SWIPER</b> changed.
8687 ///
8688 /// This event is triggered under the following scenarios:
8689 ///
8690 /// 1. When the page switching animation starts after the user lifts their finger after swiping and the swipe meets
8691 /// the threshold for page turning.
8692 ///
8693 /// 2. When the page is changed programmatically using either <b>NODE_SWIPER_INDEX</b> or
8694 /// <b>NODE_SWIPER_SWIPE_TO_INDEX</b>.
8695 ///
8696 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8697 /// [`ArkUI_NodeComponentEvent`].
8698 ///
8699 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8700 ///
8701 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the currently selected element.
8702 ///
8703 ///
8704 ///
8705 /// Available since API-level: 18
8706 #[cfg(feature = "api-18")]
8707 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
8708 pub const NODE_SWIPER_EVENT_ON_SELECTED: ArkUI_NodeEventType = ArkUI_NodeEventType(1001005);
8709 /// Defines the event triggered when the selected index of the <b>ARKUI_NODE_SWIPER</b> changed.
8710 ///
8711 /// This event is triggered under the following scenarios:
8712 ///
8713 /// 1. When the page switching animation starts after the user lifts their finger after swiping and the swipe meets
8714 /// the threshold for page turning.
8715 ///
8716 /// 2. When the page is changed programmatically using either <b>NODE_SWIPER_INDEX</b> or
8717 /// <b>NODE_SWIPER_SWIPE_TO_INDEX</b>.
8718 ///
8719 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8720 /// [`ArkUI_NodeComponentEvent`].
8721 ///
8722 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
8723 ///
8724 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: the index of the element becomes unselected.
8725 ///
8726 ///
8727 ///
8728 /// Available since API-level: 18
8729 #[cfg(feature = "api-18")]
8730 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
8731 pub const NODE_SWIPER_EVENT_ON_UNSELECTED: ArkUI_NodeEventType = ArkUI_NodeEventType(1001006);
8732 /// Defines the event triggered when the <b>ARKUI_NODE_SCROLL</b> component scrolls.
8733 ///
8734 /// Notes for triggering the event:
8735 ///
8736 /// 1. This event is triggered when scrolling is started by the <b>ARKUI_NODE_SCROLL</b> component or other input
8737 /// settings, such as keyboard and mouse operations.
8738 ///
8739 /// 2. Scrolling can be initiated by calling the controller API.
8740 ///
8741 /// 3. The out-of-bounds bounce effect is supported.
8742 ///
8743 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8744 /// [`ArkUI_NodeComponentEvent`].
8745 ///
8746 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8747 ///
8748 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: horizontal scrolling offset.
8749 ///
8750 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: vertical scrolling offset.
8751 pub const NODE_SCROLL_EVENT_ON_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1002000);
8752 /// Defines the event triggered when each frame scrolling starts in the <b>ARKUI_NODE_SCROLL</b> component.
8753 ///
8754 /// Notes for triggering the event:
8755 ///
8756 /// 1. This event is triggered when scrolling is started by the <b>ARKUI_NODE_SCROLL</b> component or other input
8757 /// settings, such as keyboard and mouse operations.
8758 ///
8759 /// 2. This event is not triggered when the controller API is called.
8760 ///
8761 /// 3. This event does not support the out-of-bounds bounce effect.
8762 ///
8763 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8764 /// [`ArkUI_NodeComponentEvent`].
8765 ///
8766 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8767 ///
8768 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: amount to scroll by.
8769 ///
8770 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: current scrolling state.
8771 ///
8772 /// <b>::ArkUI_NodeComponentEvent</b> contains one return value:
8773 ///
8774 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: The event handler can work out the amount by which the component
8775 /// needs to scroll based on the real-world situation and return the result in this parameter.
8776 pub const NODE_SCROLL_EVENT_ON_SCROLL_FRAME_BEGIN: ArkUI_NodeEventType =
8777 ArkUI_NodeEventType(1002001);
8778 /// Define the enumeration value of the pre sliding trigger event for the scrolling container component.
8779 ///
8780 /// The conditions that trigger this event:
8781 ///
8782 /// 1. When the scrolling component triggers scrolling, it supports input settings such as keyboard and mouse
8783 /// operations that trigger scrolling.
8784 ///
8785 /// 2. Called through the rolling controller API interface.
8786 ///
8787 /// 3. Cross boundary rebound.
8788 ///
8789 /// When an event callback occurs, the union type in the event parameter [`ArkUI_NodeEvent`] object is
8790 /// [`ArkUI_NodeComponentEvent`].
8791 ///
8792 /// [`ArkUI_NodeComponentEvent`] contains four parameters:
8793 ///
8794 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: The offset for each frame of scrolling is positive when scrolling to
8795 /// the left and negative when scrolling to the right, measured in vp.
8796 ///
8797 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: The offset of each frame scrolling, with a positive offset when
8798 /// scrolling up and a negative offset when scrolling down, measured in vp.
8799 ///
8800 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: Current sliding state,
8801 ///
8802 /// parameter type is [`ArkUI_ScrollState`].
8803 ///
8804 /// <b>ArkUI_NodeComponentEvent.data[3].i32</b>: Current scroll source,
8805 ///
8806 /// parameter type is [`ArkUI_ScrollSource`].
8807 ///
8808 ///
8809 /// # Returns
8810 ///
8811 /// * Does not return or returns a number that sets the actual scroll distance of the scroll component.
8812 pub const NODE_SCROLL_EVENT_ON_WILL_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1002002);
8813 /// Define the event enumeration value triggered when sliding a scrolling container component.
8814 ///
8815 /// The conditions that trigger this event:
8816 ///
8817 /// 1. When the scrolling component triggers scrolling, it supports input settings such as keyboard and mouse
8818 /// operations that trigger scrolling.
8819 ///
8820 /// 2. Called through the rolling controller API interface.
8821 ///
8822 /// 3. Cross boundary rebound.
8823 ///
8824 /// When an event callback occurs, the union type in the event parameter [`ArkUI_NodeEvent`] object is
8825 /// [`ArkUI_NodeComponentEvent`].
8826 ///
8827 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
8828 ///
8829 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: The offset for each frame of scrolling is positive when scrolling to
8830 /// the left and negative when scrolling to the right, measured in vp.
8831 ///
8832 /// <b>ArkUI_NodeComponentEvent.data[1].f32</b>: The offset of each frame scrolling, with a positive offset when
8833 /// scrolling up and a negative offset when scrolling down, measured in vp.
8834 ///
8835 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: Current sliding state,
8836 ///
8837 /// parameter type is [`ArkUI_ScrollState`].
8838 pub const NODE_SCROLL_EVENT_ON_DID_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1002003);
8839 /// Defines the event triggered when scrolling starts in the <b>ARKUI_NODE_SCROLL</b> component.
8840 ///
8841 /// Notes for triggering the event:
8842 ///
8843 /// 1. This event is triggered when scrolling is started, with support for other input settings, such as keyboard
8844 /// and mouse operations.
8845 ///
8846 /// 2. This event is triggered when the controller API is called, accompanied by a transition animation.
8847 ///
8848 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8849 /// [`ArkUI_NodeComponentEvent`].
8850 ///
8851 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
8852 pub const NODE_SCROLL_EVENT_ON_SCROLL_START: ArkUI_NodeEventType = ArkUI_NodeEventType(1002004);
8853 /// Defines the event triggered when scrolling of the <b>ARKUI_NODE_SCROLL</b> component stops.
8854 ///
8855 /// Notes for triggering the event:
8856 ///
8857 /// 1. This event is triggered when scrolling is stopped by the <b>ARKUI_NODE_SCROLL</b> component or other input
8858 /// settings, such as keyboard and mouse operations.
8859 ///
8860 /// 2. This event is triggered when the controller API is called, accompanied by a transition animation.
8861 ///
8862 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8863 /// [`ArkUI_NodeComponentEvent`].
8864 ///
8865 /// [`ArkUI_NodeComponentEvent`] does not contain parameters.
8866 pub const NODE_SCROLL_EVENT_ON_SCROLL_STOP: ArkUI_NodeEventType = ArkUI_NodeEventType(1002005);
8867 /// Defines the event triggered when scrolling of the <b>ARKUI_NODE_SCROLL</b> component reaches
8868 /// one of the edges.
8869 ///
8870 /// Notes for triggering the event:
8871 ///
8872 /// 1. This event is triggered when scrolling reaches the edge after being started by the <b>ARKUI_NODE_SCROLL</b>
8873 /// component or other input settings, such as keyboard and mouse operations.
8874 ///
8875 /// 2. Scrolling can be initiated by calling the controller API.
8876 ///
8877 /// 3. The out-of-bounds bounce effect is supported.
8878 ///
8879 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8880 /// [`ArkUI_NodeComponentEvent`].
8881 ///
8882 /// [`ArkUI_NodeComponentEvent`] contains one parameter.
8883 ///
8884 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: edge (top, bottom, left, or right) that the scrolling reaches.
8885 pub const NODE_SCROLL_EVENT_ON_SCROLL_EDGE: ArkUI_NodeEventType = ArkUI_NodeEventType(1002006);
8886 /// Define that a callback is triggered when the scrolling container component reaches the start position.
8887 /// Condition for triggering the event:
8888 ///
8889 /// Triggered when the component reaches the start position.
8890 ///
8891 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8892 /// [`ArkUI_NodeComponentEvent`].
8893 ///
8894 /// [`ArkUI_NodeComponentEvent`] contains no parameters.
8895 pub const NODE_SCROLL_EVENT_ON_REACH_START: ArkUI_NodeEventType = ArkUI_NodeEventType(1002007);
8896 /// Define that a callback is triggered when the scrolling container component ends.
8897 ///
8898 /// Condition for triggering the event:
8899 ///
8900 /// Triggered when the component reaches the end.
8901 ///
8902 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8903 /// [`ArkUI_NodeComponentEvent`].
8904 ///
8905 /// [`ArkUI_NodeComponentEvent`] contains no parameters.
8906 pub const NODE_SCROLL_EVENT_ON_REACH_END: ArkUI_NodeEventType = ArkUI_NodeEventType(1002008);
8907 /// Defines the enumerated values of the event triggered,
8908 ///
8909 /// when a subcomponent of ARKUI_NODE_LIST is moved into or out of the list display area.
8910 ///
8911 /// Condition for triggering the event:
8912 ///
8913 /// This method is triggered once during list initialization.
8914 ///
8915 /// It is triggered when the index value of the first or last subcomponent in the list display area changes.
8916 ///
8917 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8918 /// [`ArkUI_NodeComponentEvent`].
8919 ///
8920 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
8921 ///
8922 /// ArkUI_NodeComponentEvent.data[0].i32: List Displays the index value of
8923 ///
8924 /// the first child component in the region.
8925 ///
8926 /// ArkUI_NodeComponentEvent.data[1].i32: List Displays the index value of
8927 ///
8928 /// the last child component in the region.
8929 ///
8930 /// ArkUI_NodeComponentEvent.data[2].i32: List Displays the index value of
8931 ///
8932 /// the subcomponent in the middle of the area.
8933 pub const NODE_LIST_ON_SCROLL_INDEX: ArkUI_NodeEventType = ArkUI_NodeEventType(1003000);
8934 /// Defines the enumerated values of the event triggered
8935 /// before the sliding of the ARKUI_NODE_LIST component.
8936 ///
8937 /// Condition for triggering the event:
8938 ///
8939 /// This event is triggered when the scrolling component triggers scrolling.
8940 ///
8941 /// Other inputs that trigger scrolling, such as keyboard and mouse operations, can be set.
8942 ///
8943 /// Called through the scroll controller API.
8944 ///
8945 /// Out-of-bounds rebound.
8946 ///
8947 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8948 ///
8949 /// [`ArkUI_NodeComponentEvent`].
8950 ///
8951 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
8952 ///
8953 /// ArkUI_NodeComponentEvent.data[0].f32: offset of each frame scrolling.
8954 ///
8955 /// The offset is positive when the list content is scrolled up and
8956 ///
8957 /// is negative when the list content is scrolled down.
8958 ///
8959 /// ArkUI_NodeComponentEvent.data[1].i32: Current sliding state.
8960 ///
8961 /// parameter type is [`ArkUI_ScrollState`].
8962 ///
8963 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: Current scroll source,
8964 ///
8965 /// parameter type is [`ArkUI_ScrollSource`].
8966 ///
8967 ///
8968 /// # Returns
8969 ///
8970 /// * Does not return or returns a number that sets the actual scroll distance of the scroll component.
8971 pub const NODE_LIST_ON_WILL_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1003001);
8972 /// Define the enumerated values of the event triggered when the ARKUI_NODE_LIST component is flicked.
8973 /// Condition for triggering the event:
8974 ///
8975 /// This event is triggered when the scrolling component triggers scrolling.
8976 ///
8977 /// Other inputs that trigger scrolling, such as keyboard and mouse operations, can be set.
8978 ///
8979 /// Called through the scroll controller API.
8980 ///
8981 /// Out-of-bounds rebound.
8982 ///
8983 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
8984 ///
8985 /// [`ArkUI_NodeComponentEvent`].
8986 ///
8987 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
8988 ///
8989 /// ArkUI_NodeComponentEvent.data[0].f32: offset of each frame scrolling.
8990 ///
8991 /// The offset is positive when the list content is scrolled up and
8992 ///
8993 /// is negative when the list content is scrolled down.
8994 ///
8995 /// ArkUI_NodeComponentEvent.data[1].i32: Current sliding state.
8996 pub const NODE_LIST_ON_DID_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1003002);
8997 /// Defines the event triggered when the currently displayed content of the <b>ARKUI_NODE_LIST</b> changes.
8998 ///
8999 /// Notes for triggering the event:
9000 ///
9001 /// This event is triggered once when the list is initialized and when the index of the first child component or the
9002 /// next child component in the list display area changes.
9003 /// During index calculation, the list item, header of the list item group, and footer of the list item group each
9004 /// are counted as a child component.
9005 ///
9006 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9007 /// [`ArkUI_NodeComponentEvent`].
9008 ///
9009 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
9010 ///
9011 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: index of the first child component in the list display area.
9012 ///
9013 /// <b>ArkUI_NodeComponentEvent.data[1].i32</b>: area in the list item group where the list display area starts.
9014 /// The type is [`ArkUI_ListItemGroupArea`].
9015 ///
9016 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: index of the list item at the start of the list display area
9017 /// in the list item group.
9018 /// If the start of the list display area is not on a list item, the value is <b>-1</b>.
9019 ///
9020 /// <b>ArkUI_NodeComponentEvent.data[3].i32</b>: index of the last child component in the list display area.
9021 ///
9022 /// <b>ArkUI_NodeComponentEvent.data[4].i32</b>: area in the list item group where the list display area ends.
9023 /// The type is [`ArkUI_ListItemGroupArea`].
9024 ///
9025 /// <b>ArkUI_NodeComponentEvent.data[5].i32</b>: index of the list item at the end of the list display area in the
9026 /// list item group.
9027 /// If the end of the list display area is not on a list item, the value is <b>-1</b>.
9028 ///
9029 ///
9030 ///
9031 /// Available since API-level: 15
9032 #[cfg(feature = "api-15")]
9033 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
9034 pub const NODE_LIST_ON_SCROLL_VISIBLE_CONTENT_CHANGE: ArkUI_NodeEventType =
9035 ArkUI_NodeEventType(1003003);
9036 /// Defines the event triggered when the refresh state of the <b>ARKUI_NODE_REFRESH</b> object changes.
9037 ///
9038 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9039 /// [`ArkUI_NodeComponentEvent`].
9040 ///
9041 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
9042 ///
9043 /// <b>ArkUI_NodeComponentEvent.data[0].i32</b>: refresh state.
9044 pub const NODE_REFRESH_STATE_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(1009000);
9045 /// Defines the event triggered when the <b>ARKUI_NODE_REFRESH</b> object enters the refresh state.
9046 ///
9047 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9048 /// [`ArkUI_NodeComponentEvent`].
9049 ///
9050 /// [`ArkUI_NodeComponentEvent`] does not contain parameters:
9051 pub const NODE_REFRESH_ON_REFRESH: ArkUI_NodeEventType = ArkUI_NodeEventType(1009001);
9052 /// Defines the event that is triggered when the <b>ARKUI_NODE_REFRESH</b> drop-down distance changes.
9053 ///
9054 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9055 /// [`ArkUI_NodeComponentEvent`].
9056 ///
9057 /// [`ArkUI_NodeComponentEvent`] contains one parameter:
9058 ///
9059 /// <b>ArkUI_NodeComponentEvent.data[0].f32</b>: Pull-down distance.
9060 pub const NODE_REFRESH_ON_OFFSET_CHANGE: ArkUI_NodeEventType = ArkUI_NodeEventType(1009002);
9061 /// Defines the event triggered when the <b>ARKUI_NODE_SCROLL</b> component is about to scroll.
9062 ///
9063 /// Notes for triggering the event:
9064 ///
9065 /// 1. This event is triggered when scrolling is started by the <b>ARKUI_NODE_SCROLL</b> component or other
9066 /// input settings, such as keyboard and mouse operations.
9067 ///
9068 /// 2. Scrolling can be initiated by calling the controller API.
9069 ///
9070 /// 3. The out-of-bounds bounce effect is supported.
9071 ///
9072 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9073 /// [`ArkUI_NodeComponentEvent`].
9074 ///
9075 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
9076 ///
9077 /// ArkUI_NodeComponentEvent.data[0].f32: offset of each frame scrolling.
9078 ///
9079 /// The offset is positive when the list content is scrolled up and
9080 ///
9081 /// is negative when the list content is scrolled down.
9082 ///
9083 /// ArkUI_NodeComponentEvent.data[1].i32: Current sliding state.
9084 ///
9085 /// parameter type is [`ArkUI_ScrollState`].
9086 ///
9087 /// <b>ArkUI_NodeComponentEvent.data[2].i32</b>: Current scroll source,
9088 ///
9089 /// parameter type is [`ArkUI_ScrollSource`].
9090 ///
9091 ///
9092 /// # Returns
9093 ///
9094 /// * Does not return or returns a number that sets the actual scroll distance of the scroll component.
9095 pub const NODE_ON_WILL_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1010000);
9096 /// Define the enumerated values of the event triggered when the ARKUI_NODE_WATER_FLOW component slides.
9097 /// Condition for triggering the event:
9098 ///
9099 /// This event is triggered when the scrolling component triggers scrolling.
9100 /// Other inputs that trigger scrolling, such as keyboard and mouse operations, can be set.
9101 ///
9102 /// Called through the scroll controller API.
9103 ///
9104 /// Out-of-bounds rebound.
9105 ///
9106 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9107 ///
9108 /// [`ArkUI_NodeComponentEvent`].
9109 ///
9110 /// [`ArkUI_NodeComponentEvent`] contains two parameters:
9111 ///
9112 /// ArkUI_NodeComponentEvent.data[0].f32: offset of each frame scrolling.
9113 ///
9114 /// The offset is positive when the content is scrolled up and is negative when the content is scrolled down.
9115 ///
9116 /// ArkUI_NodeComponentEvent.data[1].i32: Current sliding state.
9117 pub const NODE_WATER_FLOW_ON_DID_SCROLL: ArkUI_NodeEventType = ArkUI_NodeEventType(1010001);
9118 /// Defines the enumerated values of the event triggered,
9119 /// when the subcomponent of the start position or end position displayed in the current waterfall changes.
9120 /// Condition for triggering the event:
9121 ///
9122 /// This event is triggered when the index value of the
9123 ///
9124 /// first or last subcomponent in the waterfall display area changes.
9125 ///
9126 /// When the event callback occurs, the union type in the [`ArkUI_NodeEvent`] object is
9127 ///
9128 /// [`ArkUI_NodeComponentEvent`].
9129 ///
9130 /// [`ArkUI_NodeComponentEvent`] contains three parameters:
9131 ///
9132 /// ArkUI_NodeComponentEvent.data[0].i32: The index value of the
9133 ///
9134 /// start position of the currently displayed WaterFlow.
9135 ///
9136 /// ArkUI_NodeComponentEvent.data[1].i32: The index value of
9137 ///
9138 /// the end position of the currently displayed waterfall.
9139 pub const NODE_WATER_FLOW_ON_SCROLL_INDEX: ArkUI_NodeEventType = ArkUI_NodeEventType(1010002);
9140}
9141#[repr(transparent)]
9142/// Enumerates the event types supported by the NativeNode component.
9143///
9144///
9145/// Available since API-level: 12
9146#[cfg(feature = "api-12")]
9147#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9148#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
9149pub struct ArkUI_NodeEventType(pub ::core::ffi::c_uint);
9150/// Defines the common structure type of a component event.
9151///
9152///
9153/// Available since API-level: 12
9154#[cfg(feature = "api-12")]
9155#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9156#[repr(C)]
9157pub struct ArkUI_NodeEvent {
9158 _unused: [u8; 0],
9159}
9160#[cfg(feature = "api-12")]
9161#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9162impl ArkUI_NodeDirtyFlag {
9163 /// Remeasure.
9164 ///
9165 /// When this type of flag is specified, re-layout is triggered by default.
9166 pub const NODE_NEED_MEASURE: ArkUI_NodeDirtyFlag = ArkUI_NodeDirtyFlag(1);
9167 /// Re-layout.
9168 pub const NODE_NEED_LAYOUT: ArkUI_NodeDirtyFlag = ArkUI_NodeDirtyFlag(2);
9169 /// Re-rendering.
9170 pub const NODE_NEED_RENDER: ArkUI_NodeDirtyFlag = ArkUI_NodeDirtyFlag(3);
9171}
9172#[repr(transparent)]
9173/// Defines the dirty area flag passed in the <b>::markDirty</b> API.
9174///
9175///
9176/// Available since API-level: 12
9177#[cfg(feature = "api-12")]
9178#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9179#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
9180pub struct ArkUI_NodeDirtyFlag(pub ::core::ffi::c_uint);
9181#[cfg(feature = "api-12")]
9182#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9183impl ArkUI_NodeCustomEventType {
9184 /// Measure type.
9185 pub const ARKUI_NODE_CUSTOM_EVENT_ON_MEASURE: ArkUI_NodeCustomEventType =
9186 ArkUI_NodeCustomEventType(1);
9187 /// Layout type.
9188 pub const ARKUI_NODE_CUSTOM_EVENT_ON_LAYOUT: ArkUI_NodeCustomEventType =
9189 ArkUI_NodeCustomEventType(2);
9190 /// Draw type.
9191 pub const ARKUI_NODE_CUSTOM_EVENT_ON_DRAW: ArkUI_NodeCustomEventType =
9192 ArkUI_NodeCustomEventType(4);
9193 /// Foreground type.
9194 pub const ARKUI_NODE_CUSTOM_EVENT_ON_FOREGROUND_DRAW: ArkUI_NodeCustomEventType =
9195 ArkUI_NodeCustomEventType(8);
9196 /// Overlay type.
9197 pub const ARKUI_NODE_CUSTOM_EVENT_ON_OVERLAY_DRAW: ArkUI_NodeCustomEventType =
9198 ArkUI_NodeCustomEventType(16);
9199}
9200#[repr(transparent)]
9201/// Defines the custom component event type.
9202///
9203///
9204/// Available since API-level: 12
9205#[cfg(feature = "api-12")]
9206#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9207#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
9208pub struct ArkUI_NodeCustomEventType(pub ::core::ffi::c_uint);
9209/// Defines the general structure of a custom component event.
9210///
9211///
9212/// Available since API-level: 12
9213#[cfg(feature = "api-12")]
9214#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9215#[repr(C)]
9216pub struct ArkUI_NodeCustomEvent {
9217 _unused: [u8; 0],
9218}
9219#[repr(C)]
9220pub struct ArkUI_NodeAdapter {
9221 _unused: [u8; 0],
9222}
9223/// Defines the component adapter, which is used for lazy loading of elements of scrollable components.
9224///
9225///
9226/// Available since API-level: 12
9227#[cfg(feature = "api-12")]
9228#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9229pub type ArkUI_NodeAdapterHandle = *mut ArkUI_NodeAdapter;
9230/// Defines the component adapter event.
9231///
9232///
9233/// Available since API-level: 12
9234#[cfg(feature = "api-12")]
9235#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9236#[repr(C)]
9237pub struct ArkUI_NodeAdapterEvent {
9238 _unused: [u8; 0],
9239}
9240#[cfg(feature = "api-12")]
9241#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9242impl ArkUI_NodeAdapterEventType {
9243 /// This event occurs when the component is attached to the adapter.
9244 pub const NODE_ADAPTER_EVENT_WILL_ATTACH_TO_NODE: ArkUI_NodeAdapterEventType =
9245 ArkUI_NodeAdapterEventType(1);
9246 /// This event occurs when the component is detached from the adapter.
9247 pub const NODE_ADAPTER_EVENT_WILL_DETACH_FROM_NODE: ArkUI_NodeAdapterEventType =
9248 ArkUI_NodeAdapterEventType(2);
9249 /// This event occurs when the adapter obtains the unique ID of the new element to add.
9250 pub const NODE_ADAPTER_EVENT_ON_GET_NODE_ID: ArkUI_NodeAdapterEventType =
9251 ArkUI_NodeAdapterEventType(3);
9252 /// This event occurs when the adapter obtains the content of the new element to add.
9253 pub const NODE_ADAPTER_EVENT_ON_ADD_NODE_TO_ADAPTER: ArkUI_NodeAdapterEventType =
9254 ArkUI_NodeAdapterEventType(4);
9255 /// This event occurs when the adapter removes an element.
9256 pub const NODE_ADAPTER_EVENT_ON_REMOVE_NODE_FROM_ADAPTER: ArkUI_NodeAdapterEventType =
9257 ArkUI_NodeAdapterEventType(5);
9258}
9259#[repr(transparent)]
9260/// Enumerates component adapter events.
9261///
9262///
9263/// Available since API-level: 12
9264#[cfg(feature = "api-12")]
9265#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9266#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
9267pub struct ArkUI_NodeAdapterEventType(pub ::core::ffi::c_uint);
9268/// Declares a collection of native node APIs provided by ArkUI.
9269///
9270/// The APIs related to the native node must be called in the main thread.
9271///
9272///
9273/// Version: 1
9274///
9275/// Available since API-level: 12
9276#[cfg(feature = "api-12")]
9277#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9278#[repr(C)]
9279#[derive(Debug, Copy, Clone)]
9280pub struct ArkUI_NativeNodeAPI_1 {
9281 /// Struct version.
9282 pub version: i32,
9283 /// Creates a component based on [`ArkUI_NodeType`] and returns the pointer to the created component.
9284 ///
9285 /// # Arguments
9286 ///
9287 /// * `type` - Indicates the type of component to create.
9288 ///
9289 /// # Returns
9290 ///
9291 /// * Returns the pointer to the created component. If the component fails to be created, NULL is returned.
9292 pub createNode:
9293 ::core::option::Option<unsafe extern "C" fn(type_: ArkUI_NodeType) -> ArkUI_NodeHandle>,
9294 /// Destroys the component to which the specified pointer points.
9295 ///
9296 /// # Arguments
9297 ///
9298 /// * `node` - Indicates the pointer.
9299 pub disposeNode: ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle)>,
9300 /// Adds a component to a parent node.
9301 ///
9302 /// # Arguments
9303 ///
9304 /// * `parent` - Indicates the pointer to the parent node.
9305 ///
9306 /// * `child` - Indicates the pointer to the child node.
9307 ///
9308 /// # Returns
9309 ///
9310 /// * Returns the error code.
9311 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9312 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9313 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9314 /// on BuilderNode generated nodes:
9315 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9316 pub addChild: ::core::option::Option<
9317 unsafe extern "C" fn(parent: ArkUI_NodeHandle, child: ArkUI_NodeHandle) -> i32,
9318 >,
9319 /// Removes a component from its parent node.
9320 ///
9321 /// # Arguments
9322 ///
9323 /// * `parent` - Indicates the pointer to the parent node.
9324 ///
9325 /// * `child` - Indicates the pointer to the child node.
9326 ///
9327 /// # Returns
9328 ///
9329 /// * Returns the error code.
9330 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9331 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9332 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9333 /// on BuilderNode generated nodes:
9334 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9335 pub removeChild: ::core::option::Option<
9336 unsafe extern "C" fn(parent: ArkUI_NodeHandle, child: ArkUI_NodeHandle) -> i32,
9337 >,
9338 /// Inserts a component to a parent node after the specified <b>sibling</b> node.
9339 ///
9340 /// # Arguments
9341 ///
9342 /// * `parent` - Indicates the pointer to the parent node.
9343 ///
9344 /// * `child` - Indicates the pointer to the child node.
9345 ///
9346 /// * `sibling` - Indicates the pointer to the sibling node after which the target node is to be inserted.
9347 /// If the value is null, the node is inserted at the start of the parent node.
9348 ///
9349 /// # Returns
9350 ///
9351 /// * Returns the error code.
9352 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9353 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9354 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9355 /// on BuilderNode generated nodes:
9356 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9357 pub insertChildAfter: ::core::option::Option<
9358 unsafe extern "C" fn(
9359 parent: ArkUI_NodeHandle,
9360 child: ArkUI_NodeHandle,
9361 sibling: ArkUI_NodeHandle,
9362 ) -> i32,
9363 >,
9364 /// Inserts a component to a parent node before the specified <b>sibling</b> node.
9365 ///
9366 /// # Arguments
9367 ///
9368 /// * `parent` - Indicates the pointer to the parent node.
9369 ///
9370 /// * `child` - Indicates the pointer to the child node.
9371 ///
9372 /// * `sibling` - Indicates the pointer to the sibling node before which the target node is to be inserted.
9373 /// If the value is null, the node is inserted at the end of the parent node.
9374 ///
9375 /// # Returns
9376 ///
9377 /// * Returns the error code.
9378 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9379 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9380 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9381 /// on BuilderNode generated nodes:
9382 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9383 pub insertChildBefore: ::core::option::Option<
9384 unsafe extern "C" fn(
9385 parent: ArkUI_NodeHandle,
9386 child: ArkUI_NodeHandle,
9387 sibling: ArkUI_NodeHandle,
9388 ) -> i32,
9389 >,
9390 /// Inserts a component to the specified position in a parent node.
9391 ///
9392 /// # Arguments
9393 ///
9394 /// * `parent` - Indicates the pointer to the parent node.
9395 ///
9396 /// * `child` - Indicates the pointer to the child node.
9397 ///
9398 /// * `position` - Indicates the position to which the target child node is to be inserted. If the value is a
9399 /// negative number or invalid, the node is inserted at the end of the parent node.
9400 ///
9401 /// # Returns
9402 ///
9403 /// * Returns the error code.
9404 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9405 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9406 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9407 /// on BuilderNode generated nodes:
9408 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9409 pub insertChildAt: ::core::option::Option<
9410 unsafe extern "C" fn(
9411 parent: ArkUI_NodeHandle,
9412 child: ArkUI_NodeHandle,
9413 position: i32,
9414 ) -> i32,
9415 >,
9416 /// Sets the attribute of a node.
9417 ///
9418 /// # Arguments
9419 ///
9420 /// * `node` - Indicates the node whose attribute needs to be set.
9421 ///
9422 /// * `attribute` - Indicates the type of attribute to set.
9423 ///
9424 /// * `value` - Indicates the attribute value.
9425 ///
9426 /// # Returns
9427 ///
9428 /// * Returns the error code.
9429 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9430 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9431 /// Returns [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] if the dynamic implementation library
9432 /// of the native API was not found.
9433 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9434 /// on BuilderNode generated nodes:
9435 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9436 pub setAttribute: ::core::option::Option<
9437 unsafe extern "C" fn(
9438 node: ArkUI_NodeHandle,
9439 attribute: ArkUI_NodeAttributeType,
9440 item: *const ArkUI_AttributeItem,
9441 ) -> i32,
9442 >,
9443 /// Obtains an attribute.
9444 ///
9445 /// The pointer returned by this API is an internal buffer pointer of the ArkUI framework. As such, you do not need
9446 /// to call <b>delete</b> to release the memory. However, the pointer must be used before this API is called next
9447 /// time. Otherwise, the pointer may be overwritten by other values.
9448 /// # Arguments
9449 ///
9450 /// * `node` - Indicates the node whose attribute needs to be obtained.
9451 ///
9452 /// * `attribute` - Indicates the type of attribute to obtain.
9453 ///
9454 /// # Returns
9455 ///
9456 /// * Returns the attribute value. If the operation fails, a null pointer is returned.
9457 pub getAttribute: ::core::option::Option<
9458 unsafe extern "C" fn(
9459 node: ArkUI_NodeHandle,
9460 attribute: ArkUI_NodeAttributeType,
9461 ) -> *const ArkUI_AttributeItem,
9462 >,
9463 /// Resets an attribute.
9464 ///
9465 /// # Arguments
9466 ///
9467 /// * `node` - Indicates the node whose attribute needs to be reset.
9468 ///
9469 /// * `attribute` - Indicates the type of attribute to reset.
9470 ///
9471 /// # Returns
9472 ///
9473 /// * Returns the error code.
9474 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9475 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9476 /// Returns [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] if the dynamic implementation library
9477 /// of the native API was not found.
9478 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9479 /// on BuilderNode generated nodes:
9480 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9481 pub resetAttribute: ::core::option::Option<
9482 unsafe extern "C" fn(node: ArkUI_NodeHandle, attribute: ArkUI_NodeAttributeType) -> i32,
9483 >,
9484 /// Registers an event for the specified node.
9485 ///
9486 /// When the component is being displayed, this API must be called in the main thread.
9487 ///
9488 /// # Arguments
9489 ///
9490 /// * `node` - Indicates the target node.
9491 ///
9492 /// * `eventType` - Indicates the type of event to register.
9493 ///
9494 /// * `targetId` - Indicates the custom event ID, which is passed in the callback of [`ArkUI_NodeEvent`]
9495 /// when the event is triggered.
9496 ///
9497 /// * `userData` - Indicates the custom event parameter, which is passed in the callback of [`ArkUI_NodeEvent`]
9498 ///
9499 /// # Returns
9500 ///
9501 /// * Returns the error code.
9502 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9503 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9504 /// Returns [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] if the dynamic implementation library
9505 /// of the native API was not found.
9506 /// Returns [`ARKUI_ERROR_CODE_NOT_SUPPROTED_FOR_ARKTS_NODE`] if the following operations are not allowed
9507 /// on BuilderNode generated nodes:
9508 /// setting or resetting attributes, setting events, or adding or editing subnodes.
9509 pub registerNodeEvent: ::core::option::Option<
9510 unsafe extern "C" fn(
9511 node: ArkUI_NodeHandle,
9512 eventType: ArkUI_NodeEventType,
9513 targetId: i32,
9514 userData: *mut ::core::ffi::c_void,
9515 ) -> i32,
9516 >,
9517 /// Unregisters an event for the specified node.
9518 ///
9519 /// When the component is being displayed, this API must be called in the main thread.
9520 ///
9521 /// # Arguments
9522 ///
9523 /// * `node` - Indicates the target node.
9524 ///
9525 /// * `eventType` - Indicates the type of event to unregister.
9526 pub unregisterNodeEvent: ::core::option::Option<
9527 unsafe extern "C" fn(node: ArkUI_NodeHandle, eventType: ArkUI_NodeEventType),
9528 >,
9529 /// Registers an event receiver.
9530 ///
9531 /// The ArkUI framework collects component events generated during the process and calls back the events through
9532 /// the registered event receiver.
9533 ///
9534 /// A new call to this API will overwrite the previously registered event receiver.
9535 ///
9536 /// Do not directly save the <b>ArkUI_NodeEvent</b> object pointer. The data will be destroyed after the
9537 /// callback is complete.
9538 ///
9539 /// To bind with a component instance, you can use the <b>addNodeEventReceiver</b> function.
9540 ///
9541 ///
9542 /// # Arguments
9543 ///
9544 /// * `eventReceiver` - Indicates the event receiver to register.
9545 pub registerNodeEventReceiver: ::core::option::Option<
9546 unsafe extern "C" fn(
9547 eventReceiver: ::core::option::Option<unsafe extern "C" fn(event: *mut ArkUI_NodeEvent)>,
9548 ),
9549 >,
9550 /// Unregisters the event receiver.
9551 pub unregisterNodeEventReceiver: ::core::option::Option<unsafe extern "C" fn()>,
9552 /// Forcibly marks the current node that needs to be measured, laid out, or rendered again.
9553 ///
9554 /// Regarding updates to system attributes, the ArkUI framework automatically marks the dirty area and performs
9555 /// measuring, layout, or rendering again. In this case, you do not need to call this API.
9556 /// # Arguments
9557 ///
9558 /// * `node` - Indicates the node for which you want to mark as dirty area.
9559 ///
9560 /// * `dirtyFlag` - Indicates type of dirty area.
9561 pub markDirty: ::core::option::Option<
9562 unsafe extern "C" fn(node: ArkUI_NodeHandle, dirtyFlag: ArkUI_NodeDirtyFlag),
9563 >,
9564 /// Obtains the number of subnodes.
9565 ///
9566 /// # Arguments
9567 ///
9568 /// * `node` - Indicates the target node.
9569 ///
9570 /// # Returns
9571 ///
9572 /// * the number of subnodes. If not, returns 0.
9573 pub getTotalChildCount:
9574 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> u32>,
9575 /// Obtains a subnode.
9576 ///
9577 /// # Arguments
9578 ///
9579 /// * `node` - Indicates the target node.
9580 ///
9581 /// * `position` - Indicates the position of the subnode.
9582 ///
9583 /// # Returns
9584 ///
9585 /// * Returns the pointer to the subnode if the subnode exists; returns <b>NULL</b> otherwise.
9586 pub getChildAt: ::core::option::Option<
9587 unsafe extern "C" fn(node: ArkUI_NodeHandle, position: i32) -> ArkUI_NodeHandle,
9588 >,
9589 /// Obtains the first subnode.
9590 ///
9591 /// # Arguments
9592 ///
9593 /// * `node` - Indicates the target node.
9594 ///
9595 /// # Returns
9596 ///
9597 /// * Returns the pointer to the subnode if the subnode exists; returns <b>NULL</b> otherwise.
9598 pub getFirstChild:
9599 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle>,
9600 /// Obtains the last subnode.
9601 ///
9602 /// # Arguments
9603 ///
9604 /// * `node` - Indicates the target node.
9605 ///
9606 /// # Returns
9607 ///
9608 /// * Returns the pointer to the subnode if the subnode exists; returns <b>NULL</b> otherwise.
9609 pub getLastChild:
9610 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle>,
9611 /// Obtains the previous sibling node.
9612 ///
9613 /// # Arguments
9614 ///
9615 /// * `node` - Indicates the target node.
9616 ///
9617 /// # Returns
9618 ///
9619 /// * Returns the pointer to the subnode if the subnode exists; returns <b>NULL</b> otherwise.
9620 pub getPreviousSibling:
9621 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle>,
9622 /// Obtains the next sibling node.
9623 ///
9624 /// # Arguments
9625 ///
9626 /// * `node` - Indicates the target node.
9627 ///
9628 /// # Returns
9629 ///
9630 /// * Returns the pointer to the subnode if the subnode exists; returns <b>NULL</b> otherwise.
9631 pub getNextSibling:
9632 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle>,
9633 /// Registers a custom event for a node. When the event is triggered, the value is returned through the entry
9634 /// point function registered by <b>registerNodeCustomEventReceiver</b>.
9635 ///
9636 /// # Arguments
9637 ///
9638 /// * `node` - Indicates the target node.
9639 ///
9640 /// * `eventType` - Indicates the type of event to register.
9641 ///
9642 /// * `targetId` - Indicates the custom event ID, which is passed in the callback of [`ArkUI_NodeCustomEvent`]
9643 /// when the event is triggered.
9644 ///
9645 /// * `userData` - Indicates the custom event parameter, which is passed in the callback of
9646 /// [`ArkUI_NodeCustomEvent`] when the event is triggered.
9647 ///
9648 /// # Returns
9649 ///
9650 /// * Returns the error code.
9651 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9652 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9653 /// Returns [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] if the dynamic implementation library
9654 /// of the native API was not found.
9655 pub registerNodeCustomEvent: ::core::option::Option<
9656 unsafe extern "C" fn(
9657 node: ArkUI_NodeHandle,
9658 eventType: ArkUI_NodeCustomEventType,
9659 targetId: i32,
9660 userData: *mut ::core::ffi::c_void,
9661 ) -> i32,
9662 >,
9663 /// Unregisters a custom event for a node.
9664 ///
9665 /// # Arguments
9666 ///
9667 /// * `node` - Indicates the target node.
9668 ///
9669 /// * `eventType` - Indicates the type of event to unregister.
9670 pub unregisterNodeCustomEvent: ::core::option::Option<
9671 unsafe extern "C" fn(node: ArkUI_NodeHandle, eventType: ArkUI_NodeCustomEventType),
9672 >,
9673 /// Registers a unified entry point function for custom node event callbacks.
9674 ///
9675 /// The ArkUI framework collects custom component events generated during the process and calls back the events
9676 /// through the registered <b>registerNodeCustomEventReceiver</b>.
9677 ///
9678 /// A new call to this API will overwrite the previously registered event receiver.
9679 /// Do not directly save the <b>ArkUI_NodeCustomEvent</b> object pointer.
9680 /// The data will be destroyed after the callback is complete.
9681 ///
9682 /// To bind with a component instance, you can use the <b>addNodeCustomEventReceiver</b> function.
9683 ///
9684 ///
9685 /// # Arguments
9686 ///
9687 /// * `eventReceiver` - Indicates the event receiver to register.
9688 pub registerNodeCustomEventReceiver: ::core::option::Option<
9689 unsafe extern "C" fn(
9690 eventReceiver: ::core::option::Option<
9691 unsafe extern "C" fn(event: *mut ArkUI_NodeCustomEvent),
9692 >,
9693 ),
9694 >,
9695 /// Unregisters the unified entry point function for custom node event callbacks.
9696 pub unregisterNodeCustomEventReceiver: ::core::option::Option<unsafe extern "C" fn()>,
9697 /// Sets the width and height for a component after the measurement.
9698 ///
9699 /// # Arguments
9700 ///
9701 /// * `node` - Indicates the target node.
9702 ///
9703 /// * `width` - Indicates the width.
9704 ///
9705 /// * `height` - Indicates the height.
9706 ///
9707 /// # Returns
9708 ///
9709 /// * Returns the error code.
9710 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9711 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9712 pub setMeasuredSize: ::core::option::Option<
9713 unsafe extern "C" fn(node: ArkUI_NodeHandle, width: i32, height: i32) -> i32,
9714 >,
9715 /// Sets the position for a component.
9716 ///
9717 /// # Arguments
9718 ///
9719 /// * `node` - Indicates the target node.
9720 ///
9721 /// * `positionX` - Indicates the X coordinate.
9722 ///
9723 /// * `positionY` - Indicates the Y coordinate.
9724 ///
9725 /// # Returns
9726 ///
9727 /// * Returns the error code.
9728 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9729 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9730 pub setLayoutPosition: ::core::option::Option<
9731 unsafe extern "C" fn(node: ArkUI_NodeHandle, positionX: i32, positionY: i32) -> i32,
9732 >,
9733 /// Obtains the width and height of a component after measurement.
9734 ///
9735 /// # Arguments
9736 ///
9737 /// * `node` - Indicates the target node.
9738 ///
9739 /// # Returns
9740 ///
9741 /// * Returns the width and height of the component.
9742 pub getMeasuredSize:
9743 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_IntSize>,
9744 /// Obtains the position of a component after the layout is complete.
9745 ///
9746 /// # Arguments
9747 ///
9748 /// * `node` - Indicates the target node.
9749 ///
9750 /// # Returns
9751 ///
9752 /// * Returns the position of the component.
9753 pub getLayoutPosition:
9754 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_IntOffset>,
9755 /// Measures a node. You can use the <b>getMeasuredSize</b> API to obtain the size after the measurement.
9756 ///
9757 /// # Arguments
9758 ///
9759 /// * `node` - Indicates the target node.
9760 ///
9761 /// * `Constraint` - Indicates the size constraint.
9762 ///
9763 /// # Returns
9764 ///
9765 /// * Returns the error code.
9766 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9767 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9768 pub measureNode: ::core::option::Option<
9769 unsafe extern "C" fn(
9770 node: ArkUI_NodeHandle,
9771 Constraint: *mut ArkUI_LayoutConstraint,
9772 ) -> i32,
9773 >,
9774 /// Lays outs a component and passes the expected position of the component relative to its parent component.
9775 ///
9776 /// When the component is being displayed, this API must be called in the main thread.
9777 ///
9778 /// # Arguments
9779 ///
9780 /// * `node` - Indicates the target node.
9781 ///
9782 /// * `positionX` - Indicates the X coordinate.
9783 ///
9784 /// * `positionY` - Indicates the Y coordinate.
9785 ///
9786 /// # Returns
9787 ///
9788 /// * Returns the error code.
9789 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9790 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9791 pub layoutNode: ::core::option::Option<
9792 unsafe extern "C" fn(node: ArkUI_NodeHandle, positionX: i32, positionY: i32) -> i32,
9793 >,
9794 /// Adds a component event callback function to a component to receive component events generated
9795 /// by the component.
9796 ///
9797 /// Unlike the global registration function <b>registerNodeEventReceiver</b>, this API allows multiple event
9798 /// receivers to be added to the same component.
9799 ///
9800 /// The callback added by this API is triggered before the global callback registered by
9801 /// <b>registerNodeEventReceiver</b>.
9802 ///
9803 /// Do not directly save the <b>ArkUI_NodeEvent</b> object pointer.
9804 /// The data will be destroyed after the callback is complete.
9805 ///
9806 ///
9807 /// # Arguments
9808 ///
9809 /// * `node` - Indicates the component for which you want to add the event callback function.
9810 ///
9811 /// * `eventReceiver` - Indicates the component event callback function to add.
9812 ///
9813 /// # Returns
9814 ///
9815 /// * Returns the error code.
9816 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9817 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9818 pub addNodeEventReceiver: ::core::option::Option<
9819 unsafe extern "C" fn(
9820 node: ArkUI_NodeHandle,
9821 eventReceiver: ::core::option::Option<unsafe extern "C" fn(event: *mut ArkUI_NodeEvent)>,
9822 ) -> i32,
9823 >,
9824 /// Removes the registered component event callback function from a component.
9825 ///
9826 /// # Arguments
9827 ///
9828 /// * `node` - Indicates the component from which you want to remove the event callback function.
9829 ///
9830 /// * `eventReceiver` - Indicates the component event callback function to remove.
9831 ///
9832 /// # Returns
9833 ///
9834 /// * Returns the error code.
9835 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9836 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9837 pub removeNodeEventReceiver: ::core::option::Option<
9838 unsafe extern "C" fn(
9839 node: ArkUI_NodeHandle,
9840 eventReceiver: ::core::option::Option<unsafe extern "C" fn(event: *mut ArkUI_NodeEvent)>,
9841 ) -> i32,
9842 >,
9843 /// Adds a custom event callback function to a component to receive custom events
9844 /// (such as layout and drawing events) generated by the component.
9845 ///
9846 /// Unlike the global registration function <b>registerNodeCustomEventReceiver</b>, this API allows
9847 /// multiple event receivers to be added to the same component.
9848 ///
9849 /// The callback added by this API is triggered before the global callback registered by
9850 /// <b>registerNodeCustomEventReceiver</b>.
9851 ///
9852 /// Do not directly save the <b>ArkUI_NodeCustomEvent</b> object pointer.
9853 /// The data will be destroyed after the callback is complete.
9854 ///
9855 ///
9856 /// # Arguments
9857 ///
9858 /// * `node` - Indicates the component for which you want to add the custom event callback function.
9859 ///
9860 /// * `eventReceiver` - Indicates the custom event callback function to add.
9861 ///
9862 /// # Returns
9863 ///
9864 /// * Returns the error code.
9865 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9866 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9867 pub addNodeCustomEventReceiver: ::core::option::Option<
9868 unsafe extern "C" fn(
9869 node: ArkUI_NodeHandle,
9870 eventReceiver: ::core::option::Option<
9871 unsafe extern "C" fn(event: *mut ArkUI_NodeCustomEvent),
9872 >,
9873 ) -> i32,
9874 >,
9875 /// Removes a registered custom event callback function from a component.
9876 ///
9877 /// # Arguments
9878 ///
9879 /// * `node` - Indicates the component from which you want to remove the custom event callback function.
9880 ///
9881 /// * `eventReceiver` - Indicates the custom event callback function to remove.
9882 ///
9883 /// # Returns
9884 ///
9885 /// * Returns the error code.
9886 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9887 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9888 pub removeNodeCustomEventReceiver: ::core::option::Option<
9889 unsafe extern "C" fn(
9890 node: ArkUI_NodeHandle,
9891 eventReceiver: ::core::option::Option<
9892 unsafe extern "C" fn(event: *mut ArkUI_NodeCustomEvent),
9893 >,
9894 ) -> i32,
9895 >,
9896 /// Saves custom data on the specified component.
9897 ///
9898 /// # Arguments
9899 ///
9900 /// * `node` - Indicates the component on which the custom data will be saved.
9901 ///
9902 /// * `userData` - Indicates the custom data to be saved.
9903 ///
9904 /// # Returns
9905 ///
9906 /// * Returns the error code.
9907 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9908 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs..
9909 pub setUserData: ::core::option::Option<
9910 unsafe extern "C" fn(node: ArkUI_NodeHandle, userData: *mut ::core::ffi::c_void) -> i32,
9911 >,
9912 /// Obtains the custom data saved on the specified component.
9913 ///
9914 /// # Arguments
9915 ///
9916 /// * `node` - Indicates the target component.
9917 ///
9918 /// # Returns
9919 ///
9920 /// * Returns the custom data.
9921 pub getUserData: ::core::option::Option<
9922 unsafe extern "C" fn(node: ArkUI_NodeHandle) -> *mut ::core::ffi::c_void,
9923 >,
9924 /// Sets the unit for a component.
9925 ///
9926 /// # Arguments
9927 ///
9928 /// * `node` - Indicates the component for which you want to set the unit.
9929 ///
9930 /// * `unit` - Indicates the unit, which is an enumerated value of [`ArkUI_LengthMetricUnit`].
9931 /// The default value is <b>ARKUI_LENGTH_METRIC_UNIT_DEFAULT</b>.
9932 ///
9933 /// # Returns
9934 ///
9935 /// * Returns the error code.
9936 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9937 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9938 pub setLengthMetricUnit: ::core::option::Option<
9939 unsafe extern "C" fn(node: ArkUI_NodeHandle, unit: ArkUI_LengthMetricUnit) -> i32,
9940 >,
9941 /// Get the parent node.
9942 ///
9943 /// # Arguments
9944 ///
9945 /// * `node` - target node object.
9946 ///
9947 /// # Returns
9948 ///
9949 /// * Returns the pointer of the component, if not return NULL
9950 pub getParent:
9951 ::core::option::Option<unsafe extern "C" fn(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle>,
9952 /// Uninstall all child nodes from the parent component.
9953 ///
9954 /// # Arguments
9955 ///
9956 /// * `parent` - target node object.
9957 ///
9958 /// # Returns
9959 ///
9960 /// * Returns the error code.
9961 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
9962 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
9963 ///
9964 /// Available since API-level: 12
9965 pub removeAllChildren:
9966 ::core::option::Option<unsafe extern "C" fn(parent: ArkUI_NodeHandle) -> i32>,
9967}
9968#[cfg(feature = "api-12")]
9969#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9970impl ArkUI_NodeContentEventType {
9971 /// Defines the attach event.
9972 pub const NODE_CONTENT_EVENT_ON_ATTACH_TO_WINDOW: ArkUI_NodeContentEventType =
9973 ArkUI_NodeContentEventType(0);
9974 /// Defines the detach event.
9975 pub const NODE_CONTENT_EVENT_ON_DETACH_FROM_WINDOW: ArkUI_NodeContentEventType =
9976 ArkUI_NodeContentEventType(1);
9977}
9978#[repr(transparent)]
9979/// Defines the node content event type.
9980///
9981///
9982/// Available since API-level: 12
9983#[cfg(feature = "api-12")]
9984#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
9985#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
9986pub struct ArkUI_NodeContentEventType(pub ::core::ffi::c_uint);
9987#[cfg(feature = "api-15")]
9988#[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
9989impl ArkUI_InspectorErrorCode {
9990 /// Success.
9991 pub const ARKUI_INSPECTOR_NATIVE_RESULT_SUCCESSFUL: ArkUI_InspectorErrorCode =
9992 ArkUI_InspectorErrorCode(0);
9993 /// Invalid parameter.
9994 pub const ARKUI_INSPECTOR_NATIVE_RESULT_BAD_PARAMETER: ArkUI_InspectorErrorCode =
9995 ArkUI_InspectorErrorCode(-1);
9996}
9997#[repr(transparent)]
9998/// Enumerates the inspector error codes.
9999///
10000/// Available since API-level: 15
10001#[cfg(feature = "api-15")]
10002#[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
10003#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
10004pub struct ArkUI_InspectorErrorCode(pub ::core::ffi::c_int);
10005/// Defines the general structure of a node content event.
10006///
10007/// Available since API-level: 12
10008#[cfg(feature = "api-12")]
10009#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10010#[repr(C)]
10011pub struct ArkUI_NodeContentEvent {
10012 _unused: [u8; 0],
10013}
10014/// Defines the callback function of a node content event.
10015///
10016/// Available since API-level: 12
10017#[cfg(feature = "api-12")]
10018#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10019pub type ArkUI_NodeContentCallback =
10020 ::core::option::Option<unsafe extern "C" fn(event: *mut ArkUI_NodeContentEvent)>;
10021extern "C" {
10022 /// Obtains the type of a component event.
10023 ///
10024 /// # Arguments
10025 ///
10026 /// * `event` - Indicates the pointer to the component event.
10027 ///
10028 /// # Returns
10029 ///
10030 /// * Returns the type of the component event.
10031 ///
10032 /// Available since API-level: 12
10033 #[cfg(feature = "api-12")]
10034 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10035 pub fn OH_ArkUI_NodeEvent_GetEventType(event: *mut ArkUI_NodeEvent) -> ArkUI_NodeEventType;
10036 /// Obtains the custom ID of a component event.
10037 ///
10038 /// The event ID is passed in as a parameter when the [`registerNodeEvent`] function is called and can be applied
10039 /// to the dispatch logic of the same event entry function [`registerNodeEventReceiver`].
10040 ///
10041 /// # Arguments
10042 ///
10043 /// * `event` - Indicates the pointer to the component event.
10044 ///
10045 /// # Returns
10046 ///
10047 /// * Returns the custom ID of the component event.
10048 ///
10049 /// Available since API-level: 12
10050 #[cfg(feature = "api-12")]
10051 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10052 pub fn OH_ArkUI_NodeEvent_GetTargetId(event: *mut ArkUI_NodeEvent) -> i32;
10053 /// Obtains the component object that triggers a component event.
10054 ///
10055 /// # Arguments
10056 ///
10057 /// * `event` - Indicates the pointer to the component event.
10058 ///
10059 /// # Returns
10060 ///
10061 /// * Returns the component object that triggers the component event.
10062 ///
10063 /// Available since API-level: 12
10064 #[cfg(feature = "api-12")]
10065 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10066 pub fn OH_ArkUI_NodeEvent_GetNodeHandle(event: *mut ArkUI_NodeEvent) -> ArkUI_NodeHandle;
10067 /// Obtains input event (for example, touch event) data for a component event.
10068 ///
10069 /// # Arguments
10070 ///
10071 /// * `event` - Indicates the pointer to the component event.
10072 ///
10073 /// # Returns
10074 ///
10075 /// * Returns the pointer to the input event data.
10076 ///
10077 /// Available since API-level: 12
10078 #[cfg(feature = "api-12")]
10079 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10080 pub fn OH_ArkUI_NodeEvent_GetInputEvent(event: *mut ArkUI_NodeEvent)
10081 -> *mut ArkUI_UIInputEvent;
10082 /// Obtains the numerical data in a component event.
10083 ///
10084 /// # Arguments
10085 ///
10086 /// * `event` - Indicates the pointer to the component event.
10087 ///
10088 /// # Returns
10089 ///
10090 /// * Returns the pointer to the numerical data.
10091 ///
10092 /// Available since API-level: 12
10093 #[cfg(feature = "api-12")]
10094 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10095 pub fn OH_ArkUI_NodeEvent_GetNodeComponentEvent(
10096 event: *mut ArkUI_NodeEvent,
10097 ) -> *mut ArkUI_NodeComponentEvent;
10098 /// Obtains the string data in a component event.
10099 ///
10100 /// # Arguments
10101 ///
10102 /// * `event` - Indicates the pointer to the component event.
10103 ///
10104 /// # Returns
10105 ///
10106 /// * Returns the pointer to the string data.
10107 ///
10108 /// Available since API-level: 12
10109 #[cfg(feature = "api-12")]
10110 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10111 pub fn OH_ArkUI_NodeEvent_GetStringAsyncEvent(
10112 event: *mut ArkUI_NodeEvent,
10113 ) -> *mut ArkUI_StringAsyncEvent;
10114 /// Obtains the ArkUI_TextChangeEvent data from a component event.
10115 ///
10116 /// # Arguments
10117 ///
10118 /// * `event` - Pointer to a component event. It cannot be null.
10119 ///
10120 /// # Returns
10121 ///
10122 /// * Returns the pointer to the <b>ArkUI_TextChangeEvent</b> object.
10123 ///
10124 /// Available since API-level: 15
10125 #[cfg(feature = "api-15")]
10126 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
10127 pub fn OH_ArkUI_NodeEvent_GetTextChangeEvent(
10128 event: *mut ArkUI_NodeEvent,
10129 ) -> *mut ArkUI_TextChangeEvent;
10130 /// Obtains the custom data in a component event.
10131 ///
10132 /// This parameter is passed in [`registerNodeEvent`] and can be applied to the service logic when the event
10133 /// is triggered.
10134 ///
10135 /// # Arguments
10136 ///
10137 /// * `event` - Indicates the pointer to the component event.
10138 ///
10139 /// # Returns
10140 ///
10141 /// * Returns the pointer to the custom data.
10142 ///
10143 /// Available since API-level: 12
10144 #[cfg(feature = "api-12")]
10145 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10146 pub fn OH_ArkUI_NodeEvent_GetUserData(event: *mut ArkUI_NodeEvent) -> *mut ::core::ffi::c_void;
10147 /// Obtains the numeric-type parameter of a component event.
10148 ///
10149 /// # Arguments
10150 ///
10151 /// * `event` - Indicates the pointer to the component event.
10152 ///
10153 /// * `index` - Indicates the index of the return value.
10154 ///
10155 /// * `value` - Indicates the return value.
10156 ///
10157 /// # Returns
10158 ///
10159 /// * Returns the error code.
10160 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10161 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_PARAM_INDEX_OUT_OF_RANGE`] if the parameter length exceeds
10162 /// the limit.
10163 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_PARAM_INVALID`] if the data does not exist in the component event.
10164 ///
10165 /// Available since API-level: 12
10166 #[cfg(feature = "api-12")]
10167 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10168 pub fn OH_ArkUI_NodeEvent_GetNumberValue(
10169 event: *mut ArkUI_NodeEvent,
10170 index: i32,
10171 value: *mut ArkUI_NumberValue,
10172 ) -> i32;
10173 /// Obtains the string-type parameter of a component event. The string data is valid only during an event
10174 /// callback. To use it outside an event callback, you are advised to copy the string data.
10175 ///
10176 /// # Arguments
10177 ///
10178 /// * `event` - Indicates the pointer to the component event.
10179 ///
10180 /// * `index` - Indicates the index of the return value.
10181 ///
10182 /// * `string` - Indicates the pointer to the string array.
10183 ///
10184 /// * `stringSize` - Indicates the length of the string array.
10185 ///
10186 /// # Returns
10187 ///
10188 /// * Returns the error code.
10189 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10190 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_PARAM_INDEX_OUT_OF_RANGE`] if the parameter length exceeds
10191 /// the limit.
10192 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_PARAM_INVALID`] if the data does not exist in the component event.
10193 ///
10194 /// Available since API-level: 12
10195 #[cfg(feature = "api-12")]
10196 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10197 pub fn OH_ArkUI_NodeEvent_GetStringValue(
10198 event: *mut ArkUI_NodeEvent,
10199 index: i32,
10200 string: *mut *mut ::core::ffi::c_char,
10201 stringSize: *mut i32,
10202 ) -> i32;
10203 /// Sets the return value for a component event.
10204 ///
10205 /// # Arguments
10206 ///
10207 /// * `event` - Indicates the pointer to the component event.
10208 ///
10209 /// * `value` - Indicates the numeric-type array.
10210 ///
10211 /// * `size` - Indicates the array length.
10212 ///
10213 /// # Returns
10214 ///
10215 /// * Returns the error code.
10216 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10217 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_NO_RETURN`] if the component event does not support return values.
10218 /// Returns [`ARKUI_ERROR_CODE_NODE_EVENT_PARAM_INVALID`] if data does not exist in the component event.
10219 ///
10220 /// Available since API-level: 12
10221 #[cfg(feature = "api-12")]
10222 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10223 pub fn OH_ArkUI_NodeEvent_SetReturnNumberValue(
10224 event: *mut ArkUI_NodeEvent,
10225 value: *mut ArkUI_NumberValue,
10226 size: i32,
10227 ) -> i32;
10228 /// Creates a component adapter.
10229 ///
10230 ///
10231 /// Available since API-level: 12
10232 #[cfg(feature = "api-12")]
10233 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10234 pub fn OH_ArkUI_NodeAdapter_Create() -> ArkUI_NodeAdapterHandle;
10235 /// Destroys a component adapter.
10236 ///
10237 /// # Arguments
10238 ///
10239 /// * `handle` - Indicates the target component adapter.
10240 ///
10241 /// Available since API-level: 12
10242 #[cfg(feature = "api-12")]
10243 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10244 pub fn OH_ArkUI_NodeAdapter_Dispose(handle: ArkUI_NodeAdapterHandle);
10245 /// Sets the total number of elements in the specified adapter.
10246 ///
10247 /// # Arguments
10248 ///
10249 /// * `handle` - Indicates the target component adapter.
10250 ///
10251 /// * `size` - Indicates the number of elements.
10252 ///
10253 /// # Returns
10254 ///
10255 /// * Returns the error code.
10256 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10257 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10258 ///
10259 /// Available since API-level: 12
10260 #[cfg(feature = "api-12")]
10261 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10262 pub fn OH_ArkUI_NodeAdapter_SetTotalNodeCount(
10263 handle: ArkUI_NodeAdapterHandle,
10264 size: u32,
10265 ) -> i32;
10266 /// Obtains the total number of elements in the specified adapter.
10267 ///
10268 /// # Arguments
10269 ///
10270 /// * `handle` - Indicates the target component adapter.
10271 ///
10272 /// # Returns
10273 ///
10274 /// * Returns the total number of elements in the adapter.
10275 ///
10276 /// Available since API-level: 12
10277 #[cfg(feature = "api-12")]
10278 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10279 pub fn OH_ArkUI_NodeAdapter_GetTotalNodeCount(handle: ArkUI_NodeAdapterHandle) -> u32;
10280 /// Registers an event callback for the adapter.
10281 ///
10282 /// # Arguments
10283 ///
10284 /// * `handle` - Indicates the target component adapter.
10285 ///
10286 /// * `userData` - Indicates custom data.
10287 ///
10288 /// * `receiver` - Indicates the event receiver callback.
10289 ///
10290 /// # Returns
10291 ///
10292 /// * Returns the error code.
10293 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10294 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10295 ///
10296 /// Available since API-level: 12
10297 #[cfg(feature = "api-12")]
10298 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10299 pub fn OH_ArkUI_NodeAdapter_RegisterEventReceiver(
10300 handle: ArkUI_NodeAdapterHandle,
10301 userData: *mut ::core::ffi::c_void,
10302 receiver: ::core::option::Option<unsafe extern "C" fn(event: *mut ArkUI_NodeAdapterEvent)>,
10303 ) -> i32;
10304 /// Deregisters an event callback for the adapter.
10305 ///
10306 /// # Arguments
10307 ///
10308 /// * `handle` - Indicates the target component adapter.
10309 ///
10310 /// Available since API-level: 12
10311 #[cfg(feature = "api-12")]
10312 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10313 pub fn OH_ArkUI_NodeAdapter_UnregisterEventReceiver(handle: ArkUI_NodeAdapterHandle);
10314 /// Instructs the specified adapter to reload all elements.
10315 ///
10316 /// # Arguments
10317 ///
10318 /// * `handle` - Indicates the target component adapter.
10319 ///
10320 /// # Returns
10321 ///
10322 /// * Returns the error code.
10323 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10324 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10325 ///
10326 /// Available since API-level: 12
10327 #[cfg(feature = "api-12")]
10328 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10329 pub fn OH_ArkUI_NodeAdapter_ReloadAllItems(handle: ArkUI_NodeAdapterHandle) -> i32;
10330 /// Instructs the specified adapter to reload certain elements.
10331 ///
10332 /// # Arguments
10333 ///
10334 /// * `handle` - Indicates the target component adapter.
10335 ///
10336 /// * `startPosition` - Indicates the start position of the elements to reload.
10337 ///
10338 /// * `itemCount` - Indicates the number of the elements to reload.
10339 ///
10340 /// # Returns
10341 ///
10342 /// * Returns the error code.
10343 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10344 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10345 ///
10346 /// Available since API-level: 12
10347 #[cfg(feature = "api-12")]
10348 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10349 pub fn OH_ArkUI_NodeAdapter_ReloadItem(
10350 handle: ArkUI_NodeAdapterHandle,
10351 startPosition: u32,
10352 itemCount: u32,
10353 ) -> i32;
10354 /// Instructs the specified adapter to remove certain elements.
10355 ///
10356 /// # Arguments
10357 ///
10358 /// * `handle` - Indicates the target component adapter.
10359 ///
10360 /// * `startPosition` - Indicates the start position of the elements to remove.
10361 ///
10362 /// * `itemCount` - Indicates the number of the elements to remove.
10363 ///
10364 /// # Returns
10365 ///
10366 /// * Returns the error code.
10367 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10368 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10369 ///
10370 /// Available since API-level: 12
10371 #[cfg(feature = "api-12")]
10372 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10373 pub fn OH_ArkUI_NodeAdapter_RemoveItem(
10374 handle: ArkUI_NodeAdapterHandle,
10375 startPosition: u32,
10376 itemCount: u32,
10377 ) -> i32;
10378 /// Instructs the specified adapter to insert certain elements.
10379 ///
10380 /// # Arguments
10381 ///
10382 /// * `handle` - Indicates the target component adapter.
10383 ///
10384 /// * `startPosition` - Indicates the start position of the elements to insert.
10385 ///
10386 /// * `itemCount` - Indicates the number of the elements to insert.
10387 ///
10388 /// # Returns
10389 ///
10390 /// * Returns the error code.
10391 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10392 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10393 ///
10394 /// Available since API-level: 12
10395 #[cfg(feature = "api-12")]
10396 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10397 pub fn OH_ArkUI_NodeAdapter_InsertItem(
10398 handle: ArkUI_NodeAdapterHandle,
10399 startPosition: u32,
10400 itemCount: u32,
10401 ) -> i32;
10402 /// Instructs the specified adapter to move certain elements.
10403 ///
10404 /// # Arguments
10405 ///
10406 /// * `handle` - Indicates the target component adapter.
10407 ///
10408 /// * `from` - Indicates the start position of the elements to move.
10409 ///
10410 /// * `to` - Indicates the end position of the elements to move.
10411 ///
10412 /// # Returns
10413 ///
10414 /// * Returns the error code.
10415 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10416 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10417 ///
10418 /// Available since API-level: 12
10419 #[cfg(feature = "api-12")]
10420 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10421 pub fn OH_ArkUI_NodeAdapter_MoveItem(
10422 handle: ArkUI_NodeAdapterHandle,
10423 from: u32,
10424 to: u32,
10425 ) -> i32;
10426 /// Obtains all elements stored in the specified adapter.
10427 ///
10428 /// This API returns the pointer to the array of the elements. You need to manually release the memory data
10429 /// to which the pointer points.
10430 ///
10431 /// # Arguments
10432 ///
10433 /// * `handle` - Indicates the target component adapter.
10434 ///
10435 /// * `items` - Indicates the pointer to the array of the elements in the adapter.
10436 ///
10437 /// * `size` - Indicates the number of elements.
10438 ///
10439 /// # Returns
10440 ///
10441 /// * Returns the error code.
10442 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10443 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10444 ///
10445 /// Available since API-level: 12
10446 #[cfg(feature = "api-12")]
10447 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10448 pub fn OH_ArkUI_NodeAdapter_GetAllItems(
10449 handle: ArkUI_NodeAdapterHandle,
10450 items: *mut *mut ArkUI_NodeHandle,
10451 size: *mut u32,
10452 ) -> i32;
10453 /// Obtains the custom data passed in during registration of the specified event.
10454 ///
10455 /// # Arguments
10456 ///
10457 /// * `event` - Indicates the target adapter event.
10458 ///
10459 /// Available since API-level: 12
10460 #[cfg(feature = "api-12")]
10461 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10462 pub fn OH_ArkUI_NodeAdapterEvent_GetUserData(
10463 event: *mut ArkUI_NodeAdapterEvent,
10464 ) -> *mut ::core::ffi::c_void;
10465 /// Obtains the event type.
10466 ///
10467 /// # Arguments
10468 ///
10469 /// * `event` - Indicates the target adapter event.
10470 ///
10471 /// # Returns
10472 ///
10473 /// * Returns the event type.
10474 ///
10475 /// Available since API-level: 12
10476 #[cfg(feature = "api-12")]
10477 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10478 pub fn OH_ArkUI_NodeAdapterEvent_GetType(
10479 event: *mut ArkUI_NodeAdapterEvent,
10480 ) -> ArkUI_NodeAdapterEventType;
10481 /// Obtains the element to be removed for the event to be destroyed.
10482 ///
10483 /// # Arguments
10484 ///
10485 /// * `event` - Indicates the target adapter event.
10486 ///
10487 /// # Returns
10488 ///
10489 /// * Returns the element to be removed.
10490 ///
10491 /// Available since API-level: 12
10492 #[cfg(feature = "api-12")]
10493 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10494 pub fn OH_ArkUI_NodeAdapterEvent_GetRemovedNode(
10495 event: *mut ArkUI_NodeAdapterEvent,
10496 ) -> ArkUI_NodeHandle;
10497 /// Obtains the index of the element to be operated for the specified adapter event.
10498 ///
10499 /// # Arguments
10500 ///
10501 /// * `event` - Indicates the target adapter event.
10502 ///
10503 /// # Returns
10504 ///
10505 /// * Returns the index of the element.
10506 ///
10507 /// Available since API-level: 12
10508 #[cfg(feature = "api-12")]
10509 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10510 pub fn OH_ArkUI_NodeAdapterEvent_GetItemIndex(event: *mut ArkUI_NodeAdapterEvent) -> u32;
10511 /// Obtains the scrollable container node that uses the specified adapter.
10512 ///
10513 /// # Arguments
10514 ///
10515 /// * `event` - Indicates the target adapter event.
10516 ///
10517 /// # Returns
10518 ///
10519 /// * Returns the scrollable container node that uses the specified adapter.
10520 ///
10521 /// Available since API-level: 12
10522 #[cfg(feature = "api-12")]
10523 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10524 pub fn OH_ArkUI_NodeAdapterEvent_GetHostNode(
10525 event: *mut ArkUI_NodeAdapterEvent,
10526 ) -> ArkUI_NodeHandle;
10527 /// Sets the component to be added to the specified adapter.
10528 ///
10529 /// # Arguments
10530 ///
10531 /// * `event` - Indicates the target adapter event.
10532 ///
10533 /// * `node` - Indicates the component to be added.
10534 ///
10535 /// # Returns
10536 ///
10537 /// * Returns the error code.
10538 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10539 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10540 ///
10541 /// Available since API-level: 12
10542 #[cfg(feature = "api-12")]
10543 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10544 pub fn OH_ArkUI_NodeAdapterEvent_SetItem(
10545 event: *mut ArkUI_NodeAdapterEvent,
10546 node: ArkUI_NodeHandle,
10547 ) -> i32;
10548 /// Sets the component ID to be generated.
10549 ///
10550 /// # Arguments
10551 ///
10552 /// * `event` - Indicates the target adapter event.
10553 ///
10554 /// * `id` - Indicates the component ID to set.
10555 ///
10556 /// # Returns
10557 ///
10558 /// * Returns the error code.
10559 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10560 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10561 ///
10562 /// Available since API-level: 12
10563 #[cfg(feature = "api-12")]
10564 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10565 pub fn OH_ArkUI_NodeAdapterEvent_SetNodeId(event: *mut ArkUI_NodeAdapterEvent, id: i32) -> i32;
10566 /// Obtains the size constraint for measurement through a custom component event.
10567 ///
10568 /// # Arguments
10569 ///
10570 /// * `event` - Indicates the pointer to the custom component event.
10571 ///
10572 /// # Returns
10573 ///
10574 /// * Returns the pointer to the size constraint.
10575 ///
10576 /// Available since API-level: 12
10577 #[cfg(feature = "api-12")]
10578 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10579 pub fn OH_ArkUI_NodeCustomEvent_GetLayoutConstraintInMeasure(
10580 event: *mut ArkUI_NodeCustomEvent,
10581 ) -> *mut ArkUI_LayoutConstraint;
10582 /// Obtains the expected position of a component relative to its parent component in the layout phase through a
10583 /// custom component event.
10584 ///
10585 /// # Arguments
10586 ///
10587 /// * `event` - Indicates the pointer to the custom component event.
10588 ///
10589 /// # Returns
10590 ///
10591 /// * Returns the expected position relative to the parent component.
10592 ///
10593 /// Available since API-level: 12
10594 #[cfg(feature = "api-12")]
10595 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10596 pub fn OH_ArkUI_NodeCustomEvent_GetPositionInLayout(
10597 event: *mut ArkUI_NodeCustomEvent,
10598 ) -> ArkUI_IntOffset;
10599 /// Obtains the drawing context through a custom component event.
10600 ///
10601 /// # Arguments
10602 ///
10603 /// * `event` - Indicates the pointer to the custom component event.
10604 ///
10605 /// # Returns
10606 ///
10607 /// * Returns the drawing context.
10608 ///
10609 /// Available since API-level: 12
10610 #[cfg(feature = "api-12")]
10611 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10612 pub fn OH_ArkUI_NodeCustomEvent_GetDrawContextInDraw(
10613 event: *mut ArkUI_NodeCustomEvent,
10614 ) -> *mut ArkUI_DrawContext;
10615 /// Obtains the ID of a custom component event.
10616 ///
10617 /// # Arguments
10618 ///
10619 /// * `event` - Indicates the pointer to the custom component event.
10620 ///
10621 /// # Returns
10622 ///
10623 /// * Returns the ID of the custom component event.
10624 ///
10625 /// Available since API-level: 12
10626 #[cfg(feature = "api-12")]
10627 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10628 pub fn OH_ArkUI_NodeCustomEvent_GetEventTargetId(event: *mut ArkUI_NodeCustomEvent) -> i32;
10629 /// Obtains custom event parameters through a custom component event.
10630 ///
10631 /// # Arguments
10632 ///
10633 /// * `event` - Indicates the pointer to the custom component event.
10634 ///
10635 /// # Returns
10636 ///
10637 /// * Returns the custom event parameters.
10638 ///
10639 /// Available since API-level: 12
10640 #[cfg(feature = "api-12")]
10641 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10642 pub fn OH_ArkUI_NodeCustomEvent_GetUserData(
10643 event: *mut ArkUI_NodeCustomEvent,
10644 ) -> *mut ::core::ffi::c_void;
10645 /// Obtains a component object through a custom component event.
10646 ///
10647 /// # Arguments
10648 ///
10649 /// * `event` - Indicates the pointer to the custom component event.
10650 ///
10651 /// # Returns
10652 ///
10653 /// * Returns the component object.
10654 ///
10655 /// Available since API-level: 12
10656 #[cfg(feature = "api-12")]
10657 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10658 pub fn OH_ArkUI_NodeCustomEvent_GetNodeHandle(
10659 event: *mut ArkUI_NodeCustomEvent,
10660 ) -> ArkUI_NodeHandle;
10661 /// Obtains the event type through a custom component event.
10662 ///
10663 /// # Arguments
10664 ///
10665 /// * `event` - Indicates the pointer to the custom component event.
10666 ///
10667 /// # Returns
10668 ///
10669 /// * Returns the type of the custom component event.
10670 ///
10671 /// Available since API-level: 12
10672 #[cfg(feature = "api-12")]
10673 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10674 pub fn OH_ArkUI_NodeCustomEvent_GetEventType(
10675 event: *mut ArkUI_NodeCustomEvent,
10676 ) -> ArkUI_NodeCustomEventType;
10677 /// Obtains the measurement information of a custom span through a custom component event.
10678 ///
10679 /// # Arguments
10680 ///
10681 /// * `event` - Indicates the pointer to the custom component event.
10682 ///
10683 /// * `info` - Indicates the measurement information to be obtained.
10684 ///
10685 /// # Returns
10686 ///
10687 /// * Returns the result code.
10688 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10689 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10690 /// <br> Possible causes: Parameter verification failed, the parameter should not be nullptr.
10691 ///
10692 /// Available since API-level: 12
10693 #[cfg(feature = "api-12")]
10694 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10695 pub fn OH_ArkUI_NodeCustomEvent_GetCustomSpanMeasureInfo(
10696 event: *mut ArkUI_NodeCustomEvent,
10697 info: *mut ArkUI_CustomSpanMeasureInfo,
10698 ) -> i32;
10699 /// Sets the measurement metrics of a custom span through a custom component event.
10700 ///
10701 /// # Arguments
10702 ///
10703 /// * `event` - Indicates the pointer to the custom component event.
10704 ///
10705 /// * `metrics` - Indicates the measurement metrics to set.
10706 ///
10707 /// # Returns
10708 ///
10709 /// * Returns the result code.
10710 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10711 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10712 /// <br> Possible causes: Parameter verification failed, the parameter should not be nullptr.
10713 ///
10714 /// Available since API-level: 12
10715 #[cfg(feature = "api-12")]
10716 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10717 pub fn OH_ArkUI_NodeCustomEvent_SetCustomSpanMetrics(
10718 event: *mut ArkUI_NodeCustomEvent,
10719 metrics: *mut ArkUI_CustomSpanMetrics,
10720 ) -> i32;
10721 /// Obtains the drawing information of a custom span through a custom component event.
10722 ///
10723 /// # Arguments
10724 ///
10725 /// * `event` - Indicates the pointer to the custom component event.
10726 ///
10727 /// * `info` - Indicates the drawing information to obtain.
10728 ///
10729 /// # Returns
10730 ///
10731 /// * Returns the result code.
10732 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10733 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10734 /// <br> Possible causes: Parameter verification failed, the parameter should not be nullptr.
10735 ///
10736 /// Available since API-level: 12
10737 #[cfg(feature = "api-12")]
10738 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10739 pub fn OH_ArkUI_NodeCustomEvent_GetCustomSpanDrawInfo(
10740 event: *mut ArkUI_NodeCustomEvent,
10741 info: *mut ArkUI_CustomSpanDrawInfo,
10742 ) -> i32;
10743 /// register a callback function to a node content.
10744 ///
10745 /// # Arguments
10746 ///
10747 /// * `content` - Indicates the pointer to the node content instance.
10748 ///
10749 /// * `callback` - Indicates the callback function.
10750 ///
10751 /// # Returns
10752 ///
10753 /// * Returns the error code.
10754 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10755 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10756 ///
10757 /// Available since API-level: 12
10758 #[cfg(feature = "api-12")]
10759 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10760 pub fn OH_ArkUI_NodeContent_RegisterCallback(
10761 content: ArkUI_NodeContentHandle,
10762 callback: ArkUI_NodeContentCallback,
10763 ) -> i32;
10764 /// Obtains the type of a node content event.
10765 ///
10766 /// # Arguments
10767 ///
10768 /// * `event` - Indicates the pointer to the node content event.
10769 ///
10770 /// # Returns
10771 ///
10772 /// * Returns the type of the node content event.
10773 ///
10774 /// Available since API-level: 12
10775 #[cfg(feature = "api-12")]
10776 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10777 pub fn OH_ArkUI_NodeContentEvent_GetEventType(
10778 event: *mut ArkUI_NodeContentEvent,
10779 ) -> ArkUI_NodeContentEventType;
10780 /// Obtains the node content object that triggers a node content event.
10781 ///
10782 /// # Arguments
10783 ///
10784 /// * `event` - Indicates the pointer to the node content event.
10785 ///
10786 /// # Returns
10787 ///
10788 /// * Returns the node content object that triggers the node content event.
10789 ///
10790 /// Available since API-level: 12
10791 #[cfg(feature = "api-12")]
10792 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10793 pub fn OH_ArkUI_NodeContentEvent_GetNodeContentHandle(
10794 event: *mut ArkUI_NodeContentEvent,
10795 ) -> ArkUI_NodeContentHandle;
10796 /// Saves custom data on the specified node content.
10797 ///
10798 /// # Arguments
10799 ///
10800 /// * `content` - Indicates the node content on which the custom data will be saved.
10801 ///
10802 /// * `userData` - Indicates the custom data to be saved.
10803 ///
10804 /// # Returns
10805 ///
10806 /// * Returns the error code.
10807 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10808 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10809 ///
10810 /// Available since API-level: 12
10811 #[cfg(feature = "api-12")]
10812 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10813 pub fn OH_ArkUI_NodeContent_SetUserData(
10814 content: ArkUI_NodeContentHandle,
10815 userData: *mut ::core::ffi::c_void,
10816 ) -> i32;
10817 /// Obtains the custom data saved on the specified node content.
10818 ///
10819 /// # Arguments
10820 ///
10821 /// * `content` - Indicates the target node content.
10822 ///
10823 /// # Returns
10824 ///
10825 /// * Returns the custom data.
10826 ///
10827 /// Available since API-level: 12
10828 #[cfg(feature = "api-12")]
10829 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10830 pub fn OH_ArkUI_NodeContent_GetUserData(
10831 content: ArkUI_NodeContentHandle,
10832 ) -> *mut ::core::ffi::c_void;
10833 /// Add a node to a node content.
10834 ///
10835 /// # Arguments
10836 ///
10837 /// * `content` - Indicates the pointer to the node content instance.
10838 ///
10839 /// * `node` - Indicates the pointer to the node
10840 ///
10841 /// # Returns
10842 ///
10843 /// * Returns the error code.
10844 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10845 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10846 ///
10847 /// Available since API-level: 12
10848 #[cfg(feature = "api-12")]
10849 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10850 pub fn OH_ArkUI_NodeContent_AddNode(
10851 content: ArkUI_NodeContentHandle,
10852 node: ArkUI_NodeHandle,
10853 ) -> i32;
10854 /// remove a node from a node content.
10855 ///
10856 /// # Arguments
10857 ///
10858 /// * `content` - Indicates the pointer to the node content instance.
10859 ///
10860 /// * `node` - Indicates the pointer to the node
10861 ///
10862 /// # Returns
10863 ///
10864 /// * Returns the error code.
10865 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10866 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10867 ///
10868 /// Available since API-level: 12
10869 #[cfg(feature = "api-12")]
10870 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10871 pub fn OH_ArkUI_NodeContent_RemoveNode(
10872 content: ArkUI_NodeContentHandle,
10873 node: ArkUI_NodeHandle,
10874 ) -> i32;
10875 /// insert a node into a node content at a given position.
10876 ///
10877 /// # Arguments
10878 ///
10879 /// * `content` - Indicates the pointer to the node content instance.
10880 ///
10881 /// * `node` - Indicates the pointer to the node
10882 ///
10883 /// * `position` - Indicates the position for inserting the node
10884 ///
10885 /// # Returns
10886 ///
10887 /// * Returns the error code.
10888 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10889 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10890 ///
10891 /// Available since API-level: 12
10892 #[cfg(feature = "api-12")]
10893 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10894 pub fn OH_ArkUI_NodeContent_InsertNode(
10895 content: ArkUI_NodeContentHandle,
10896 node: ArkUI_NodeHandle,
10897 position: i32,
10898 ) -> i32;
10899 /// Get the size of the component layout area.
10900 /// The layout area size does not include graphic variation attributes such as scaling.
10901 ///
10902 /// # Arguments
10903 ///
10904 /// * `node` - ArkUI_NodeHandle pointer.
10905 ///
10906 /// * `size` - The drawing area size of the component handle, in px.
10907 ///
10908 /// # Returns
10909 ///
10910 /// * Returns the error code.
10911 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10912 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10913 ///
10914 /// Available since API-level: 12
10915 #[cfg(feature = "api-12")]
10916 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10917 pub fn OH_ArkUI_NodeUtils_GetLayoutSize(
10918 node: ArkUI_NodeHandle,
10919 size: *mut ArkUI_IntSize,
10920 ) -> i32;
10921 /// Obtain the position of the component layout area relative to the parent component.
10922 /// The relative position of the layout area does not include graphic variation attributes, such as translation.
10923 ///
10924 /// # Arguments
10925 ///
10926 /// * `node` - ArkUI_NodeHandle pointer.
10927 ///
10928 /// * `localOffset` - The offset value of the component handle relative to the parent component, in px.
10929 ///
10930 /// # Returns
10931 ///
10932 /// * Returns the error code.
10933 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10934 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10935 ///
10936 /// Available since API-level: 12
10937 #[cfg(feature = "api-12")]
10938 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10939 pub fn OH_ArkUI_NodeUtils_GetLayoutPosition(
10940 node: ArkUI_NodeHandle,
10941 localOffset: *mut ArkUI_IntOffset,
10942 ) -> i32;
10943 /// Obtain the position of the component layout area relative to the window.
10944 /// The relative position of the layout area does not include graphic variation attributes, such as translation.
10945 ///
10946 /// # Arguments
10947 ///
10948 /// * `node` - ArkUI_NodeHandle pointer.
10949 ///
10950 /// * `globalOffset` - The offset value of the component handle relative to the window, in px.
10951 ///
10952 /// # Returns
10953 ///
10954 /// * Returns the error code.
10955 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10956 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10957 ///
10958 /// Available since API-level: 12
10959 #[cfg(feature = "api-12")]
10960 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10961 pub fn OH_ArkUI_NodeUtils_GetLayoutPositionInWindow(
10962 node: ArkUI_NodeHandle,
10963 globalOffset: *mut ArkUI_IntOffset,
10964 ) -> i32;
10965 /// Obtain the position of the component layout area relative to the screen.
10966 /// The relative position of the layout area does not include graphic variation attributes, such as translation.
10967 ///
10968 /// # Arguments
10969 ///
10970 /// * `node` - ArkUI_NodeHandle pointer.
10971 ///
10972 /// * `screenOffset` - The offset value of the component handle relative to the screen, in px.
10973 ///
10974 /// # Returns
10975 ///
10976 /// * Returns the error code.
10977 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
10978 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
10979 ///
10980 /// Available since API-level: 12
10981 #[cfg(feature = "api-12")]
10982 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10983 pub fn OH_ArkUI_NodeUtils_GetLayoutPositionInScreen(
10984 node: ArkUI_NodeHandle,
10985 screenOffset: *mut ArkUI_IntOffset,
10986 ) -> i32;
10987 /// Obtain the position of the component in the window, including the properties of graphic translation changes.
10988 ///
10989 /// # Arguments
10990 ///
10991 /// * `node` - ArkUI_NodeHandle pointer.
10992 ///
10993 /// * `translateOffset` - The cumulative offset value of the component handle itself,
10994 /// parent components, and ancestor nodes, in px.
10995 ///
10996 /// # Returns
10997 ///
10998 /// * Returns the error code.
10999 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
11000 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
11001 ///
11002 /// Available since API-level: 12
11003 #[cfg(feature = "api-12")]
11004 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11005 pub fn OH_ArkUI_NodeUtils_GetPositionWithTranslateInWindow(
11006 node: ArkUI_NodeHandle,
11007 translateOffset: *mut ArkUI_IntOffset,
11008 ) -> i32;
11009 /// Obtain the position of the component on the screen, including the attributes of graphic translation changes.
11010 ///
11011 /// # Arguments
11012 ///
11013 /// * `node` - ArkUI_NodeHandle pointer.
11014 ///
11015 /// * `translateOffset` - The cumulative offset value of the component handle itself,
11016 /// parent components, and ancestor nodes, in px.
11017 ///
11018 /// # Returns
11019 ///
11020 /// * Returns the error code.
11021 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
11022 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
11023 ///
11024 /// Available since API-level: 12
11025 #[cfg(feature = "api-12")]
11026 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11027 pub fn OH_ArkUI_NodeUtils_GetPositionWithTranslateInScreen(
11028 node: ArkUI_NodeHandle,
11029 translateOffset: *mut ArkUI_IntOffset,
11030 ) -> i32;
11031 /// Add the custom property of the component. This interface only works on the main thread.
11032 ///
11033 /// # Arguments
11034 ///
11035 /// * `node` - ArkUI_NodeHandle pointer.
11036 ///
11037 /// * `name` - The name of the custom property. Passing null pointers is not allowed.
11038 ///
11039 /// * `value` - The value of the custom property. Passing null pointers is not allowed.
11040 ///
11041 /// Available since API-level: 13
11042 #[cfg(feature = "api-13")]
11043 #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
11044 pub fn OH_ArkUI_NodeUtils_AddCustomProperty(
11045 node: ArkUI_NodeHandle,
11046 name: *const ::core::ffi::c_char,
11047 value: *const ::core::ffi::c_char,
11048 );
11049 /// Remove the custom property of the component.
11050 ///
11051 /// # Arguments
11052 ///
11053 /// * `node` - ArkUI_NodeHandle pointer.
11054 ///
11055 /// * `name` - The name of the custom property.
11056 ///
11057 /// Available since API-level: 13
11058 #[cfg(feature = "api-13")]
11059 #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
11060 pub fn OH_ArkUI_NodeUtils_RemoveCustomProperty(
11061 node: ArkUI_NodeHandle,
11062 name: *const ::core::ffi::c_char,
11063 );
11064 /// Get the value of the custom property of the component.
11065 ///
11066 /// # Arguments
11067 ///
11068 /// * `node` - ArkUI-NodeHandle pointer.
11069 ///
11070 /// * `name` - The name of the custom attribute.
11071 ///
11072 /// * `handle` - The structure of the custom attribute corresponding to the key parameter name obtained.
11073 ///
11074 /// # Returns
11075 ///
11076 /// * Error code.
11077 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11078 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11079 ///
11080 /// Available since API-level: 14
11081 #[cfg(feature = "api-14")]
11082 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11083 pub fn OH_ArkUI_NodeUtils_GetCustomProperty(
11084 node: ArkUI_NodeHandle,
11085 name: *const ::core::ffi::c_char,
11086 handle: *mut *mut ArkUI_CustomProperty,
11087 ) -> i32;
11088 /// Get the parent node to obtain the component nodes created by ArkTs.
11089 ///
11090 /// # Arguments
11091 ///
11092 /// * `node` - Target node object.
11093 ///
11094 /// # Returns
11095 ///
11096 /// * Return the pointer of the component.
11097 ///
11098 /// Available since API-level: 14
11099 #[cfg(feature = "api-14")]
11100 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11101 pub fn OH_ArkUI_NodeUtils_GetParentInPageTree(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle;
11102 /// Retrieve all active child nodes of a node. Span will not be counted in the children.
11103 ///
11104 /// # Arguments
11105 ///
11106 /// * `head` - Pass in the node that needs to be obtained.
11107 ///
11108 /// * `handle` - The structure corresponding to the sub node information of the head node.
11109 ///
11110 /// # Returns
11111 ///
11112 /// * Error code.
11113 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11114 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11115 ///
11116 /// Available since API-level: 14
11117 #[cfg(feature = "api-14")]
11118 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11119 pub fn OH_ArkUI_NodeUtils_GetActiveChildrenInfo(
11120 head: ArkUI_NodeHandle,
11121 handle: *mut *mut ArkUI_ActiveChildrenInfo,
11122 ) -> i32;
11123 /// Retrieve the root node of the current page.
11124 ///
11125 /// # Arguments
11126 ///
11127 /// * `node` - Target node object.
11128 ///
11129 /// # Returns
11130 ///
11131 /// * Return the pointer of the component.
11132 ///
11133 /// Available since API-level: 14
11134 #[cfg(feature = "api-14")]
11135 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11136 pub fn OH_ArkUI_NodeUtils_GetCurrentPageRootNode(node: ArkUI_NodeHandle) -> ArkUI_NodeHandle;
11137 /// Retrieve whether the component is labeled by C-API.
11138 ///
11139 /// # Arguments
11140 ///
11141 /// * `node` - Target node object.
11142 ///
11143 /// # Returns
11144 ///
11145 /// * Return whether the node is a Tag created by C-API,
11146 /// true represents created by C-API, false represents not created by C-API.
11147 ///
11148 /// Available since API-level: 14
11149 #[cfg(feature = "api-14")]
11150 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11151 pub fn OH_ArkUI_NodeUtils_IsCreatedByNDK(node: ArkUI_NodeHandle) -> bool;
11152 /// Get the type of node.
11153 ///
11154 /// # Arguments
11155 ///
11156 /// * `node` - Target node object.
11157 ///
11158 /// # Returns
11159 ///
11160 /// * Return the type of the node.
11161 /// For specific open types, refer to [`ArkUI_NodeType`]. For unopened nodes, return -1.
11162 ///
11163 /// Available since API-level: 14
11164 #[cfg(feature = "api-14")]
11165 #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
11166 pub fn OH_ArkUI_NodeUtils_GetNodeType(node: ArkUI_NodeHandle) -> i32;
11167 /// Get info of the window to which the node belongs.
11168 ///
11169 /// # Arguments
11170 ///
11171 /// * `node` - Target node object.
11172 ///
11173 /// * `info` - Window info. Use [`OH_ArkUI_HostWindowInfo_Destroy`] to release memory.
11174 ///
11175 /// # Returns
11176 ///
11177 /// * Error code.
11178 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11179 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11180 /// [`ARKUI_ERROR_CODE_NODE_NOT_ON_MAIN_TREE`] The node is not mounted.
11181 ///
11182 /// Available since API-level: 15
11183 #[cfg(feature = "api-15")]
11184 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11185 pub fn OH_ArkUI_NodeUtils_GetWindowInfo(
11186 node: ArkUI_NodeHandle,
11187 info: *mut *mut ArkUI_HostWindowInfo,
11188 ) -> i32;
11189 /// Obtains the index of the current FrameNode's first child node which is on the tree.
11190 ///
11191 /// # Arguments
11192 ///
11193 /// * `node` - Indicates the target node.
11194 ///
11195 /// * `index` - The index of the subnode.
11196 ///
11197 /// # Returns
11198 ///
11199 /// * Error code.
11200 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11201 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11202 ///
11203 /// Available since API-level: 15
11204 #[cfg(feature = "api-15")]
11205 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11206 pub fn OH_ArkUI_NodeUtils_GetFirstChildIndexWithoutExpand(
11207 node: ArkUI_NodeHandle,
11208 index: *mut u32,
11209 ) -> i32;
11210 /// Obtains the index of the current FrameNode's last child node which is on the tree.
11211 ///
11212 /// # Arguments
11213 ///
11214 /// * `node` - Indicates the target node.
11215 ///
11216 /// * `index` - the index of the subnode.
11217 ///
11218 /// # Returns
11219 ///
11220 /// * Error code.
11221 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11222 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11223 ///
11224 /// Available since API-level: 15
11225 #[cfg(feature = "api-15")]
11226 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11227 pub fn OH_ArkUI_NodeUtils_GetLastChildIndexWithoutExpand(
11228 node: ArkUI_NodeHandle,
11229 index: *mut u32,
11230 ) -> i32;
11231 /// Obtains a subnode by position with the expand mode.
11232 ///
11233 /// # Arguments
11234 ///
11235 /// * `node` - Indicates the target node.
11236 ///
11237 /// * `position` - Indicates the position of the subnode.
11238 ///
11239 /// * `subnode` - The pointer to the subnode.
11240 ///
11241 /// * `expandMode` - Indicates the expand mode. [`ArkUI_ExpandMode`].
11242 ///
11243 /// # Returns
11244 ///
11245 /// * Error code.
11246 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11247 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11248 ///
11249 /// Available since API-level: 15
11250 #[cfg(feature = "api-15")]
11251 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11252 pub fn OH_ArkUI_NodeUtils_GetChildWithExpandMode(
11253 node: ArkUI_NodeHandle,
11254 position: i32,
11255 subnode: *mut ArkUI_NodeHandle,
11256 expandMode: u32,
11257 ) -> i32;
11258 /// Collapse the ListItem in its expanded state.
11259 ///
11260 /// # Arguments
11261 ///
11262 /// * `node` - Node objects that need to be registered for events.
11263 ///
11264 /// * `userData` - Custom event parameters are carried back in the callback parameter when the event is triggered.
11265 ///
11266 /// * `onFinish` - The callback triggered after the completion of the folding animation.
11267 ///
11268 /// # Returns
11269 ///
11270 /// * Error code.
11271 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
11272 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11273 /// [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] The component does not support this event.
11274 ///
11275 /// Available since API-level: 12
11276 #[cfg(feature = "api-12")]
11277 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11278 pub fn OH_ArkUI_List_CloseAllSwipeActions(
11279 node: ArkUI_NodeHandle,
11280 userData: *mut ::core::ffi::c_void,
11281 onFinish: ::core::option::Option<unsafe extern "C" fn(userData: *mut ::core::ffi::c_void)>,
11282 ) -> i32;
11283 /// Obtain the UIContext pointer to the page where the node is located.
11284 ///
11285 /// # Arguments
11286 ///
11287 /// * `node` - The node.
11288 ///
11289 /// # Returns
11290 ///
11291 /// * The UIContext pointer.
11292 /// If a null pointer is returned, it may be because the node is empty.
11293 ///
11294 /// Available since API-level: 12
11295 #[cfg(feature = "api-12")]
11296 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11297 pub fn OH_ArkUI_GetContextByNode(node: ArkUI_NodeHandle) -> ArkUI_ContextHandle;
11298 /// The event called when the system color mode changes.
11299 /// Only one system color change callback can be registered for the same component.
11300 ///
11301 /// # Arguments
11302 ///
11303 /// * `node` - Indicates the target node.
11304 ///
11305 /// * `userData` - Indicates the custom data to be saved.
11306 ///
11307 /// * `onColorModeChange` - Callback Events.
11308 ///
11309 /// # Returns
11310 ///
11311 /// * Error code.
11312 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
11313 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11314 /// [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] The component does not support this event.
11315 ///
11316 /// Available since API-level: 12
11317 #[cfg(feature = "api-12")]
11318 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11319 pub fn OH_ArkUI_RegisterSystemColorModeChangeEvent(
11320 node: ArkUI_NodeHandle,
11321 userData: *mut ::core::ffi::c_void,
11322 onColorModeChange: ::core::option::Option<
11323 unsafe extern "C" fn(
11324 colorMode: ArkUI_SystemColorMode,
11325 userData: *mut ::core::ffi::c_void,
11326 ),
11327 >,
11328 ) -> i32;
11329 /// Unregister the event callback when the system color mode changes.
11330 ///
11331 /// # Arguments
11332 ///
11333 /// * `node` - Indicates the target node.
11334 ///
11335 /// Available since API-level: 12
11336 #[cfg(feature = "api-12")]
11337 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11338 pub fn OH_ArkUI_UnregisterSystemColorModeChangeEvent(node: ArkUI_NodeHandle);
11339 /// The event called when the system font style changes.
11340 /// Only one system font change callback can be registered for the same component.
11341 ///
11342 /// # Arguments
11343 ///
11344 /// * `node` - Indicates the target node.
11345 ///
11346 /// * `userData` - Indicates the custom data to be saved.
11347 ///
11348 /// * `onFontStyleChange` - Callback Events.
11349 ///
11350 /// # Returns
11351 ///
11352 /// * Error code.
11353 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
11354 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11355 /// [`ARKUI_ERROR_CODE_ATTRIBUTE_OR_EVENT_NOT_SUPPORTED`] The component does not support this event.
11356 ///
11357 /// Available since API-level: 12
11358 #[cfg(feature = "api-12")]
11359 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11360 pub fn OH_ArkUI_RegisterSystemFontStyleChangeEvent(
11361 node: ArkUI_NodeHandle,
11362 userData: *mut ::core::ffi::c_void,
11363 onFontStyleChange: ::core::option::Option<
11364 unsafe extern "C" fn(
11365 event: *mut ArkUI_SystemFontStyleEvent,
11366 userData: *mut ::core::ffi::c_void,
11367 ),
11368 >,
11369 ) -> i32;
11370 /// Unregister the event callback when the system font style changes.
11371 ///
11372 /// # Arguments
11373 ///
11374 /// * `node` - Indicates the target node.
11375 ///
11376 /// Available since API-level: 12
11377 #[cfg(feature = "api-12")]
11378 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11379 pub fn OH_ArkUI_UnregisterSystemFontStyleChangeEvent(node: ArkUI_NodeHandle);
11380 /// Retrieve the font size value for system font change events.
11381 ///
11382 /// # Arguments
11383 ///
11384 /// * `event` - Indicates a pointer to the current system font change event.
11385 ///
11386 /// # Returns
11387 ///
11388 /// * Updated system font size scaling factor. Default value: 1.0.
11389 ///
11390 /// Available since API-level: 12
11391 #[cfg(feature = "api-12")]
11392 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11393 pub fn OH_ArkUI_SystemFontStyleEvent_GetFontSizeScale(
11394 event: *const ArkUI_SystemFontStyleEvent,
11395 ) -> f32;
11396 /// Retrieve the font thickness values for system font change events.
11397 ///
11398 /// # Arguments
11399 ///
11400 /// * `event` - Indicates a pointer to the current system font change event.
11401 ///
11402 /// # Returns
11403 ///
11404 /// * The updated system font thickness scaling factor. Default value: 1.0.
11405 ///
11406 /// Available since API-level: 12
11407 #[cfg(feature = "api-12")]
11408 #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
11409 pub fn OH_ArkUI_SystemFontStyleEvent_GetFontWeightScale(
11410 event: *const ArkUI_SystemFontStyleEvent,
11411 ) -> f32;
11412 /// Move the node handle to target parent node as child.
11413 ///
11414 /// # Arguments
11415 ///
11416 /// * `node` - The node handle of the node to move.
11417 ///
11418 /// * `target_parent` - The node handle of target parent.
11419 ///
11420 /// * `index` - Indicates the index which the node is moved to. If the value is a nagative number of invalid, the
11421 /// node is moved to the end of the target parent node.
11422 ///
11423 /// # Returns
11424 ///
11425 /// * Error code.
11426 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11427 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11428 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if the CAPI init error.
11429 ///
11430 /// Available since API-level: 18
11431 #[cfg(feature = "api-18")]
11432 #[cfg_attr(docsrs, doc(cfg(feature = "api-18")))]
11433 pub fn OH_ArkUI_NodeUtils_MoveTo(
11434 node: ArkUI_NodeHandle,
11435 target_parent: ArkUI_NodeHandle,
11436 index: i32,
11437 ) -> i32;
11438 /// Set the cross-language option of the target node handle.
11439 ///
11440 /// # Arguments
11441 ///
11442 /// * `node` - The target node handle.
11443 ///
11444 /// * `option` - The cross-language option [`ArkUI_CrossLanguageOption`].
11445 ///
11446 /// # Returns
11447 ///
11448 /// * Error code.
11449 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11450 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11451 ///
11452 /// Available since API-level: 15
11453 #[cfg(feature = "api-15")]
11454 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11455 pub fn OH_ArkUI_NodeUtils_SetCrossLanguageOption(
11456 node: ArkUI_NodeHandle,
11457 option: *mut ArkUI_CrossLanguageOption,
11458 ) -> i32;
11459 /// Get the cross-language option of the target node handle.
11460 ///
11461 /// # Arguments
11462 ///
11463 /// * `node` - The target node handle.
11464 ///
11465 /// * `option` - The cross-language option [`ArkUI_CrossLanguageOption`].
11466 ///
11467 /// # Returns
11468 ///
11469 /// * Error code.
11470 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11471 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11472 ///
11473 /// Available since API-level: 15
11474 #[cfg(feature = "api-15")]
11475 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11476 pub fn OH_ArkUI_NodeUtils_GetCrossLanguageOption(
11477 node: ArkUI_NodeHandle,
11478 option: *mut ArkUI_CrossLanguageOption,
11479 ) -> i32;
11480 /// Registers a callback for node when layout is completed.
11481 ///
11482 /// # Arguments
11483 ///
11484 /// * `node` - Indicates the target node.
11485 ///
11486 /// * `userData` - Indicates the custom data used in onLayoutCompleted callback function.
11487 ///
11488 /// * `onLayoutCompleted` - Indicates the function when layout completed is callback.
11489 ///
11490 /// # Returns
11491 ///
11492 /// * error code
11493 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_SUCCESSFUL`] if the operation is successful.
11494 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_BAD_PARAMETER`] if a parameter is incorrect.
11495 ///
11496 /// Available since API-level: 15
11497 #[cfg(feature = "api-15")]
11498 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11499 pub fn OH_ArkUI_RegisterLayoutCallbackOnNodeHandle(
11500 node: ArkUI_NodeHandle,
11501 userData: *mut ::core::ffi::c_void,
11502 onLayoutCompleted: ::core::option::Option<
11503 unsafe extern "C" fn(userData: *mut ::core::ffi::c_void),
11504 >,
11505 ) -> i32;
11506 /// Registers a callback for node when draw is completed.
11507 ///
11508 /// # Arguments
11509 ///
11510 /// * `node` - Indicates the target node.
11511 ///
11512 /// * `userData` - Indicates the custom data used in onDrawCompleted callback function.
11513 ///
11514 /// * `onDrawCompleted` - Indicates the function when draw completed is callback.
11515 ///
11516 /// # Returns
11517 ///
11518 /// * error code
11519 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_SUCCESSFUL`] if the operation is successful.
11520 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_BAD_PARAMETER`] if a parameter is incorrect.
11521 ///
11522 /// Available since API-level: 15
11523 #[cfg(feature = "api-15")]
11524 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11525 pub fn OH_ArkUI_RegisterDrawCallbackOnNodeHandle(
11526 node: ArkUI_NodeHandle,
11527 userData: *mut ::core::ffi::c_void,
11528 onDrawCompleted: ::core::option::Option<
11529 unsafe extern "C" fn(userData: *mut ::core::ffi::c_void),
11530 >,
11531 ) -> i32;
11532 /// Unregisters the layout completed callback for node.
11533 ///
11534 /// # Arguments
11535 ///
11536 /// * `node` - Indicates the target node.
11537 ///
11538 /// # Returns
11539 ///
11540 /// * error code
11541 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_SUCCESSFUL`] if the operation is successful.
11542 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_BAD_PARAMETER`] if a parameter is incorrect.
11543 ///
11544 /// Available since API-level: 15
11545 #[cfg(feature = "api-15")]
11546 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11547 pub fn OH_ArkUI_UnregisterLayoutCallbackOnNodeHandle(node: ArkUI_NodeHandle) -> i32;
11548 /// Unregisters the draw completed callback for node.
11549 ///
11550 /// # Arguments
11551 ///
11552 /// * `node` - Indicates the target node.
11553 ///
11554 /// # Returns
11555 ///
11556 /// * error code
11557 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_SUCCESSFUL`] if the operation is successful.
11558 /// [`ARKUI_INSPECTOR_NATIVE_RESULT_BAD_PARAMETER`] if a parameter is incorrect.
11559 ///
11560 /// Available since API-level: 15
11561 #[cfg(feature = "api-15")]
11562 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11563 pub fn OH_ArkUI_UnregisterDrawCallbackOnNodeHandle(node: ArkUI_NodeHandle) -> i32;
11564 /// Get the node handle by id.
11565 ///
11566 /// # Arguments
11567 ///
11568 /// * `id` - The id of the target node handle.
11569 ///
11570 /// * `node` - The handle of target node handle.
11571 ///
11572 /// # Returns
11573 ///
11574 /// * Error code.
11575 /// [`ARKUI_ERROR_CODE_NO_ERROR`] success.
11576 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
11577 ///
11578 /// Available since API-level: 15
11579 #[cfg(feature = "api-15")]
11580 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11581 pub fn OH_ArkUI_NodeUtils_GetAttachedNodeHandleById(
11582 id: *const ::core::ffi::c_char,
11583 node: *mut ArkUI_NodeHandle,
11584 ) -> i32;
11585 /// Get the snapshot pixelmap for the given node synchronously, will get error if the node is not on the
11586 /// tree or is not rendered yet.
11587 /// Note: the pixelmap should be released through OH_PixelmapNative_Release when it's not used any more.
11588 ///
11589 /// # Arguments
11590 ///
11591 /// * `node` - Indicates the target node.
11592 ///
11593 /// * `snapshotOptions` - the given configuration for taking snapshot, can be null for using default.
11594 ///
11595 /// * `pixelmap` - Pixelmap pointer created by system, it's the out result.
11596 ///
11597 /// # Returns
11598 ///
11599 /// * Returns the result code.
11600 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
11601 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
11602 /// Returns [`ARKUI_ERROR_CODE_INTERNAL_ERROR`] if the snapshot taking failed will null pixelmap returned.
11603 /// Returns [`ARKUI_ERROR_CODE_COMPONENT_SNAPSHOT_TIMEOUT`] if the snapshot taking is timeout.
11604 ///
11605 /// Available since API-level: 15
11606 #[cfg(feature = "api-15")]
11607 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11608 pub fn OH_ArkUI_GetNodeSnapshot(
11609 node: ArkUI_NodeHandle,
11610 snapshotOptions: *mut ArkUI_SnapshotOptions,
11611 pixelmap: *mut *mut OH_PixelmapNative,
11612 ) -> i32;
11613 /// Obtains the offset of a specific node relative to its parent node.
11614 ///
11615 /// # Arguments
11616 ///
11617 /// * `node` - Target node.
11618 ///
11619 /// * `globalOffset` - Offset of the target node relative to its parent node, in px.
11620 ///
11621 /// # Returns
11622 ///
11623 /// * Returns the result code.
11624 /// Returns [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
11625 /// Returns [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
11626 ///
11627 /// Available since API-level: 15
11628 #[cfg(feature = "api-15")]
11629 #[cfg_attr(docsrs, doc(cfg(feature = "api-15")))]
11630 pub fn OH_ArkUI_NodeUtils_GetPositionToParent(
11631 node: ArkUI_NodeHandle,
11632 globalOffset: *mut ArkUI_IntOffset,
11633 ) -> i32;
11634}