# PreviewStageView

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-designer/struct-previewstageview/

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

```rust
struct PreviewStageView
```

The view never owns document or runtime state. A host supplies stable native stage
controls and immutable descriptions, then handles explicit guarded commands.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L135)

## Members

- [`new`](#function-new)
- [`control`](#function-control)
- [`on_action`](#function-on_action)
- [`show_error`](#function-show_error)
- [`set_query`](#function-set_query)
- [`set_all_views`](#function-set_all_views)
- [`visible_stage_ids`](#function-visible_stage_ids)
- [`cancel_interaction`](#function-cancel_interaction)
- [`update`](#function-update)

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

### new

```rust
fn new(palette: &Control) -> Rc<Self>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L153)

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

### control

```rust
fn control(self: &Self) -> Ref<Control>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L321)

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

### on_action

```rust
fn on_action(self: &Self, callback: impl Fn(PreviewStageAction, Ref<Control>) -> Result<(), String> + 'static)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L324)

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

### show_error

```rust
fn show_error(self: &Self, message: &str)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L330)

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

### set_query

```rust
fn set_query(self: &Self, query: &str)
```

Filtering changes presentation only; accepted roots stay attached and retain
their native input, scroll state and card zoom while temporarily hidden.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L337)

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

### set_all_views

```rust
fn set_all_views(self: &Self, all: bool)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L341)

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

### visible_stage_ids

```rust
fn visible_stage_ids(self: &Self) -> Vec<PreviewStageId>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L345)

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

### cancel_interaction

```rust
fn cancel_interaction(self: &Self)
```

Cancel detached corner-grip drafts before hiding or moving the board.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L405)

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

### update

```rust
fn update(self: &Rc<Self>, stages: &[PreviewStageInfo], hosts: &BTreeMap<PreviewStageId, Ref<Control>>, active: Option<PreviewStageId>, current_uri: &str, _total: usize)
```

Reconcile cards by stable identity and graph epoch. Unchanged live roots stay
attached, preserving input state, focus and scroll while another card updates.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Designer/preview_stage_view.rs#L441)

## 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`
- `Same`
- `Drop`

## Availability

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