Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 77050

Altering dynamic base styles

$
0
0

Hi,

I’m using Xamarin.Forms 2.0 and would like to know if you can create a new style from a base style (as shown below) but vary the font size to be bigger or smaller than the base style font size. For example, below If I wanted to create a Big Title style that is 2 points bigger than the base title style, how would I do this?

Thanks!

Chris

            var BigTitleStyle = new Style(typeof(Label))
            {
                BaseResourceKey = Device.Styles.TitleStyleKey,
                Setters = {
            new Setter { Property = Label.TextColorProperty, Value = Color.Green,  }
        }
            };
            Application.Current.Resources.Add("BigTitleStyle", BigTitleStyle); // use the "AppStyle" key in the app

Viewing all articles
Browse latest Browse all 77050

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>