Struct egui::widgets::ImageButton
source · [−]pub struct ImageButton { /* private fields */ }
Expand description
A clickable image within a frame.
Implementations
sourceimpl ImageButton
impl ImageButton
pub fn new(texture_id: impl Into<TextureId>, size: impl Into<Vec2>) -> Self
sourcepub fn uv(self, uv: impl Into<Rect>) -> Self
pub fn uv(self, uv: impl Into<Rect>) -> Self
Select UV range. Default is (0,0) in top-left, (1,1) bottom right.
Trait Implementations
sourceimpl Clone for ImageButton
impl Clone for ImageButton
sourcefn clone(&self) -> ImageButton
fn clone(&self) -> ImageButton
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for ImageButton
impl Debug for ImageButton
Auto Trait Implementations
impl RefUnwindSafe for ImageButton
impl Send for ImageButton
impl Sync for ImageButton
impl Unpin for ImageButton
impl UnwindSafe for ImageButton
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more