0

I’m using Eclipse IDE 2022-09 (4.25.0) and when I print a French text like Périneau, the console return P�rineau.

example:

String str = "Périneau";
System.out.println(str);

console:

P�rineau

Is there something that I can do to have a good output?

shmosel
  • 49,289
  • 6
  • 73
  • 138
Alberto
  • 13
  • 3
  • 1
    It's under _Run Configurations > Common > Console Encoding_. Switch to "UTF-8" option. – Reilas May 24 '23 at 20:35
  • Also make sure the **Console font**, set on the **Colors and Fonts** preference page, supports those characters. – nitind May 24 '23 at 21:13
  • Hi Reilas, Your solution Worked. It worked with ISO-8859-1 but not with UTF-8. Thanks You. – Alberto May 25 '23 at 01:05

1 Answers1

1

You'll need to switch to "UTF-8".

Common Tab (Help - Eclipse Platform).

Encoding

Sets the encoding for the console allocated for this launch. If Default is selected the launch will inherit the current Text file encoding setting from the Workspace preference page. Or a different encoding can be selected for this launch.

Reilas
  • 3,297
  • 2
  • 4
  • 17