Bug 6147 Templates don't work in "Show source of selected element only" mode
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/link/LinkedPositionUI.java
return minLocation;
	}
	private static Point getMaximumLocation(StyledText text, int offset, int length) {
		Point maxLocation= new Point(Integer.MIN_VALUE, Integer.MIN_VALUE);
		for (int i= 0; i <= length; i++) {
			Point location= text.getLocationAtOffset(offset + i);
			
			if (location.x > maxLocation.x)
				maxLocation.x= location.x;			
			if (location.y > maxLocation.y)
				maxLocation.y= location.y;			
		}	
		
		return maxLocation;
	}
	private void redrawRegion() {
		IRegion region= fViewer.getVisibleRegion();		
		int offset= fFramePosition.getOffset() -  region.getOffset();
		int length= fFramePosition.getLength();
		
		fViewer.getTextWidget().redrawRange(offset, length, true);
	}
	private void selectRegion() {
		IRegion region= fViewer.getVisibleRegion();
		int start= fFramePosition.getOffset() - region.getOffset();
		int end= fFramePosition.getLength() + start;	
		fViewer.getTextWidget().setSelection(start, end);		
	}
	private void updateCaret() {
		IRegion region= fViewer.getVisibleRegion();