JComponent () { JPanel panel = new JPanel(new BorderLayout()); myMessagePane = new JEditorPane(UIUtil.HTML_MIME, ""); myMessagePane.setEditable(false); myMessagePane.setEditorKit(HTMLEditorKitBuilder.simple()); JScrollPane scrollPane = ScrollPaneFactory.createScrollPane(myMessagePane); scrollPane.setPreferredSize(JBUI.size(500, 400)); panel.add(new JLabel(RefactoringBundle.message("the.following.problems.were.found")), BorderLayout.NORTH); panel.add(scrollPane, BorderLayout.CENTER); @Nls StringBuilder buf = new StringBuilder(); for (String description : myConflictDescriptions) { buf.append(description); buf.append("<br><br>"); } myMessagePane.setText(buf.toString()); return panel; }