arkui_sys/native_render/native_render_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::*;
7
8#[repr(C)]
9pub struct ArkUI_RenderNode {
10 _unused: [u8; 0],
11}
12/// Handle to ArkUI native render node object.
13///
14///
15/// Available since API-level: 20
16#[cfg(feature = "api-20")]
17#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
18pub type ArkUI_RenderNodeHandle = *mut ArkUI_RenderNode;
19#[repr(C)]
20pub struct ArkUI_RenderContentModifier {
21 _unused: [u8; 0],
22}
23/// Handle to ArkUI native render content modifier.
24///
25///
26/// Available since API-level: 20
27#[cfg(feature = "api-20")]
28#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
29pub type ArkUI_RenderContentModifierHandle = *mut ArkUI_RenderContentModifier;
30#[repr(C)]
31pub struct ArkUI_FloatProperty {
32 _unused: [u8; 0],
33}
34/// Handle to the ArkUI native float render property.
35///
36///
37/// Available since API-level: 20
38#[cfg(feature = "api-20")]
39#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
40pub type ArkUI_FloatPropertyHandle = *mut ArkUI_FloatProperty;
41#[repr(C)]
42pub struct ArkUI_Vector2Property {
43 _unused: [u8; 0],
44}
45/// Handle to the ArkUI native vector2 render property.
46///
47///
48/// Available since API-level: 20
49#[cfg(feature = "api-20")]
50#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
51pub type ArkUI_Vector2PropertyHandle = *mut ArkUI_Vector2Property;
52#[repr(C)]
53pub struct ArkUI_ColorProperty {
54 _unused: [u8; 0],
55}
56/// Handle to the ArkUI native color render property.
57///
58///
59/// Available since API-level: 20
60#[cfg(feature = "api-20")]
61#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
62pub type ArkUI_ColorPropertyHandle = *mut ArkUI_ColorProperty;
63#[repr(C)]
64pub struct ArkUI_FloatAnimatableProperty {
65 _unused: [u8; 0],
66}
67/// Handle to the ArkUI native animatable float render property.
68///
69///
70/// Available since API-level: 20
71#[cfg(feature = "api-20")]
72#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
73pub type ArkUI_FloatAnimatablePropertyHandle = *mut ArkUI_FloatAnimatableProperty;
74#[repr(C)]
75pub struct ArkUI_Vector2AnimatableProperty {
76 _unused: [u8; 0],
77}
78/// Handle to the ArkUI native animatable vector2 render property.
79///
80///
81/// Available since API-level: 20
82#[cfg(feature = "api-20")]
83#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
84pub type ArkUI_Vector2AnimatablePropertyHandle = *mut ArkUI_Vector2AnimatableProperty;
85#[repr(C)]
86pub struct ArkUI_ColorAnimatableProperty {
87 _unused: [u8; 0],
88}
89/// Handle to the ArkUI native animatable color render property.
90///
91///
92/// Available since API-level: 20
93#[cfg(feature = "api-20")]
94#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
95pub type ArkUI_ColorAnimatablePropertyHandle = *mut ArkUI_ColorAnimatableProperty;
96#[repr(C)]
97pub struct ArkUI_RectShape {
98 _unused: [u8; 0],
99}
100/// Rectangle shape option.
101///
102///
103/// Available since API-level: 20
104#[cfg(feature = "api-20")]
105#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
106pub type ArkUI_RectShapeOption = ArkUI_RectShape;
107#[repr(C)]
108pub struct ArkUI_NodeBorderStyle {
109 _unused: [u8; 0],
110}
111/// Node border style option.
112///
113///
114/// Available since API-level: 20
115#[cfg(feature = "api-20")]
116#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
117pub type ArkUI_NodeBorderStyleOption = ArkUI_NodeBorderStyle;
118#[repr(C)]
119pub struct ArkUI_NodeBorderWidth {
120 _unused: [u8; 0],
121}
122/// Node border width option.
123///
124///
125/// Available since API-level: 20
126#[cfg(feature = "api-20")]
127#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
128pub type ArkUI_NodeBorderWidthOption = ArkUI_NodeBorderWidth;
129#[repr(C)]
130pub struct ArkUI_NodeBorderColor {
131 _unused: [u8; 0],
132}
133/// Node border color option.
134///
135///
136/// Available since API-level: 20
137#[cfg(feature = "api-20")]
138#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
139pub type ArkUI_NodeBorderColorOption = ArkUI_NodeBorderColor;
140#[repr(C)]
141pub struct ArkUI_NodeBorderRadius {
142 _unused: [u8; 0],
143}
144/// Node border radius option.
145///
146///
147/// Available since API-level: 20
148#[cfg(feature = "api-20")]
149#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
150pub type ArkUI_NodeBorderRadiusOption = ArkUI_NodeBorderRadius;
151#[repr(C)]
152pub struct ArkUI_CircleShape {
153 _unused: [u8; 0],
154}
155/// Circle shape option.
156///
157///
158/// Available since API-level: 20
159#[cfg(feature = "api-20")]
160#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
161pub type ArkUI_CircleShapeOption = ArkUI_CircleShape;
162#[repr(C)]
163pub struct ArkUI_RoundRectShape {
164 _unused: [u8; 0],
165}
166/// Round rect shape option.
167///
168///
169/// Available since API-level: 20
170#[cfg(feature = "api-20")]
171#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
172pub type ArkUI_RoundRectShapeOption = ArkUI_RoundRectShape;
173#[repr(C)]
174pub struct ArkUI_CommandPath {
175 _unused: [u8; 0],
176}
177/// Command path option.
178///
179///
180/// Available since API-level: 20
181#[cfg(feature = "api-20")]
182#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
183pub type ArkUI_CommandPathOption = ArkUI_CommandPath;
184/// Render node mask option.
185///
186///
187/// Available since API-level: 20
188#[cfg(feature = "api-20")]
189#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
190#[repr(C)]
191pub struct ArkUI_RenderNodeMaskOption {
192 _unused: [u8; 0],
193}
194/// Render node clip option.
195///
196///
197/// Available since API-level: 20
198#[cfg(feature = "api-20")]
199#[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
200#[repr(C)]
201pub struct ArkUI_RenderNodeClipOption {
202 _unused: [u8; 0],
203}
204extern "C" {
205 /// Adds a child render node to a parent node.
206 ///
207 /// # Arguments
208 ///
209 /// * `node` - the target parent node.
210 /// - Only customNode type parent nodes are supported.
211 /// - Each customNode can mount only one ArkUI_RenderNodeHandle.
212 /// - customNode cannot mount other ArkUI_NodeHandle.
213 ///
214 /// * `child` - the child RenderNode to add.
215 ///
216 /// # Returns
217 ///
218 /// * Error code.
219 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
220 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
221 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
222 /// [`ARKUI_ERROR_CODE_NOT_CUSTOM_NODE`] The node is not a customNode.
223 /// [`ARKUI_ERROR_CODE_CHILD_EXISTED`] The node already has a child.
224 /// [`ARKUI_ERROR_CODE_RENDER_PARENT_EXISTED`] The child already has a parent node.
225 /// [`ARKUI_ERROR_CODE_RENDER_HAS_INVALID_FRAME_NODE`] if the child is obtained from a FrameNode, and its
226 /// corresponding FrameNode is no longer in the adopted state. Add since api 22.
227 ///
228 /// Available since API-level: 20
229 #[cfg(feature = "api-20")]
230 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
231 pub fn OH_ArkUI_RenderNodeUtils_AddRenderNode(
232 node: ArkUI_NodeHandle,
233 child: ArkUI_RenderNodeHandle,
234 ) -> i32;
235 /// Remove the specified child node from its parent node.
236 ///
237 /// # Arguments
238 ///
239 /// * `node` - the parent node.
240 ///
241 /// * `child` - the child RenderNode to remove.
242 ///
243 /// # Returns
244 ///
245 /// * Error code.
246 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
247 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
248 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
249 /// [`ARKUI_ERROR_CODE_NOT_CUSTOM_NODE`] The node is not a customNode.
250 ///
251 /// Available since API-level: 20
252 #[cfg(feature = "api-20")]
253 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
254 pub fn OH_ArkUI_RenderNodeUtils_RemoveRenderNode(
255 node: ArkUI_NodeHandle,
256 child: ArkUI_RenderNodeHandle,
257 ) -> i32;
258 /// Clear all child render nodes from the specified parent node.
259 ///
260 /// # Arguments
261 ///
262 /// * `node` - the target parent node.
263 ///
264 /// # Returns
265 ///
266 /// * Error code.
267 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
268 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
269 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
270 /// [`ARKUI_ERROR_CODE_NOT_CUSTOM_NODE`] The node is not a customNode.
271 ///
272 /// Available since API-level: 20
273 #[cfg(feature = "api-20")]
274 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
275 pub fn OH_ArkUI_RenderNodeUtils_ClearRenderNodeChildren(node: ArkUI_NodeHandle) -> i32;
276 /// Mark dirty the node handle. Invalidate the specified node, causing its lifecycle and triggering a
277 /// rerender of its child render nodes.
278 ///
279 /// # Arguments
280 ///
281 /// * `node` - Target node.
282 ///
283 /// # Returns
284 ///
285 /// * Error code.
286 /// [`ARKUI_ERROR_CODE_NO_ERROR`] if the operation is successful.
287 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
288 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] if a parameter error occurs.
289 ///
290 /// Available since API-level: 20
291 #[cfg(feature = "api-20")]
292 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
293 pub fn OH_ArkUI_RenderNodeUtils_Invalidate(node: ArkUI_NodeHandle) -> i32;
294 /// Create a new RenderNode handle.
295 ///
296 ///
297 /// # Returns
298 ///
299 /// * ArkUI_RenderNodeHandle pointer to receive the new node handle.
300 ///
301 /// Available since API-level: 20
302 #[cfg(feature = "api-20")]
303 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
304 pub fn OH_ArkUI_RenderNodeUtils_CreateNode() -> ArkUI_RenderNodeHandle;
305 /// Dispose a RenderNode handle.
306 ///
307 /// # Arguments
308 ///
309 /// * `node` - Handle to the render node to dispose.
310 ///
311 /// # Returns
312 ///
313 /// * Error code.
314 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
315 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
316 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
317 ///
318 /// Available since API-level: 20
319 #[cfg(feature = "api-20")]
320 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
321 pub fn OH_ArkUI_RenderNodeUtils_DisposeNode(node: ArkUI_RenderNodeHandle) -> i32;
322 /// Add a child node to the specified RenderNode.
323 ///
324 /// # Arguments
325 ///
326 /// * `node` - the parent RenderNode.
327 ///
328 /// * `child` - the child RenderNode to add.
329 ///
330 /// # Returns
331 ///
332 /// * Error code.
333 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
334 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
335 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
336 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
337 /// Add since api 22.
338 /// [`ARKUI_ERROR_CODE_RENDER_HAS_INVALID_FRAME_NODE`] if the child is obtained from a FrameNode, and its
339 /// corresponding FrameNode is no longer in the adopted state. Add since api 22.
340 ///
341 /// Available since API-level: 20
342 #[cfg(feature = "api-20")]
343 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
344 pub fn OH_ArkUI_RenderNodeUtils_AddChild(
345 node: ArkUI_RenderNodeHandle,
346 child: ArkUI_RenderNodeHandle,
347 ) -> i32;
348 /// Insert a child node after the specified sibling node in RenderNode.
349 ///
350 /// # Arguments
351 ///
352 /// * `node` - the parent RenderNode.
353 ///
354 /// * `child` - the child RenderNode to insert.
355 ///
356 /// * `sibling` - the reference sibling node. If the sibling node does not exist in the children,
357 /// the child component will be added to the end.
358 ///
359 /// # Returns
360 ///
361 /// * Error code.
362 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
363 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
364 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
365 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
366 /// Add since api 22.
367 /// [`ARKUI_ERROR_CODE_RENDER_HAS_INVALID_FRAME_NODE`] if the child is obtained from a FrameNode, and its
368 /// corresponding FrameNode is no longer in the adopted state. Add since api 22.
369 ///
370 /// Available since API-level: 20
371 #[cfg(feature = "api-20")]
372 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
373 pub fn OH_ArkUI_RenderNodeUtils_InsertChildAfter(
374 node: ArkUI_RenderNodeHandle,
375 child: ArkUI_RenderNodeHandle,
376 sibling: ArkUI_RenderNodeHandle,
377 ) -> i32;
378 /// Remove a child node from the specified RenderNode.
379 ///
380 /// # Arguments
381 ///
382 /// * `node` - the parent RenderNode.
383 ///
384 /// * `child` - the child RenderNode to remove.
385 ///
386 /// # Returns
387 ///
388 /// * Error code.
389 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
390 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
391 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
392 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
393 /// Add since api 22.
394 ///
395 /// Available since API-level: 20
396 #[cfg(feature = "api-20")]
397 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
398 pub fn OH_ArkUI_RenderNodeUtils_RemoveChild(
399 node: ArkUI_RenderNodeHandle,
400 child: ArkUI_RenderNodeHandle,
401 ) -> i32;
402 /// Clear all children from the specified RenderNode.
403 ///
404 /// # Arguments
405 ///
406 /// * `node` - Handle to the target render node.
407 ///
408 /// # Returns
409 ///
410 /// * Error code.
411 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
412 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
413 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
414 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the RenderNode is obtained from a FrameNode. Add since api 22.
415 ///
416 /// Available since API-level: 20
417 #[cfg(feature = "api-20")]
418 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
419 pub fn OH_ArkUI_RenderNodeUtils_ClearChildren(node: ArkUI_RenderNodeHandle) -> i32;
420 /// Get a child node at the specified index position.
421 ///
422 /// # Arguments
423 ///
424 /// * `node` - the parent RenderNode.
425 ///
426 /// * `index` - Zero-based index of the child node.
427 ///
428 /// * `child` - ArkUI_RenderNodeHandle pointer to receive the child node.
429 ///
430 /// # Returns
431 ///
432 /// * Error code.
433 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
434 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
435 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
436 /// [`ARKUI_ERROR_CODE_RENDER_CHILD_NOT_EXIST`] The child does not exist.
437 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the RenderNode is obtained from a FrameNode. Add since api 22.
438 ///
439 /// Available since API-level: 20
440 #[cfg(feature = "api-20")]
441 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
442 pub fn OH_ArkUI_RenderNodeUtils_GetChild(
443 node: ArkUI_RenderNodeHandle,
444 index: i32,
445 child: *mut ArkUI_RenderNodeHandle,
446 ) -> i32;
447 /// Get the first child node of the specified RenderNode.
448 ///
449 /// # Arguments
450 ///
451 /// * `node` - Handle to the target render node.
452 ///
453 /// * `child` - ArkUI_RenderNodeHandle pointer to receive the first child.
454 ///
455 /// # Returns
456 ///
457 /// * Error code.
458 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
459 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
460 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
461 /// [`ARKUI_ERROR_CODE_RENDER_CHILD_NOT_EXIST`] The child does not exist.
462 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
463 /// Add since api 22.
464 ///
465 /// Available since API-level: 20
466 #[cfg(feature = "api-20")]
467 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
468 pub fn OH_ArkUI_RenderNodeUtils_GetFirstChild(
469 node: ArkUI_RenderNodeHandle,
470 child: *mut ArkUI_RenderNodeHandle,
471 ) -> i32;
472 /// Get the next sibling node of the specified node.
473 ///
474 /// # Arguments
475 ///
476 /// * `node` - the reference node.
477 ///
478 /// * `sibling` - ArkUI_RenderNodeHandle pointer to receive the next sibling.
479 ///
480 /// # Returns
481 ///
482 /// * Error code.
483 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
484 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
485 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
486 /// [`ARKUI_ERROR_CODE_RENDER_CHILD_NOT_EXIST`] The child does not exist.
487 ///
488 /// Available since API-level: 20
489 #[cfg(feature = "api-20")]
490 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
491 pub fn OH_ArkUI_RenderNodeUtils_GetNextSibling(
492 node: ArkUI_RenderNodeHandle,
493 sibling: *mut ArkUI_RenderNodeHandle,
494 ) -> i32;
495 /// Get the previous sibling node of the specified node.
496 ///
497 /// # Arguments
498 ///
499 /// * `node` - the reference node.
500 ///
501 /// * `sibling` - ArkUI_RenderNodeHandle pointer to receive the previous sibling.
502 ///
503 /// # Returns
504 ///
505 /// * Error code.
506 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
507 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
508 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
509 /// [`ARKUI_ERROR_CODE_RENDER_CHILD_NOT_EXIST`] The child does not exist.
510 ///
511 /// Available since API-level: 20
512 #[cfg(feature = "api-20")]
513 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
514 pub fn OH_ArkUI_RenderNodeUtils_GetPreviousSibling(
515 node: ArkUI_RenderNodeHandle,
516 sibling: *mut ArkUI_RenderNodeHandle,
517 ) -> i32;
518 /// Retrieve all child render nodes of a parent render node.
519 /// This function populates a list of child render nodes for the specified parent node.
520 /// The caller is responsible for freeing the allocated child node array.
521 ///
522 /// # Arguments
523 ///
524 /// * `node` - Handle to the target parent render node.
525 ///
526 /// * `children` - Pointer to an array of child render node handles.
527 ///
528 /// * `count` - Pointer to store the number of child nodes retrieved.
529 ///
530 /// # Returns
531 ///
532 /// * Error code.
533 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
534 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
535 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
536 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode. Add since api 22.
537 ///
538 /// Available since API-level: 20
539 #[cfg(feature = "api-20")]
540 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
541 pub fn OH_ArkUI_RenderNodeUtils_GetChildren(
542 node: ArkUI_RenderNodeHandle,
543 children: *mut *mut ArkUI_RenderNodeHandle,
544 count: *mut i32,
545 ) -> i32;
546 /// Retrieve render child nodes count of a render node.
547 ///
548 /// # Arguments
549 ///
550 /// * `node` - Handle to the target parent render node.
551 ///
552 /// * `count` - Pointer to store the number of child nodes retrieved.
553 ///
554 /// # Returns
555 ///
556 /// * Error code.
557 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
558 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
559 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
560 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
561 /// Add since api 22.
562 ///
563 /// Available since API-level: 20
564 #[cfg(feature = "api-20")]
565 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
566 pub fn OH_ArkUI_RenderNodeUtils_GetChildrenCount(
567 node: ArkUI_RenderNodeHandle,
568 count: *mut i32,
569 ) -> i32;
570 /// Set the background color for a RenderNode.
571 ///
572 /// # Arguments
573 ///
574 /// * `node` - Handle to the target render node
575 ///
576 /// * `color` - Packed ARGB color value (32-bit unsigned integer)
577 /// Color byte layout:
578 /// - Bits 24-31: Alpha channel (0x00 fully transparent, 0xFF fully opaque)
579 /// - Bits 16-23: Red channel
580 /// - Bits 8-15: Green channel
581 /// - Bits 0-7: Blue channel
582 ///
583 /// # Returns
584 ///
585 /// * Error code.
586 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
587 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
588 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
589 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
590 /// Add since api 22.
591 ///
592 /// Available since API-level: 20
593 #[cfg(feature = "api-20")]
594 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
595 pub fn OH_ArkUI_RenderNodeUtils_SetBackgroundColor(
596 node: ArkUI_RenderNodeHandle,
597 color: u32,
598 ) -> i32;
599 /// Get the background color of a RenderNode.
600 ///
601 /// # Arguments
602 ///
603 /// * `node` - Handle to the target render node
604 ///
605 /// * `color` - Integer pointer to store the retrieved RGBA color value.
606 /// The retrieved color is a packed 32-bit value with the following byte layout:
607 /// - Bits 24-31: Alpha channel (0x00 fully transparent, 0xFF fully opaque)
608 /// - Bits 16-23: Red channel
609 /// - Bits 8-15: Green channel
610 /// - Bits 0-7: Blue channel
611 ///
612 /// # Returns
613 ///
614 /// * Error code.
615 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
616 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
617 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
618 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
619 /// Add since api 22.
620 ///
621 /// Available since API-level: 20
622 #[cfg(feature = "api-20")]
623 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
624 pub fn OH_ArkUI_RenderNodeUtils_GetBackgroundColor(
625 node: ArkUI_RenderNodeHandle,
626 color: *mut u32,
627 ) -> i32;
628 /// Set whether to clip content to the node's frame.
629 ///
630 /// # Arguments
631 ///
632 /// * `node` - Handle to the target render node.
633 ///
634 /// * `clipToFrame` - Integer (1 = clip to frame, 0 = do not clip).
635 ///
636 /// # Returns
637 ///
638 /// * Error code.
639 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
640 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
641 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
642 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
643 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
644 /// Add since api 22.
645 ///
646 /// Available since API-level: 20
647 #[cfg(feature = "api-20")]
648 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
649 pub fn OH_ArkUI_RenderNodeUtils_SetClipToFrame(
650 node: ArkUI_RenderNodeHandle,
651 clipToFrame: i32,
652 ) -> i32;
653 /// Get the clip-to-frame status of a RenderNode.
654 ///
655 /// # Arguments
656 ///
657 /// * `node` - Handle to the target render node.
658 ///
659 /// * `clipToFrame` - Integer pointer to receive clip status (1 or 0).
660 ///
661 /// # Returns
662 ///
663 /// * Error code.
664 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
665 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
666 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
667 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
668 /// Add since api 22.
669 ///
670 /// Available since API-level: 20
671 #[cfg(feature = "api-20")]
672 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
673 pub fn OH_ArkUI_RenderNodeUtils_GetClipToFrame(
674 node: ArkUI_RenderNodeHandle,
675 clipToFrame: *mut i32,
676 ) -> i32;
677 /// Set whether to clip content to the node's Bounds.
678 ///
679 /// # Arguments
680 ///
681 /// * `node` - Handle to the target render node.
682 ///
683 /// * `clipToBounds` - Clipping flag (1: clip to bounds, 0: do not clip)
684 ///
685 /// # Returns
686 ///
687 /// * Error code.
688 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
689 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
690 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
691 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
692 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
693 /// Add since api 22.
694 ///
695 /// Available since API-level: 20
696 #[cfg(feature = "api-20")]
697 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
698 pub fn OH_ArkUI_RenderNodeUtils_SetClipToBounds(
699 node: ArkUI_RenderNodeHandle,
700 clipToBounds: i32,
701 ) -> i32;
702 /// Get whether to clip content to the node's Bounds.
703 ///
704 /// # Arguments
705 ///
706 /// * `node` - Handle to the target render node.
707 ///
708 /// * `clipToBounds` - Integer pointer (1 = clip to bounds, 0 = do not clip).
709 ///
710 /// # Returns
711 ///
712 /// * Error code.
713 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
714 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
715 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
716 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
717 /// Add since api 22.
718 ///
719 /// Available since API-level: 20
720 #[cfg(feature = "api-20")]
721 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
722 pub fn OH_ArkUI_RenderNodeUtils_GetClipToBounds(
723 node: ArkUI_RenderNodeHandle,
724 clipToBounds: *mut i32,
725 ) -> i32;
726 /// Set the opacity value for a RenderNode.
727 ///
728 /// # Arguments
729 ///
730 /// * `node` - Handle to the target render node.
731 ///
732 /// * `opacity` - Opacity value (0.0-1.0).
733 ///
734 /// # Returns
735 ///
736 /// * Error code.
737 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
738 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
739 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
740 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
741 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
742 /// Add since api 22.
743 ///
744 /// Available since API-level: 20
745 #[cfg(feature = "api-20")]
746 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
747 pub fn OH_ArkUI_RenderNodeUtils_SetOpacity(node: ArkUI_RenderNodeHandle, opacity: f32) -> i32;
748 /// Get the opacity value of a RenderNode.
749 ///
750 /// # Arguments
751 ///
752 /// * `node` - Handle to the target render node.
753 ///
754 /// * `opacity` - Pointer to receive opacity value (0.0-1.0).
755 ///
756 /// # Returns
757 ///
758 /// * Error code.
759 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
760 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
761 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
762 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
763 /// Add since api 22.
764 ///
765 /// Available since API-level: 20
766 #[cfg(feature = "api-20")]
767 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
768 pub fn OH_ArkUI_RenderNodeUtils_GetOpacity(
769 node: ArkUI_RenderNodeHandle,
770 opacity: *mut f32,
771 ) -> i32;
772 /// Set the dimensions for a RenderNode.
773 ///
774 /// # Arguments
775 ///
776 /// * `node` - Handle to the target render node.
777 ///
778 /// * `width` - Width value in pixels.
779 ///
780 /// * `height` - Height value in pixels.
781 ///
782 /// # Returns
783 ///
784 /// * Error code.
785 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
786 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
787 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
788 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
789 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
790 /// Add since api 22.
791 ///
792 /// Available since API-level: 20
793 #[cfg(feature = "api-20")]
794 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
795 pub fn OH_ArkUI_RenderNodeUtils_SetSize(
796 node: ArkUI_RenderNodeHandle,
797 width: i32,
798 height: i32,
799 ) -> i32;
800 /// Get the dimensions of a RenderNode.
801 ///
802 /// # Arguments
803 ///
804 /// * `node` - Handle to the target render node.
805 ///
806 /// * `width` - Pointer to receive width value in pixels.
807 ///
808 /// * `height` - Pointer to receive height value in pixels.
809 ///
810 /// # Returns
811 ///
812 /// * Error code.
813 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
814 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
815 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
816 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
817 /// Add since api 22.
818 ///
819 /// Available since API-level: 20
820 #[cfg(feature = "api-20")]
821 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
822 pub fn OH_ArkUI_RenderNodeUtils_GetSize(
823 node: ArkUI_RenderNodeHandle,
824 width: *mut i32,
825 height: *mut i32,
826 ) -> i32;
827 /// Set the position coordinates for a RenderNode.
828 ///
829 /// # Arguments
830 ///
831 /// * `node` - Handle to the target render node.
832 ///
833 /// * `x` - X-coordinate value in pixels.
834 ///
835 /// * `y` - Y-coordinate value in pixels.
836 ///
837 /// # Returns
838 ///
839 /// * Error code.
840 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
841 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
842 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
843 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
844 /// Add since api 22.
845 ///
846 /// Available since API-level: 20
847 #[cfg(feature = "api-20")]
848 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
849 pub fn OH_ArkUI_RenderNodeUtils_SetPosition(
850 node: ArkUI_RenderNodeHandle,
851 x: i32,
852 y: i32,
853 ) -> i32;
854 /// Get the position coordinates of a RenderNode.
855 ///
856 /// # Arguments
857 ///
858 /// * `node` - Handle to the target render node.
859 ///
860 /// * `x` - Pointer to receive X-coordinate value in pixels.
861 ///
862 /// * `y` - Pointer to receive Y-coordinate value in pixels.
863 ///
864 /// # Returns
865 ///
866 /// * Error code.
867 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
868 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
869 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
870 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
871 /// Add since api 22.
872 ///
873 /// Available since API-level: 20
874 #[cfg(feature = "api-20")]
875 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
876 pub fn OH_ArkUI_RenderNodeUtils_GetPosition(
877 node: ArkUI_RenderNodeHandle,
878 x: *mut i32,
879 y: *mut i32,
880 ) -> i32;
881 /// Set the pivot point for transformations of a RenderNode.
882 ///
883 /// # Arguments
884 ///
885 /// * `node` - Handle to the target render node.
886 ///
887 /// * `x` - The X-coordinate of pivot (normalized 0.0-1.0).
888 ///
889 /// * `y` - The Y-coordinate of pivot (normalized 0.0-1.0).
890 ///
891 /// # Returns
892 ///
893 /// * Error code.
894 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
895 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
896 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
897 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
898 /// Add since api 22.
899 ///
900 /// Available since API-level: 20
901 #[cfg(feature = "api-20")]
902 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
903 pub fn OH_ArkUI_RenderNodeUtils_SetPivot(node: ArkUI_RenderNodeHandle, x: f32, y: f32) -> i32;
904 /// Get the pivot point coordinates of a RenderNode.
905 ///
906 /// # Arguments
907 ///
908 /// * `node` - Handle to the target render node.
909 ///
910 /// * `x` - Pointer to receive the X-coordinate of pivot.
911 ///
912 /// * `y` - Pointer to receive the Y-coordinate of pivot.
913 ///
914 /// # Returns
915 ///
916 /// * Error code.
917 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
918 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
919 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
920 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
921 /// Add since api 22.
922 ///
923 /// Available since API-level: 20
924 #[cfg(feature = "api-20")]
925 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
926 pub fn OH_ArkUI_RenderNodeUtils_GetPivot(
927 node: ArkUI_RenderNodeHandle,
928 x: *mut f32,
929 y: *mut f32,
930 ) -> i32;
931 /// Set the scaling factors for a RenderNode.
932 ///
933 /// # Arguments
934 ///
935 /// * `node` - Handle to the target render node.
936 ///
937 /// * `x` - Horizontal scale factor.
938 ///
939 /// * `y` - Vertical scale factor.
940 ///
941 /// # Returns
942 ///
943 /// * Error code.
944 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
945 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
946 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
947 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
948 /// Add since api 22.
949 ///
950 /// Available since API-level: 20
951 #[cfg(feature = "api-20")]
952 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
953 pub fn OH_ArkUI_RenderNodeUtils_SetScale(node: ArkUI_RenderNodeHandle, x: f32, y: f32) -> i32;
954 /// Get the scaling factors of a RenderNode.
955 ///
956 /// # Arguments
957 ///
958 /// * `node` - Handle to the target render node.
959 ///
960 /// * `x` - Pointer to receive horizontal scale factor.
961 ///
962 /// * `y` - Pointer to receive vertical scale factor.
963 ///
964 /// # Returns
965 ///
966 /// * Error code.
967 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
968 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
969 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
970 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
971 /// Add since api 22.
972 ///
973 /// Available since API-level: 20
974 #[cfg(feature = "api-20")]
975 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
976 pub fn OH_ArkUI_RenderNodeUtils_GetScale(
977 node: ArkUI_RenderNodeHandle,
978 x: *mut f32,
979 y: *mut f32,
980 ) -> i32;
981 /// Set the translation offset for a RenderNode.
982 ///
983 /// # Arguments
984 ///
985 /// * `node` - Handle to the target render node.
986 ///
987 /// * `x` - Horizontal translation in pixels.
988 ///
989 /// * `y` - Vertical translation in pixels.
990 ///
991 /// # Returns
992 ///
993 /// * Error code.
994 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
995 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
996 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
997 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
998 /// Add since api 22.
999 ///
1000 /// Available since API-level: 20
1001 #[cfg(feature = "api-20")]
1002 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1003 pub fn OH_ArkUI_RenderNodeUtils_SetTranslation(
1004 node: ArkUI_RenderNodeHandle,
1005 x: f32,
1006 y: f32,
1007 ) -> i32;
1008 /// Get the translation offset of a RenderNode.
1009 ///
1010 /// # Arguments
1011 ///
1012 /// * `node` - Handle to the target render node.
1013 ///
1014 /// * `x` - Pointer to receive horizontal translation.
1015 ///
1016 /// * `y` - Pointer to receive vertical translation.
1017 ///
1018 /// # Returns
1019 ///
1020 /// * Error code.
1021 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1022 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1023 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1024 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1025 /// Add since api 22.
1026 ///
1027 /// Available since API-level: 20
1028 #[cfg(feature = "api-20")]
1029 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1030 pub fn OH_ArkUI_RenderNodeUtils_GetTranslation(
1031 node: ArkUI_RenderNodeHandle,
1032 x: *mut f32,
1033 y: *mut f32,
1034 ) -> i32;
1035 /// Set the rotation angles for a RenderNode.
1036 ///
1037 /// # Arguments
1038 ///
1039 /// * `node` - Handle to the target render node.
1040 ///
1041 /// * `x` - Rotation angle around X-axis in degrees.
1042 ///
1043 /// * `y` - Rotation angle around Y-axis in degrees.
1044 ///
1045 /// * `z` - Rotation angle around Z-axis in degrees.
1046 ///
1047 /// # Returns
1048 ///
1049 /// * Error code.
1050 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1051 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1052 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1053 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1054 /// Add since api 22.
1055 ///
1056 /// Available since API-level: 20
1057 #[cfg(feature = "api-20")]
1058 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1059 pub fn OH_ArkUI_RenderNodeUtils_SetRotation(
1060 node: ArkUI_RenderNodeHandle,
1061 x: f32,
1062 y: f32,
1063 z: f32,
1064 ) -> i32;
1065 /// Get the rotation angles of a RenderNode.
1066 ///
1067 /// # Arguments
1068 ///
1069 /// * `node` - Handle to the target render node.
1070 ///
1071 /// * `x` - Pointer to receive X-axis rotation angle in degrees.
1072 ///
1073 /// * `y` - Pointer to receive Y-axis rotation angle in degrees.
1074 ///
1075 /// * `z` - Pointer to receive Z-axis rotation angle in degrees.
1076 ///
1077 /// # Returns
1078 ///
1079 /// * Error code.
1080 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1081 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1082 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1083 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1084 /// Add since api 22.
1085 ///
1086 /// Available since API-level: 20
1087 #[cfg(feature = "api-20")]
1088 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1089 pub fn OH_ArkUI_RenderNodeUtils_GetRotation(
1090 node: ArkUI_RenderNodeHandle,
1091 x: *mut f32,
1092 y: *mut f32,
1093 z: *mut f32,
1094 ) -> i32;
1095 /// Set the transformation matrix for a RenderNode.
1096 ///
1097 /// # Arguments
1098 ///
1099 /// * `node` - Handle to the target render node.
1100 ///
1101 /// * `matrix` - Pointer to a 4x4 transformation matrix (16 consecutive values).
1102 /// The transformation matrix should be provided as 16 consecutive floating-point values in row-major order:
1103 /// [m00, m01, m02, m03,
1104 /// m10, m11, m12, m13,
1105 /// m20, m21, m22, m23,
1106 /// m30, m31, m32, m33]
1107 /// Where the matrix represents:
1108 /// | m00 m01 m02 m03 |
1109 /// | m10 m11 m12 m13 |
1110 /// | m20 m21 m22 m23 |
1111 /// | m30 m31 m32 m33 |
1112 /// Matrix components:
1113 /// | m00 | Scaling value of the x-axis. The default value is **1** for the identity matrix. |
1114 /// | m01 | The second value, which is affected by the rotation or tilt of the x, y, and z axes. |
1115 /// | m02 | The third value, which is affected by the rotation of the x, y, and z axes. |
1116 /// | m03 | The fourth value, which is affected by perspective projection. |
1117 /// | m10 | The fifth value, which is affected by the rotation or tilt of the x, y, and z axes. |
1118 /// | m11 | Scaling value of the y-axis. The default value is **1** for the identity matrix. |
1119 /// | m12 | The seventh value, which is affected by the rotation of the x, y, and z axes. |
1120 /// | m13 | The eighth value, which is affected by perspective projection. |
1121 /// | m20 | The ninth value, which is affected by the rotation of the x, y, and z axes. |
1122 /// | m21 | The tenth value, which is affected by the rotation of the x, y, and z axes. |
1123 /// | m22 | Scaling value of the z-axis. The default value is **1** for the identity matrix. |
1124 /// | m23 | The 12th value, which is affected by perspective projection. |
1125 /// | m30 | Translation value of the x-axis, in px. The default value is **0** for the identity matrix.|
1126 /// | m31 | Translation value of the y-axis, in px. The default value is **0** for the identity matrix.|
1127 /// | m32 | Translation value of the z-axis, in px. The default value is **0** for the identity matrix.|
1128 /// | m33 | Valid in homogeneous coordinates, presenting the perspective projection effect. |
1129 ///
1130 /// # Returns
1131 ///
1132 /// * Error code.
1133 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1134 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1135 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1136 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1137 /// Add since api 22.
1138 ///
1139 /// Available since API-level: 20
1140 #[cfg(feature = "api-20")]
1141 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1142 pub fn OH_ArkUI_RenderNodeUtils_SetTransform(
1143 node: ArkUI_RenderNodeHandle,
1144 matrix: *mut f32,
1145 ) -> i32;
1146 /// Set the shadow color for a RenderNode.
1147 ///
1148 /// # Arguments
1149 ///
1150 /// * `node` - Handle to the target render node.
1151 ///
1152 /// * `color` - Packed ARGB color value (32-bit unsigned integer)
1153 /// Color byte layout:
1154 /// - Bits 24-31: Alpha channel (0x00 fully transparent, 0xFF fully opaque)
1155 /// - Bits 16-23: Red channel
1156 /// - Bits 8-15: Green channel
1157 /// - Bits 0-7: Blue channel
1158 ///
1159 /// # Returns
1160 ///
1161 /// * Error code.
1162 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1163 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1164 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1165 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1166 /// Add since api 22.
1167 ///
1168 /// Available since API-level: 20
1169 #[cfg(feature = "api-20")]
1170 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1171 pub fn OH_ArkUI_RenderNodeUtils_SetShadowColor(node: ArkUI_RenderNodeHandle, color: u32)
1172 -> i32;
1173 /// Get the shadow color of a RenderNode.
1174 ///
1175 /// # Arguments
1176 ///
1177 /// * `node` - Handle to the target render node.
1178 ///
1179 /// * `color` - Integer pointer to store the retrieved RGBA color value.
1180 /// The retrieved color is a packed 32-bit value with the following byte layout:
1181 /// - Bits 24-31: Alpha channel (0x00 fully transparent, 0xFF fully opaque)
1182 /// - Bits 16-23: Red channel
1183 /// - Bits 8-15: Green channel
1184 /// - Bits 0-7: Blue channel
1185 ///
1186 /// # Returns
1187 ///
1188 /// * Error code.
1189 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1190 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1191 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1192 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1193 /// Add since api 22.
1194 ///
1195 /// Available since API-level: 20
1196 #[cfg(feature = "api-20")]
1197 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1198 pub fn OH_ArkUI_RenderNodeUtils_GetShadowColor(
1199 node: ArkUI_RenderNodeHandle,
1200 color: *mut u32,
1201 ) -> i32;
1202 /// Set the shadow offset for a RenderNode.
1203 ///
1204 /// # Arguments
1205 ///
1206 /// * `node` - Handle to the target render node.
1207 ///
1208 /// * `x` - Horizontal offset value in pixels.
1209 ///
1210 /// * `y` - Vertical offset value in pixels.
1211 ///
1212 /// # Returns
1213 ///
1214 /// * Error code.
1215 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1216 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1217 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1218 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1219 /// Add since api 22.
1220 ///
1221 /// Available since API-level: 20
1222 #[cfg(feature = "api-20")]
1223 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1224 pub fn OH_ArkUI_RenderNodeUtils_SetShadowOffset(
1225 node: ArkUI_RenderNodeHandle,
1226 x: i32,
1227 y: i32,
1228 ) -> i32;
1229 /// Get the shadow offset of a RenderNode.
1230 ///
1231 /// # Arguments
1232 ///
1233 /// * `node` - Handle to the target render node.
1234 ///
1235 /// * `x` - Pointer to receive horizontal offset value.
1236 ///
1237 /// * `y` - Pointer to receive vertical offset value.
1238 ///
1239 /// # Returns
1240 ///
1241 /// * Error code.
1242 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1243 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1244 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1245 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1246 /// Add since api 22.
1247 ///
1248 /// Available since API-level: 20
1249 #[cfg(feature = "api-20")]
1250 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1251 pub fn OH_ArkUI_RenderNodeUtils_GetShadowOffset(
1252 node: ArkUI_RenderNodeHandle,
1253 x: *mut i32,
1254 y: *mut i32,
1255 ) -> i32;
1256 /// Set the shadow transparency for a RenderNode.
1257 ///
1258 /// # Arguments
1259 ///
1260 /// * `node` - Handle to the target render node.
1261 ///
1262 /// * `alpha` - Shadow alpha value (0.0-1.0).
1263 ///
1264 /// # Returns
1265 ///
1266 /// * Error code.
1267 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1268 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1269 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1270 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
1271 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1272 /// Add since api 22.
1273 ///
1274 /// Available since API-level: 20
1275 #[cfg(feature = "api-20")]
1276 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1277 pub fn OH_ArkUI_RenderNodeUtils_SetShadowAlpha(node: ArkUI_RenderNodeHandle, alpha: f32)
1278 -> i32;
1279 /// Get the shadow transparency of a RenderNode.
1280 ///
1281 /// # Arguments
1282 ///
1283 /// * `node` - Handle to the target render node.
1284 ///
1285 /// * `alpha` - Pointer to receive shadow alpha value.
1286 ///
1287 /// # Returns
1288 ///
1289 /// * Error code.
1290 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1291 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1292 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1293 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1294 /// Add since api 22.
1295 ///
1296 /// Available since API-level: 20
1297 #[cfg(feature = "api-20")]
1298 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1299 pub fn OH_ArkUI_RenderNodeUtils_GetShadowAlpha(
1300 node: ArkUI_RenderNodeHandle,
1301 alpha: *mut f32,
1302 ) -> i32;
1303 /// Set the shadow elevation for a RenderNode.
1304 ///
1305 /// # Arguments
1306 ///
1307 /// * `node` - Handle to the target render node.
1308 ///
1309 /// * `elevation` - Elevation value.
1310 ///
1311 /// # Returns
1312 ///
1313 /// * Error code.
1314 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1315 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1316 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1317 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
1318 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1319 /// Add since api 22.
1320 ///
1321 /// Available since API-level: 20
1322 #[cfg(feature = "api-20")]
1323 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1324 pub fn OH_ArkUI_RenderNodeUtils_SetShadowElevation(
1325 node: ArkUI_RenderNodeHandle,
1326 elevation: f32,
1327 ) -> i32;
1328 /// Get the shadow elevation of a RenderNode.
1329 ///
1330 /// # Arguments
1331 ///
1332 /// * `node` - Handle to the target render node.
1333 ///
1334 /// * `elevation` - Pointer to receive elevation value.
1335 ///
1336 /// # Returns
1337 ///
1338 /// * Error code.
1339 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1340 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1341 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1342 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1343 /// Add since api 22.
1344 ///
1345 /// Available since API-level: 20
1346 #[cfg(feature = "api-20")]
1347 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1348 pub fn OH_ArkUI_RenderNodeUtils_GetShadowElevation(
1349 node: ArkUI_RenderNodeHandle,
1350 elevation: *mut f32,
1351 ) -> i32;
1352 /// Set the shadow radius of a RenderNode.
1353 ///
1354 /// # Arguments
1355 ///
1356 /// * `node` - Handle to the target render node.
1357 ///
1358 /// * `radius` - Radius value.
1359 ///
1360 /// # Returns
1361 ///
1362 /// * Error code.
1363 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1364 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1365 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1366 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
1367 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1368 /// Add since api 22.
1369 ///
1370 /// Available since API-level: 20
1371 #[cfg(feature = "api-20")]
1372 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1373 pub fn OH_ArkUI_RenderNodeUtils_SetShadowRadius(
1374 node: ArkUI_RenderNodeHandle,
1375 radius: f32,
1376 ) -> i32;
1377 /// Get the shadow radius of a RenderNode.
1378 ///
1379 /// # Arguments
1380 ///
1381 /// * `node` - Handle to the target render node.
1382 ///
1383 /// * `radius` - Pointer to receive radius value.
1384 ///
1385 /// # Returns
1386 ///
1387 /// * Error code.
1388 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1389 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1390 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1391 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1392 /// Add since api 22.
1393 ///
1394 /// Available since API-level: 20
1395 #[cfg(feature = "api-20")]
1396 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1397 pub fn OH_ArkUI_RenderNodeUtils_GetShadowRadius(
1398 node: ArkUI_RenderNodeHandle,
1399 radius: *mut f32,
1400 ) -> i32;
1401 /// Set the border style for a RenderNode.
1402 ///
1403 /// # Arguments
1404 ///
1405 /// * `node` - Handle to the target render node.
1406 ///
1407 /// * `borderStyle` - Handle to border style option.
1408 ///
1409 /// # Returns
1410 ///
1411 /// * Error code.
1412 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1413 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1414 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1415 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1416 /// Add since api 22.
1417 ///
1418 /// Available since API-level: 20
1419 #[cfg(feature = "api-20")]
1420 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1421 pub fn OH_ArkUI_RenderNodeUtils_SetBorderStyle(
1422 node: ArkUI_RenderNodeHandle,
1423 borderStyle: *mut ArkUI_NodeBorderStyleOption,
1424 ) -> i32;
1425 /// Get the border style of a RenderNode.
1426 ///
1427 /// # Arguments
1428 ///
1429 /// * `node` - Handle to the target render node.
1430 ///
1431 /// * `borderStyle` - Pointer to receive border style option.
1432 ///
1433 /// # Returns
1434 ///
1435 /// * Error code.
1436 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1437 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1438 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1439 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1440 /// Add since api 22.
1441 ///
1442 /// Available since API-level: 20
1443 #[cfg(feature = "api-20")]
1444 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1445 pub fn OH_ArkUI_RenderNodeUtils_GetBorderStyle(
1446 node: ArkUI_RenderNodeHandle,
1447 borderStyle: *mut *mut ArkUI_NodeBorderStyleOption,
1448 ) -> i32;
1449 /// Set the border widths for a RenderNode.
1450 ///
1451 /// # Arguments
1452 ///
1453 /// * `node` - Handle to the target render node.
1454 ///
1455 /// * `borderWidth` - Handle to border width option.
1456 ///
1457 /// # Returns
1458 ///
1459 /// * Error code.
1460 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1461 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1462 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1463 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1464 /// Add since api 22.
1465 ///
1466 /// Available since API-level: 20
1467 #[cfg(feature = "api-20")]
1468 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1469 pub fn OH_ArkUI_RenderNodeUtils_SetBorderWidth(
1470 node: ArkUI_RenderNodeHandle,
1471 borderWidth: *mut ArkUI_NodeBorderWidthOption,
1472 ) -> i32;
1473 /// Get the border widths of a RenderNode.
1474 ///
1475 /// # Arguments
1476 ///
1477 /// * `node` - Handle to the target render node.
1478 ///
1479 /// * `borderWidth` - Pointer to receive border width option.
1480 ///
1481 /// # Returns
1482 ///
1483 /// * Error code.
1484 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1485 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1486 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1487 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1488 /// Add since api 22.
1489 ///
1490 /// Available since API-level: 20
1491 #[cfg(feature = "api-20")]
1492 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1493 pub fn OH_ArkUI_RenderNodeUtils_GetBorderWidth(
1494 node: ArkUI_RenderNodeHandle,
1495 borderWidth: *mut *mut ArkUI_NodeBorderWidthOption,
1496 ) -> i32;
1497 /// Set the border colors for a RenderNode.
1498 ///
1499 /// # Arguments
1500 ///
1501 /// * `node` - Handle to the target render node.
1502 ///
1503 /// * `borderColor` - Handle to border color option.
1504 ///
1505 /// # Returns
1506 ///
1507 /// * Error code.
1508 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1509 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1510 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1511 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1512 /// Add since api 22.
1513 ///
1514 /// Available since API-level: 20
1515 #[cfg(feature = "api-20")]
1516 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1517 pub fn OH_ArkUI_RenderNodeUtils_SetBorderColor(
1518 node: ArkUI_RenderNodeHandle,
1519 borderColor: *mut ArkUI_NodeBorderColorOption,
1520 ) -> i32;
1521 /// Get the border colors of a RenderNode.
1522 ///
1523 /// # Arguments
1524 ///
1525 /// * `node` - Handle to the target render node.
1526 ///
1527 /// * `borderColor` - Pointer to receive border color option.
1528 ///
1529 /// # Returns
1530 ///
1531 /// * Error code.
1532 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1533 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1534 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1535 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1536 /// Add since api 22.
1537 ///
1538 /// Available since API-level: 20
1539 #[cfg(feature = "api-20")]
1540 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1541 pub fn OH_ArkUI_RenderNodeUtils_GetBorderColor(
1542 node: ArkUI_RenderNodeHandle,
1543 borderColor: *mut *mut ArkUI_NodeBorderColorOption,
1544 ) -> i32;
1545 /// Set the border corner radius for a RenderNode.
1546 ///
1547 /// # Arguments
1548 ///
1549 /// * `node` - Handle to the target render node.
1550 ///
1551 /// * `borderRadius` - Handle to border radius option.
1552 /// eturn Error code.
1553 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1554 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1555 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1556 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1557 /// Add since api 22.
1558 ///
1559 /// Available since API-level: 20
1560 #[cfg(feature = "api-20")]
1561 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1562 pub fn OH_ArkUI_RenderNodeUtils_SetBorderRadius(
1563 node: ArkUI_RenderNodeHandle,
1564 borderRadius: *mut ArkUI_NodeBorderRadiusOption,
1565 ) -> i32;
1566 /// Get the border corner radius of a RenderNode.
1567 ///
1568 /// # Arguments
1569 ///
1570 /// * `node` - Handle to the target render node.
1571 ///
1572 /// * `borderRadius` - Pointer to receive border radius option.
1573 ///
1574 /// # Returns
1575 ///
1576 /// * Error code.
1577 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1578 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1579 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1580 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1581 /// Add since api 22.
1582 ///
1583 /// Available since API-level: 20
1584 #[cfg(feature = "api-20")]
1585 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1586 pub fn OH_ArkUI_RenderNodeUtils_GetBorderRadius(
1587 node: ArkUI_RenderNodeHandle,
1588 borderRadius: *mut *mut ArkUI_NodeBorderRadiusOption,
1589 ) -> i32;
1590 /// Apply a mask to a render node using the mask option.
1591 ///
1592 /// # Arguments
1593 ///
1594 /// * `node` - Handle to the target render node.
1595 ///
1596 /// * `mask` - Handle to the mask option.
1597 ///
1598 /// # Returns
1599 ///
1600 /// * Error code.
1601 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1602 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1603 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1604 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1605 /// Add since api 22.
1606 ///
1607 /// Available since API-level: 20
1608 #[cfg(feature = "api-20")]
1609 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1610 pub fn OH_ArkUI_RenderNodeUtils_SetMask(
1611 node: ArkUI_RenderNodeHandle,
1612 mask: *mut ArkUI_RenderNodeMaskOption,
1613 ) -> i32;
1614 /// Apply a clip to a render node using the clip option.
1615 ///
1616 /// # Arguments
1617 ///
1618 /// * `node` - Handle to the target render node.
1619 ///
1620 /// * `clip` - Handle to the clip option.
1621 ///
1622 /// # Returns
1623 ///
1624 /// * Error code.
1625 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1626 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1627 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1628 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1629 /// Add since api 22.
1630 ///
1631 /// Available since API-level: 20
1632 #[cfg(feature = "api-20")]
1633 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1634 pub fn OH_ArkUI_RenderNodeUtils_SetClip(
1635 node: ArkUI_RenderNodeHandle,
1636 clip: *mut ArkUI_RenderNodeClipOption,
1637 ) -> i32;
1638 /// Mark whether to preferentially draw the node and its children.
1639 ///
1640 /// # Arguments
1641 ///
1642 /// * `node` - Handle to the target render node.
1643 ///
1644 /// * `markNodeGroup` - Boolean flag indicates whether to preferentially draw the node and its children.
1645 ///
1646 /// # Returns
1647 ///
1648 /// * Error code.
1649 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1650 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1651 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1652 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1653 /// Add since api 22.
1654 ///
1655 /// Available since API-level: 20
1656 #[cfg(feature = "api-20")]
1657 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1658 pub fn OH_ArkUI_RenderNodeUtils_SetMarkNodeGroup(
1659 node: ArkUI_RenderNodeHandle,
1660 markNodeGroup: bool,
1661 ) -> i32;
1662 /// Set the bounds for a RenderNode.
1663 ///
1664 /// # Arguments
1665 ///
1666 /// * `node` - Handle to the target render node.
1667 ///
1668 /// * `x` - X-coordinate of the bounds's top-left corner (in pixels)
1669 ///
1670 /// * `y` - Y-coordinate of the bounds's top-left corner (in pixels)
1671 ///
1672 /// * `width` - Width of the bounds (in pixels).
1673 ///
1674 /// * `height` - Height of the bounds (in pixels).
1675 ///
1676 /// # Returns
1677 ///
1678 /// * Error code.
1679 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1680 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1681 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1682 /// [`ARKUI_ERROR_CODE_PARAM_OUT_OF_RANGE`] Parameter out of range.
1683 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1684 /// Add since api 22.
1685 ///
1686 /// Available since API-level: 20
1687 #[cfg(feature = "api-20")]
1688 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1689 pub fn OH_ArkUI_RenderNodeUtils_SetBounds(
1690 node: ArkUI_RenderNodeHandle,
1691 x: i32,
1692 y: i32,
1693 width: i32,
1694 height: i32,
1695 ) -> i32;
1696 /// Get the bounds for a RenderNode.
1697 ///
1698 /// # Arguments
1699 ///
1700 /// * `node` - Handle to the target render node.
1701 ///
1702 /// * `x` - Pointer to receive x-coordinate value of the bounds's top-left corner (in pixels)
1703 ///
1704 /// * `y` - Pointer to receive y-coordinate value of the bounds's top-left corner (in pixels)
1705 ///
1706 /// * `width` - Pointer to receive width value in pixels.
1707 ///
1708 /// * `height` - Pointer to receive height value in pixels.
1709 ///
1710 /// # Returns
1711 ///
1712 /// * Error code.
1713 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1714 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1715 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1716 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1717 /// Add since api 22.
1718 ///
1719 /// Available since API-level: 20
1720 #[cfg(feature = "api-20")]
1721 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1722 pub fn OH_ArkUI_RenderNodeUtils_GetBounds(
1723 node: ArkUI_RenderNodeHandle,
1724 x: *mut i32,
1725 y: *mut i32,
1726 width: *mut i32,
1727 height: *mut i32,
1728 ) -> i32;
1729 /// Set the draw region for a RenderNode.
1730 ///
1731 /// # Arguments
1732 ///
1733 /// * `node` - Handle to the target render node.
1734 ///
1735 /// * `x` - X-coordinate of the bounds's top-left corner (in pixels).
1736 ///
1737 /// * `y` - Y-coordinate of the bounds's top-left corner (in pixels).
1738 ///
1739 /// * `w` - Width of the bounds (in pixels).
1740 ///
1741 /// * `h` - Height of the bounds (in pixels).
1742 ///
1743 /// # Returns
1744 ///
1745 /// * Error code.
1746 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1747 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1748 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1749 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1750 /// Add since api 22.
1751 ///
1752 /// Available since API-level: 20
1753 #[cfg(feature = "api-20")]
1754 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1755 pub fn OH_ArkUI_RenderNodeUtils_SetDrawRegion(
1756 node: ArkUI_RenderNodeHandle,
1757 x: f32,
1758 y: f32,
1759 w: f32,
1760 h: f32,
1761 ) -> i32;
1762 /// Attach a content modifier for the render node.
1763 ///
1764 /// # Arguments
1765 ///
1766 /// * `node` - Handle to the target render node.
1767 ///
1768 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] The content modifier handle.
1769 ///
1770 /// # Returns
1771 ///
1772 /// * Error code.
1773 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1774 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1775 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1776 /// [`ARKUI_ERROR_CODE_RENDER_IS_FROM_FRAME_NODE`] if the node is obtained from a FrameNode.
1777 /// Add since api 22.
1778 ///
1779 /// Available since API-level: 20
1780 #[cfg(feature = "api-20")]
1781 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1782 pub fn OH_ArkUI_RenderNodeUtils_AttachContentModifier(
1783 node: ArkUI_RenderNodeHandle,
1784 modifier: ArkUI_RenderContentModifierHandle,
1785 ) -> i32;
1786 /// Create a content modifier handle.
1787 ///
1788 ///
1789 /// # Returns
1790 ///
1791 /// * [`ArkUI_RenderContentModifierHandle`] A content modifier handle.
1792 ///
1793 /// Available since API-level: 20
1794 #[cfg(feature = "api-20")]
1795 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1796 pub fn OH_ArkUI_RenderNodeUtils_CreateContentModifier() -> ArkUI_RenderContentModifierHandle;
1797 /// Dispose the content modifier handle.
1798 ///
1799 /// # Arguments
1800 ///
1801 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Handle to the content modifier.
1802 ///
1803 /// Available since API-level: 20
1804 #[cfg(feature = "api-20")]
1805 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1806 pub fn OH_ArkUI_RenderNodeUtils_DisposeContentModifier(
1807 modifier: ArkUI_RenderContentModifierHandle,
1808 );
1809 /// Attach a float property to the target content modifier.
1810 ///
1811 /// # Arguments
1812 ///
1813 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set float property to the target content modifier.
1814 ///
1815 /// * `property` - [`ArkUI_FloatPropertyHandle`] Handle to the float property.
1816 ///
1817 /// # Returns
1818 ///
1819 /// * Error code.
1820 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1821 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1822 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1823 ///
1824 /// Available since API-level: 20
1825 #[cfg(feature = "api-20")]
1826 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1827 pub fn OH_ArkUI_RenderNodeUtils_AttachFloatProperty(
1828 modifier: ArkUI_RenderContentModifierHandle,
1829 property: ArkUI_FloatPropertyHandle,
1830 ) -> i32;
1831 /// Attach a vector2 property to the target content modifier.
1832 ///
1833 /// # Arguments
1834 ///
1835 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set vector2 property to the target content modifier.
1836 ///
1837 /// * `property` - [`ArkUI_Vector2PropertyHandle`] Handle to the vector2 property.
1838 ///
1839 /// # Returns
1840 ///
1841 /// * Error code.
1842 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1843 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1844 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1845 ///
1846 /// Available since API-level: 20
1847 #[cfg(feature = "api-20")]
1848 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1849 pub fn OH_ArkUI_RenderNodeUtils_AttachVector2Property(
1850 modifier: ArkUI_RenderContentModifierHandle,
1851 property: ArkUI_Vector2PropertyHandle,
1852 ) -> i32;
1853 /// Attach a color property to the target content modifier.
1854 ///
1855 /// # Arguments
1856 ///
1857 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set color property to the target content modifier.
1858 ///
1859 /// * `property` - [`ArkUI_ColorPropertyHandle`] Handle to the color property.
1860 ///
1861 /// # Returns
1862 ///
1863 /// * Error code.
1864 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1865 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1866 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1867 ///
1868 /// Available since API-level: 20
1869 #[cfg(feature = "api-20")]
1870 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1871 pub fn OH_ArkUI_RenderNodeUtils_AttachColorProperty(
1872 modifier: ArkUI_RenderContentModifierHandle,
1873 property: ArkUI_ColorPropertyHandle,
1874 ) -> i32;
1875 /// Attach a float animatable property to the target content modifier.
1876 ///
1877 /// # Arguments
1878 ///
1879 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set float animatable property to the target content
1880 /// modifier.
1881 ///
1882 /// * `property` - [`ArkUI_FloatAnimatablePropertyHandle`] Handle to the float animatable property.
1883 ///
1884 /// # Returns
1885 ///
1886 /// * Error code.
1887 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1888 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1889 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1890 ///
1891 /// Available since API-level: 20
1892 #[cfg(feature = "api-20")]
1893 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1894 pub fn OH_ArkUI_RenderNodeUtils_AttachFloatAnimatableProperty(
1895 modifier: ArkUI_RenderContentModifierHandle,
1896 property: ArkUI_FloatAnimatablePropertyHandle,
1897 ) -> i32;
1898 /// Attach a vector2 animatable property to the target content modifier.
1899 ///
1900 /// # Arguments
1901 ///
1902 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set vector2 animatable property to the target content
1903 /// modifier.
1904 ///
1905 /// * `property` - [`ArkUI_Vector2AnimatablePropertyHandle`] Handle to the vector2 animatable property.
1906 ///
1907 /// # Returns
1908 ///
1909 /// * Error code.
1910 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1911 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1912 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1913 ///
1914 /// Available since API-level: 20
1915 #[cfg(feature = "api-20")]
1916 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1917 pub fn OH_ArkUI_RenderNodeUtils_AttachVector2AnimatableProperty(
1918 modifier: ArkUI_RenderContentModifierHandle,
1919 property: ArkUI_Vector2AnimatablePropertyHandle,
1920 ) -> i32;
1921 /// Attach a color property to the target content modifier.
1922 ///
1923 /// # Arguments
1924 ///
1925 /// * `modifier` - [`ArkUI_RenderContentModifierHandle`] Set color animatable property to the target content
1926 /// modifier.
1927 ///
1928 /// * `property` - [`ArkUI_ColorAnimatablePropertyHandle`] Handle to the color animatable property.
1929 ///
1930 /// # Returns
1931 ///
1932 /// * Error code.
1933 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1934 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1935 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1936 ///
1937 /// Available since API-level: 20
1938 #[cfg(feature = "api-20")]
1939 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1940 pub fn OH_ArkUI_RenderNodeUtils_AttachColorAnimatableProperty(
1941 modifier: ArkUI_RenderContentModifierHandle,
1942 property: ArkUI_ColorAnimatablePropertyHandle,
1943 ) -> i32;
1944 /// Create a float property handle.
1945 ///
1946 /// # Arguments
1947 ///
1948 /// * `value` - The property value.
1949 ///
1950 /// # Returns
1951 ///
1952 /// * Handle to the float property.
1953 ///
1954 /// Available since API-level: 20
1955 #[cfg(feature = "api-20")]
1956 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1957 pub fn OH_ArkUI_RenderNodeUtils_CreateFloatProperty(value: f32) -> ArkUI_FloatPropertyHandle;
1958 /// Set value of the float property.
1959 ///
1960 /// # Arguments
1961 ///
1962 /// * `property` - [`ArkUI_FloatPropertyHandle`] The float property handle.
1963 ///
1964 /// * `value` - The property value.
1965 ///
1966 /// # Returns
1967 ///
1968 /// * Error code.
1969 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1970 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1971 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1972 ///
1973 /// Available since API-level: 20
1974 #[cfg(feature = "api-20")]
1975 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1976 pub fn OH_ArkUI_RenderNodeUtils_SetFloatPropertyValue(
1977 property: ArkUI_FloatPropertyHandle,
1978 value: f32,
1979 ) -> i32;
1980 /// Get value of the float property.
1981 ///
1982 /// # Arguments
1983 ///
1984 /// * `property` - [`ArkUI_FloatPropertyHandle`] The float property handle.
1985 ///
1986 /// * `value` - The pointer to receive property value.
1987 ///
1988 /// # Returns
1989 ///
1990 /// * Error code.
1991 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
1992 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
1993 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
1994 ///
1995 /// Available since API-level: 20
1996 #[cfg(feature = "api-20")]
1997 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
1998 pub fn OH_ArkUI_RenderNodeUtils_GetFloatPropertyValue(
1999 property: ArkUI_FloatPropertyHandle,
2000 value: *mut f32,
2001 ) -> i32;
2002 /// Dispose the float property handle.
2003 ///
2004 /// # Arguments
2005 ///
2006 /// * `property` - [`ArkUI_FloatPropertyHandle`] Handle to the float property.
2007 ///
2008 /// Available since API-level: 20
2009 #[cfg(feature = "api-20")]
2010 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2011 pub fn OH_ArkUI_RenderNodeUtils_DisposeFloatProperty(property: ArkUI_FloatPropertyHandle);
2012 /// Create a vector2 property handle.
2013 ///
2014 /// # Arguments
2015 ///
2016 /// * `x` - X-coordinate value of the property.
2017 ///
2018 /// * `y` - Y-coordinate value of the property.
2019 ///
2020 /// # Returns
2021 ///
2022 /// * Handle to the vector2 property.
2023 ///
2024 /// Available since API-level: 20
2025 #[cfg(feature = "api-20")]
2026 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2027 pub fn OH_ArkUI_RenderNodeUtils_CreateVector2Property(
2028 x: f32,
2029 y: f32,
2030 ) -> ArkUI_Vector2PropertyHandle;
2031 /// Set value of the vector2 property.
2032 ///
2033 /// # Arguments
2034 ///
2035 /// * `property` - [`ArkUI_Vector2PropertyHandle`] The vector2 property handle.
2036 ///
2037 /// * `x` - X-coordinate value of the property.
2038 ///
2039 /// * `y` - Y-coordinate value of the property.
2040 ///
2041 /// # Returns
2042 ///
2043 /// * Error code.
2044 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2045 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2046 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2047 ///
2048 /// Available since API-level: 20
2049 #[cfg(feature = "api-20")]
2050 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2051 pub fn OH_ArkUI_RenderNodeUtils_SetVector2PropertyValue(
2052 property: ArkUI_Vector2PropertyHandle,
2053 x: f32,
2054 y: f32,
2055 ) -> i32;
2056 /// Get value of the vector2 property.
2057 ///
2058 /// # Arguments
2059 ///
2060 /// * `property` - [`ArkUI_Vector2PropertyHandle`] The Vector2 property handle.
2061 ///
2062 /// * `x` - The pointer to receive x-coordinate value of the property.
2063 ///
2064 /// * `y` - The pointer to receive y-coordinate value of the property.
2065 ///
2066 /// # Returns
2067 ///
2068 /// * Error code.
2069 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2070 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2071 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2072 ///
2073 /// Available since API-level: 20
2074 #[cfg(feature = "api-20")]
2075 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2076 pub fn OH_ArkUI_RenderNodeUtils_GetVector2PropertyValue(
2077 property: ArkUI_Vector2PropertyHandle,
2078 x: *mut f32,
2079 y: *mut f32,
2080 ) -> i32;
2081 /// Dispose the vector2 property handle.
2082 ///
2083 /// # Arguments
2084 ///
2085 /// * `property` - [`ArkUI_Vector2PropertyHandle`] Handle to the vector2 property.
2086 ///
2087 /// Available since API-level: 20
2088 #[cfg(feature = "api-20")]
2089 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2090 pub fn OH_ArkUI_RenderNodeUtils_DisposeVector2Property(property: ArkUI_Vector2PropertyHandle);
2091 /// Create a color property handle.
2092 ///
2093 /// # Arguments
2094 ///
2095 /// * `value` - The property value.
2096 ///
2097 /// # Returns
2098 ///
2099 /// * Handle to the color property.
2100 ///
2101 /// Available since API-level: 20
2102 #[cfg(feature = "api-20")]
2103 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2104 pub fn OH_ArkUI_RenderNodeUtils_CreateColorProperty(value: u32) -> ArkUI_ColorPropertyHandle;
2105 /// Set value of the color property.
2106 ///
2107 /// # Arguments
2108 ///
2109 /// * `property` - [`ArkUI_ColorPropertyHandle`] The color property handle.
2110 ///
2111 /// * `value` - The property value.
2112 ///
2113 /// # Returns
2114 ///
2115 /// * Error code.
2116 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2117 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2118 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2119 ///
2120 /// Available since API-level: 20
2121 #[cfg(feature = "api-20")]
2122 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2123 pub fn OH_ArkUI_RenderNodeUtils_SetColorPropertyValue(
2124 property: ArkUI_ColorPropertyHandle,
2125 value: u32,
2126 ) -> i32;
2127 /// Get value of the color property.
2128 ///
2129 /// # Arguments
2130 ///
2131 /// * `property` - [`ArkUI_ColorPropertyHandle`] The color property handle.
2132 ///
2133 /// * `value` - The pointer to receive property value.
2134 ///
2135 /// # Returns
2136 ///
2137 /// * Error code.
2138 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2139 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2140 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2141 ///
2142 /// Available since API-level: 20
2143 #[cfg(feature = "api-20")]
2144 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2145 pub fn OH_ArkUI_RenderNodeUtils_GetColorPropertyValue(
2146 property: ArkUI_ColorPropertyHandle,
2147 value: *mut u32,
2148 ) -> i32;
2149 /// Dispose the color property handle.
2150 ///
2151 /// # Arguments
2152 ///
2153 /// * `property` - [`ArkUI_ColorPropertyHandle`] Handle to the color property.
2154 ///
2155 /// Available since API-level: 20
2156 #[cfg(feature = "api-20")]
2157 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2158 pub fn OH_ArkUI_RenderNodeUtils_DisposeColorProperty(property: ArkUI_ColorPropertyHandle);
2159 /// Create a float animatable property handle.
2160 ///
2161 /// # Arguments
2162 ///
2163 /// * `value` - The property value.
2164 ///
2165 /// # Returns
2166 ///
2167 /// * Handle to the float animatable property.
2168 ///
2169 /// Available since API-level: 20
2170 #[cfg(feature = "api-20")]
2171 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2172 pub fn OH_ArkUI_RenderNodeUtils_CreateFloatAnimatableProperty(
2173 value: f32,
2174 ) -> ArkUI_FloatAnimatablePropertyHandle;
2175 /// Set value of the float animatable property.
2176 ///
2177 /// # Arguments
2178 ///
2179 /// * `property` - [`ArkUI_FloatAnimatablePropertyHandle`] The float animatable property handle.
2180 ///
2181 /// * `value` - The property value.
2182 ///
2183 /// # Returns
2184 ///
2185 /// * Error code.
2186 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2187 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2188 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2189 ///
2190 /// Available since API-level: 20
2191 #[cfg(feature = "api-20")]
2192 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2193 pub fn OH_ArkUI_RenderNodeUtils_SetFloatAnimatablePropertyValue(
2194 property: ArkUI_FloatAnimatablePropertyHandle,
2195 value: f32,
2196 ) -> i32;
2197 /// Get value of the float animatable property.
2198 ///
2199 /// # Arguments
2200 ///
2201 /// * `property` - [`ArkUI_FloatAnimatablePropertyHandle`] The float animatable property handle.
2202 ///
2203 /// * `value` - The pointer to receive property value.
2204 ///
2205 /// # Returns
2206 ///
2207 /// * Error code.
2208 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2209 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2210 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2211 ///
2212 /// Available since API-level: 20
2213 #[cfg(feature = "api-20")]
2214 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2215 pub fn OH_ArkUI_RenderNodeUtils_GetFloatAnimatablePropertyValue(
2216 property: ArkUI_FloatAnimatablePropertyHandle,
2217 value: *mut f32,
2218 ) -> i32;
2219 /// Dispose the float animatable property handle.
2220 ///
2221 /// # Arguments
2222 ///
2223 /// * `property` - [`ArkUI_FloatAnimatablePropertyHandle`] Handle to the float animatable property.
2224 ///
2225 /// Available since API-level: 20
2226 #[cfg(feature = "api-20")]
2227 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2228 pub fn OH_ArkUI_RenderNodeUtils_DisposeFloatAnimatableProperty(
2229 property: ArkUI_FloatAnimatablePropertyHandle,
2230 );
2231 /// Create a vector2 animatable property handle.
2232 ///
2233 /// # Arguments
2234 ///
2235 /// * `x` - X-coordinate value of the property.
2236 ///
2237 /// * `y` - Y-coordinate value of the property.
2238 ///
2239 /// # Returns
2240 ///
2241 /// * Handle to the vector2 animatable property.
2242 ///
2243 /// Available since API-level: 20
2244 #[cfg(feature = "api-20")]
2245 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2246 pub fn OH_ArkUI_RenderNodeUtils_CreateVector2AnimatableProperty(
2247 x: f32,
2248 y: f32,
2249 ) -> ArkUI_Vector2AnimatablePropertyHandle;
2250 /// Set value of the vector2 animatable property.
2251 ///
2252 /// # Arguments
2253 ///
2254 /// * `property` - [`ArkUI_Vector2AnimatablePropertyHandle`] The vector2 animatable property handle.
2255 ///
2256 /// * `x` - X-coordinate value of the property.
2257 ///
2258 /// * `y` - Y-coordinate value of the property.
2259 ///
2260 /// # Returns
2261 ///
2262 /// * Error code.
2263 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2264 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2265 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2266 ///
2267 /// Available since API-level: 20
2268 #[cfg(feature = "api-20")]
2269 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2270 pub fn OH_ArkUI_RenderNodeUtils_SetVector2AnimatablePropertyValue(
2271 property: ArkUI_Vector2AnimatablePropertyHandle,
2272 x: f32,
2273 y: f32,
2274 ) -> i32;
2275 /// Get value of the vector2 animatable property.
2276 ///
2277 /// # Arguments
2278 ///
2279 /// * `property` - [`ArkUI_Vector2AnimatablePropertyHandle`] The Vector2 animatable property handle.
2280 ///
2281 /// * `x` - The pointer to receive x-coordinate value of the property.
2282 ///
2283 /// * `y` - The pointer to receive y-coordinate value of the property.
2284 ///
2285 /// # Returns
2286 ///
2287 /// * Error code.
2288 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2289 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2290 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2291 ///
2292 /// Available since API-level: 20
2293 #[cfg(feature = "api-20")]
2294 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2295 pub fn OH_ArkUI_RenderNodeUtils_GetVector2AnimatablePropertyValue(
2296 property: ArkUI_Vector2AnimatablePropertyHandle,
2297 x: *mut f32,
2298 y: *mut f32,
2299 ) -> i32;
2300 /// Dispose the vector2 animatable property handle.
2301 ///
2302 /// # Arguments
2303 ///
2304 /// * `property` - [`ArkUI_Vector2AnimatablePropertyHandle`] Handle to the vector2 animatable property.
2305 ///
2306 /// Available since API-level: 20
2307 #[cfg(feature = "api-20")]
2308 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2309 pub fn OH_ArkUI_RenderNodeUtils_DisposeVector2AnimatableProperty(
2310 property: ArkUI_Vector2AnimatablePropertyHandle,
2311 );
2312 /// Create a color animatable property handle.
2313 ///
2314 /// # Arguments
2315 ///
2316 /// * `value` - The property value.
2317 ///
2318 /// # Returns
2319 ///
2320 /// * Handle to the color animatable property.
2321 ///
2322 /// Available since API-level: 20
2323 #[cfg(feature = "api-20")]
2324 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2325 pub fn OH_ArkUI_RenderNodeUtils_CreateColorAnimatableProperty(
2326 value: u32,
2327 ) -> ArkUI_ColorAnimatablePropertyHandle;
2328 /// Set value of the color animatable property.
2329 ///
2330 /// # Arguments
2331 ///
2332 /// * `property` - [`ArkUI_ColorAnimatablePropertyHandle`] The color animatable property handle.
2333 ///
2334 /// * `value` - The property value.
2335 ///
2336 /// # Returns
2337 ///
2338 /// * Error code.
2339 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2340 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2341 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2342 ///
2343 /// Available since API-level: 20
2344 #[cfg(feature = "api-20")]
2345 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2346 pub fn OH_ArkUI_RenderNodeUtils_SetColorAnimatablePropertyValue(
2347 property: ArkUI_ColorAnimatablePropertyHandle,
2348 value: u32,
2349 ) -> i32;
2350 /// Get value of the color animatable property.
2351 ///
2352 /// # Arguments
2353 ///
2354 /// * `property` - [`ArkUI_ColorAnimatablePropertyHandle`] The color animatable property handle.
2355 ///
2356 /// * `value` - The pointer to receive property value.
2357 ///
2358 /// # Returns
2359 ///
2360 /// * Error code.
2361 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2362 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2363 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2364 ///
2365 /// Available since API-level: 20
2366 #[cfg(feature = "api-20")]
2367 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2368 pub fn OH_ArkUI_RenderNodeUtils_GetColorAnimatablePropertyValue(
2369 property: ArkUI_ColorAnimatablePropertyHandle,
2370 value: *mut u32,
2371 ) -> i32;
2372 /// Dispose the color animatable property handle.
2373 ///
2374 /// # Arguments
2375 ///
2376 /// * `property` - [`ArkUI_ColorAnimatablePropertyHandle`] Handle to the color animatable property.
2377 ///
2378 /// Available since API-level: 20
2379 #[cfg(feature = "api-20")]
2380 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2381 pub fn OH_ArkUI_RenderNodeUtils_DisposeColorAnimatableProperty(
2382 property: ArkUI_ColorAnimatablePropertyHandle,
2383 );
2384 /// Set the onDraw function of the content modifier.
2385 ///
2386 /// # Arguments
2387 ///
2388 /// * `modifier` - The target content modifier handle.
2389 ///
2390 /// * `userData` - Custom data to be passed to the callback.
2391 ///
2392 /// * `callback` - The draw event receiver callback.
2393 ///
2394 /// # Returns
2395 ///
2396 /// * Error code.
2397 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
2398 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
2399 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if CAPI init error.
2400 ///
2401 /// Available since API-level: 20
2402 #[cfg(feature = "api-20")]
2403 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2404 pub fn OH_ArkUI_RenderNodeUtils_SetContentModifierOnDraw(
2405 modifier: ArkUI_RenderContentModifierHandle,
2406 userData: *mut ::core::ffi::c_void,
2407 callback: ::core::option::Option<
2408 unsafe extern "C" fn(
2409 context: *mut ArkUI_DrawContext,
2410 userData: *mut ::core::ffi::c_void,
2411 ),
2412 >,
2413 ) -> i32;
2414 /// Create a RectShape option.
2415 ///
2416 ///
2417 /// # Returns
2418 ///
2419 /// * A pointer to the RectShape option.
2420 ///
2421 /// Available since API-level: 20
2422 #[cfg(feature = "api-20")]
2423 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2424 pub fn OH_ArkUI_RenderNodeUtils_CreateRectShapeOption() -> *mut ArkUI_RectShapeOption;
2425 /// Dispose the RectShape option.
2426 ///
2427 /// # Arguments
2428 ///
2429 /// * `option` - Pointer to the RectShape option.
2430 ///
2431 /// Available since API-level: 20
2432 #[cfg(feature = "api-20")]
2433 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2434 pub fn OH_ArkUI_RenderNodeUtils_DisposeRectShapeOption(option: *mut ArkUI_RectShapeOption);
2435 /// Set the edge value of RectShape option.
2436 ///
2437 /// # Arguments
2438 ///
2439 /// * `option` - Pointer to the RectShape option.
2440 ///
2441 /// * `edgeValue` - The edge value of the RectShape.
2442 ///
2443 /// * `direction` - [`ArkUI_EdgeDirection`] The direction of the edge.
2444 ///
2445 /// Available since API-level: 20
2446 #[cfg(feature = "api-20")]
2447 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2448 pub fn OH_ArkUI_RenderNodeUtils_SetRectShapeOptionEdgeValue(
2449 option: *mut ArkUI_RectShapeOption,
2450 edgeValue: f32,
2451 direction: ArkUI_EdgeDirection,
2452 );
2453 /// Create a NodeBorderStyle option.
2454 ///
2455 ///
2456 /// # Returns
2457 ///
2458 /// * A pointer to the NodeBorderStyle option.
2459 ///
2460 /// Available since API-level: 20
2461 #[cfg(feature = "api-20")]
2462 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2463 pub fn OH_ArkUI_RenderNodeUtils_CreateNodeBorderStyleOption() -> *mut ArkUI_NodeBorderStyleOption;
2464 /// Dispose the NodeBorderStyle option.
2465 ///
2466 /// # Arguments
2467 ///
2468 /// * `option` - Pointer to the NodeBorderStyle option.
2469 ///
2470 /// Available since API-level: 20
2471 #[cfg(feature = "api-20")]
2472 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2473 pub fn OH_ArkUI_RenderNodeUtils_DisposeNodeBorderStyleOption(
2474 option: *mut ArkUI_NodeBorderStyleOption,
2475 );
2476 /// Set the edge value of NodeBorderStyle option.
2477 ///
2478 /// # Arguments
2479 ///
2480 /// * `option` - Pointer to the NodeBorderStyle option.
2481 ///
2482 /// * `edgeStyle` - [`ArkUI_BorderStyle`] The edge border style value of the NodeBorderStyle option.
2483 ///
2484 /// * `direction` - [`ArkUI_EdgeDirection`] The direction of the edge.
2485 ///
2486 /// Available since API-level: 20
2487 #[cfg(feature = "api-20")]
2488 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2489 pub fn OH_ArkUI_RenderNodeUtils_SetNodeBorderStyleOptionEdgeStyle(
2490 option: *mut ArkUI_NodeBorderStyleOption,
2491 edgeStyle: ArkUI_BorderStyle,
2492 direction: ArkUI_EdgeDirection,
2493 );
2494 /// Create a NodeBorderWidth option.
2495 ///
2496 ///
2497 /// # Returns
2498 ///
2499 /// * A pointer to the NodeBorderWidth option.
2500 ///
2501 /// Available since API-level: 20
2502 #[cfg(feature = "api-20")]
2503 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2504 pub fn OH_ArkUI_RenderNodeUtils_CreateNodeBorderWidthOption() -> *mut ArkUI_NodeBorderWidthOption;
2505 /// Dispose the NodeBorderWidth option.
2506 ///
2507 /// # Arguments
2508 ///
2509 /// * `option` - Pointer to the NodeBorderWidth option.
2510 ///
2511 /// Available since API-level: 20
2512 #[cfg(feature = "api-20")]
2513 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2514 pub fn OH_ArkUI_RenderNodeUtils_DisposeNodeBorderWidthOption(
2515 option: *mut ArkUI_NodeBorderWidthOption,
2516 );
2517 /// Set the edge value of NodeBorderWidth option.
2518 ///
2519 /// # Arguments
2520 ///
2521 /// * `option` - Pointer to the NodeBorderWidth option.
2522 ///
2523 /// * `edgeWidth` - The edge width value of the NodeBorderWidth option.
2524 ///
2525 /// * `direction` - [`ArkUI_EdgeDirection`] The direction of the edge.
2526 ///
2527 /// Available since API-level: 20
2528 #[cfg(feature = "api-20")]
2529 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2530 pub fn OH_ArkUI_RenderNodeUtils_SetNodeBorderWidthOptionEdgeWidth(
2531 option: *mut ArkUI_NodeBorderWidthOption,
2532 edgeWidth: f32,
2533 direction: ArkUI_EdgeDirection,
2534 );
2535 /// Create a NodeBorderColor option.
2536 ///
2537 ///
2538 /// # Returns
2539 ///
2540 /// * A pointer to the NodeBorderColor option.
2541 ///
2542 /// Available since API-level: 20
2543 #[cfg(feature = "api-20")]
2544 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2545 pub fn OH_ArkUI_RenderNodeUtils_CreateNodeBorderColorOption() -> *mut ArkUI_NodeBorderColorOption;
2546 /// Dispose the NodeBorderColor option.
2547 ///
2548 /// # Arguments
2549 ///
2550 /// * `option` - Pointer to the NodeBorderColor option.
2551 ///
2552 /// Available since API-level: 20
2553 #[cfg(feature = "api-20")]
2554 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2555 pub fn OH_ArkUI_RenderNodeUtils_DisposeNodeBorderColorOption(
2556 option: *mut ArkUI_NodeBorderColorOption,
2557 );
2558 /// Set the edge value of NodeBorderColor option.
2559 ///
2560 /// # Arguments
2561 ///
2562 /// * `option` - Pointer to the NodeBorderColor option.
2563 ///
2564 /// * `edgeColor` - The edge color value of the NodeBorderColor option.
2565 ///
2566 /// * `direction` - [`ArkUI_EdgeDirection`] The direction of the edge.
2567 ///
2568 /// Available since API-level: 20
2569 #[cfg(feature = "api-20")]
2570 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2571 pub fn OH_ArkUI_RenderNodeUtils_SetNodeBorderColorOptionEdgeColor(
2572 option: *mut ArkUI_NodeBorderColorOption,
2573 edgeColor: u32,
2574 direction: ArkUI_EdgeDirection,
2575 );
2576 /// Create a NodeBorderRadius option.
2577 ///
2578 ///
2579 /// # Returns
2580 ///
2581 /// * A pointer to the NodeBorderRadius option.
2582 ///
2583 /// Available since API-level: 20
2584 #[cfg(feature = "api-20")]
2585 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2586 pub fn OH_ArkUI_RenderNodeUtils_CreateNodeBorderRadiusOption(
2587 ) -> *mut ArkUI_NodeBorderRadiusOption;
2588 /// Dispose the NodeBorderRadius option.
2589 ///
2590 /// # Arguments
2591 ///
2592 /// * `option` - Pointer to the NodeBorderRadius option.
2593 ///
2594 /// Available since API-level: 20
2595 #[cfg(feature = "api-20")]
2596 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2597 pub fn OH_ArkUI_RenderNodeUtils_DisposeNodeBorderRadiusOption(
2598 option: *mut ArkUI_NodeBorderRadiusOption,
2599 );
2600 /// Set the corner value of NodeBorderRadius option.
2601 ///
2602 /// # Arguments
2603 ///
2604 /// * `option` - Pointer to the NodeBorderRadius option.
2605 ///
2606 /// * `cornerRadius` - The corner radius value of the NodeBorderRadius option.
2607 ///
2608 /// * `direction` - [`ArkUI_CornerDirection`] The direction of the corner.
2609 ///
2610 /// Available since API-level: 20
2611 #[cfg(feature = "api-20")]
2612 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2613 pub fn OH_ArkUI_RenderNodeUtils_SetNodeBorderRadiusOptionCornerRadius(
2614 option: *mut ArkUI_NodeBorderRadiusOption,
2615 cornerRadius: u32,
2616 direction: ArkUI_CornerDirection,
2617 );
2618 /// Create a CircleShape option.
2619 ///
2620 ///
2621 /// # Returns
2622 ///
2623 /// * A pointer to the CircleShape option.
2624 ///
2625 /// Available since API-level: 20
2626 #[cfg(feature = "api-20")]
2627 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2628 pub fn OH_ArkUI_RenderNodeUtils_CreateCircleShapeOption() -> *mut ArkUI_CircleShapeOption;
2629 /// Dispose the CircleShape option.
2630 ///
2631 /// # Arguments
2632 ///
2633 /// * `option` - Pointer to the CircleShape option.
2634 ///
2635 /// Available since API-level: 20
2636 #[cfg(feature = "api-20")]
2637 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2638 pub fn OH_ArkUI_RenderNodeUtils_DisposeCircleShapeOption(option: *mut ArkUI_CircleShapeOption);
2639 /// Set the centerX value of CircleShape option.
2640 ///
2641 /// # Arguments
2642 ///
2643 /// * `option` - Pointer to the CircleShape option.
2644 ///
2645 /// * `centerX` - The centerX value.
2646 ///
2647 /// Available since API-level: 20
2648 #[cfg(feature = "api-20")]
2649 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2650 pub fn OH_ArkUI_RenderNodeUtils_SetCircleShapeOptionCenterX(
2651 option: *mut ArkUI_CircleShapeOption,
2652 centerX: f32,
2653 );
2654 /// Set the centerY value of CircleShape option.
2655 ///
2656 /// # Arguments
2657 ///
2658 /// * `option` - Pointer to the CircleShape option.
2659 ///
2660 /// * `centerY` - The centerY value.
2661 ///
2662 /// Available since API-level: 20
2663 #[cfg(feature = "api-20")]
2664 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2665 pub fn OH_ArkUI_RenderNodeUtils_SetCircleShapeOptionCenterY(
2666 option: *mut ArkUI_CircleShapeOption,
2667 centerY: f32,
2668 );
2669 /// Set the radius value of CircleShape option.
2670 ///
2671 /// # Arguments
2672 ///
2673 /// * `option` - Pointer to the CircleShape option.
2674 ///
2675 /// * `radius` - The radius value.
2676 ///
2677 /// Available since API-level: 20
2678 #[cfg(feature = "api-20")]
2679 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2680 pub fn OH_ArkUI_RenderNodeUtils_SetCircleShapeOptionRadius(
2681 option: *mut ArkUI_CircleShapeOption,
2682 radius: f32,
2683 );
2684 /// Create a RoundRectShape option.
2685 ///
2686 ///
2687 /// # Returns
2688 ///
2689 /// * A pointer to the RoundRectShape option.
2690 ///
2691 /// Available since API-level: 20
2692 #[cfg(feature = "api-20")]
2693 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2694 pub fn OH_ArkUI_RenderNodeUtils_CreateRoundRectShapeOption() -> *mut ArkUI_RoundRectShapeOption;
2695 /// Dispose the RoundRectShape option.
2696 ///
2697 /// # Arguments
2698 ///
2699 /// * `option` - Pointer to the RoundRectShape option.
2700 ///
2701 /// Available since API-level: 20
2702 #[cfg(feature = "api-20")]
2703 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2704 pub fn OH_ArkUI_RenderNodeUtils_DisposeRoundRectShapeOption(
2705 option: *mut ArkUI_RoundRectShapeOption,
2706 );
2707 /// Set the edge value of RoundRectShape option.
2708 ///
2709 /// # Arguments
2710 ///
2711 /// * `option` - Pointer to the RoundRectShape option.
2712 ///
2713 /// * `edgeValue` - The edge value of the RoundRectShape.
2714 ///
2715 /// * `direction` - [`ArkUI_EdgeDirection`] The direction of the edge.
2716 ///
2717 /// Available since API-level: 20
2718 #[cfg(feature = "api-20")]
2719 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2720 pub fn OH_ArkUI_RenderNodeUtils_SetRoundRectShapeOptionEdgeValue(
2721 option: *mut ArkUI_RoundRectShapeOption,
2722 edgeValue: f32,
2723 direction: ArkUI_EdgeDirection,
2724 );
2725 /// Set the coordinate value of the target corner.
2726 ///
2727 /// # Arguments
2728 ///
2729 /// * `option` - Pointer to the RoundRectShape option.
2730 ///
2731 /// * `x` - X-coordinate of the target corner (in pixels).
2732 ///
2733 /// * `y` - Y-coordinate of the target corner (in pixels).
2734 ///
2735 /// * `direction` - [`ArkUI_CornerDirection`] The direction of the corner.
2736 ///
2737 /// Available since API-level: 20
2738 #[cfg(feature = "api-20")]
2739 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2740 pub fn OH_ArkUI_RenderNodeUtils_SetRoundRectShapeOptionCornerXY(
2741 option: *mut ArkUI_RoundRectShapeOption,
2742 x: f32,
2743 y: f32,
2744 direction: ArkUI_CornerDirection,
2745 );
2746 /// Create a CommandPath option.
2747 ///
2748 ///
2749 /// # Returns
2750 ///
2751 /// * A pointer to the CommandPath option.
2752 ///
2753 /// Available since API-level: 20
2754 #[cfg(feature = "api-20")]
2755 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2756 pub fn OH_ArkUI_RenderNodeUtils_CreateCommandPathOption() -> *mut ArkUI_CommandPathOption;
2757 /// Dispose the CommandPath option.
2758 ///
2759 /// # Arguments
2760 ///
2761 /// * `option` - Pointer to the CommandPath option.
2762 ///
2763 /// Available since API-level: 20
2764 #[cfg(feature = "api-20")]
2765 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2766 pub fn OH_ArkUI_RenderNodeUtils_DisposeCommandPathOption(option: *mut ArkUI_CommandPathOption);
2767 /// Set the commands value of CommandPath option.
2768 ///
2769 /// # Arguments
2770 ///
2771 /// * `option` - Pointer to the CommandPath option.
2772 ///
2773 /// * `commands` - The commands value.
2774 ///
2775 /// Available since API-level: 20
2776 #[cfg(feature = "api-20")]
2777 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2778 pub fn OH_ArkUI_RenderNodeUtils_SetCommandPathOptionCommands(
2779 option: *mut ArkUI_CommandPathOption,
2780 commands: *mut ::core::ffi::c_char,
2781 );
2782 /// Create a mask option from a RectShape option.
2783 ///
2784 /// # Arguments
2785 ///
2786 /// * `shape` - [`ArkUI_RectShapeOption`] Pointer to the RectShape option.
2787 ///
2788 /// # Returns
2789 ///
2790 /// * A pointer to the RenderNodeMask option.
2791 ///
2792 /// Available since API-level: 20
2793 #[cfg(feature = "api-20")]
2794 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2795 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeMaskOptionFromRectShape(
2796 shape: *mut ArkUI_RectShapeOption,
2797 ) -> *mut ArkUI_RenderNodeMaskOption;
2798 /// Create a mask option from a RoundRectShape option.
2799 ///
2800 /// # Arguments
2801 ///
2802 /// * `shape` - [`ArkUI_RoundRectShapeOption`] Pointer to the RoundRectShape option.
2803 ///
2804 /// # Returns
2805 ///
2806 /// * A pointer to the RenderNodeMask option.
2807 ///
2808 /// Available since API-level: 20
2809 #[cfg(feature = "api-20")]
2810 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2811 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeMaskOptionFromRoundRectShape(
2812 shape: *mut ArkUI_RoundRectShapeOption,
2813 ) -> *mut ArkUI_RenderNodeMaskOption;
2814 /// Create a mask option from a CircleShape option.
2815 ///
2816 /// # Arguments
2817 ///
2818 /// * `shape` - [`ArkUI_CircleShapeOption`] Pointer to the CircleShape option.
2819 ///
2820 /// # Returns
2821 ///
2822 /// * A pointer to the RenderNodeMask option.
2823 ///
2824 /// Available since API-level: 20
2825 #[cfg(feature = "api-20")]
2826 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2827 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeMaskOptionFromCircleShape(
2828 shape: *mut ArkUI_CircleShapeOption,
2829 ) -> *mut ArkUI_RenderNodeMaskOption;
2830 /// Create a mask option from a OvalShape option.
2831 ///
2832 /// # Arguments
2833 ///
2834 /// * `shape` - [`ArkUI_RectShapeOption`] Pointer to the OvalShape option.
2835 ///
2836 /// # Returns
2837 ///
2838 /// * A pointer to the RenderNodeMask option.
2839 ///
2840 /// Available since API-level: 20
2841 #[cfg(feature = "api-20")]
2842 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2843 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeMaskOptionFromOvalShape(
2844 shape: *mut ArkUI_RectShapeOption,
2845 ) -> *mut ArkUI_RenderNodeMaskOption;
2846 /// Create a mask option from a CommandPath option.
2847 ///
2848 /// # Arguments
2849 ///
2850 /// * `path` - [`ArkUI_CommandPathOption`] Pointer to the CommandPath option.
2851 ///
2852 /// # Returns
2853 ///
2854 /// * A pointer to the RenderNodeMask option.
2855 ///
2856 /// Available since API-level: 20
2857 #[cfg(feature = "api-20")]
2858 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2859 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeMaskOptionFromCommandPath(
2860 path: *mut ArkUI_CommandPathOption,
2861 ) -> *mut ArkUI_RenderNodeMaskOption;
2862 /// Dispose the RenderNodeMask option.
2863 ///
2864 /// # Arguments
2865 ///
2866 /// * `option` - Pointer to the RenderNodeMask option.
2867 ///
2868 /// Available since API-level: 20
2869 #[cfg(feature = "api-20")]
2870 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2871 pub fn OH_ArkUI_RenderNodeUtils_DisposeRenderNodeMaskOption(
2872 option: *mut ArkUI_RenderNodeMaskOption,
2873 );
2874 /// Set the fill color of RenderNodeMask option.
2875 ///
2876 /// # Arguments
2877 ///
2878 /// * `mask` - Pointer to the RenderNodeMask option.
2879 ///
2880 /// * `fillColor` - The fill color of the mask.
2881 ///
2882 /// Available since API-level: 20
2883 #[cfg(feature = "api-20")]
2884 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2885 pub fn OH_ArkUI_RenderNodeUtils_SetRenderNodeMaskOptionFillColor(
2886 mask: *mut ArkUI_RenderNodeMaskOption,
2887 fillColor: u32,
2888 );
2889 /// Set the stroke color of RenderNodeMask option.
2890 ///
2891 /// # Arguments
2892 ///
2893 /// * `mask` - Pointer to the RenderNodeMask option.
2894 ///
2895 /// * `strokeColor` - The stroke color of the mask.
2896 ///
2897 /// Available since API-level: 20
2898 #[cfg(feature = "api-20")]
2899 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2900 pub fn OH_ArkUI_RenderNodeUtils_SetRenderNodeMaskOptionStrokeColor(
2901 mask: *mut ArkUI_RenderNodeMaskOption,
2902 strokeColor: u32,
2903 );
2904 /// Set the stroke width of RenderNodeMask option.
2905 ///
2906 /// # Arguments
2907 ///
2908 /// * `mask` - Pointer to the RenderNodeMask option.
2909 ///
2910 /// * `strokeWidth` - The stroke width of the mask.
2911 ///
2912 /// Available since API-level: 20
2913 #[cfg(feature = "api-20")]
2914 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2915 pub fn OH_ArkUI_RenderNodeUtils_SetRenderNodeMaskOptionStrokeWidth(
2916 mask: *mut ArkUI_RenderNodeMaskOption,
2917 strokeWidth: f32,
2918 );
2919 /// Create a clip option from a RectShape option.
2920 ///
2921 /// # Arguments
2922 ///
2923 /// * `shape` - [`ArkUI_RectShapeOption`] Pointer to the RectShape option.
2924 ///
2925 /// # Returns
2926 ///
2927 /// * A pointer to the RenderNodeClip option.
2928 ///
2929 /// Available since API-level: 20
2930 #[cfg(feature = "api-20")]
2931 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2932 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeClipOptionFromRectShape(
2933 shape: *mut ArkUI_RectShapeOption,
2934 ) -> *mut ArkUI_RenderNodeClipOption;
2935 /// Create a clip option from a RoundRectShape option.
2936 ///
2937 /// # Arguments
2938 ///
2939 /// * `shape` - [`ArkUI_RoundRectShapeOption`] Pointer to the RoundRectShape option.
2940 ///
2941 /// # Returns
2942 ///
2943 /// * A pointer to the RenderNodeClip option.
2944 ///
2945 /// Available since API-level: 20
2946 #[cfg(feature = "api-20")]
2947 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2948 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeClipOptionFromRoundRectShape(
2949 shape: *mut ArkUI_RoundRectShapeOption,
2950 ) -> *mut ArkUI_RenderNodeClipOption;
2951 /// Create a clip option from a CircleShape option.
2952 ///
2953 /// # Arguments
2954 ///
2955 /// * `shape` - [`ArkUI_CircleShapeOption`] Pointer to the CircleShape option.
2956 ///
2957 /// # Returns
2958 ///
2959 /// * A pointer to the RenderNodeClip option.
2960 ///
2961 /// Available since API-level: 20
2962 #[cfg(feature = "api-20")]
2963 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2964 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeClipOptionFromCircleShape(
2965 shape: *mut ArkUI_CircleShapeOption,
2966 ) -> *mut ArkUI_RenderNodeClipOption;
2967 /// Create a clip option from a OvalShape option.
2968 ///
2969 /// # Arguments
2970 ///
2971 /// * `shape` - [`ArkUI_RectShapeOption`] Pointer to the OvalShape option.
2972 ///
2973 /// # Returns
2974 ///
2975 /// * A pointer to the RenderNodeClip option.
2976 ///
2977 /// Available since API-level: 20
2978 #[cfg(feature = "api-20")]
2979 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2980 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeClipOptionFromOvalShape(
2981 shape: *mut ArkUI_RectShapeOption,
2982 ) -> *mut ArkUI_RenderNodeClipOption;
2983 /// Create a clip option from a CommandPath option.
2984 ///
2985 /// # Arguments
2986 ///
2987 /// * `path` - [`ArkUI_CommandPathOption`] Pointer to the CommandPath option.
2988 ///
2989 /// # Returns
2990 ///
2991 /// * A pointer to the RenderNodeClip option.
2992 ///
2993 /// Available since API-level: 20
2994 #[cfg(feature = "api-20")]
2995 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
2996 pub fn OH_ArkUI_RenderNodeUtils_CreateRenderNodeClipOptionFromCommandPath(
2997 path: *mut ArkUI_CommandPathOption,
2998 ) -> *mut ArkUI_RenderNodeClipOption;
2999 /// Dispose the RenderNodeClip option.
3000 ///
3001 /// # Arguments
3002 ///
3003 /// * `option` - Pointer to the RenderNodeClip option.
3004 ///
3005 /// Available since API-level: 20
3006 #[cfg(feature = "api-20")]
3007 #[cfg_attr(docsrs, doc(cfg(feature = "api-20")))]
3008 pub fn OH_ArkUI_RenderNodeUtils_DisposeRenderNodeClipOption(
3009 option: *mut ArkUI_RenderNodeClipOption,
3010 );
3011 /// Get the RenderNode of the target node. The target node should be adopted.
3012 ///
3013 /// # Arguments
3014 ///
3015 /// * `node` - ArkUI_NodeHandle pointer.
3016 ///
3017 /// * `renderNode` - ArkUI_RenderNodeHandle* pointer, the RenderNode of the target node.
3018 ///
3019 /// # Returns
3020 ///
3021 /// * Error code.
3022 /// [`ARKUI_ERROR_CODE_NO_ERROR`] Success.
3023 /// [`ARKUI_ERROR_CODE_PARAM_INVALID`] Function parameter exception.
3024 /// [`ARKUI_ERROR_CODE_CAPI_INIT_ERROR`] if the CAPI init error.
3025 /// [`ARKUI_ERROR_CODE_RENDER_NOT_ADOPTED_NODE`] The node is not adopted.
3026 ///
3027 /// Available since API-level: 22
3028 #[cfg(feature = "api-22")]
3029 #[cfg_attr(docsrs, doc(cfg(feature = "api-22")))]
3030 pub fn OH_ArkUI_RenderNodeUtils_GetRenderNode(
3031 node: ArkUI_NodeHandle,
3032 renderNode: *mut ArkUI_RenderNodeHandle,
3033 ) -> i32;
3034}