I previously posted a sample showing how to create a plugin for Intellipad (shipped with the Microsoft "Oslo" SDK) which would support syntax coloring and error highlighting for files written in your own Mg-defined language. That sample worked with the previous release of the SDK. Now that the January 2009 release has come out, the sample needs a few minor updates.
The code for the updated sample is available at github.com:
- git://github.com/m4dc4p/mg-todo.git -- Git users can pull the tag v02102009.
- http://github.com/m4dc4p/mg-todo/tree/v02102009 -- For online browsing and download. Just click the "download" link on that page.
- System.Dataflow.DynamicParser no longer exposes a ParseObject() method -- now Parse<object> must be used.
Loading a parser from an MGX resource now uses
The signature of the abstract method System.Dataflow.ErrorReporter.OnError is now
protected abstract void OnError(ErrorInformation errorInformation)
protected abstract void OnError(ISourceLocation sourceLocation, ErrorInformation errorInformation)
The ISourceLocation parameter is now available on the errorInformation object from the Location property.
- The Python script to add the ToDo Mode command is no longer needed. ToDo mode will stil not show up in "mode" drop down on the right. However, loading a .todo file will use the right mode.
Thanks to Douglas Purdy the link reminding me I should update this sample!