DocumentContent (@Nullable Project project, @NotNull Document document, @Nullable VirtualFile highlightFile) { VirtualFile file = FileDocumentManager.getInstance().getFile(document); if (file != null && file.equals(highlightFile)) return new FileDocumentContentImpl(project, document, file); if (highlightFile == null) return new DocumentContentImpl(document); return new FileReferentDocumentContent(project, document, highlightFile); }