List<Component> () { suggestedFileList = new JBList<>(preparedMethodNames); suggestedFileList.setSelectionInterval(0, suggestedFileList.getItemsCount()); var scrollPane = new JBScrollPane(suggestedFileList); scrollPane.setAlignmentX(Component.LEFT_ALIGNMENT); final var choices = new String[]{ JavaBundle.message("generate.select.default.modifier.text"), PsiModifier.PUBLIC, PsiModifier.PROTECTED, PsiModifier.PRIVATE }; selectModifierBox = new ComboBox<>(choices); selectModifierBox.setAlignmentX(Component.LEFT_ALIGNMENT); return List.of(scrollPane, selectModifierBox); }