void (@NotNull String templateText, @NotNull PsiFile context) { PsiFile file = PsiFileFactory.getInstance(context.getProject()) .createFileFromText("dummy.html", context.getLanguage(), templateText, false, true); VirtualFile vFile = file.getVirtualFile(); if (vFile != null) { UndoUtil.disableUndoFor(vFile); } setFile(file); }