I want to display two Unicode characters in a TextView, but I get the squares:
- ℏ (reduced Planck constant / PLANCK CONSTANT OVER PW http://www.fileformat.info/info/unicode/char/210f/index.htm )
- ℞ ( WARNING ACCEPTS http://www.fileformat.info/info/unicode/char/211e/index.htm )
I know that not all Unicode characters are supported by the Android font by default, but the abbreviation "h-bar" is a Latin character and is one of the fundamental physical constants. Can anyone confirm that I am doing everything right? And if, how to solve this problem (the font of the third part is the only solution)?
view = new TextView(this);
int[] codePoint = { 0x210f, 0x211e };
String hhh = new String(codePoint, 0, codePoint.length);
view.setText(hhh);
source
share