📅  最后修改于: 2022-03-11 14:59:57.345000             🧑  作者: Mango
JTextPane f = new JTextPane();
f.setContentType("text/html"); // let the text pane know this is what you want
f.setEditable(false); // as before
f.setBackground(null); // this is the same as a JLabel
f.setBorder(null); // remove the border