Add these three lines in this file and restart:
C:\Users\Administrator\AppData\Roaming\Google\AndroidStudio4.2\studio64.exe.vmoptions
-Dfile.encoding=UTF-8
-Duser.country=US
-Duser.language=en
For memo
Before modify:
“C:\Program Files\Java\jdk1.8.0_202\bin\java.exe” -Djava.security.manager=worker.org.gradle.process.internal.worker.child.BootstrapSecurityManager -Xmx512m -Dfile.encoding=UTF-8 -Duser.country=CN -Duser.language=zh -Duser.variant -cp C:\Users\Administrator.gradle\caches\6.5\workerMain\gradle-worker.jar worker.org.gradle.process.internal.worker.GradleWorkerMain “‘Gradle Worker Daemon 9’”
After modify:
“C:\Program Files\Java\jdk1.8.0_202\bin\java.exe” -Djava.security.manager=worker.org.gradle.process.internal.worker.child.BootstrapSecurityManager -Xmx512m -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp C:\Users\Administrator.gradle\caches\6.5\workerMain\gradle-worker.jar worker.org.gradle.process.internal.worker.GradleWorkerMain “‘Gradle Worker Daemon 1’”
“C:\Program Files\Java\jdk1.8.0_202\bin\java.exe” -XX:MaxMetaspaceSize=256m -XX:+HeapDumpOnOutOfMemoryError -Xms256m -Xmx512m -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp C:\Users\Administrator.gradle\wrapper\dists\gradle-6.5-all\2oz4ud9k3tuxjg84bbf55q0tn\gradle-6.5\lib\gradle-launcher-6.5.jar org.gradle.launcher.daemon.bootstrap.GradleDaemon 6.5
“C:\Program Files\Java\jdk1.8.0_202\bin\java.exe” -Xmx1536m -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant -cp C:\Users\Administrator.gradle\wrapper\dists\gradle-6.5-all\2oz4ud9k3tuxjg84bbf55q0tn\gradle-6.5\lib\gradle-launcher-6.5.jar org.gradle.launcher.daemon.bootstrap.GradleDaemon 6.5
Bugs for Android Studio / IntelliJ IDEA
But when generating javadoc, Android Studio does not use any options in file studio64.exe.vmoptions, you can execute in commandline and add “-J-Duser.language=en” manualy:
“C:\Program Files\Java\jdk1.8.0_202\bin\javadoc.exe” -J-Duser.language=en @D:\Downloads\Android-xxx\build\tmp\androidJavadocs\javadoc.options