Version

Final Value Layer

Topic Overview

Purpose

This topic provides information about the final value layer used for hover interactions. It describes the properties of the final value layer and provides an example of its implementation.

Required background

The following topics are prerequisites to understanding this topic:

Topic Purpose

The XamDataChart control requires a data object model to be mapped to control’s DataContext property. This article will provide a simple data object model but you can create your own and use it with this sample code instead.

This topic explains various types of Category Series in the XamDataChart control.

In this topic

This topic contains the following sections:

Overview

Final Value Layer Overview

The FinalValueLayer displays annotations along the chart’s axes that represent the final value of a series on the XamDataChart control.

You can configure the annotations to target a specific series if you want to have multiple final value layers present with different configurations. This can be done be setting the TargetSeries property. For more information on this property, see the Properties section below.

Preview

The following image is a preview of the XamDataChart control with the FinalValueLayer added.

datachart finalvaluelayer wpf.png

Properties

Final Value Layer Summary

The following table summarizes the properties of the FinalValueLayer layer.

Property Name Property Type Description

FinalValueSelectionMode

The selection mode determines how the final value is identified in your data.

Series

Gets or sets the series to target this annotation to. If null, this annotation targets all series simultaneously.

Brush

This property is used to choose the brush for the annotation’s background color. The default is to use the series brush.

Brush

This property is used to choose the brush for the annotation’s text’s color.

Brush

This property is used to choose the brush for the annotation’s outline color.

Example

Following is the code used in the screenshot above.

In XAML:

<ig:XamDataChart x:Name="theChart" Margin="5,0,5,0" >
   <ig:XamDataChart.Axes>
      <ig:CategoryXAxis x:Name="xmCategoryXAxis"
                        ItemsSource="{StaticResource CategoryData1}"
                        Label="{}{Category}">
         <ig:CategoryXAxis.LabelSettings>
      </ig:CategoryXAxis>
      <ig:NumericYAxis x:Name="xmNumericYAxis1">
      </ig:NumericYAxis>
   </ig:XamDataChart.Axes>
   <ig:XamDataChart.Series>
      <ig:ColumnSeries x:Name="columnSeries"
                       ItemsSource="{StaticResource CategoryData1}"
                       ValueMemberPath="Value"
                       XAxis="{Binding ElementName=xmCategoryXAxis}"
                       YAxis="{Binding ElementName=xmNumericYAxis1}">
      </ig:ColumnSeries>
      <ig:LineSeries x:Name="lineSeries"
                     ItemsSource="{StaticResource CategoryData2}"
                     ValueMemberPath="Value"
                     XAxis="{Binding ElementName=xmCategoryXAxis}"
                     YAxis="{Binding ElementName=xmNumericYAxis1}">
      </ig:LineSeries>

      <ig:FinalValueLayer TargetSeries="{Binding ElementName=lineSeries}"/>
   </ig:XamDataChart.Series>
</ig:XamDataChart>

In C#:

var finalValue = new FinalValueLayer();
finalValue.TargetSeries = theChart.Series[0];
theChart.Series.Add(finalValue);
Topic Purpose

This topic provides information about the properties and methods that the hover interaction feature uses for highlighting, hovering and interacting with the tooltip interactions inherited from the Series class.

This topic provides information about the crosshair layer used for hover interactions. It describes the properties of the crosshair layer and provides an implementation example.

This topic provides information about the category item highlight layer used for hover interactions. It describes the properties of the category item highlight layer and provides an example of its implementation.

This topic provides information about the category tooltip layer used for hover interactions. It describes the properties of the category tooltip layer and provides an example of its implementation.

This topic provides information about the item tooltip layer which is used for hover interactions. It describes the properties of the item tooltip layer and also provides an example of its implementation.