Eclipse Encoding MacRoman -> UTF8

陌路散爱 提交于 2019-12-17 10:58:35

问题


I recently created a project, organized it and well... I used my Mac with Eclipse running. Somehow it stored everything in MacRoman. The project has to be UTF8. Is there any easy way to handle the conversions?


回答1:


You have some detailed explanation in this blog post by David HOLT for the WOLips/WOProject.

Check your default preferences:

In Eclipse, go to Preferences>General>Workspace and select UTF-8 as the Text File Encoding.
This should set the encoding for all the resources in your workspace. Any components you create from now on using the default encoding should all match.

Change the encoding for a resource (project, folder or file)

Right (or Control) click on the resource in the WO Package Explorer and select the Properties option at the bottom of the contextual menu.
Go to Resource>Text File Encoding.
You should see "Inherited from container (UTF-8)" if you've made the change above, otherwise it will be (MacRoman).
Select Other - UTF-8 and Apply to make the warning go away.



来源:https://stackoverflow.com/questions/2707986/eclipse-encoding-macroman-utf8

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!