Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update SkiaSharp to the latest stable version (2.88.6) #17558

Merged
merged 1 commit into from
Sep 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 45 additions & 1 deletion eng/Microsoft.Extensions.targets
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
<Project>
<ItemGroup>
<PackageReference
Update="HarfBuzzSharp"
Version="$(_HarfBuzzSharpVersion)"
/>
<PackageReference
Update="HarfBuzzSharp.NativeAssets.Linux"
Version="$(_HarfBuzzSharpVersion)"
/>
<PackageReference
Update="HarfBuzzSharp.NativeAssets.macOS"
Version="$(_HarfBuzzSharpVersion)"
/>
<PackageReference
Update="HarfBuzzSharp.NativeAssets.Win32"
Version="$(_HarfBuzzSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.HarfBuzz"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.Extended"
Version="$(_SkiaSharpExtendedVersion)"
/>
<PackageReference
Update="SkiaSharp"
Version="$(_SkiaSharpVersion)"
Expand All @@ -8,12 +32,32 @@
Update="SkiaSharp.Views"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.Views.Gtk3"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.Views.WinUI"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.HarfBuzz"
Update="SkiaSharp.Views.WPF"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.NativeAssets.Linux"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.NativeAssets.Linux.NoDependencies"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.NativeAssets.macOS"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Update="SkiaSharp.NativeAssets.Win32"
Version="$(_SkiaSharpVersion)"
/>
<PackageReference
Expand Down
7 changes: 4 additions & 3 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,10 @@
- Feed URI in the nuget.config
- Native assets build and sha
-->
<_SkiaSharpVersion>2.88.2</_SkiaSharpVersion>
<_HarfBuzzSharpVersion>2.8.2.2</_HarfBuzzSharpVersion>
<_SkiaSharpNativeAssetsVersion>0.0.0-commit.193b587552cb0ed39372a049d7e6c692db98c267.483</_SkiaSharpNativeAssetsVersion>
<_SkiaSharpVersion>2.88.6</_SkiaSharpVersion>
<_SkiaSharpExtendedVersion>2.0.0-preview.86</_SkiaSharpExtendedVersion>
<_HarfBuzzSharpVersion>7.3.0</_HarfBuzzSharpVersion>
<_SkiaSharpNativeAssetsVersion>0.0.0-commit.e2c5c86249621857107c779af0f79b4d06613766.655</_SkiaSharpNativeAssetsVersion>
<MicrosoftTemplateEngineTasksVersion>7.0.100-preview.5.22226.1</MicrosoftTemplateEngineTasksVersion>
<MicrosoftDotNetXHarnessTestRunnersCommonVersion>8.0.0-prerelease.23431.1</MicrosoftDotNetXHarnessTestRunnersCommonVersion>
<MicrosoftDotNetXHarnessTestRunnersXunitVersion>8.0.0-prerelease.23431.1</MicrosoftDotNetXHarnessTestRunnersXunitVersion>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp" Version="2.88.0" />
<PackageReference Include="SkiaSharp" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp.NativeAssets.Linux" Version="2.88.0" />
<PackageReference Include="SkiaSharp.Views.Gtk3" Version="2.88.0" />
<PackageReference Include="SkiaSharp.NativeAssets.Linux" />
<PackageReference Include="SkiaSharp.Views.Gtk3" />
<PackageReference Include="GtkSharp" Version="3.24.24.34" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp" Version="2.88.0" />
<PackageReference Include="SkiaSharp.Views" Version="2.88.0" />
<PackageReference Include="SkiaSharp" />
<PackageReference Include="SkiaSharp.Views" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp.Views.WPF" Version="2.88.0" />
<PackageReference Include="SkiaSharp.Views.WPF" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp.Views.Gtk3" Version="2.88.0" />
<PackageReference Include="SkiaSharp.Views.Gtk3" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp.Views.WPF" Version="2.88.0" />
<PackageReference Include="SkiaSharp.Views.WPF" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@

<ItemGroup>
<!-- skiasharp and skia-related -->
<PackageReference Include="HarfBuzzSharp" Version="$(_HarfBuzzSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Linux" Version="$(_HarfBuzzSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Win32" Version="$(_HarfBuzzSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.macOS" Version="$(_HarfBuzzSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp" Version="$(_SkiaSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.Win32" Version="$(_SkiaSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.macOS" Version="$(_SkiaSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.Linux.NoDependencies" Version="$(_SkiaSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.HarfBuzz" Version="$(_SkiaSharpVersion)" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Linux" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Win32" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.macOS" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.Win32" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.macOS" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.NativeAssets.Linux.NoDependencies" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="SkiaSharp.HarfBuzz" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="Svg.Skia" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="Svg.Custom" GeneratePathProperty="true" PrivateAssets="all" />
<PackageReference Include="Svg.Model" GeneratePathProperty="true" PrivateAssets="all" />
Expand Down
10 changes: 10 additions & 0 deletions src/SingleProject/Resizetizer/src/SkiaSharpTools.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,16 @@ namespace Microsoft.Maui.Resizetizer
{
internal abstract class SkiaSharpTools
{
static SkiaSharpTools()
{
// DO NOT DELETE!
// Because we are doing dangerous things - like using a net462 assembly in a netstandard2.0 assembly
// we need to make sure the correct dependencies are loaded. We use net462 because this has special
// native library loading logic for the .NET Framework (Visual Studio).
var span = (Span<SKPoint>)new SKPoint[1];
span[0] = new SKPoint();
}

public static SkiaSharpTools Create(bool isVector, string filename, SKSize? baseSize, SKColor? backgroundColor, SKColor? tintColor, ILogger logger)
=> isVector
? new SkiaSharpSvgTools(filename, baseSize, backgroundColor, tintColor, logger) as SkiaSharpTools
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
<PackageReference Include="Microsoft.Build.Framework" Version="16.7.0" PrivateAssets="all" />
<PackageReference Include="Microsoft.Build.Utilities.Core" Version="16.7.0" PrivateAssets="all" />
<PackageReference Include="SkiaSharp" Version="$(_SkiaSharpVersion)" />
<PackageReference Include="SkiaSharp.Extended" Version="2.0.0-preview.61" />
<PackageReference Include="SkiaSharp" />
<PackageReference Include="SkiaSharp.Extended" />
<PackageReference Include="xunit" Version="2.5.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
<PackageReference Include="coverlet.collector" Version="6.0.0" />
Expand Down
Loading