From 4e9a505aefd68882659af5c4f71aaf50af728151 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Sat, 8 May 2021 01:49:57 +0200 Subject: [PATCH 1/4] Update to .NET 5.0 (#1697) --- VERSIONS.txt | 1 + binding/Binding/SkiaApi.cs | 14 +------------- binding/HarfBuzzSharp.Shared/HarfBuzzApi.cs | 16 +--------------- binding/HarfBuzzSharp.Shared/NativeObject.cs | 2 +- .../HarfBuzzSharp.UWP/HarfBuzzSharp.UWP.csproj | 2 +- binding/HarfBuzzSharp/HarfBuzzSharp.csproj | 5 +---- binding/SkiaSharp.UWP/SkiaSharp.UWP.csproj | 1 - binding/SkiaSharp/SkiaSharp.csproj | 5 +---- nuget/SkiaSharp.Views.Desktop.Common.nuspec | 9 ++++++--- nuget/SkiaSharp.Views.WPF.nuspec | 6 +++--- nuget/SkiaSharp.Views.WindowsForms.nuspec | 6 +++--- .../Gtk3/SkiaSharpSample/SkiaSharpSample.csproj | 2 +- .../SkiaSharpSample/SkiaSharpSample.csproj | 2 +- .../WPF/SkiaSharpSample/SkiaSharpSample.csproj | 2 +- samples/Gallery/Xamarin.Forms/Core/Core.csproj | 1 - scripts/azure-pipelines.yml | 3 ++- scripts/azure-templates-bootstrapper.yml | 8 +++++++- .../SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz.csproj | 6 ------ .../SkiaSharp.Views.Forms.csproj | 1 - .../SkiaSharp.Views.Desktop.Common.csproj | 9 ++------- .../SkiaSharp.Views.Shared/Extensions.cs | 2 +- .../SkiaSharp.Views.WPF.csproj | 2 +- .../SkiaSharp.Views.WindowsForms.csproj | 2 +- .../SkiaSharp.Vulkan.SharpVk.csproj | 1 - .../SkiaSharp.NetCore.Tests.csproj | 6 +++--- .../SkiaSharp.Vulkan.NetCore.Tests.csproj | 5 ++--- tests/Tests/BaseTest.cs | 2 +- .../SkiaSharpGenerator/SkiaSharpGenerator.csproj | 2 +- utils/WasmTestRunner/WasmTestRunner.csproj | 2 +- 29 files changed, 44 insertions(+), 81 deletions(-) diff --git a/VERSIONS.txt b/VERSIONS.txt index 4be6006b3..ef9483e6e 100644 --- a/VERSIONS.txt +++ b/VERSIONS.txt @@ -19,6 +19,7 @@ GLibSharp release 3.22.24.37 AtkSharp release 3.22.24.37 System.Memory release 4.5.3 System.IO.UnmanagedMemoryStream release 4.3.0 +System.Drawing.Common release 4.5.1 SharpVk release 0.4.2 Uno.UI release 2.4.4 diff --git a/binding/Binding/SkiaApi.cs b/binding/Binding/SkiaApi.cs index 79032a2d4..a9bad6216 100644 --- a/binding/Binding/SkiaApi.cs +++ b/binding/Binding/SkiaApi.cs @@ -4,20 +4,8 @@ namespace SkiaSharp { internal partial class SkiaApi { -#if __TVOS__ && __UNIFIED__ +#if __IOS__ || __TVOS__ || __WATCHOS__ private const string SKIA = "@rpath/libSkiaSharp.framework/libSkiaSharp"; -#elif __WATCHOS__ && __UNIFIED__ - private const string SKIA = "@rpath/libSkiaSharp.framework/libSkiaSharp"; -#elif __IOS__ && __UNIFIED__ - private const string SKIA = "@rpath/libSkiaSharp.framework/libSkiaSharp"; -#elif __ANDROID__ - private const string SKIA = "libSkiaSharp.so"; -#elif __MACOS__ - private const string SKIA = "libSkiaSharp.dylib"; -#elif WINDOWS_UWP - private const string SKIA = "libSkiaSharp.dll"; -#elif __TIZEN__ - private const string SKIA = "libSkiaSharp.so"; #else private const string SKIA = "libSkiaSharp"; #endif diff --git a/binding/HarfBuzzSharp.Shared/HarfBuzzApi.cs b/binding/HarfBuzzSharp.Shared/HarfBuzzApi.cs index 719525c61..36983e29f 100644 --- a/binding/HarfBuzzSharp.Shared/HarfBuzzApi.cs +++ b/binding/HarfBuzzSharp.Shared/HarfBuzzApi.cs @@ -4,22 +4,8 @@ namespace HarfBuzzSharp { internal unsafe partial class HarfBuzzApi { -#if __TVOS__ && __UNIFIED__ +#if __IOS__ || __TVOS__ || __WATCHOS__ private const string HARFBUZZ = "__Internal"; -#elif __WATCHOS__ && __UNIFIED__ - private const string HARFBUZZ = "__Internal"; -#elif __IOS__ && __UNIFIED__ - private const string HARFBUZZ = "__Internal"; -#elif __ANDROID__ - private const string HARFBUZZ = "libHarfBuzzSharp.so"; -#elif __MACOS__ - private const string HARFBUZZ = "libHarfBuzzSharp.dylib"; -#elif __DESKTOP__ - private const string HARFBUZZ = "libHarfBuzzSharp"; -#elif WINDOWS_UWP - private const string HARFBUZZ = "libHarfBuzzSharp.dll"; -#elif NET_STANDARD - private const string HARFBUZZ = "libHarfBuzzSharp"; #else private const string HARFBUZZ = "libHarfBuzzSharp"; #endif diff --git a/binding/HarfBuzzSharp.Shared/NativeObject.cs b/binding/HarfBuzzSharp.Shared/NativeObject.cs index f292f172c..a881a31c4 100644 --- a/binding/HarfBuzzSharp.Shared/NativeObject.cs +++ b/binding/HarfBuzzSharp.Shared/NativeObject.cs @@ -62,7 +62,7 @@ namespace HarfBuzzSharp internal static int SizeOf () { -#if WINDOWS_UWP || NET_STANDARD +#if WINDOWS_UWP || NETSTANDARD || NET5_0_OR_GREATER return Marshal.SizeOf (); #else return Marshal.SizeOf (typeof (T)); diff --git a/binding/HarfBuzzSharp.UWP/HarfBuzzSharp.UWP.csproj b/binding/HarfBuzzSharp.UWP/HarfBuzzSharp.UWP.csproj index e7a1a287b..2a3e5eed9 100644 --- a/binding/HarfBuzzSharp.UWP/HarfBuzzSharp.UWP.csproj +++ b/binding/HarfBuzzSharp.UWP/HarfBuzzSharp.UWP.csproj @@ -4,7 +4,7 @@ HarfBuzzSharp HarfBuzzSharp HarfBuzzSharp - $(DefineConstants);NET_STANDARD;HARFBUZZ + $(DefineConstants);HARFBUZZ diff --git a/binding/HarfBuzzSharp/HarfBuzzSharp.csproj b/binding/HarfBuzzSharp/HarfBuzzSharp.csproj index 5f09b45d1..79747dfc5 100644 --- a/binding/HarfBuzzSharp/HarfBuzzSharp.csproj +++ b/binding/HarfBuzzSharp/HarfBuzzSharp.csproj @@ -6,11 +6,8 @@ HarfBuzzSharp $(DefineConstants);HARFBUZZ - - $(DefineConstants);NET_STANDARD - - $(DefineConstants);USE_DELEGATES;__DESKTOP__ + $(DefineConstants);USE_DELEGATES diff --git a/binding/SkiaSharp.UWP/SkiaSharp.UWP.csproj b/binding/SkiaSharp.UWP/SkiaSharp.UWP.csproj index 338b2a736..9895267c0 100644 --- a/binding/SkiaSharp.UWP/SkiaSharp.UWP.csproj +++ b/binding/SkiaSharp.UWP/SkiaSharp.UWP.csproj @@ -4,7 +4,6 @@ SkiaSharp SkiaSharp SkiaSharp - $(DefineConstants);NET_STANDARD diff --git a/binding/SkiaSharp/SkiaSharp.csproj b/binding/SkiaSharp/SkiaSharp.csproj index 1ccae6524..e8d9bc2ec 100644 --- a/binding/SkiaSharp/SkiaSharp.csproj +++ b/binding/SkiaSharp/SkiaSharp.csproj @@ -5,11 +5,8 @@ SkiaSharp SkiaSharp - - $(DefineConstants);NET_STANDARD - - $(DefineConstants);USE_DELEGATES;__DESKTOP__ + $(DefineConstants);USE_DELEGATES diff --git a/nuget/SkiaSharp.Views.Desktop.Common.nuspec b/nuget/SkiaSharp.Views.Desktop.Common.nuspec index a928724af..af668fc71 100644 --- a/nuget/SkiaSharp.Views.Desktop.Common.nuspec +++ b/nuget/SkiaSharp.Views.Desktop.Common.nuspec @@ -29,12 +29,15 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release + - + + + @@ -44,8 +47,8 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - - + + diff --git a/nuget/SkiaSharp.Views.WPF.nuspec b/nuget/SkiaSharp.Views.WPF.nuspec index 3949fb9cf..43f1257a2 100644 --- a/nuget/SkiaSharp.Views.WPF.nuspec +++ b/nuget/SkiaSharp.Views.WPF.nuspec @@ -31,7 +31,7 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - + @@ -41,8 +41,8 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - - + + diff --git a/nuget/SkiaSharp.Views.WindowsForms.nuspec b/nuget/SkiaSharp.Views.WindowsForms.nuspec index 305b7c924..8d53db080 100644 --- a/nuget/SkiaSharp.Views.WindowsForms.nuspec +++ b/nuget/SkiaSharp.Views.WindowsForms.nuspec @@ -33,7 +33,7 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - + @@ -47,8 +47,8 @@ Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release - - + + diff --git a/samples/Basic/Gtk3/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/Gtk3/SkiaSharpSample/SkiaSharpSample.csproj index c745786e6..a76a3f730 100644 --- a/samples/Basic/Gtk3/SkiaSharpSample/SkiaSharpSample.csproj +++ b/samples/Basic/Gtk3/SkiaSharpSample/SkiaSharpSample.csproj @@ -2,7 +2,7 @@ WinExe - netcoreapp3.0 + netcoreapp3.1 8.0 diff --git a/samples/Basic/NetCore/Console/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/NetCore/Console/SkiaSharpSample/SkiaSharpSample.csproj index 64e7334f4..e9f16c2b8 100644 --- a/samples/Basic/NetCore/Console/SkiaSharpSample/SkiaSharpSample.csproj +++ b/samples/Basic/NetCore/Console/SkiaSharpSample/SkiaSharpSample.csproj @@ -2,7 +2,7 @@ Exe - netcoreapp3.0 + netcoreapp3.1 8.0 diff --git a/samples/Basic/NetCore/WPF/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/NetCore/WPF/SkiaSharpSample/SkiaSharpSample.csproj index 7d0f8353b..44310b7c3 100644 --- a/samples/Basic/NetCore/WPF/SkiaSharpSample/SkiaSharpSample.csproj +++ b/samples/Basic/NetCore/WPF/SkiaSharpSample/SkiaSharpSample.csproj @@ -2,7 +2,7 @@ WinExe - netcoreapp3.0 + netcoreapp3.1 true 8.0 icon.ico diff --git a/samples/Gallery/Xamarin.Forms/Core/Core.csproj b/samples/Gallery/Xamarin.Forms/Core/Core.csproj index 3b4851e80..6e4d3be4b 100644 --- a/samples/Gallery/Xamarin.Forms/Core/Core.csproj +++ b/samples/Gallery/Xamarin.Forms/Core/Core.csproj @@ -2,7 +2,6 @@ netstandard2.0 - $(DefineConstants);NET_STANDARD 8.0 diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index e1ca35610..3604d06ee 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -23,7 +23,8 @@ variables: MONO_VERSION_MACOS: 'Latest' MONO_VERSION_LINUX: '' XCODE_VERSION: 12.4 - DOTNET_VERSION: 3.1.405 + DOTNET_VERSION_PREVIOUS: 3.1.408 + DOTNET_VERSION: 5.0.202 CONFIGURATION: 'Release' VM_IMAGE_WINDOWS: windows-2019 VM_IMAGE_WINDOWS_PREVIOUS: vs2017-win2016 diff --git a/scripts/azure-templates-bootstrapper.yml b/scripts/azure-templates-bootstrapper.yml index 2cd23e089..f030fbac9 100644 --- a/scripts/azure-templates-bootstrapper.yml +++ b/scripts/azure-templates-bootstrapper.yml @@ -99,6 +99,12 @@ jobs: # install extra bits for the manged builds - ${{ if not(startsWith(parameters.name, 'native_')) }}: + - task: UseDotNet@2 + inputs: + packageType: 'sdk' + version: $(DOTNET_VERSION_PREVIOUS) + performMultiLevelLookup: true + displayName: Install the previous version of .NET Core - task: UseDotNet@2 inputs: packageType: 'sdk' @@ -189,7 +195,7 @@ jobs: # publish artifacts - task: PublishBuildArtifacts@1 displayName: Publish the ${{ parameters.name }} artifacts - condition: ${{ parameters.shouldPublish }} + condition: or(${{ parameters.shouldPublish }}, failed()) inputs: artifactName: ${{ parameters.name }} pathToPublish: 'output' diff --git a/source/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz.csproj b/source/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz.csproj index c6a8b9d62..754c43f35 100644 --- a/source/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz.csproj +++ b/source/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz.csproj @@ -5,12 +5,6 @@ SkiaSharp.HarfBuzz SkiaSharp.HarfBuzz - - $(DefineConstants);NET_STANDARD - - - $(DefineConstants);__DESKTOP__ - diff --git a/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.csproj b/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.csproj index 3cccef58f..bac6c17e3 100644 --- a/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.csproj +++ b/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.csproj @@ -5,7 +5,6 @@ SkiaSharp.Views.Forms false SkiaSharp.Views.Forms - $(DefineConstants);NET_STANDARD diff --git a/source/SkiaSharp.Views/SkiaSharp.Views.Desktop.Common/SkiaSharp.Views.Desktop.Common.csproj b/source/SkiaSharp.Views/SkiaSharp.Views.Desktop.Common/SkiaSharp.Views.Desktop.Common.csproj index 6c1a6c101..c9dad5d71 100644 --- a/source/SkiaSharp.Views/SkiaSharp.Views.Desktop.Common/SkiaSharp.Views.Desktop.Common.csproj +++ b/source/SkiaSharp.Views/SkiaSharp.Views.Desktop.Common/SkiaSharp.Views.Desktop.Common.csproj @@ -1,14 +1,9 @@  - netstandard2.0;net462;netcoreapp3.0 + netstandard2.0;net462;netcoreapp3.1 SkiaSharp.Views.Desktop SkiaSharp.Views.Desktop.Common SkiaSharp.Views.Desktop.Common - - - $(DefineConstants);__DESKTOP__;NET_STANDARD - - $(DefineConstants);__DESKTOP__ @@ -17,7 +12,7 @@ - + \ No newline at end of file diff --git a/source/SkiaSharp.Views/SkiaSharp.Views.Shared/Extensions.cs b/source/SkiaSharp.Views/SkiaSharp.Views.Shared/Extensions.cs index 5a5804862..b7319d122 100644 --- a/source/SkiaSharp.Views/SkiaSharp.Views.Shared/Extensions.cs +++ b/source/SkiaSharp.Views/SkiaSharp.Views.Shared/Extensions.cs @@ -106,7 +106,7 @@ namespace SkiaSharp.Views.Tizen return new System.Drawing.Size(size.Width, size.Height); } -#if __DESKTOP__ && !NET_STANDARD +#if __DESKTOP__ // System.Drawing.Bitmap diff --git a/source/SkiaSharp.Views/SkiaSharp.Views.WPF/SkiaSharp.Views.WPF.csproj b/source/SkiaSharp.Views/SkiaSharp.Views.WPF/SkiaSharp.Views.WPF.csproj index ab5c6b34c..cb1f84f2b 100644 --- a/source/SkiaSharp.Views/SkiaSharp.Views.WPF/SkiaSharp.Views.WPF.csproj +++ b/source/SkiaSharp.Views/SkiaSharp.Views.WPF/SkiaSharp.Views.WPF.csproj @@ -1,6 +1,6 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 true SkiaSharp.Views.WPF SkiaSharp.Views.WPF diff --git a/source/SkiaSharp.Views/SkiaSharp.Views.WindowsForms/SkiaSharp.Views.WindowsForms.csproj b/source/SkiaSharp.Views/SkiaSharp.Views.WindowsForms/SkiaSharp.Views.WindowsForms.csproj index b838764db..80fcd785c 100644 --- a/source/SkiaSharp.Views/SkiaSharp.Views.WindowsForms/SkiaSharp.Views.WindowsForms.csproj +++ b/source/SkiaSharp.Views/SkiaSharp.Views.WindowsForms/SkiaSharp.Views.WindowsForms.csproj @@ -1,6 +1,6 @@  - net462;netcoreapp3.0 + net462;netcoreapp3.1 true SkiaSharp.Views.Desktop SkiaSharp.Views.WindowsForms diff --git a/source/SkiaSharp.Vulkan/SkiaSharp.Vulkan.SharpVk/SkiaSharp.Vulkan.SharpVk.csproj b/source/SkiaSharp.Vulkan/SkiaSharp.Vulkan.SharpVk/SkiaSharp.Vulkan.SharpVk.csproj index 8d8d06790..6b3084710 100644 --- a/source/SkiaSharp.Vulkan/SkiaSharp.Vulkan.SharpVk/SkiaSharp.Vulkan.SharpVk.csproj +++ b/source/SkiaSharp.Vulkan/SkiaSharp.Vulkan.SharpVk/SkiaSharp.Vulkan.SharpVk.csproj @@ -5,7 +5,6 @@ SkiaSharp.Vulkan.SharpVk false SkiaSharp.Vulkan.SharpVk - $(DefineConstants);NET_STANDARD diff --git a/tests/SkiaSharp.NetCore.Tests/SkiaSharp.NetCore.Tests.csproj b/tests/SkiaSharp.NetCore.Tests/SkiaSharp.NetCore.Tests.csproj index c83e26bd8..99f1c9d41 100644 --- a/tests/SkiaSharp.NetCore.Tests/SkiaSharp.NetCore.Tests.csproj +++ b/tests/SkiaSharp.NetCore.Tests/SkiaSharp.NetCore.Tests.csproj @@ -1,7 +1,7 @@  - netcoreapp3.0 - $(DefineConstants);NET_STANDARD;USE_LIBRARY_LOADER + netcoreapp3.1 + $(DefineConstants);USE_LIBRARY_LOADER SkiaSharp.Tests SkiaSharp.Tests true @@ -13,7 +13,7 @@ - + diff --git a/tests/SkiaSharp.Vulkan.NetCore.Tests/SkiaSharp.Vulkan.NetCore.Tests.csproj b/tests/SkiaSharp.Vulkan.NetCore.Tests/SkiaSharp.Vulkan.NetCore.Tests.csproj index 683315f5d..519741c23 100644 --- a/tests/SkiaSharp.Vulkan.NetCore.Tests/SkiaSharp.Vulkan.NetCore.Tests.csproj +++ b/tests/SkiaSharp.Vulkan.NetCore.Tests/SkiaSharp.Vulkan.NetCore.Tests.csproj @@ -1,7 +1,6 @@  - netcoreapp3.0 - $(DefineConstants);NET_STANDARD + netcoreapp3.1 SkiaSharp.Vulkan.Tests SkiaSharp.Vulkan.Tests false @@ -16,7 +15,7 @@ - + diff --git a/tests/Tests/BaseTest.cs b/tests/Tests/BaseTest.cs index c1794c85c..acc04167c 100644 --- a/tests/Tests/BaseTest.cs +++ b/tests/Tests/BaseTest.cs @@ -36,7 +36,7 @@ namespace SkiaSharp.Tests PathToImages = Path.Combine(PathToAssembly, "images"); // some platforms run the tests from a temporary location, so copy the native files -#if !NET_STANDARD && !__ANDROID__ && !__IOS__ +#if !NETCOREAPP && !__ANDROID__ && !__IOS__ var skiaRoot = Path.GetDirectoryName(typeof(SkiaSharp.SKImageInfo).Assembly.Location); var harfRoot = Path.GetDirectoryName(typeof(HarfBuzzSharp.Buffer).Assembly.Location); diff --git a/utils/SkiaSharpGenerator/SkiaSharpGenerator.csproj b/utils/SkiaSharpGenerator/SkiaSharpGenerator.csproj index 943d7a7a4..321b6d206 100644 --- a/utils/SkiaSharpGenerator/SkiaSharpGenerator.csproj +++ b/utils/SkiaSharpGenerator/SkiaSharpGenerator.csproj @@ -2,7 +2,7 @@ Exe - netcoreapp3.0 + netcoreapp3.1 enable diff --git a/utils/WasmTestRunner/WasmTestRunner.csproj b/utils/WasmTestRunner/WasmTestRunner.csproj index d98b3880a..fbe142188 100644 --- a/utils/WasmTestRunner/WasmTestRunner.csproj +++ b/utils/WasmTestRunner/WasmTestRunner.csproj @@ -2,7 +2,7 @@ Exe - netcoreapp3.0 + netcoreapp3.1 8.0 wasm-test From 29d8b8315c624bfb5ac710f5e2a04f0b618202c2 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Tue, 11 May 2021 03:24:45 +0200 Subject: [PATCH 2/4] Improve build props/targets (#1698) --- build.cake | 1 - source/SkiaSharp.Build.props | 9 ++++----- source/SkiaSharp.Build.targets | 31 +++++++++++++++++-------------- 3 files changed, 21 insertions(+), 20 deletions(-) diff --git a/build.cake b/build.cake index 2d6b8007a..207edb56b 100644 --- a/build.cake +++ b/build.cake @@ -203,7 +203,6 @@ Task ("tests-netcore") CleanDirectories ($"{PACKAGE_CACHE_PATH}/harfbuzzsharp*"); // SkiaSharp.NetCore.Tests.csproj - RunMSBuild ("./tests/SkiaSharp.NetCore.Tests.sln"); try { RunNetCoreTests ("./tests/SkiaSharp.NetCore.Tests/SkiaSharp.NetCore.Tests.csproj"); } catch { diff --git a/source/SkiaSharp.Build.props b/source/SkiaSharp.Build.props index 650ca08db..71a947565 100644 --- a/source/SkiaSharp.Build.props +++ b/source/SkiaSharp.Build.props @@ -13,7 +13,6 @@ true true $(MSBuildThisFileDirectory)..\docs\SkiaSharpAPI - False 8.0 @@ -32,9 +31,9 @@ - true - true - true + $([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows))) + $([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::OSX))) + $([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Linux))) + Condition=" !$(IsWindows) and !$(IsMacOS) and !$(IsLinux) " /> \ No newline at end of file diff --git a/source/SkiaSharp.Build.targets b/source/SkiaSharp.Build.targets index c66e99e18..a0305531b 100644 --- a/source/SkiaSharp.Build.targets +++ b/source/SkiaSharp.Build.targets @@ -14,7 +14,6 @@ mono.snk $(MSBuildThisFileDirectory)..\$(KeyFileName) - true $(GIT_SHA) $(GIT_COMMIT) @@ -25,6 +24,10 @@ false false false + false + false + false + false - VSX1000 + $(MSBuildWarningsAsMessages);VSX1000 - MSB9004 + $(MSBuildWarningsAsMessages);MSB9004 $(TargetFramework) - + - - - <_SignAssemblyDependsOn Condition=" '$(TypeRedirectorSkip)' == 'false'"> - _RedirectMovedTypes - + <_SignAssemblyAfterTargets> CoreCompile - + @@ -130,12 +131,14 @@ internal partial class VersionConstants { Verify that the output assembly is signed correctly for release. =================================================================================================================== --> - + <_SignAssemblyVerifyAfterTargets> Build - + @@ -195,7 +198,7 @@ internal partial class VersionConstants { This runs during the build phase. =================================================================================================================== --> - + CoreCompile @@ -215,7 +218,7 @@ internal partial class VersionConstants { <_MDocInputs Include="$(MDocDocumentationDirectory)\**\*" /> - From b551b3485f6a0183b1d2254bc6857f680bcf4fa0 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Tue, 11 May 2021 15:47:39 +0200 Subject: [PATCH 3/4] Add support for WinUI for Desktop (#1696) --- VERSIONS.txt | 16 +- .../HarfBuzzApi.generated.cs | 2 - build.cake | 5 +- cake/UtilsManaged.cake | 21 +- .../2.6.1.8/HarfBuzzSharp.breaking.md | 23 + .../HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.md | 442 ++++++++++++++++++ .../2.80.3/SkiaSharp.HarfBuzz.md | 5 + .../2.80.3/SkiaSharp.Views.Desktop.Common.md | 22 + .../2.80.3/SkiaSharp.Views.Forms.md | 5 + .../2.80.3/SkiaSharp.Views.Forms.md | 5 + .../2.80.3/SkiaSharp.Views.Forms.md | 5 + .../2.80.3/SkiaSharp.Views.Gtk.md | 5 + .../2.80.3/SkiaSharp.Views.Gtk3.md | 5 + .../2.80.3/SkiaSharp.Views.UWP.md | 24 + .../2.80.3/SkiaSharp.Views.WPF.md | 5 + .../2.80.3/SkiaSharp.Views.Windows.md | 103 ++++ .../2.80.3/SkiaSharp.Views.WindowsForms.md | 5 + .../2.80.3/SkiaSharp.Views.Android.md | 16 + .../2.80.3/SkiaSharp.Views.Desktop.md | 5 + .../2.80.3/SkiaSharp.Views.Mac.md | 42 ++ .../2.80.3/SkiaSharp.Views.Tizen.md | 5 + .../2.80.3/SkiaSharp.Views.UWP.md | 5 + .../2.80.3/SkiaSharp.Views.iOS.md | 42 ++ .../2.80.3/SkiaSharp.Views.tvOS.md | 5 + .../2.80.3/SkiaSharp.Views.watchOS.md | 5 + .../2.80.3/SkiaSharp.Vulkan.SharpVk.md | 5 + changelogs/SkiaSharp/2.80.3/SkiaSharp.md | 100 ++++ docs | 2 +- nuget/SkiaSharp.Views.WinUI.nuspec | 47 ++ .../SkiaSharpSample/SkiaSharpSample.csproj | 1 - .../Images/LockScreenLogo.scale-200.png | Bin 0 -> 1430 bytes .../Images/SplashScreen.scale-200.png | Bin 0 -> 7700 bytes .../Images/Square150x150Logo.scale-200.png | Bin 0 -> 2937 bytes .../Images/Square44x44Logo.scale-200.png | Bin 0 -> 1647 bytes ...x44Logo.targetsize-24_altform-unplated.png | Bin 0 -> 1255 bytes .../Images/StoreLogo.png | Bin 0 -> 1451 bytes .../Images/Wide310x150Logo.scale-200.png | Bin 0 -> 3204 bytes .../Package.appxmanifest | 48 ++ .../SkiaSharpSample.Package.wapproj | 75 +++ .../Basic/WinUI/Desktop/SkiaSharpSample.sln | 107 +++++ .../WinUI/Desktop/SkiaSharpSample/App.xaml | 15 + .../WinUI/Desktop/SkiaSharpSample/App.xaml.cs | 20 + .../Desktop/SkiaSharpSample/MainWindow.xaml | 13 + .../SkiaSharpSample/MainWindow.xaml.cs | 42 ++ .../SkiaSharpSample/SkiaSharpSample.csproj | 29 ++ .../Desktop/SkiaSharpSample/app.manifest | 15 + samples/Directory.Build.props | 8 + samples/Directory.Build.targets | 12 + source/SkiaSharp.Build.props | 5 + source/SkiaSharp.Build.targets | 16 +- .../Interop/IBufferByteAccess.cs | 101 ++++ .../SkiaSharp.Views.WinUI.csproj | 20 + .../AndroidExtensions.cs | 4 +- .../SkiaSharp.Views.Android/GLTextureView.cs | 10 +- .../SkiaSharp.Views.Shared/Extensions.cs | 3 + .../GlesInterop/Gles.cs | 2 +- .../SKPaintGLSurfaceEventArgs.cs | 2 + .../SKPaintSurfaceEventArgs.cs | 2 + .../AngleSwapChainPanel.cs | 10 +- .../GlesInterop/GlesContext.cs | 13 +- .../Interop/IBufferByteAccess.cs | 19 +- .../Interop/PropertySetExtensions.cs | 6 +- .../SkiaSharp.Views.UWP/SKSwapChainPanel.cs | 10 +- .../SkiaSharp.Views.UWP/SKXamlCanvas.cs | 38 ++ .../SkiaSharp.Views.UWP/UWPExtensions.cs | 30 +- source/SkiaSharpSource.Windows.sln | 9 + source/SkiaSharpSource.sln | 9 + 67 files changed, 1620 insertions(+), 51 deletions(-) create mode 100644 changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.breaking.md create mode 100644 changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.md create mode 100644 changelogs/SkiaSharp.HarfBuzz/2.80.3/SkiaSharp.HarfBuzz.md create mode 100644 changelogs/SkiaSharp.Views.Desktop.Common/2.80.3/SkiaSharp.Views.Desktop.Common.md create mode 100644 changelogs/SkiaSharp.Views.Forms.GTK/2.80.3/SkiaSharp.Views.Forms.md create mode 100644 changelogs/SkiaSharp.Views.Forms.WPF/2.80.3/SkiaSharp.Views.Forms.md create mode 100644 changelogs/SkiaSharp.Views.Forms/2.80.3/SkiaSharp.Views.Forms.md create mode 100644 changelogs/SkiaSharp.Views.Gtk2/2.80.3/SkiaSharp.Views.Gtk.md create mode 100644 changelogs/SkiaSharp.Views.Gtk3/2.80.3/SkiaSharp.Views.Gtk3.md create mode 100644 changelogs/SkiaSharp.Views.Uno/2.80.3/SkiaSharp.Views.UWP.md create mode 100644 changelogs/SkiaSharp.Views.WPF/2.80.3/SkiaSharp.Views.WPF.md create mode 100644 changelogs/SkiaSharp.Views.WinUI/2.80.3/SkiaSharp.Views.Windows.md create mode 100644 changelogs/SkiaSharp.Views.WindowsForms/2.80.3/SkiaSharp.Views.WindowsForms.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Android.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Desktop.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Mac.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Tizen.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.UWP.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.iOS.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.tvOS.md create mode 100644 changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.watchOS.md create mode 100644 changelogs/SkiaSharp.Vulkan.SharpVk/2.80.3/SkiaSharp.Vulkan.SharpVk.md create mode 100644 changelogs/SkiaSharp/2.80.3/SkiaSharp.md create mode 100644 nuget/SkiaSharp.Views.WinUI.nuspec create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/LockScreenLogo.scale-200.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/SplashScreen.scale-200.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square150x150Logo.scale-200.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.scale-200.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.targetsize-24_altform-unplated.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/StoreLogo.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Wide310x150Logo.scale-200.png create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Package.appxmanifest create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/SkiaSharpSample.Package.wapproj create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample.sln create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml.cs create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml.cs create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/SkiaSharpSample.csproj create mode 100644 samples/Basic/WinUI/Desktop/SkiaSharpSample/app.manifest create mode 100644 samples/Directory.Build.props create mode 100644 samples/Directory.Build.targets create mode 100644 source/SkiaSharp.Views.WinUI/SkiaSharp.Views.WinUI/Interop/IBufferByteAccess.cs create mode 100644 source/SkiaSharp.Views.WinUI/SkiaSharp.Views.WinUI/SkiaSharp.Views.WinUI.csproj diff --git a/VERSIONS.txt b/VERSIONS.txt index ef9483e6e..e3a637bd0 100644 --- a/VERSIONS.txt +++ b/VERSIONS.txt @@ -1,5 +1,5 @@ # dependencies -mdoc release 5.7.4.10 +mdoc release 5.8.2 harfbuzz release 2.6.1 skia release m80 xunit release 2.4.1 @@ -18,10 +18,15 @@ GdkSharp release 3.22.24.37 GLibSharp release 3.22.24.37 AtkSharp release 3.22.24.37 System.Memory release 4.5.3 +System.Drawing.Common release 4.5.1 System.IO.UnmanagedMemoryStream release 4.3.0 System.Drawing.Common release 4.5.1 SharpVk release 0.4.2 Uno.UI release 2.4.4 +Microsoft.ProjectReunion release 0.5.0 +Microsoft.ProjectReunion.Foundation release 0.5.0 +Microsoft.ProjectReunion.WinUI release 0.5.0 +Microsoft.Windows.SDK.NET.Ref release 10.0.18362.15 # additional references used by the tooling OpenTK.GLControl reference 1.1.2349.61993 @@ -44,7 +49,7 @@ SkiaSharp file 2.80.3.0 # HarfBuzzSharp.dll HarfBuzzSharp assembly 1.0.0.0 -HarfBuzzSharp file 2.6.1.7 +HarfBuzzSharp file 2.6.1.8 # nuget versions SkiaSharp nuget 2.80.3 @@ -62,11 +67,12 @@ SkiaSharp.Views.Forms nuget 2.80.3 SkiaSharp.Views.Forms.WPF nuget 2.80.3 SkiaSharp.Views.Forms.GTK nuget 2.80.3 SkiaSharp.Views.Uno nuget 2.80.3 +SkiaSharp.Views.WinUI nuget 2.80.3 SkiaSharp.HarfBuzz nuget 2.80.3 SkiaSharp.Vulkan.SharpVk nuget 2.80.3 -HarfBuzzSharp nuget 2.6.1.7 -HarfBuzzSharp.NativeAssets.Linux nuget 2.6.1.7 -HarfBuzzSharp.NativeAssets.WebAssembly nuget 2.6.1.7 +HarfBuzzSharp nuget 2.6.1.8 +HarfBuzzSharp.NativeAssets.Linux nuget 2.6.1.8 +HarfBuzzSharp.NativeAssets.WebAssembly nuget 2.6.1.8 # nuget replacement versions Xamarin.Forms nuget 4.6.0.772 diff --git a/binding/HarfBuzzSharp.Shared/HarfBuzzApi.generated.cs b/binding/HarfBuzzSharp.Shared/HarfBuzzApi.generated.cs index 0b9a28466..5f8ea45a2 100644 --- a/binding/HarfBuzzSharp.Shared/HarfBuzzApi.generated.cs +++ b/binding/HarfBuzzSharp.Shared/HarfBuzzApi.generated.cs @@ -5494,8 +5494,6 @@ namespace HarfBuzzSharp IdeoEmboxTopOrRight = 1768191088, // HB_OT_LAYOUT_BASELINE_TAG_MATH = 1835103336 Math = 1835103336, - // _HB_OT_LAYOUT_BASELINE_TAG_MAX_VALUE = 2147483647 - HbOtLayoutBaselineTagMaxValue = 2147483647, } // hb_ot_layout_glyph_class_t diff --git a/build.cake b/build.cake index 207edb56b..1569e8420 100644 --- a/build.cake +++ b/build.cake @@ -6,7 +6,7 @@ #addin nuget:?package=Mono.ApiTools.NuGetDiff&version=1.3.2&loaddependencies=true #addin nuget:?package=Xamarin.Nuget.Validator&version=1.1.1 -#tool nuget:?package=mdoc&version=5.7.4.10 +#tool nuget:?package=mdoc&version=5.8.2 #tool nuget:?package=xunit.runner.console&version=2.4.1 #tool nuget:?package=vswhere&version=2.7.1 @@ -72,6 +72,7 @@ var TRACKED_NUGETS = new Dictionary { { "SkiaSharp.Views.Forms.WPF", new Version (1, 57, 0) }, { "SkiaSharp.Views.Forms.GTK", new Version (1, 57, 0) }, { "SkiaSharp.Views.Uno", new Version (1, 57, 0) }, + { "SkiaSharp.Views.WinUI", new Version (1, 57, 0) }, { "HarfBuzzSharp", new Version (1, 0, 0) }, { "HarfBuzzSharp.NativeAssets.Linux", new Version (1, 0, 0) }, { "HarfBuzzSharp.NativeAssets.WebAssembly", new Version (1, 0, 0) }, @@ -385,6 +386,7 @@ Task ("samples") { "macos", isMac }, { "tvos", isMac }, { "uwp", isWin }, + { "winui", isWin }, { "watchos", isMac }, { "wpf", isWin }, }; @@ -393,6 +395,7 @@ Task ("samples") { "ios", "iPhone" }, { "tvos", "iPhoneSimulator" }, { "uwp", "x86" }, + { "winui", "x64" }, { "watchos", "iPhoneSimulator" }, { "xamarin.forms.mac", "iPhone" }, { "xamarin.forms.windows", "x86" }, diff --git a/cake/UtilsManaged.cake b/cake/UtilsManaged.cake index caa9e043e..bf098b802 100644 --- a/cake/UtilsManaged.cake +++ b/cake/UtilsManaged.cake @@ -147,22 +147,26 @@ IEnumerable<(DirectoryPath path, string platform)> GetPlatformDirectories(Direct // there were no cross-platform libraries, so process each platform foreach (var dir in platformDirs) { var d = dir.GetDirectoryName().ToLower(); - if (d.StartsWith("monoandroid")) + if (d.StartsWith("monoandroid") || (d.StartsWith("net") && d.Contains("-android"))) yield return (dir, "android"); else if (d.StartsWith("net4")) yield return (dir, "net"); else if (d.StartsWith("uap")) yield return (dir, "uwp"); - else if (d.StartsWith("xamarinios") || d.StartsWith("xamarin.ios")) + else if (d.StartsWith("xamarinios") || d.StartsWith("xamarin.ios") || (d.StartsWith("net") && d.Contains("-ios"))) yield return (dir, "ios"); - else if (d.StartsWith("xamarinmac") || d.StartsWith("xamarin.mac")) + else if (d.StartsWith("xamarinmac") || d.StartsWith("xamarin.mac") || (d.StartsWith("net") && d.Contains("-macos"))) yield return (dir, "macos"); - else if (d.StartsWith("xamarintvos") || d.StartsWith("xamarin.tvos")) + else if (d.StartsWith("xamarintvos") || d.StartsWith("xamarin.tvos") || (d.StartsWith("net") && d.Contains("-tvos"))) yield return (dir, "tvos"); - else if (d.StartsWith("xamarinwatchos") || d.StartsWith("xamarin.watchos")) + else if (d.StartsWith("xamarinwatchos") || d.StartsWith("xamarin.watchos") || (d.StartsWith("net") && d.Contains("-watchos"))) yield return (dir, "watchos"); - else if (d.StartsWith("tizen")) + else if (d.StartsWith("tizen") || (d.StartsWith("net") && d.Contains("-tizen"))) yield return (dir, "tizen"); + else if (d.StartsWith("net") && d.Contains("-windows")) + yield return (dir, "windows"); + else if (d.StartsWith("net") && d.Contains("-maccatalyst")) + yield return (dir, "maccatalyst"); else if (d.StartsWith("netcoreapp")) ; // skip this one for now else @@ -225,6 +229,9 @@ async Task CreateNuGetDiffAsync() await AddDep("Uno.UI", "xamarinios10"); await AddDep("Uno.UI", "xamarinmac20"); await AddDep("Uno.UI", "UAP"); + await AddDep("Microsoft.ProjectReunion.Foundation", "net5.0-windows"); + await AddDep("Microsoft.ProjectReunion.WinUI", "net5.0-windows10.0.18362.0"); + await AddDep("Microsoft.Windows.SDK.NET.Ref", ""); await AddDep("OpenTK.GLControl", "NET40", "reference"); await AddDep("Xamarin.Forms", "Xamarin.iOS10", "reference"); @@ -271,7 +278,7 @@ async Task DownloadPackageAsync(string id, DirectoryPath outputDirectory) { currentId = currentId.ToLower(); - Information($"Downloading: {currentId}..."); + Information($"Downloading '{currentId}' version '{currentVersion}'..."); var root = await comparer.ExtractCachedPackageAsync(currentId, currentVersion); var toolsDir = $"{root}/tools/"; diff --git a/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.breaking.md b/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.breaking.md new file mode 100644 index 000000000..74b9a24f8 --- /dev/null +++ b/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.breaking.md @@ -0,0 +1,23 @@ +# API diff: HarfBuzzSharp.dll + +## HarfBuzzSharp.dll + +### Namespace HarfBuzzSharp + +#### Type Changed: HarfBuzzSharp.OpenTypeMetrics + +Modified base type: + +```diff +-System.ValueType ++System.Object +``` + +Removed constructor: + +```csharp +public OpenTypeMetrics (IntPtr font); +``` + + + diff --git a/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.md b/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.md new file mode 100644 index 000000000..4bdf09870 --- /dev/null +++ b/changelogs/HarfBuzzSharp/2.6.1.8/HarfBuzzSharp.md @@ -0,0 +1,442 @@ +# API diff: HarfBuzzSharp.dll + +## HarfBuzzSharp.dll + +### Namespace HarfBuzzSharp + +#### Type Changed: HarfBuzzSharp.Feature + +Added interface: + +```csharp +System.IEquatable +``` + +Added methods: + +```csharp +public virtual bool Equals (Feature obj); +public override bool Equals (object obj); +public override int GetHashCode (); +public static bool op_Equality (Feature left, Feature right); +public static bool op_Inequality (Feature left, Feature right); +``` + + +#### Type Changed: HarfBuzzSharp.FontExtents + +Added interface: + +```csharp +System.IEquatable +``` + +Added methods: + +```csharp +public virtual bool Equals (FontExtents obj); +public override bool Equals (object obj); +public override int GetHashCode (); +public static bool op_Equality (FontExtents left, FontExtents right); +public static bool op_Inequality (FontExtents left, FontExtents right); +``` + + +#### Type Changed: HarfBuzzSharp.GlyphExtents + +Added interface: + +```csharp +System.IEquatable +``` + +Added methods: + +```csharp +public virtual bool Equals (GlyphExtents obj); +public override bool Equals (object obj); +public override int GetHashCode (); +public static bool op_Equality (GlyphExtents left, GlyphExtents right); +public static bool op_Inequality (GlyphExtents left, GlyphExtents right); +``` + + +#### Type Changed: HarfBuzzSharp.GlyphInfo + +Added interface: + +```csharp +System.IEquatable +``` + +Added methods: + +```csharp +public virtual bool Equals (GlyphInfo obj); +public override bool Equals (object obj); +public override int GetHashCode (); +public static bool op_Equality (GlyphInfo left, GlyphInfo right); +public static bool op_Inequality (GlyphInfo left, GlyphInfo right); +``` + + +#### Type Changed: HarfBuzzSharp.GlyphPosition + +Added interface: + +```csharp +System.IEquatable +``` + +Added methods: + +```csharp +public virtual bool Equals (GlyphPosition obj); +public override bool Equals (object obj); +public override int GetHashCode (); +public static bool op_Equality (GlyphPosition left, GlyphPosition right); +public static bool op_Inequality (GlyphPosition left, GlyphPosition right); +``` + + +#### Type Changed: HarfBuzzSharp.OpenTypeMetrics + +Modified base type: + +```diff +-System.ValueType ++System.Object +``` + +Removed constructor: + +```csharp +public OpenTypeMetrics (IntPtr font); +``` + +Added constructor: + +```csharp +public OpenTypeMetrics (Font font); +``` + + +#### New Type: HarfBuzzSharp.BufferDiffFlags + +```csharp +[Serializable] +public enum BufferDiffFlags { + ClusterMismatch = 32, + CodepointMismatch = 16, + ContentTypeMismatch = 1, + DottedCirclePresent = 8, + Equal = 0, + GlyphFlagsMismatch = 64, + LengthMismatch = 2, + NotdefPresent = 4, + PositionMismatch = 128, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeColorLayer + +```csharp +public struct OpenTypeColorLayer, System.IEquatable { + // properties + public uint ColorIndex { get; set; } + public uint Glyph { get; set; } + // methods + public virtual bool Equals (OpenTypeColorLayer obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeColorLayer left, OpenTypeColorLayer right); + public static bool op_Inequality (OpenTypeColorLayer left, OpenTypeColorLayer right); +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeColorPaletteFlags + +```csharp +[Serializable] +public enum OpenTypeColorPaletteFlags { + Default = 0, + UsableWithDarkBackground = 2, + UsableWithLightBackground = 1, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeLayoutBaselineTag + +```csharp +[Serializable] +public enum OpenTypeLayoutBaselineTag { + Hanging = 1751215719, + IdeoEmboxBottomOrLeft = 1768187247, + IdeoEmboxTopOrRight = 1768191088, + IdeoFaceBottomOrLeft = 1768121954, + IdeoFaceTopOrRight = 1768121972, + Math = 1835103336, + Roman = 1919905134, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeLayoutGlyphClass + +```csharp +[Serializable] +public enum OpenTypeLayoutGlyphClass { + BaseGlyph = 1, + Component = 4, + Ligature = 2, + Mark = 3, + Unclassified = 0, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMathConstant + +```csharp +[Serializable] +public enum OpenTypeMathConstant { + AccentBaseHeight = 6, + AxisHeight = 5, + DelimitedSubFormulaMinHeight = 2, + DisplayOperatorMinHeight = 3, + FlattenedAccentBaseHeight = 7, + FractionDenomDisplayStyleGapMin = 40, + FractionDenominatorDisplayStyleShiftDown = 35, + FractionDenominatorGapMin = 39, + FractionDenominatorShiftDown = 34, + FractionNumDisplayStyleGapMin = 37, + FractionNumeratorDisplayStyleShiftUp = 33, + FractionNumeratorGapMin = 36, + FractionNumeratorShiftUp = 32, + FractionRuleThickness = 38, + LowerLimitBaselineDropMin = 21, + LowerLimitGapMin = 20, + MathLeading = 4, + OverbarExtraAscender = 45, + OverbarRuleThickness = 44, + OverbarVerticalGap = 43, + RadicalDegreeBottomRaisePercent = 55, + RadicalDisplayStyleVerticalGap = 50, + RadicalExtraAscender = 52, + RadicalKernAfterDegree = 54, + RadicalKernBeforeDegree = 53, + RadicalRuleThickness = 51, + RadicalVerticalGap = 49, + ScriptPercentScaleDown = 0, + ScriptScriptPercentScaleDown = 1, + SkewedFractionHorizontalGap = 41, + SkewedFractionVerticalGap = 42, + SpaceAfterScript = 17, + StackBottomDisplayStyleShiftDown = 25, + StackBottomShiftDown = 24, + StackDisplayStyleGapMin = 27, + StackGapMin = 26, + StackTopDisplayStyleShiftUp = 23, + StackTopShiftUp = 22, + StretchStackBottomShiftDown = 29, + StretchStackGapAboveMin = 30, + StretchStackGapBelowMin = 31, + StretchStackTopShiftUp = 28, + SubSuperscriptGapMin = 15, + SubscriptBaselineDropMin = 10, + SubscriptShiftDown = 8, + SubscriptTopMax = 9, + SuperscriptBaselineDropMax = 14, + SuperscriptBottomMaxWithSubscript = 16, + SuperscriptBottomMin = 13, + SuperscriptShiftUp = 11, + SuperscriptShiftUpCramped = 12, + UnderbarExtraDescender = 48, + UnderbarRuleThickness = 47, + UnderbarVerticalGap = 46, + UpperLimitBaselineRiseMin = 19, + UpperLimitGapMin = 18, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMathGlyphPart + +```csharp +public struct OpenTypeMathGlyphPart, System.IEquatable { + // properties + public int EndConnectorLength { get; set; } + public OpenTypeMathGlyphPartFlags Flags { get; set; } + public int FullAdvance { get; set; } + public uint Glyph { get; set; } + public int StartConnectorLength { get; set; } + // methods + public virtual bool Equals (OpenTypeMathGlyphPart obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeMathGlyphPart left, OpenTypeMathGlyphPart right); + public static bool op_Inequality (OpenTypeMathGlyphPart left, OpenTypeMathGlyphPart right); +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMathGlyphPartFlags + +```csharp +[Serializable] +public enum OpenTypeMathGlyphPartFlags { + Extender = 1, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMathGlyphVariant + +```csharp +public struct OpenTypeMathGlyphVariant, System.IEquatable { + // properties + public int Advance { get; set; } + public uint Glyph { get; set; } + // methods + public virtual bool Equals (OpenTypeMathGlyphVariant obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeMathGlyphVariant left, OpenTypeMathGlyphVariant right); + public static bool op_Inequality (OpenTypeMathGlyphVariant left, OpenTypeMathGlyphVariant right); +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMathKern + +```csharp +[Serializable] +public enum OpenTypeMathKern { + BottomLeft = 3, + BottomRight = 2, + TopLeft = 1, + TopRight = 0, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeMetaTag + +```csharp +[Serializable] +public enum OpenTypeMetaTag { + DesignLanguages = 1684827751, + SupportedLanguages = 1936485991, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeNameEntry + +```csharp +public struct OpenTypeNameEntry, System.IEquatable { + // properties + public IntPtr Language { get; set; } + public OpenTypeNameId NameId { get; set; } + public int Var { get; set; } + // methods + public virtual bool Equals (OpenTypeNameEntry obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeNameEntry left, OpenTypeNameEntry right); + public static bool op_Inequality (OpenTypeNameEntry left, OpenTypeNameEntry right); +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeNameId + +```csharp +[Serializable] +public enum OpenTypeNameId { + CidFindFontName = 20, + Copyright = 0, + DarkBackground = 24, + Description = 10, + Designer = 9, + DesignerUrl = 12, + FontFamily = 1, + FontSubfamily = 2, + FullName = 4, + Invalid = 65535, + License = 13, + LicenseUrl = 14, + LightBackground = 23, + MacFullName = 18, + Manufacturer = 8, + PostscriptName = 6, + SampleText = 19, + Trademark = 7, + TypographicFamily = 16, + TypographicSubfamily = 17, + UniqueId = 3, + VariationsPostscriptPrefix = 25, + VendorUrl = 11, + VersionString = 5, + WwsFamily = 21, + WwsSubfamily = 22, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeVarAxis + +```csharp +public struct OpenTypeVarAxis, System.IEquatable { + // properties + public float DefaultValue { get; set; } + public float MaxValue { get; set; } + public float MinValue { get; set; } + public OpenTypeNameId NameId { get; set; } + public uint Tag { get; set; } + // methods + public virtual bool Equals (OpenTypeVarAxis obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeVarAxis left, OpenTypeVarAxis right); + public static bool op_Inequality (OpenTypeVarAxis left, OpenTypeVarAxis right); +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeVarAxisFlags + +```csharp +[Serializable] +public enum OpenTypeVarAxisFlags { + Hidden = 1, +} +``` + +#### New Type: HarfBuzzSharp.OpenTypeVarAxisInfo + +```csharp +public struct OpenTypeVarAxisInfo, System.IEquatable { + // properties + public uint AxisIndex { get; set; } + public float DefaultValue { get; set; } + public OpenTypeVarAxisFlags Flags { get; set; } + public float MaxValue { get; set; } + public float MinValue { get; set; } + public OpenTypeNameId NameId { get; set; } + public uint Tag { get; set; } + // methods + public virtual bool Equals (OpenTypeVarAxisInfo obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (OpenTypeVarAxisInfo left, OpenTypeVarAxisInfo right); + public static bool op_Inequality (OpenTypeVarAxisInfo left, OpenTypeVarAxisInfo right); +} +``` + +#### New Type: HarfBuzzSharp.Variation + +```csharp +public struct Variation, System.IEquatable { + // properties + public uint Tag { get; set; } + public float Value { get; set; } + // methods + public virtual bool Equals (Variation obj); + public override bool Equals (object obj); + public override int GetHashCode (); + public static bool op_Equality (Variation left, Variation right); + public static bool op_Inequality (Variation left, Variation right); +} +``` + + diff --git a/changelogs/SkiaSharp.HarfBuzz/2.80.3/SkiaSharp.HarfBuzz.md b/changelogs/SkiaSharp.HarfBuzz/2.80.3/SkiaSharp.HarfBuzz.md new file mode 100644 index 000000000..9e2886165 --- /dev/null +++ b/changelogs/SkiaSharp.HarfBuzz/2.80.3/SkiaSharp.HarfBuzz.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.HarfBuzz.dll + +## SkiaSharp.HarfBuzz.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Desktop.Common/2.80.3/SkiaSharp.Views.Desktop.Common.md b/changelogs/SkiaSharp.Views.Desktop.Common/2.80.3/SkiaSharp.Views.Desktop.Common.md new file mode 100644 index 000000000..4cae28970 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Desktop.Common/2.80.3/SkiaSharp.Views.Desktop.Common.md @@ -0,0 +1,22 @@ +# API diff: SkiaSharp.Views.Desktop.Common.dll + +## SkiaSharp.Views.Desktop.Common.dll + +### Namespace SkiaSharp.Views.Desktop + +#### Type Changed: SkiaSharp.Views.Desktop.Extensions + +Added methods: + +```csharp +public static System.Drawing.Bitmap ToBitmap (this SkiaSharp.SKBitmap skiaBitmap); +public static System.Drawing.Bitmap ToBitmap (this SkiaSharp.SKImage skiaImage); +public static System.Drawing.Bitmap ToBitmap (this SkiaSharp.SKPixmap pixmap); +public static System.Drawing.Bitmap ToBitmap (this SkiaSharp.SKPicture picture, SkiaSharp.SKSizeI dimensions); +public static SkiaSharp.SKBitmap ToSKBitmap (this System.Drawing.Bitmap bitmap); +public static SkiaSharp.SKImage ToSKImage (this System.Drawing.Bitmap bitmap); +public static void ToSKPixmap (this System.Drawing.Bitmap bitmap, SkiaSharp.SKPixmap pixmap); +``` + + + diff --git a/changelogs/SkiaSharp.Views.Forms.GTK/2.80.3/SkiaSharp.Views.Forms.md b/changelogs/SkiaSharp.Views.Forms.GTK/2.80.3/SkiaSharp.Views.Forms.md new file mode 100644 index 000000000..5564a6718 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Forms.GTK/2.80.3/SkiaSharp.Views.Forms.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Forms.dll + +## SkiaSharp.Views.Forms.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Forms.WPF/2.80.3/SkiaSharp.Views.Forms.md b/changelogs/SkiaSharp.Views.Forms.WPF/2.80.3/SkiaSharp.Views.Forms.md new file mode 100644 index 000000000..5564a6718 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Forms.WPF/2.80.3/SkiaSharp.Views.Forms.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Forms.dll + +## SkiaSharp.Views.Forms.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Forms/2.80.3/SkiaSharp.Views.Forms.md b/changelogs/SkiaSharp.Views.Forms/2.80.3/SkiaSharp.Views.Forms.md new file mode 100644 index 000000000..5564a6718 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Forms/2.80.3/SkiaSharp.Views.Forms.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Forms.dll + +## SkiaSharp.Views.Forms.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Gtk2/2.80.3/SkiaSharp.Views.Gtk.md b/changelogs/SkiaSharp.Views.Gtk2/2.80.3/SkiaSharp.Views.Gtk.md new file mode 100644 index 000000000..62518e13a --- /dev/null +++ b/changelogs/SkiaSharp.Views.Gtk2/2.80.3/SkiaSharp.Views.Gtk.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Gtk.dll + +## SkiaSharp.Views.Gtk.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Gtk3/2.80.3/SkiaSharp.Views.Gtk3.md b/changelogs/SkiaSharp.Views.Gtk3/2.80.3/SkiaSharp.Views.Gtk3.md new file mode 100644 index 000000000..cc4c1d9a5 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Gtk3/2.80.3/SkiaSharp.Views.Gtk3.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Gtk3.dll + +## SkiaSharp.Views.Gtk3.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.Uno/2.80.3/SkiaSharp.Views.UWP.md b/changelogs/SkiaSharp.Views.Uno/2.80.3/SkiaSharp.Views.UWP.md new file mode 100644 index 000000000..164abbd42 --- /dev/null +++ b/changelogs/SkiaSharp.Views.Uno/2.80.3/SkiaSharp.Views.UWP.md @@ -0,0 +1,24 @@ +# API diff: SkiaSharp.Views.UWP.dll + +## SkiaSharp.Views.UWP.dll + +### Namespace SkiaSharp.Views.UWP + +#### Type Changed: SkiaSharp.Views.UWP.GlobalStaticResources + +Obsoleted methods: + +```diff + [Obsolete ("This method is provided for binary backward compatibility. It will always return null.")] + public static object FindResource (string name); +``` + +Added methods: + +```csharp +public static void RegisterDefaultStyles (); +public static void RegisterResourceDictionariesBySource (); +``` + + + diff --git a/changelogs/SkiaSharp.Views.WPF/2.80.3/SkiaSharp.Views.WPF.md b/changelogs/SkiaSharp.Views.WPF/2.80.3/SkiaSharp.Views.WPF.md new file mode 100644 index 000000000..0c21d2bfb --- /dev/null +++ b/changelogs/SkiaSharp.Views.WPF/2.80.3/SkiaSharp.Views.WPF.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.WPF.dll + +## SkiaSharp.Views.WPF.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views.WinUI/2.80.3/SkiaSharp.Views.Windows.md b/changelogs/SkiaSharp.Views.WinUI/2.80.3/SkiaSharp.Views.Windows.md new file mode 100644 index 000000000..f83ac96e0 --- /dev/null +++ b/changelogs/SkiaSharp.Views.WinUI/2.80.3/SkiaSharp.Views.Windows.md @@ -0,0 +1,103 @@ +# API diff: SkiaSharp.Views.Windows.dll + +## SkiaSharp.Views.Windows.dll + +> Assembly Version Changed: 2.80.0.0 vs 0.0.0.0 + +### New Namespace SkiaSharp.Views.Windows + +#### New Type: SkiaSharp.Views.Windows.Extensions + +```csharp +public static class Extensions { + // methods + public static System.Drawing.PointF ToDrawingPoint (this SkiaSharp.SKPoint point); + public static System.Drawing.Point ToDrawingPoint (this SkiaSharp.SKPointI point); + public static System.Drawing.RectangleF ToDrawingRect (this SkiaSharp.SKRect rect); + public static System.Drawing.Rectangle ToDrawingRect (this SkiaSharp.SKRectI rect); + public static System.Drawing.SizeF ToDrawingSize (this SkiaSharp.SKSize size); + public static System.Drawing.Size ToDrawingSize (this SkiaSharp.SKSizeI size); + public static SkiaSharp.SKPointI ToSKPoint (this System.Drawing.Point point); + public static SkiaSharp.SKPoint ToSKPoint (this System.Drawing.PointF point); + public static SkiaSharp.SKRectI ToSKRect (this System.Drawing.Rectangle rect); + public static SkiaSharp.SKRect ToSKRect (this System.Drawing.RectangleF rect); + public static SkiaSharp.SKSizeI ToSKSize (this System.Drawing.Size size); + public static SkiaSharp.SKSize ToSKSize (this System.Drawing.SizeF size); +} +``` + +#### New Type: SkiaSharp.Views.Windows.SKPaintGLSurfaceEventArgs + +```csharp +public class SKPaintGLSurfaceEventArgs : System.EventArgs { + // constructors + public SKPaintGLSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget); + + [Obsolete ("Use SKPaintGLSurfaceEventArgs(SKSurface, GRBackendRenderTarget, SKColorType, GRSurfaceOrigin) instead.")] +public SKPaintGLSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTargetDesc renderTarget); + public SKPaintGLSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget, SkiaSharp.GRSurfaceOrigin origin, SkiaSharp.SKColorType colorType); + public SKPaintGLSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget, SkiaSharp.GRSurfaceOrigin origin, SkiaSharp.SKColorType colorType, SkiaSharp.GRGlFramebufferInfo glInfo); + // properties + public SkiaSharp.GRBackendRenderTarget BackendRenderTarget { get; } + public SkiaSharp.SKColorType ColorType { get; } + public SkiaSharp.GRSurfaceOrigin Origin { get; } + + [Obsolete ("Use BackendRenderTarget instead.")] +public SkiaSharp.GRBackendRenderTargetDesc RenderTarget { get; } + public SkiaSharp.SKSurface Surface { get; } +} +``` + +#### New Type: SkiaSharp.Views.Windows.SKPaintSurfaceEventArgs + +```csharp +public class SKPaintSurfaceEventArgs : System.EventArgs { + // constructors + public SKPaintSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.SKImageInfo info); + // properties + public SkiaSharp.SKImageInfo Info { get; } + public SkiaSharp.SKSurface Surface { get; } +} +``` + +#### New Type: SkiaSharp.Views.Windows.SKXamlCanvas + +```csharp +public class SKXamlCanvas : Microsoft.UI.Xaml.Controls.Canvas, Microsoft.UI.Composition.IAnimationObject, Microsoft.UI.Composition.IVisualElement, Microsoft.UI.Composition.IVisualElement2, System.IEquatable, System.IEquatable, System.IEquatable, System.IEquatable, System.IEquatable, System.Runtime.InteropServices.ICustomQueryInterface, WinRT.IWinRTObject { + // constructors + public SKXamlCanvas (); + // properties + public SkiaSharp.SKSize CanvasSize { get; } + public double Dpi { get; } + public bool IgnorePixelScaling { get; set; } + // events + public event System.EventHandler PaintSurface; + // methods + public void Invalidate (); + protected virtual void OnPaintSurface (SKPaintSurfaceEventArgs e); +} +``` + +#### New Type: SkiaSharp.Views.Windows.WindowsExtensions + +```csharp +public static class WindowsExtensions { + // methods + public static Windows.UI.Color ToColor (this SkiaSharp.SKColor color); + public static Windows.Foundation.Point ToPoint (this SkiaSharp.SKPoint point); + public static Windows.Foundation.Rect ToRect (this SkiaSharp.SKRect rect); + public static SkiaSharp.SKBitmap ToSKBitmap (this Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap bitmap); + public static SkiaSharp.SKColor ToSKColor (this Windows.UI.Color color); + public static SkiaSharp.SKImage ToSKImage (this Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap bitmap); + public static bool ToSKPixmap (this Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap bitmap, SkiaSharp.SKPixmap pixmap); + public static SkiaSharp.SKPoint ToSKPoint (this Windows.Foundation.Point point); + public static SkiaSharp.SKRect ToSKRect (this Windows.Foundation.Rect rect); + public static SkiaSharp.SKSize ToSKSize (this Windows.Foundation.Size size); + public static Windows.Foundation.Size ToSize (this SkiaSharp.SKSize size); + public static Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap ToWriteableBitmap (this SkiaSharp.SKBitmap skiaBitmap); + public static Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap ToWriteableBitmap (this SkiaSharp.SKImage skiaImage); + public static Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap ToWriteableBitmap (this SkiaSharp.SKPixmap pixmap); + public static Microsoft.UI.Xaml.Media.Imaging.WriteableBitmap ToWriteableBitmap (this SkiaSharp.SKPicture picture, SkiaSharp.SKSizeI dimensions); +} +``` + diff --git a/changelogs/SkiaSharp.Views.WindowsForms/2.80.3/SkiaSharp.Views.WindowsForms.md b/changelogs/SkiaSharp.Views.WindowsForms/2.80.3/SkiaSharp.Views.WindowsForms.md new file mode 100644 index 000000000..7ac0b262f --- /dev/null +++ b/changelogs/SkiaSharp.Views.WindowsForms/2.80.3/SkiaSharp.Views.WindowsForms.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.WindowsForms.dll + +## SkiaSharp.Views.WindowsForms.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Android.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Android.md new file mode 100644 index 000000000..e369675b6 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Android.md @@ -0,0 +1,16 @@ +# API diff: SkiaSharp.Views.Android.dll + +## SkiaSharp.Views.Android.dll + +### Namespace SkiaSharp.Views.Android + +#### Type Changed: SkiaSharp.Views.Android.SKCanvasView + +Added method: + +```csharp +protected override void OnAttachedToWindow (); +``` + + + diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Desktop.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Desktop.md new file mode 100644 index 000000000..9ffcfd2d1 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Desktop.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Desktop.dll + +## SkiaSharp.Views.Desktop.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Mac.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Mac.md new file mode 100644 index 000000000..1bc274432 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Mac.md @@ -0,0 +1,42 @@ +# API diff: SkiaSharp.Views.Mac.dll + +## SkiaSharp.Views.Mac.dll + +### Namespace SkiaSharp.Views.Mac + +#### New Type: SkiaSharp.Views.Mac.SKMetalView + +```csharp +public class SKMetalView : MetalKit.MTKView, AppKit.INSAccessibility, AppKit.INSAccessibilityElementProtocol, AppKit.INSAppearanceCustomization, AppKit.INSDraggingDestination, AppKit.INSTouchBarProvider, AppKit.INSUserInterfaceItemIdentification, CoreAnimation.ICALayerDelegate, Foundation.INSCoding, Foundation.INSObjectProtocol, MetalKit.IMTKViewDelegate, ObjCRuntime.INativeObject, System.ComponentModel.IComponent, System.IDisposable, System.IEquatable { + // constructors + public SKMetalView (); + public SKMetalView (CoreGraphics.CGRect frame); + public SKMetalView (IntPtr p); + public SKMetalView (CoreGraphics.CGRect frame, Metal.IMTLDevice device); + // properties + public SkiaSharp.SKSize CanvasSize { get; } + public SkiaSharp.GRContext GRContext { get; } + // events + public event System.EventHandler PaintSurface; + // methods + public override void AwakeFromNib (); + protected virtual void OnPaintSurface (SKPaintMetalSurfaceEventArgs e); +} +``` + +#### New Type: SkiaSharp.Views.Mac.SKPaintMetalSurfaceEventArgs + +```csharp +public class SKPaintMetalSurfaceEventArgs : System.EventArgs { + // constructors + public SKPaintMetalSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget); + public SKPaintMetalSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget, SkiaSharp.GRSurfaceOrigin origin, SkiaSharp.SKColorType colorType); + // properties + public SkiaSharp.GRBackendRenderTarget BackendRenderTarget { get; } + public SkiaSharp.SKColorType ColorType { get; } + public SkiaSharp.GRSurfaceOrigin Origin { get; } + public SkiaSharp.SKSurface Surface { get; } +} +``` + + diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Tizen.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Tizen.md new file mode 100644 index 000000000..576719cc5 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.Tizen.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.Tizen.dll + +## SkiaSharp.Views.Tizen.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.UWP.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.UWP.md new file mode 100644 index 000000000..65f4808e2 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.UWP.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.UWP.dll + +## SkiaSharp.Views.UWP.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.iOS.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.iOS.md new file mode 100644 index 000000000..cbf573f31 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.iOS.md @@ -0,0 +1,42 @@ +# API diff: SkiaSharp.Views.iOS.dll + +## SkiaSharp.Views.iOS.dll + +### Namespace SkiaSharp.Views.iOS + +#### New Type: SkiaSharp.Views.iOS.SKMetalView + +```csharp +public class SKMetalView : MetalKit.MTKView, CoreAnimation.ICALayerDelegate, Foundation.INSCoding, Foundation.INSObjectProtocol, MetalKit.IMTKViewDelegate, ObjCRuntime.INativeObject, System.Collections.IEnumerable, System.ComponentModel.IComponent, System.IDisposable, System.IEquatable, UIKit.IUIAccessibilityIdentification, UIKit.IUIAppearance, UIKit.IUIAppearanceContainer, UIKit.IUICoordinateSpace, UIKit.IUIDynamicItem, UIKit.IUIFocusEnvironment, UIKit.IUIFocusItem, UIKit.IUIFocusItemContainer, UIKit.IUILargeContentViewerItem, UIKit.IUIPasteConfigurationSupporting, UIKit.IUITraitEnvironment, UIKit.IUIUserActivityRestoring { + // constructors + public SKMetalView (); + public SKMetalView (CoreGraphics.CGRect frame); + public SKMetalView (IntPtr p); + public SKMetalView (CoreGraphics.CGRect frame, Metal.IMTLDevice device); + // properties + public SkiaSharp.SKSize CanvasSize { get; } + public SkiaSharp.GRContext GRContext { get; } + // events + public event System.EventHandler PaintSurface; + // methods + public override void AwakeFromNib (); + protected virtual void OnPaintSurface (SKPaintMetalSurfaceEventArgs e); +} +``` + +#### New Type: SkiaSharp.Views.iOS.SKPaintMetalSurfaceEventArgs + +```csharp +public class SKPaintMetalSurfaceEventArgs : System.EventArgs { + // constructors + public SKPaintMetalSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget); + public SKPaintMetalSurfaceEventArgs (SkiaSharp.SKSurface surface, SkiaSharp.GRBackendRenderTarget renderTarget, SkiaSharp.GRSurfaceOrigin origin, SkiaSharp.SKColorType colorType); + // properties + public SkiaSharp.GRBackendRenderTarget BackendRenderTarget { get; } + public SkiaSharp.SKColorType ColorType { get; } + public SkiaSharp.GRSurfaceOrigin Origin { get; } + public SkiaSharp.SKSurface Surface { get; } +} +``` + + diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.tvOS.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.tvOS.md new file mode 100644 index 000000000..f8e47f50e --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.tvOS.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.tvOS.dll + +## SkiaSharp.Views.tvOS.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.watchOS.md b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.watchOS.md new file mode 100644 index 000000000..2556d68a9 --- /dev/null +++ b/changelogs/SkiaSharp.Views/2.80.3/SkiaSharp.Views.watchOS.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Views.watchOS.dll + +## SkiaSharp.Views.watchOS.dll + +> No changes. diff --git a/changelogs/SkiaSharp.Vulkan.SharpVk/2.80.3/SkiaSharp.Vulkan.SharpVk.md b/changelogs/SkiaSharp.Vulkan.SharpVk/2.80.3/SkiaSharp.Vulkan.SharpVk.md new file mode 100644 index 000000000..ce2cf9898 --- /dev/null +++ b/changelogs/SkiaSharp.Vulkan.SharpVk/2.80.3/SkiaSharp.Vulkan.SharpVk.md @@ -0,0 +1,5 @@ +# API diff: SkiaSharp.Vulkan.SharpVk.dll + +## SkiaSharp.Vulkan.SharpVk.dll + +> No changes. diff --git a/changelogs/SkiaSharp/2.80.3/SkiaSharp.md b/changelogs/SkiaSharp/2.80.3/SkiaSharp.md new file mode 100644 index 000000000..ab09af6dc --- /dev/null +++ b/changelogs/SkiaSharp/2.80.3/SkiaSharp.md @@ -0,0 +1,100 @@ +# API diff: SkiaSharp.dll + +## SkiaSharp.dll + +### Namespace SkiaSharp + +#### Type Changed: SkiaSharp.GRContext + +Added property: + +```csharp +public bool IsAbandoned { get; } +``` + +Added methods: + +```csharp +public static GRContext CreateGl (GRContextOptions options); +public static GRContext CreateGl (GRGlInterface backendContext, GRContextOptions options); +public static GRContext CreateVulkan (GRVkBackendContext backendContext, GRContextOptions options); +``` + + +#### Type Changed: SkiaSharp.GRGlInterface + +Added method: + +```csharp +public static GRGlInterface CreateAngle (); +``` + + +#### Type Changed: SkiaSharp.SKData + +Added property: + +```csharp +public System.Span Span { get; } +``` + +Added methods: + +```csharp +public static SKData Create (long size); +public static SKData CreateCopy (IntPtr bytes, int length); +public static SKData CreateCopy (IntPtr bytes, long length); +``` + + +#### Type Changed: SkiaSharp.SKImage + +Added property: + +```csharp +public SKImageInfo Info { get; } +``` + + +#### Type Changed: SkiaSharp.SKPicture + +Added methods: + +```csharp +public static SKPicture Deserialize (SKData data); +public static SKPicture Deserialize (SKStream stream); +public static SKPicture Deserialize (System.IO.Stream stream); +public static SKPicture Deserialize (System.ReadOnlySpan data); +public static SKPicture Deserialize (IntPtr data, int length); +public SKData Serialize (); +public void Serialize (SKWStream stream); +public void Serialize (System.IO.Stream stream); +``` + + +#### Type Changed: SkiaSharp.SKSurface + +Added method: + +```csharp +public void Flush (); +``` + + +#### New Type: SkiaSharp.GRContextOptions + +```csharp +public class GRContextOptions { + // constructors + public GRContextOptions (); + // properties + public bool AllowPathMaskCaching { get; set; } + public bool AvoidStencilBuffers { get; set; } + public int BufferMapThreshold { get; set; } + public bool DoManualMipmapping { get; set; } + public int GlyphCacheTextureMaximumBytes { get; set; } + public int RuntimeProgramCacheSize { get; set; } +} +``` + + diff --git a/docs b/docs index cf4946f2f..344d2be82 160000 --- a/docs +++ b/docs @@ -1 +1 @@ -Subproject commit cf4946f2fbf2ca915820615de729d8622d9515f4 +Subproject commit 344d2be82b193e435bcf140b6e9771998ae7552f diff --git a/nuget/SkiaSharp.Views.WinUI.nuspec b/nuget/SkiaSharp.Views.WinUI.nuspec new file mode 100644 index 000000000..e6842a788 --- /dev/null +++ b/nuget/SkiaSharp.Views.WinUI.nuspec @@ -0,0 +1,47 @@ + + + + + + SkiaSharp.Views.WinUI + SkiaSharp Views & Layers for Windows (WinUI) + 1.0.0 + +SkiaSharp Views & Layers are a set of platform-specific views and containers that can be used to draw on the screen. + + +SkiaSharp Views & Layers are a set of platform-specific views and containers that can be used to draw on the screen. + + +Please visit https://go.microsoft.com/fwlink/?linkid=868517 to view the release notes. + + https://go.microsoft.com/fwlink/?linkid=868515 + https://go.microsoft.com/fwlink/?linkid=2130524 + ui xamarin graphics ios android linux windows uwp tvos watchos macos tizen cross-platform skiasharp + + + https://go.microsoft.com/fwlink/?linkid=868514 + Microsoft + Microsoft + true + © Microsoft Corporation. All rights reserved. + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/samples/Basic/Desktop/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/Desktop/SkiaSharpSample/SkiaSharpSample.csproj index 995130cf1..eecb870b6 100644 --- a/samples/Basic/Desktop/SkiaSharpSample/SkiaSharpSample.csproj +++ b/samples/Basic/Desktop/SkiaSharpSample/SkiaSharpSample.csproj @@ -46,7 +46,6 @@ - diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/LockScreenLogo.scale-200.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/LockScreenLogo.scale-200.png new file mode 100644 index 0000000000000000000000000000000000000000..735f57adb5dfc01886d137b4e493d7e97cf13af3 GIT binary patch literal 1430 zcmaJ>TTC2P7~aKltDttVHYH6u8Io4i*}3fO&d$gd*bA_<3j~&e7%8(eXJLfhS!M@! zKrliY>>6yT4+Kr95$!DoD(Qn-5TP|{V_KS`k~E6(LGS@#`v$hQo&^^BKsw3HIsZBT z_y6C2n`lK@apunKojRQ^(_P}Mgewt$(^BBKCTZ;*xa?J3wQ7~@S0lUvbcLeq1Bg4o zH-bvQi|wt~L7q$~a-gDFP!{&TQfc3fX*6=uHv* zT&1&U(-)L%Xp^djI2?~eBF2cxC@YOP$+9d?P&h?lPy-9M2UT9fg5jKm1t$m#iWE{M zIf%q9@;fyT?0UP>tcw-bLkz;s2LlKl2qeP0w zECS7Ate+Awk|KQ+DOk;fl}Xsy4o^CY=pwq%QAAKKl628_yNPsK>?A>%D8fQG6IgdJ ztnxttBz#NI_a@fk7SU`WtrpsfZsNs9^0(2a z@C3#YO3>k~w7?2hipBf{#b6`}Xw1hlG$yi?;1dDs7k~xDAw@jiI*+tc;t2Lflg&bM)0!Y;0_@=w%`LW^8DsYpS#-bLOklX9r?Ei}TScw|4DbpW%+7 zFgAI)f51s}{y-eWb|vrU-Ya!GuYKP)J7z#*V_k^Xo>4!1Yqj*m)x&0L^tg3GJbVAJ zJ-Pl$R=NAabouV=^z_t;^K*0AvFs!vYU>_<|I^#c?>>CR<(T?=%{;U=aI*SbZADLH z&(f2wz_Y0??Tf|g;?|1Znw6}6U43Q#qNRwv1vp9uFn1)V#*4p&%$mP9x&15^OaBiDS(XppT|z^>;B{PLVEbS3IFYV yGvCsSX*m literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/SplashScreen.scale-200.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/SplashScreen.scale-200.png new file mode 100644 index 0000000000000000000000000000000000000000..023e7f1feda78d5100569825acedfd213a0d84e9 GIT binary patch literal 7700 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 literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square150x150Logo.scale-200.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square150x150Logo.scale-200.png new file mode 100644 index 0000000000000000000000000000000000000000..af49fec1a5484db1d52a7f9b5ec90a27c7030186 GIT binary patch literal 2937 zcma)84OCO-8BSud5)jwMLRVKgX(S?$n?Ld|vrsm<$CF7)&zTbyy1FE5bU`Q17MRv`9ue$;R(@8kR;#vJ*IM0>cJIAOte!d7oRgdH zd%ySjdB6L9=gX^A6)VzH7p2l@v~3zJAMw|DFy#^)F@@F*`mqUn=Il>l)8_+ab;nOW{%+iPx z+s{Eu|&pIs)Z7{La9~?xKfyl z#43?gjEL15d4WbOZo#SiP%>DB^+BcnJ=7dHEe;r#G=tuw|ka z%q@}##Uh7;tc%L_64m(kHtw74ty%BJMb)_1)#S0j`)F8_1jF7vScpsnH=0V19bO8y zR`0SjIdCUo&=>JwMQF8KHA<{ODHTiQh}0^@5QRmCA?gOH6_H3K^-_sNB^RrdNuK-R zOO*vOrKCVvDwgUck`kF(E7j{I#iiN;b*ZdCt4m@HPA`EuEqGGf4%!K<;(=I=&Vyrw z%TwcWtxa}8mCZ%Cyf&ActJ6_$ox5z6-D!0-dvnRx6t7y3d+h6QYpKWO;8OdnvERo7 zuEf>ih5`wqY)~o@OeVt-wM?Q!>QzdGRj!bz6fzYrfw$hZfAKzr2-M+D+R>}~oT574c;_3zquHcElqKIsryILt3g8n3jcMb+j?i?-L3FpZJ z2WRVBRdDPc+G5aaYg#5hpE+6nQ|(VSoxT3|biF;BUq#==-27Xi=gihDPYP$7?=9cP zYKE$jeQ|3~_L0VG-(F~2ZPyD0=k{J4Q~h(t__{-mz_w8{JDY9{`1ouzz!Vr5!ECdE z6U~O1k8c}24V7~zzXWTV-Pe4)y}wQJS&q%H5`Fo_f_JvIU489aCX$;P`u#!I-=^4ijC2{&9!O&h>mi?9oYD=GC#%)6{GzN6nQYw+Fal50!#x^asjBBR50i`+mho*ttoqV)ubM2KD9S~k7+FR4>{29?6 z{!l6kDdyTN0YJ9LgkPWeXm|gyi@zM3?0@{&pXT12w|78&W-q!RRF)&iLCEZVH<|fR zN0fr2^t8H(>L?>K#>^+jWROLral(Qy-xoBq1U7A&DV||wClb)Otd9?(gZ|8znMF}D zf<1haWz^s0qgecz;RFGt0C-B4g`jNGHsFU+;{<%t65v^sjk^h$lmWn#B0#_)9ij&d z-~lc`A)YYExi^7sBuPM^Y|wA2g*5?`K?#7tzELQYNxGo$UB$4J8RJp1k(8Jj+~hMT zlN~>M@KTTh^--8y3PK_NZ@AC!{PT=CziBzGd+wTJ^@icH!Bd}%)g8V)%K?|c&WTUk zy}qv1C%(fjRoZ4ozC3{O%@5?)XzH35zHns$pgU*Q?fj4v?fp1Qbm+j;3l;9jam9Da zXVcKjPlQ73x78QPu|Ffm6x?`~e3oD=gl=4kYK?={kD5j~QCXU)`HSdduNNENzA*2$ zOm3PzF!lN5e*06-f1Uot67wY#{o-S1!KZ7E=!~7ynnk9_iJR#kFoNbAOT#^2Gd17F zMmvU6>lndZQGd|ax9kUoXXO+$N?|j@6qpsF&_j7YXvwo_C{JpmLw5&#e6k>atv%es z5)7r*Wvv_JkUpT}M!_o!nVlEk1Zbl=a*2hQ*<|%*K1Glj^FcF`6kTzGQ3lz~2tCc@ z&x|tj;aH&1&9HwcJBcT`;{?a+pnej;M1HO(6Z{#J!cZA04hnFl;NXA+&`=7bjW_^o zfC40u3LMG?NdPtwGl>Tq6u}*QG)}-y;)lu-_>ee3kibW(69n0$0Zy!}9rQz%*v1iO zT9_H>99yIrSPYVy6^);rR}7Yo=J_T@hi+qhTZXnVWyf;JDYm5#eYLTxr*?kiNn!+Y zQ+LUkBafNJ#rH#C(?d5^;gw9o#%daEI{mA*LHPIHPU`#|H$hD zwm>0&+kahQ)E#%~k>&5@&#Vg82H?s%71=)(soi@174pi9--2{w{1$}Sz4zGn3Du&x bht0Iza^2ykEt4(epJ78uh5nDlX8(TxzDYwP literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.scale-200.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.scale-200.png new file mode 100644 index 0000000000000000000000000000000000000000..ce342a2ec8a61291ba76c54604aea7e9d20af11b GIT binary patch literal 1647 zcmaJ?eM}Q)7(e+G1Q(|`V9JhTI2>MkceK4;p;PR&$Pi?ejk3YQ_3o`S&|W_dsOZ8# zWPTt69g`t$ab`0cj-Y0yiBSOqmd)tG7G(}M5aP0_%&9TijB#&)I{zSE^4@#z^FF`l z`8{8`o%wlL(UI|y2!cdsuVamHH~H86F!*-15em4)NqUpCQM5?aoC_eCf@lV4wvF2a zjDQn1JBL69f&@2M3rvzJcfE!eZ8FZUBlFlC5RD)it33{mF9#B82AiyQE%w)`vlwa> zv{<1sm&kSKK$&%2jSFn7$t&P%%6Ue>R=EAnG8N7fqynWG8L3p!4801a;8{+nliO(qd(jNJ_?+9W3#hLIDLoT6~3fx9=`CC-D}-AMrpEO7HK zt3$GicGPc?GmDjy7K2P@La;eu4!$zWCZ`ym{Z$b zu-O6RM&K4JT|BIZB`E-gxqG%FzanI#+2FFmqHqXG7yxWB=w55RGOM)$xMb(>kSNR z2w=1AZi%z=AmG~yea~XaXJR!v7vLn(RUnELfiB1|6D84ICOS}^Zo2AdN}<&*h}G_u z{xZ!(%>tLT3J3<5XhWy-tg+6)0nmUUENLW8TWA{R6bgVd3X;anYFZ^IRis*_P-C-r z;i>%1^eL3UI2-{w8nuFFcs0e~7J{O2k^~Ce%+Ly4U?|=!0LH=t6()xi<^I-rs+9sF z*q{E-CxZbGPeu#a;XJwE;9S1?#R&uns>^0G3p`hEUF*v`M?@h%T%J%RChmD|EVydq zmHWh*_=S%emRC*mhxaVLzT@>Z2SX0u9v*DIJ@WC^kLVdlGV6LpK$KIrlJqc zpJ921)+3JJdTx|<`G&kXpKkjGJv=76R`yYIQ{#c-`%+`#V(7}Q;&@6U8!Td1`d;?N z_9mnI#?AA}4J!r)LN4!E-@H5eXauuB7TOawS>Y|{-P?NNx-lq+z1W-+y(;39P&&LP zL{N80?&=C*qKmdA^moMZRuPcD!B<*mq$ch=0Cnlitw#txRWhb3%TQvPqjkC`F69G4b! ze7z9MZ#+;_#l?H37UqUhDFb^l&s2{oM$3I0o^Q!yx;;V)QmCMo)Tb_ui|mit8MS?U zm##6$sZZ1$@|s%?l@>4Z<*Q}sRBSKMhb4I{e5LdEhsHIHTe8Bod5c>6QtT>$XgUBz z6MK`kO$=jmt@FqggOhJ5j~e@ygRbG;<{Vu)*+nn9aQeo0;$#j;|MS=S$&L?BeV25z xs3B`@=#`5TF{^6(A1rvdY@|-RtQ|iS5{tyX+wH?;n8E)G$kykv-D^wh{{!TZT%7;_ literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.targetsize-24_altform-unplated.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Square44x44Logo.targetsize-24_altform-unplated.png new file mode 100644 index 0000000000000000000000000000000000000000..f6c02ce97e0a802b85f6021e822c89f8bf57d5cd GIT binary patch literal 1255 zcmaJ>TWs4@7*5+{G#S+&C!qC#> zf>5N3P6jO*Cz>ug*(_DmW=)kea&m$gZ^+nyiF`;j%w@}y8)>p*SH}C`m?DXeieF2U zyQHecc_L%Gh!7GMt+hG06y;+|p4>m~}PjA}rKViGiEnn7G0ZO<>G|7q;2?NwGCM3s?eued6%hd$B+ z*kQJ{#~$S=DFE(%=E+UkmlEI*%3llUf~8Ja9YU1Vui0IbGBkW_gHB%Rd&!!ioX zs40O?i9I{};kle7GMvE7(rk`la=gTI)47=>%?q@^iL-nUo3}h4S}N-KHn8t5mVP8w z&bSErwp+37 zNJJ8?a|{r5Q3R0Z5s-LB1WHOwYC@7pCHWND#cL1cZ?{kJ368_*(UDWUDyb<}0y@o# zfMF016iMWPCb6obAxT$JlB6(2DrlXDTB&!0`!m??4F(qWMhjVZo?JXQmz`1*58Z=& zcDmB|S-E@j?BoFGix0flckqdS4jsPNzhfWyWIM98GxcLs89C(~dw%$_t;JjX-SD}E zfiGV;{8Q%8r}w9x>EEigW81>`kvnU@pK)4+xk9@+bNj9L!AAZ@SZ@q|)&BmY3+HZx zul~BeG4|}-;L%cHViQGQX?^zFfO0&#cHwel=d`lH9sJ-@Sl@n*(8J2>%Ac`IxyY?Q z{=GhWvC#gu-~Ia7*n{=+;qM?Ul_wy1+u7ho;=`>EwP^g~R@{unBds`!#@}tluZQpS zm)M~nYEifJWJGx?_6DcTy>#uh%>!H9=hb^(v`=m3F1{L>db=<5_tm+_&knAQ2EU$s Mu9UqpbNZeC0BbUo^Z)<= literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/StoreLogo.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/StoreLogo.png new file mode 100644 index 0000000000000000000000000000000000000000..7385b56c0e4d3c6b0efe3324aa1194157d837826 GIT binary patch literal 1451 zcmaJ>eN5D57_Z|bH;{0+1#mbl)eTU3{h)Wf7EZV?;HD@XL@{B`Ui%(2aMxQ~xdXSv z5nzWi(LW)U2=Vc-cY@s7nPt{i0hc6!7xN4NNHI#EQl>YNBy8l4%x9gr_W-j zEZMQmmTIy(>;lblRfh`dIyTgc9W5d!VP$L4(kKrN1c5G~(O_#xG zAJCNTstD^5SeXFB+&$h=ToJP2H>xr$iqPs-#O*;4(!Fjw25-!gEb*)mU}=)J;Iu>w zxK(5XoD0wrPSKQ~rbL^Cw6O_03*l*}i=ydbu7adJ6y;%@tjFeXIXT+ms30pmbOP%Q zX}S;+LBh8Tea~TSkHzvX6$rYb)+n&{kSbIqh|c7hmlxmwSiq5iVhU#iEQ<>a18|O^Sln-8t&+t`*{qBWo5M?wFM(JuimAOb5!K#D}XbslM@#1ZVz_;!9U zpfEpLAOz=0g@bd6Xj_ILi-x^!M}73h^o@}hM$1jflTs|Yuj9AL@A3<-?MV4!^4q`e z)fO@A;{9K^?W?DbnesnPr6kK>$zaKo&;FhFd(GYFCIU^T+OIMb%Tqo+P%oq(IdX7S zf6+HLO?7o0m+p>~Tp5UrXWh!UH!wZ5kv!E`_w)PTpI(#Iw{AS`gH4^b(bm^ZCq^FZ zY9DD7bH}rq9mg88+KgA$Zp!iWncuU2n1AuIa@=sWvUR-s`Qb{R*kk(SPU^`$6BXz8 zn#7yaFOIK%qGxyi`dYtm#&qqox0$h=pNi#u=M8zUG@bpiZ=3sT=1}Trr}39cC)H|v zbL?W)=&s4zrh)7>L(|cc%$1#!zfL?HjpeP%T+x_a+jZ16b^iKOHxFEX$7d|8${H-* zIrOJ5w&i$>*D>AKaIoYg`;{L@jM((Kt?$N$5OnuPqVvq**Nm}(f0wwOF%iX_Pba;V z;m@wxX&NcV3?<1+u?A{y_DIj7#m3Af1rCE)o`D&Y3}0%7E;iX1yMDiS)sh0wKi!36 zL!Wmq?P^Ku&rK~HJd97KkLTRl>ScGFYZNlYytWnhmuu|)L&ND8_PmkayQb{HOY640 bno1(wj@u8DCVuFR|31B*4ek@pZJqxCDDe1x literal 0 HcmV?d00001 diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Wide310x150Logo.scale-200.png b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/Images/Wide310x150Logo.scale-200.png new file mode 100644 index 0000000000000000000000000000000000000000..288995b397fdbef1fb7e85afd71445d5de1952c5 GIT binary patch literal 3204 zcmbVPeQXow8NYmBd90>}0NP?GhXW~VaeThm=a0tV#EwJMI!)6M3}|c4_Bl3=Kd>G0 z(GHx1wl<7(tP?FsOQkTilSo*iIvF%uArExJ73~P zSv1xEy!U(Wd4A9D`FQV@W3@F^qJ@PEF$@z`Z!*BbFsS(^?B zyiAzJ+q})bkgiQHWqEb*jJD-coHYr1^iocg)l!Qa{Xqs-l~6J}p-|##ZHYofskQ3$ zI0;xzXyhazBeXhIsg5A=%ufo@f)1yy&ScKS0;HF^!r_2UE^lpZEom(+@duma3awTv zCrCL-%D_SvYWIcdHkmI}#50(fkUi)Qgx!80ju>g1za^}ff>JI8Z@^-iCiaCgg@TgF z+vtE?Q9{VQUX&MW9SYYmGcxA14%N2@7FwBTD4N<(2{nWgV8$e3?-F=L^&FrtWn~(U_Q~~^uYiyeY6-KoTnfh9AWz@ zIKje0)u!_Lw)E}G!#kEfwKVdNt(UAf9*f>tEL_(=xco-T%jTi@7YlC3hs2ik%Le0H ztj}RTeCF(5mwvi3_56>-yB?l;J>-1%!9~=fs|QcNG3J~a@JCu`4SB460s0ZO+##4fFUSGLcj_ja^fL4&BKALfb#$6$O?>P@qx2Agl^x0i&ugt zsy5Pyu=()`7HRMG3IB7F1@`_ z+-!J%#i6e^U$e#+C%Q>_qVRzWRsG^W_n+@OcX@vzI&z;mzHNb!GQ?LWA(wtpqHqTM z1OFw_{Zn?fD)p)`c`kOgv{de=v@suGRqY{N^U7gI1VF3*F=obwaXI6ob5__Yn zVTguS!%(NI09J8x#AO_aW!9W7k*UvB;IWDFC3srwftr{kHj%g)fvnAm;&h_dnl~

MY- zf+K}sCe8qU6Ujs`3ua{U0Of$R_gVQBuUA za0v=mu#vIOqiiAZOr&h*$WyOw&k-xr$;G4Ixa!#TJNr>95(h>l%)PUy4p+^SgR(uR zta%k*?ny-+nAr8spEk1fo{J4i!b^Fia`N{_F6@zidA2ZTTrjl#^5Z-2KfB@Cu}l9s z(*|Z2jc?p~vn2f)3y9i*7zJV1L{$?|&q)4oaT;uXi6>1GkRXVTOzAz(RHEmr=eFIi z`}<>-Q?K0GN8!IYxeP1XKXO+jsJbp~o^);Bc;%b7Flpe7;1`Ny@3r7ZR;?R)aJt8C ziNlEC<@3f_lIV4TwV}&e;D!Ee5_|e#g0LUh=5vmYWYm7&2h*M>QPKvGh9-)wfMMW3 z8J9b%1k7dzPzO0_NGQy92BZ^FR6R~6;^6?lqO;-QUP4BY%cG%3vEhbm#>4vIhPBh3 z-+pZGjh$x%Hp{?=FHsMp0&wNPlj00us{&`1ZOZTqs8%4X&xH=UDr*xyBW(Zp&Em94 zf)ZSfn#yg0N)>!1kWdkqJ^S*z0FF5|fj&qcE#Na|%OY0$uO>!&hP+1ywfD_WXk@4J(?MBftK7>$Nvqh@tDuarN%PrTLQ2Uzysx>UV=V zk^RrDSvdQ?0;=hY67EgII-f4`t=+i*yS=Y~!XlqIy_4x&%+OdfbKOFPXS2X5%4R{N z$SQMX^AK6(fA + + + + + + + SkiaSharpSample + matthew + Images\StoreLogo.png + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/SkiaSharpSample.Package.wapproj b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/SkiaSharpSample.Package.wapproj new file mode 100644 index 000000000..85dcff5ab --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample.Package/SkiaSharpSample.Package.wapproj @@ -0,0 +1,75 @@ + + + + 15.0 + + + + Debug + x86 + + + Release + x86 + + + Debug + x64 + + + Release + x64 + + + Debug + arm64 + + + Release + arm64 + + + + $(MSBuildExtensionsPath)\Microsoft\DesktopBridge\ + SkiaSharpSample\ + + + + bf0aea36-d579-49ee-a589-705d3d81feb1 + 10.0.19041.0 + 10.0.17763.0 + en-US + false + ..\SkiaSharpSample\SkiaSharpSample.csproj + net5.0-windows$(TargetPlatformVersion);$(AssetTargetFallback) + + + + Designer + + + + + + + + + + + + + + True + Properties\PublishProfiles\win10-$(Platform).pubxml + + + + + build + + + build + + + + \ No newline at end of file diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample.sln b/samples/Basic/WinUI/Desktop/SkiaSharpSample.sln new file mode 100644 index 000000000..2995519ab --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample.sln @@ -0,0 +1,107 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.31025.218 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{C7167F0D-BC9F-4E6E-AFE1-012C56B48DB5}") = "SkiaSharpSample.Package", "SkiaSharpSample.Package\SkiaSharpSample.Package.wapproj", "{8287A10F-D119-4EBF-9CD7-1D697A476D6F}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SkiaSharpSample", "SkiaSharpSample\SkiaSharpSample.csproj", "{71668276-ECDD-49EC-9406-27A9D2676139}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SkiaSharp", "..\..\..\..\binding\SkiaSharp\SkiaSharp.csproj", "{EA2AC287-6FEF-415D-BD33-01287DD11574}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SkiaSharp.Views.WinUI", "..\..\..\..\source\SkiaSharp.Views.WinUI\SkiaSharp.Views.WinUI\SkiaSharp.Views.WinUI.csproj", "{B9E319D8-0A0E-471C-BD01-8015655FBD99}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Debug|arm64 = Debug|arm64 + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|Any CPU = Release|Any CPU + Release|arm64 = Release|arm64 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|Any CPU.ActiveCfg = Debug|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|arm64.ActiveCfg = Debug|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|arm64.Build.0 = Debug|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|arm64.Deploy.0 = Debug|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x64.ActiveCfg = Debug|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x64.Build.0 = Debug|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x64.Deploy.0 = Debug|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x86.ActiveCfg = Debug|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x86.Build.0 = Debug|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Debug|x86.Deploy.0 = Debug|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|Any CPU.ActiveCfg = Release|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|arm64.ActiveCfg = Release|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|arm64.Build.0 = Release|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|arm64.Deploy.0 = Release|arm64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x64.ActiveCfg = Release|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x64.Build.0 = Release|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x64.Deploy.0 = Release|x64 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x86.ActiveCfg = Release|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x86.Build.0 = Release|x86 + {8287A10F-D119-4EBF-9CD7-1D697A476D6F}.Release|x86.Deploy.0 = Release|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|Any CPU.ActiveCfg = Debug|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|arm64.ActiveCfg = Debug|arm64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|arm64.Build.0 = Debug|arm64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|x64.ActiveCfg = Debug|x64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|x64.Build.0 = Debug|x64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|x86.ActiveCfg = Debug|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Debug|x86.Build.0 = Debug|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|Any CPU.ActiveCfg = Release|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|arm64.ActiveCfg = Release|arm64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|arm64.Build.0 = Release|arm64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|x64.ActiveCfg = Release|x64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|x64.Build.0 = Release|x64 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|x86.ActiveCfg = Release|x86 + {71668276-ECDD-49EC-9406-27A9D2676139}.Release|x86.Build.0 = Release|x86 + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|Any CPU.Build.0 = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|arm64.ActiveCfg = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|arm64.Build.0 = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|x64.ActiveCfg = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|x64.Build.0 = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|x86.ActiveCfg = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Debug|x86.Build.0 = Debug|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|Any CPU.ActiveCfg = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|Any CPU.Build.0 = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|arm64.ActiveCfg = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|arm64.Build.0 = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|x64.ActiveCfg = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|x64.Build.0 = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|x86.ActiveCfg = Release|Any CPU + {EA2AC287-6FEF-415D-BD33-01287DD11574}.Release|x86.Build.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|Any CPU.Build.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|Any CPU.Deploy.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|arm64.ActiveCfg = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|arm64.Build.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|arm64.Deploy.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x64.ActiveCfg = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x64.Build.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x64.Deploy.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x86.ActiveCfg = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x86.Build.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Debug|x86.Deploy.0 = Debug|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|Any CPU.ActiveCfg = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|Any CPU.Build.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|Any CPU.Deploy.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|arm64.ActiveCfg = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|arm64.Build.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|arm64.Deploy.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x64.ActiveCfg = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x64.Build.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x64.Deploy.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x86.ActiveCfg = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x86.Build.0 = Release|Any CPU + {B9E319D8-0A0E-471C-BD01-8015655FBD99}.Release|x86.Deploy.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {F5AABA3E-0272-4E88-A2B4-BD422E83400E} + EndGlobalSection +EndGlobal diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml b/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml new file mode 100644 index 000000000..4ef7c6d3a --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml @@ -0,0 +1,15 @@ + + + + + + + + + + + diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml.cs b/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml.cs new file mode 100644 index 000000000..bd738d2ee --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/App.xaml.cs @@ -0,0 +1,20 @@ +using Microsoft.UI.Xaml; + +namespace SkiaSharpSample +{ + public partial class App : Application + { + private Window window; + + public App() + { + InitializeComponent(); + } + + protected override void OnLaunched(LaunchActivatedEventArgs args) + { + window = new MainWindow(); + window.Activate(); + } + } +} diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml b/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml new file mode 100644 index 000000000..97823c096 --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml @@ -0,0 +1,13 @@ + + + + + diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml.cs b/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml.cs new file mode 100644 index 000000000..9a4d6f10f --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/MainWindow.xaml.cs @@ -0,0 +1,42 @@ +using Microsoft.UI.Xaml; +using SkiaSharp; +using SkiaSharp.Views.Windows; + +namespace SkiaSharpSample +{ + public sealed partial class MainWindow : Window + { + public MainWindow() + { + InitializeComponent(); + } + + private void OnPaintSurface(object sender, SKPaintSurfaceEventArgs e) + { + // the the canvas and properties + var canvas = e.Surface.Canvas; + + // get the screen density for scaling + var scale = (float)((SKXamlCanvas)sender).XamlRoot.RasterizationScale; + var scaledSize = new SKSize(e.Info.Width / scale, e.Info.Height / scale); + + // handle the device screen density + canvas.Scale(scale); + + // make sure the canvas is blank + canvas.Clear(SKColors.White); + + // draw some text + var paint = new SKPaint + { + Color = SKColors.Black, + IsAntialias = true, + Style = SKPaintStyle.Fill, + TextAlign = SKTextAlign.Center, + TextSize = 24 + }; + var coord = new SKPoint(scaledSize.Width / 2, (scaledSize.Height + paint.TextSize) / 2); + canvas.DrawText("SkiaSharp", coord, paint); + } + } +} diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/SkiaSharpSample.csproj b/samples/Basic/WinUI/Desktop/SkiaSharpSample/SkiaSharpSample.csproj new file mode 100644 index 000000000..295bb0384 --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/SkiaSharpSample.csproj @@ -0,0 +1,29 @@ + + + + WinExe + net5.0-windows10.0.19041.0 + 10.0.17763.0 + SkiaSharpSample + app.manifest + x86;x64;arm64 + win10-x86;win10-x64;win10-arm64 + + + + + + + + + + + + + + + + + + + diff --git a/samples/Basic/WinUI/Desktop/SkiaSharpSample/app.manifest b/samples/Basic/WinUI/Desktop/SkiaSharpSample/app.manifest new file mode 100644 index 000000000..3b144ccbc --- /dev/null +++ b/samples/Basic/WinUI/Desktop/SkiaSharpSample/app.manifest @@ -0,0 +1,15 @@ + + + + + + + + true/PM + PerMonitorV2, PerMonitor + + + diff --git a/samples/Directory.Build.props b/samples/Directory.Build.props new file mode 100644 index 000000000..1789d43dc --- /dev/null +++ b/samples/Directory.Build.props @@ -0,0 +1,8 @@ + + + + + true + + + \ No newline at end of file diff --git a/samples/Directory.Build.targets b/samples/Directory.Build.targets new file mode 100644 index 000000000..148cf106a --- /dev/null +++ b/samples/Directory.Build.targets @@ -0,0 +1,12 @@ + + + + + + UAP + + + + \ No newline at end of file diff --git a/source/SkiaSharp.Build.props b/source/SkiaSharp.Build.props index 71a947565..c0646a46c 100644 --- a/source/SkiaSharp.Build.props +++ b/source/SkiaSharp.Build.props @@ -30,6 +30,11 @@ true + + + true + + $([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows))) $([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::OSX))) diff --git a/source/SkiaSharp.Build.targets b/source/SkiaSharp.Build.targets index a0305531b..e2fc8306a 100644 --- a/source/SkiaSharp.Build.targets +++ b/source/SkiaSharp.Build.targets @@ -51,9 +51,18 @@ - + + + + + UAP + + +