简体   繁体   English

在IDE中突出显示求反运算符

[英]Highlight negation operator in an IDE

I prefer Eclipse, but I'd love to know if there is any IDE anywhere that can detect, and offers syntax highlighting for, the negation operator (!). 我更喜欢Eclipse,但我很想知道是否有任何IDE可以检测到否定运算符(!),并为其提供语法高亮显示。 It's a critical thing, but it's often lost between long method names and an open parenthesis. 这是很关键的事情,但是在长方法名和圆括号之间经常会丢失。

Well, from the Preferences->Java->Editor->Syntax Coloring dialog, you can change the font and colors for operators which include ! 好了,从“首选项”->“ Java”->“编辑器”->“语法着色”对话框中,您可以更改运算符的字体和颜色,包括! to be whatever color, bold, italic, strikethrough, underline you want. 可以是您想要的任何颜色,粗体,斜体,删除线,下划线。 I'm not sure if you can just do ! 我不确定你是否能做到! though. 虽然。

Thanks to @Techrocket9's comments in @dkatzel's answer, I eventually found my way to wiki articles on how to create an editor and providing coloring for custom syntax rules . 感谢@ Techrocket9在@dkatzel的回答中的评论,我最终找到了有关如何创建编辑器并为自定义语法规则着色的Wiki文章。 These two articles have enough related information that I can begin trying my hand at creating a plugin. 这两篇文章都有足够的相关信息,我可以开始尝试创建一个插件。 If anyone has experience in this, feel free to add to this community wiki answer. 如果有人对此有经验,请随时添加到此社区Wiki答案中。 Otherwise, I'll update this when I have something. 否则,我在有东西的时候会更新它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM