3

I tried to do it this way:

<Label FontSize="10" FontAttributes="None" />
<Label FontSize="10" FontAttributes="Bold" />

However "Bold" makes the characters too dark and "None" makes them too light. Is there a way that I can change the font to something in between, using an iOS and Android CustomRenderer or something like that?

1
  • Hey,did you solv ethe issue? Feb 28, 2019 at 2:05

2 Answers 2

5

I would strongly suggest you should take a look at using custom fonts. Otherwise you might need to create custom renderer for both iOS & Android projects and try exposing font properties to the Forms layer.
It's quicker to use custom font.

Take a look at this step by step instructions from XamarinHelp

4

In your case what I have done is use custom fonts with my apps where I can have different variations of the font.

Let's use as example: Avenir Next Font Name. I would have:

Avenir+Next+Ultralight

Avenir+Next+Regular

Avenir+Next+Medium

Avenir+Next+Demi

Avenir+Next+Bold

Avenir+Next+Heavy

This will give you access to all the different weight of the font.

You will need to implement the custom fonts though.

I found this tutorial which does a really good job explaining how to do it.

Once implemented you will be able to assign the weight you prefer to your controls.

Hope this help.-

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.