-
Notifications
You must be signed in to change notification settings - Fork 59
Typeface
Wiesław Šoltés edited this page Aug 26, 2022
·
3 revisions
var typefaceProvider = new CustomTypefaceProvider("font.ttf");
SvgTextExtensions.s_typefaceProviders.Insert(0, typefaceProvider);
var typefaceProvider = new CustomTypefaceProvider(stream);
SvgTextExtensions.s_typefaceProviders.Insert(0, typefaceProvider);
foreach (var typefaceProvider in SvgTextExtensions.s_typefaceProviders)
{
if (typefaceProvider is FontManagerTypefacerovider fontManagerTypefacerovider)
{
fontManagerTypefacerovider.CreateTypeface("font.ttf");
break;
}
}
foreach (var typefaceProvider in SvgTextExtensions.s_typefaceProviders)
{
if (typefaceProvider is FontManagerTypefacerovider fontManagerTypefacerovider)
{
fontManagerTypefacerovider..CreateTypeface(stream);
break;
}
}
https://github.com/wieslawsoltes/Svg.Skia/tree/master/src/Svg.Skia/TypefaceProviders