Blazor

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

    Show / Hide Table of Contents

    Class TooltipRelativeMode

    The RelativeMode property of the tooltip defines whether the tooltip should be displayed around the object or at the mouse position.

    Inheritance
    System.Object
    TooltipRelativeMode
    Namespace: Syncfusion.Blazor.Diagrams
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public sealed class TooltipRelativeMode : Enum
    Remarks
    By default, the relative mode is set to Mouse.
    The following code snippet is an example that sets RelativeMode to the tooltip,
    Examples
    <SfDiagram Height="600px" Constraints="DiagramConstraints.Default | DiagramConstraints.Tooltip" Nodes="@NodeCollection">
    </SfDiagram>
    @code{
       public ObservableCollection<DiagramNode> NodeCollection { get; set; }
       protected override void OnInitialized()
       {
           NodeCollection = new ObservableCollection<DiagramNode>();
           DiagramNode Node = new DiagramNode()
           {
               Width = 100,
               Height = 100,
               OffsetX = 200,
               OffsetY = 200,
               Constraints = NodeConstraints.Default | NodeConstraints.Tooltip,
               Tooltip = new NodeTooltip()
               {
                   Content = "Node1",
                   //Sets to show tooltip around the element
                   RelativeMode = TooltipRelativeMode.Object
               }
           };
           NodeCollection.Add(Node);
       }
    }

    Fields

    Mouse

    Displays the tooltip at the mouse position when pointed.

    Declaration
    public const TooltipRelativeMode Mouse
    Field Value
    Type Description
    TooltipRelativeMode

    Object

    Displays the tooltip around the object when pointed.

    Declaration
    public const TooltipRelativeMode Object
    Field Value
    Type Description
    TooltipRelativeMode

    value__

    Declaration
    public int value__
    Field Value
    Type Description
    System.Int32
    Back to top Generated by DocFX
    Copyright © 2001 - 2022 Syncfusion Inc. All Rights Reserved