Struct Window

Source
pub struct Window<'v, S: IntoCStr, P: Pushable = ()> { /* private fields */ }

Implementations§

Source§

impl<'v, S: IntoCStr, P: Pushable> Window<'v, S, P>

Source

pub fn push_for_begin<P2: Pushable>(self, push: P2) -> Window<'v, S, (P, P2)>

Registers this Pushable to be called only for the begin part of this UI element.

This is useful for example to modify the style of a window without changing the stily of its content.

Source

pub fn with<R>(self, f: impl FnOnce() -> R) -> Option<R>

Calls f inside this UI element, but only if it is visible.

Source

pub fn with_always<R>(self, f: impl FnOnce(bool) -> R) -> R

Calls f inside this UI element, passing true if the elements visible, false if it is not.

Source

pub fn open(self, open: &'v mut bool) -> Self

Source

pub fn flags(self, flags: WindowFlags) -> Self

Auto Trait Implementations§

§

impl<'v, S, P> Freeze for Window<'v, S, P>
where <S as IntoCStr>::Temp: Freeze, P: Freeze,

§

impl<'v, S, P> RefUnwindSafe for Window<'v, S, P>

§

impl<'v, S, P> Send for Window<'v, S, P>
where <S as IntoCStr>::Temp: Send, P: Send,

§

impl<'v, S, P> Sync for Window<'v, S, P>
where <S as IntoCStr>::Temp: Sync, P: Sync,

§

impl<'v, S, P> Unpin for Window<'v, S, P>
where <S as IntoCStr>::Temp: Unpin, P: Unpin,

§

impl<'v, S, P = ()> !UnwindSafe for Window<'v, S, P>

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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.