void (TextEditor editor) { ApplicationManager.getApplication().executeOnPooledThread(() -> { try { byte[] bytes = editor.getFile().contentsToByteArray(true); String log = new String(bytes, StandardCharsets.UTF_8); int index = log.lastIndexOf(StartupUtil.IDE_STARTED); if (index != -1) { ApplicationManager.getApplication().invokeLater(() -> { editor.getEditor().getCaretModel().moveToOffset(index); editor.getEditor().getScrollingModel().scrollToCaret(ScrollType.CENTER_UP); }, x -> editor.getEditor().isDisposed()); } } catch (IOException ignore) { } }); }