[]Trait yew_stdweb::events::IPointerEvent

pub trait IPointerEvent: IMouseEvent {
    fn pointer_id(&self) -> i32 { ... }
fn width(&self) -> f64 { ... }
fn height(&self) -> f64 { ... }
fn pressure(&self) -> f64 { ... }
fn tangential_pressure(&self) -> f64 { ... }
fn tilt_x(&self) -> i32 { ... }
fn tilt_y(&self) -> i32 { ... }
fn twist(&self) -> i32 { ... }
fn pointer_type(&self) -> String { ... }
fn is_primary(&self) -> bool { ... } }

The IPointerEvent interface represents the state of a DOM event produced by a pointer such as the geometry of the contact point, the device type that generated the event, the amount of pressure that was applied on the contact surface, etc.

(JavaScript docs)

Provided methods

fn pointer_id(&self) -> i32

Returns a unique identifier for the pointer causing the event.

(JavaScript docs)

fn width(&self) -> f64

Returns the width, in CSS pixels, of the contact geometry of the pointer.

(JavaScript docs)

fn height(&self) -> f64

Returns the height, in CSS pixels, of the contact geometry of the pointer.

(JavaScript docs)

fn pressure(&self) -> f64

Returns the normalized pressure of the pointer in the range [0, 1]

(JavaScript docs)

fn tangential_pressure(&self) -> f64

Returns the normalized tangential pressure of the pointer in the range [-1, 1], where 0 is the hardware's neutral position

(JavaScript docs)

fn tilt_x(&self) -> i32

Returns the angle, in the range of [-90, 90] degrees, between the Y-Z plane and the plane containing the transducer (e.g. pen stylus) and the Y axis.

(JavaScript docs)

fn tilt_y(&self) -> i32

Returns the angle, in the range of [-90, 90] degrees, between the X-Z plane and the plane containing the transducer (e.g. pen stylus) and the X axis.

(JavaScript docs)

fn twist(&self) -> i32

Returns the clockwise rotation, in the range of [0, 359] degrees, of the transducer (e.g. pen stylus) around it's own major axis

(JavaScript docs)

fn pointer_type(&self) -> String

Indicates the device type that caused the event.

(JavaScript docs)

fn is_primary(&self) -> bool

Indicates if the pointer represents the primary pointer of this pointer type

(JavaScript docs)

Loading content...

Implementors

impl IPointerEvent for GotPointerCaptureEvent

impl IPointerEvent for LostPointerCaptureEvent

impl IPointerEvent for PointerCancelEvent

impl IPointerEvent for PointerDownEvent

impl IPointerEvent for PointerEnterEvent

impl IPointerEvent for PointerLeaveEvent

impl IPointerEvent for PointerMoveEvent

impl IPointerEvent for PointerOutEvent

impl IPointerEvent for PointerOverEvent

impl IPointerEvent for PointerUpEvent

Loading content...