How to enter unicode characters in eclipse?

I run eclipse on Linux, and shift + control + U + 1 + 1 + 1 + 1 works in other applications (where 1111 is 4 digits of the Unicode character), like firefox, it does not work in eclipse.

I just want to add some special characters to my Java string.

+7
eclipse linux unicode
source share
2 answers

If all else fails, just use the Unicode escape code:

String s = "\u1111"; 

Makes you worry about setting encodings for your source files :)

+8
source share

Make a character in another program and copy it to Eclipse.

+6
source share

All Articles