1.File->Settings->Editor->File Encodings
2.File->Other Settings->Default Settings ->Editor->File Encodings
3.将项目中的.idea文件夹中的encodings.xml文件中的编码格式改为uft-8
4.File->Settings->Build,Execution,Deployment -> Compiler -> Java Compiler
设置 Additional command line parameters选项为 -encoding utf-8