Blazor

Upgrade Guide User Guide Demos Support Forums Download
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DiagramFitOptions - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class DiagramFitOptions

    Represents the diagram content that can fit into the diagram.

    Inheritance
    System.Object
    Syncfusion.Blazor.SfBaseComponent
    Syncfusion.Blazor.SfBaseExtension
    DiagramFitOptions
    Namespace: Syncfusion.Blazor.Diagrams
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class DiagramFitOptions : SfBaseExtension
    Examples
    <SfDiagram Height="600px" id="diagram">
        <DiagramPageSettings >
         <DiagramFitOptions CanFit = "true" Mode="FitModes.Width" CanZoomIn="true" Region="DiagramRegions.Content" ></DiagramFitOptions>
       </DiagramPageSettings>
    </SfDiagram>

    Constructors

    DiagramFitOptions()

    Declaration
    public DiagramFitOptions()

    Properties

    CanFit

    It allows the user to enable or disable the fit of diagram content while rendering. It'll be false by default.

    Declaration
    public bool CanFit { get; set; }
    Property Value
    Type Description
    System.Boolean

    CanZoomIn

    It allows the user to enable or disable the zooming, to insert the smaller content into the larger viewport.

    Declaration
    public bool CanZoomIn { get; set; }
    Property Value
    Type Description
    System.Boolean

    ChildContent

    Represents a segment of UI content, implemented.

    Declaration
    public RenderFragment ChildContent { get; set; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Components.RenderFragment

    CustomBounds

    Defines the custom region that can be fit into the viewport.

    Declaration
    public object CustomBounds { get; set; }
    Property Value
    Type Description
    System.Object

    jsProperty

    Declaration
    protected override string jsProperty { get; set; }
    Property Value
    Type Description
    System.String
    Overrides
    Syncfusion.Blazor.SfBaseExtension.jsProperty

    mainParent

    Declaration
    protected override SfBaseExtension mainParent { get; set; }
    Property Value
    Type Description
    Syncfusion.Blazor.SfBaseExtension
    Overrides
    Syncfusion.Blazor.SfBaseExtension.mainParent

    Margin

    Specifies the space around the diagram content. By default, it will be 25 from all sides.

    Declaration
    public DiagramFitOptionsMargin Margin { get; set; }
    Property Value
    Type Description
    DiagramFitOptionsMargin

    Mode

    Defines whether the diagram can fit within the viewport based on viewport width or viewport Height or page.

    Declaration
    public FitModes Mode { get; set; }
    Property Value
    Type Description
    FitModes
    Remarks
    The mode has the following three options. They are
    � Page
    � Width
    � Height
    By default, the Mode is set to Page.

    Region

    Defines the region that can be fit into the viewport.

    Declaration
    public DiagramRegions Region { get; set; }
    Property Value
    Type Description
    DiagramRegions
    Remarks
    The region has the following three options. They are
    � PageSettings
    � Content
    � CustomBounds
    By default, the region is set to PageSettings.

    Methods

    BuildRenderTree(RenderTreeBuilder)

    Declaration
    protected override void BuildRenderTree(RenderTreeBuilder __builder)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder __builder

    Dispose()

    Declaration
    public override void Dispose()
    Overrides
    Syncfusion.Blazor.SfBaseExtension.Dispose()

    GetJSNamespace()

    Declaration
    public string GetJSNamespace()
    Returns
    Type Description
    System.String

    Get the parent namespaces

    OnInitializedAsync()

    Declaration
    protected override Task OnInitializedAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task

    Returns asynchronous operation when the component is ready to start, having received its initial parameters from its parent in the render tree

    Overrides
    Syncfusion.Blazor.SfBaseComponent.OnInitializedAsync()

    OnParametersSetAsync()

    Declaration
    protected override Task OnParametersSetAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task

    Returns asynchronous operation when the component has received parameters from its parent in the render tree, and the incoming values have been assigned to properties

    updateChildProperties(String, Object)

    Declaration
    public void updateChildProperties(string key, object value)
    Parameters
    Type Name Description
    System.String key
    System.Object value
    Back to top Generated by DocFX
    Copyright © 2001 - 2021 Syncfusion Inc. All Rights Reserved