| Summary: | Marker tooltip / message is not displayed on left editor ruler when using custom markers | ||
|---|---|---|---|
| Product: | [Modeling] TMF | Reporter: | Kristian Nagy <nkristy1> |
| Component: | Xtext | Assignee: | Project Inbox <tmf.xtext-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | Holger.Schill, sebastian.zarnekow, sven.efftinge |
| Version: | unspecified | Flags: | sven.efftinge:
indigo+
|
| Target Milestone: | SR2 | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
After having a deeper look there was a guard in org.eclipse.xtext.ui.editor.hover.AbstractProblemHover.isHandled(Annotation) that filtered out non Xtext markers. I can not see a reason why this is a must. pushed test and fix to master. After a discussion with Sebastian the guard has to filter out so that only warnings and errors can be hovered. I will work on this issue again. Now the guard only enables hover for subTypes of org.eclipse.ui.workbench.texteditor.error and org.eclipse.ui.workbench.texteditor.warning. Kristian, for your example you have to set the severity to IMarker.SEVERITY_WARNING or IMarker.SEVERITY_ERROR to enable hover on your custom markers. m.setAttribute(IMarker.SEVERITY, IMarker.SEVERITY_WARNING); pushed final fix to master :-) Sorry Holger, I'm afraid I was wrong. Please double check whether a bookmark (add via Add Bookmark... in the left gutter) is correctly displayed in the hover, too. I assume your initial patch was better than my suggestion. No problem. I replaced the implementation with the original one and bookmarks are not visible as hover also. Now I enabled subTypes of org.eclipse.ui.workbench.texteditor.bookmark also and everything is fine. I think I will add some tests for that stuff tomorrow. :-) pushed to master. Closing all bugs that were set to RESOLVED before Neon.0 Closing all bugs that were set to RESOLVED before Neon.0 |
Build Identifier: I20110613-1736 Move mouse over a resource marker displayed on left Xtext editor ruler. Marker message should be shown. This worked in Xtext 2.0.0. In Xtext 2.0.1 nothing is displayed when you move mouse over the marker. Xtext 2.0.1 displays the message only on right editor ruler. Reproducible: Always Steps to Reproduce: 1. Create custom marker extension in plugin.xml. Example: <extension id="com.examples.problem" name="Example problem marker" point="org.eclipse.core.resources.markers"> <super type="org.eclipse.core.resources.problemmarker"> </super> <super type="org.eclipse.core.resources.textmarker"> </super> </extension> 2. Create a marker of this type: IMarker m = iresource.createMarker("com.examples.problem"); m.setAttribute(IMarker.LOCATION, "path to iresource (/Project/src/resource)"); m.setAttribute(IMarker.MESSAGE, "Hello?"); m.setAttribute(IMarker.LINE_NUMBER, 1); 3. Run the code above and in runtime Eclipse: move mouse over marker and see that no message appears on left editor ruler. There will be a message if you hover over the right editor ruler (only).