pub struct HandleMetrics {
pub diameter: f32,
pub hit: f32,
}Expand description
The two dimensions a handle is built from. Taken from the active
TextSelectionStyle so the controller
that hit-tests a handle and the widget that paints it cannot disagree.
Fields§
§diameter: f32Diameter of the painted disc.
hit: f32Extent of the square hit rectangle.
Implementations§
Source§impl HandleMetrics
impl HandleMetrics
Sourcepub fn for_tokens(tokens: &InputTokens) -> Self
pub fn for_tokens(tokens: &InputTokens) -> Self
The shipped dimensions projected onto a density ladder.
Trait Implementations§
Source§impl Clone for HandleMetrics
impl Clone for HandleMetrics
Source§fn clone(&self) -> HandleMetrics
fn clone(&self) -> HandleMetrics
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for HandleMetrics
Source§impl Debug for HandleMetrics
impl Debug for HandleMetrics
Source§impl Default for HandleMetrics
impl Default for HandleMetrics
Source§impl From<&TextSelectionHandleRecipe> for HandleMetrics
impl From<&TextSelectionHandleRecipe> for HandleMetrics
Source§fn from(recipe: &TextSelectionHandleRecipe) -> Self
fn from(recipe: &TextSelectionHandleRecipe) -> Self
Converts to this type from the input type.
Source§impl PartialEq for HandleMetrics
impl PartialEq for HandleMetrics
impl StructuralPartialEq for HandleMetrics
Auto Trait Implementations§
impl Freeze for HandleMetrics
impl RefUnwindSafe for HandleMetrics
impl Send for HandleMetrics
impl Sync for HandleMetrics
impl Unpin for HandleMetrics
impl UnsafeUnpin for HandleMetrics
impl UnwindSafe for HandleMetrics
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