The goog.editor.range.Point Class

goog.editor.range.Point(node, offset)

One endpoint of a range, represented as a Node and and offset.

node {Node}
The node containing the point.
offset {number}
The offset of the point into the node.

.createDeepestPoint(node, offset, opt_trendLeft)

Construct the deepest possible point in the DOM that's equivalent to the given point, expressed as a node and an offset.

node {Node}
The node containing the point.
offset {number}
The offset of the point from the node.
opt_trendLeft {boolean=}
Notice that a (node, offset) pair may be equivalent to more than one descendent (node, offset) pair in the DOM. By default, we trend rightward. If this parameter is true, then we trend leftward. The tendency to fall rightward by default is for consistency with other range APIs (like placeCursorNextTo).
returns {goog.editor.range.Point}
A new point.

.getParentPoint()

Gets the point of this point's node in the DOM.

returns {goog.editor.range.Point}
The node's point.

.getPointAtEndOfNode(node)

Construct a point at the very end of the given node.

node {Node}
The node to create a point for.
returns {goog.editor.range.Point}
A new point.

.node {Node}

The node containing the point.

.offset {number}

The offset of the point into the node.