Beispiel #1
0
 /// <summary>
 /// Initializes a new instance of HtmlRenderer.
 /// </summary>
 public HtmlRenderer()
 {
     _contentRendererCollection = new ContentRendererCollection();
     _contentRendererCollection.AddRenderers(new List <IContentRenderer> {
         new ParagraphRenderer(_contentRendererCollection),
         new HyperlinkContentRenderer(_contentRendererCollection),
         new TextRenderer(),
         new HorizontalRulerContentRenderer(),
         new HeadingRenderer(_contentRendererCollection),
         new ListContentRenderer(_contentRendererCollection),
         new ListItemContentRenderer(_contentRendererCollection),
         new QuoteContentRenderer(_contentRendererCollection),
         new AssetRenderer(_contentRendererCollection),
         new NullContentRenderer()
     });
 }
Beispiel #2
0
 public HtmlRenderer(HtmlRendererOptions options)
 {
     options ??= new HtmlRendererOptions();
     _contentRendererCollection = new ContentRendererCollection();
     _contentRendererCollection.AddRenderers(new List <IContentRenderer> {
         new ParagraphRenderer(_contentRendererCollection),
         new HyperlinkContentRenderer(_contentRendererCollection),
         new TextRenderer(true),
         new HorizontalRulerContentRenderer(),
         new HeadingRenderer(_contentRendererCollection),
         new TableRenderer(_contentRendererCollection),
         new TableRowRenderer(_contentRendererCollection),
         new TableCellRenderer(_contentRendererCollection),
         new TableHeaderRenderer(_contentRendererCollection),
         new ListContentRenderer(_contentRendererCollection),
         new ListItemContentRenderer(_contentRendererCollection, options.ListItemOptions),
         new QuoteContentRenderer(_contentRendererCollection),
         new AssetRenderer(_contentRendererCollection),
         new NullContentRenderer()
     });
 }