eclipse for Java中没有语法突出显示 [英] No syntax highlighting in eclipse for java
问题描述
eclipse中的Java文件中没有突出显示语法。.这突然发生了..不知道为什么..
这是它的外观
如其他文章所述。.我试图从首选项窗口更改颜色,当我键入java时没有任何反应。
所有建议。
更新:
似乎未安装Java插件。 。按照下面的screeenshot
当我尝试安装Java插件时,它说根据以下屏幕截图已安装了新版本
在执行提交/更新项目操作后,我突然遇到了相同的问题。
要点是,Eclipse的默认编辑器有所更改,我们必须将其设置为正常。
请尝试以下方法,
1.转到 Windows ->单击首选项
2.从首选项窗口中转到常规-> 编辑器->单击文件关联
3.您可以在此处为* .java文件选择默认编辑器
当我第一次打开首选项时,文本编辑器 被设置为.java文件的默认编辑器,然后将其更改回 Java编辑器 。
现在它可以正常工作了。
There is no syntax highlighting in java files in my eclipse..This happened all of a sudden..Not sure why..
This is how it is looking now..
As mentioned in other posts..i tried to change the color from preferences window and there is nothing when i type java..something really messed up...
AAny suggestions..
Update:
It seems Java plugin is not installed..as per the below screeenshot
And when i try to install java plugin it says new version is already installed as per the below screenshot
I faced the same issue all of a sudden after a commit/update project operation.
The point is, default editor of Eclipse has changed somehow and we have to set it back to normal.
Try the below method,
1. Goto Windows -> Click Preferences
2. From the Preferences window goto General -> Editors -> Click File Associations
3. You can choose the default editor for *.java files here
When I first opened Preferences, 'Text editor' was set as the default editor for .java files and then I changed it back to 'Java Editor'.
Now it works perfectly fine.
这篇关于eclipse for Java中没有语法突出显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!