FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    PointerPointProperties

    struct · ferroui-base · v0.5.0

    struct PointerPointProperties
    

    Provides extended properties for a pointer point.

    View source

    Members

    contact_rect

    contact_rect: crate::Rect
    

    The bounding rectangle of the contact area (typically from touch input).

    Source

    is_left_button_pressed

    is_left_button_pressed: bool
    

    Whether the pointer input was triggered by the primary action mode of an input device.

    Source

    is_middle_button_pressed

    is_middle_button_pressed: bool
    

    Whether the pointer input was triggered by the tertiary action mode of an input device.

    Source

    is_right_button_pressed

    is_right_button_pressed: bool
    

    Whether the pointer input was triggered by the secondary action mode (if supported) of an input device.

    Source

    is_x_button_1_pressed

    is_x_button_1_pressed: bool
    

    Whether the pointer input was triggered by the first extended mouse button (XButton1).

    Source

    is_x_button_2_pressed

    is_x_button_2_pressed: bool
    

    Whether the pointer input was triggered by the second extended mouse button (XButton2).

    Source

    is_barrel_button_pressed

    is_barrel_button_pressed: bool
    

    Whether the barrel button of the pen/stylus device is pressed.

    Source

    is_eraser

    is_eraser: bool
    

    Whether the input is from a pen eraser.

    Source

    is_inverted

    is_inverted: bool
    

    Whether the digitizer input is from an inverted pen.

    Source

    twist

    twist: f32
    

    The clockwise rotation in degrees of a pen device around its own major axis (such as when the user spins the pen in their fingers). A value between 0.0 and 359.0 in degrees of rotation; the default value is 0.0.

    Source

    pressure

    pressure: f32
    

    A value that indicates the force that the pointer device (typically a pen/stylus) exerts on the surface of the digitizer. A value from 0 to 1.0; the default value is 0.5.

    Source

    x_tilt

    x_tilt: f32
    

    The plane angle between the Y-Z plane and the plane that contains the Y axis and the axis of the input device (typically a pen/stylus). The value is 0.0 when the finger or pen is perpendicular to the digitizer surface, between 0.0 and 90.0 when tilted to the right of perpendicular, and between 0.0 and -90.0 when tilted to the left of perpendicular. The default value is 0.0.

    Source

    y_tilt

    y_tilt: f32
    

    The plane angle between the X-Z plane and the plane that contains the X axis and the axis of the input device (typically a pen/stylus). The value is 0.0 when the finger or pen is perpendicular to the digitizer surface, between 0.0 and 90.0 when tilted towards the user, and between 0.0 and -90.0 when tilted away from the user. The default value is 0.0.

    Source

    pointer_update_kind

    pointer_update_kind: PointerUpdateKind
    

    The kind of pointer state change.

    Source

    NONE

    const NONE: PointerPointProperties
    

    The default properties: nothing pressed.

    Source

    new

    fn new(modifiers: RawInputModifiers, kind: PointerUpdateKind) -> Self
    

    Creates properties from raw input modifiers and the kind of state change.

    Source

    with_pen_state

    fn with_pen_state(modifiers: RawInputModifiers, kind: PointerUpdateKind, twist: f32, pressure: f32, x_tilt: f32, y_tilt: f32) -> Self
    

    Creates properties with pen state.

    Source

    with_pen_state_and_contact_rect

    fn with_pen_state_and_contact_rect(modifiers: RawInputModifiers, kind: PointerUpdateKind, twist: f32, pressure: f32, x_tilt: f32, y_tilt: f32, contact_rect: Rect) -> Self
    

    Creates properties with pen state and a contact rectangle.

    Source

    from_raw_point

    fn from_raw_point(modifiers: RawInputModifiers, kind: PointerUpdateKind, raw_point: RawPointerPoint) -> Self
    

    Creates properties from a raw pointer point.

    Source

    based_on

    fn based_on(based_on: PointerPointProperties, raw_point: RawPointerPoint) -> Self
    

    Creates the properties of an intermediate point: the button state of based_on with the pen state of a raw pointer point.

    Source

    Trait implementations

    • Send
    • Sync
    • Freeze
    • UnsafeUnpin
    • Unpin
    • UnwindSafe
    • RefUnwindSafe
    • PropertyValue
    • AnyValue
    • ClassDefaults
    • Borrow<T>
    • BorrowMut<T>
    • CloneToUninit
    • Into<U>
    • From<T>
    • TryInto<U>
    • TryFrom<U>
    • Any
    • ToOwned
    • ErasedDestructor
    • IntoEither
    • Clone
    • Copy
    • Debug
    • StructuralPartialEq
    • PartialEq
    • Default

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.