예제 #1
0
        static XmlExpandSelectionAnnotation GetAnnotation(TextEditor editor, Func <XmlParser> getTreeParser)
        {
            var result = editor.Annotation <XmlExpandSelectionAnnotation> ();

            if (result == null)
            {
                result = new XmlExpandSelectionAnnotation(editor, getTreeParser());
                editor.AddAnnotation(result);
            }
            return(result);
        }