Eclipse:为类和对象打开语法高亮

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/13566517/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 21:26:42  来源:igfitidea点击:

Eclipse: Turn on syntax-highlighting for Classes and Objects

eclipsesyntax-highlighting

提问by Philip Giuliani

Is there any possibility to turn on the highlighting for Classes and Objects in Eclipse like it is in Visual Studio? At the moment only the Variable names are highlighted.

是否有可能像在 Visual Studio 中一样在 Eclipse 中打开类和对象的突出显示?目前仅突出显示变量名称。

Left: Eclipse, Right: Visual Studio 2012

左:Eclipse,右:Visual Studio 2012

Image: (http://image-uploader.de/bild.php/9468,unbenanntHU9EZ.jpg)

图片:(http://image-uploader.de/bild.php/9468,unbenanntHU9EZ.jpg

Visual difference between Eclipse(left) and Visual Studio (right)

Eclipse(左)和 Visual Studio(右)的视觉差异

回答by user136776

Preferences -> Java -> Editor -> Syntax Coloring

首选项 -> Java -> 编辑器 -> 语法着色

Then just switch on / off what you want highlighted.

然后只需打开/关闭您想要突出显示的内容。

回答by Festus Tamakloe

try this

尝试这个

Window -> Preferences -> Java -> Editor -> Mark Occurrences

回答by 2ne

Full explanation here of how to add advanced syntax marking http://www.javalobby.org/forums/thread.jspa?threadID=15586

这里完整解释了如何添加高级语法标记http://www.javalobby.org/forums/thread.jspa?threadID=15586