Defining Unicode Characters

Unicode characters can be defined using the "\u" character escape sequence, followed by the hexadecimal notation of that character. For example, the hexadecimal notation for the number 65 is 0041, which is (4*16) + 1. So the following code would assign the letter A to the character variable letter.

char letter = '\u0041';



Java 1.4 Game Programming
Java 1.4 Game Programming (Wordware Game and Graphics Library)
ISBN: 1556229631
EAN: 2147483647
Year: 2003
Pages: 237

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net