开发者

Implementing quick fixes list in eclipse

开发者 https://www.devze.com 2023-03-05 15:34 出处:网络
I develop plugin for eclipse, which marks some location in files. Also, user must have ability to do some actions with this markers, something like this list of actions in spellchecker:

I develop plugin for eclipse, which marks some location in files. Also, user must have ability to do some actions with this markers, something like this list of actions in spellchecker: http://i.stack.imgur.com/euB3g.png

but the only realization i've found is http://wiki.eclipse.org/FAQ_How_do_I_implement_Quick_Fixes_for_my_own_language%3F

which implements quick fixes list which looks more like auto开发者_高级运维completion list (screenshot is in article above).

So how i can implement list of quick fixes, which will be shown in marker's tooltip? This must work in any editor, or at least in CDT's editor and default text editor in eclipse.


The Eclipse Wiki article you reference is the correct way to add quick fixes. The quick fixes are associated with markers which may appear in your editor (if they are associated with a resource and line number).

There are several ways markers and their quick fixes are visible. In the java editor, markers by default appear highlighted with an icon in the ruler. Clicking on the icon, hitting ctrl+1 while editing that line, or hovering over the marker will open a popup with quickfixes.

Markers are also visible in the problems view. Similarly you can use the context menu or Ctrl+1 to open possble quickfixes.

0

精彩评论

暂无评论...
验证码 换一张
取 消