SpreadJS Documentation
getHitInfo Method
x-coordinate of pointer's current location relative to the canvas.
y-coordinate of pointer's current location relative to the canvas.
The current cell's actual style.
The current cell's layout information.
The context associated with the cell type. See the Remarks for more information.
Gets the cell type's hit information.
Syntax
var instance = new GcSpread.Sheets.BaseCellType();
var value; // Type: object
value = instance.getHitInfo(x, y, cellStyle, cellRect, context);
function getHitInfo( 
   x : number,
   y : number,
   cellStyle : Style,
   cellRect : Rect,
   context : object
) : object;

Parameters

x
x-coordinate of pointer's current location relative to the canvas.
y
y-coordinate of pointer's current location relative to the canvas.
cellStyle
The current cell's actual style.
cellRect
The current cell's layout information.
context
The context associated with the cell type. See the Remarks for more information.

Return Value

Returns an object that contains the x, y, row, col, cellRect, and sheetArea parameters, and a value to indicate isReservedLocation. isReservedLocation is true if the hit test is in a special area that the cell type needs to handle; otherwise, false.
Remarks

The context parameter can include the following items:

Item Type Description
context.sheet GcSpread.Sheets.Sheet instance Indicates the current sheet.
context.row number The row index.
context.col number The column index.
context.sheetArea GcSpread.Sheets.SheetArea The current sheet area.

 

See Also

Reference

BaseCellType type

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.