pub struct PanePressureSnapProfile {
pub strength_bps: u16,
pub hysteresis_bps: u16,
}Expand description
Dynamic snap aggressiveness derived from drag pressure cues.
Fields§
§strength_bps: u16Relative snap strength (0..=10_000). Higher means stronger canonical snap.
hysteresis_bps: u16Effective hysteresis window used for sticky docking/snap.
Implementations§
Source§impl PanePressureSnapProfile
impl PanePressureSnapProfile
Sourcepub fn from_motion(motion: PaneMotionVector) -> Self
pub fn from_motion(motion: PaneMotionVector) -> Self
Compute pressure profile from gesture speed and direction noise.
Slow/stable drags reduce snap force for precision; fast drags with consistent direction increase snap force for canonical layouts.
pub fn apply_to_tuning(self, base: PaneSnapTuning) -> PaneSnapTuning
Trait Implementations§
Source§impl Clone for PanePressureSnapProfile
impl Clone for PanePressureSnapProfile
Source§fn clone(&self) -> PanePressureSnapProfile
fn clone(&self) -> PanePressureSnapProfile
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 Debug for PanePressureSnapProfile
impl Debug for PanePressureSnapProfile
Source§impl<'de> Deserialize<'de> for PanePressureSnapProfile
impl<'de> Deserialize<'de> for PanePressureSnapProfile
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PanePressureSnapProfile
impl PartialEq for PanePressureSnapProfile
Source§impl Serialize for PanePressureSnapProfile
impl Serialize for PanePressureSnapProfile
impl Copy for PanePressureSnapProfile
impl Eq for PanePressureSnapProfile
impl StructuralPartialEq for PanePressureSnapProfile
Auto Trait Implementations§
impl Freeze for PanePressureSnapProfile
impl RefUnwindSafe for PanePressureSnapProfile
impl Send for PanePressureSnapProfile
impl Sync for PanePressureSnapProfile
impl Unpin for PanePressureSnapProfile
impl UnsafeUnpin for PanePressureSnapProfile
impl UnwindSafe for PanePressureSnapProfile
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