layout | title | description | platform | control | documentation |
---|---|---|---|---|---|
post |
Markers |
How to customize markers in Essential Xamarin.Forms Sparkline |
xamarin |
Sparkline |
ug |
Markers
are used to highlight the data point in SfLineSparkline
and SfAreaSparkline
. You can use the following properties to customize the appearance.
IsVisible
- used to change the visibility of the marker.Width
- used to change the width of the marker.Height
- used to change the height of the marker.Color
- used to change the color of the marker.
{% tabs %}
{% highlight xaml %}
<sparkline:SfLineSparkline ItemsSource="{Binding Data}"
YBindingPath="Performance">
sparkline:SfLineSparkline.Marker
<sparkline:MarkerBase IsVisible="True"
Width="15"
Height="15"/>
</sparkline:SfLineSparkline.Marker>
</sparkline:SfLineSparkline>
{% endhighlight %}
{% highlight c# %}
SfLineSparkline lineSparkline = new SfLineSparkline() { YBindingPath = "Performance", ItemsSource = viewModel.Data, Marker = new MarkerBase() { IsVisible = true, Width = 15, Height = 15 } };
{% endhighlight %}
{% endtabs %}