Component (JTable ttable, Object value, boolean isSelected, int row, int col) { myExpression = (Expression)value; myDocument = PsiDocumentManager.getInstance(project).getDocument(myExpression.getFile()); return new EditorTextField(myDocument, project, myExpression.getFileType()) { @Override protected boolean shouldHaveBorder() { return false; } @Override protected void onEditorAdded(@NotNull Editor editor) { super.onEditorAdded(editor); Runnable runnable = () -> { final Editor e = getEditor(); if (e != null) { IdeFocusManager.getGlobalInstance().doWhenFocusSettlesDown(() -> IdeFocusManager.getGlobalInstance().requestFocus(e.getContentComponent(), true)); } }; SwingUtilities.invokeLater(runnable); } }; }