| How to associate custom XML schema with XML editor? [message #230533] |
Tue, 21 April 2009 14:14  |
Dan Hoyt Messages: 13 Registered: July 2009 |
Junior Member |
|
|
I am trying to add content assist and validation to the "stock" XML editor
in a standalone product that repackages the Eclipse 3.3.2 platform and
adds our own plugins. I have:
A) extended org.eclipse.core.contenttype.contentTypes with my own
content-type specifying a base type of org.eclipse.core.runtime.xml and a
org.eclipse.core.runtime.content.XMLRootElementContentDescri ber:myRootElement
describer.
B) extended org.eclipse.wst.xml.core.catalogContributions with my own
catalogContribution pointing to my .xsd file.
However, I don't see 1) how to associate the editor with my .xsd for
content assist (I thought this was done automatically by B); or 2) how to
enable "Validate" on the context menu in the Navigator.
I saw in Nitin's EclipseCon presentation that "ItÂ’s common to define your
own contentType, say for a specialized form of XML, based on some specific
DTD, and then associate it with your editor," but I can't find any
documentation explaining exactly how to do this.
Any help or direction would be appreciated.
-Dan Hoyt
Senior Systems Architect, TSC
|
|
|