10 references to LockBits
System.Drawing.Common.Tests (10)
mono\System.Drawing\BitmapTests.cs (1)
74
bd = bmp.
LockBits
(rect, ImageLockMode.ReadWrite, PixelFormat.Format8bppIndexed, bd);
System\Drawing\BitmapTests.cs (9)
1094
AssertExtensions.Throws<ArgumentNullException>("bitmapData", () => bitmap.
LockBits
(Rectangle.Empty, ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb, null));
1115
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(x, y, width, height), ImageLockMode.ReadOnly, bitmap.PixelFormat, bitmapData));
1136
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), lockMode, format, bitmapData));
1146
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format16bppGrayScale, new BitmapData()));
1149
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format16bppGrayScale, new BitmapData()));
1165
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), lockMode, bitmap.PixelFormat, bitmapData));
1177
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb, bitmapData));
1188
Assert.Throws<InvalidOperationException>(() => bitmap.
LockBits
(new Rectangle(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat, new BitmapData()));
1191
Assert.Throws<InvalidOperationException>(() => bitmap.
LockBits
(new Rectangle(1, 1, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat, new BitmapData()));