I'm developing a bar chart where when the label is selected I need to set the color of that label as well as call an event handler (a different one than what I have set up for the bar selection).
Is there a property that enables this, similar to the ChartSelectionBehavior? Starting with one of the examples I found (see XAML below) I've been able to get the bar selection working and I made the label change color on mouse over, but this isn't what I need - it needs to function more like the bar selection.
<UserControl x:Class="TelerikChartDemo.ChartUserControl2" xmlns:chart="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Chart" xmlns:charting="clr-namespace:Telerik.Charting;assembly=Telerik.Windows.Controls.Chart" xmlns:chartView="clr-namespace:Telerik.Windows.Controls.ChartView;assembly=Telerik.Windows.Controls.Chart" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" xmlns:local="clr-namespace:TelerikChartDemo" mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="300"> <UserControl.DataContext> <local:PerformanceViewModel /> </UserControl.DataContext> <UserControl.Resources> <Style x:Key="ItemLabelStyle" TargetType="TextBlock"> <Setter Property="Padding" Value="4"/> <Setter Property="Background" Value="LightBlue" /> <Setter Property="Foreground" Value="Black" /> <Style.Triggers> <Trigger Property="IsMouseOver" Value="True"> <Setter Property="Background" Value="Black" /> <Setter Property="Foreground" Value="White" /> <!--<Setter Property="FontSize" Value="13.333" /> <Setter Property="FontWeight" Value="Bold" />--> </Trigger> </Style.Triggers> </Style> </UserControl.Resources> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="6*" /> <ColumnDefinition Width="*" /> </Grid.ColumnDefinitions> <chart:RadCartesianChart x:Name="RadCartesianChart" Palette="Windows8" Margin="0,18,0,0"> <telerik:RadCartesianChart.Behaviors> <telerik:ChartSelectionBehavior DataPointSelectionMode="Single" SelectionChanged="ChartSelectionBehavior_Changed" /> </telerik:RadCartesianChart.Behaviors> <chartView:BarSeries ItemsSource="{Binding Q1}" ValueBinding="Performance" CategoryBinding="RepresentativeName" ShowLabels="{Binding ShowLabels, Mode=TwoWay}" CombineMode="{Binding BarCombineMode, Mode=TwoWay}" FontFamily="Segoe UI" FontSize="10"> </chartView:BarSeries> <chart:RadCartesianChart.HorizontalAxis> <chartView:CategoricalAxis FontFamily="Segoe UI" FontSize="12" GapLength="{Binding GapLength}" /> </chart:RadCartesianChart.HorizontalAxis> <chart:RadCartesianChart.VerticalAxis> <chartView:LinearAxis FontFamily="Segoe UI" FontSize="12" Title="{Binding AxisTitle}" Minimum="0" Maximum="{Binding AxisMaxValue}" LabelFormat="{Binding AxisLabelFormat}" /> </chart:RadCartesianChart.VerticalAxis> </chart:RadCartesianChart> </Grid></UserControl>
