pub struct FormState<W>{
pub layout: Rc<RefCell<GenericLayout<W>>>,
pub non_exhaustive: NonExhaustive,
}Expand description
Widget state.
Fields§
§layout: Rc<RefCell<GenericLayout<W>>>Page layout read+write renewed with each render.
non_exhaustive: NonExhaustiveOnly construct with ..Default::default().
Implementations§
Source§impl<W> FormState<W>
impl<W> FormState<W>
pub fn new() -> Self
Sourcepub fn valid_layout(&self, size: Size) -> bool
pub fn valid_layout(&self, size: Size) -> bool
Layout needs to change?
Sourcepub fn set_layout(&mut self, layout: GenericLayout<W>)
pub fn set_layout(&mut self, layout: GenericLayout<W>)
Set the layout.
Sourcepub fn layout(&self) -> Ref<'_, GenericLayout<W>>
pub fn layout(&self) -> Ref<'_, GenericLayout<W>>
Layout.
Trait Implementations§
Auto Trait Implementations§
impl<W> Freeze for FormState<W>
impl<W> !RefUnwindSafe for FormState<W>
impl<W> !Send for FormState<W>
impl<W> !Sync for FormState<W>
impl<W> Unpin for FormState<W>
impl<W> !UnwindSafe for FormState<W>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more