I am developping a text editor with Java swing, I want to use a monospace font to display (for example Consolas
font):
JTextArea textArea = new JTextArea("text");
textArea.setFont(new Font("Consolas", Font.PLAIN, 12));
But if there's any unicode character(for ex: Japanese character), it shows square (this font does not support this kind of character).
I still want to use Consolas, but if there's any character which is not supported, it will use other font to render (a unicode font). How can I do that?
I think about use html to set font for each character but maybe it's too heavy. I just want 2 font: 1 monospace font & 1 unicode font