Class LinearGaugeAnnotation
Defines the annotation element for an axis in linear gauge component.
Inherited Members
Namespace: Syncfusion.Blazor.LinearGauge
Assembly: Syncfusion.Blazor.dll
Syntax
public class LinearGaugeAnnotation : SfOwningComponentBase, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
Constructors
LinearGaugeAnnotation()
Declaration
public LinearGaugeAnnotation()
Properties
AxisIndex
Gets or sets the index value of the axis of the linear gauge.
Declaration
[Parameter]
public int AxisIndex { get; set; }
Property Value
| Type | Description |
|---|---|
| int | An integer representing the axis index. |
Remarks
This property determines which axis the annotation is associated with in a multiple-axes scenario.
AxisValue
Gets or sets the value on the axis where the annotation will be rendered.
Declaration
[Parameter]
public double AxisValue { get; set; }
Property Value
| Type | Description |
|---|---|
| double |
Remarks
This property specifies the axis value that the annotation corresponds to.
ChildContent
Gets or sets the content of the UI element.
Declaration
[Parameter]
public RenderFragment ChildContent { get; set; }
Property Value
| Type | Description |
|---|---|
| RenderFragment | A RenderFragment that represents the child content of the annotation. |
Remarks
It allows embedding custom elements or components within the annotation.
Content
Gets or sets the text content for the annotation.
Declaration
[Parameter]
public string Content { get; set; }
Property Value
| Type | Description |
|---|---|
| string | A string containing the text to be displayed in the annotation. |
Remarks
Use this string property to set simple text content for the annotation if templates are not needed.
ContentTemplate
Gets or sets the template content for the annotation.
Declaration
[Parameter]
public RenderFragment ContentTemplate { get; set; }
Property Value
| Type | Description |
|---|---|
| RenderFragment | A RenderFragment representing the template content of the annotation. |
Remarks
This property is used to customize the display of annotation using templates.
HorizontalAlignment
Gets or sets the horizontal alignment of the annotation.
Declaration
[Parameter]
public Placement HorizontalAlignment { get; set; }
Property Value
| Type | Description |
|---|---|
| Placement | A Placement enumeration value for horizontal alignment. Default is None. |
Remarks
This property controls how the annotation is horizontally aligned with respect to its defined position.
VerticalAlignment
Gets or sets the vertical alignment of the annotation.
Declaration
[Parameter]
public Placement VerticalAlignment { get; set; }
Property Value
| Type | Description |
|---|---|
| Placement | A Placement enumeration value for vertical alignment. Default is None. |
Remarks
This property determines the vertical alignment aspect of the annotation within the gauge.
X
Gets or sets the X-coordinate position for the annotation.
Declaration
[Parameter]
public double X { get; set; }
Property Value
| Type | Description |
|---|---|
| double | A double that specifies the horizontal offset of the annotation from its default position. |
Remarks
This property allows positioning the annotation horizontally within the gauge.
Y
Gets or sets the Y-coordinate position for the annotation.
Declaration
[Parameter]
public double Y { get; set; }
Property Value
| Type | Description |
|---|---|
| double | A double that specifies the vertical offset of the annotation from its default position. |
Remarks
This property allows positioning the annotation vertically within the gauge.
ZIndex
Gets or sets the Z-index of the annotation.
Declaration
[Parameter]
public string ZIndex { get; set; }
Property Value
| Type | Description |
|---|---|
| string | A string representing the Z-index property for layering annotations. Default is "-1". |
Remarks
This property helps in handling the stacking order of the annotation with respect to other components.
Methods
BuildRenderTree(RenderTreeBuilder)
Declaration
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
| Type | Name | Description |
|---|---|---|
| RenderTreeBuilder | __builder |
Overrides
Dispose(bool)
Disposes the property values during the destroy of the component that is hold up for the execution of the component.
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | disposing |
Overrides
OnInitializedAsync()
OnInitializedAsync method is called when the component has received its initial parameters.
Declaration
protected override Task OnInitializedAsync()
Returns
| Type | Description |
|---|---|
| Task | Task representing the asynchronous operation. |
Overrides
OnParametersSetAsync()
OnParametersSetAsync is a lifecycle method that is invoked when the component has received parameters, and the incoming values have been assigned to the properties.
Declaration
protected override Task OnParametersSetAsync()
Returns
| Type | Description |
|---|---|
| Task | Task representing the asynchronous operation. |