JComponent () { loadCombo(); JButton editTemplatesButton = new FixedSizeButton(myCbxTemplates); JPanel centerPanel = new JPanel(new GridBagLayout()); JLabel selectTemplateLabel = new JLabel(IdeBundle.message("label.name")); centerPanel.add(selectTemplateLabel, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0, GridBagConstraints.EAST, GridBagConstraints.NONE, JBUI.insets(2), 0, 0)); centerPanel.add(myCbxTemplates, new GridBagConstraints(1, 1, 1, 1, 0.0, 0.0, GridBagConstraints.EAST, GridBagConstraints.HORIZONTAL, JBUI.insets(2), 50, 0)); centerPanel.add(editTemplatesButton, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0, GridBagConstraints.EAST, GridBagConstraints.NONE, JBUI.insets(2), 0, 0)); editTemplatesButton.addActionListener(new ActionListener(){ @Override public void actionPerformed(ActionEvent e){ onEditTemplates(); } }); return centerPanel; }