alexa
menu

MAUI Toolkit

  • User Guide
  • Demos
  • Support

    Show / Hide Table of Contents

    Class SparkChartLabelStyle

    Represents the label style for SparkChart trackball labels.

    Inheritance
    System.Object
    SparkChartLabelStyle
    Namespace: Syncfusion.Maui.Toolkit.SparkCharts
    Assembly: Syncfusion.Maui.Toolkit.dll
    Syntax
    public class SparkChartLabelStyle : Element, ITextElement, IThemeElement
    Remarks

    This class provides properties to customize the appearance of trackball labels in SparkCharts.

    TextColor - To customize the text color, refer to this TextColor property.

    Background - To customize the background color, refer to this Background property.

    Stroke - To customize the stroke color, refer to this Stroke property.

    StrokeWidth - To modify the stroke width, refer to this StrokeWidth property.

    FontSize - To change the text size for labels, refer to this FontSize property.

    FontFamily - To change the font family for labels, refer to this FontFamily property.

    FontAttributes - To change the font attributes for labels, refer to this FontAttributes property.

    Margin - To adjust the outer margin for labels, refer to this Margin property.

    LabelFormat - To customize the label format for labels, refer to this LabelFormat property.

    CornerRadius - To defines the rounded corners for labels, refer to this Microsoft.Maui.CornerRadius property.

    Constructors

    SparkChartLabelStyle()

    Declaration
    public SparkChartLabelStyle()

    Fields

    BackgroundProperty

    Identifies the Background bindable property.

    Declaration
    public static readonly BindableProperty BackgroundProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the Background bindable property determines the background brush of the trackball label.

    FontAttributesProperty

    Identifies the FontAttributes bindable property.

    Declaration
    public static readonly BindableProperty FontAttributesProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the FontAttributes bindable property determines the font attributes (e.g., bold, italic) used in the trackball label.

    FontFamilyProperty

    Identifies the FontFamily bindable property.

    Declaration
    public static readonly BindableProperty FontFamilyProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the FontFamily bindable property determines the font family used in the trackball label.

    FontSizeProperty

    Identifies the FontSize bindable property.

    Declaration
    public static readonly BindableProperty FontSizeProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the FontSize bindable property determines the size of the font used in the trackball label.

    LabelFormatProperty

    Identifies the LabelFormat bindable property.

    Declaration
    public static readonly BindableProperty LabelFormatProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the LabelFormat bindable property determines the format string used for the trackball label.

    MarginProperty

    Identifies the Margin bindable property.

    Declaration
    public static readonly BindableProperty MarginProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the Margin bindable property determines the margin around the trackball label.

    StrokeProperty

    Identifies the Stroke bindable property.

    Declaration
    public static readonly BindableProperty StrokeProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the Stroke bindable property determines the brush used for the stroke around the trackball label.

    StrokeWidthProperty

    Identifies the StrokeWidth bindable property.

    Declaration
    public static readonly BindableProperty StrokeWidthProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the StrokeWidth bindable property determines the stroke width around the trackball label.

    TextColorProperty

    Identifies the TextColor bindable property.

    Declaration
    public static readonly BindableProperty TextColorProperty
    Field Value
    Type
    Microsoft.Maui.Controls.BindableProperty
    Remarks

    The identifier for the TextColor bindable property determines the color of the text in the trackball label.

    Properties

    Background

    Gets or sets a value to customize the appearance of the label's background.

    Declaration
    public Brush Background { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    It accepts Microsoft.Maui.Controls.Brush values and the default value is Microsoft.Maui.Graphics.Colors.Black.

    FontAttributes

    Gets or sets a value that indicates the font attributes of the label.

    Declaration
    public FontAttributes FontAttributes { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.FontAttributes

    It accepts Microsoft.Maui.Controls.FontAttributes values and the default value is Microsoft.Maui.Controls.FontAttributes.None.

    FontFamily

    Gets or sets a value that indicates the font family of the label.

    Declaration
    public string FontFamily { get; set; }
    Property Value
    Type Description
    System.String

    It accepts System.String values and the default value is System.String.Empty.

    FontSize

    Gets or sets a value that indicates the label's font size.

    Declaration
    public double FontSize { get; set; }
    Property Value
    Type Description
    System.Double

    It accepts System.Double values and the default value is 12.

    Remarks

    The value must be greater than zero.

    LabelFormat

    Gets or sets a value to customize the label's format.

    Declaration
    public string LabelFormat { get; set; }
    Property Value
    Type Description
    System.String

    It accepts System.String values and the default value is System.String.Empty.

    Margin

    Gets or sets a value that indicates the margin of the label.

    Declaration
    public Thickness Margin { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Thickness

    It accepts Microsoft.Maui.Thickness values and the default value is 4.

    Stroke

    Gets or sets a value to customize the outer stroke appearance of the label.

    Declaration
    public Brush Stroke { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    It accepts Microsoft.Maui.Controls.Brush values and the default value is Microsoft.Maui.Controls.Brush.Transparent.

    StrokeWidth

    Gets or sets a value that indicates the stroke thickness of the label.

    Declaration
    public double StrokeWidth { get; set; }
    Property Value
    Type Description
    System.Double

    It accepts System.Double values and the default value is 0.

    Remarks

    The value needs to be greater than zero.

    TextColor

    Gets or sets a value to customize the appearance of the label's text color.

    Declaration
    public Color TextColor { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Graphics.Color

    It accepts Microsoft.Maui.Graphics.Color values and the default value is Microsoft.Maui.Graphics.Colors.White.

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