System.Drawing.Common 10.0.0-preview.3.25173.2

System.Drawing.Common

The System.Drawing.Common package allows .NET Core and .NET 6+ applications to access GDI+ graphics functionality. This package is especially useful for porting .NET Framework applications that rely on the System.Drawing namespace.

Getting Started

To get started with System.Drawing.Common, install it using the NuGet Package Manager, the .NET CLI, or by editing your project file directly.

NOTE: If you are developing a WinForms application, you do not need to install the System.Drawing.Common package separately (to this end, you use the Sdk attribute for the Project element like <Project Sdk="Microsoft.NET.Sdk"> in the .csproj or the .vbproj file and then specify <UseWindowsForms>true</UseWindowsForms>). This package is then automatically included as part of the .NET SDK for WinForms Apps, which means you can start using the System.Drawing namespace right away in your WinForms projects.

Usage

The following examples demonstrate some basic tasks you can accomplish with System.Drawing.Common.

Create a Simple Bitmap and Save it

C#

using System.Drawing;

class Program
{
    static void Main()
    {
        using (Bitmap bitmap = new Bitmap(100, 100))
        {
            using (Graphics g = Graphics.FromImage(bitmap))
            {
                g.Clear(Color.Red);
            }
            bitmap.Save("output.bmp");
        }
    }
}

VB

Imports System.Drawing

Module Program
    Sub Main()
        Using bitmap As New Bitmap(100, 100)
            Using g As Graphics = Graphics.FromImage(bitmap)
                g.Clear(Color.Red)
            End Using
            bitmap.Save("output.bmp")
        End Using
    End Sub
End Module

Additional Documentation

For more in-depth tutorials and API references, you can check the following resources:

Feedback

Showing the top 20 packages that depend on System.Drawing.Common.

Packages Downloads
System.Windows.Extensions
Provides miscellaneous Windows-specific types Commonly Used Types: System.Security.Cryptography.X509Certificates.X509Certificate2UI System.Security.Cryptography.X509Certificates.X509SelectionFlag When using NuGet 3.x this package requires at least version 3.4.
4,226
ElectronNET.API
Building cross platform electron based desktop apps with .NET Core and ASP.NET Core. This package contains the API to access the "native" electron API.
211
ElectronNET.API
Building cross platform electron based desktop apps with .NET Core and ASP.NET Core. This package contains the API to access the "native" electron API.
70
IKVM
Java SE 8 Virtual Machine for .NET
68
IKVM
Java SE 8 Virtual Machine for .NET
66
IKVM
Java SE 8 Virtual Machine for .NET
65
IKVM
Java SE 8 Virtual Machine for .NET
64
IKVM
Java SE 8 Virtual Machine for .NET
63
IKVM
Java SE 8 Virtual Machine for .NET
60
IKVM
Java SE 8 Virtual Machine for .NET
59
Microsoft.Windows.Compatibility
This Windows Compatibility Pack provides access to APIs that were previously available only for .NET Framework. It can be used from both .NET Core as well as .NET Standard.
58
IKVM
Java SE 8 Virtual Machine for .NET
58
IKVM
Java SE 8 Virtual Machine for .NET
57
IKVM
Java SE 8 Virtual Machine for .NET
56
IKVM
Java SE 8 Virtual Machine for .NET
54

.NET Framework 4.6.2

  • No dependencies.

.NET 8.0

.NET 9.0

.NET 10.0

.NET Standard 2.0

  • No dependencies.

Version Downloads Last updated
10.0.0-preview.3.25173.2 7 04/11/2025
10.0.0-preview.2.25163.9 7 03/20/2025
10.0.0-preview.1.25080.3 14 02/26/2025
9.0.4 5 04/09/2025
9.0.3 6 03/13/2025
9.0.2 10 02/13/2025
9.0.1 14 01/20/2025
9.0.0 18 11/13/2024
9.0.0-rc.2.24474.1 14 10/12/2024
9.0.0-rc.1.24451.1 18 09/10/2024
9.0.0-preview.7.24405.4 22 08/21/2024
9.0.0-preview.6.24327.6 26 07/13/2024
9.0.0-preview.5.24306.5 31 06/12/2024
9.0.0-preview.4.24267.1 29 05/21/2024
9.0.0-preview.3.24172.9 31 04/11/2024
9.0.0-preview.2.24128.3 31 03/18/2024
9.0.0-preview.1.24081.2 30 02/15/2024
8.0.15 5 04/09/2025
8.0.14 8 03/13/2025
8.0.13 12 02/12/2025
8.0.12 13 01/19/2025
8.0.11 15 11/13/2024
8.0.10 16 10/12/2024
8.0.8 24 08/21/2024
8.0.7 27 07/11/2024
8.0.6 28 05/29/2024
8.0.5 28 05/14/2024
8.0.4 35 04/10/2024
8.0.3 37 03/17/2024
8.0.2 35 03/07/2024
8.0.1 37 01/23/2024
8.0.0 38 11/16/2023
8.0.0-rc.2.23479.14 50 10/14/2023
8.0.0-rc.1.23419.5 45 09/14/2023
8.0.0-preview.7.23375.5 41 08/09/2023
8.0.0-preview.6.23329.4 53 08/16/2023
8.0.0-preview.5.23280.5 46 07/11/2023
8.0.0-preview.4.23259.4 40 09/14/2023
8.0.0-preview.2.23128.3 48 03/25/2023
8.0.0-preview.1.23110.8 37 08/09/2023
7.0.0 42 11/30/2022
7.0.0-rc.2.22472.3 37 08/20/2023
7.0.0-rc.1.22426.10 39 10/11/2022
7.0.0-preview.7.22375.6 41 08/23/2022
7.0.0-preview.6.22324.4 46 11/30/2022
7.0.0-preview.5.22301.12 45 07/17/2022
7.0.0-preview.4.22229.4 38 11/30/2022
7.0.0-preview.3.22175.4 41 11/30/2022
7.0.0-preview.2.22152.2 32 12/23/2022
7.0.0-preview.1.22076.8 37 11/30/2022
6.0.2-mauipre.1.22102.15 47 09/09/2022
6.0.2-mauipre.1.22054.8 49 02/06/2023
6.0.0 46 11/10/2021
6.0.0-rc.2.21480.5 43 02/08/2023
6.0.0-rc.1.21451.13 38 02/27/2023
6.0.0-preview.7.21377.19 33 08/17/2023
6.0.0-preview.6.21352.12 34 08/05/2023
6.0.0-preview.5.21301.5 45 12/02/2022
6.0.0-preview.4.21253.7 56 09/14/2022
6.0.0-preview.3.21201.4 43 08/11/2023
6.0.0-preview.2.21154.6 36 08/06/2023
6.0.0-preview.1.21102.12 40 10/19/2022
5.0.3 39 04/17/2023
5.0.2 44 02/15/2023
5.0.1 41 05/28/2022
5.0.0 49 02/01/2021
5.0.0-rc.2.20475.5 33 12/08/2022
5.0.0-rc.1.20451.14 36 08/28/2023
5.0.0-preview.8.20407.11 34 11/30/2022
5.0.0-preview.7.20364.11 43 08/07/2023
5.0.0-preview.6.20305.6 39 11/21/2022
5.0.0-preview.5.20278.1 41 07/26/2023
5.0.0-preview.4.20251.6 34 11/21/2021
5.0.0-preview.3.20214.6 43 11/21/2021
5.0.0-preview.2.20160.6 48 08/10/2023
5.0.0-preview.1.20120.5 50 08/06/2023
4.7.3 45 03/06/2023
4.7.2 39 05/16/2023
4.7.1 40 06/19/2023
4.7.0 43 06/06/2022
4.7.0-preview3.19551.4 29 08/09/2023
4.7.0-preview2.19523.17 34 09/24/2023
4.7.0-preview1.19504.10 40 11/21/2021
4.6.2 49 11/02/2022
4.6.1 37 02/27/2023
4.6.0 4,247 04/06/2023
4.6.0-rc1.19456.4 38 08/18/2023
4.6.0-preview9.19421.4 38 07/24/2022
4.6.0-preview9.19416.11 35 08/04/2023
4.6.0-preview8.19405.3 32 06/20/2023
4.6.0-preview7.19362.9 32 08/15/2023
4.6.0-preview6.19303.8 37 11/06/2022
4.6.0-preview6.19264.9 42 11/30/2022
4.6.0-preview5.19224.8 38 02/01/2023
4.6.0-preview4.19212.13 43 02/15/2023
4.6.0-preview3.19128.7 48 07/10/2023
4.6.0-preview.19073.11 42 07/24/2023
4.6.0-preview.18571.3 35 02/17/2023
4.5.2 46 02/01/2023
4.5.1 61 11/30/2022
4.5.0 38 02/27/2023
4.5.0-rc1 43 10/03/2022
4.5.0-preview2-26406-04 43 11/21/2021
4.5.0-preview1-26216-02 38 05/28/2022
4.5.0-preview1-25914-04 35 09/27/2023
4.5.0-preview1-25718-03 36 08/15/2023