Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Stimulsoft Reports.NET discussion
Post Reply
iiror
Posts: 1
Joined: Sun Aug 27, 2023 5:08 pm

Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Post by iiror »

Hey,

I noticed an issue in the Stimulsoft.Reports.Engine.NetCore version 2023.3.2 that it cannot find a method from the SixLabors.Fonts-library.

It seems that the library has a dependency on SixLabors.Fonts >= 1.0.0-beta19, but I'm using another library with version 1.0.0 which might then be used for the report engine, instead of the beta version. There are some API changes between the beta and final version of SixLabors.Fonts, which probably breaks the report. Below is the full error message and stack trace. I also attached a screenshot of the API changes in SixLabors.Fonts.

Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure(System.String, SixLabors.Fonts.TextOptions)'.

System.MissingMethodException:
at Stimulsoft.Drawing.Graphics.MeasureString (Stimulsoft.Drawing, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Drawing.Graphics.MeasureString (Stimulsoft.Drawing, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Base.Drawing.StiTextDrawing.GetAdditionalSpaceSize (Stimulsoft.Base, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Base.Drawing.StiTextDrawing.MeasureString (Stimulsoft.Base, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Components.StiStandardTextRenderer.MeasureString (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Components.StiText.GetActualSize (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Components.StiContainerHelper.CheckSize (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiContainerV2Builder.InternalRender (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Components.StiComponent.InternalRender (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiEngine.InternalRenderBand (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiEngine.RenderBand (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderBand (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderMaster (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Components.StiDataBand.RenderMaster (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiPageHelper.RenderPage (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiRenderProviderV2.RenderReport (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiRenderProviderV2.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.Engine.StiReportV2Builder.RenderSingleReport (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.RenderReport (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
at Stimulsoft.Report.StiReport.Render (Stimulsoft.Report, Version=2023.3.2.0, Culture=neutral, PublicKeyToken=ebe6666cba19647a)
Attachments
Screenshot 2023-08-27 at 20.40.55.png
Screenshot 2023-08-27 at 20.40.55.png (113.67 KiB) Viewed 5426 times
Lech Kulikowski
Posts: 6271
Joined: Tue Mar 20, 2018 5:34 am

Re: Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Post by Lech Kulikowski »

Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.
#12322
kx197
Posts: 1
Joined: Tue Sep 05, 2023 8:37 am

Re: Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Post by kx197 »

If it helps:

There seems to be a clash with ClosedXml; when the latest version (0.102.1) is included, the error occurs as soon as one TextField is set to growable. However, downgrading to 0.102.0 (or removing the library) removes the error.
Lech Kulikowski
Posts: 6271
Joined: Tue Mar 20, 2018 5:34 am

Re: Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Post by Lech Kulikowski »

Hello,

Thank you for the information.
Lech Kulikowski
Posts: 6271
Joined: Tue Mar 20, 2018 5:34 am

Re: Method not found: 'SixLabors.Fonts.FontRectangle SixLabors.Fonts.TextMeasurer.Measure

Post by Lech Kulikowski »

Hello,

The issue is fixed. Please check the next release within a week or two.

Thank you.
Post Reply