DrawingUIProvider
Provides the shared visual lifecycle for inline drawing layout boxes, including hyperlink handling and clipping to section columns.
Definition
Namespace:Telerik.WinForms.Documents.UI.UIProviders
Assembly:Telerik.WinControls.RichTextEditor.dll
Syntax:
public abstract class DrawingUIProvider : HyperlinkUIProviderBase, IUIProvider
Inheritance: objectHyperlinkUIProviderBaseDrawingUIProvider
Implements:
Inherited Members
Constructors
Initializes a provider for the drawing layout box whose visual it manages.
public DrawingUIProvider(DrawingLayoutBox drawingBox)
The layout box that supplies the drawing bounds and associated inline.
Properties
Gets the drawing's control bounds, which the layer uses for viewport visibility.
public override RectangleF BoundingRectangle { get; }
Overrides:
Gets the update context most recently supplied to GetUIElements(UILayerUpdateContext).
public UILayerUpdateContext CurrentUpdateContext { get; }
Gets the layout box used to position and associate the drawing visual.
protected DrawingLayoutBox DrawingBox { get; }
Gets or sets the framework control that renders the drawing inside the provider's clipping container.
public FrameworkElement DrawingControl { get; set; }
Gets the inline associated with the drawing box, used by the base class for hyperlink interaction.
public override Inline HyperlinkInline { get; }
Overrides:
Gets whether the drawing box is a clone that requires the layer to replace this provider.
public override bool IsInvalidated { get; }
Overrides:
Gets whether the drawing layout box has been removed from the document layout.
public override bool IsRemoved { get; }
Overrides:
Gets or sets whether hyperlink handlers have been attached to the current drawing control.
protected bool IsUIElementRegisteredAsHyperlink { get; set; }
Gets the framework element used to render the drawing and receive hyperlink pointer interaction.
public override FrameworkElement UIElement { get; }
Overrides:
Methods
Positions the drawing relative to the current view and clips it to the section's columns when column layout is active.
public override void Arrange(UILayerUpdateContext uILayerUpdateContext)
The current section and view-offset information.
Overrides:
Creates the framework control that renders the drawing box; the result is retained for subsequent layer updates.
protected abstract FrameworkElement CreateDrawingControl()
The control to host as the drawing visual.
Stores context, creates the drawing control on first use or updates the retained control, and yields its clipping container.
public override IEnumerable<UIElement> GetUIElements(UILayerUpdateContext context)
The presenter, viewport, and object-pool state for this layer update.
Returns:IEnumerable<UIElement>
The container that hosts the drawing control and applies column clipping when needed.
Overrides:
Associates the control with the drawing box and attaches hyperlink handlers once when its inline is a hyperlink.
protected void RegisterControl(FrameworkElement result)
The control created for the drawing box.
Detaches hyperlink handlers, clears the drawing control's layout association, and releases the provider's visual references.
public override void ReleaseElements()
Overrides:
Refreshes a drawing control that has already been created when the layer requests its visual again.
protected abstract void UpdateRecycledUIElement()