public class MarkRegionTarget extends Object implements IMarkRegionTarget
IMarkRegionTarget using ITextViewer
and IStatusLineManager.| Constructor and Description |
|---|
MarkRegionTarget(ITextViewer viewer,
IStatusLineManager manager)
Creates a MarkRegionTaret.
|
| Modifier and Type | Method and Description |
|---|---|
protected static boolean |
isVisible(ITextViewer viewer,
int offset)
Tells whether the given offset is visible in the given text viewer.
|
void |
setMarkAtCursor(boolean set)
Sets or clears a mark at the current cursor position.
|
void |
swapMarkAndCursor()
Swaps the mark and cursor position if the mark is in the visible region.
|
public MarkRegionTarget(ITextViewer viewer, IStatusLineManager manager)
viewer - the text viewermanager - the status line managerpublic void setMarkAtCursor(boolean set)
IMarkRegionTargetsetMarkAtCursor in interface IMarkRegionTargetset - sets the mark if true, clears otherwise.public void swapMarkAndCursor()
IMarkRegionTargetswapMarkAndCursor in interface IMarkRegionTargetprotected static final boolean isVisible(ITextViewer viewer, int offset)
viewer - the text vieweroffset - the offset to checktrue if the given offset is visible in the given text viewerGuidelines for using Eclipse APIs. Copyright (c) IBM Corp. and others 2000, 2006. All rights reserved.