I'm trying to load a custom font by following your walkthrough , including the blog post it refers to, without success. I keep getting a null argument exception. Is anyone else having this issue? I'm using the PCL approach, not shared project. Repro steps for iOS are:
- Copy font to Resources folder in iOS project
- Set Build action to "BundleResource"
- Set copy to output directory to "Always copy"
- In the Source tab of Info.plist, add the "Fonts provided by application" key and add a string value of "Quicksand_Bold.otf" (in my case)
- Load the font
var bodyLabel = new Label
{
HorizontalOptions = LayoutOptions.CenterAndExpand,
VerticalOptions = LayoutOptions.CenterAndExpand,
Font = Device.OnPlatform (
Font.OfSize ("Quicksand_Bold", 15),
Font.SystemFontOfSize (NamedSize.Medium),
Font.SystemFontOfSize (NamedSize.Large)
)
};