程序员潇然 发表于 2022-8-10 14:42:31

Android Studio as 控制台中文乱码 utf8设置

IDEA控制台中文乱码,Android Studio控制台中文乱码是经常发生的事情,尤其是新项目,或者工具新安装,一般就这样几个步骤,可以逐个试一下看看。

!(data/attachment/forum/202208/10/144105k9ytxn7qz98f2aix.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "image.png")

### 编码设置

设置

!(data/attachment/forum/202208/10/144117zcp54do7ee4beynh.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "image.png")

### 虚拟机参数设置

!(data/attachment/forum/202208/10/144135vb00dfad0f0n0uid.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "image.png")

写入`-Dfile.encoding=UTF-8`

!(data/attachment/forum/202208/10/144155zxcct08at0h2zt20.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "image.png")

**关闭项目重新打开**


!(data/attachment/forum/202208/10/144228a5k8mym2beb8z00y.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "image.png")


!(data/attachment/forum/202206/16/141330jha7st9soow8772i.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/300 "common_log.png")
`转载务必注明出处:程序员潇然,疯狂的字节X,https://crazybytex.com/thread-132-1-1.html `
页: [1]
查看完整版本: Android Studio as 控制台中文乱码 utf8设置