public abstract class ExtendWordSelectionHandlerBase extends java.lang.Object implements ExtendWordSelectionHandler
EP_NAME
Constructor and Description |
---|
ExtendWordSelectionHandlerBase() |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
canSelect(PsiElement e) |
static java.util.List<TextRange> |
expandToWholeLine(java.lang.CharSequence text,
TextRange range) |
static java.util.List<TextRange> |
expandToWholeLine(java.lang.CharSequence text,
TextRange range,
boolean isSymmetric) |
static java.util.List<TextRange> |
expandToWholeLinesWithBlanks(java.lang.CharSequence text,
TextRange range) |
int |
getMinimalTextRangeLength(PsiElement element,
java.lang.CharSequence text,
int cursorOffset)
Returns minimal selection length for given element.
|
java.util.List<TextRange> |
select(PsiElement e,
java.lang.CharSequence editorText,
int cursorOffset,
Editor editor) |
public abstract boolean canSelect(PsiElement e)
canSelect
in interface ExtendWordSelectionHandler
public java.util.List<TextRange> select(PsiElement e, java.lang.CharSequence editorText, int cursorOffset, Editor editor)
select
in interface ExtendWordSelectionHandler
public int getMinimalTextRangeLength(PsiElement element, java.lang.CharSequence text, int cursorOffset)
element
- element at carettext
- text in editorcursorOffset
- current caret offset in editorpublic static java.util.List<TextRange> expandToWholeLine(java.lang.CharSequence text, TextRange range, boolean isSymmetric)
public static java.util.List<TextRange> expandToWholeLinesWithBlanks(java.lang.CharSequence text, TextRange range)