There is such code:
private JTextPane htmlTextPane = new JTextPane(); htmlTextPane.setContentType("text/html;Charset=CP1251"); when displaying the contents of the htmlTextPane field using getText () instead of Russian characters, html character codes of the form & # nnnn; What should I do to make Russian characters appear normally instead?