public EmbeddedFontProvider(Assembly assembly, string ns, FontProvider provider) { _assembly = assembly; _namespace = ns; _provider = provider; // Register application font resources RegisterFontResources(_assembly, _namespace); // Register Theme font resources RegisterFontResources(Theme.Assembly, Theme.Namespace); if (_provider != null) { _provider.FontChanged += (string baseUri, string familyName, FontWeight weight, FontStretch stretch, FontStyle style) => { _provider.RaiseFontChanged(baseUri, familyName, weight, stretch, style); }; } }