How do I change the accent colour of a Xamarin.Forms UWP application?

前端 未结 2 662
迷失自我
迷失自我 2021-01-20 05:42

I am developing a Xamarin.Forms UWP application.

I am struggling to set the accent colour of my application. This is the colour that is used for certain

2条回答
  •  粉色の甜心
    2021-01-20 06:42

    You can define a style setter property in App.xaml

            
            
        
    

    Then use CustomRenderer for the controls you need to change colors

        protected override void OnElementChanged(ElementChangedEventArgs

    in a similar way you would be able to use Themed Resource Dictionary key and apply. This code can be used to have native styles on Xamarin's control.

提交回复
热议问题