InvalidOperationException: A highlighting span matched 0 characters, which would cause an endless loop.
Change the highlighting definition so that either the start or the end regex matches at least one character.
Start regex:
(?<=(?<=([^\\]|^)(\\\\)*):\|)(?!.*(?<=([^\\]|^)(\\\\)*):\|\|\|)
End regex: ($|$
)
StackTrace:
在 ICSharpCode.AvalonEdit.Highlighting.HighlightingEngine.HighlightLineInternal()
在 ICSharpCode.AvalonEdit.Highlighting.HighlightingEngine.ScanLine(IDocument document, IDocumentLine line)
在 ICSharpCode.AvalonEdit.Highlighting.DocumentHighlighter.HighlightUpTo(Int32 targetLineNumber)
在 ICSharpCode.AvalonEdit.Highlighting.DocumentHighlighter.UpdateHighlightingState(Int32 lineNumber)
在 ICSharpCode.AvalonEdit.Highlighting.HighlightingColorizer.textView_VisualLineConstructionStarting(Object sender, VisualLineConstructionStartEventArgs e)
在 ICSharpCode.AvalonEdit.Rendering.TextView.CreateAndMeasureVisualLines(Size availableSize)
在 ICSharpCode.AvalonEdit.Rendering.TextView.MeasureOverride(Size availableSize)
在 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
在 System.Windows.UIElement.Measure(Size availableSize)
在 System.Windows.ContextLayoutManager.UpdateLayout()
在 System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
在 System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
在 System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
在 System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)
在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)