Two reasons why Android Studio code has no color distinction

After using Android Studio Electric Eel | 2022.1.1 Patch 1 version for a period of time, I found that the code inside had no color prompts. After searching, there were two reasons:

1. Power save mode is checked. At this time, just click File to find Power Save Mode and uncheck it, then recompile.

2. After the Android Studio version is 4.1, the Butter Knife plug-in is installed. This can be solved by uninstalling the Butter Knife plug-in and restarting Android Studio;

(This picture shows the current status of my AS installation)

I installed the first butterKnife before. I uninstalled it and reinstalled the second one. Here is what I did:

Find the file path of Android-ButterKnife-Injections.jar:

C:\Users\EDZ\AppData\Roaming\Google\AndroidStudio2022.1\plugins You can see the latest installed jar package in this folder (the jar package corresponding to the second butterKnife, and the previously downloaded ButterKnife in the path jar file (needs to be deleted), put the Android-ButterKnife-Injections.jar file in the installation path of Android Studio (I installed it to the D drive, so the path is D:\Android\studio\As4.2\android- studio\plugins), then restart, and find that there is still no color. At this time, the packaging can be compiled and packaged normally;

Then I continued to set the Android-ButterKnife-Injections plug-in and set it to disable, as shown below

Then restart, you can see the color distinction, and some other functions are displayed, and where they are called will also be displayed, as follows:

Then compile and package, and it can be packaged normally;

Guess you like

Origin blog.csdn.net/gqg_guan/article/details/132803603