void () { Document document = FileDocumentManager.getInstance().getDocument(myFile); if (document == null) return; int offset = document.getLineEndOffset(myPosition.getLine()); myRangeMarker = document.createRangeMarker(offset, offset, true); }