I have a simple SciChart CompositeAnnotation:
<s:CompositeAnnotation x:Class="KernelDensity.DensityAnnotation"
xmlns:s="http://schemas.abtsoftware.co.uk/scichart"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Canvas.ZIndex="1" MouseDoubleClick="DensityAnnotation_OnMouseDoubleClick">
<s:CompositeAnnotation.Annotations>
<s:BoxAnnotation x:Name="DensityBoxArea" Background="#FFBADAFF" BorderBrush ="Black" BorderThickness="1" CoordinateMode="Relative" CornerRadius="1" Width="1" Height="1" Opacity="0.5" X1="0" X2="1" Y1="0" Y2="1" >
<s:BoxAnnotation.Template>
<ControlTemplate TargetType="s:BoxAnnotation">
<Border x:Name="PART_BoxAnnotationRoot"
Margin="{TemplateBinding Margin}"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="{TemplateBinding CornerRadius}">
<Image x:Name="DensityPlot" Width="Auto" Stretch="Fill"/>
</Border>
</ControlTemplate>
</s:BoxAnnotation.Template>
</s:BoxAnnotation>
<s:TextAnnotation x:Name="SelectedSeriesTextAnnotation"
Background="Black"
CoordinateMode="Relative"
CornerRadius="3"
Foreground="White"
HorizontalAnchorPoint="Center"
X1="0.5"
Y1="0.5"
FontSize="14"
Text="{Binding SelectedSeriesTextAnnotationText}">
</s:TextAnnotation>
</s:CompositeAnnotation.Annotations>
<s:CompositeAnnotation.ToolTip >
<ToolTip Placement="Right">
<TextBlock Text="{Binding SelectedSeriesTextAnnotationText}" FontSize="15" Foreground="Black"/>
</ToolTip>
</s:CompositeAnnotation.ToolTip>
</s:CompositeAnnotation>
Here you can see that TextAnnotation-Text attribute and ToolTip-TextBlock-Text attribute have the same bindings to my view model property. The problem is that this binding works correctly for ToolTip TextBlock Text attribute, but doesn't work for TextAnnotation Text attribute (as if there is no binding at all). How can I fix this problem?