JosephCooney

Putting the 'Junk' in DotNetJunkies

<November 2008>
SuMoTuWeThFrSa
2627282930311
2345678
9101112131415
16171819202122
23242526272829
30123456


Navigation

My GotDotNet Samples

Subscriptions

News

I've moved my weblog to jcooney.net. Come and visit me there.


Syntax Hilighting XPath Expressions

I love XPath. My first GotDotNet sample was an XPath expression tester. It is a very simple application. It can be quite helpful when working out expressions, but one thing that I always wanted to add (but never got around to) was syntax hilighting. After a while mucking around with the ROTOR XPath implementation I'm starting to be able to do the syntax hilighting.



As you can see from the screen shot I'm not actually hiligthing the text as it is typed, I'm doing that in a seperate text box for now. The eventual .plan is for it to all happen in a single text box, possibly with auto-completeion like Visual Studio Intellisense (tm). One problem with the SSCLI XPath implementation (for the use I'm putting it to anyway) is that it doesn't care about maintaining the exact text used to create the expression - it's only concerned with building an abstract syntax tree of nodes so certain things are "thrown out" during the parse. I'm not actually sure if the current way I'm going about things is going to work, but hopefully I can have fun trying. When/If I get it working I will post an update on GotDotNet.

posted on Tuesday, April 13, 2004 7:09 AM by JosephCooney





Powered by Dot Net Junkies, by Telligent Systems