Skip to content

Commit

Permalink
Merge pull request #326 from SixLabors/js/update-refs
Browse files Browse the repository at this point in the history
Update Fonts to v2.0.3 and ImageSharp to v3.1.4
  • Loading branch information
JimBobSquarePants authored Apr 15, 2024
2 parents 6b62e73 + 6bca16c commit c8ae268
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions src/ImageSharp.Drawing/ImageSharp.Drawing.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@
<None Include="..\..\shared-infrastructure\branding\icons\imagesharp.drawing\sixlabors.imagesharp.drawing.128.png" Pack="true" PackagePath="" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="SixLabors.Fonts" Version="2.0.1" />
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.3" />
<PackageReference Include="SixLabors.Fonts" Version="2.0.3" />
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.4" />
</ItemGroup>
<Import Project="..\..\shared-infrastructure\src\SharedInfrastructure\SharedInfrastructure.projitems" Label="Shared" />
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -451,8 +451,8 @@ public void CanRotateFilledFont_Issue175<TPixel>(
AffineTransformBuilder builder = new AffineTransformBuilder().AppendRotationDegrees(angle);

RichTextOptions textOptions = new(font);
FontRectangle bounds = TextMeasurer.MeasureSize(text, textOptions);
Matrix3x2 transform = builder.BuildMatrix(Rectangle.Round(new RectangleF(bounds.X, bounds.Y, bounds.Width, bounds.Height)));
FontRectangle advance = TextMeasurer.MeasureAdvance(text, textOptions);
Matrix3x2 transform = builder.BuildMatrix(Rectangle.Round(new RectangleF(advance.X, advance.Y, advance.Width, advance.Height)));

provider.RunValidatingProcessorTest(
x => x.SetDrawingTransform(transform).DrawText(textOptions, text, Color.Black),
Expand All @@ -478,8 +478,8 @@ public void CanRotateOutlineFont_Issue175<TPixel>(
AffineTransformBuilder builder = new AffineTransformBuilder().AppendRotationDegrees(angle);

RichTextOptions textOptions = new(font);
FontRectangle bounds = TextMeasurer.MeasureSize(text, textOptions);
Matrix3x2 transform = builder.BuildMatrix(Rectangle.Round(new RectangleF(bounds.X, bounds.Y, bounds.Width, bounds.Height)));
FontRectangle advance = TextMeasurer.MeasureAdvance(text, textOptions);
Matrix3x2 transform = builder.BuildMatrix(Rectangle.Round(new RectangleF(advance.X, advance.Y, advance.Width, advance.Height)));

provider.RunValidatingProcessorTest(
x => x.SetDrawingTransform(transform)
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit c8ae268

Please sign in to comment.