menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class RulerSettings - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class RulerSettings

    Controls the visibility of horizontal and vertical rulers and allows customization of their appearance.

    Inheritance
    System.Object
    RulerSettings
    Namespace: Syncfusion.Blazor.Diagram
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class RulerSettings : OwningComponentBase
    Remarks

    It manages the visibility of horizontal and vertical rulers within the diagram. Additionally, it provides options to customize the appearance of these rulers.

    Examples
        <SfDiagramComponent Height="600px">
            <RulerSettings>
                <HorizontalRuler IsVisible = "true" Interval="7"  MarkerColor="red" TickAlignment="TickAlignment.RightAndBottom">
                </HorizontalRuler>
                <VerticalRuler IsVisible = "true" Interval="7"  MarkerColor = "blue" TickAlignment = "TickAlignment.RightAndBottom">
                </VerticalRuler>
            </RulerSettings>
        </SfDiagramComponent>

    Constructors

    RulerSettings()

    Declaration
    public RulerSettings()

    Properties

    ChildContent

    Gets or sets the child content of the RulerSettings.

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

    Accepts a RenderFragment that defines the content of the UI element.

    HorizontalRuler

    Gets or sets the appearance settings for the horizontal ruler.

    Declaration
    public HorizontalRuler HorizontalRuler { get; set; }
    Property Value
    Type
    HorizontalRuler
    Remarks

    This property allows customization of appearance of the horizontal ruler.

    Examples
        <SfDiagramComponent Height = "600px">
            <RulerSettings>
                <HorizontalRuler IsVisible = "true" Interval="7"  MarkerColor="red" TickAlignment="TickAlignment.RightAndBottom">
                </HorizontalRuler>
            </RulerSettings>
        </SfDiagramComponent>

    VerticalRuler

    Gets or sets the appearance settings for the vertical ruler.

    Declaration
    public VerticalRuler VerticalRuler { get; set; }
    Property Value
    Type
    VerticalRuler
    Remarks

    This property allows customization of appearance of the vertical ruler.

    Examples
     
    
        <SfDiagramComponent Height = "600px">
            <RulerSettings> 
                <VerticalRuler IsVisible = "true" Interval="7"  MarkerColor = "blue" TickAlignment = "TickAlignment.RightAndBottom"> 
                </VerticalRuler> 
            </RulerSettings> 
        </SfDiagramComponent> 

    Methods

    BuildRenderTree(RenderTreeBuilder)

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

    OnAfterRenderAsync(Boolean)

    Method invoked after each time the component has been rendered.

    Declaration
    protected override Task OnAfterRenderAsync(bool firstRender)
    Parameters
    Type Name Description
    System.Boolean firstRender

    Set to true for the first time component rendering; otherwise gets false.

    Returns
    Type
    System.Threading.Tasks.Task

    OnInitializedAsync()

    Method invoked when the component is ready to start.

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

    A System.Threading.Tasks.Task representing any asynchronous operation.

    OnParametersSetAsync()

    Method invoked when any changes in component state occur.

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

    ="Task".

    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved