Eclipse Mark Occurrences
Mark Occurrences
The Mark Occurrences feature enables you to see where an element is referenced by simply clicking on the element in the editor.
When the Mark Occurrences feature is enabled, all occurrences of the element within the active file will be highlighted,
and indicators will be displayed in the annotations bar (to the right of the editor).
In addition, hovering over the element will cause a tooltip to be displayed with the location of all references of the element,
including occurrences of the element in other files.

Occurrences can be of 2 types -
“Write Occurrence” (for occurrences that are in a write mode) or
“Read Occurrence” (for occurrences that are in a read mode).
These will be highlighted in different colors according to the setting configured for PHP elements 'read' and 'write' occurrences
in the Annotations preferences page (Window | Preferences | General | Editors | Text Editors | Preferences).
Here you can also configure the indicators used in the vertical ruler/marker bar (to the left of the editor)
and the annnotations bar (to the right of the editor).
The types of elements whose occurrences will be highlighted can be configured in the
Mark Occurrences preferences page (Window | Preferences | PHP | Editor | Mark Occurrences ).
By default, the following types of elements are marked:
Method Exit - Exit points (throws / return / end of flow) of a method will be marked
Break / Continue - Scope (for, foreach, while, do-while or switch structure) of a break / continue statement will be marked
Local variables
Global variables
Parameters
Functions
Methods
Fields
Class Constants
Constants (defined)
Class/Interface
HTML Tags
You'll want to change the "Occurrences" and "Write Occurrences" colors.
This can be done in the Annotations menu, which is located —
as Colin said — in the Preferences menu under the path
General > Editors > Text Editors > Annotations
If you have an occurrence marked in the overview ruler (the column to the right of the scrollbar),
you can open the Annotations menu directly by right-clicking on the occurrence and selecting Preferences from the context menu.
The color of "occurrences" is used for instances where the variable is being read, but not modified,
in the code (e.g. k in if(k > 1)).
The color of "write occurrences" is used where the variable gets modified/written to
in the code (e.g. k in k = k + 1).

If you want to change the default highlight colours you can do so in the
Preferences > General > Editors > Text Editors > Annotations
– look for“Occurrence annotation” and “Write occurrences”.

Eclipse Mark Occurrences的更多相关文章
- eclipse使用tips-Toggle Mark Occurrences 颜色更改
Toggle Mark Occurrences这个功能非常好用,能把选中的方法/变量在本类中全部出现的地方高亮显示,是一个非常实用的功能.但是默认颜色是灰色,非常毁眼.可以通过下面的设置更改为自己喜欢 ...
- Eclipse 相同变量背景高亮显示设置(Occurrences)
为了你们查看设置的简便,本次书写重点用图片说明.
- eclipse常用快捷键
1. ctrl+shift+r:打开资源 这可能是所有快捷键组合中最省时间的了.这组快捷键可以让你打开你的工作区中任何一个文件,而你只需要按下文件名或mask名中的前几个字母,比如applic*.xm ...
- Eclipse 双击变量,其他相同变量有底色
转载:http://blog.csdn.net/majian_1987/article/details/46691697 方便下次查找. 在Eclipse中,鼠标选中或者光标移动到Java类的变量名时 ...
- [No000077]打造自己的Eclipse
下载官网的Eclipse IDE for Java EE Developers 在根目录下的eclipse.ini文件中添加"-Dfile.encoding=UTF-8", 作用: ...
- Eclipse设置选中高亮显示
高亮显示选中的变量对于程序员编程很有帮助,正常情况下Eclipse选中变量时都会高亮显示,可能软件冲突导致高亮显示失效,通过如下方法可以进行恢复. 单击IDE顶部Window菜单下的Prefences ...
- 【转】Eclipse快捷键 10个最有用的快捷键
转载地址:http://www.open-open.com/bbs/view/1320934157953 Eclipse中10个最有用的快捷键组合 一个Eclipse骨灰级开发者总结了他认为最有用但 ...
- 转:Eclipse快捷键 10个最有用的快捷键
Eclipse快捷键 10个最有用的快捷键 Eclipse中10个最有用的快捷键组合 一个Eclipse骨灰级开发者总结了他认为最有用但又不太为人所知的快捷键组合.通过这些组合可以更加容易的浏览源代 ...
- Eclipse中10个最有用的快捷键组合
Eclipse中10个最有用的快捷键组合 (转) 一个Eclipse骨灰级开发者总结了他认为最有用但又不太为人所知的快捷键组合.通过这些组合可以更加容易的浏览源代码,使得整体的开发效率和质量得到提升. ...
随机推荐
- c++刷题(39/100)笔试题3
题目1: 现在你需要用一台奇怪的打字机书写一封书信.信的每行只能容纳宽度为100的字符,也就是说如果写下某个字符会导致行宽超过100,那么就要另起一行书写 信的内容由a-z的26个小写字母构成,而每个 ...
- 由于找不到MSVCP20.dll,无法继续执行代码
系统:win10 专业版,刚升级win10没几天 mysql 5.7.21 解压安装,初始化时报错,错误如图: 一.查找错误原因 参考:MySQL安装使用遇到的问题, 找到微软中文官方网站,搜索 ms ...
- linux磁盘已满,文件占用情况
du -sh /data0/* 如上,/data0/* 表示查看data0文件夹下各个目录的磁盘占用情况 df -h 查看总的磁盘占比
- web.xml 配置中classpath: 与classpath*:的区别——(十一)
首先 classpath是指 WEB-INF文件夹下的classes目录 解释classes含义: 1.存放各种资源配置文件 eg.init.properties log4j.properties s ...
- 大数据系列之数据仓库Hive安装
Hive系列博文,持续更新~~~ 大数据系列之数据仓库Hive原理 大数据系列之数据仓库Hive安装 大数据系列之数据仓库Hive中分区Partition如何使用 大数据系列之数据仓库Hive命令使用 ...
- 005_系统运维之SLA与SLO的关系
服务水平协议(简称:SLA,全称:service level agreement)是在一定开销下为保障服务的性能和可靠性,服务提供商与用户间定义的一种双方认可的协定.通常这个开销是驱动提供服务质量的主 ...
- history命令追查登录的用户和时间
Linux查看History记录加时间,这个对于系统管理员还是很有帮助的,原因不解释,你懂得!ora11g$ history | more 1 rlwrap sqlplus / as sy ...
- Kali Linux上安装SSH服务
安装 SSH 从终端使用 apt-get 命令安装 SSH 包: # apt-get update # apt-get install ssh 启用和开始使用 SSH 为了确保安全 shell 能够使 ...
- reportng之测试报告升级美化
背景:偶然看到一个人的自动化框架的测试报告好漂亮,心痒痒,今天弄了一下午,还是不行,结果到现在就现在,我特么成功了,不为什么 Mark一下: 本地化修改 获取源码,修改reportng.propert ...
- 对象克隆及属性转换-JavaScript
在某些项目中,需要将一些返回信息进行其他语言的翻译,可以为不同语言用户提供不同的语言版本.下面是一个实现: /** * @class Translate * @description 查询字典,翻译成 ...