-1

I'm programming a GUI with a table to show the unicode-characters, but with the standard font it will display instead of the unicode-character a square box.

With what fonts can i display all that characters if possible of all languages?

enter image description here

Usually I do not declare a font, only I need it, but not in this case.

It would be nice if someone knows a solution.

Thanks in advance for your answers :D

Sebi
  • 5
  • 1
  • 6

1 Answers1

0

I can't see your picture. But usually those squares come when you want a character that is not existed in your font or you have some problem in your unicode encoding. either you can use more comprehensive font (TrueType) or check your data to be encoded correctly. see these for further info on Java & Unicodes.

https://docs.oracle.com/javase/tutorial/i18n/text/unicode.html

https://www.javatpoint.com/unicode-system-in-java

https://en.wikibooks.org/wiki/Java_Programming/Unicode

an example would be :

http://www.java2s.com/Tutorial/Java/0419__PDF/Usetruetypefonttodrawunicodestring.htm

How to draw a unicode character in java?

http://www.java2s.com/Code/Java/2D-Graphics-GUI/Drawunicodestring.htm

nullqube
  • 2,959
  • 19
  • 18
  • I know how to declare Unicode, but need some fonts whit that I can display if possible all characters. – Sebi Feb 27 '18 at 16:06
  • what language you need to display? also can you provide some code you using ? – nullqube Feb 27 '18 at 16:16
  • If possible I want to display every language also if I need more than one font. I tryed to provide some code, but i don't know what exactly you want to see. ;) – Sebi Feb 27 '18 at 16:58