PeachBrackets

PeachBrackets.Building

DocumentBuildContext Class

What a document built in code (rather than parsed from HTML) is built with: the render context its styles resolve against, and the bookkeeping the pages built from it share.

public sealed class DocumentBuildContext

Inheritance System.Object → DocumentBuildContext

Remarks

Make one per document, then one DeclarativePage per page with CreatePage(). Nodes made through the context must not be mixed with another context’s.

Constructors  
DocumentBuildContext(RenderContext) Starts a build over renderContext.
Properties  
RenderContext The context the nodes’ styles are resolved against.
Methods  
CreatePage() Starts a page: a root node and the page-level settings that go with it. Whatever an earlier page left behind (the hidden wrappers of display: contents elements in the HTML fragments it spliced in) is dropped, since it belongs to a document already laid out.