JComponent () { final JPanel panel = new JPanel(new GridLayout(myFields.size(), 1, 0, JBUI.scale(5))); for (BeanField field: myFields) { panel.add(field.getComponent()); } BorderLayoutPanel result = JBUI.Panels.simplePanel().addToTop(panel); if (myTitle != null) { result.setBorder(IdeBorderFactory.createTitledBorder(myTitle)); } return result; }