<!--    XPath Visualiser,
	 by Dimitre Novatchev, Apr. 2000.
	 mailto:dnovatchev@yahoo.com

This is a simple yet powerful tool for the evaluation of an XPath expression
and visual presentation of the resulting nodeset.

The source XML Document is displayed with any node hi-lighted that satisfies the
XPath expression.

The expandable/collapsible syntax colour-coded display of the source
XML Document is the same as done by default by Internet Explorer.

This tool will best be used for:
-------------------------------
1. Composing the exact XPath expression when designing an XSLT stylesheet. 
2. As a "nodeset view" in a watch window of an XSLT debugger.
3. Learning and playing with XPath expressions.
4. As a good example how to process completely un-anticipated XML documents
   using "push processing".

Files in this distribution:
--------------------------
      623 authors.xml
    2,256 back42.jpg
   20,144 myDefaultss50.xsl
    3,371 Readme.txt
      496 topFrame.htm
      102 viewFrame.htm
    2,414 XPathMain.htm

To start the XPath Visualiser:
-----------------------------
1. Unzip the XPathVisualiser.zip file in a separate directory.
2. Double-click on XPathMain.htm


This is a customisation of the original DEFAULTSS.XSL 
written by Johnatan Marsh. 
The changes that had to be made are listed below:
------------------------------------------------

1. The original stylesheet was modified to work 
with the XSLT default namespace uri: 
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

2. A global parameter named "selectedNodes" was added.

3. Additional logic was added to all templates 
to recognise whether the current match belongs to
the $selectedNodes nodeset.

4. All nodes that belong to the $selectedNodes nodeset 
are treated in a special way - hi-lighted.

Known issues:
------------
A bug in all MSXML processors, including the July one, sometimes
prevents the correct finding and hilighting of nodes that are 
specified by the XPath expression.

What happens is that sometimes, according to MSXML 
count(nodeset | member-node) != count(nodeset)

I have reported this bug to Microsoft twice (every month since June)
and every time got their assurance that the bug will be fixed...
Hopefully this will happen in the not so distant future.

Plans for the future:
--------------------
1. Provide a remote, web-server based XPath Visualiser.
2. Change the user interface into Netscape-compatible.
3. Integrate the XPath Visualiser into an existing editor/debugger 
(hopefully Corey Haines and Chris Stefano will be interested... :o))) )
 -->

Here are the title comments of Johnatan Marsh -- the author of the
original Microsoft default stylesheet:
-------------------------------------
<!--
  IE5 default style sheet, provides a view of any XML document
  and provides the following features:
  - auto-indenting of the display, expanding of entity references
  - click or tab/return to expand/collapse
  - color coding of markup
  - color coding of recognized namespaces - xml, xmlns, xsl, dt
  
  This style sheet is available in IE5 in a compact form at the URL
  "res://msxml.dll/DEFAULTSS.xsl".  This version differs only in the
  addition of comments and whitespace for readability.
  
  Author:  Jonathan Marsh (jmarsh@microsoft.com)
-->
------------------------------------

Change History:

28 Sep. 2000. 
Fixed a bug that hi-lighted the end-tag (in addition to the
start tag of a selected element.

27 Sep. 2000.  Fixed the following bugs found by Aung Aung (aaung@microsoft.com):
> 1. one thing, if I
> hit 'Enter' key  when my coursor is in the browse box, it flip to a 
> "This page is unable to display" page, I think you might want to fix it
>
> 2. <!-- ************** use apply-templates instead of value-of, or the text
> node won't be colored ************-->  
>  <xsl:apply-templates/>
>  <!--
>    <SPAN class="tx"><xsl:value-of select="."/></SPAN>
>    -->
> <!-- ************** END ************-->  


26 Sep. 2000. Fixed the following bugs found by Aung Aung (aaung@microsoft.com):

> 1. async property on the documents (style and source) should set to
> false
> before loading, or "attempt to modify a read-only node" error occurs.
> ( need
> to fix in htm file)
>
> 2. If the fileName is invalid the loadFile() got called infinately
> which
> crash IE. (need to check and not call doQuery() from inside
> loadFile()).
> 


 9 Sep. 2000. Submitted initially to vbxml.com.
