[MonoDevelop] How can I attach file extensions to text editor

Michael Hutchinson m.j.hutchinson at gmail.com
Tue Nov 16 17:13:32 EST 2010


On Tue, Nov 9, 2010 at 5:38 PM, asharif <asharif.mse at gmail.com> wrote:
>
> Hello,
>
> Newbie to monodevelop.  So far it's awesome, but I can't figure out one
> thing.  How can I attach all files with extentions (say *.vm) to the default
> html editor ala VS, eclipse, netbeans, etc.

It's not supported from the GUI, but you could do it with a .addin.xml
file, e.g. like we do for spark files:

<Extension path = "/MonoDevelop/Core/MimeTypes">
	<MimeType id="application/x-spark" _description="Spark View template"
icon="md-html-file-icon" isText="true"
		baseType="text/html">
		<File pattern="*.spark" />
	</MimeType>
</Extension>

For full support you'd probably also have to attach a copy of the parser:

<Extension path = "/MonoDevelop/ProjectModel/DomParser">
	<Parser class = "MonoDevelop.Html.HtmlParser" fileExtensions=".vm" />
</Extension>

-- 
Michael Hutchinson
http://mjhutchinson.com


More information about the Monodevelop-list mailing list