Set a custom default font for whole Xamarin.iOS app?

Published

I have a custom font that I want to set as the default font for the whole Xamarin.iOS app without specifying the size. How can I achieve this?

I already found a similar question here, however this refers to a non-Xamarin iOS app.

Source: Xamarin.ios Questions

Published
Categorised as Uncategorised Tagged , , , ,

Answers

You can subclass each control you want affected (Entry, Label) etc and add a custom property for size. From there create a custom renderer in iOS where you set the font to be used by all but also pass the custom property for size each type you call the control. Here is a blog article I wrote a while ago on this topic Making Custom Renderers in Xamarin.Forms More Scalable


Dr. Zelda Conn

Leave a Reply

Your email address will not be published. Required fields are marked *

Still Have Questions?


Our dedicated development team is here for you!

We can help you find answers to your question for as low as 5$.

Contact Us
faq