Merge branch 'main' into darc-main-f514bd6d-d72e-4bd4-88ed-19db4ff9175a
This commit is contained in:
Коммит
fe8f1a73c7
|
@ -49,7 +49,7 @@ Xamarin.Forms | Dependent on native platform support (noted above) |
|
|||
* Fonts - You can access fonts with a common API
|
||||
* Attributed text - You can draw attributed text with a common API
|
||||
* Bitmaps - You can create and draw on bitmap images with a common API
|
||||
* PDF - You can create PDF's using a common API
|
||||
* PDF - You can create PDFs using a common API
|
||||
|
||||
# Known Limitations
|
||||
* Attributed text is not currently supported with SkiaSharp
|
||||
|
|
|
@ -2,18 +2,25 @@ variables:
|
|||
BuildVersion: $[counter('release-counter', 1)]
|
||||
IsRunningOnCI: true
|
||||
DotNet.Cli.Telemetry.OptOut: true
|
||||
provisioningVS: true
|
||||
provisionator.path: '$(System.DefaultWorkingDirectory)/eng/provisioning/provisioning.csx'
|
||||
provisionator.vs: '$(System.DefaultWorkingDirectory)/eng/provisioning/vs.csx'
|
||||
provisionator.extraArguments: '--v'
|
||||
signingCondition: and(succeeded(), or(eq(variables['Sign'], 'true'), or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), or(startsWith(variables['Build.SourceBranch'],'refs/tags/'), startsWith(variables['Build.SourceBranch'],'refs/heads/release/') ))))
|
||||
signingCondition: or(eq(variables['Sign'], 'true'),
|
||||
or(eq(variables['Build.SourceBranch'], 'refs/heads/main'),
|
||||
or(startsWith(variables['Build.SourceBranch'],'refs/tags/'), startsWith(variables['Build.SourceBranch'],'refs/heads/release/') )
|
||||
)
|
||||
)
|
||||
|
||||
parameters:
|
||||
- name: BuildConfigurations
|
||||
type: object
|
||||
default:
|
||||
- Debug
|
||||
- Release
|
||||
- name: Debug
|
||||
poolName: $(windowsNet6VmPool)
|
||||
vmImage: $(windowsNet6VmImage)
|
||||
- name: Release
|
||||
poolName: $(windowsNet6VmPool)
|
||||
vmImage: $(windowsNet6VmPool)
|
||||
|
||||
trigger:
|
||||
branches:
|
||||
|
@ -62,20 +69,21 @@ resources:
|
|||
type: github
|
||||
name: xamarin/yaml-templates
|
||||
endpoint: xamarin
|
||||
ref: refs/heads/main # still defaults to master even though main is the main branch
|
||||
ref: refs/heads/main
|
||||
|
||||
stages:
|
||||
- stage: windows
|
||||
displayName: Build Windows
|
||||
jobs:
|
||||
- ${{ each BuildConfiguration in parameters.BuildConfigurations }}:
|
||||
- job: win_hosted_${{ BuildConfiguration }}
|
||||
- job: win_hosted_${{ BuildConfiguration.name }}
|
||||
workspace:
|
||||
clean: all
|
||||
displayName: Build Windows Phase (${{ BuildConfiguration }})
|
||||
displayName: Build Windows Phase (${{ BuildConfiguration.name }})
|
||||
timeoutInMinutes: 60
|
||||
pool:
|
||||
vmImage: windows-2022
|
||||
name: ${{ BuildConfiguration.poolName }}
|
||||
vmImage: ${{ BuildConfiguration.vmImage }}
|
||||
steps:
|
||||
|
||||
- template: /eng/pipelines/common/provision.yml
|
||||
|
@ -97,14 +105,6 @@ stages:
|
|||
- pwsh: dotnet tool restore
|
||||
displayName: install dotnet tools
|
||||
|
||||
|
||||
- pwsh: |
|
||||
& dotnet vs where --prop=InstallationPath
|
||||
displayName: list vs installs
|
||||
|
||||
- pwsh: echo "##vso[task.setvariable variable=JAVA_HOME]$(JAVA_HOME_11_X64)"
|
||||
displayName: Select JDK 11
|
||||
|
||||
- pwsh: |
|
||||
[xml] $fileXml = Get-Content "eng\Versions.props"
|
||||
$DotNetVersion = $fileXml.SelectSingleNode("Project/PropertyGroup/MicrosoftDotnetSdkInternalPackageVersion").InnerText
|
||||
|
@ -122,11 +122,6 @@ stages:
|
|||
displayName: install .NET
|
||||
errorActionPreference: stop
|
||||
|
||||
#- pwsh: |
|
||||
# rm $env:DOTNET_ROOT\metadata\workloads\6.0.200\installertype\msi
|
||||
# displayName: don't use msi .net
|
||||
# errorActionPreference: stop
|
||||
|
||||
- pwsh: |
|
||||
dotnet build ./build/DotNet/DotNet.csproj -p:DotNetDirectory="$env:DOTNET_ROOT" -p:InstallDotNet=false
|
||||
displayName: install dotnet workloads
|
||||
|
@ -143,10 +138,7 @@ stages:
|
|||
.\winsdksetup.exe /norestart /quiet | Out-Null
|
||||
dir "C:\Program Files (x86)\Windows Kits\10\References\"
|
||||
displayName: install Windows 10 SDK, version 1903 (10.0.18362.1)
|
||||
|
||||
- pwsh: |
|
||||
& 'C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Current\Bin\MSBuild.exe' /r /m ./build/Build.Microsoft.Maui.Graphics.Windows.sln /p:Configuration=${{ BuildConfiguration }} /bl:$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration }}.binlog
|
||||
displayName: build classic solutions
|
||||
condition: eq(variables['provisioningWindowsSdk'], 'true')
|
||||
|
||||
- pwsh: |
|
||||
# $VS_ROOT = (& dotnet vs where --prop=InstallationPath)[0]
|
||||
|
@ -159,7 +151,11 @@ stages:
|
|||
errorActionPreference: stop
|
||||
|
||||
- pwsh: |
|
||||
& $env:MSBUILD_EXE /r /m ./Microsoft.Maui.Graphics-net6.sln /p:Configuration=${{ BuildConfiguration }} /bl:$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration }}-net6.binlog
|
||||
& $env:MSBUILD_EXE /r /m ./build/Build.Microsoft.Maui.Graphics.Windows.sln /p:Configuration=${{ BuildConfiguration.name }} /bl:$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration.name }}.binlog
|
||||
displayName: build classic solutions~
|
||||
|
||||
- pwsh: |
|
||||
& $env:MSBUILD_EXE /r /m ./Microsoft.Maui.Graphics-net6.sln /p:Configuration=${{ BuildConfiguration.name }} /bl:$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration.name }}-net6.binlog
|
||||
displayName: build net6 solutions
|
||||
|
||||
- task: NuGetCommand@2
|
||||
|
@ -167,8 +163,8 @@ stages:
|
|||
inputs:
|
||||
command: 'pack'
|
||||
packagesToPack: '**\Microsoft.Maui.*.nuspec'
|
||||
packDestination: '$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration }}'
|
||||
configuration: ${{ BuildConfiguration }}
|
||||
packDestination: '$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration.name }}'
|
||||
configuration: ${{ BuildConfiguration.name }}
|
||||
basePath: '$(System.DefaultWorkingDirectory)'
|
||||
versioningScheme : 'byEnvVar'
|
||||
versionEnvVar: 'BUILD_BUILDNUMBER'
|
||||
|
@ -178,7 +174,7 @@ stages:
|
|||
inputs:
|
||||
Contents: |
|
||||
**/SignList.xml
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration }}'
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)/${{ BuildConfiguration.name }}'
|
||||
flattenFolders: true
|
||||
|
||||
- task: PublishBuildArtifacts@1
|
||||
|
@ -203,19 +199,29 @@ stages:
|
|||
signedArtifactName: nuget
|
||||
signedArtifactPath: signed
|
||||
displayName: Sign Phase
|
||||
condition: ${{ variables['signingCondition'] }}
|
||||
condition: and(succeeded(), ${{ variables['signingCondition'] }} )
|
||||
|
||||
- stage: sbom
|
||||
displayName: 'Software Bill of Materials'
|
||||
${{ if not(variables['signingCondition']) }}:
|
||||
dependsOn: [ 'windows' ]
|
||||
${{ if variables['signingCondition'] }}:
|
||||
dependsOn: [ 'nuget_signing' ]
|
||||
dependsOn: [ 'windows', 'nuget_signing' ]
|
||||
condition: succeeded('windows')
|
||||
jobs:
|
||||
- template: compliance/sbom/job.v1.yml@xamarin-templates
|
||||
parameters:
|
||||
jobName: SBOM_PR
|
||||
jobDisplayName: 'Software Bill of Materials (PR)'
|
||||
artifactNames: ['nuget']
|
||||
${{ if variables['signingCondition'] }}:
|
||||
artifactMap: ['nuget/signed']
|
||||
artifactMap: ['nuget/Release']
|
||||
packageName: 'Microsoft Maui Graphics'
|
||||
packageFilter: '*.nupkg'
|
||||
condition: not(${{ variables['signingCondition'] }}) # Executed when signing is not enabled such as for pull request builds (PRs)
|
||||
|
||||
- template: compliance/sbom/job.v1.yml@xamarin-templates
|
||||
parameters:
|
||||
jobName: SBOM_CI
|
||||
jobDisplayName: 'Software Bill of Materials (CI)'
|
||||
artifactNames: ['nuget']
|
||||
artifactMap: ['nuget/signed']
|
||||
packageName: 'Microsoft Maui Graphics'
|
||||
packageFilter: '*.nupkg'
|
||||
condition: and(succeeded(), ${{ variables['signingCondition'] }} ) # Executed when signing is enabled such as for continuous integration builds (CIs)
|
|
@ -1,38 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Forms</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Forms</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Microsoft.Maui.Graphics support for Xamarin.Forms</description>
|
||||
<summary>This allows you to use Microsoft.Maui.Graphics within Xamarin.Forms.</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="Xamarin.Forms" version="4.8.0.1821"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/netstandard2.0/Microsoft.Maui.Graphics.Forms.dll" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/netstandard2.0/Microsoft.Maui.Graphics.Forms.pdb" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/netstandard2.1/Microsoft.Maui.Graphics.Forms.dll" target="lib/netstandard2.1/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/netstandard2.1/Microsoft.Maui.Graphics.Forms.pdb" target="lib/netstandard2.1/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Forms.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Forms.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Forms.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Forms.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/monoandroid10.0/Microsoft.Maui.Graphics.Forms.dll" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/monoandroid10.0/Microsoft.Maui.Graphics.Forms.pdb" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.mac20/Microsoft.Maui.Graphics.Forms.dll" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Forms/bin/Release/xamarin.mac20/Microsoft.Maui.Graphics.Forms.pdb" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Forms.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,27 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.GDI.Winforms</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.GDI.Winforms</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>GDI support for Microsoft.Maui.Graphics on WinForms</description>
|
||||
<summary>GDI support for Microsoft.Maui.Graphics on WinForms</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.GDI.Winforms/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.GDI.Winforms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.GDI.Winforms/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.GDI.Winforms.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,31 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.SharpDX.UWP</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.SharpDX.UWP</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Microsoft.Maui.Graphics for UWP powered by SharpDX</description>
|
||||
<summary>Microsoft.Maui.Graphics for UWP powered by SharpDX</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="SharpDX.D3DCompiler" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Direct2D1" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Direct3D11" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Mathematics" version="4.2.0"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.UWP/bin/Release/Microsoft.Maui.Graphics.SharpDX.UWP.dll" target="lib/uap/Microsoft.Maui.Graphics.SharpDX.UWP.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.UWP/bin/Release/Microsoft.Maui.Graphics.SharpDX.UWP.pdb" target="lib/uap/Microsoft.Maui.Graphics.SharpDX.UWP.dll"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,33 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.SharpDX.WPF</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.SharpDX.WPF</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Microsoft.Maui.Graphics for WPF powered by SharpDX</description>
|
||||
<summary>Microsoft.Maui.Graphics for WPF powered by SharpDX</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="SharpDX.D3DCompiler" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Direct2D1" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Direct3D11" version="4.2.0"/>
|
||||
<dependency id="SharpDX.Mathematics" version="4.2.0"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.SharpDX.WPF.dll" target="lib/net5.0-windows/Microsoft.Maui.Graphics.SharpDX.WPF.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.SharpDX.WPF.pdb" target="lib/net5.0-windows/Microsoft.Maui.Graphics.SharpDX.WPF.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.WPF/bin/Release/net5.0-windows/SharpDX.Desktop.dll" target="lib/net5.0-windows/SharpDX.Desktop.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.SharpDX.WPF/bin/Release/net5.0-windows/SharpDX.Desktop.pdb" target="lib/net5.0-windows/SharpDX.Desktop.dll"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,42 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Skia.Forms</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Skia.Forms</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Support for Microsoft.Maui.Graphics using Skia on Xamarin.Forms</description>
|
||||
<summary>This allows you to use Skia as a Microsoft.Maui.Graphics target in Xamarin.Forms.</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="SkiaSharp" version="2.80.3"/>
|
||||
<dependency id="SkiaSharp.Views" version="2.80.3"/>
|
||||
<dependency id="Xamarin.Forms" version="4.8.0.1821"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/netstandard2.0/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/netstandard2.0/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/netstandard2.1/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/netstandard2.1/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/netstandard2.1/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/netstandard2.1/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/monoandroid10.0/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/monoandroid10.0/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.mac20/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/xamarin.mac20/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/tizen40/Microsoft.Maui.Graphics.Skia.Forms.dll" target="lib/tizen40/Microsoft.Maui.Graphics.Skia.Forms.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.Forms/bin/Release/tizen40/Microsoft.Maui.Graphics.Skia.Forms.pdb" target="lib/tizen40/Microsoft.Maui.Graphics.Skia.Forms.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,30 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Skia.WPF</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Skia.WPF</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Support for Microsoft.Maui.Graphics using Skia on WPF</description>
|
||||
<summary>This allows you to use Skia as a Microsoft.Maui.Graphics target in WPF.</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="SkiaSharp" version="2.80.3"/>
|
||||
<dependency id="SkiaSharp.Views" version="2.80.3"/>
|
||||
<dependency id="SkiaSharp.Views.WPF" version="2.80.3"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Skia.WPF.dll" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Skia.WPF.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Skia.WPF.pdb" target="lib/netstandard2.0/Microsoft.Maui.Graphics.Skia.WPF.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,27 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Text.WPF</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Text.WPF</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Support for Microsoft.Maui.Graphics.Text on WPF</description>
|
||||
<summary>This allows you to use Skia as a Microsoft.Maui.Graphics.TExt on WPF.</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Text.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Text.WPF.dll" target="lib/net5.0-windows/Microsoft.Maui.Graphics.Text.WPF.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Text.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Text.WPF.pdb" target="lib/net5.0-windows/Microsoft.Maui.Graphics.Text.WPF.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,28 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Win2D.UWP</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Win2D.UWP</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Microsoft.Maui.Graphics for UWP powered by Win2D</description>
|
||||
<summary>Microsoft.Maui.Graphics for UWP powered by Win2D</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="Win2D.uwp" version="1.25.0"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Win2D.UWP/bin/Release/Microsoft.Maui.Graphics.Win2D.UWP.dll" target="lib/uap/Microsoft.Maui.Graphics.Win2D.UWP.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Win2D.UWP/bin/Release/Microsoft.Maui.Graphics.Win2D.UWP.pdb" target="lib/uap/Microsoft.Maui.Graphics.Win2D.UWP.dll"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,27 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Xaml.UWP</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Xaml.UWP</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Microsoft.Maui.Graphics for UWP powered by Xaml</description>
|
||||
<summary>Microsoft.Maui.Graphics for UWP powered by Xaml</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Xaml.UWP/bin/Release/Microsoft.Maui.Graphics.Xaml.UWP.dll" target="lib/uap/Microsoft.Maui.Graphics.Xaml.UWP.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Xaml.UWP/bin/Release/Microsoft.Maui.Graphics.Xaml.UWP.pdb" target="lib/uap/Microsoft.Maui.Graphics.Xaml.UWP.dll"/>
|
||||
</files>
|
||||
</package>
|
|
@ -1,27 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>JonLipsky.Microsoft.Maui.Graphics.Xaml.WPF</id>
|
||||
<version>$version$</version>
|
||||
<title>JonLipsky.Microsoft.Maui.Graphics.Xaml.WPF</title>
|
||||
<authors>Jon Lipsky</authors>
|
||||
<owners>jonlipsky</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>Support for Microsoft.Maui.Graphics on WPF powered by Xaml</description>
|
||||
<summary>This allows you to use Microsoft.Maui.Graphics on WPF within your Xaml.</summary>
|
||||
<copyright>Jon Lipsky</copyright>
|
||||
<projectUrl>https://github.com/dotnet/Microsoft.Maui.Graphics</projectUrl>
|
||||
<repository type="git" url="https://github.com/dotnet/Microsoft.Maui.Graphics"/>
|
||||
<license type="expression">MIT</license>
|
||||
<language>C#</language>
|
||||
<dependencies>
|
||||
<group>
|
||||
<dependency id="JonLipsky.Microsoft.Maui.Graphics" version="$version$"/>
|
||||
</group>
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="src/Microsoft.Maui.Graphics.Xaml.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Xaml.WPF.dll" target="lib/net5.0-windows/Microsoft.Maui.Graphics.Xaml.WPF.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Xaml.WPF/bin/Release/net5.0-windows/Microsoft.Maui.Graphics.Xaml.WPF.pdb" target="lib/net5.0-windows/Microsoft.Maui.Graphics.Xaml.WPF.pdb"/>
|
||||
</files>
|
||||
</package>
|
|
@ -29,7 +29,7 @@
|
|||
</group>
|
||||
<group targetFramework="xamarin.ios10">
|
||||
</group>
|
||||
<group targetFramework="monoandroid10.0">
|
||||
<group targetFramework="monoandroid12.0">
|
||||
</group>
|
||||
<group targetFramework="xamarin.mac20">
|
||||
</group>
|
||||
|
@ -49,8 +49,8 @@
|
|||
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/xamarin.ios10/Microsoft.Maui.Graphics.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/xamarin.ios10/Microsoft.Maui.Graphics.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/monoandroid10.0/Microsoft.Maui.Graphics.dll" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/monoandroid10.0/Microsoft.Maui.Graphics.pdb" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/monoandroid12.0/Microsoft.Maui.Graphics.dll" target="lib/monoandroid12.0/Microsoft.Maui.Graphics.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/monoandroid12.0/Microsoft.Maui.Graphics.pdb" target="lib/monoandroid12.0/Microsoft.Maui.Graphics.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/xamarin.mac20/Microsoft.Maui.Graphics.dll" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics/bin/$configuration$/xamarin.mac20/Microsoft.Maui.Graphics.pdb" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.pdb"/>
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
<dependency id="SkiaSharp" version="2.88.0-preview.179"/>
|
||||
<dependency id="SkiaSharp.Views" version="2.88.0-preview.179"/>
|
||||
</group>
|
||||
<group targetFramework="monoandroid10.0">
|
||||
<group targetFramework="monoandroid12.0">
|
||||
<dependency id="Microsoft.Maui.Graphics" version="$version$"/>
|
||||
<dependency id="SkiaSharp" version="2.88.0-preview.179"/>
|
||||
<dependency id="SkiaSharp.Views" version="2.88.0-preview.179"/>
|
||||
|
@ -89,8 +89,8 @@
|
|||
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/xamarin.ios10/Microsoft.Maui.Graphics.Skia.dll" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/xamarin.ios10/Microsoft.Maui.Graphics.Skia.pdb" target="lib/xamarin.ios10/Microsoft.Maui.Graphics.Skia.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/monoandroid10.0/Microsoft.Maui.Graphics.Skia.dll" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Skia.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/monoandroid10.0/Microsoft.Maui.Graphics.Skia.pdb" target="lib/monoandroid10.0/Microsoft.Maui.Graphics.Skia.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/monoandroid12.0/Microsoft.Maui.Graphics.Skia.dll" target="lib/monoandroid12.0/Microsoft.Maui.Graphics.Skia.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/monoandroid12.0/Microsoft.Maui.Graphics.Skia.pdb" target="lib/monoandroid12.0/Microsoft.Maui.Graphics.Skia.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/xamarin.mac20/Microsoft.Maui.Graphics.Skia.dll" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Skia.dll"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/xamarin.mac20/Microsoft.Maui.Graphics.Skia.pdb" target="lib/xamarin.mac20/Microsoft.Maui.Graphics.Skia.pdb"/>
|
||||
<file src="src/Microsoft.Maui.Graphics.Skia/bin/$configuration$/tizen40/Microsoft.Maui.Graphics.Skia.dll" target="lib/tizen40/Microsoft.Maui.Graphics.Skia.dll"/>
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
<AndroidApplication>True</AndroidApplication>
|
||||
<AssemblyName>GraphicsTester.Android</AssemblyName>
|
||||
<AndroidManifest>Properties\AndroidManifest.xml</AndroidManifest>
|
||||
<TargetFrameworkVersion>v10.0</TargetFrameworkVersion>
|
||||
<TargetFrameworkVersion>v12.0</TargetFrameworkVersion>
|
||||
<AndroidTlsProvider>
|
||||
</AndroidTlsProvider>
|
||||
<AndroidLinkMode>None</AndroidLinkMode>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="1.0" package="Microsoft.Maui.Graphics.tester.Android">
|
||||
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="29" />
|
||||
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="31" />
|
||||
<application android:label="GraphicsTester"></application>
|
||||
</manifest>
|
||||
</manifest>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="MSBuild.Sdk.Extras">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.0;netstandard2.1;Xamarin.iOS10;MonoAndroid10.0;Xamarin.Mac20;tizen40</TargetFrameworks>
|
||||
<TargetFrameworks>netstandard2.0;netstandard2.1;Xamarin.iOS10;MonoAndroid12.0;Xamarin.Mac20;tizen40</TargetFrameworks>
|
||||
<RootNamespace>Microsoft.Maui.Graphics.Skia</RootNamespace>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
|
@ -738,208 +738,158 @@ namespace Microsoft.Maui.Graphics
|
|||
return true;
|
||||
}
|
||||
|
||||
string[] parts = value.Split('.');
|
||||
if (parts.Length == 1 || (parts.Length == 2 && parts[0] == "Color"))
|
||||
var namedColor = value?.ToLowerInvariant() switch
|
||||
{
|
||||
string namedColorStr = parts[parts.Length - 1];
|
||||
"default" => default,
|
||||
"aliceblue" => Colors.AliceBlue,
|
||||
"antiquewhite" => Colors.AntiqueWhite,
|
||||
"aqua" => Colors.Aqua,
|
||||
"aquamarine" => Colors.Aquamarine,
|
||||
"azure" => Colors.Azure,
|
||||
"beige" => Colors.Beige,
|
||||
"bisque" => Colors.Bisque,
|
||||
"black" => Colors.Black,
|
||||
"blanchedalmond" => Colors.BlanchedAlmond,
|
||||
"blue" => Colors.Blue,
|
||||
"blueViolet" => Colors.BlueViolet,
|
||||
"brown" => Colors.Brown,
|
||||
"burlywood" => Colors.BurlyWood,
|
||||
"cadetblue" => Colors.CadetBlue,
|
||||
"chartreuse" => Colors.Chartreuse,
|
||||
"chocolate" => Colors.Chocolate,
|
||||
"coral" => Colors.Coral,
|
||||
"cornflowerblue" => Colors.CornflowerBlue,
|
||||
"cornsilk" => Colors.Cornsilk,
|
||||
"crimson" => Colors.Crimson,
|
||||
"cyan" => Colors.Cyan,
|
||||
"darkblue" => Colors.DarkBlue,
|
||||
"darkcyan" => Colors.DarkCyan,
|
||||
"darkgoldenrod" => Colors.DarkGoldenrod,
|
||||
"darkgray" => Colors.DarkGray,
|
||||
"darkgreen" => Colors.DarkGreen,
|
||||
"darkkhaki" => Colors.DarkKhaki,
|
||||
"darkmagenta" => Colors.DarkMagenta,
|
||||
"darkolivegreen" => Colors.DarkOliveGreen,
|
||||
"darkorange" => Colors.DarkOrange,
|
||||
"darkorchid" => Colors.DarkOrchid,
|
||||
"darkred" => Colors.DarkRed,
|
||||
"darksalmon" => Colors.DarkSalmon,
|
||||
"darkseagreen" => Colors.DarkSeaGreen,
|
||||
"darkslateblue" => Colors.DarkSlateBlue,
|
||||
"darkslategray" => Colors.DarkSlateGray,
|
||||
"darkturquoise" => Colors.DarkTurquoise,
|
||||
"darkviolet" => Colors.DarkViolet,
|
||||
"deeppink" => Colors.DeepPink,
|
||||
"deepskyblue" => Colors.DeepSkyBlue,
|
||||
"dimgray" => Colors.DimGray,
|
||||
"dodgerblue" => Colors.DodgerBlue,
|
||||
"firebrick" => Colors.Firebrick,
|
||||
"floralwhite" => Colors.FloralWhite,
|
||||
"forestgreen" => Colors.ForestGreen,
|
||||
"fuchsia" => Colors.Fuchsia,
|
||||
"gainsboro" => Colors.Gainsboro,
|
||||
"ghostwhite" => Colors.GhostWhite,
|
||||
"gold" => Colors.Gold,
|
||||
"goldenrod" => Colors.Goldenrod,
|
||||
"gray" => Colors.Gray,
|
||||
"green" => Colors.Green,
|
||||
"greenyellow" => Colors.GreenYellow,
|
||||
"honeydew" => Colors.Honeydew,
|
||||
"hotpink" => Colors.HotPink,
|
||||
"indianred" => Colors.IndianRed,
|
||||
"indigo" => Colors.Indigo,
|
||||
"ivory" => Colors.Ivory,
|
||||
"khaki" => Colors.Khaki,
|
||||
"lavender" => Colors.Lavender,
|
||||
"lavenderblush" => Colors.LavenderBlush,
|
||||
"lawngreen" => Colors.LawnGreen,
|
||||
"lemonchiffon" => Colors.LemonChiffon,
|
||||
"lightblue" => Colors.LightBlue,
|
||||
"lightcoral" => Colors.LightCoral,
|
||||
"lightcyan" => Colors.LightCyan,
|
||||
"lightgoldenrodyellow" => Colors.LightGoldenrodYellow,
|
||||
"lightgrey" => Colors.LightGrey,
|
||||
"lightgray" => Colors.LightGray,
|
||||
"lightgreen" => Colors.LightGreen,
|
||||
"lightpink" => Colors.LightPink,
|
||||
"lightsalmon" => Colors.LightSalmon,
|
||||
"lightseagreen" => Colors.LightSeaGreen,
|
||||
"lightskyblue" => Colors.LightSkyBlue,
|
||||
"lightslategray" => Colors.LightSlateGray,
|
||||
"lightsteelblue" => Colors.LightSteelBlue,
|
||||
"lightyellow" => Colors.LightYellow,
|
||||
"lime" => Colors.Lime,
|
||||
"limegreen" => Colors.LimeGreen,
|
||||
"linen" => Colors.Linen,
|
||||
"magenta" => Colors.Magenta,
|
||||
"maroon" => Colors.Maroon,
|
||||
"mediumaquamarine" => Colors.MediumAquamarine,
|
||||
"mediumblue" => Colors.MediumBlue,
|
||||
"mediumorchid" => Colors.MediumOrchid,
|
||||
"mediumpurple" => Colors.MediumPurple,
|
||||
"mediumseagreen" => Colors.MediumSeaGreen,
|
||||
"mediumslateblue" => Colors.MediumSlateBlue,
|
||||
"mediumspringgreen" => Colors.MediumSpringGreen,
|
||||
"mediumturquoise" => Colors.MediumTurquoise,
|
||||
"mediumvioletred" => Colors.MediumVioletRed,
|
||||
"midnightblue" => Colors.MidnightBlue,
|
||||
"mintcream" => Colors.MintCream,
|
||||
"mistyrose" => Colors.MistyRose,
|
||||
"moccasin" => Colors.Moccasin,
|
||||
"navajowhite" => Colors.NavajoWhite,
|
||||
"navy" => Colors.Navy,
|
||||
"oldlace" => Colors.OldLace,
|
||||
"olive" => Colors.Olive,
|
||||
"olivedrab" => Colors.OliveDrab,
|
||||
"orange" => Colors.Orange,
|
||||
"orangered" => Colors.OrangeRed,
|
||||
"orchid" => Colors.Orchid,
|
||||
"palegoldenrod" => Colors.PaleGoldenrod,
|
||||
"palegreen" => Colors.PaleGreen,
|
||||
"paleturquoise" => Colors.PaleTurquoise,
|
||||
"palevioletred" => Colors.PaleVioletRed,
|
||||
"papayawhip" => Colors.PapayaWhip,
|
||||
"peachpuff" => Colors.PeachPuff,
|
||||
"peru" => Colors.Peru,
|
||||
"pink" => Colors.Pink,
|
||||
"plum" => Colors.Plum,
|
||||
"powderblue" => Colors.PowderBlue,
|
||||
"purple" => Colors.Purple,
|
||||
"red" => Colors.Red,
|
||||
"rosybrown" => Colors.RosyBrown,
|
||||
"royalblue" => Colors.RoyalBlue,
|
||||
"saddlebrown" => Colors.SaddleBrown,
|
||||
"salmon" => Colors.Salmon,
|
||||
"sandybrown" => Colors.SandyBrown,
|
||||
"seagreen" => Colors.SeaGreen,
|
||||
"seashell" => Colors.SeaShell,
|
||||
"sienna" => Colors.Sienna,
|
||||
"silver" => Colors.Silver,
|
||||
"skyblue" => Colors.SkyBlue,
|
||||
"slateblue" => Colors.SlateBlue,
|
||||
"slategray" => Colors.SlateGray,
|
||||
"snow" => Colors.Snow,
|
||||
"springgreen" => Colors.SpringGreen,
|
||||
"steelblue" => Colors.SteelBlue,
|
||||
"tan" => Colors.Tan,
|
||||
"teal" => Colors.Teal,
|
||||
"thistle" => Colors.Thistle,
|
||||
"tomato" => Colors.Tomato,
|
||||
"transparent" => Colors.Transparent,
|
||||
"turquoise" => Colors.Turquoise,
|
||||
"violet" => Colors.Violet,
|
||||
"wheat" => Colors.Wheat,
|
||||
"white" => Colors.White,
|
||||
"whitesmoke" => Colors.WhiteSmoke,
|
||||
"yellow" => Colors.Yellow,
|
||||
"yellowgreen" => Colors.YellowGreen,
|
||||
_ => null
|
||||
};
|
||||
|
||||
var namedColor = namedColorStr?.ToLowerInvariant() switch
|
||||
{
|
||||
"default" => default,
|
||||
"aliceblue" => Colors.AliceBlue,
|
||||
"antiquewhite" => Colors.AntiqueWhite,
|
||||
"aqua" => Colors.Aqua,
|
||||
"aquamarine" => Colors.Aquamarine,
|
||||
"azure" => Colors.Azure,
|
||||
"beige" => Colors.Beige,
|
||||
"bisque" => Colors.Bisque,
|
||||
"black" => Colors.Black,
|
||||
"blanchedalmond" => Colors.BlanchedAlmond,
|
||||
"blue" => Colors.Blue,
|
||||
"blueViolet" => Colors.BlueViolet,
|
||||
"brown" => Colors.Brown,
|
||||
"burlywood" => Colors.BurlyWood,
|
||||
"cadetblue" => Colors.CadetBlue,
|
||||
"chartreuse" => Colors.Chartreuse,
|
||||
"chocolate" => Colors.Chocolate,
|
||||
"coral" => Colors.Coral,
|
||||
"cornflowerblue" => Colors.CornflowerBlue,
|
||||
"cornsilk" => Colors.Cornsilk,
|
||||
"crimson" => Colors.Crimson,
|
||||
"cyan" => Colors.Cyan,
|
||||
"darkblue" => Colors.DarkBlue,
|
||||
"darkcyan" => Colors.DarkCyan,
|
||||
"darkgoldenrod" => Colors.DarkGoldenrod,
|
||||
"darkgray" => Colors.DarkGray,
|
||||
"darkgreen" => Colors.DarkGreen,
|
||||
"darkkhaki" => Colors.DarkKhaki,
|
||||
"darkmagenta" => Colors.DarkMagenta,
|
||||
"darkolivegreen" => Colors.DarkOliveGreen,
|
||||
"darkorange" => Colors.DarkOrange,
|
||||
"darkorchid" => Colors.DarkOrchid,
|
||||
"darkred" => Colors.DarkRed,
|
||||
"darksalmon" => Colors.DarkSalmon,
|
||||
"darkseagreen" => Colors.DarkSeaGreen,
|
||||
"darkslateblue" => Colors.DarkSlateBlue,
|
||||
"darkslategray" => Colors.DarkSlateGray,
|
||||
"darkturquoise" => Colors.DarkTurquoise,
|
||||
"darkviolet" => Colors.DarkViolet,
|
||||
"deeppink" => Colors.DeepPink,
|
||||
"deepskyblue" => Colors.DeepSkyBlue,
|
||||
"dimgray" => Colors.DimGray,
|
||||
"dodgerblue" => Colors.DodgerBlue,
|
||||
"firebrick" => Colors.Firebrick,
|
||||
"floralwhite" => Colors.FloralWhite,
|
||||
"forestgreen" => Colors.ForestGreen,
|
||||
"fuchsia" => Colors.Fuchsia,
|
||||
"gainsboro" => Colors.Gainsboro,
|
||||
"ghostwhite" => Colors.GhostWhite,
|
||||
"gold" => Colors.Gold,
|
||||
"goldenrod" => Colors.Goldenrod,
|
||||
"gray" => Colors.Gray,
|
||||
"green" => Colors.Green,
|
||||
"greenyellow" => Colors.GreenYellow,
|
||||
"honeydew" => Colors.Honeydew,
|
||||
"hotpink" => Colors.HotPink,
|
||||
"indianred" => Colors.IndianRed,
|
||||
"indigo" => Colors.Indigo,
|
||||
"ivory" => Colors.Ivory,
|
||||
"khaki" => Colors.Khaki,
|
||||
"lavender" => Colors.Lavender,
|
||||
"lavenderblush" => Colors.LavenderBlush,
|
||||
"lawngreen" => Colors.LawnGreen,
|
||||
"lemonchiffon" => Colors.LemonChiffon,
|
||||
"lightblue" => Colors.LightBlue,
|
||||
"lightcoral" => Colors.LightCoral,
|
||||
"lightcyan" => Colors.LightCyan,
|
||||
"lightgoldenrodyellow" => Colors.LightGoldenrodYellow,
|
||||
"lightgrey" => Colors.LightGrey,
|
||||
"lightgray" => Colors.LightGray,
|
||||
"lightgreen" => Colors.LightGreen,
|
||||
"lightpink" => Colors.LightPink,
|
||||
"lightsalmon" => Colors.LightSalmon,
|
||||
"lightseagreen" => Colors.LightSeaGreen,
|
||||
"lightskyblue" => Colors.LightSkyBlue,
|
||||
"lightslategray" => Colors.LightSlateGray,
|
||||
"lightsteelblue" => Colors.LightSteelBlue,
|
||||
"lightyellow" => Colors.LightYellow,
|
||||
"lime" => Colors.Lime,
|
||||
"limegreen" => Colors.LimeGreen,
|
||||
"linen" => Colors.Linen,
|
||||
"magenta" => Colors.Magenta,
|
||||
"maroon" => Colors.Maroon,
|
||||
"mediumaquamarine" => Colors.MediumAquamarine,
|
||||
"mediumblue" => Colors.MediumBlue,
|
||||
"mediumorchid" => Colors.MediumOrchid,
|
||||
"mediumpurple" => Colors.MediumPurple,
|
||||
"mediumseagreen" => Colors.MediumSeaGreen,
|
||||
"mediumslateblue" => Colors.MediumSlateBlue,
|
||||
"mediumspringgreen" => Colors.MediumSpringGreen,
|
||||
"mediumturquoise" => Colors.MediumTurquoise,
|
||||
"mediumvioletred" => Colors.MediumVioletRed,
|
||||
"midnightblue" => Colors.MidnightBlue,
|
||||
"mintcream" => Colors.MintCream,
|
||||
"mistyrose" => Colors.MistyRose,
|
||||
"moccasin" => Colors.Moccasin,
|
||||
"navajowhite" => Colors.NavajoWhite,
|
||||
"navy" => Colors.Navy,
|
||||
"oldlace" => Colors.OldLace,
|
||||
"olive" => Colors.Olive,
|
||||
"olivedrab" => Colors.OliveDrab,
|
||||
"orange" => Colors.Orange,
|
||||
"orangered" => Colors.OrangeRed,
|
||||
"orchid" => Colors.Orchid,
|
||||
"palegoldenrod" => Colors.PaleGoldenrod,
|
||||
"palegreen" => Colors.PaleGreen,
|
||||
"paleturquoise" => Colors.PaleTurquoise,
|
||||
"palevioletred" => Colors.PaleVioletRed,
|
||||
"papayawhip" => Colors.PapayaWhip,
|
||||
"peachpuff" => Colors.PeachPuff,
|
||||
"peru" => Colors.Peru,
|
||||
"pink" => Colors.Pink,
|
||||
"plum" => Colors.Plum,
|
||||
"powderblue" => Colors.PowderBlue,
|
||||
"purple" => Colors.Purple,
|
||||
"red" => Colors.Red,
|
||||
"rosybrown" => Colors.RosyBrown,
|
||||
"royalblue" => Colors.RoyalBlue,
|
||||
"saddlebrown" => Colors.SaddleBrown,
|
||||
"salmon" => Colors.Salmon,
|
||||
"sandybrown" => Colors.SandyBrown,
|
||||
"seagreen" => Colors.SeaGreen,
|
||||
"seashell" => Colors.SeaShell,
|
||||
"sienna" => Colors.Sienna,
|
||||
"silver" => Colors.Silver,
|
||||
"skyblue" => Colors.SkyBlue,
|
||||
"slateblue" => Colors.SlateBlue,
|
||||
"slategray" => Colors.SlateGray,
|
||||
"snow" => Colors.Snow,
|
||||
"springgreen" => Colors.SpringGreen,
|
||||
"steelblue" => Colors.SteelBlue,
|
||||
"tan" => Colors.Tan,
|
||||
"teal" => Colors.Teal,
|
||||
"thistle" => Colors.Thistle,
|
||||
"tomato" => Colors.Tomato,
|
||||
"transparent" => Colors.Transparent,
|
||||
"turquoise" => Colors.Turquoise,
|
||||
"violet" => Colors.Violet,
|
||||
"wheat" => Colors.Wheat,
|
||||
"white" => Colors.White,
|
||||
"whitesmoke" => Colors.WhiteSmoke,
|
||||
"yellow" => Colors.Yellow,
|
||||
"yellowgreen" => Colors.YellowGreen,
|
||||
_ => null
|
||||
};
|
||||
|
||||
if (namedColor != null)
|
||||
{
|
||||
color = namedColor;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Look for fields of Color or Colors matching the name
|
||||
var field = typeof(Color).GetFields().FirstOrDefault(fi => fi.IsStatic && string.Equals(fi.Name, namedColorStr, StringComparison.OrdinalIgnoreCase));
|
||||
if (field != null)
|
||||
{
|
||||
var fieldColor = field.GetValue(null) as Color;
|
||||
if (fieldColor != null)
|
||||
{
|
||||
color = fieldColor;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
field = typeof(Colors).GetFields().FirstOrDefault(fi => fi.IsStatic && string.Equals(fi.Name, namedColorStr, StringComparison.OrdinalIgnoreCase));
|
||||
if (field != null)
|
||||
{
|
||||
var fieldColor = field.GetValue(null) as Color;
|
||||
if (fieldColor != null)
|
||||
{
|
||||
color = fieldColor;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
// Look for property of Color or Colors matching the name
|
||||
var property = typeof(Color).GetProperties().FirstOrDefault(pi => string.Equals(pi.Name, namedColorStr, StringComparison.OrdinalIgnoreCase) && pi.CanRead && pi.GetMethod.IsStatic);
|
||||
if (property != null)
|
||||
{
|
||||
var propColor = property.GetValue(null, null) as Color;
|
||||
if (propColor != null)
|
||||
{
|
||||
color = propColor;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
property = typeof(Colors).GetProperties().FirstOrDefault(pi => string.Equals(pi.Name, namedColorStr, StringComparison.OrdinalIgnoreCase) && pi.CanRead && pi.GetMethod.IsStatic);
|
||||
if (property != null)
|
||||
{
|
||||
var propColor = property.GetValue(null, null) as Color;
|
||||
if (propColor != null)
|
||||
{
|
||||
color = propColor;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if (namedColor != null)
|
||||
{
|
||||
color = namedColor;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,36 +1,36 @@
|
|||
<Project Sdk="MSBuild.Sdk.Extras/3.0.23">
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.1;netstandard2.0;Xamarin.iOS10;MonoAndroid10.0;Xamarin.Mac20;tizen40</TargetFrameworks>
|
||||
<!-- Optional: Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
|
||||
<PublishRepositoryUrl>true</PublishRepositoryUrl>
|
||||
<!-- Optional: Build symbol package (.snupkg) to distribute the PDB containing Source Link -->
|
||||
<IncludeSymbols>true</IncludeSymbols>
|
||||
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
||||
<RootNamespace>Microsoft.Maui.Graphics</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PackageId>Microsoft.Maui.Graphics</PackageId>
|
||||
<Product>Microsoft.Maui.Graphics</Product>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0">
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="NETStandard.Library" Version="2.0.3" />
|
||||
<PackageReference Include="System.Numerics.Vectors" Version="4.5.0" Condition="$(TargetFramework.StartsWith('netstandard'))" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="Mac\GraphicsMac.resx">
|
||||
<CustomToolNamespace>Microsoft.Maui.Graphics.Platform</CustomToolNamespace>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<Import Project="..\targets\MultiTargeting.targets" />
|
||||
<ItemGroup>
|
||||
<None Update="Mac\GraphicsMac.Designer.cs">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>GraphicsMac.resx</DependentUpon>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.1;netstandard2.0;Xamarin.iOS10;MonoAndroid12.0;Xamarin.Mac20;tizen40</TargetFrameworks>
|
||||
<!-- Optional: Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
|
||||
<PublishRepositoryUrl>true</PublishRepositoryUrl>
|
||||
<!-- Optional: Build symbol package (.snupkg) to distribute the PDB containing Source Link -->
|
||||
<IncludeSymbols>true</IncludeSymbols>
|
||||
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
||||
<RootNamespace>Microsoft.Maui.Graphics</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PackageId>Microsoft.Maui.Graphics</PackageId>
|
||||
<Product>Microsoft.Maui.Graphics</Product>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0">
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="NETStandard.Library" Version="2.0.3" />
|
||||
<PackageReference Include="System.Numerics.Vectors" Version="4.5.0" Condition="$(TargetFramework.StartsWith('netstandard'))" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="Mac\GraphicsMac.resx">
|
||||
<CustomToolNamespace>Microsoft.Maui.Graphics.Platform</CustomToolNamespace>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<Import Project="..\targets\MultiTargeting.targets" />
|
||||
<ItemGroup>
|
||||
<None Update="Mac\GraphicsMac.Designer.cs">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>GraphicsMac.resx</DependentUpon>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
Загрузка…
Ссылка в новой задаче