44 references to new
System.Drawing.Common.Tests (17)
mono\System.Imaging\MetafileTest.cs (3)
46using Metafile mf = new(filename); 94using Metafile mf = new(Helpers.GetTestBitmapPath(WmfPlaceable)); 161using Metafile mf = new(Helpers.GetTestBitmapPath(Emf));
System\Drawing\GraphicsTests.cs (1)
285using Metafile image = new(Helpers.GetTestBitmapPath("telescope_01.wmf"));
System\Drawing\Imaging\MetafileTests.cs (12)
46using Metafile metafile = new(GetPath(WmfFile)); 53using Metafile metafile = new(GetPath(WmfFile)); 60Assert.Throws<ExternalException>(() => new Metafile(GetPath(BmpFile))); 66AssertExtensions.Throws<ArgumentNullException>("path", () => new Metafile((string)null)); 72Assert.Throws<ExternalException>(() => new Metafile("fileNotExist")); 87AssertExtensions.Throws<ArgumentException>("path", null, () => new Metafile(path)); 846using Metafile metafile = new(GetPath(WmfFile)); 888using Metafile metafile = new(GetPath(WmfFile)); 898Metafile metafile = new(GetPath(WmfFile)); 907using Metafile metafile = new(GetPath(WmfFile)); 914Metafile metafile = new(GetPath(WmfFile)); 923Metafile metafile = new(GetPath(WmfFile));
System\Drawing\TextureBrushTests.cs (1)
14yield return new object[] { new Metafile(Helpers.GetTestBitmapPath("telescope_01.wmf")), PixelFormat.Format32bppArgb, new Size(490, 654) };
System.Windows.Forms.Tests (27)
System\Windows\Forms\AxHostTests.cs (4)
1632Metafile original = new("bitmaps/milkmateya01.emf"); 1654Metafile original = new("bitmaps/telescope_01.wmf"); 1697Metafile original = new("bitmaps/milkmateya01.emf"); 1722Metafile original = new("bitmaps/telescope_01.wmf");
System\Windows\Forms\ClipboardTests.cs (4)
370using Metafile metafile = new("bitmaps/telescope_01.wmf"); 371using Metafile enhancedMetafile = new("bitmaps/milkmateya01.emf"); 436using Metafile metafile = new("bitmaps/telescope_01.wmf"); 445using Metafile metafile = new("bitmaps/milkmateya01.emf");
System\Windows\Forms\ControlPaintTests.cs (7)
1316yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), -10, -20, Color.Red }; 1317yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 0, 0, Color.Red }; 1318yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 1, 2, Color.Red }; 1319yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 0, 0, Color.Black }; 1320yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 0, 0, Color.White }; 1321yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 0, 0, Color.Transparent }; 1322yield return new object[] { new Metafile("bitmaps/telescope_01.wmf"), 0, 0, Color.Empty };
System\Windows\Forms\DataObjectTests.cs (1)
1568using var metafile = new Drawing.Imaging.Metafile("bitmaps/milkmateya01.emf");
System\Windows\Forms\ImageList.ImageCollectionTests.cs (11)
339using Metafile value = new("bitmaps/telescope_01.wmf"); 806using Metafile value = new("bitmaps/telescope_01.wmf"); 883using Metafile value = new("bitmaps/telescope_01.wmf"); 1058yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") }; 1272yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") }; 1288yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") }; 1723using Metafile value = new("bitmaps/telescope_01.wmf"); 1730yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") }; 1761yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") }; 1796yield return new object[] { index, new Metafile("bitmaps/telescope_01.wmf") }; 1813yield return new object[] { new Metafile("bitmaps/telescope_01.wmf") };