pub struct ScreensView<V = BoxedView> { /* private fields */ }
Expand description

A view that can switch between different screens.

Implementations

Creates a new empty ScreensView.

Creates a new ScreensView with a single screen.

Returns a reference to the currently active screen.

Returns None if there is no active screen.

Returns a mutable reference to the currently active screen.

Returns the id of the currently active screen.

Adds a new screen, and returns its ID.

Convenient method to create a new screen, and set it as active.

Sets the active screen. Panics if no such screen exist.

Draws the background.

This is mostly used internally by cursive. You probably just want View::draw.

Draws the foreground.

This is mostly used internally by cursive. You probably just want View::draw.

Trait Implementations

Returns the “default value” for a type. Read more

Type that this view wraps.

Runs a function on the inner view, returning the result. Read more

Runs a function on the inner view, returning the result. Read more

Wraps the find method.

Wraps the focus_view method.

Attempts to retrieve the inner view.

Wraps the draw method.

Wraps the required_size method.

Wraps the on_event method.

Wraps the layout method.

Wraps the take_focus method.

Wraps the needs_relayout method.

Wraps the important_area method.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.