Is there a way to make IntelliJ mark error locations continuously for the files you are working on in the similar manner as Eclipse does? At the moment I need to make the project which lists all the errors in the message panel, but even then I cannot navigate to them using the editor panel. I would like to have simple dots/markers which would point to error/warning locations.
问题:
回答1:
IntelliJ IDEA detects errors and warnings in the current file on the fly (unless Power Save Mode is activated in the File
menu).
Errors in other files and in the project view will be shown after Build
| Make
and listed in the Messages tool window.
To navigate between errors use Navigate
| Next Highlighted Error
(F2) / Previous Highlighted Error
(Shift+F2).
Error Stripe Mark color can be changed here:
回答2:
I ran into the problem of not having set my sources root folder (project window--right click folder, mark directory as > sources root). If you don't set this IDEA doesn't parse the file.
回答3:
For those who even yet have the problem, try enabling "Build project automatically" in the Java compiler settings and see if that makes a difference as it worked for me.
回答4:
Frankly the errors are really hard to see, especially if only one character is "underwaved" in a sea of Java code. I used the instructions above to make the background an orangey-red color and things are much more obvious.
回答5:
Besides, you can choose going to next error only (ignore warning) by:
- Right click the Validation Side Bar.
- On the context menu, choose the
Go to high priority problems only
it works for Intellij Idea 12
回答6:
Use "Problem" tool window to see all errors. This window appears in bottom/side tabs when you enable "automatic" build/make as mentioned by @pavan above (https://stackoverflow.com/a/45556424/828062).
回答7:
In my case, I unknowingly unchecked Error Stripe Mark (Idea 2018.2: Settings > Editor > Color Scheme > General
and expand `Error and Warnings'). Checking that for Error showing the error marks in scrollbar area.
回答8:
In my case, IntelliJ was simply in power safe mode