Search
DiagramView.ZoomToRect Method (Rect, Boolean)
See Also
 





Zooms and scrolls the view to fit the specified diagram rectangle in the viewport.

Namespace: MindFusion.Diagramming.Wpf
Assembly: MindFusion.Diagramming.Wpf

 Syntax

C#  Copy Code

public void ZoomToRect (
    Rect rect,
    bool centered
)

Visual Basic  Copy Code

Public Sub ZoomToRect( _
    rect As Rect, _
    centered As Boolean _
)

 Parameters

rect

A Rect instance specifying viewport position and size.

centered

true to center the specified rectangle in new viewport, or false to align top-left corners.

 Remarks

The scroll position and zoom factor of the DiagramView are set so that specified rectangular area of the diagram is entirely visible in the viewport.

 See Also