SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and now iOS Charting & Android Chart Components

Welcome to the SciChart Community Forums!

Please use the forums below to ask questions about SciChart. Take a moment to read our Question asking guidelines on how to ask a good question and our support policy. We also have a tag=SciChart on Stackoverflow.com where you can earn rep for your questions!

Please note: SciChart team will only answer questions from customers with active support subscriptions. Expired support questions will be ignored. If your support status shows incorrectly, contact us and we will be glad to help.

0
0

Hey guys,

A quick one; is there a way I can hide the tooltip that the RolloverModifier displays on the XAxis when it is in use? This has nothing to do with the regular RolloverTemplate tooltip or hit-testing data points.

Screenshot attached to be clear đŸ™‚

Thanks,
Miles

PS bonus question: can I style what it looks like? I might want to tweak the background colour or something later on, but for now just removing it for one of my Charts is the hurdle I need to jump over đŸ™‚

Images
  • You must to post comments
0
0

Yes, you can set ShowAxisLabels=False.

This was a requested feature so we added it in. To style the axis label you will need to set RolloverModifier.AxisLabelTemplate. An example can be found below:

    <DataTemplate x:Key="AxisLabelTemplate" DataType="r:AxisInfo">
        <Border Margin="1"
                Background="{Binding Path=CursorLabelBackgroundBrush,
                                     Source={x:Static s:ThemeManager.ThemeProvider}}"
                BorderBrush="{Binding Path=CursorLabelBorderBrush,
                                      Source={x:Static s:ThemeManager.ThemeProvider}}"
                BorderThickness="1"
                CornerRadius="2">
            <TextBlock Text="{Binding CursorFormattedDataValue}" />
        </Border>
    </DataTemplate>

Thanks!

Andrew

  • Diego Guerrero
    I followed this example and it works fine for templating the X-Axis label, but now the Y-Axis label is being displayed too (default behavior for Rollover is to show only on the X-Axis label).How do I disable or hide the Y-Axis after I changed the template for AxisLabelTemplate?
  • You must to post comments
0
0

Hi there,

You need to use the AxisInfoTemplateSelector object and an empty DataTemplate. The following code shows how AxisLabelTemplate is defined by default:

    <ControlTemplate x:Key="RolloverAxisLabelTemplate" TargetType="r:TemplatableControl">
        <s:AxisInfoTemplateSelector Content="{Binding}"
                                    XAxisDataTemplate="{StaticResource AxisLabelTemplate}"
                                    YAxisDataTemplate="{StaticResource EmptyDataTemplate}" />
    </ControlTemplate>

Please, try it and let us know if this helps!

Best regards,
Yuriy

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.