We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Change default style of charts in App.xaml ResourceDictionary

how can i change the default appearance of syncfusion charts using the ResourceDictionary in the App.xaml file?


i tried some but this seems not to work:

 <Style TargetType="sfChart:DateTimeAxis">
                <Setter Property="LabelStyle">
                    <Setter.Value>
                        <sfChart:ChartAxisLabelStyle TextColor="Red"/>
                    </Setter.Value>
                </Setter>
            </Style>


            <Style TargetType="sfChart:SfCartesianChart">
                <Setter Property="sfChart:DateTimeAxis.LabelStyle">
                    <Setter.Value>
                        <sfChart:ChartAxisLabelStyle TextColor="Red" Stroke="red" FontSize="35"/>
                    </Setter.Value>
                </Setter>
            </Style>

can you give me some directions?


I need to change, LabelColors, Grid Lines colors


2 Replies

RR Raja Ramalingam Syncfusion Team January 3, 2023 12:36 PM UTC

Hi Andreas,

Styles from resources will not work with the chart and its elements because they are not implemented by element. However, we recommend applying inline styles directly to the chart. And we are planning to provide theme key support for .NET MAUI chart control, which will be available in our upcoming releases.


Regards,

Raja.



RR Raja Ramalingam Syncfusion Team January 10, 2023 06:29 AM UTC

Hi Andreas,

We are pleased to inform you that we have considered adding theme key support for MAUI controls in our 2023 plan. You can find more information about our 2023 roadmap at the following link: https://www.syncfusion.com/blogs/post/syncfusion-net-maui-2023-roadmap.aspx.

You can check on the status of this request through the following feedback portal link: https://www.syncfusion.com/feedback/40265/implement-the-theme-support-for-net-maui-controls. And you can leave comments in the feedback portal if you have any further specifications or suggestions for this feature request.


Regards,

Raja.


Loader.
Live Chat Icon For mobile
Up arrow icon