// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) // This code is distributed under the GNU LGPL (for details please see \doc\license.txt) using System; using ICSharpCode.AvalonEdit.Document; using ICSharpCode.AvalonEdit.Utils; namespace ICSharpCode.AvalonEdit.Highlighting { /// /// Represents a highlighted document. /// /// This interface is used by the to register the highlighter as a TextView service. public interface IHighlighter { /// /// Gets the underlying text document. /// TextDocument Document { get; } /// /// Gets the span stack at the end of the specified line. /// -> GetSpanStack(1) returns the spans at the start of the second line. /// /// GetSpanStack(0) is valid and will always return the empty stack. ImmutableStack GetSpanStack(int lineNumber); /// /// Highlights the specified document line. /// /// The line to highlight. /// A line object that represents the highlighted sections. HighlightedLine HighlightLine(int lineNumber); } }