void (@NotNull Editor hostEditor, @NotNull PsiFile hostFile, @NotNull ShowIntentionsPass.IntentionsInfo intentions, int passIdToShowIntentionsFor, int offset) { Project project = hostFile.getProject(); PsiElement psiElement = hostFile.findElementAt(offset); if (HighlightingLevelManager.getInstance(project).shouldInspect(hostFile)) { PsiElement intentionElement = psiElement; int intentionOffset = offset; if (psiElement instanceof PsiWhiteSpace && offset == psiElement.getTextRange().getStartOffset() && offset > 0) { PsiElement prev = hostFile.findElementAt(offset - 1); if (prev != null && prev.isValid()) { intentionElement = prev; intentionOffset = offset - 1; } } if (intentionElement != null && (intentionElement.getManager().isInProject(intentionElement) || ScratchUtil.isScratch(hostFile.getVirtualFile()))) { collectIntentionsFromDoNotShowLeveledInspections(project, hostFile, intentionElement, intentionOffset, intentions); } } }