getTextPositionBelow method
Returns the TextPosition below the given offset into the text.
If the offset is already on the last line, the given offset will be returned.
Implementation
@override
TextPosition getTextPositionBelow(TextPosition position) {
// The caret offset gives a location in the upper left hand corner of
// the caret so the middle of the line above is a half line above that
// point and the line below is 1.5 lines below that point.
final double preferredLineWidth = _textPainter.preferredLineWidth;
final double horizontalOffset = 1.5 * preferredLineWidth;
return _getTextPositionHorizontal(position, horizontalOffset);
}