Skip to main content

DocumentTab

Struct DocumentTab 

Source
pub struct DocumentTab<T: 'static> { /* private fields */ }
Expand description

A tab of DocumentTabs: its title, and the value choosing it gives the tabs’ selection.

In view!, its text is its title: <DocumentTab value=1>"notes.txt"</DocumentTab>.

Implementations§

Source§

impl<T: 'static> DocumentTab<T>

Source

pub fn new(title: impl IntoValue<String>, value: T) -> DocumentTab<T>

Source

pub fn title(self, title: impl IntoValue<String>) -> DocumentTab<T>

Source

pub fn value<U: 'static>(self, value: U) -> DocumentTab<U>

The value choosing it gives the tabs’ selection.

Trait Implementations§

Source§

impl<T: 'static> DocumentTabsChildren<T> for DocumentTab<T>

Source§

fn add_to(self, tabs: &mut Vec<DocumentTab<T>>)

Auto Trait Implementations§

§

impl<T> !RefUnwindSafe for DocumentTab<T>

§

impl<T> !Send for DocumentTab<T>

§

impl<T> !Sync for DocumentTab<T>

§

impl<T> !UnwindSafe for DocumentTab<T>

§

impl<T> Freeze for DocumentTab<T>
where T: Freeze,

§

impl<T> Unpin for DocumentTab<T>
where T: Unpin,

§

impl<T> UnsafeUnpin for DocumentTab<T>
where T: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.