public XmlExpandSelectionAnnotation(MonoDevelop.Ide.Editor.TextEditor editor, XmlParser parser)
 {
     this.parser = parser;
     this.editor = editor;
     document    = editor.CreateDocumentSnapshot();
     editor.CaretPositionChanged += Editor_CaretPositionChanged;
     NodePath = GetNodePath(parser, document);
 }