pub struct StateStorage<'ui> { /* private fields */ }Expand description
A non-owning reference to an ImGuiStorage belonging to the current context.
Implementations§
Source§impl<'ui> StateStorage<'ui>
impl<'ui> StateStorage<'ui>
Sourcepub unsafe fn from_raw(raw: *mut ImGuiStorage) -> Self
pub unsafe fn from_raw(raw: *mut ImGuiStorage) -> Self
§Safety
raw must be a valid, non-null pointer to an ImGuiStorage.
Sourcepub fn as_raw(self) -> *mut ImGuiStorage
pub fn as_raw(self) -> *mut ImGuiStorage
Returns the raw ImGuiStorage*.
pub fn get_int(&self, key: Id, default: i32) -> i32
pub fn set_int(&mut self, key: Id, value: i32)
pub fn get_bool(&self, key: Id, default: bool) -> bool
pub fn set_bool(&mut self, key: Id, value: bool)
pub fn get_float(&self, key: Id, default: f32) -> f32
pub fn set_float(&mut self, key: Id, value: f32)
Trait Implementations§
Source§impl<'ui> Clone for StateStorage<'ui>
impl<'ui> Clone for StateStorage<'ui>
Source§fn clone(&self) -> StateStorage<'ui>
fn clone(&self) -> StateStorage<'ui>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'ui> Debug for StateStorage<'ui>
impl<'ui> Debug for StateStorage<'ui>
impl<'ui> Copy for StateStorage<'ui>
Auto Trait Implementations§
impl<'ui> Freeze for StateStorage<'ui>
impl<'ui> RefUnwindSafe for StateStorage<'ui>
impl<'ui> !Send for StateStorage<'ui>
impl<'ui> !Sync for StateStorage<'ui>
impl<'ui> Unpin for StateStorage<'ui>
impl<'ui> UnsafeUnpin for StateStorage<'ui>
impl<'ui> !UnwindSafe for StateStorage<'ui>
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