JComponent () { myTable = new JBTable(myTableModel); myTable.setShowGrid(false); TableColumn nameColumn = myTable.getColumnModel().getColumn(NAME_COLUMN); TableColumn boundColumn = myTable.getColumnModel().getColumn(BOUND_VALUE_COLUMN); TableColumn valueColumn = myTable.getColumnModel().getColumn(DEFAULT_VALUE_COLUMN); Project project = myClass.getProject(); nameColumn.setCellRenderer(new MyCellRenderer()); nameColumn.setCellEditor(new StringTableCellEditor(project)); boundColumn.setCellRenderer(new CodeFragmentTableCellRenderer(project)); boundColumn.setCellEditor(new JavaCodeFragmentTableCellEditor(project)); valueColumn.setCellRenderer(new CodeFragmentTableCellRenderer(project)); valueColumn.setCellEditor(new JavaCodeFragmentTableCellEditor(project)); myTable.setPreferredScrollableViewportSize(JBUI.size(210, -1)); myTable.setVisibleRowCount(4); myTable.getSelectionModel().setSelectionMode(ListSelectionModel.SINGLE_SELECTION); myTable.getSelectionModel().setSelectionInterval(0, 0); myTable.setSurrendersFocusOnKeystroke(true); myTable.setCellSelectionEnabled(true); myTable.setFocusCycleRoot(true); if (myHideDefaultValueColumn) { final TableColumn defaultValue = myTable.getColumnModel().getColumn(DEFAULT_VALUE_COLUMN); myTable.removeColumn(defaultValue); myTable.getModel().addTableModelListener(new TableModelListener() { @Override public void tableChanged(TableModelEvent e) { if (e.getType() == TableModelEvent.INSERT) { myTable.getModel().removeTableModelListener(this); final TableColumnAnimator animator = new TableColumnAnimator(myTable); animator.setStep(20); animator.addColumn(defaultValue, myTable.getWidth() / 2); animator.startAndDoWhenDone(() -> myTable.editCellAt(myTable.getRowCount() - 1, 0)); animator.start(); } } }); } final JPanel panel = new JPanel(new BorderLayout()); panel.add(SeparatorFactory.createSeparator(JavaRefactoringBundle.message("changeClassSignature.parameters.panel.border.title"), myTable), BorderLayout.NORTH); panel.add(ToolbarDecorator.createDecorator(myTable).createPanel(), BorderLayout.CENTER); return panel; }