sysdrawing-coregraphics (System.Drawing) support for Unified Xamarin.Mac/Xamarin.iOS

ChrisHamonsChrisHamons Chris HamonsUSXamarin Team Xamurai

I'd like to announce the release of sysdrawing-coregraphics with support for Unified.

sysdrawing-coregraphics is an implementation of much of the System.Drawing API using CoreGraphics for the implementation. This means it has support for both Xamarin.Mac and Xamarin.iOS.

This project has been around for awhile with Classic support, but now has been updated to work with Unified Xamarin.Mac/Xamarin.iOS.

Download the build here: http://download.xamarin.com/system-drawing/sysdrawing-coregraphics-Cycle6.zip
View the project here: https://github.com/mono/sysdrawing-coregraphics
Samples are here: https://github.com/mono/sysdrawing-coregraphics/tree/master/Samples

Please note, this is a community project, and not an officially supported part of the Xamarin platform.

Posts

  • JohnConnersJohnConners John Conners GBMember ✭✭
    edited February 2016

    Thought I'd give this a spin as I'd ultimately like to migrate a classic app away from the old System.Drawing namespace to the new unified world. Only snag is I can't seem to get it to compile in a simple project. I created a default unified C# app targeting .NET 4.5, added a reference to the assembly above and tried to compile this code:

    using( var image = new Bitmap( 600, 400 ) ) { }

    However I get the following error:

    Error CS0012: The type 'System.Drawing.Size' is defined in an assembly that is not referenced. Consider adding a reference to assembly 'OpenTK, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' (CS0012)

    Now System.Drawing.Size is defined in Xamarin.Mac which I'm referencing so I'm wondering if the Cycle6 assembly above is referencing a different version or something? I'm running Xamarin.Mac 2.4.1.6 (Indie). Any thoughts? Sample project attached.

  • JohnConnersJohnConners John Conners GBMember ✭✭

    Well sysdrawing-coregraphics does indeed depend on OpenTK but if I add a reference to the one included in the Xamarin.Mac framework folder it has System.Drawing.Color defined which is also defined in the sysdrawing-coregraphics version of System.Drawing.dll. This means anything referencing Color will not compile meaning I'm dead in the water currently unfortunately.

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    Hey John, apologies on the delay in response, I was out sick.

    Did you accidentally add the mobile version of OpenTK or System.Drawing. You need:

    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/OpenTK.dll

    and

    mac/xm45/System.Drawing.dll (from the zip)

    if you are targeting the XM 4.5 target framework.

    If that does not help, please post the build log on a pastebin service (like gist) and post a link here for me to look at.

  • JohnConnersJohnConners John Conners GBMember ✭✭

    No worries! So /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/OpenTK.dll is actually an alias to /Library/Frameworks/Xamarin.Mac.framework/Versions/2.4.1.6/lib/reference/net_4_5/OpenTK.dll and that does contain a definition for some System.Drawing types (the other version in /.../Versions/2.4.1.6/lib/reference/net_4_5/full/ does not).

    Likewise the System.Drawing.dll in sysdrawing-coregraphics-Cycle6/mac/xml45/System.Drawing.dll also contains System.Drawing.Color - screenshot below:

    I've copied them multiple times to ensure I'm not bringing a mobile version over. The build log is here:

    http://pastebin.com/Rxdng0rH

    Hopefully you can see what rookie mistake I'm making!

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    Hmm. I have:

    Xamarin.Mac
    Version: 2.4.1.6 (Business Edition)

    and I made a new XM Unified project, added SD and OpenTK and it built fine for me.

    Could you clean, zip, and attach your test project somewhere for me to look at?

  • JohnConnersJohnConners John Conners GBMember ✭✭

    Attached below is a newly created and cleaned test app. It targets .NET 4.5. It would build fine so long as I didn't reference System.Drawing.Color which I'm doing here.

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    I can reproduce that. I'm not sure how that slipped by. Let me get back to you...

  • JohnConnersJohnConners John Conners GBMember ✭✭

    Phew, at least I wasn't making a rookie mistake! :smile: Cool!

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai
    edited February 2016

    @JohnConners - Could you please try this version?

    It turns out to be busted for both XM 4.5 and Mobile.

    https://www.dropbox.com/s/2ejrtqcxy9vcz1r/sysdrawing-coregraphics-Cycle6-fixed.zip?dl=0

    It has not gone through official QA, but it should have it fixed [1]. It works for me locally and my test case.

    [1] - https://github.com/mono/sysdrawing-coregraphics/commit/fc3a0ac290ef42fd26b5fa4c0a0b98c8f24c4ef8

  • JohnConnersJohnConners John Conners GBMember ✭✭

    That's got me up and running - thanks! :) If I find any bugs and what not is the GitHub page the best place to report them?

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai
    edited February 2016

    In this one specific case (this does not apply to anything else XM related for anyone else reading), Yes.

    Since this is a community project (that I just happened to spend some time on, issues on the github page is preferred over bugzilla.

  • SeanbaSeanba Sean Barton USMember

    Chris, this is great. However, I'm getting compile errors on System.Drawing.Color references in my Xamarin.Mac application. I see that the color classes are only included in the IOS builds so are we supposed to be getting Color et al. from some other reference in XM?

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    Unfortunately, due to legacy reasons we can't change now, since it came first, System.Drawing.Color is provided by OpenTK:

    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/Xamarin.Mac/OpenTK.dll (Mobile)
    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/OpenTK.dll (XM 4.5)

  • SeanbaSeanba Sean Barton USMember

    Thanks, Chris. I got it working. BTW, I'm very grateful for this library.

  • teejay87teejay87 Tommaso Sala ITMember
    edited November 2016

    Hi,
    I'm trying to use sysdrawing-coregraphics (System.Drawing) in VisualStudio for Mac, but I encountered some errors.

    Even after adding reference to OpenTK, I still get the error:

    The type 'System.Drawing.Size' is defined in an assembly that is not referenced. Consider adding a reference to assembly 'OpenTK, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'

    In fact, after opening the OpenTK in the VS Object Browser, I can't find Size in System.Drawing namespace.

    Note that I tried both OpenTK available in VS and building it from sources (which indeed seems very different), but none worked.

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai
    edited November 2016

    @teejay87 You very likely have a mismatch between Xamarin.Mac, OpenTK, and System.Drawing assemblies.

    Since you can't find System.Drawing, I assume you are using XM 4.5 Target Framework

    $ monop -r:/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/Xamarin.Mac/Xamarin.Mac.dll | grep System.Drawing
    System.Drawing.Point

    $ monop -r:/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/Xamarin.Mac.dll | grep System.Drawing

    $ monop -r:/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/OpenTK.dll | grep System.Drawing.SizeF
    System.Drawing.SizeF

    Did you reference the correct OpenTK? (The one from mono/4.5 and not mono/Xamarin.Mac)?

    If unclear, please post your csproj.

  • teejay87teejay87 Tommaso Sala ITMember
    edited November 2016

    @ChrisHamons
    I'm really new to Xamarin / VS Mac, so I could very likely have done some basic mistake.

    The Xamarin.Mac assembly is the one VS Mac automatically adds when creating a new project:
    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/Xamarin.Mac/Xamarin.Mac.dll

    The OpenTK assembly was the one that appears in the "Package" tab of the "Modify reference" dialog
    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/Xamarin.Mac/OpenTK.dll

    Now I tried to reference the one in:
    /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono/4.5/OpenTK.dll

    and it works...!

    But... Am I missing something? Am I mixing non-mixable libraries?

    Thanks for your time

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    Sorry for the delay in response, I was out on sick time yesterday.

    So if you are using the "mobile" XM - mono/Xamarin.Mac/Xamarin.Mac.dll you should use the mobile OpenTK - mono/Xamarin.Mac/OpenTK.dll

    The fact that it doesn't makes me think you are using the wrong System.Drawing one. Are you using the bin/mobile version?

    Could you attach an example somewhere for me to look at if not?

  • MustafaShdaifatMustafaShdaifat Mustafa Shdaifat USMember

    Hi, I'm alittle bit beginner with compiling libraries, I'm using Xamarin on mac I tried to compile the library I got the following.
    make: *** No rule to make target ../mono/mcs/class/System.Drawing/System.Drawing.Drawing2D/Blend.cs', needed by bin/ios/System.Drawing.dll'. Stop.

    any ideas?

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    As the readme states:

    The Makefile assumes you have a copy of mono checked out side by side. You can update the MONO_SYSD variable to point to a checkout in another location if necessary.

    It looks like you don't have mono next to the checkout.

    git clone git@github.com:mono/mono.git

    on the directory that contains your sysdrawing checkout (so the two folders are side by side) should set you up.

  • MustafaShdaifatMustafaShdaifat Mustafa Shdaifat USMember

    Thanks I built it, and I added it to the references,
    Now I'm getting the following error.
    (Path).../AvicennaPage.xaml.cs(4,4): Error CS7069: Reference to type System.ICloneable' claims it is defined assembly mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089', but it could not be found (CS7069) (Avicenna)

  • AnithaPonrajAnithaPonraj Anitha Ponraj USMember

    I am getting this error while running sample xamarin.UITest application in visual studio 2015.But i have downloaded and installed the System.Drawing.dll.
    What can i do next?

    Anyone Knows please do help.Thanks in advance.

    Severity Code Description Project File Line Suppression State
    Error Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Perhaps it doesn't exist in the Mono for Android profile?
    File name: 'System.Configuration.dll'
    at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)
    at Xamarin.Android.Tasks.ResolveAssemblies.AddAssemblyReferences(DirectoryAssemblyResolver resolver, ICollection`1 assemblies, AssemblyDefinition assembly, Boolean topLevel)
    at Xamarin.Android.Tasks.ResolveAssemblies.Execute(DirectoryAssemblyResolver resolver) CreditCardValidator.Droid

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    The error roughly says "I can't find System.Configuration". The "Mono for Android" part makes me think you are using Android? sysdrawing-coregraphics uses CoreGraphics, which is only available for macOS and iOS.

    In any case, please start a new topic in the right forum. This is unrelated enough.

  • FrederikTheisenFrederikTheisen Frederik Theisen DKMember ✭✭

    I'm trying to convert my project from Xamarin.Mac mobile to Xamarin.Mac 4.5.
    Now I get errors with drawing. When building it says that System.Drawing.Color is referenced multiple times and if I look at the System.Drawing and the OpenTK assemblies, they both contain a Color class. Did anyone else run into this?

    I may be using the wrong System.Drawing assembly.

    Minimal csproj: (from new test project)

    <?xml version="1.0" encoding="utf-8"?>
    <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
      <PropertyGroup>
        <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
        <Platform Condition=" '$(Platform)' == '' ">x86</Platform>
        <ProjectGuid>{365A0970-BA60-446D-8C7E-D618EE51D3EB}</ProjectGuid>
        <ProjectTypeGuids>{A3F8F2AB-B479-4A4A-A458-A89E7DC349F1};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
        <OutputType>Exe</OutputType>
        <RootNamespace>DrawingTestApp3</RootNamespace>
        <AssemblyName>DrawingTestApp3</AssemblyName>
        <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
        <MonoMacResourcePrefix>Resources</MonoMacResourcePrefix>
        <UseXamMacFullFramework>true</UseXamMacFullFramework>
      </PropertyGroup>
      <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
        <DebugSymbols>true</DebugSymbols>
        <DebugType>full</DebugType>
        <Optimize>false</Optimize>
        <OutputPath>bin\Debug</OutputPath>
        <DefineConstants>DEBUG;</DefineConstants>
        <ErrorReport>prompt</ErrorReport>
        <WarningLevel>4</WarningLevel>
        <EnableCodeSigning>false</EnableCodeSigning>
        <CodeSigningKey>Mac Developer</CodeSigningKey>
        <CreatePackage>false</CreatePackage>
        <EnablePackageSigning>false</EnablePackageSigning>
        <IncludeMonoRuntime>false</IncludeMonoRuntime>
        <UseSGen>true</UseSGen>
        <UseRefCounting>true</UseRefCounting>
        <PlatformTarget>x86</PlatformTarget>
      </PropertyGroup>
      <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
        <DebugType>pdbonly</DebugType>
        <Optimize>true</Optimize>
        <OutputPath>bin\Release</OutputPath>
        <ErrorReport>prompt</ErrorReport>
        <WarningLevel>4</WarningLevel>
        <EnableCodeSigning>false</EnableCodeSigning>
        <CreatePackage>true</CreatePackage>
        <EnablePackageSigning>false</EnablePackageSigning>
        <IncludeMonoRuntime>true</IncludeMonoRuntime>
        <UseSGen>true</UseSGen>
        <UseRefCounting>true</UseRefCounting>
        <LinkMode>None</LinkMode>
        <PlatformTarget>x86</PlatformTarget>
      </PropertyGroup>
      <ItemGroup>
        <Reference Include="System" />
        <Reference Include="System.Core" />
        <Reference Include="Xamarin.Mac" />
        <Reference Include="OpenTK">
          <HintPath>..\..\..\..\..\Library\Frameworks\Xamarin.Mac.framework\Versions\3.0.0.398\lib\reference\net_4_5\OpenTK.dll</HintPath>
        </Reference>
        <Reference Include="System.Drawing">
          <HintPath>..\..\..\Downloads\sysdrawing-coregraphics-Cycle6-2\mac\xm45\System.Drawing.dll</HintPath>
        </Reference>
      </ItemGroup>
      <ItemGroup>
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\Contents.json" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-128.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-128%402x.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-16.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-16%402x.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-256.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-256%402x.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-32.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-32%402x.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-512.png" />
        <ImageAsset Include="Assets.xcassets\AppIcon.appiconset\AppIcon-512%402x.png" />
        <ImageAsset Include="Assets.xcassets\Contents.json" />
      </ItemGroup>
      <ItemGroup>
        <Folder Include="Resources\" />
      </ItemGroup>
      <ItemGroup>
        <None Include="Info.plist" />
        <None Include="Entitlements.plist" />
      </ItemGroup>
      <ItemGroup>
        <Compile Include="Main.cs" />
        <Compile Include="AppDelegate.cs" />
        <Compile Include="ViewController.cs" />
        <Compile Include="ViewController.designer.cs">
          <DependentUpon>ViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="DrawingView.cs" />
        <Compile Include="DrawingView.designer.cs">
          <DependentUpon>DrawingView.cs</DependentUpon>
        </Compile>
      </ItemGroup>
      <ItemGroup>
        <InterfaceDefinition Include="Main.storyboard" />
        <InterfaceDefinition Include="DrawingView.xib" />
      </ItemGroup>
      <Import Project="$(MSBuildExtensionsPath)\Xamarin\Mac\Xamarin.Mac.CSharp.targets" />
    </Project>
    

    csproj from my actual project (same error with multiple Color types):

    <?xml version="1.0" encoding="utf-8"?>
    <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
      <PropertyGroup>
        <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
        <Platform Condition=" '$(Platform)' == '' ">x86</Platform>
        <ProjectGuid>{DE253DD2-CB6A-4C18-A905-CE9B607F969A}</ProjectGuid>
        <ProjectTypeGuids>{A3F8F2AB-B479-4A4A-A458-A89E7DC349F1};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
        <OutputType>Exe</OutputType>
        <RootNamespace>GeneViewerMac</RootNamespace>
        <AssemblyName>GeneViewer</AssemblyName>
        <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
        <MonoMacResourcePrefix>Resources</MonoMacResourcePrefix>
        <UseXamMacFullFramework>true</UseXamMacFullFramework>
      </PropertyGroup>
      <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
        <DebugSymbols>true</DebugSymbols>
        <DebugType>full</DebugType>
        <Optimize>false</Optimize>
        <OutputPath>bin\Debug</OutputPath>
        <DefineConstants>DEBUG;</DefineConstants>
        <ErrorReport>prompt</ErrorReport>
        <WarningLevel>4</WarningLevel>
        <EnableCodeSigning>false</EnableCodeSigning>
        <CodeSigningKey>Mac Developer</CodeSigningKey>
        <CreatePackage>false</CreatePackage>
        <EnablePackageSigning>false</EnablePackageSigning>
        <IncludeMonoRuntime>false</IncludeMonoRuntime>
        <UseSGen>true</UseSGen>
        <UseRefCounting>true</UseRefCounting>
        <Profiling>true</Profiling>
        <PlatformTarget>x86</PlatformTarget>
      </PropertyGroup>
      <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
        <DebugType>pdbonly</DebugType>
        <Optimize>true</Optimize>
        <OutputPath>bin\Release</OutputPath>
        <ErrorReport>prompt</ErrorReport>
        <WarningLevel>4</WarningLevel>
        <EnableCodeSigning>false</EnableCodeSigning>
        <CreatePackage>true</CreatePackage>
        <EnablePackageSigning>false</EnablePackageSigning>
        <IncludeMonoRuntime>true</IncludeMonoRuntime>
        <UseSGen>true</UseSGen>
        <UseRefCounting>true</UseRefCounting>
        <LinkMode>None</LinkMode>
        <PlatformTarget>x86</PlatformTarget>
      </PropertyGroup>
      <ItemGroup>
        <Reference Include="System.Net.Http" />
        <Reference Include="System.Net" />
        <Reference Include="System.Json" />
        <Reference Include="System.Xml.Linq" />
        <Reference Include="System.Xml.Serialization" />
        <Reference Include="System.Xml" />
        <Reference Include="System.Windows" />
        <Reference Include="System.Web.Services" />
        <Reference Include="System.IO.Compression.FileSystem" />
        <Reference Include="System.Runtime.Serialization" />
        <Reference Include="System.IO.Compression" />
        <Reference Include="System.ServiceModel.Web" />
        <Reference Include="System.Net.Http.WinHttpHandler" />
        <Reference Include="System.Data.Services.Client" />
        <Reference Include="System.Runtime.InteropServices.RuntimeInformation" />
        <Reference Include="System.Security" />
        <Reference Include="Mono.Security" />
        <Reference Include="System" />
        <Reference Include="System.Core" />
        <Reference Include="Xamarin.Mac" />
        <Reference Include="Microsoft.CSharp" />
        <Reference Include="Mono.CSharp" />
        <Reference Include="Newtonsoft.Json">
          <HintPath>..\packages\Newtonsoft.Json.10.0.1\lib\netstandard1.3\Newtonsoft.Json.dll</HintPath>
        </Reference>
        <Reference Include="System.Drawing">
          <HintPath>..\..\..\Downloads\sysdrawing-coregraphics-Cycle6-2\mac\xm45\System.Drawing.dll</HintPath>
        </Reference>
        <Reference Include="OpenTK">
          <HintPath>..\..\..\..\..\Library\Frameworks\Xamarin.Mac.framework\Versions\3.0.0.398\lib\reference\net_4_5\OpenTK.dll</HintPath>
        </Reference>
      </ItemGroup>
      <ItemGroup>
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Contents.json" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_128x128.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_128x128%402x.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_16x16.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_16x16%402x.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_256x256.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_256x256%402x.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_32x32.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_32x32%402x.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_512x512.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\Icon.iconset\icon_512x512%402x.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\Contents.json" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\16.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\32.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\64.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\128.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\256.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\512.png" />
        <ImageAsset Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\1024.png" />
      </ItemGroup>
      <ItemGroup>
        <Folder Include="Resources\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon3.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon2.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon1.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\Image01.imageset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon4.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon5.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon6.appiconset\" />
        <Folder Include="Resources\GeneViewerMac\Images.xcassets\AppIcon7.appiconset\" />
        <Folder Include="CrossPlatformFiles\" />
        <Folder Include="Data\" />
      </ItemGroup>
      <ItemGroup>
        <None Include="Info.plist" />
        <None Include="Entitlements.plist" />
        <None Include="packages.config" />
        <None Include="CrossPlatformFiles\App_localservice.cs" />
        <None Include="CrossPlatformFiles\App_webservice.cs" />
        <None Include="OpenTK.dll.config" />
      </ItemGroup>
      <ItemGroup>
        <Compile Include="Main.cs" />
        <Compile Include="App.cs" />
        <Compile Include="MainViewController.cs" />
        <Compile Include="MainViewController.designer.cs">
          <DependentUpon>MainViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="NewDNAViewController.cs" />
        <Compile Include="NewDNAViewController.designer.cs">
          <DependentUpon>NewDNAViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="CrossPlatformFiles\GeneViewerClasses.cs" />
        <Compile Include="MainWindowController.designer.cs">
          <DependentUpon>MainWindowController.cs</DependentUpon>
        </Compile>
        <Compile Include="MainSplitViewController.cs" />
        <Compile Include="MainSplitViewController.designer.cs">
          <DependentUpon>MainSplitViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="ControlAssets\NSTextViewAsset.cs" />
        <Compile Include="ControlAssets\NSTextViewAsset.designer.cs">
          <DependentUpon>NSTextViewAsset.cs</DependentUpon>
        </Compile>
        <Compile Include="App.designer.cs">
          <DependentUpon>App.cs</DependentUpon>
        </Compile>
        <Compile Include="ControlAssets\MainWindowBrowser.cs" />
        <Compile Include="ControlAssets\MainWindowBrowser.designer.cs">
          <DependentUpon>MainWindowBrowser.cs</DependentUpon>
        </Compile>
        <Compile Include="NewDNAWindowController.designer.cs">
          <DependentUpon>NewDNAWindowController.cs</DependentUpon>
        </Compile>
        <Compile Include="NewDNAWindowController.cs" />
        <Compile Include="AnalyzerSettingsViewController.designer.cs">
          <DependentUpon>AnalyzerSettingsViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="AnalyzerSettingsViewController.cs" />
        <Compile Include="AnalyzerSettingsWindowController.cs" />
        <Compile Include="AnalyzerSettingsWindowController.designer.cs">
          <DependentUpon>AnalyzerSettingsWindowController.cs</DependentUpon>
        </Compile>
        <Compile Include="AnalyzerViewController.cs" />
        <Compile Include="AnalyzerViewController.designer.cs">
          <DependentUpon>AnalyzerViewController.cs</DependentUpon>
        </Compile>
        <Compile Include="MainWindowController.cs" />
        <Compile Include="CrossPlatformFiles\dna_analyzerclass.cs" />
        <Compile Include="Resources\GeneViewerMac\DrawingView.cs" />
        <Compile Include="Resources\GeneViewerMac\DrawingView.designer.cs">
          <DependentUpon>DrawingView.cs</DependentUpon>
        </Compile>
        <Compile Include="PlasmidMapCircular.cs" />
        <Compile Include="PlasmidMapCircular.designer.cs">
          <DependentUpon>PlasmidMapCircular.cs</DependentUpon>
        </Compile>
      </ItemGroup>
      <ItemGroup>
        <InterfaceDefinition Include="Main.storyboard" />
      </ItemGroup>
      <ItemGroup>
        <BundleResource Include="Data\data_ntDict.txt" />
        <BundleResource Include="Data\data_RestrictionSites.xml" />
        <BundleResource Include="Data\data_ntCompDict.txt" />
        <BundleResource Include="Data\data_DNAFeatures.xml" />
        <BundleResource Include="Data\data_colorDict.txt" />
        <BundleResource Include="Data\data_codonDict.txt" />
        <BundleResource Include="Data\data_aminoAcidPropertiesXML.txt" />
      </ItemGroup>
      <Import Project="$(MSBuildExtensionsPath)\Xamarin\Mac\Xamarin.Mac.CSharp.targets" />
    </Project>
    
  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    As I mentioned before @FrederikTheisen, this is unrelated to the original thread.

    Please create a new thread.

    Also note you are mixing:

    <HintPath>..\..\..\Downloads\sysdrawing-coregraphics-Cycle6-2\mac\xm45\System.Drawing.dll</HintPath>

    with

    <HintPath>..\..\..\..\..\Library\Frameworks\Xamarin.Mac.framework\Versions\3.0.0.398\lib\reference\net_4_5\OpenTK.dll</HintPath>

    3.0 is Cycle 9.

    I'm not completely shocked that isn't working out of the box. You'll likely need to build a sysdrawing-coregraphics against C9.

    But in any case, another thread, so we can stop spamming people on this thread.

  • pierreDurantpierreDurant pierre Durant USMember ✭✭

    HI all,

    I'm a newbie on Xamarin. :-)
    So I downloaded the build .ZIP but.... where do I have to install those files ?

    Thanks and congrats for your work !

    Pierre

  • ChrisHamonsChrisHamons Chris Hamons USXamarin Team Xamurai

    So you can either build the assemblies yourself (see directions on github) or download the ones I made against C9 here:

    https://forums.xamarin.com/discussion/comment/263406/#Comment_263406

    This isn't an SDK you install, just raw files you reference in your project. It is not uncommon to add a folder named external in your project, and check in copies into your project.

Sign In or Register to comment.