Search
Grid.getHeaderFromPoint Method
See Also
 






Gets the Header that is located at the specified point.

Namespace: MindFusion.Diagramming.Lanes
File: Grid.js

 Syntax

JavaScript  Copy Code

function getHeaderFromPoint (point, headerBounds, scrollPosition)

 Parameters

point

A Point instance specifying a point within the grid.

headerBounds

An object that receives the coordinates of the found header in its headerBounds field.

scrollPosition

Point. When the headers are hooked this parameter should provide information about the current scroll position in the view.

 Return Value

The found Header object, or null if there is no header located at the specified point.

 Example

The following example illustrates how to find the header at a specific position as well as its bounding rectangle:

JavaScript  Copy Code

var boundsResult = {};
var header = grid.getHeaderFromPoint(new Point(20, 10), boundsResult);
if (header)
{
    var headerBounds = boundsResult.headerBounds;
}

 See Also