Defining Character Encoding

You can define character encoding at the workspace level, at the editor level, or for specific text files. The default character encoding scheme in Eclipse is cp1252. You may be required to change this scheme, for example, if you intend to submit orders that contain character sets from languages such as Chinese, Japanese, or Norwegian. In this case, you can define the character encoding scheme as UTF-8.

When working with character encoding, see the following topics:

Defining Character Encoding at the Workspace Level

To define the character encoding scheme for the entire workspace:

  1. From the Design Studio Window menu, select Preferences.

    The Preferences dialog box opens.

  2. Expand General and then click Workspace.

    The Workspace page appears.

  3. In the Text file encoding field, select Other and then select an encoding value.

  4. Click Apply, then click OK.

Defining Character Encoding for Text Files

Text files do not include encoding declarations. Consequently, Eclipse editors attempt to use the most suitable character encoding, based on preference definitions or on the file content. For example, the default encoding for a Java properties file is ISO-8859-1. You may need to change the encoding to UTF-8 to ensure that the characters display correctly in the Properties File editor.

To define character encoding for text files:

  1. In Design Studio, open the text file.

  2. From the Edit menu, select Set Encoding.

    The Set Encoding dialog box appears.

  3. Select Other.

    A list of available options becomes available.

  4. Select a different encoding to associate with the file.

  5. Click Apply, then click OK.