DataGridXL - API

Renderer Events

Description

The Renderer takes care of rendering the Sheet inside your DataGridXL instance.

Usage

Your DataGridXL instance contains a property renderer.

javascript
// create DataGridXL instance
const grid = new DataGridXL(...);
// listening to renderer events
grid.renderer.events.on('scroll', ...)
NOTE: You don't need to create a Renderer instance yourself — it is provided by the grid automatically.

Events

contextmenuRendererPointerEvent

Fires when native `contextmenu` event is triggered

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
dblclickcellRendererPointerEvent

Fires when cell has been double-clicked

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
dblclickcolheaderedgeRendererPointerEvent

Fires when right edge of column header has been double-clicked

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
dblclickpointerareaRendererPointerEvent

Fires when any pointer area has been double-clicked

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcellRendererPointerEvent

Fires when a cell has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcellpickerbuttonRendererPointerEvent

Fires when a cell picker button has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcolheaderRendererPointerEvent

Fires when a column header has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcolheaderedgeRendererPointerEvent

Fires when a column header right edge has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcolheaderlabelRendererPointerEvent

Fires when a column header label has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitcolheadersortbuttonRendererPointerEvent

Fires when a column header sort button has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitemptycanvasRendererPointerEvent

Fires when part of the empty canvas has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitfillhandleRendererPointerEvent

Fires when the fill handle has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitheadercornerRendererPointerEvent

Fires when the top-left header corner has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hithiddencolgroupindicatorRendererPointerEvent

Fires when the "hidden column group" indicator has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hithiddenrowgroupindicatorRendererPointerEvent

Fires when the "hidden row group" indicator has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
beforehitpointerareaRendererPointerEvent

Fires before any pointer area inside renderer has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitpointerareaRendererPointerEvent

Fires when any pointer area inside renderer has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitrowheaderRendererPointerEvent

Fires when a row header has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitsectiondividerxRendererPointerEvent

Fires when a section divider X (freeze line) has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
hitsectiondivideryRendererPointerEvent

Fires when a section divider Y (freeze line) has been hit

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
mouseentercellRendererPointerEvent

Fires when the mouse enters a cell

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
mouseenterpointerareaRendererPointerEvent

Fires when the mouse enters a pointer area

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
mouseleavePassthroughEvent

Fires when the mouse leaves the renderer

Payload

type
string
Event name (e.g. 'copy', 'paste')
target
object
Instance that fired the event
nativeEvent
Event
The original DOM event
mouseleavecellRendererPointerEvent

Fires when the mouse leaves a cell

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
mouseleavepointerareaRendererPointerEvent

Fires when the mouse leavers a pointer area

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
nativeEvent
MouseEvent
The original DOM event
payload
RendererPointerEventPayload
Structured event data
scrollPassthroughEvent

Fires when renderer scrolls

Payload

type
string
Event name (e.g. 'copy', 'paste')
target
object
Instance that fired the event
nativeEvent
Event
The original DOM event
scrollstopRendererViewportEvent

Fires when renderer stops scrolling

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
payload
RendererViewportEventPayload
Structured event data
viewportpositionchangeRendererViewportEvent

Fires when viewport position has changed

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
Renderer
Instance that fired the event
payload
RendererViewportEventPayload
Structured event data