Settings properties file to display utf-8 encoding in Intellij Idea
When developing i18n international multilingual using java, * .properties files are often used to store text in various languages. In the past, I used eclipse to enter a piece of Chinese in the properties file, and it will be automatically converted to Unicode encoding, so that the Chinese garbled problem was prevented. Intellij Idea also supports this.
By default, the properties property file displays Unicode encoding, which is very inconvenient for development. such as
Set the properties file to display in Chinese
- mac os
Preferences -> Editor -> File Encodings -> Check 'Transparent native-to-ascii conversion'
- windows and Linux
File -> Setting -> Editor -> File Encodings -> Check 'Transparent native-to-ascii conversion'
Click OK, Unicode will automatically switch to Chinese, so editing is more convenient.
In fact, the properties file is still unicode encoded, but when it is opened in the editor, Intellij Idea converts its content into Chinese, which is very useful!