Xamarin Forms:如何为自定义字体设置 FontAttributes Bold

Xamarin Forms: How to set FontAttributes Bold for a custom font

我有一个使用 FontAwesome 的 Xamarin Forms 项目,请遵循此 link: http://forums.xamarin.com/discussion/31530/fontawesome-label-heres-how

效果很好。但是当我添加这段代码时:

myLabel.FontAttributes = FontAttributes.Bold;

图标变为带有“?”的矩形图像在里面。

我认为是因为我设置的自定义字体只是在普通字体属性中。如何在 Xamarin Forms 中为粗体属性设置字体?

好的,FontAwesome 不支持粗体。所以我必须使用普通的字体属性。