Struct egui::style::Interaction
source · pub struct Interaction {
pub interact_radius: f32,
pub resize_grab_radius_side: f32,
pub resize_grab_radius_corner: f32,
pub show_tooltips_only_when_still: bool,
pub tooltip_delay: f32,
pub tooltip_grace_time: f32,
pub selectable_labels: bool,
pub multi_widget_text_select: bool,
}
Expand description
How and when interaction happens.
Fields§
§interact_radius: f32
How close a widget must be to the mouse to have a chance to register as a click or drag.
If this is larger than zero, it gets easier to hit widgets, which is important for e.g. touch screens.
resize_grab_radius_side: f32
Radius of the interactive area of the side of a window during drag-to-resize.
resize_grab_radius_corner: f32
Radius of the interactive area of the corner of a window during drag-to-resize.
show_tooltips_only_when_still: bool
If false
, tooltips will show up anytime you hover anything, even if mouse is still moving
tooltip_delay: f32
Delay in seconds before showing tooltips after the mouse stops moving
tooltip_grace_time: f32
If you have waited for a tooltip and then hover some other widget within
this many seconds, then show the new tooltip right away,
skipping Self::tooltip_delay
.
This lets the user quickly move over some dead space to hover the next thing.
selectable_labels: bool
Can you select the text on a crate::Label
by default?
multi_widget_text_select: bool
Can the user select text that span multiple labels?
The default is true
, but text selection can be slightly glitchy,
so you may want to disable it.
Implementations§
Trait Implementations§
source§impl Clone for Interaction
impl Clone for Interaction
source§fn clone(&self) -> Interaction
fn clone(&self) -> Interaction
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for Interaction
impl Debug for Interaction
source§impl Default for Interaction
impl Default for Interaction
source§impl PartialEq for Interaction
impl PartialEq for Interaction
impl StructuralPartialEq for Interaction
Auto Trait Implementations§
impl Freeze for Interaction
impl RefUnwindSafe for Interaction
impl Send for Interaction
impl Sync for Interaction
impl Unpin for Interaction
impl UnwindSafe for Interaction
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)