final Event event= new Event(); event.x= text.getSelection().x; event.y= text.getSelection().y; text.notifyListeners(SWT.Selection, event);
		protected void setCaretPosition(final int position) {			final ISourceViewer viewer= getSourceViewer();						final StyledText text= viewer.getTextWidget();			if (text != null && !text.isDisposed()) {								final Point selection= text.getSelection();				final int caret= text.getCaretOffset();				final int offset= modelOffset2WidgetOffset(viewer, position);								if (caret == selection.x)					text.setSelectionRange(selection.y, offset - selection.y);				else					text.setSelectionRange(selection.x, offset - selection.x);						final Event event= new Event();				event.x= text.getSelection().x;				event.y= text.getSelection().y;				text.notifyListeners(SWT.Selection, event);			}		}