Reputation: 9152
I am running eclipse in Linux and while shift+control+U+1+1+1+1 works in other apps (where 1111 are the 4 digits of the unicode character in question) like firefox, it fails in eclipse.
I just want to add some special chars to my Java string.
Upvotes: 8
Views: 4918
Reputation: 354566
If all else fails, just use a Unicode escape:
String s = "\u1111";
Spares you the hassle of configuring charsets for your source files as well :)
Upvotes: 9