SixLabors / Fonts

:black_nib: Font loading and layout library.
https://sixlabors.com/products/fonts
Other
306 stars 71 forks source link

MAUI.Android error: cant use FontCollection() add a font stream #324

Closed 3egirlsdream closed 1 year ago

3egirlsdream commented 1 year ago

Prerequisites

ImageSharp version

3.0.0.0

Other ImageSharp packages and versions

SixLabors.Fonts 1.0.0-beta19

Environment (Operating system, version and so on)

MAUI Android

.NET Framework version

.net 6

Description

Steps to Reproduce

Images

            SixLabors.Fonts.FontFamily? family = null;
            var stream = FileSystem.OpenAppPackageFileAsync("OpenSans-Regular.ttf").Result;
            var collection2 = new FontCollection();
            family = collection2.Add(stream);
JimBobSquarePants commented 1 year ago

You should raise any MAUI specific issues with that repository. ImageSharp and Fonts use standard .NET APIs.

3egirlsdream commented 1 year ago

You should raise any MAUI specific issues with that repository. ImageSharp and Fonts use standard .NET APIs.

you can find bug by those steps:

JimBobSquarePants commented 1 year ago

You need to understand. If MAUI has constraint you need to confirm them with the team responsible. None of the APIs used in this codebase are subject to platform restrictions. I.E it should run anywhere the >NET runtime is installable.