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

Trying to get a Horizontal Y Axis Title. Why doesn’t this work?

<Style x:Key="AxisTitleStyle" TargetType="s:AxisTitle">
            <Setter Property="Orientation" Value="Horizontal" />
</Style>

...

        <s:SciChartSurface.YAxis>
            <s:NumericAxis AxisTitle="Axis Title" TitleStyle="{StaticResource AxisTitleStyle}"/>
        </s:SciChartSurface.YAxis>

Title is still Vertical.

  • You must to post comments
0
0

Hi Mike,

To rotate an Axis Title to horizontal, you will need to follow the steps from the KB Article Styling Axis Labels, Axis Titles, Rotating Axis Labels to template the AxisTitle, and include a LayoutTransform with Angle=90, like this:

   <Style x:Key="AxisTitleStyle" TargetType="s:AxisTitle">
       <Setter Property="LayoutTransform">
           <Setter.Value>
               <RotateTransform Angle="90"/>
           </Setter.Value>
       </Setter>
   </Style>
 
   <s:SciChartSurface.YAxis>
      <s:NumericAxis AxisTitle="Axis Title" TitleStyle="{StaticResource AxisTitleStyle}"/>
   </s:SciChartSurface.YAxis>

Let me know if this helps,

Best regards,
Andrew

  • You must to post comments
0
0

Yep, that worked, thanks.

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.