ITextEditor editor= getTextEditor();
if (editor == null)
return;
IMarkRegionTarget target= (IMarkRegionTarget) editor.getAdapter(IMarkRegionTarget.class);
if (target == null)
return;
switch (fType) {
case SET_MARK:
target.setMarkAtCursor(true);
break;
case CLEAR_MARK:
target.setMarkAtCursor(false);
break;
case SWAP_MARK:
target.swapMarkAndCursor();
break;
}
}