# VisualTreeNode

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-diagnostics/diagnostics/view_models/struct-visualtreenode/

**struct** · [`ferroui-diagnostics`](/docs/0.5.0/api/ferroui-diagnostics/) · v0.5.0

```rust
struct VisualTreeNode
```

A node of the visual tree.

The original derives the node class from [`TreeNode`](/docs/0.5.0/api/ferroui-diagnostics/diagnostics/view_models/struct-treenode/); here a visual
tree node is a [`TreeNode`](/docs/0.5.0/api/ferroui-diagnostics/diagnostics/view_models/struct-treenode/) of the kind `TreeNodeKind::Visual`, made by
the functions of this type.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/visual_tree_node.rs#L21)

## Members

- [`new`](#function-new)
- [`create`](#function-create)

<a id="function-new"></a>

### new

```rust
fn new(ferro_object: Ref<FerroObject>, parent: Option<&Rc<TreeNode>>, custom_name: Option<String>) -> Rc<TreeNode>
```

`VisualTreeNode(FerroObject ferroObject, TreeNode? parent, string? customName = null)`:
the node of an object of the visual tree, whose children are the
visual children of the visual and the root of the popup it hosts, or
the top levels of an application.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/visual_tree_node.rs#L28)

<a id="function-create"></a>

### create

```rust
fn create(control: impl Into<Nullable<FerroObject>>) -> Vec<Rc<TreeNode>>
```

`Create(object control)`: the root node of the visual tree of
`control`, or no node when it is not an object of the framework.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/visual_tree_node.rs#L47)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
