Пример #1
0
 /// <summary>Visits the provided <paramref name="preformattedBlock"/> element.</summary>
 /// <param name="preformattedBlock">The <see cref="PreformattedBlockElement"/> to visit.</param>
 protected internal override void Visit(PreformattedBlockElement preformattedBlock)
 {
     BeginElement("pre");
     BeginElementWithoutIndent("code");
     Write(preformattedBlock.PreformattedText);
     EndElementWithoutIndent();
     EndElementWithoutIndent();
 }
Пример #2
0
        public void EscapesHtmlSpecialCharactersForPreformattedBlock(string text, string expectedHtml)
        {
            var actualHtml = new PreformattedBlockElement(text).Accept(new HtmlWriterVisitor());

            Assert.Equal(expectedHtml, actualHtml);
        }
Пример #3
0
 /// <summary>Visits the provided <paramref name="preformattedBlock"/> element.</summary>
 /// <param name="preformattedBlock">The <see cref="PreformattedBlockElement"/> to visit.</param>
 protected internal abstract void Visit(PreformattedBlockElement preformattedBlock);