Skip to content
sigma.js sigma.js
v4.0.6 Docs Examples GitHub 12.2K

TouchCaptor

Defined in: packages/sigma/src/core/captors/touch.ts:45

Touch captor class.

N extends Attributes = Attributes

E extends Attributes = Attributes

G extends Attributes = Attributes

new TouchCaptor<N, E, G>(container, renderer): TouchCaptor<N, E, G>

Defined in: packages/sigma/src/core/captors/touch.ts:68

HTMLElement

Sigma<N, E, G>

TouchCaptor<N, E, G>

Captor<TouchCaptorEvents, N, E, G>.constructor

container: HTMLElement

Defined in: packages/sigma/src/core/captors/captor.ts:141

Captor.container


enabled: boolean = true

Defined in: packages/sigma/src/core/captors/touch.ts:50


hasMoved: boolean = false

Defined in: packages/sigma/src/core/captors/touch.ts:52


isMoving: boolean = false

Defined in: packages/sigma/src/core/captors/touch.ts:51


isPanningStage: boolean = false

Defined in: packages/sigma/src/core/captors/touch.ts:53


isZoomingStage: boolean = false

Defined in: packages/sigma/src/core/captors/touch.ts:54


lastTap: { position: Coordinates; time: number; } | null = null

Defined in: packages/sigma/src/core/captors/touch.ts:64


lastTouches: Touch[] = []

Defined in: packages/sigma/src/core/captors/touch.ts:63


optional lastTouchesPositions?: Coordinates[]

Defined in: packages/sigma/src/core/captors/touch.ts:62


optional movingTimeout?: number

Defined in: packages/sigma/src/core/captors/touch.ts:57


rawEmitter: EventEmitter

Defined in: packages/sigma/src/types.ts:253

Captor.rawEmitter


renderer: Sigma<N, E, G>

Defined in: packages/sigma/src/core/captors/captor.ts:142

Captor.renderer


settings: TouchSettings = DEFAULT_TOUCH_SETTINGS

Defined in: packages/sigma/src/core/captors/touch.ts:66


optional startCameraState?: CameraState

Defined in: packages/sigma/src/core/captors/touch.ts:55


optional startTouchesAngle?: number

Defined in: packages/sigma/src/core/captors/touch.ts:59


optional startTouchesDistance?: number

Defined in: packages/sigma/src/core/captors/touch.ts:60


startTouchesPositions: Coordinates[] = []

Defined in: packages/sigma/src/core/captors/touch.ts:61


touchMode: number = 0

Defined in: packages/sigma/src/core/captors/touch.ts:56

addListener<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:259

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.addListener


emit<Event>(type, …args): boolean

Defined in: packages/sigma/src/types.ts:258

Event extends TouchCaptorEventType

Event

…Parameters<TouchCaptorEvents[Event]>

boolean

Captor.emit


eventNames<Event>(): Event[]

Defined in: packages/sigma/src/types.ts:255

Event extends TouchCaptorEventType

Event[]

Captor.eventNames


getDimensions(): Dimensions

Defined in: packages/sigma/src/core/captors/touch.ts:92

Dimensions


getMaxListeners(): number

Defined in: packages/sigma/src/types.ts:257

number

Captor.getMaxListeners


handleLeave(e): void

Defined in: packages/sigma/src/core/captors/touch.ts:149

TouchEvent

void


handleMove(e): void

Defined in: packages/sigma/src/core/captors/touch.ts:233

TouchEvent

void


handleStart(e): void

Defined in: packages/sigma/src/core/captors/touch.ts:124

TouchEvent

void


kill(): void

Defined in: packages/sigma/src/core/captors/touch.ts:83

void

Captor.kill


listenerCount<Event>(type): number

Defined in: packages/sigma/src/types.ts:268

Event extends TouchCaptorEventType

Event

number

Captor.listenerCount


listeners<Event>(type): TouchCaptorEvents[Event][]

Defined in: packages/sigma/src/types.ts:267

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event][]

Captor.listeners


off<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:265

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.off


on<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:260

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.on


once<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:261

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.once


prependListener<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:262

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.prependListener


prependOnceListener<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:263

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.prependOnceListener


rawListeners<Event>(type): TouchCaptorEvents[Event][]

Defined in: packages/sigma/src/types.ts:269

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event][]

Captor.rawListeners


removeAllListeners<Event>(type?): this

Defined in: packages/sigma/src/types.ts:266

Event extends TouchCaptorEventType

Event

this

Captor.removeAllListeners


removeListener<Event>(type, listener): this

Defined in: packages/sigma/src/types.ts:264

Event extends TouchCaptorEventType

Event

TouchCaptorEvents[Event]

this

Captor.removeListener


setMaxListeners(n): this

Defined in: packages/sigma/src/types.ts:256

number

this

Captor.setMaxListeners


setSettings(settings): void

Defined in: packages/sigma/src/core/captors/touch.ts:357

TouchSettings

void