StyledText.getOffsetAtLine

Returns the character offset of the first character of the given line.

@param lineIndex index of the line, 0 based relative to the first line in the content. 0 <= lineIndex < getLineCount(), except lineIndex may always be 0 @return offset offset of the first character of the line, relative to the beginning of the document. The first character of the document is at offset 0. When there are not any lines, getOffsetAtLine(0) is a valid call that answers 0. @exception SWTException <ul> <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> </ul> @exception IllegalArgumentException <ul> <li>ERROR_INVALID_RANGE when the line index is outside the valid range (< 0 or >= getLineCount())</li> </ul> @since 2.0

class StyledText
int
getOffsetAtLine
()

Meta