[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.webtools] Re: QuickFix in XML Editor

Xavier Coulon wrote:
I managed to generate custom Markers (of my own type) in a plugin based on the Eclipse XML Editor. It works fine, and given the content validation result, I get error or warning markers in the left margin that are bound into the 'problems' view.
Now, I'd like to provide some 'quick fix' as we can find in the Java Editor, but for now, I'm a bit stuck.
First, I added an extension based on 'markerResolution' and it appears correctly - yet *ONLY* - in the problems view. I did not find how to get access to the 'Quick Fix' contextual menu in the editor's left column. Secondly,I noticed a 'quick assistant' that provides a 'surround with element' when I press 'Ctrl+1' as item I want to fix is selected in the editor.
Adding a 'org.e.wst.sse.ui.quickFixProcessor' targeting a 'problemType' that matches an attribute of the same name in my custom marker does not seem to work :-( BTW, this custom attribute that was also declared in the plugin.xml


Can you tell me what are the differences between 'quick fix' and 'quick assistant' (or is it just the same) ?
Is it possible to have quickfix in the XML Editor's left margin ?
Otherwise, how can I contribute to the 'quick assist' contextual menu ?

The order should be to present any available Quick Fixes first, and then if there aren't any, to offer Quick Assists. But they're essentially doing the same thing, the former just being tied to a problem annotation of some kind.


If you were using 'org.e.wst.sse.ui.quickFixProcessor' literally, it might just be that that's an incorrect form of "org.eclipse.wst.sse.ui.quickFixProcessor". Could you post the part of your plugin.xml that's meant to contribute your processor?

--
---
Nitin Dahyabhai
Eclipse WTP Source Editing
IBM Rational