boolean (@NotNull PsiElement psiRoot) { FileHighlightingSetting settingForRoot = getHighlightingSettingForRoot(psiRoot); if (settingForRoot == FileHighlightingSetting.SKIP_HIGHLIGHTING || settingForRoot == FileHighlightingSetting.SKIP_INSPECTION) { return false; } Project project = psiRoot.getProject(); VirtualFile virtualFile = psiRoot.getContainingFile().getVirtualFile(); if (virtualFile == null || !virtualFile.isValid()) return false; if (ProjectUtil.isProjectOrWorkspaceFile(virtualFile) && !vcsIgnoreFileNames.contains(virtualFile.getName())) { return false; } ProjectFileIndex fileIndex = ProjectRootManager.getInstance(project).getFileIndex(); if (ProjectScope.getLibrariesScope(project).contains(virtualFile) && !fileIndex.isInContent(virtualFile)) return false; return !SingleRootFileViewProvider.isTooLargeForIntelligence(virtualFile); }