Page 1 of 1

Update from 2022.2.6 to 2022.3.1

Posted: Wed Jun 22, 2022 6:08 am
by mrapi
Hi
I've updated today from 2022.2.6 to 2022.3.1 but in console got error
I've tested also github Blazor examples(I've updated to .NET 6) https://github.com/stimulsoft/Samples-B ... ebAssembly but the same error
thanks

Code: Select all

blazor.webassembly.js:1 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Invalid value for 'classFormat' 0. Should be '1' or '2'.
SixLabors.Fonts.InvalidFontFileException: Invalid value for 'classFormat' 0. Should be '1' or '2'.
   at SixLabors.Fonts.Tables.AdvancedTypographic.ClassDefinitionTable.Load(BigEndianBinaryReader reader, Int64 offset)
   at SixLabors.Fonts.Tables.AdvancedTypographic.GlyphDefinitionTable.Load(BigEndianBinaryReader reader)
   at SixLabors.Fonts.Tables.AdvancedTypographic.GlyphDefinitionTable.Load(FontReader reader)
   at SixLabors.Fonts.Tables.TableLoader.Load[GlyphDefinitionTable](FontReader reader)
   at SixLabors.Fonts.FontReader.TryGetTable[GlyphDefinitionTable]()
   at SixLabors.Fonts.StreamFontMetrics.LoadFont(FontReader reader)
   at SixLabors.Fonts.StreamFontMetrics.LoadFont(Stream stream)
   at SixLabors.Fonts.FontCollection.AddImpl(Stream stream, CultureInfo culture, FontDescription& description)
   at SixLabors.Fonts.FontCollection.Add(Stream stream, FontDescription& description)
   at SixLabors.Fonts.FontCollection.Add(Stream stream)
   at Stimulsoft.Drawing.Text.PrivateFontCollection.AddFontBytesInternal(Byte[] fontData)
   at Stimulsoft.Base.StiFontCollection.AddFontBytes(PrivateFontCollection collection, Byte[] fontData)
   at Stimulsoft.Base.Drawing.FontV..ctor(String name, Byte[] content, String extension, Boolean allowFileCache, String hash, PrivateFontCollection masterFontCollection)
   at Stimulsoft.Base.StiFontCollection.AddContentToCache(Byte[] content, String extension, String alias, Nullable`1 fontStyle, Boolean isResource)
   at Stimulsoft.Base.StiFontCollection.AddFontBytes(Byte[] content, String alias, Nullable`1 fontStyle)
   at Stimulsoft.Base.StiFontCollection.AddFontBase64(String fontBase64, String alias, Nullable`1 fontStyle)
   at Showing_a_Viewer_without_Toolbar.Pages.Index.OnInitializedAsync() in D:\downloads\Samples-Blazor-WebAssembly-main\Showing a Viewer without Toolbar\Pages\Index.razor:line 30
   at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync()

Re: Update from 2022.2.6 to 2022.3.1

Posted: Wed Jun 22, 2022 8:52 am
by Max Shamanov
Hello,

Please comment the following string

Code: Select all

//StiFontCollection.AddFontFile("Fonts/Microsoft Sans Serif.ttf", "Segoe UI");
Thank you.

Re: Update from 2022.2.6 to 2022.3.1

Posted: Wed Jun 22, 2022 11:30 am
by mrapi
Hi
it works
but the commented code is:

Code: Select all

  //var fontBase64 = "AAEAAAAVAQAABABQRFNJ ......
 // StiFontCollection.AddFontBase64(fontBase64, "Segoe UI");
thanks

Re: Update from 2022.2.6 to 2022.3.1

Posted: Wed Jun 22, 2022 12:33 pm
by Max Shamanov
Hello,

You are welcome!