public class BlockTextSelection extends TextSelection implements IBlockTextSelection
IBlockTextSelection.| Constructor and Description |
|---|
BlockTextSelection(IDocument document,
int startLine,
int startColumn,
int endLine,
int endColumn,
int tabWidth)
Creates a column selection for the given lines and columns.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
int |
getEndColumn()
Returns the exclusive column on the end line at which the
selection ends.
|
int |
getEndLine()
Returns the number of the line containing the last character of the selected text.
|
IRegion[] |
getRegions()
Returns a non-empty array containing the selected text range for each line covered by the
selection.
|
int |
getStartColumn()
Returns the column on the start line at which the
selection starts.
|
int |
getStartLine()
Returns number of the line containing the offset of the selected text.
|
String |
getText()
Returns the selected text.
|
int |
hashCode() |
emptySelection, getDocument, getLength, getOffset, isEmptyclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitgetLength, getOffsetisEmptypublic BlockTextSelection(IDocument document, int startLine, int startColumn, int endLine, int endColumn, int tabWidth)
document - the document that this selection refers tostartLine - the start linestartColumn - the possibly virtual start column, measured in characters from the start
of startLineendLine - the inclusive end lineendColumn - the exclusive and possibly virtual end column, measured in characters from
the start of endLinetabWidth - the tabulator width used to compute the visual offsets from character offsetspublic int getStartLine()
ITextSelectiongetStartLine in interface ITextSelectiongetStartLine in class TextSelectionpublic int getStartColumn()
IBlockTextSelectiongetStartColumn in interface IBlockTextSelectionpublic int getEndLine()
ITextSelectiongetEndLine in interface ITextSelectiongetEndLine in class TextSelectionpublic int getEndColumn()
IBlockTextSelectiongetEndColumn in interface IBlockTextSelectionpublic String getText()
ITextSelectiongetText in interface IBlockTextSelectiongetText in interface ITextSelectiongetText in class TextSelectionnull if there is no valid text informationITextSelection.getText()public int hashCode()
hashCode in class TextSelectionpublic boolean equals(Object obj)
equals in class TextSelectionpublic IRegion[] getRegions()
IBlockTextSelectiongetRegions in interface IBlockTextSelection
Copyright (c) 2000, 2014 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.