DocumentLayoutBox
Root of a document's layout tree; it measures and arranges the document's section boxes.
Definition
Namespace:Telerik.WinForms.Documents.Layout
Assembly:Telerik.WinControls.RichTextEditor.dll
Syntax:
public class DocumentLayoutBox : LayoutBox, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor
Inheritance: objectDisposableObjectRadObjectLayoutElementLayoutBoxDocumentLayoutBox...
Implements:
Inherited Members
Constructors
Creates the root layout box for a document.
public DocumentLayoutBox(RadDocument ownerDocument)
The document whose sections are laid out by this box.
Properties
Gets the document model represented by this root layout box.
public RadDocument AssociatedDocument { get; }
Gets whether layout boxes can be created from the document's section collection.
protected override bool CanCreateLayoutBoxesFromContent { get; }
Overrides:
Gets whether this box has its own visual representation. The document root is structural; its section children provide the visible content.
public override bool HasVisualRepresentation { get; }
Overrides:
Gets the document supplied when this root layout box was created.
public RadDocument OwnerDocument { get; }
Methods
Arranges sections consecutively, ensures the caret points to a leaf box, and notifies the document that arrangement is complete. When the document has many sections, their arrangement is dispatched in batches to worker tasks.
Creates a section layout box for each section in the owning document.
protected void CreateLayoutBoxesFromContent(LayoutElementCollection fragmentList)
The collection that receives the section boxes.
Cannot create another document root; a document has a single DocumentLayoutBox.
public override LayoutElement CreateLayoutElement()
This method does not return.
Exceptions: InvalidOperationExceptionA document root cannot be duplicated.
Overrides:
Measures each section and returns the maximum section width and the combined document height. The document's layout mode determines whether sections use page-sized or flow-sized constraints. The measure may be repeated when updating the notes cache invalidates the first result.
Re-measures using the previous measure constraint, then arranges using the previous arrange rectangle. Any dimension whose measure constraint was infinite is replaced with the newly measured desired size.
public void UpdateLayout()