3407 references to Rectangle
BinaryFormatTests (2)
FormatTests\FormattedObject\BinaryFormatWriterTests.cs (2)
194
new
Rectangle
(1, 2, 3, 4),
195
new
Rectangle
(int.MinValue, int.MaxValue, 0, 0),
PresentationFramework-SystemDrawing (1)
SystemDrawingExtension.cs (1)
169
new
Rectangle
(0, 0, imageWidth, imageHeight),
PresentationUI (5)
MS\Internal\Documents\SignatureSummaryDialog.cs (5)
656
Rectangle iconRect = new
Rectangle
(
666
Rectangle statusRect = new
Rectangle
(
674
Rectangle intentRect = new
Rectangle
(
701
Rectangle signByRect = new
Rectangle
(
709
Rectangle localeRect = new
Rectangle
(
System.ComponentModel.TypeConverter (2)
System\Drawing\RectangleConverter.cs (2)
53
return new
Rectangle
(values[0], values[1], values[2], values[3]);
113
return new
Rectangle
((int)x, (int)y, (int)width, (int)height);
System.Drawing.Common.Tests (494)
mono\System.Drawing.Imaging\BmpCodecTests.cs (1)
242
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing.Imaging\GifCodecTests.cs (1)
109
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing.Imaging\IconCodecTests.cs (5)
132
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
328
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
546
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
750
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
1525
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing.Imaging\JpegCodecTests.cs (2)
112
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
227
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing.Imaging\PngCodecTests.cs (3)
145
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
297
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
470
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing.Imaging\TiffCodecTests.cs (1)
119
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
mono\System.Drawing\BitmapTests.cs (13)
63
Rectangle rect =
new
(0, 0, bmp.Width, bmp.Height);
73
Rectangle rect =
new
(0, 0, bmp.Width, bmp.Height);
90
Rectangle r =
new
(4, 4, 4, 4);
110
Rectangle r =
new
(4, 4, 4, 4);
216
BitmapData bd = bmp.LockBits(new
Rectangle
(0, 0, 2, 1), ImageLockMode.ReadOnly, format);
319
Rectangle rect =
new
(0, 0, 50, 50);
411
data = test.LockBits(new
Rectangle
(0, 0, test.Width, test.Height), ImageLockMode.ReadOnly, test.PixelFormat);
504
BitmapData bd = bmp.LockBits(new
Rectangle
(0, 0, width, height), mode, fmt);
680
data = bmp.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb);
709
data = bmp.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb);
733
data = bmp.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
753
data = bmp.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format24bppRgb);
798
BitmapData data = bmp.LockBits(new
Rectangle
(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadWrite, PixelFormat.Format1bppIndexed);
mono\System.Drawing\GraphicsTests.cs (67)
152
g.Clip = new Region(new
Rectangle
(50, 40, 210, 220));
179
g.ExcludeClip(new
Rectangle
(40, 60, 100, 20));
206
g.IntersectClip(new
Rectangle
(290, 40, 60, 80));
223
g.IntersectClip(new
Rectangle
(290, 40, 60, 80));
243
g.SetClip(new Region(new
Rectangle
(50, 40, 210, 220)), CombineMode.Replace);
267
g.SetClip(new
Rectangle
(50, 40, 210, 220));
292
g.Clip = new Region(new
Rectangle
(0, 0, 100, 100));
305
g.Clip = new Region(new
Rectangle
(1, 2, 20, 25));
361
Graphics.Clip = new Region(new
Rectangle
(0, 0, width, height));
456
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
466
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
479
RectangleF clip = new
Rectangle
(0, 0, 8, 8);
497
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
513
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
528
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
544
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
563
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
599
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
622
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
643
g.Clip = new Region(new
Rectangle
(0, 0, 8, 8));
837
g.DrawRectangle(pen, new
Rectangle
(15, 0, -10, 5));
874
g.FillRectangle(brush, new
Rectangle
(15, 0, -10, 5));
955
g.Clip = new Region(new
Rectangle
(10, 10, 10, 10));
988
g.Clip = new Region(new
Rectangle
(10, 10, 10, 10));
1003
GraphicsContainer gc = g.BeginContainer(new
Rectangle
(10, 20, 30, 40), new
Rectangle
(10, 20, 300, 400), GraphicsUnit.Millimeter);
1022
g.Clip = new Region(new
Rectangle
(10, 10, 10, 10));
1103
g.Clip = new Region(new
Rectangle
(10, 10, 10, 10));
1193
Rectangle rect =
new
(5, 5, 10, 10);
1214
Rectangle rect =
new
(5, 5, 10, 10);
1378
Rectangle rect =
new
(5, 5, 10, 10);
2337
Assert.Throws<ArgumentNullException>(() => g.DrawIcon(null, new
Rectangle
(0, 0, 32, 32)));
2345
g.DrawIcon(SystemIcons.Application, new
Rectangle
(0, 0, 40, 20));
2348
g.DrawIcon(SystemIcons.Asterisk, new
Rectangle
(0, 0, 0, 0));
2350
g.DrawIcon(SystemIcons.Error, new
Rectangle
(20, 40, 0, 0));
2352
g.DrawIconUnstretched(SystemIcons.WinLogo, new
Rectangle
(10, 20, -1, 0));
2353
g.DrawIconUnstretched(SystemIcons.WinLogo, new
Rectangle
(20, 10, 0, -1));
2378
Assert.Throws<ArgumentNullException>(() => g.DrawIconUnstretched(null, new
Rectangle
(0, 0, 40, 20)));
2386
g.DrawIconUnstretched(SystemIcons.Information, new
Rectangle
(0, 0, 40, 20));
2389
g.DrawIconUnstretched(SystemIcons.Question, new
Rectangle
(0, 0, 0, 0));
2391
g.DrawIconUnstretched(SystemIcons.Warning, new
Rectangle
(20, 40, 0, 0));
2393
g.DrawIconUnstretched(SystemIcons.WinLogo, new
Rectangle
(10, 20, -1, 0));
2394
g.DrawIconUnstretched(SystemIcons.WinLogo, new
Rectangle
(20, 10, 0, -1));
2472
Assert.Throws<ArgumentNullException>(() => g.DrawImage(null, new
Rectangle
(0, 0, 0, 0)));
2482
g.DrawImage(bmp, new
Rectangle
(0, 0, 0, 0));
2484
g.DrawImage(bmp, new
Rectangle
(20, 40, 0, 0));
2486
g.DrawImage(bmp, new
Rectangle
(10, 20, -1, 0));
2487
g.DrawImage(bmp, new
Rectangle
(20, 10, 0, -1));
2598
Rectangle r =
new
(0, 0, 40, 40);
2624
Rectangle r =
new
(1, 2, 3, 4);
2633
Rectangle r =
new
(1, 2, 3, 4);
2682
Rectangle r =
new
(1, 2, 3, 4);
2691
Rectangle r =
new
(1, 2, 3, 4);
2742
Rectangle r =
new
(1, 2, 3, 4);
2753
Rectangle r =
new
(1, 2, 3, 4);
2781
Assert.Throws<ArgumentNullException>(() => g.DrawImageUnscaled(null, new
Rectangle
(0, 0, -1, -1)));
2789
g.DrawImageUnscaled(bmp, new
Rectangle
(0, 0, -1, -1));
2829
Assert.Throws<ArgumentNullException>(() => g.DrawImageUnscaledAndClipped(null, new
Rectangle
(0, 0, 0, 0)));
2839
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(0, 0, 0, 0));
2841
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(20, 40, 0, 0));
2843
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(10, 20, -1, 0));
2844
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(20, 10, 0, -1));
2846
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(0, 0, 10, 20));
2847
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(0, 0, 40, 10));
2848
g.DrawImageUnscaledAndClipped(bmp, new
Rectangle
(0, 0, 80, 20));
2875
Rectangle baserect =
new
(0, 0, 19, 19);
2917
Rectangle baserect =
new
(0, 0, 19, 19);
System\Drawing\BitmapTests.cs (68)
359
yield return new object[] { new Bitmap(3, 3, PixelFormat.Format32bppArgb), new
Rectangle
(0, 0, 3, 3), PixelFormat.Format32bppArgb };
360
yield return new object[] { new Bitmap(3, 3, PixelFormat.Format32bppArgb), new
Rectangle
(0, 0, 3, 3), PixelFormat.Format24bppRgb };
361
yield return new object[] { new Bitmap(3, 3, PixelFormat.Format1bppIndexed), new
Rectangle
(1, 1, 1, 1), PixelFormat.Format64bppArgb };
362
yield return new object[] { new Bitmap(3, 3, PixelFormat.Format64bppPArgb), new
Rectangle
(1, 1, 1, 1), PixelFormat.Format16bppRgb565 };
426
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.Clone(new
Rectangle
(0, 0, width, height), bitmap.PixelFormat));
440
Assert.Throws<OutOfMemoryException>(() => bitmap.Clone(new
Rectangle
(x, y, width, height), bitmap.PixelFormat));
456
Assert.Throws<OutOfMemoryException>(() => bitmap.Clone(new
Rectangle
(0, 0, 1, 1), format));
464
Assert.Throws<OutOfMemoryException>(() => bitmap.Clone(new
Rectangle
(0, 0, 1, 1), PixelFormat.Format32bppArgb));
485
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.Clone(new
Rectangle
(0, 0, 1, 1), PixelFormat.Format32bppArgb));
1014
yield return new object[] { bitmap(), new
Rectangle
(0, 0, 2, 2), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb, 8, 1 };
1015
yield return new object[] { bitmap(), new
Rectangle
(0, 0, 2, 2), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb, 8, 3 };
1016
yield return new object[] { bitmap(), new
Rectangle
(0, 0, 2, 2), ImageLockMode.WriteOnly, PixelFormat.Format32bppArgb, 8, 2 };
1018
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb, 400, 1 };
1019
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format32bppRgb, 400, 3 };
1020
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format32bppRgb, 400, 2 };
1022
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb, 300, 65537 };
1023
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format24bppRgb, 300, 65539 };
1024
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format24bppRgb, 300, 65538 };
1026
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb, 300, 1 };
1027
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format24bppRgb, 300, 3 };
1028
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format24bppRgb, 300, 2 };
1030
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb, 400, 65537 };
1031
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format32bppRgb, 400, 65539 };
1032
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format24bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format32bppRgb, 400, 65538 };
1034
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb, 300, 65537 };
1036
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format8bppIndexed, 100, 1 };
1037
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format8bppIndexed, 100, 3 };
1038
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format8bppIndexed, 100, 2 };
1040
yield return new object[] { new Bitmap(184, 184, PixelFormat.Format1bppIndexed), new
Rectangle
(0, 0, 184, 184), ImageLockMode.ReadOnly, PixelFormat.Format1bppIndexed, 24, 1 };
1041
yield return new object[] { new Bitmap(184, 184, PixelFormat.Format1bppIndexed), new
Rectangle
(0, 0, 184, 184), ImageLockMode.ReadWrite, PixelFormat.Format1bppIndexed, 24, 3 };
1042
yield return new object[] { new Bitmap(184, 184, PixelFormat.Format1bppIndexed), new
Rectangle
(0, 0, 184, 184), ImageLockMode.WriteOnly, PixelFormat.Format1bppIndexed, 24, 2 };
1044
yield return new object[] { bitmap(), new
Rectangle
(1, 1, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb, 8, 1 };
1045
yield return new object[] { bitmap(), new
Rectangle
(1, 1, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb, 8, 3 };
1046
yield return new object[] { bitmap(), new
Rectangle
(1, 1, 1, 1), ImageLockMode.WriteOnly, PixelFormat.Format32bppArgb, 8, 2 };
1048
yield return new object[] { bitmap(), new
Rectangle
(1, 1, 1, 1), ImageLockMode.ReadOnly - 1, PixelFormat.Format32bppArgb, 8, 0 };
1050
yield return new object[] { bitmap(), new
Rectangle
(0, 0, 2, 2), ImageLockMode.WriteOnly, PixelFormat.Format16bppGrayScale, 4, 65538 };
1052
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadOnly, PixelFormat.Format8bppIndexed, 100, 65537 };
1053
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format8bppIndexed, 100, 65539 };
1054
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format32bppRgb), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format8bppIndexed, 100, 65538 };
1056
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.ReadWrite, PixelFormat.Format24bppRgb, 300, 65539 };
1057
yield return new object[] { new Bitmap(100, 100, PixelFormat.Format8bppIndexed), new
Rectangle
(0, 0, 100, 100), ImageLockMode.WriteOnly, PixelFormat.Format24bppRgb, 300, 65538 };
1113
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(x, y, width, height), ImageLockMode.ReadOnly, bitmap.PixelFormat));
1116
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(x, y, width, height), ImageLockMode.ReadOnly, bitmap.PixelFormat, bitmapData));
1134
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), lockMode, format));
1137
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));
1147
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));
1150
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format16bppGrayScale, new BitmapData()));
1152
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.WriteOnly, PixelFormat.Format16bppGrayScale);
1163
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), lockMode, bitmap.PixelFormat));
1166
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), lockMode, bitmap.PixelFormat, bitmapData));
1175
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb));
1178
AssertExtensions.Throws<ArgumentException>(null, () => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb, bitmapData));
1186
bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat);
1188
Assert.Throws<InvalidOperationException>(() => bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat));
1189
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));
1192
Assert.Throws<InvalidOperationException>(() => bitmap.LockBits(new
Rectangle
(1, 1, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat, new BitmapData()));
1202
BitmapData data = bitmap.LockBits(new
Rectangle
(offset, offset, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat);
1213
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat);
1225
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat);
1249
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, bitmap.PixelFormat);
1348
BitmapData bitmapData = bitmap.LockBits(new
Rectangle
(0, 0, 2, 1), ImageLockMode.ReadOnly, format);
1474
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format32bppArgb);
1503
data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb);
1527
BitmapData data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadOnly, PixelFormat.Format24bppRgb);
1546
data = bitmap.LockBits(new
Rectangle
(0, 0, 1, 1), ImageLockMode.ReadWrite, PixelFormat.Format24bppRgb);
System\Drawing\BufferedGraphicsContextTests.cs (8)
35
using BufferedGraphics bufferedGraphics = context.Allocate(graphics, new
Rectangle
(0, 0, context.MaximumBuffer.Width - 1, context.MaximumBuffer.Height - 1));
47
using BufferedGraphics bufferedGraphics = context.Allocate(graphics, new
Rectangle
(0, 0, context.MaximumBuffer.Width + 1, context.MaximumBuffer.Height + 1));
84
using (BufferedGraphics bufferedGraphics = context.Allocate(hdc, new
Rectangle
(0, 0, context.MaximumBuffer.Width - 1, context.MaximumBuffer.Height - 1)))
106
using (BufferedGraphics bufferedGraphics = context.Allocate(hdc, new
Rectangle
(0, 0, context.MaximumBuffer.Width + 1, context.MaximumBuffer.Height + 1)))
123
AssertExtensions.Throws<ArgumentException>(null, () => context.Allocate(-1, new
Rectangle
(0, 0, 10, 10)));
139
Assert.Throws<ArgumentNullException>("hdc", () => context.Allocate(null, new
Rectangle
(0, 0, 10, 10)));
150
Rectangle largeRectangle =
new
(0, 0, context.MaximumBuffer.Width + 1, context.MaximumBuffer.Height + 1);
165
Rectangle largeRectangle =
new
(0, 0, context.MaximumBuffer.Width + 1, context.MaximumBuffer.Height + 1);
System\Drawing\BufferedGraphicsTests.cs (9)
14
BufferedGraphics graphics = context.Allocate(targetGraphics, new
Rectangle
(0, 0, 1, 1));
29
BufferedGraphics graphics = context.Allocate(targetGraphics, new
Rectangle
(0, 0, context.MaximumBuffer.Width + 1, context.MaximumBuffer.Height + 1));
47
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 3, 3));
49
using BufferedGraphics bufferedGraphics = context.Allocate(graphics, new
Rectangle
(0, 0, 3, 3));
67
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 3, 3));
72
using BufferedGraphics bufferedGraphics = context.Allocate(hdc, new
Rectangle
(0, 0, 3, 3));
92
originalGraphics.FillRectangle(brush, new
Rectangle
(0, 0, 3, 3));
94
using BufferedGraphics graphics = context.Allocate(originalGraphics, new
Rectangle
(0, 0, 3, 3));
111
using BufferedGraphics bufferedGraphics = context.Allocate(graphics, new
Rectangle
(0, 0, 1, 1));
System\Drawing\Drawing2D\CustomLineCapTests.cs (1)
22
strokePath.AddRectangle(new
Rectangle
(0, 0, 10, 10));
System\Drawing\Drawing2D\GraphicsPathTests.cs (30)
147
gp.AddRectangle(new
Rectangle
(1, 1, 2, 2));
160
gp.AddRectangle(new
Rectangle
(1, 1, 2, 2));
180
gp.AddRectangle(new
Rectangle
(1, 1, 2, 2));
346
gpi.AddArc(new
Rectangle
(1, 1, 2, 2), Pi4, Pi4);
705
gpi.AddRectangle(new
Rectangle
(1, 1, 2, 2));
718
gpi.AddRectangle(new
Rectangle
(1, 1, 1, 1));
724
gpi.AddRectangle(new
Rectangle
((int)endI.X, (int)endI.Y, 1, 1));
748
gpi.AddRectangle(new
Rectangle
(1, 2, width, height));
815
gpi.AddEllipse(new
Rectangle
(1, 1, 2, 2));
854
gpi.AddPie(new
Rectangle
(1, 1, 2, 2), Pi4, Pi4);
881
AssertExtensions.Throws<ArgumentException>(null, () => gp.AddPie(new
Rectangle
(1, 1, height, width), Pi4, Pi4));
978
inner.AddRectangle(new
Rectangle
(1, 1, 2, 2));
1007
gpi.AddString("mono", FontFamily.GenericMonospace, 0, 10, new
Rectangle
(10, 10, 10, 10), StringFormat.GenericDefault);
1023
gpi.AddString("mono", FontFamily.GenericMonospace, 0, -10, new
Rectangle
(10, 10, 10, 10), StringFormat.GenericDefault);
1071
gp.AddString(null, FontFamily.GenericMonospace, 0, 10, new
Rectangle
(10, 10, 10, 10), StringFormat.GenericDefault));
1089
gp.AddRectangle(new
Rectangle
(1, 1, 2, 2));
1140
Rectangle rectangle =
new
(10, 10, 100, 100);
1272
gp.AddRectangle(new
Rectangle
(0, 0, 100, 100));
1662
gp.AddRectangle(new
Rectangle
(1, 1, 2, 2));
1714
yield return new object[] { new
Rectangle
(1, 1, 2, 2), 0f, new RectangleF(0.5f, 0.5f, 3.0f, 3.0f) };
1715
yield return new object[] { new
Rectangle
(1, 1, 2, 2), 0.5f, new RectangleF(0.5f, 0.5f, 3.0f, 3.0f) };
1716
yield return new object[] { new
Rectangle
(1, 1, 2, 2), 1.0f, new RectangleF(0.5f, 0.5f, 3.0f, 3.0f) };
1717
yield return new object[] { new
Rectangle
(1, 1, 2, 2), 1.1f, new RectangleF(0.45f, 0.45f, 3.10f, 3.10f) };
1931
gp.AddRectangle(new
Rectangle
(1, 2, 3, 4));
1970
gp.AddRectangle(new
Rectangle
(200, 201, 60, 61));
2006
gp.AddRectangle(new
Rectangle
(200, 201, 60, 61));
2277
gp.AddRectangle(new
Rectangle
(10, 10, 20, 20));
2304
gp.AddRectangle(new
Rectangle
(10, 10, 20, 20));
2325
gp.AddEllipse(new
Rectangle
(10, 10, 20, 20));
2355
path.AddRoundedRectangle(new
Rectangle
(10, 10, 20, 20), new(5, 5));
System\Drawing\Drawing2D\LinearGradientBrushTests.cs (82)
75
yield return new object[] { new
Rectangle
(0, 0, 1, 2), Color.Empty, Color.Red, LinearGradientMode.BackwardDiagonal };
76
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, LinearGradientMode.ForwardDiagonal };
77
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), Color.Red, Color.Red, LinearGradientMode.Horizontal };
78
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Plum, LinearGradientMode.Vertical };
117
yield return new object[] { new
Rectangle
(0, 0, 1, 2), Color.Empty, Color.Red, 90 };
118
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 180 };
119
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), Color.Red, Color.Red, 0 };
120
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), Color.Red, Color.Red, 360 };
121
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Plum, 90 };
204
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 0, 4), Color.Empty, Color.Empty, 0f));
206
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 0, 4), Color.Empty, Color.Empty, LinearGradientMode.BackwardDiagonal));
208
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 0, 4), Color.Empty, Color.Empty, 0, true));
215
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 3, 0), Color.Empty, Color.Empty, 0f));
217
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 3, 0), Color.Empty, Color.Empty, LinearGradientMode.BackwardDiagonal));
219
AssertExtensions.Throws<ArgumentException>(null, () => new LinearGradientBrush(new
Rectangle
(1, 2, 3, 0), Color.Empty, Color.Empty, 0, true));
228
Assert.ThrowsAny<ArgumentException>(() => new LinearGradientBrush(new
Rectangle
(1, 2, 3, 4), Color.Empty, Color.Empty, linearGradientMode));
235
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
249
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
258
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
280
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
299
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
311
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
318
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
325
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
332
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
339
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
346
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
358
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true) { GammaCorrection = gammaCorrection };
365
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
375
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
390
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true)
411
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
418
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
427
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
436
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
446
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
459
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
470
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true)
491
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true)
510
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true)
535
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true) { LinearColors = colors };
542
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
551
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
558
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
568
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
578
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true) { Transform = transform };
585
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
592
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
606
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true) { WrapMode = wrapMode };
615
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
622
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
629
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
639
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
649
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
658
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
674
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
695
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
703
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
717
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
726
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
739
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
756
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
769
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
776
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
789
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
806
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
819
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
826
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
840
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
857
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
870
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
877
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
891
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
902
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
914
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
921
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
934
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 0, true);
948
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 0, true);
962
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
974
using LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
981
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
991
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
System\Drawing\Drawing2D\MatrixTests.cs (6)
97
yield return new object[] { new
Rectangle
(1, 4, 8, 16), new Point[] { new(32, 64), new(128, 256), new(512, 1024) }, new float[] { 12, 24, 30, 60, -100, -200 }, false, false };
98
yield return new object[] { new
Rectangle
(0, 0, 2, 4), new Point[] { new(8, 16), new(32, 64), new(128, 256) }, new float[] { 12, 24, 30, 60, 8, 16 }, false, false };
99
yield return new object[] { new
Rectangle
(0, 0, 1, 1), new Point[] { new(0, 0), new(0, 0), new(0, 0) }, new float[] { 0, 0, 0, 0, 0, 0 }, false, false };
100
yield return new object[] { new
Rectangle
(0, 0, 1, 1), new Point[] { new(0, 0), new(1, 0), new(0, 1) }, new float[] { 1, 0, 0, 1, 0, 0 }, true, true };
147
Assert.Throws<OutOfMemoryException>(() => new Matrix(new
Rectangle
(1, 1, 0, 1), new Point[3]));
154
Assert.Throws<OutOfMemoryException>(() => new Matrix(new
Rectangle
(1, 1, 1, 0), new Point[3]));
System\Drawing\Graphics_DrawBezierTests.cs (1)
110
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
System\Drawing\Graphics_GetContextTests.Core.cs (5)
29
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
62
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
81
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
100
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
121
graphics.SetClip(new
Rectangle
(1, 2, 9, 10));
System\Drawing\Graphics_GetContextTests.cs (5)
33
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
65
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
83
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
101
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
122
using Region initialClip = new(new
Rectangle
(1, 2, 9, 10));
System\Drawing\GraphicsTests.cs (39)
320
graphics.FillRectangle(transparentBlackBrush, new
Rectangle
(0, 0, 2, 2));
321
graphics.FillRectangle(transparentWhiteBrush, new
Rectangle
(1, 1, 2, 2));
410
graphics.FillRectangle(transparentBlackBrush, new
Rectangle
(0, 0, 2, 2));
411
graphics.FillRectangle(transparentWhiteBrush, new
Rectangle
(1, 1, 2, 2));
866
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 3, 3));
1076
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 3, 2));
1228
LinearGradientBrush brush = new(new
Rectangle
(1, 2, 3, 4), Color.Plum, Color.Red, 45, true);
1559
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 10, 10));
1562
Rectangle drawnRect =
new
(destinationX, destinationY, width, height);
1960
AssertExtensions.Throws<ArgumentNullException>("pen", () => graphics.DrawArc(null, new
Rectangle
(0, 0, 1, 1), 0, 90));
1974
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
1986
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 0, 1), 0, 90));
1998
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 0), 0, 90));
2013
Assert.Throws<InvalidOperationException>(() => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
2032
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
2043
AssertExtensions.Throws<ArgumentNullException>("pen", () => graphics.DrawRectangle(null, new
Rectangle
(0, 0, 1, 1)));
2056
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawRectangle(pen, new
Rectangle
(0, 0, 1, 1)));
2070
Assert.Throws<InvalidOperationException>(() => graphics.DrawRectangle(pen, new
Rectangle
(0, 0, 1, 1)));
2088
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawRectangle(pen, new
Rectangle
(0, 0, 1, 1)));
2169
AssertExtensions.Throws<ArgumentNullException>("pen", () => graphics.DrawEllipse(null, new
Rectangle
(0, 0, 1, 1)));
2183
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawEllipse(pen, new
Rectangle
(0, 0, 1, 1)));
2198
Assert.Throws<InvalidOperationException>(() => graphics.DrawEllipse(pen, new
Rectangle
(0, 0, 1, 1)));
2217
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawEllipse(pen, new
Rectangle
(0, 0, 1, 1)));
2228
AssertExtensions.Throws<ArgumentNullException>("pen", () => graphics.DrawPie(null, new
Rectangle
(0, 0, 1, 1), 0, 90));
2242
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawPie(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
2254
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawPie(pen, new
Rectangle
(0, 0, 0, 1), 0, 90));
2266
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawArc(pen, new
Rectangle
(0, 0, 1, 0), 0, 90));
2281
Assert.Throws<InvalidOperationException>(() => graphics.DrawPie(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
2300
AssertExtensions.Throws<ArgumentException>(null, () => graphics.DrawPie(pen, new
Rectangle
(0, 0, 1, 1), 0, 90));
2661
AssertExtensions.Throws<ArgumentNullException>("brush", () => graphics.FillPie(null, new
Rectangle
(0, 0, 1, 1), 0, 90));
2674
AssertExtensions.Throws<ArgumentException>(null, () => graphics.FillPie(brush, new
Rectangle
(0, 0, 1, 1), 0, 90));
2685
AssertExtensions.Throws<ArgumentException>(null, () => graphics.FillPie(brush, new
Rectangle
(0, 0, 0, 1), 0, 90));
2696
AssertExtensions.Throws<ArgumentException>(null, () => graphics.FillPie(brush, new
Rectangle
(0, 0, 1, 0), 0, 90));
2710
Assert.Throws<InvalidOperationException>(() => graphics.FillPie(brush, new
Rectangle
(0, 0, 1, 1), 0, 90));
2728
AssertExtensions.Throws<ArgumentException>(null, () => graphics.FillPie(brush, new
Rectangle
(0, 0, 1, 1), 0, 90));
2741
graphics.FillRectangle(brush, new
Rectangle
(0, 0, 2, 2));
2834
Rectangle rect =
new
(10, 10, 50, 50);
2974
graphics.DrawRoundedRectangle(Pens.Red,
new
(0, 0, 10, 10), new(2, 2));
2992
graphics.FillRoundedRectangle(Brushes.Green,
new
(0, 0, 10, 10), new(2, 2));
System\Drawing\Imaging\ImageAttributesTests.cs (3)
32
private readonly Rectangle _rectangle =
new
(0, 0, 64, 64);
136
graphicsBigBitmap.DrawImage(bitmapSmall, new
Rectangle
(0, 0, 100, 100), 0, 0, 100, 100, GraphicsUnit.Pixel, null);
137
graphicsBigBitmap.DrawImage(bitmapSmall, new
Rectangle
(100, 0, 100, 100), 0, 0, 100, 100, GraphicsUnit.Pixel, imageAttr);
System\Drawing\Imaging\MetafileTests.cs (5)
34
private readonly Rectangle _rectangle =
new
(0, 0, 64, 64);
968
Assert.Equal(new
Rectangle
(0, 0, 1, 1), metafile.GetBounds(ref graphicsUnit));
975
Assert.Equal(new
Rectangle
(0, 0, 0, 0), metafileHeader.Bounds);
984
Assert.Equal(new
Rectangle
(-30, -40, 3096, 4127), metafile.GetBounds(ref graphicsUnit));
992
Assert.Equal(new
Rectangle
(-30, -40, 3096, 4127), header.Bounds);
System\Drawing\Printing\PrintDocumentTests.cs (2)
238
Assert.Equal(new
Rectangle
(0, 0, 827, 1169), pageSettings.Bounds);
242
Assert.Equal(new
Rectangle
(0, 0, 850, 1100), pageSettings.Bounds);
System\Drawing\Printing\PrinterUnitConvertTests.cs (2)
99
var converted = PrinterUnitConvert.Convert(new
Rectangle
(100, 1000, 100, 1000), fromUnit, toUnit);
100
Assert.Equal(new
Rectangle
(expectedLeftValue, expectedRightValue, expectedLeftValue, expectedRightValue), converted);
System\Drawing\RegionTests.cs (131)
56
Rectangle rectangle =
new
(x, y, width, height);
83
yield return new object[] { new Region(new
Rectangle
(0, 0, 0, 0)) };
84
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
104
graphicsPath.AddRectangle(new
Rectangle
(1, 2, 3, 4));
113
using Region region = new(new
Rectangle
(1, 2, 3, 4));
167
graphicsPath.AddRectangle(new
Rectangle
(1, 2, 3, 4));
168
graphicsPath.AddRectangle(new
Rectangle
(4, 5, 6, 7));
194
path1.AddRectangle(new
Rectangle
(-4194304, -4194304, 8388608, 8388608));
198
path2.AddRectangle(new
Rectangle
(-4194304, -4194304, 8388608, 8388608));
203
path3.AddRectangle(new
Rectangle
(-4194304, -4194304, 8388608, 8388608));
204
path3.AddRectangle(new
Rectangle
(1, 2, 3, 4));
355
using Region region = new(new
Rectangle
(20, 20, 20, 20));
356
using Region other = new(new
Rectangle
(20, 80, 20, 10));
358
other.Union(new
Rectangle
(60, 60, 30, 10));
373
region.Intersect(new
Rectangle
(5, 5, -10, -10));
374
region.Complement(new
Rectangle
(-5, -5, 12, 12));
388
using Region region = new(new
Rectangle
(1, 2, 3, 4));
430
region.Complement(new
Rectangle
((int)rect.X, (int)rect.Y, (int)rect.Width, (int)rect.Height));
475
Rectangle rect1 =
new
(20, 30, 60, 80);
476
Rectangle rect2 =
new
(50, 40, 60, 80);
538
yield return new object[] { new Region(), new Region(new
Rectangle
(1, 2, 3, 4)), false };
541
yield return new object[] { Empty(), new Region(new
Rectangle
(0, 0, 0, 0)), true };
542
yield return new object[] { Empty(), new Region(new
Rectangle
(1, 2, 3, 3)), false };
544
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new
Rectangle
(1, 2, 3, 4)), true };
545
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new RectangleF(1, 2, 3, 4)), true };
546
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new
Rectangle
(2, 2, 3, 4)), false };
547
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new
Rectangle
(1, 3, 3, 4)), false };
548
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new
Rectangle
(1, 2, 4, 4)), false };
549
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)), new Region(new
Rectangle
(1, 2, 3, 5)), false };
552
graphics1.AddRectangle(new
Rectangle
(1, 2, 3, 4));
555
graphics2.AddRectangle(new
Rectangle
(1, 2, 3, 4));
558
graphics3.AddRectangle(new
Rectangle
(2, 2, 3, 4));
561
graphics4.AddRectangle(new
Rectangle
(1, 3, 3, 4));
564
graphics5.AddRectangle(new
Rectangle
(1, 2, 4, 4));
567
graphics6.AddRectangle(new
Rectangle
(1, 2, 3, 5));
626
new Region(new
Rectangle
(500, 30, 60, 80)),
633
new Region(new
Rectangle
(500, 30, 60, 80)),
655
new RectangleF[] { new
Rectangle
(-4194304, -4194304, 8388608, 8388608) }
661
new Region(new
Rectangle
(10, 10, 100, 100)),
674
new Region(new
Rectangle
(70, 10, 100, 100)),
687
new Region(new
Rectangle
(40, 100, 100, 100)),
700
new Region(new
Rectangle
(40, 10, 100, 100)),
713
new Region(new
Rectangle
(30, 30, 80, 80)),
730
new Region(new
Rectangle
(50, 100, 100, 100)),
738
new Region(new
Rectangle
(70, 60, 100, 70)),
746
new Region(new
Rectangle
(70, 60, 100, 70)),
754
new Region(new
Rectangle
(20, 20, 100, 100)),
761
new Region(new
Rectangle
(130, 30, 60, 80)),
802
using Region region = new(new
Rectangle
(1, 2, 3, 4));
837
region.Exclude(new
Rectangle
((int)rect.X, (int)rect.Y, (int)rect.Width, (int)rect.Height));
911
using Region region = new(new
Rectangle
(1, 2, 3, 4));
936
using Region region = new(new
Rectangle
(1, 2, 3, 4));
1010
using Region region = new(new
Rectangle
(1, 2, 3, 4));
1047
Rectangle smaller =
new
(5, 5, -10, -10);
1062
new Region(new
Rectangle
(500, 30, 60, 80)),
1068
new Region(new
Rectangle
(0, 0, 0, 0)),
1075
new Region(new
Rectangle
(500, 30, 60, 80)),
1084
new RectangleF[] { new
Rectangle
(520, 40, 60, 80) }
1134
using Region region = new(new
Rectangle
(1, 2, 3, 4));
1139
Assert.Equal([new
Rectangle
(1, 2, 3, 4)], region.GetRegionScans(matrix));
1170
region.Intersect(new
Rectangle
((int)rect.X, (int)rect.Y, (int)rect.Width, (int)rect.Height));
1183
region.Intersect(new
Rectangle
(5, 5, -10, -10));
1304
infiniteExclude.Exclude(new
Rectangle
(387, 292, 189, 133));
1305
infiniteExclude.Exclude(new
Rectangle
(387, 66, 189, 133));
1307
yield return new object[] { infiniteExclude, new
Rectangle
(66, 292, 189, 133), true };
1310
yield return new object[] { new Region(new
Rectangle
(0, 0, 10, 10)), new
Rectangle
(0, 0, 0, 1), false };
1311
yield return new object[] { new Region(new
Rectangle
(500, 30, 60, 80)), new
Rectangle
(500, 30, 60, 80), true };
1312
yield return new object[] { new Region(new
Rectangle
(500, 30, 60, 80)), new
Rectangle
(520, 40, 60, 80), true };
1314
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(1, 1, 2, 1), true };
1315
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(1, 1, 2, 2), true };
1316
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(1, 1, 10, 10), true };
1317
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(1, 1, 1, 1), true };
1318
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(2, 2, 1, 1), false };
1319
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(0, 0, 1, 1), false };
1320
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new
Rectangle
(3, 3, 1, 1), false };
1356
infiniteExclude.Exclude(new
Rectangle
(387, 292, 189, 133));
1357
infiniteExclude.Exclude(new
Rectangle
(387, 66, 189, 133));
1362
yield return new object[] { new Region(new
Rectangle
(500, 30, 60, 80)), new Point(500, 29), false };
1363
yield return new object[] { new Region(new
Rectangle
(500, 30, 60, 80)), new Point(500, 30), true };
1365
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(0, 1), false };
1366
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(1, 0), false };
1367
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(2, 0), false };
1368
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(3, 0), false };
1369
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(1, 1), true };
1370
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(2, 1), true };
1371
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(3, 1), false };
1372
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(0, 2), false };
1373
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(2, 2), false };
1374
yield return new object[] { new Region(new
Rectangle
(1, 1, 2, 1)), new Point(3, 2), false };
1424
AssertExtensions.Throws<ArgumentException>(null, () => disposedRegion.IsVisible(new
Rectangle
(1, 2, 3, 4)));
1428
AssertExtensions.Throws<ArgumentException>(null, () => disposedRegion.IsVisible(new
Rectangle
(1, 2, 3, 4), s_graphic));
1490
new Region(new
Rectangle
(500, 30, 60, 80)),
1497
new Region(new
Rectangle
(500, 30, 60, 80)),
1504
new Region(new
Rectangle
(500, 30, 60, 80)),
1511
new Region(new
Rectangle
(500, 30, 60, 80)),
1525
new RectangleF[] { new
Rectangle
(-4194304, -4194304, 8388608, 8388608) }
1532
new RectangleF[] { new
Rectangle
(-4194304, -4194304, 8388608, 8388608) }
1538
new Region(new
Rectangle
(20, 20, 20, 20)),
1554
new Region(new
Rectangle
(20, 180, 40, 50)),
1572
new Region(new
Rectangle
(20, 330, 40, 50)),
1592
new Region(new
Rectangle
(10, 20, 50, 50)),
1609
new Region(new
Rectangle
(10, 10, 100, 100)),
1622
new Region(new
Rectangle
(70, 10, 100, 100)),
1635
new Region(new
Rectangle
(40, 100, 100, 100)),
1647
new Region(new
Rectangle
(40, 10, 100, 100)),
1659
new Region(new
Rectangle
(30, 30, 80, 80)),
1696
using Region region = new(new
Rectangle
(1, 2, 3, 4));
1701
Assert.Equal([new
Rectangle
(-4194304, -4194304, 8388608, 8388608)], region.GetRegionScans(matrix));
1733
region.Union(new
Rectangle
((int)rect.X, (int)rect.Y, (int)rect.Width, (int)rect.Height));
1853
region.Intersect(new
Rectangle
(-10, -10, 20, 20));
1865
region.Intersect(new
Rectangle
(-10, -10, 20, 20));
1903
region.Intersect(new
Rectangle
(-10, -10, 20, 20));
1926
region.Intersect(new
Rectangle
(-10, -10, 20, 20));
2011
new RectangleF[] { new
Rectangle
(-4194304, -4194304, 8388608, 8388608) }
2048
using Region region = new(new
Rectangle
(1, 2, 3, 4));
2091
region.Xor(new
Rectangle
((int)rect.X, (int)rect.Y, (int)rect.Width, (int)rect.Height));
System\Drawing\TextureBrushTests.cs (4)
81
yield return new object[] { new Bitmap(10, 10), new
Rectangle
(0, 0, 10, 10) };
82
yield return new object[] { new Bitmap(10, 10), new
Rectangle
(5, 5, 5, 5) };
289
Rectangle rectangle =
new
(x, y, width, height);
814
targetGraphics.FillRectangle(brush, new
Rectangle
(0, 0, 4, 4));
System.Drawing.Primitives (6)
System\Drawing\Rectangle.cs (6)
51
new
Rectangle
(left, top, unchecked(right - left), unchecked(bottom - top));
181
return new
Rectangle
(
196
return new
Rectangle
(
211
return new
Rectangle
(
297
return new
Rectangle
(x1, y1, x2 - x1, y2 - y1);
320
return new
Rectangle
(x1, y1, x2 - x1, y2 - y1);
System.Private.Windows.Core (1)
System\Private\Windows\Core\Nrbf\SerializationRecordExtensions.cs (1)
175
value = new
Rectangle
(
System.Windows.Forms (267)
System\Windows\Forms\Accessibility\AccessibleObjectExtensions.cs (1)
45
return new
Rectangle
(pxLeft, pyTop, pcxWidth, pcyHeight);
System\Windows\Forms\ActiveX\AxHost.cs (4)
1225
SetObjectRects(new
Rectangle
(x, y, width, height));
1231
SetObjectRects(new
Rectangle
(x, y, width, height));
3259
Bounds = new
Rectangle
(location.X, location.Y, ocxExtent.Width, ocxExtent.Height);
3266
Bounds = new
Rectangle
(location.X, location.Y, newSize.Width, newSize.Height);
System\Windows\Forms\Control.cs (8)
1010
get =>
new
(_x, _y, _width, _height);
1164
public Rectangle ClientRectangle => new
Rectangle
(0, 0, _clientWidth, _clientHeight);
1650
=>
new
(0, 0, _clientWidth, _clientHeight);
5196
Rectangle newBounds =
new
(suggestedX, suggestedY, 0, 0)
5206
return new
Rectangle
(suggestedX, suggestedY, proposedWidth, proposedHeight);
5339
return new
Rectangle
(sx, sy, sw, sh);
8227
Rectangle shift =
new
(-Left, -Top, parent.Width, parent.Height);
8230
Rectangle newClipRect =
new
(
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
611
return new
Rectangle
(-1, -1, 1, 1);
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.cs (5)
332
Rectangle left =
new
(bounds.X, bounds.Y, size, bounds.Height);
333
Rectangle right =
new
(bounds.X + bounds.Width - size, bounds.Y, size, bounds.Height);
334
Rectangle top =
new
(bounds.X + size, bounds.Y, bounds.Width - size * 2, size);
335
Rectangle bottom =
new
(bounds.X + size, bounds.Y + bounds.Height - size, bounds.Width - size * 2, size);
380
Rectangle bounds =
new
(
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.LayoutOptions.cs (2)
280
Rectangle textAdjusted =
new
(
358
layout.CheckBounds = new
Rectangle
(Client.X, Client.Y, checkSizeFull, checkSizeFull);
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckBoxBaseAdapter.cs (1)
307
RECT rcCheck = new
Rectangle
(0, 0, fullSize.Width, fullSize.Height);
System\Windows\Forms\Controls\Buttons\ButtonInternal\RadioButtonBaseAdapter.cs (2)
152
Rectangle vCross =
new
(
160
Rectangle hCross =
new
(
System\Windows\Forms\Controls\Buttons\CheckBox.cs (1)
303
return new
Rectangle
(-1, -1, 1, 1);
System\Windows\Forms\Controls\Buttons\RadioButton.cs (1)
277
return new
Rectangle
(-1, -1, 1, 1);
System\Windows\Forms\Controls\ComboBox\ComboBox.FlatComboAdapter.cs (7)
36
_innerBorder = new
Rectangle
(_outerBorder.X + 1, _outerBorder.Y + 1, _outerBorder.Width - dropDownButtonWidth - 2, _outerBorder.Height - 2);
37
_innerInnerBorder = new
Rectangle
(_innerBorder.X + 1, _innerBorder.Y + 1, _innerBorder.Width - 2, _innerBorder.Height - 2);
38
_dropDownRect = new
Rectangle
(_innerBorder.Right + 1, _innerBorder.Y, dropDownButtonWidth, _innerBorder.Height + 1);
95
new
Rectangle
(_outerBorder.X, _outerBorder.Y, _dropDownRect.Width + 1, _outerBorder.Height));
101
new
Rectangle
(_dropDownRect.X, _outerBorder.Y, _outerBorder.Right - _dropDownRect.X, _outerBorder.Height));
143
new
Rectangle
(_outerBorder.X, _outerBorder.Y, _dropDownRect.Width + 1, _outerBorder.Height));
149
new
Rectangle
(_dropDownRect.X, _outerBorder.Y, _outerBorder.Right - _dropDownRect.X, _outerBorder.Height));
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (1)
4070
Invalidate(new
Rectangle
(_layout.Inside.X, _layout.Inside.Y, RowHeadersWidth, ColumnHeadersHeight));
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (22)
2979
r = new
Rectangle
(
2989
r = new
Rectangle
(
3004
Rectangle r =
new
(
3025
Rectangle r =
new
(
5638
Rectangle rectInsertionBar =
new
(0, _layout.ColumnHeaders.Top, InsertionBarWidth, _layout.ColumnHeaders.Height);
8308
? new
Rectangle
(cx - displayWidth, data.Y, displayWidth, data.Height)
8309
: new
Rectangle
(cx, data.Y, displayWidth, data.Height);
9094
Rectangle rowRect =
new
(data.X, cy, data.Width, displayHeight);
10021
Invalidate(new
Rectangle
(data.X, top, data.Width, bottom - top));
10307
_layout.ResizeBoxRect = new
Rectangle
(
10324
_horizScrollBar.Bounds = new
Rectangle
(
10365
_vertScrollBar.Bounds = new
Rectangle
(
17449
right = new
Rectangle
(oldClientRectangle.X + oldClientRectangle.Width - borderWidth,
17453
bottom = new
Rectangle
(oldClientRectangle.X,
17471
right = new
Rectangle
(newClientRectangle.X + newClientRectangle.Width - borderWidth,
17481
bottom = new
Rectangle
(newClientRectangle.X,
17491
right = new
Rectangle
(oldGridFocusRectangle.X + oldGridFocusRectangle.Width - 1,
17497
bottom = new
Rectangle
(oldGridFocusRectangle.X,
19293
Rectangle edge =
new
(0, 0, bounds.Width, borderWidth);
19323
g.DrawRectangle(pen, new
Rectangle
(0, 0, bounds.Width - 1, bounds.Height - 1));
19333
g.DrawRectangle(pen, new
Rectangle
(0, 0, bounds.Width - 1, bounds.Height - 1));
19832
Rectangle cellBounds =
new
(leftEdge, GetRowYFromIndex(_ptCurrentCell.Y),
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (2)
27
private static Rectangle s_rectThemeMargins =
new
(-1, -1, 0, 0);
415
Rectangle rectCell =
new
(0, 0, DATAGRIDVIEWBUTTONCELL_themeMargin, DATAGRIDVIEWBUTTONCELL_themeMargin);
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (4)
1019
Rectangle bmpRect =
new
(DataGridView!.RightToLeftInternal ?
3598
rectPadding = new
Rectangle
(bounds.X, bounds.Y, cellStyle.Padding.Right, bounds.Height);
3607
rectPadding = new
Rectangle
(bounds.X, bounds.Y, cellStyle.Padding.Left, bounds.Height);
3859
return new
Rectangle
(xEditingControl, yEditingControl, wEditingControl, hEditingControl);
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxCell.cs (7)
1237
new
Rectangle
(checkBoxX, checkBoxY, checkBoxSize.Width, checkBoxSize.Height),
1241
resultBounds = new
Rectangle
(checkBoxX, checkBoxY, checkBoxSize.Width, checkBoxSize.Height);
1271
resultBounds = new
Rectangle
(checkBoxX, checkBoxY, checkBoxSize.Width, checkBoxSize.Height);
1278
Rectangle checkBounds =
new
(checkBoxX, checkBoxY, checkBoxSize.Width, checkBoxSize.Height);
1336
Rectangle fullSize =
new
(checkBoxX - 1, checkBoxY - 1, checkBoxSize.Width + 3, checkBoxSize.Height + 3);
1350
RECT rcCheck = new
Rectangle
(0, 0, fullSize.Width, fullSize.Height);
1384
Rectangle checkBounds =
new
(checkBoxX, checkBoxY, checkBoxSize.Width - 1, checkBoxSize.Height - 1);
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnHeaderCell.cs (2)
838
DataGridViewColumnHeaderCellRenderer.DrawHeader(gFlip, new
Rectangle
(0, 0, backgroundBounds.Width, backgroundBounds.Height), state);
840
g.DrawImage(bmFlipXPThemes, backgroundBounds, new
Rectangle
(bmFlipXPThemes.Width - backgroundBounds.Width, 0, backgroundBounds.Width, backgroundBounds.Height), GraphicsUnit.Pixel);
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnHeaderCell.DataGridViewColumnHeaderCellRenderer.cs (2)
32
Rectangle cornerClip =
new
(bounds.Left, bounds.Bottom - 2, 2, 2);
35
cornerClip = new
Rectangle
(bounds.Right - 2, bounds.Bottom - 2, 2, 2);
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (4)
1983
g.DrawRectangle(SystemPens.ControlLightLight, new
Rectangle
(valBounds.X, valBounds.Y, valBounds.Width - 1, valBounds.Height - 1));
2013
dropRect = new
Rectangle
(
2021
dropRect = new
Rectangle
(
2030
dropRect = new
Rectangle
(
System\Windows\Forms\Controls\DataGridView\DataGridViewHeaderCell.cs (4)
19
private static Rectangle s_rectThemeMargins =
new
(-1, -1, 0, 0);
385
Rectangle rectCell =
new
(0, 0, ThemeMargin, ThemeMargin);
396
s_rectThemeMargins = new
Rectangle
(0, 0, 2, 3);
410
s_rectThemeMargins = new
Rectangle
(2, 1, 0, 2);
System\Windows\Forms\Controls\DataGridView\DataGridViewImageCell.cs (3)
584
imageBounds = new
Rectangle
(bounds.X, bounds.Y, imgWidth, imgHeight);
591
imageBounds = new
Rectangle
(
600
imageBounds = new
Rectangle
(
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (3)
700
DataGridViewRowHeaderCellRenderer.DrawHeader(gFlip, new
Rectangle
(0, 0, backgroundBounds.Height, backgroundBounds.Width), state);
706
new
Rectangle
(0, 0, backgroundBounds.Width, backgroundBounds.Height),
1029
Rectangle bmpRect =
new
(width, height, s_iconsWidth, s_iconsHeight);
System\Windows\Forms\Controls\GroupBox\GroupBox.cs (3)
163
return new
Rectangle
(
434
new
Rectangle
(0, 0, Width, Height),
445
new
Rectangle
(0, 0, Width, Height),
System\Windows\Forms\Controls\ImageList\ImageList.cs (1)
632
targetData = result.LockBits(new
Rectangle
(0, 0, _imageSize.Width, _imageSize.Height), ImageLockMode.WriteOnly, PixelFormat.Format32bppArgb);
System\Windows\Forms\Controls\Labels\Label.cs (2)
902
return new
Rectangle
(xLoc, yLoc, pointImageSize.Width, pointImageSize.Height);
1435
Rectangle rectInScreen = RectangleToScreen(new
Rectangle
(0, 0, Width, Height));
System\Windows\Forms\Controls\Labels\LinkLabel.cs (2)
423
return new
Rectangle
(xLoc, yLoc, width, height);
580
Rectangle visualRectangle =
new
(
System\Windows\Forms\Controls\ListBoxes\CheckedListBox.cs (4)
540
Rectangle box =
new
(
569
Rectangle textBounds =
new
(
626
Rectangle stringBounds =
new
(
719
Rectangle emptyRectangle =
new
(
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (1)
2327
Rectangle rect =
new
(0, 0, Size.Width - 1, Size.Height - 1);
System\Windows\Forms\Controls\ListView\DrawListViewItemEventArgs.cs (1)
106
resultBounds = new
Rectangle
(originalBounds.X, originalBounds.Y, textSize.Width, textSize.Height);
System\Windows\Forms\Controls\ListView\ListView.cs (1)
6899
Rectangle rect =
new
(0, 0, Size.Width - 1, Size.Height - 1);
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemBaseAccessibleObject.cs (1)
42
: new
Rectangle
(
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemListAccessibleObject.cs (1)
20
: new
Rectangle
(
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObject.cs (1)
63
return new
Rectangle
(
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (2)
2620
Rectangle toolStripBounds =
new
(0, 1, toolStripWidth, toolStripHeight);
2898
pevent.Graphics.FillRectangle(backgroundBrush, new
Rectangle
(0, 0, width, psheetLoc.Y));
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CategoryGridEntry.cs (1)
121
Rectangle focusRect =
new
(indent, rect.Y, labelWidth + 3, rect.Height - 1);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CommandsPane.cs (1)
62
return new
Rectangle
(4, 4, size.Width - 8, size.Height - 8);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\DropDownButton.cs (1)
84
Rectangle dropDownButtonRect =
new
(0, 0, Width, Height);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.cs (6)
660
_outlineRect = new
Rectangle
(
1577
Rectangle textRect =
new
(stringX, rect.Y + 1, maxSpace, rect.Height - 1);
1719
compatibleDC.HDC.FillRectangle(new
Rectangle
(0, 0, rectangle.Width, rectangle.Height), brush);
1720
explorerTreeRenderer.DrawBackground(compatibleDC, new
Rectangle
(0, 0, rectangle.Width, rectangle.Height), hwnd);
1845
Rectangle rectPaint =
new
(
1905
Rectangle textRectangle =
new
(
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\HelpPane.cs (1)
122
Invalidate(new
Rectangle
(
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyDescriptorGridEntry.cs (1)
536
_uiItemRects[i] = new
Rectangle
(
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (9)
619
return new
Rectangle
(pt.X, pt.Y, rect.Width, rect.Height);
1881
Rectangle rect =
new
(0, 0, 0, 0);
2121
Invalidate(new
Rectangle
(left, 0, Size.Width - left, Size.Height));
2213
ControlPaint.DrawFocusRectangle(g, new
Rectangle
(_offset2Units, _offset2Units, Size.Width - doubleOffset, Size.Height - doubleOffset));
2359
Rectangle clearRect =
new
(1, 1, Size.Width - 2, Size.Height - 2);
3350
Rectangle clearRect =
new
(1, yPosition, Size.Width - 2, Size.Height - yPosition - 1);
3583
Rectangle rectInvalidate =
new
(_lastClientRect.Width - 1, 0, newRect.Width - _lastClientRect.Width + 1, _lastClientRect.Height);
3589
Rectangle rectInvalidate =
new
(0, _lastClientRect.Height - 1, _lastClientRect.Width, newRect.Height - _lastClientRect.Height + 1);
4325
Rectangle rectTarget =
new
(
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.DropDownHolder.cs (3)
364
Rectangle bottomGrip =
new
(0, Height - s_resizeGripSize, s_resizeGripSize, s_resizeGripSize);
365
Rectangle topGrip =
new
(0, 0, s_resizeGripSize, s_resizeGripSize);
510
Rectangle lRect =
new
(0, _resizeUp ? 0 : Height - s_resizeGripSize, s_resizeGripSize, s_resizeGripSize);
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
616
Rectangle rectWithBorder =
new
(
System\Windows\Forms\Controls\TextBox\MaskedTextBox.cs (1)
2899
Rectangle rect =
new
(0, 0, Size.Width - 1, Size.Height - 1);
System\Windows\Forms\Controls\TextBox\TextBox.cs (1)
826
Rectangle rect =
new
(0, 0, Size.Width - 1, Size.Height - 1);
System\Windows\Forms\Controls\ToolStrips\StatusStrip.cs (2)
216
return new
Rectangle
(0, statusStripSize.Height - gripHeight, GripWidth, gripHeight);
220
return new
Rectangle
(statusStripSize.Width - GripWidth, statusStripSize.Height - gripHeight, GripWidth, gripHeight);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDown.cs (1)
1525
Rectangle bounds =
new
(x, y, width, height);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.ToolStripDropDownButtonInternalLayout.cs (3)
66
_dropDownArrowRect = new
Rectangle
(_dropDownArrowPadding.Left, 0, s_dropDownArrowSize.Width, _ownerItem.Bounds.Height);
71
_dropDownArrowRect = new
Rectangle
(options.Client.Right, 0, s_dropDownArrowSize.Width, _ownerItem.Bounds.Height);
82
_dropDownArrowRect = new
Rectangle
(0, options.Client.Bottom + _dropDownArrowPadding.Top, _ownerItem.Bounds.Width - 1, s_dropDownArrowSize.Height);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownMenu.cs (5)
364
_checkRectangle = LayoutUtils.Align(maxCheckSize, new
Rectangle
(nextPoint.X, nextPoint.Y, maxCheckSize.Width, _maxItemSize.Height), ContentAlignment.MiddleCenter);
369
_imageRectangle = LayoutUtils.Align(maxImageSize, new
Rectangle
(nextPoint.X, nextPoint.Y, maxImageSize.Width, _maxItemSize.Height), ContentAlignment.MiddleCenter);
380
_checkRectangle = LayoutUtils.Align(maxCheckSize, new
Rectangle
(nextPoint.X, nextPoint.Y, checkAndImageMarginWidth, _maxItemSize.Height), ContentAlignment.MiddleCenter);
399
_checkRectangle = LayoutUtils.Align(LayoutUtils.UnionSizes(maxCheckSize, maxImageSize), new
Rectangle
(nextPoint.X, nextPoint.Y, checkAndImageMarginWidth - 1, _maxItemSize.Height), ContentAlignment.MiddleCenter);
416
_imageMarginBounds = new
Rectangle
(0, 0, checkAndImageMarginWidth, Height);
System\Windows\Forms\Controls\ToolStrips\ToolStripHighContrastRenderer.cs (7)
74
new
Rectangle
(startX, startY, 2, 2) :
75
new
Rectangle
(startY, startX, 2, 2);
100
e.Graphics.DrawRectangle(SystemPens.ButtonHighlight, new
Rectangle
(0, 0, e.Item.Width - 1, e.Item.Height - 1));
314
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(1, 1, 1, 1));
319
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(bounds.Width - 2, 1, 1, 1));
326
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(1, bounds.Height - 2, 1, 1));
333
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(bounds.Width - 2, bounds.Height - 2, 1, 1));
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
3255
=> SetBounds(new
Rectangle
(x, y, width, height));
System\Windows\Forms\Controls\ToolStrips\ToolStripProfessionalLowResolutionRenderer.cs (4)
79
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(1, 1, 1, 1));
84
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(bounds.Width - 2, 1, 1, 1));
91
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(1, bounds.Height - 2, 1, 1));
98
g.FillRectangle(SystemBrushes.ButtonShadow, new
Rectangle
(bounds.Width - 2, bounds.Height - 2, 1, 1));
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (18)
168
overflowArrowRect = new
Rectangle
(0, item.Height - _overflowArrowOffsetY, _overflowArrowWidth, _overflowArrowHeight);
172
overflowArrowRect = new
Rectangle
(item.Width - _overflowButtonWidth, item.Height - _overflowArrowOffsetY, _overflowArrowWidth, _overflowArrowHeight);
322
ControlPaint.DrawBorder3D(e.Graphics, new
Rectangle
(0, 0, item.Width, item.Height), item.BorderStyle, (Border3DSide)item.BorderSides);
457
edging = new
Rectangle
(bounds.Width - 1, 3, 1, bounds.Height - 3);
461
edging = new
Rectangle
(3, bounds.Height - 1, bounds.Width - 3, bounds.Height - 1);
505
new
Rectangle
(startX, startY, 2, 2) :
506
new
Rectangle
(startY, startX, 2, 2);
862
Rectangle bottomLeftParentVerticalPixels =
new
(bottomLeft.X, bottomLeft.Y - 1, 1, 2);
865
Rectangle bottomRightHorizontalPixels =
new
(bottomRight.X - 1, bottomRight.Y, 2, 1);
866
Rectangle bottomRightVerticalPixels =
new
(bottomRight.X, bottomRight.Y - 1, 1, 2);
873
topRightHorizontalPixels = new
Rectangle
(topRight.X - 1, topRight.Y, 1, 1);
874
topRightVerticalPixels = new
Rectangle
(topRight.X, topRight.Y, 1, 2);
878
topRightHorizontalPixels = new
Rectangle
(topRight.X - 2, topRight.Y, 2, 1);
879
topRightVerticalPixels = new
Rectangle
(topRight.X, topRight.Y, 1, 3);
1046
? new
Rectangle
(
1050
: new
Rectangle
(e.ImageRectangle.Left - 2, 1, e.ImageRectangle.Width + 4, e.Item.Height - 2);
1321
Rectangle fillRect =
new
(overflowBoundsFill.X - 1, 0, 1, 1);
1396
Rectangle otherBottom =
new
(bottomLeft.X, bottomLeft.Y - 2, 1, 1);
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderer.cs (1)
1040
new
Rectangle
(0, 0, size.Width, size.Height),
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderEventArgs.cs (1)
125
return new
Rectangle
(itemBounds.X + 1, 0, itemBounds.Width - 2, 2);
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.cs (2)
316
_splitterBounds = new
Rectangle
(splitButtonButtonBounds.Right, splitButtonButtonBounds.Top, _splitterWidth, splitButtonButtonBounds.Height);
322
_splitterBounds = new
Rectangle
(dropDownButtonBounds.Right, dropDownButtonBounds.Top, _splitterWidth, dropDownButtonBounds.Height);
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitStackDragDropHandler.cs (4)
143
insertionRect = new
Rectangle
(_owner.Margin.Left, item.Bounds.Top, _owner.Width - (_owner.Margin.Horizontal) - 1, ToolStrip.s_insertionBeamWidth);
146
insertionRect = new
Rectangle
(_owner.Margin.Left, item.Bounds.Bottom, _owner.Width - (_owner.Margin.Horizontal) - 1, ToolStrip.s_insertionBeamWidth);
149
insertionRect = new
Rectangle
(item.Bounds.Right, _owner.Margin.Top, ToolStrip.s_insertionBeamWidth, _owner.Height - (_owner.Margin.Vertical) - 1);
152
insertionRect = new
Rectangle
(item.Bounds.Left, _owner.Margin.Top, ToolStrip.s_insertionBeamWidth, _owner.Height - (_owner.Margin.Vertical) - 1);
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitStackLayout.cs (8)
301
alignedRightItems = (alignedRightItems == Rectangle.Empty) ? new
Rectangle
(x, y, itemSize.Width, itemSize.Height)
302
: Rectangle.Union(alignedRightItems, new
Rectangle
(x, y, itemSize.Width, itemSize.Height));
314
alignedLeftItems = (alignedLeftItems == Rectangle.Empty) ? new
Rectangle
(x, y, itemSize.Width, itemSize.Height)
315
: Rectangle.Union(alignedLeftItems, new
Rectangle
(x, y, itemSize.Width, itemSize.Height));
438
alignedRightItems = (alignedRightItems == Rectangle.Empty) ? new
Rectangle
(x, y, itemSize.Width, itemSize.Height)
439
: Rectangle.Union(alignedRightItems, new
Rectangle
(x, y, itemSize.Width, itemSize.Height));
446
alignedLeftItems = (alignedLeftItems == Rectangle.Empty) ? new
Rectangle
(x, y, itemSize.Width, itemSize.Height)
447
: Rectangle.Union(alignedLeftItems, new
Rectangle
(x, y, itemSize.Width, itemSize.Height));
System\Windows\Forms\Controls\ToolStrips\ToolStripSystemRenderer.cs (2)
499
ControlPaint.DrawBorder3D(e.Graphics, new
Rectangle
(0, 0, item.Width - 1, item.Height - 1), item.BorderStyle, (Border3DSide)item.BorderSides);
776
vsRenderer.DrawBackground(e.Graphics, new
Rectangle
(0, 0, e.ToolStrip.Width - 1, e.ToolStrip.Height - 1));
System\Windows\Forms\Controls\TrackBar\TrackBarRenderer.cs (4)
120
t_visualStyleRenderer.DrawEdge(g, new
Rectangle
(bounds.X, bounds.Y, LineWidth, bounds.Height), Edges.Left, edgeStyle, EdgeEffects.None);
130
t_visualStyleRenderer.DrawEdge(g, new
Rectangle
((int)Math.Round(x), bounds.Y, LineWidth, bounds.Height), Edges.Left, edgeStyle, EdgeEffects.None);
150
t_visualStyleRenderer.DrawEdge(g, new
Rectangle
(bounds.X, bounds.Y, bounds.Width, LineWidth), Edges.Top, edgeStyle, EdgeEffects.None);
160
t_visualStyleRenderer.DrawEdge(g, new
Rectangle
(bounds.X, (int)Math.Round(y), bounds.Width, LineWidth), Edges.Top, edgeStyle, EdgeEffects.None);
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
3151
Rectangle rect =
new
(0, 0, Size.Width - 1, Size.Height - 1);
System\Windows\Forms\Controls\UpDown\UpDownBase.cs (5)
531
Rectangle clipLeft =
new
(bounds.Left, bounds.Top, border, bounds.Height);
532
Rectangle clipTop =
new
(bounds.Left, bounds.Top, bounds.Width, border);
533
Rectangle clipRight =
new
(bounds.Right - border, bounds.Top, border, bounds.Height);
534
Rectangle clipBottom =
new
(bounds.Left, bounds.Bottom - border, bounds.Width, border);
862
upDownButtonsBounds = new
Rectangle
(
System\Windows\Forms\Controls\UpDown\UpDownBase.UpDownButtons.cs (4)
280
new
Rectangle
(0, 0, _parent._defaultButtonsWidth, half_height),
300
new
Rectangle
(0, half_height, _parent._defaultButtonsWidth, half_height),
307
new
Rectangle
(0, 0, _parent._defaultButtonsWidth, half_height),
313
new
Rectangle
(0, half_height, _parent._defaultButtonsWidth, half_height),
System\Windows\Forms\Controls\WebBrowser\HtmlElement.cs (3)
105
return
new
(clientLeft, clientTop, clientWidth, clientHeight);
310
return
new
(offsetLeft, offsetTop, offsetWidth, offsetHeight);
409
return
new
(scrollLeft, scrollTop, scrollWidth, scrollHeight);
System\Windows\Forms\Controls\WebBrowser\WebBrowserBase.cs (2)
201
RECT posRect = new
Rectangle
(0, 0, width, height);
791
Bounds = new
Rectangle
(location.X, location.Y, extent.Width, extent.Height);
System\Windows\Forms\Controls\WebBrowser\WebBrowserHelper.cs (1)
109
internal static RECT GetClipRect() => new
Rectangle
(0, 0, 32000, 32000);
System\Windows\Forms\Design\ComponentEditorForm.cs (4)
235
Rectangle pageHostBounds =
new
(2 * BUTTON_PAD + selectorWidth, 2 * BUTTON_PAD + STRIP_HEIGHT,
238
grayStrip.Bounds = new
Rectangle
(pageHostBounds.X, BUTTON_PAD,
243
Rectangle pageBounds =
new
(0, 0, pageHostBounds.Width, pageHostBounds.Height);
258
_selector.Bounds = new
Rectangle
(BUTTON_PAD, BUTTON_PAD,
System\Windows\Forms\ErrorProvider\ErrorProvider.ControlItem.cs (1)
241
return new
Rectangle
(x, y, size.Width, size.Height);
System\Windows\Forms\ErrorProvider\ErrorProvider.ErrorWindow.cs (1)
316
using Region windowRegion = new(new
Rectangle
(0, 0, 0, 0));
System\Windows\Forms\ErrorProvider\ErrorProvider.IconRegion.cs (3)
40
_region = new Region(new
Rectangle
(0, 0, 0, 0));
66
_region.Union(new
Rectangle
(x, y, 1, 1));
72
_region.Intersect(new
Rectangle
(0, 0, size.Width, size.Height));
System\Windows\Forms\Form.cs (5)
151
private Rectangle _restoredWindowBounds =
new
(-1, -1, -1, -1);
158
private Rectangle _restoreBounds =
new
(-1, -1, -1, -1);
4212
form.SetBounds(new
Rectangle
(Left, Top, adjustedSize.Width, adjustedSize.Height), BoundsSpecified.None);
4411
new
Rectangle
(size.Width - SizeGripSize, size.Height - SizeGripSize, SizeGripSize, SizeGripSize));
5015
_restoredWindowBounds = new
Rectangle
(-1, -1, -1, -1);
System\Windows\Forms\Layout\CommonProperties.cs (1)
336
Rectangle bounds =
new
(x, y, width, height);
System\Windows\Forms\Layout\Containers\ContainerControl.cs (1)
698
return new
Rectangle
(topLeftPoint.X, topLeftPoint.Y, clientRectangle.right, clientRectangle.bottom);
System\Windows\Forms\Layout\Containers\SplitContainer.cs (1)
2285
return new
Rectangle
(containerRectangle.X + splitterRectangle.X, containerRectangle.Y + splitterRectangle.Y, splitterRectangle.Width, splitterRectangle.Height);
System\Windows\Forms\Layout\DefaultLayout.cs (7)
234
return new
Rectangle
(anchorInfo.Left, anchorInfo.Top, width, height);
336
return new
Rectangle
(left, top, right - left, bottom - top);
401
Rectangle newElementBounds =
new
(remainingBounds.X, remainingBounds.Y, elementSize.Width, elementSize.Height);
414
Rectangle newElementBounds =
new
(remainingBounds.X, remainingBounds.Bottom - elementSize.Height, elementSize.Width, elementSize.Height);
427
Rectangle newElementBounds =
new
(remainingBounds.X, remainingBounds.Y, elementSize.Width, elementSize.Height);
440
Rectangle newElementBounds =
new
(remainingBounds.Right - elementSize.Width, remainingBounds.Y, elementSize.Width, elementSize.Height);
458
Rectangle newElementBounds =
new
(remainingBounds.X, remainingBounds.Y, elementSize.Width, elementSize.Height);
System\Windows\Forms\Layout\FlowLayout.cs (2)
76
Rectangle measureBounds =
new
(displayRect.X, displayRect.Y, displayRect.Width, displayRect.Height - layoutSize.Height);
86
Rectangle rowBounds =
new
(displayRect.X,
System\Windows\Forms\Layout\LayoutUtils.cs (1)
16
public static readonly Rectangle s_maxRectangle =
new
(0, 0, int.MaxValue, int.MaxValue);
System\Windows\Forms\Layout\TableLayout.cs (3)
1250
Rectangle cellBounds =
new
((int)(startX + cellBorderWidth / 2.0f), (int)(top + cellBorderWidth / 2.0f), width - cellBorderWidth, height - cellBorderWidth);
1475
Rectangle cellsOccupied1 =
new
(layoutInfo1.ColumnStart, layoutInfo1.RowStart, layoutInfo1.ColumnSpan, layoutInfo1.RowSpan);
1480
Rectangle cellsOccupied2 =
new
(layoutInfo2.ColumnStart, layoutInfo2.RowStart, layoutInfo2.ColumnSpan, layoutInfo2.RowSpan);
System\Windows\Forms\Panels\TableLayoutPanel\TableLayoutPanel.cs (3)
380
Rectangle outsideCellBounds =
new
(
386
Rectangle insideCellBounds =
new
(
432
Rectangle tableBounds =
new
(
System\Windows\Forms\Printing\PrintPreviewControl.cs (3)
462
private Rectangle FocusRectangle =>
new
(0, 0, Width - 1, Height - 1);
464
private Rectangle ResizeBoxRectangle =>
new
(_vScrollBar.Left, _hScrollBar.Top, _vScrollBar.Width, _hScrollBar.Height);
672
pageRenderArea[imageIndex - StartPage] = new
Rectangle
(x, y, imagePixels.Width, imagePixels.Height);
System\Windows\Forms\Printing\PrintPreviewDialog.cs (1)
1143
Rectangle rect =
new
(0, 0, item.Bounds.Width - 1, item.Bounds.Height - 1);
System\Windows\Forms\Rendering\ControlPaint.cs (11)
268
new
Rectangle
(0, 0, width, height),
1030
RECT rc = new
Rectangle
(x, y, width, height);
1151
bounds = new
Rectangle
(bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
1238
DrawFlatCheckBox(graphics, new
Rectangle
(x, y, width, height), state);
1348
Rectangle offsetRectangle =
new
(
1469
new
Rectangle
(x, y, width, height),
1495
Rectangle fillRect =
new
(
1594
=> DrawImageDisabled(graphics, image, new
Rectangle
(x, y, image.Width, image.Height), unscaledImage: false);
1641
new
Rectangle
(0, 0, imageSize.Width, imageSize.Height),
2378
bound = new
Rectangle
(bound.X + 1, bound.Y + 1, bound.Width - 1, bound.Height - 1);
2398
bound = new
Rectangle
(bound.X + 1, bound.Y + 1, bound.Width - 1, bound.Height - 1);
System\Windows\Forms\Scrolling\ScrollableControl.cs (2)
560
_displayRect = new
Rectangle
(_displayRect.X, _displayRect.Y, HorizontalScroll.Maximum, _displayRect.Height);
565
_displayRect = new
Rectangle
(_displayRect.X, _displayRect.Y, _displayRect.Width, VerticalScroll.Maximum);
System\Windows\Forms\SystemInformation.cs (1)
462
return new
Rectangle
(0, 0, size.Width, size.Height);
System\Windows\Forms\ToolTip\ToolTip.cs (4)
1555
new
Rectangle
(centeredX, toolRectangle.Top - height, width, height),
1556
new
Rectangle
(toolRectangle.Right, centeredY, width, height),
1557
new
Rectangle
(centeredX, toolRectangle.Bottom, width, height),
1558
new
Rectangle
(toolRectangle.Left - width, centeredY, width, height),
System.Windows.Forms.Design (95)
System\ComponentModel\Design\ByteViewer.cs (2)
144
new
Rectangle
(
154
new
Rectangle
(
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (1)
598
Rectangle baseVar =
new
(e.Bounds.X + offset, e.Bounds.Y + 1, PaintWidth, e.Bounds.Height - 3);
System\ComponentModel\Design\CollectionEditor.SplitButton.cs (2)
196
Rectangle bounds =
new
(0, 0, Width, Height);
201
_dropDownRectangle = new
Rectangle
(bounds.Right - PushButtonWidth - 1, 4, PushButtonWidth, bounds.Height - 8);
System\ComponentModel\Design\DesignerActionPanel.cs (2)
488
e.Graphics.DrawRectangle(borderPen, new
Rectangle
(0, 0, Width - 1, Height - 1));
508
g.SetClip(new
Rectangle
(0, yPos, lineWidth, lineHeight));
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.cs (2)
294
Rectangle rect =
new
(1, 1, width - 2, height - 2);
297
swatchGraphics.DrawRectangle(SystemPens.ControlDark, new
Rectangle
(0, 0, width - 1, height - 1));
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.EditorButton.cs (5)
70
ButtonRenderer.DrawButton(g, new
Rectangle
(-1, -1, Width + 2, Height + 2), "…", Font, Focused, buttonState);
93
ComboBoxRenderer.DrawDropDownButton(g, new
Rectangle
(0, 0, Width, Height), state);
116
new
Rectangle
(-1, -1, Width + 2, Height + 2),
137
new
Rectangle
(
155
ControlPaint.DrawFocusRectangle(g, new
Rectangle
(2, 2, Width - 5, Height - 5));
System\Drawing\Design\ColorEditor.ColorPalette.ColorPaletteAccessibleObject.ColorCellAccessibleObject.cs (1)
43
return new
Rectangle
(pt.X, pt.Y, rect.Width, rect.Height);
System\Drawing\Design\ColorEditor.ColorUI.cs (2)
275
_editor.PaintValue(value, graphics, new
Rectangle
(die.Bounds.X + 2, die.Bounds.Y + 2, 22, die.Bounds.Height - 4));
276
graphics.DrawRectangle(SystemPens.WindowText, new
Rectangle
(die.Bounds.X + 2, die.Bounds.Y + 2, 22 - 1, die.Bounds.Height - 4 - 1));
System\Drawing\Design\CursorEditor.CursorUI.cs (3)
69
e.Graphics.FillRectangle(SystemBrushes.Control, new
Rectangle
(e.Bounds.X + 2, e.Bounds.Y + 2, 32, e.Bounds.Height - 4));
70
e.Graphics.DrawRectangle(SystemPens.WindowText, new
Rectangle
(e.Bounds.X + 2, e.Bounds.Y + 2, 32 - 1, e.Bounds.Height - 4 - 1));
72
cursor.DrawStretched(e.Graphics, new
Rectangle
(e.Bounds.X + 2, e.Bounds.Y + 2, 32, e.Bounds.Height - 4));
System\Windows\Forms\Design\Behavior\ContainerSelectorGlyph.cs (1)
26
_glyphBounds = new
Rectangle
(containerBounds.X + glyphOffset, containerBounds.Y - (int)(glyphSize * .5), glyphSize, glyphSize);
System\Windows\Forms\Design\Behavior\DesignerActionGlyph.cs (1)
161
_bounds = (new
Rectangle
(topRight.X, topRight.Y, GlyphImageOpened.Width, GlyphImageOpened.Height));
System\Windows\Forms\Design\Behavior\DragAssistanceManager.cs (4)
372
invalidRect = new
Rectangle
(diffs[k].X1, diffs[k].Y1, diffs[k].X2 - diffs[k].X1, diffs[k].Y2 - diffs[k].Y1);
393
invalidRect = new
Rectangle
(line.X1, line.Y1, line.X2 - line.X1, line.Y2 - line.Y1);
535
Rectangle clipBounds =
new
(0, 0, rootControl.ClientRectangle.Width, rootControl.ClientRectangle.Height);
1144
Rectangle tempDragRect =
new
(dragBounds.Left + snapPoint.X, dragBounds.Top + snapPoint.Y, dragBounds.Width, dragBounds.Height);
System\Windows\Forms\Design\Behavior\DropSourceBehavior.cs (4)
744
Rectangle newRect =
new
(newPosition.X, newPosition.Y,
765
_dragAssistanceManager.OnMouseMove(new
Rectangle
(-100, -100, 0, 0)); /*just an invalid rect - so we won't snap*/// );
1033
Rectangle controlRect =
new
(_dragComponents[i].draggedLocation.X - _dragImageRect.X,
1040
new
Rectangle
(0, 0, _dragComponents[i].dragImage.Width, _dragComponents[i].dragImage.Height),
System\Windows\Forms\Design\Behavior\GrabHandleGlyph.cs (8)
33
bounds = new
Rectangle
(controlBounds.X + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, controlBounds.Y + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
38
bounds = new
Rectangle
(controlBounds.Right - DesignerUtils.s_handleOverlap, controlBounds.Y + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
43
bounds = new
Rectangle
(controlBounds.Right - DesignerUtils.s_handleOverlap, controlBounds.Bottom - DesignerUtils.s_handleOverlap, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
48
bounds = new
Rectangle
(controlBounds.X + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, controlBounds.Bottom - DesignerUtils.s_handleOverlap, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
58
bounds = new
Rectangle
(controlBounds.X + (controlBounds.Width / 2) - (DesignerUtils.s_handleSize / 2), controlBounds.Y + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
70
bounds = new
Rectangle
(controlBounds.X + (controlBounds.Width / 2) - (DesignerUtils.s_handleSize / 2), controlBounds.Bottom - DesignerUtils.s_handleOverlap, DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
82
bounds = new
Rectangle
(controlBounds.X + DesignerUtils.s_handleOverlap - DesignerUtils.s_handleSize, controlBounds.Y + (controlBounds.Height / 2) - (DesignerUtils.s_handleSize / 2), DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
94
bounds = new
Rectangle
(controlBounds.Right - DesignerUtils.s_handleOverlap, controlBounds.Y + (controlBounds.Height / 2) - (DesignerUtils.s_handleSize / 2), DesignerUtils.s_handleSize, DesignerUtils.s_handleSize);
System\Windows\Forms\Design\Behavior\LockedHandleGlyph.cs (1)
26
bounds = new
Rectangle
((controlBounds.X + DesignerUtils.s_lockHandleOverlap) - DesignerUtils.s_lockHandleWidth,
System\Windows\Forms\Design\Behavior\NoResizeHandleGlyph.cs (1)
34
bounds = new
Rectangle
(
System\Windows\Forms\Design\Behavior\ResizeBehavior.cs (2)
603
_dragManager.OnMouseMove(new
Rectangle
(-100, -100, 0, 0));
618
Rectangle controlBounds =
new
(_resizeComponents[0].resizeBounds.X, _resizeComponents[0].resizeBounds.Y,
System\Windows\Forms\Design\Behavior\ToolboxItemSnapLineBehavior.cs (2)
316
Rectangle newRectangle =
new
(mouseLoc.X - DesignerUtils.s_boxImageSize / 2, mouseLoc.Y - DesignerUtils.s_boxImageSize / 2,
351
Rectangle statusRect =
new
(newRectangle.X - adornerServiceOrigin.X, newRectangle.Y - adornerServiceOrigin.Y, 0, 0);
System\Windows\Forms\Design\Behavior\ToolStripPanelSelectionGlyph.cs (8)
111
_glyphBounds = new
Rectangle
(bounds.X + x, bounds.Y + bounds.Height, _imageWidth, _imageHeight);
120
_glyphBounds = new
Rectangle
(bounds.X + x, bounds.Y - _imageHeight, _imageWidth, _imageHeight);
129
_glyphBounds = new
Rectangle
(bounds.X + bounds.Width, bounds.Y + y, _imageHeight, _imageWidth);
138
_glyphBounds = new
Rectangle
(bounds.X - _imageHeight, bounds.Y + y, _imageHeight, _imageWidth);
160
_glyphBounds = new
Rectangle
(bounds.X + x, bounds.Y + bounds.Height, _imageWidth, _imageHeight);
169
_glyphBounds = new
Rectangle
(bounds.X + x, bounds.Y - _imageHeight, _imageWidth, _imageHeight);
178
_glyphBounds = new
Rectangle
(bounds.X + bounds.Width, bounds.Y + y, _imageHeight, _imageWidth);
187
_glyphBounds = new
Rectangle
(bounds.X - _imageHeight, bounds.Y + y, _imageHeight, _imageWidth);
System\Windows\Forms\Design\ComponentTray.cs (2)
2290
e.Graphics.DrawImage(_toolboxBitmap, new
Rectangle
(x, y, _cxIcon, _cyIcon));
2302
e.Graphics.DrawImage(_toolboxBitmap, new
Rectangle
(rc.X, y, _cxIcon, _cyIcon));
System\Windows\Forms\Design\ControlCommandSet.cs (1)
717
Rectangle dragRect =
new
(primaryControl.Location.X, primaryControl.Location.Y,
System\Windows\Forms\Design\ControlDesigner.cs (1)
2251
Rectangle imageRect =
new
(marginX, marginY, glyphSize.Width, glyphSize.Height);
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (4)
905
Rectangle bounds =
new
(0, selectedIndex * _selectedColumns.ItemHeight, _selectedColumns.Width, _selectedColumns.ItemHeight);
1006
Rectangle focusRectangle =
new
(bounds.X, e.Bounds.Y + 1, textWidth + OWNERDRAWHORIZONTALBUFFER, e.Bounds.Height - 2);
1021
e.Graphics.FillRectangle(backBrush, new
Rectangle
(focusRectangle.Right + 1, e.Bounds.Y, e.Bounds.Width - focusRectangle.Right - 1, e.Bounds.Height));
1025
e.Graphics.FillRectangle(backBrush, new
Rectangle
(bounds.X, e.Bounds.Y, e.Bounds.Width - bounds.X, e.Bounds.Height));
System\Windows\Forms\Design\DesignerUtils.cs (5)
462
SelectionBorderGlyphType.Top => new
Rectangle
(originalBounds.Left - borderSize, originalBounds.Top - borderSize, originalBounds.Width + 2 * borderSize, borderSize),
463
SelectionBorderGlyphType.Bottom => new
Rectangle
(originalBounds.Left - borderSize, originalBounds.Bottom, originalBounds.Width + 2 * borderSize, borderSize),
464
SelectionBorderGlyphType.Left => new
Rectangle
(originalBounds.Left - borderSize, originalBounds.Top - borderSize, borderSize, originalBounds.Height + 2 * borderSize),
465
SelectionBorderGlyphType.Right => new
Rectangle
(originalBounds.Right, originalBounds.Top - borderSize, borderSize, originalBounds.Height + 2 * borderSize),
671
BitmapData data = b.LockBits(new
Rectangle
(0, 0, b.Width, b.Height), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb);
System\Windows\Forms\Design\FlowLayoutPanelDesigner .cs (2)
152
return new
Rectangle
(
458
Rectangle invalidRect =
new
(
System\Windows\Forms\Design\InheritanceUI.cs (1)
37
s_inheritanceGlyphRect = new
Rectangle
(0, 0, size.Width, size.Height);
System\Windows\Forms\Design\OleDragDropHandler.cs (1)
845
Rectangle offset =
new
(de.X - _dragBase.X, de.Y - _dragBase.Y, 0, 0);
System\Windows\Forms\Design\ParentControlDesigner.cs (7)
1120
Rectangle r = GetUpdatedRect(Rectangle.Empty, new
Rectangle
(pt.X, pt.Y, 0, 0), false);
1783
Rectangle frameRect =
new
(offset.X - _adornerWindowToScreenOffset.X,
1825
_statusCommandUI?.SetStatusInformation(new
Rectangle
(location.X, location.Y, offset.Width, offset.Height));
1938
Rectangle r =
new
(_mouseDragBase.X - _adornerWindowToScreenOffset.X,
1975
Rectangle frameRect =
new
(_mouseDragOffset.X - _adornerWindowToScreenOffset.X,
2016
_statusCommandUI?.SetStatusInformation(new
Rectangle
(offset.X, offset.Y, _mouseDragOffset.Width, _mouseDragOffset.Height));
2032
Rectangle paintRect =
new
(Math.Min(displayRect.X, clientRect.X),
System\Windows\Forms\Design\SelectionUIHandler.cs (1)
346
Rectangle tempNewBounds = GetUpdatedRect(oldBounds, new
Rectangle
(targetX, targetY, targetWidth, targetHeight), true);
System\Windows\Forms\Design\SelectionUIService.ContainerSelectionUIItem.cs (3)
36
Rectangle rect =
new
(_outerRect.X, _outerRect.Y, CONTAINER_WIDTH, CONTAINER_HEIGHT);
59
Rectangle glyphBounds =
new
(_outerRect.X, _outerRect.Y, CONTAINER_WIDTH, CONTAINER_HEIGHT);
72
Rectangle rect =
new
(_outerRect.X, _outerRect.Y, CONTAINER_WIDTH, CONTAINER_HEIGHT);
System\Windows\Forms\Design\SelectionUIService.cs (1)
830
Region region = new(new
Rectangle
(0, 0, 0, 0));
System\Windows\Forms\Design\SelectionUIService.SelectionUIItem.cs (2)
134
Rectangle rect =
new
(_outerRect.X, _outerRect.Y, GRABHANDLE_WIDTH, GRABHANDLE_HEIGHT);
514
Rectangle rcOuterNew =
new
(_innerRect.X - GRABHANDLE_WIDTH, _innerRect.Y - GRABHANDLE_HEIGHT, _innerRect.Width + 2 * GRABHANDLE_WIDTH, _innerRect.Height + 2 * GRABHANDLE_HEIGHT);
System\Windows\Forms\Design\TableLayoutPanelDesigner.cs (2)
1109
Rectangle gBounds =
new
(startLoc - halfSize, checkBounds.Top, DesignerUtils.s_resizeGlyphSize, checkBounds.Height);
1136
Rectangle gBounds =
new
(checkBounds.Left, startLoc - halfSize, checkBounds.Width, DesignerUtils.s_resizeGlyphSize);
System\Windows\Forms\Design\TabOrder.cs (1)
197
_region = new Region(new
Rectangle
(0, 0, 0, 0));
System\Windows\Forms\Design\ToolStripTemplateNode.cs (9)
1873
Rectangle drawRect =
new
(bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
1887
Rectangle drawRect =
new
(bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
1898
_hotRegion = new
Rectangle
(bounds.Left + 2, bounds.Top + 2, s_templateHotRegionWidth, bounds.Bottom - 4);
1902
_hotRegion = new
Rectangle
(bounds.Right - s_templateHotRegionWidth - 2, bounds.Top + 2, s_templateHotRegionWidth, bounds.Bottom - 4);
1919
_hotRegion = new
Rectangle
(bounds.Left + 2, bounds.Top + 2, s_templateHotRegionWidth, bounds.Bottom - 4);
1923
_hotRegion = new
Rectangle
(bounds.Right - s_templateHotRegionWidth - 2, bounds.Top + 2, s_templateHotRegionWidth, bounds.Bottom - 4);
1988
Rectangle fillRect =
new
(buttonBounds.Left + 1, buttonBounds.Top, buttonBounds.Right, buttonBounds.Bottom);
2007
Rectangle fillRect =
new
(buttonBounds.Left + 1, buttonBounds.Top, buttonBounds.Right, buttonBounds.Bottom);
2032
Rectangle drawRect =
new
(bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
System.Windows.Forms.Design.Tests (6)
System\ComponentModel\Design\ByteViewerTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, control.Width, control.Height), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, control.Width, control.Height), control.ClientRectangle);
65
Assert.Equal(new
Rectangle
(0, 0, control.Width, control.Height), control.DisplayRectangle);
System\Drawing\Design\ImageEditorTests.cs (2)
170
PaintValueEventArgs e = new(null, otherImage, graphics, new
Rectangle
(1, 2, 3, 4));
187
PaintValueEventArgs e = new(null, value, graphics, new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\Design\ImageIndexEditorTests.cs (1)
37
PaintValueEventArgs paintValueEventArgs = new(_context, value, graphics, new
Rectangle
(0, 0, 10, 10));
System.Windows.Forms.Primitives (2)
System\Windows\Forms\Automation\UiaTextRange.cs (2)
398
Rectangle rectangle =
new
(startPoint.X, startPoint.Y + 2, endPoint.X - startPoint.X, clippingRectangle.Height);
864
Rectangle rect =
new
(startPoint.X, startPoint.Y + 2, endPoint.X - startPoint.X, lineHeight);
System.Windows.Forms.Primitives.Tests (15)
System\Windows\Forms\Automation\UiaTextRangeTests.cs (6)
545
Rectangle expected =
new
(10, 33, 96, 19);
657
providerMock.Setup(m => m.BoundingRectangle).Returns(new
Rectangle
(1, 1, 94, 15));
707
providerMock.Setup(m => m.BoundingRectangle).Returns(new
Rectangle
(5, 1, 118, 153));
716
.Returns((Rectangle rect) => new
Rectangle
(rect.X + 27, rect.Y + 128, rect.Width, rect.Height));
789
providerMock.Setup(m => m.BoundingRectangle).Returns(new
Rectangle
(5, 1, 118, 153));
798
.Returns((Rectangle rect) => new
Rectangle
(rect.X + 27, rect.Y + 128, rect.Width, rect.Height));
System\Windows\Forms\DeviceContextHdcScopeTests.cs (6)
18
Rectangle clipRectangle =
new
(1, 1, 5, 5);
36
Assert.Equal(new
Rectangle
(-1, -2, 10, 10), (Rectangle)clipRect);
66
Assert.Equal(new
Rectangle
(0, -1, 5, 5), (Rectangle)clipRect);
81
Assert.Equal(new
Rectangle
(0, 0, 10, 10), (Rectangle)clipRect);
101
Rectangle clipRectangle =
new
(1, 1, 5, 5);
169
Assert.Equal(new
Rectangle
(0, -1, 5, 5), (Rectangle)clipRect);
System\Windows\Forms\DeviceContextScopeTests.cs (2)
41
using Region region = new(new
Rectangle
(1, 1, 2, 3));
52
Assert.Equal(new
Rectangle
(2, 1, 1, 3), (Rectangle)rect);
Windows\Win32\RegionTests.cs (1)
54
Rectangle rectangle =
new
(1, 2, 3, 4);
System.Windows.Forms.Primitives.TestUtilities (2)
Metafiles\RecordTypes\EMRBITBLT.cs (1)
35
RECT dest = new
Rectangle
(xDest, yDest, cxDest, cyDest);
Win32\EditControl.cs (1)
19
: base(s_editClass, new
Rectangle
(0, 0, 100, 50), windowName, style, extendedStyle, isMainWindow, parentWindow, parameters, menuHandle)
System.Windows.Forms.Tests (2502)
CheckedListBoxTests.cs (6)
406
yield return new object[] { null, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.None, Color.Red, Color.Blue };
407
yield return new object[] { null, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Checked, Color.Red, Color.Blue };
408
yield return new object[] { new Font("Arial", 8.25f), new
Rectangle
(10, 20, 30, 40), 1, DrawItemState.Default, Color.Red, Color.Blue };
464
DrawItemEventArgs e = new(graphics, null, new
Rectangle
(1, 2, 3, 4), -1, DrawItemState.Default);
475
DrawItemEventArgs e = new(graphics, null, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Default);
488
DrawItemEventArgs e = new(graphics, null, new
Rectangle
(1, 2, 3, 4), 2, DrawItemState.Default);
NumericUpDownTests.cs (5)
36
Assert.Equal(new
Rectangle
(0, 0, 120, 23), upDown.Bounds);
44
new
Rectangle
(1, 1, 98, 17),
86
new
Rectangle
(0, 0, 99, 18),
89
new
Rectangle
(1, 1, 97, 16),
115
Assert.Equal(new
Rectangle
(0, 0, 120, 23), upDown.Bounds);
System\Drawing\Design\PaintValueEventArgsTests.cs (1)
15
yield return new object[] { new Mock<ITypeDescriptorContext>(MockBehavior.Strict).Object, new(), new
Rectangle
(1, 2, 3, 4) };
System\Drawing\Design\UITypeEditorTests.cs (1)
121
yield return new object[] { new(), graphics, new
Rectangle
(1, 2, 3, 4) };
System\Windows\Forms\AbstractButtonBaseTests.cs (1)
80
overChangeRectangle.Should().Be(new
Rectangle
(-1, -1, 1, 1));
System\Windows\Forms\AccessibleObjects\AccessibleObjectTests.cs (11)
316
.Returns(new
Rectangle
(1, 2, 3, 4));
337
.Returns(new
Rectangle
(1, 2, 3, 4));
383
.Returns(new
Rectangle
(1, 2, 3, 4));
387
.Returns(new
Rectangle
(1, 2, 3, 4));
965
.Returns(new
Rectangle
(1, 2, 3, 4));
987
.Returns(new
Rectangle
(1, 2, 3, 4));
1035
.Returns(new
Rectangle
(1, 2, 3, 4));
1039
.Returns(new
Rectangle
(1, 2, 3, 4));
1069
.Returns(new
Rectangle
(1, 2, 3, 4))
1088
.Returns(new
Rectangle
(1, 2, 3, 4))
1093
.Returns(new
Rectangle
(1, 2, 3, 4))
System\Windows\Forms\AccessibleObjects\ComboBox.ComboBoxItemAccessibleObjectTests.cs (1)
438
yield return new object[] { comboBoxStyle, index, new
Rectangle
(x, y, width, height) };
System\Windows\Forms\AccessibleObjects\ListBox.ListBoxItemAccessibleObjectTests.cs (1)
99
Rectangle actualRectangle =
new
((int)actualArray[0], (int)actualArray[1], (int)actualArray[2], (int)actualArray[3]);
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewSubItem.ListViewSubItemAccessibleObjectTests.cs (2)
665
Rectangle expectedBounds =
new
(subItem.Bounds.X, subItem.Bounds.Y, expectedWidth, expectedHeight)
933
Rectangle actualRectangle =
new
((int)actualArray[0], (int)actualArray[1], (int)actualArray[2], (int)actualArray[3]);
System\Windows\Forms\AccessibleObjects\ListViewLabelEditAccessibleObjectTests.cs (1)
25
Rectangle actualRectangle =
new
((int)actualArray[0], (int)actualArray[1], (int)actualArray[2], (int)actualArray[3]);
System\Windows\Forms\AccessibleObjects\MonthCalendar.CalendarCellAccessibleObjectTests.cs (6)
35
yield return new object[] { 0, 0, new
Rectangle
(13, 81, 31, 15) };
36
yield return new object[] { 0, 1, new
Rectangle
(44, 81, 31, 15) };
37
yield return new object[] { 0, 2, new
Rectangle
(75, 81, 31, 15) };
38
yield return new object[] { 1, 0, new
Rectangle
(13, 96, 31, 15) };
39
yield return new object[] { 1, 1, new
Rectangle
(44, 96, 31, 15) };
40
yield return new object[] { 1, 2, new
Rectangle
(75, 96, 31, 15) };
System\Windows\Forms\AccessibleObjects\Panel.PanelAccessibleObjectTests.cs (1)
140
Rectangle expected =
new
(0, 0, 10, 10);
System\Windows\Forms\AccessibleObjects\TreeViewLabelEditAccessibleObjectTests.cs (1)
24
Rectangle actualRectangle =
new
((int)actualArray[0], (int)actualArray[1], (int)actualArray[2], (int)actualArray[3]);
System\Windows\Forms\AccessibleObjects\UpDownBase.UpDownButtons.UpDownButtonsAccessibleObjectTests.cs (1)
115
Rectangle actualRectangle =
new
((int)actualArray[0], (int)actualArray[1], (int)actualArray[2], (int)actualArray[3]);
System\Windows\Forms\AxHostTests.cs (6)
42
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.Bounds);
50
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.ClientRectangle);
67
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.DisplayRectangle);
136
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.Bounds);
144
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.ClientRectangle);
161
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.DisplayRectangle);
System\Windows\Forms\BinaryFormatUtilitiesTests.cs (3)
125
new
Rectangle
(-1, int.MinValue, 10, 13),
468
Rectangle value =
new
(1, 1, 2, 2);
904
public Rectangle Rectangle =
new
(1, 2, 3, 4);
System\Windows\Forms\ButtonBaseTests.cs (3)
34
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.Bounds);
42
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.ClientRectangle);
58
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.DisplayRectangle);
System\Windows\Forms\ButtonRenderingTests.cs (1)
242
new
Rectangle
(0, 0, button.Width - 1, button.Height - 1),
System\Windows\Forms\ButtonTests.cs (3)
36
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.Bounds);
44
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.ClientRectangle);
61
Assert.Equal(new
Rectangle
(0, 0, 75, 23), control.DisplayRectangle);
System\Windows\Forms\CheckBoxRendererTests.cs (3)
77
bounds: new
Rectangle
(41, 5, 20, 12),
114
bounds: new
Rectangle
(3, 0, 20, 12),
148
bounds: new
Rectangle
(3, 0, 20, 12),
System\Windows\Forms\CheckBoxTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.Bounds);
46
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.ClientRectangle);
62
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.DisplayRectangle);
System\Windows\Forms\ClipboardTests.cs (1)
817
Rectangle expected =
new
(1, 1, 2, 2);
System\Windows\Forms\ComboBox.ComboBoxUiaTextProviderTests.cs (3)
562
yield return new object[] { comboBoxStyle, new Size(0, 0), new
Rectangle
(0, 0, 80, 16) };
564
yield return new object[] { comboBoxStyle, new Size(50, 50), new
Rectangle
(0, 0, width, 15) };
566
yield return new object[] { comboBoxStyle, new Size(250, 100), new
Rectangle
(0, 0, width, 15) };
System\Windows\Forms\ComboBoxTests.cs (8)
39
Assert.Equal(new
Rectangle
(0, 0, 121, control.PreferredHeight), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 117, control.PreferredHeight - 4), control.ClientRectangle);
66
Assert.Equal(new
Rectangle
(0, 0, 117, control.PreferredHeight - 4), control.DisplayRectangle);
390
comboBox.InvokeOnPaint(new PaintEventArgs(graphics, new
Rectangle
(0, 0, 100, 100)));
1828
Bounds = new
Rectangle
(1, 2, 30, 40)
1910
Bounds = new
Rectangle
(1, 2, 30, 40)
2012
Bounds = new
Rectangle
(1, 2, 30, 40)
2116
Bounds = new
Rectangle
(1, 2, 30, 40)
System\Windows\Forms\ContentsResizedEventArgsTests.cs (2)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
15
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
System\Windows\Forms\ControlPaintTests.cs (256)
543
yield return new object[] { new
Rectangle
(1, 2, -3, -4), Color.Empty, style };
544
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, style };
545
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.ControlLight, style };
546
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.Control, style };
547
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.ControlDark, style };
548
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Black, style };
549
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.White, style };
550
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Transparent, style };
551
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Empty, style };
552
yield return new object[] { new
Rectangle
(1, 2, 4, 3), Color.Red, style };
553
yield return new object[] { new
Rectangle
(1, 2, 3, 3), Color.Red, style };
576
ControlPaint.DrawBorder(graphics, new
Rectangle
(1, 2, 3, 4), Color.Red, style);
579
ControlPaint.DrawBorder(graphics, new
Rectangle
(1, 2, 3, 4), Color.Red, style);
586
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 4, style };
588
yield return new object[] { new
Rectangle
(1, 2, -3, -4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 4, style };
590
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 4, style };
591
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 0, style, Color.Blue, 3, style, Color.Yellow, 4, style };
592
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 0, style, Color.Blue, 0, style, Color.Yellow, 4, style };
593
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 0, style, Color.Blue, 3, style, Color.Yellow, 0, style };
594
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 0, style, Color.Blue, 0, style, Color.Yellow, 0, style };
595
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 2, style, Color.Blue, 0, style, Color.Yellow, 4, style };
596
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 2, style, Color.Blue, 0, style, Color.Yellow, 0, style };
597
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 0, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 0, style };
599
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 0, style, Color.Blue, 3, style, Color.Yellow, 4, style };
600
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 0, style, Color.Blue, 0, style, Color.Yellow, 4, style };
601
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 0, style, Color.Blue, 3, style, Color.Yellow, 0, style };
602
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 0, style, Color.Blue, 0, style, Color.Yellow, 0, style };
604
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 0, style, Color.Yellow, 4, style };
605
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 0, style, Color.Yellow, 0, style };
607
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 0, style };
632
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, 4, style };
633
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, -1, style, Color.Blue, 3, style, Color.Yellow, 4, style };
634
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, -1, style, Color.Blue, -1, style, Color.Yellow, 4, style };
635
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, -1, style, Color.Blue, 3, style, Color.Yellow, -1, style };
636
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, -1, style, Color.Blue, -1, style, Color.Yellow, -1, style };
637
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, 2, style, Color.Blue, -1, style, Color.Yellow, 4, style };
638
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, 2, style, Color.Blue, -1, style, Color.Yellow, -1, style };
639
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, -1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, -1, style };
641
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, -1, style, Color.Blue, 3, style, Color.Yellow, 4, style };
642
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, -1, style, Color.Blue, -1, style, Color.Yellow, 4, style };
643
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, -1, style, Color.Blue, 3, style, Color.Yellow, -1, style };
644
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, -1, style, Color.Blue, -1, style, Color.Yellow, -1, style };
646
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, -1, style, Color.Yellow, 4, style };
647
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, -1, style, Color.Yellow, -1, style };
649
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Green, 2, style, Color.Blue, 3, style, Color.Yellow, -1, style };
675
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawBorder(null, new
Rectangle
(1, 2, 3, 4), Color.Red, style));
683
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawBorder(null, new
Rectangle
(1, 2, 3, 4), Color.Red, 1, style, Color.Red, 1, style, Color.Red, 1, style, Color.Red, 1, style));
689
yield return new object[] { new
Rectangle
(1, 2, -3, -4) };
690
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
691
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
692
yield return new object[] { new
Rectangle
(1, 2, 4, 3) };
693
yield return new object[] { new
Rectangle
(1, 2, 3, 3) };
713
yield return new object[] { new
Rectangle
(1, 2, -3, -4), style };
714
yield return new object[] { new
Rectangle
(0, 0, 3, 4), style };
715
yield return new object[] { new
Rectangle
(1, 2, 3, 4), style };
716
yield return new object[] { new
Rectangle
(1, 2, 4, 3), style };
717
yield return new object[] { new
Rectangle
(1, 2, 3, 3), style };
740
yield return new object[] { new
Rectangle
(1, 2, -3, -4), style, side };
741
yield return new object[] { new
Rectangle
(0, 0, 3, 4), style, side };
742
yield return new object[] { new
Rectangle
(1, 2, 3, 4), style, side };
743
yield return new object[] { new
Rectangle
(1, 2, 4, 3), style, side };
744
yield return new object[] { new
Rectangle
(1, 2, 3, 3), style, side };
802
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawBorder3D(null, new
Rectangle
(1, 2, 3, 4)));
803
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawBorder3D(null, new
Rectangle
(1, 2, 3, 4), style));
804
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawBorder3D(null, new
Rectangle
(1, 2, 3, 4), style, Border3DSide.All));
814
yield return new object[] { new
Rectangle
(0, 0, 3, 4), state };
815
yield return new object[] { new
Rectangle
(1, 2, 3, 4), state };
816
yield return new object[] { new
Rectangle
(1, 2, 4, 3), state };
817
yield return new object[] { new
Rectangle
(1, 2, 3, 3), state };
850
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawButton(null, new
Rectangle
(1, 2, 3, 4), state));
865
Assert.Throws<ArgumentException>(() => ControlPaint.DrawButton(graphics, new
Rectangle
(0, 0, width, height), state));
876
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawButton(graphics, new
Rectangle
(0, 0, -3, 4), state));
887
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawButton(graphics, new
Rectangle
(0, 0, 3, -4), state));
897
yield return new object[] { new
Rectangle
(0, 0, 3, 4), button, state };
898
yield return new object[] { new
Rectangle
(1, 2, 3, 4), button, state };
899
yield return new object[] { new
Rectangle
(1, 2, 4, 3), button, state };
900
yield return new object[] { new
Rectangle
(1, 2, 3, 3), button, state };
934
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawCaptionButton(null, new
Rectangle
(1, 2, 3, 4), CaptionButton.Close, state));
948
Assert.Throws<ArgumentException>(() => ControlPaint.DrawCaptionButton(graphics, new
Rectangle
(0, 0, width, height), CaptionButton.Close, state));
959
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawCaptionButton(graphics, new
Rectangle
(0, 0, -3, 4), CaptionButton.Close, state));
970
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawCaptionButton(graphics, new
Rectangle
(0, 0, 3, -4), CaptionButton.Close, state));
978
yield return new object[] { new
Rectangle
(0, 0, 3, 4), state };
979
yield return new object[] { new
Rectangle
(1, 2, 3, 4), state };
980
yield return new object[] { new
Rectangle
(1, 2, 4, 3), state };
981
yield return new object[] { new
Rectangle
(1, 2, 3, 3), state };
1014
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawCheckBox(null, new
Rectangle
(1, 2, 3, 4), state));
1029
Assert.Throws<ArgumentException>(() => ControlPaint.DrawCheckBox(graphics, new
Rectangle
(0, 0, width, height), state));
1040
Assert.Throws<ArgumentOutOfRangeException>(expectedParamName, () => ControlPaint.DrawCheckBox(graphics, new
Rectangle
(0, 0, -3, 4), state));
1051
Assert.Throws<ArgumentOutOfRangeException>(expectedParamName, () => ControlPaint.DrawCheckBox(graphics, new
Rectangle
(0, 0, 3, -4), state));
1059
yield return new object[] { new
Rectangle
(0, 0, 3, 4), state };
1060
yield return new object[] { new
Rectangle
(1, 2, 3, 4), state };
1061
yield return new object[] { new
Rectangle
(1, 2, 4, 3), state };
1062
yield return new object[] { new
Rectangle
(1, 2, 3, 3), state };
1095
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawComboButton(null, new
Rectangle
(1, 2, 3, 4), state));
1109
Assert.Throws<ArgumentException>(() => ControlPaint.DrawComboButton(graphics, new
Rectangle
(0, 0, width, height), state));
1120
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawComboButton(graphics, new
Rectangle
(0, 0, -3, 4), state));
1131
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawComboButton(graphics, new
Rectangle
(0, 0, 3, -4), state));
1138
yield return new object[] { new
Rectangle
(1, 2, -3, -4) };
1139
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
1140
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
1141
yield return new object[] { new
Rectangle
(1, 2, 4, 3) };
1142
yield return new object[] { new
Rectangle
(1, 2, 3, 3) };
1160
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawContainerGrabHandle(null, new
Rectangle
(1, 2, 3, 4)));
1166
yield return new object[] { new
Rectangle
(1, 2, -3, -4) };
1167
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
1168
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
1169
yield return new object[] { new
Rectangle
(1, 2, 4, 3) };
1170
yield return new object[] { new
Rectangle
(1, 2, 3, 3) };
1188
yield return new object[] { new
Rectangle
(1, 2, -3, -4), Color.Red, Color.Blue };
1189
yield return new object[] { new
Rectangle
(0, 0, 3, 4), Color.Red, Color.Blue };
1190
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Blue };
1191
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Black, Color.Blue };
1192
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.White, Color.Blue };
1193
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Empty, Color.Blue };
1194
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Transparent, Color.Blue };
1195
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Black };
1196
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.White };
1197
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Empty };
1198
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Transparent };
1199
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Red };
1200
yield return new object[] { new
Rectangle
(1, 2, 4, 3), Color.Red, Color.Blue };
1201
yield return new object[] { new
Rectangle
(1, 2, 3, 3), Color.Red, Color.Blue };
1219
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawFocusRectangle(null, new
Rectangle
(1, 2, 3, 4)));
1220
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawFocusRectangle(null, new
Rectangle
(1, 2, 3, 4), Color.Red, Color.Blue));
1230
yield return new object[] { new
Rectangle
(1, 2, -3, -4), primary, enabled };
1231
yield return new object[] { new
Rectangle
(0, 0, 3, 4), primary, enabled };
1232
yield return new object[] { new
Rectangle
(1, 2, 3, 4), primary, enabled };
1233
yield return new object[] { new
Rectangle
(1, 2, 4, 3), primary, enabled };
1234
yield return new object[] { new
Rectangle
(1, 2, 3, 3), primary, enabled };
1258
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawGrabHandle(null, new
Rectangle
(1, 2, 3, 4), primary, enabled));
1264
yield return new object[] { new
Rectangle
(1, 2, -3, -4), new Size(1, 1), Color.Red };
1265
yield return new object[] { new
Rectangle
(0, 0, 3, 4), new Size(1, 1), Color.Red };
1266
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.Red };
1267
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.Black };
1268
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.White };
1269
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.Empty };
1270
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.Transparent };
1271
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(10, 20), Color.Red };
1272
yield return new object[] { new
Rectangle
(1, 2, 4, 3), new Size(10, 20), Color.Red };
1273
yield return new object[] { new
Rectangle
(1, 2, 3, 3), new Size(10, 20), Color.Red };
1291
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawGrid(null, new
Rectangle
(1, 2, 3, 4), new Size(1, 1), Color.Red));
1303
Assert.Throws<ArgumentOutOfRangeException>("pixelsBetweenDots", () => ControlPaint.DrawGrid(graphics, new
Rectangle
(0, 0, width, height), new Size(width, height), Color.Red));
1357
yield return new object[] { new
Rectangle
(1, 2, -3, -4), primary };
1358
yield return new object[] { new
Rectangle
(0, 0, 3, 4), primary };
1359
yield return new object[] { new
Rectangle
(1, 2, 3, 4), primary };
1360
yield return new object[] { new
Rectangle
(1, 2, 4, 3), primary };
1361
yield return new object[] { new
Rectangle
(1, 2, 3, 3), primary };
1382
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawLockedFrame(null, new
Rectangle
(1, 2, 3, 4), primary));
1389
yield return new object[] { new
Rectangle
(0, 0, 3, 4), glyph };
1390
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph };
1391
yield return new object[] { new
Rectangle
(1, 2, 4, 3), glyph };
1392
yield return new object[] { new
Rectangle
(1, 2, 3, 3), glyph };
1412
yield return new object[] { new
Rectangle
(0, 0, 3, 4), glyph, Color.Red, Color.Blue };
1413
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.Blue };
1414
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Black, Color.Blue };
1415
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.White, Color.Blue };
1416
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Empty, Color.Blue };
1417
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Transparent, Color.Blue };
1418
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.Black };
1419
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.White };
1420
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.Empty };
1421
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.Transparent };
1422
yield return new object[] { new
Rectangle
(1, 2, 3, 4), glyph, Color.Red, Color.Red };
1423
yield return new object[] { new
Rectangle
(1, 2, 4, 3), glyph, Color.Red, Color.Red };
1424
yield return new object[] { new
Rectangle
(1, 2, 3, 3), glyph, Color.Red, Color.Red };
1470
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawMenuGlyph(null, new
Rectangle
(1, 2, 3, 4), glyph));
1488
Assert.Throws<ArgumentException>(() => ControlPaint.DrawMenuGlyph(graphics, new
Rectangle
(0, 0, width, height), glyph));
1500
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawMenuGlyph(graphics, new
Rectangle
(0, 0, -3, 4), glyph));
1512
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawMenuGlyph(graphics, new
Rectangle
(0, 0, 3, -4), glyph));
1520
yield return new object[] { new
Rectangle
(0, 0, 3, 4), state };
1521
yield return new object[] { new
Rectangle
(1, 2, 3, 4), state };
1522
yield return new object[] { new
Rectangle
(1, 2, 4, 3), state };
1523
yield return new object[] { new
Rectangle
(1, 2, 3, 3), state };
1556
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawMixedCheckBox(null, new
Rectangle
(1, 2, 3, 4), state));
1570
Assert.Throws<ArgumentException>(() => ControlPaint.DrawMixedCheckBox(graphics, new
Rectangle
(0, 0, width, height), state));
1581
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawMixedCheckBox(graphics, new
Rectangle
(0, 0, -3, 4), state));
1592
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawMixedCheckBox(graphics, new
Rectangle
(0, 0, 3, -4), state));
1600
yield return new object[] { new
Rectangle
(0, 0, 3, 4), state };
1601
yield return new object[] { new
Rectangle
(1, 2, 3, 4), state };
1602
yield return new object[] { new
Rectangle
(1, 2, 4, 3), state };
1603
yield return new object[] { new
Rectangle
(1, 2, 3, 3), state };
1636
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawRadioButton(null, new
Rectangle
(1, 2, 3, 4), state));
1650
Assert.Throws<ArgumentException>(() => ControlPaint.DrawRadioButton(graphics, new
Rectangle
(0, 0, width, height), state));
1661
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawRadioButton(graphics, new
Rectangle
(0, 0, -3, 4), state));
1672
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawRadioButton(graphics, new
Rectangle
(0, 0, 3, -4), state));
1681
yield return new object[] { new
Rectangle
(1, 2, -3, -4), Color.Empty, style };
1682
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red, style };
1683
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.ControlLight, style };
1684
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.Control, style };
1685
yield return new object[] { new
Rectangle
(1, 2, 3, 4), SystemColors.ControlDark, style };
1686
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Black, style };
1687
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.White, style };
1688
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Transparent, style };
1689
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Empty, style };
1690
yield return new object[] { new
Rectangle
(1, 2, 4, 3), Color.Red, style };
1691
yield return new object[] { new
Rectangle
(1, 2, 3, 3), Color.Red, style };
1737
yield return new object[] { new
Rectangle
(0, 0, 3, 4), button, state };
1738
yield return new object[] { new
Rectangle
(1, 2, 3, 4), button, state };
1739
yield return new object[] { new
Rectangle
(1, 2, 4, 3), button, state };
1740
yield return new object[] { new
Rectangle
(1, 2, 3, 3), button, state };
1774
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawScrollButton(null, new
Rectangle
(1, 2, 3, 4), ScrollButton.Up, state));
1788
Assert.Throws<ArgumentException>(() => ControlPaint.DrawScrollButton(graphics, new
Rectangle
(0, 0, width, height), ScrollButton.Up, state));
1799
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.DrawScrollButton(graphics, new
Rectangle
(0, 0, -3, 4), ScrollButton.Up, state));
1810
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.DrawScrollButton(graphics, new
Rectangle
(0, 0, 3, -4), ScrollButton.Up, state));
1819
yield return new object[] { active, new
Rectangle
(1, 2, -3, -4), new
Rectangle
(1, 2, -3, -4), Color.Red };
1820
yield return new object[] { active, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), Color.Red };
1821
yield return new object[] { active, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 1, 4, 5), Color.Red };
1822
yield return new object[] { active, new
Rectangle
(0, 1, 4, 5), new
Rectangle
(1, 2, 3, 4), Color.Red };
1823
yield return new object[] { active, new
Rectangle
(0, 1, 4, 5), new
Rectangle
(1, 2, 3, 4), Color.Black };
1824
yield return new object[] { active, new
Rectangle
(0, 1, 4, 5), new
Rectangle
(1, 2, 3, 4), Color.White };
1825
yield return new object[] { active, new
Rectangle
(0, 1, 4, 5), new
Rectangle
(1, 2, 3, 4), Color.Transparent };
1826
yield return new object[] { active, new
Rectangle
(0, 1, 4, 5), new
Rectangle
(1, 2, 3, 4), Color.Empty };
1847
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawSelectionFrame(null, active, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), Color.Red));
1853
yield return new object[] { Color.Red, new
Rectangle
(1, 2, -3, -4) };
1854
yield return new object[] { Color.Red, new
Rectangle
(0, 0, 3, 4) };
1855
yield return new object[] { Color.Red, new
Rectangle
(1, 2, 3, 4) };
1856
yield return new object[] { Color.Black, new
Rectangle
(1, 2, 3, 4) };
1857
yield return new object[] { Color.White, new
Rectangle
(1, 2, 3, 4) };
1858
yield return new object[] { Color.Empty, new
Rectangle
(1, 2, 3, 4) };
1859
yield return new object[] { Color.Transparent, new
Rectangle
(1, 2, 3, 4) };
1860
yield return new object[] { Color.Red, new
Rectangle
(1, 2, 3, 4) };
1861
yield return new object[] { Color.Red, new
Rectangle
(1, 2, 3, 4) };
1862
yield return new object[] { Color.Red, new
Rectangle
(1, 2, 4, 3) };
1892
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawSizeGrip(null, Color.Red, new
Rectangle
(1, 2, 3, 4)));
1948
yield return new object[] { s, SystemFonts.MenuFont, Color.Red, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.Default };
1950
yield return new object[] { s, SystemFonts.MenuFont, Color.Red, new
Rectangle
(1, 2, -3, -4), TextFormatFlags.VerticalCenter };
1951
yield return new object[] { s, SystemFonts.MenuFont, Color.Red, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.VerticalCenter };
1952
yield return new object[] { s, SystemFonts.MenuFont, Color.Black, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.VerticalCenter };
1953
yield return new object[] { s, SystemFonts.MenuFont, Color.White, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.VerticalCenter };
1954
yield return new object[] { s, SystemFonts.MenuFont, Color.Transparent, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.VerticalCenter };
1955
yield return new object[] { s, SystemFonts.MenuFont, Color.Empty, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.VerticalCenter };
1977
Assert.Throws<ArgumentNullException>("dc", () => ControlPaint.DrawStringDisabled(null, s, SystemFonts.MenuFont, Color.Red, new
Rectangle
(1, 2, 3, 4), TextFormatFlags.Default));
1983
yield return new object[] { new
Rectangle
(1, 2, -3, -4) };
1984
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
1985
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
1986
yield return new object[] { new
Rectangle
(1, 2, 4, 3) };
1987
yield return new object[] { new
Rectangle
(1, 2, 3, 3) };
2005
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.DrawVisualStyleBorder(null, new
Rectangle
(1, 2, 3, 4)));
2011
yield return new object[] { new
Rectangle
(1, 2, -3, -4), Color.Red };
2012
yield return new object[] { new
Rectangle
(0, 0, 3, 4), Color.Red };
2013
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Red };
2014
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Black };
2015
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.White };
2016
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Empty };
2017
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Color.Transparent };
2018
yield return new object[] { new
Rectangle
(1, 2, 4, 3), Color.Red };
2019
yield return new object[] { new
Rectangle
(1, 2, 3, 3), Color.Red };
System\Windows\Forms\ControlPaintTests.Rendering.cs (10)
21
Rectangle bounds =
new
(10, 10, 10, 10);
28
new
Rectangle
(10, 10, 9, 9),
40
Rectangle bounds =
new
(10, 10, 10, 10);
100
Rectangle bounds =
new
(10, 10, 10, 10);
175
Rectangle bounds =
new
(10, 10, 10, 10);
249
Rectangle bounds =
new
(10, 10, 10, 10);
323
Rectangle bounds =
new
(10, 10, 10, 10);
336
new
Rectangle
(8, 8, 13, 13),
351
Rectangle bounds =
new
(10, 10, 10, 10);
364
new
Rectangle
(8, 8, 13, 13),
System\Windows\Forms\ControlTests.cs (6)
214
Assert.Equal(new
Rectangle
(left, top, width, height), control.Bounds);
221
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
238
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
406
Assert.Equal(new
Rectangle
(left, top, width, height), control.Bounds);
413
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
430
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
System\Windows\Forms\ControlTests.Handlers.cs (36)
2183
yield return new object[] { testData, new Region(new
Rectangle
(1, 2, 3, 4)) };
2335
yield return new object[] { testData, new Region(new
Rectangle
(1, 2, 3, 4)) };
2737
yield return new object[] { new InvalidateEventArgs(new
Rectangle
(1, 2, 3, 4)) };
2770
yield return new object[] { true, Color.Empty, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)) };
2771
yield return new object[] { true, Color.Empty, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)) };
2774
yield return new object[] { true, Color.Red, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)) };
2775
yield return new object[] { true, Color.Red, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)) };
2778
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)) };
2779
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)) };
2783
yield return new object[] { false, Color.Empty, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)) };
2784
yield return new object[] { false, Color.Empty, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)) };
2787
yield return new object[] { false, Color.Red, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)) };
2788
yield return new object[] { false, Color.Red, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)) };
2874
yield return new object[] { true, Color.Empty, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)), 0 };
2875
yield return new object[] { true, Color.Empty, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)), 0 };
2877
yield return new object[] { true, Color.Red, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)), 0 };
2878
yield return new object[] { true, Color.Red, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)), 0 };
2880
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)), 0 };
2881
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)), 1 };
2884
yield return new object[] { false, Color.Empty, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)), 0 };
2885
yield return new object[] { false, Color.Empty, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)), 0 };
2887
yield return new object[] { false, Color.Red, new InvalidateEventArgs(new
Rectangle
(100, 200, 300, 400)), 0 };
2888
yield return new object[] { false, Color.Red, new InvalidateEventArgs(new
Rectangle
(1, 2, 300, 400)), 0 };
3856
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
3891
Bounds = new
Rectangle
(1, 2, 30, 40)
3895
Bounds = new
Rectangle
(1, 2, 30, 40)
3932
Bounds = new
Rectangle
(1, 2, 30, 40)
3936
Bounds = new
Rectangle
(1, 2, 30, 40)
3978
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
3982
Bounds = new
Rectangle
(1, 2, 10, 20),
4001
Assert.Equal(new
Rectangle
(1, 2, 0, 0), e.ClipRectangle);
4028
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4105
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4109
Bounds = new
Rectangle
(1, 2, 30, 40)
4113
Bounds = new
Rectangle
(1, 2, 10, 20),
4132
Assert.Equal(new
Rectangle
(1, 2, 10, 20), e.ClipRectangle);
System\Windows\Forms\ControlTests.Internals.cs (1)
175
Rectangle expectedBounds =
new
(expected, expected, expected, expected);
System\Windows\Forms\ControlTests.Methods.cs (531)
450
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
637
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
859
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
1831
yield return new object[] { new
Rectangle
(0, 0, 1, 1) };
1832
yield return new object[] { new
Rectangle
(0, 0, 10, 10) };
1833
yield return new object[] { new
Rectangle
(2, 3, 10, 15) };
1834
yield return new object[] { new
Rectangle
(2, 3, 15, 10) };
1835
yield return new object[] { new
Rectangle
(0, 0, 100, 150) };
1881
Assert.Throws<ArgumentNullException>("bitmap", () => control.DrawToBitmap(null, new
Rectangle
(1, 2, 3, 4)));
1899
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(x, y, width, height)));
1913
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(1, 2, 3, 4)));
1927
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(1, 2, 3, 4)));
2342
Bounds = new
Rectangle
(1, 2, 30, 40)
2402
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, Rectangle.Empty };
2403
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
2404
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
2405
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 0, 4) };
2406
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 0) };
2408
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2409
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2410
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2411
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2412
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2414
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 6, 12) };
2415
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
2416
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
2417
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 6, 4) };
2418
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 12) };
2420
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, -6, -12) };
2421
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
2422
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
2423
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, -6, 4) };
2424
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, -12) };
2442
yield return new object[] { Rectangle.Empty, new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 4, 4) };
2445
yield return new object[] { Rectangle.Empty, new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(0, 0, 4, 0) };
2446
yield return new object[] { Rectangle.Empty, new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(0, 0, 0, 4) };
2448
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 4, 4) };
2449
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
2450
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
2451
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 4, 4) };
2452
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2454
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2455
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2456
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2457
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2458
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2460
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 2, 4) };
2461
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
2462
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
2463
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 2, 4) };
2464
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2466
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, 6, 4) };
2467
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
2468
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
2469
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, 6, 4) };
2470
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2575
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(1, 2, 0, 0) };
2576
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2577
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2578
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 0, 4) };
2579
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 0) };
2581
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2582
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2583
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2584
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2585
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2587
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(1, 2, 6, 12) };
2588
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2589
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2590
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 6, 4) };
2591
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 12) };
2593
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(1, 2, -6, -12) };
2594
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2595
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2596
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, -6, 4) };
2597
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, -12) };
2664
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 3, 0) };
2665
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
2666
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
2667
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2668
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 0) };
2670
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2671
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2672
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2673
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2674
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2676
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 3, 12) };
2677
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
2678
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
2679
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2680
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 12) };
2682
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, 3, -12) };
2683
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
2684
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
2685
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2686
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, -12) };
2714
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 0, 4) };
2715
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
2716
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
2717
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 0, 4) };
2718
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2720
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2721
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2722
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2723
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2724
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2726
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 6, 4) };
2727
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
2728
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
2729
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 6, 4) };
2730
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2732
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, -6, 4) };
2733
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
2734
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
2735
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, -6, 4) };
2736
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2764
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 3, 4) };
2765
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
2766
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
2767
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2768
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2770
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
2771
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
2772
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
2773
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2774
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2776
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 3, 4) };
2777
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
2778
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
2779
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2780
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
2782
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, 3, 4) };
2783
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
2784
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
2785
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
2786
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
3200
yield return new object[] { opaque, new
Rectangle
(0, 0, 10, 20) };
3201
yield return new object[] { opaque, new
Rectangle
(1, 2, 3, 4) };
3202
yield return new object[] { opaque, new
Rectangle
(5, 10, 5, 10) };
3203
yield return new object[] { opaque, new
Rectangle
(100, 200, 300, 400) };
3204
yield return new object[] { opaque, new
Rectangle
(-100, -200, -300, -400) };
3230
yield return new object[] { opaque, Rectangle.Empty, new
Rectangle
(0, 0, 10, 20) };
3231
yield return new object[] { opaque, new
Rectangle
(0, 0, 10, 20), new
Rectangle
(0, 0, 10, 20) };
3232
yield return new object[] { opaque, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
3233
yield return new object[] { opaque, new
Rectangle
(5, 10, 5, 10), new
Rectangle
(5, 10, 5, 10) };
3234
yield return new object[] { opaque, new
Rectangle
(100, 200, 300, 400), new
Rectangle
(100, 200, 300, 400) };
3235
yield return new object[] { opaque, new
Rectangle
(-100, -200, -300, -400), new
Rectangle
(-100, -200, -300, -400) };
3337
yield return new object[] { opaque, new
Rectangle
(0, 0, 10, 20), invalidateChildren };
3338
yield return new object[] { opaque, new
Rectangle
(1, 2, 3, 4), invalidateChildren };
3339
yield return new object[] { opaque, new
Rectangle
(5, 10, 5, 10), invalidateChildren };
3340
yield return new object[] { opaque, new
Rectangle
(100, 200, 300, 400), invalidateChildren };
3341
yield return new object[] { opaque, new
Rectangle
(-100, -200, -300, -400), invalidateChildren };
3370
yield return new object[] { opaque, Rectangle.Empty, invalidateChildren, new
Rectangle
(0, 0, 10, 20) };
3371
yield return new object[] { opaque, new
Rectangle
(0, 0, 10, 20), invalidateChildren, new
Rectangle
(0, 0, 10, 20) };
3372
yield return new object[] { opaque, new
Rectangle
(1, 2, 3, 4), invalidateChildren, new
Rectangle
(1, 2, 3, 4) };
3373
yield return new object[] { opaque, new
Rectangle
(5, 10, 5, 10), invalidateChildren, new
Rectangle
(5, 10, 5, 10) };
3374
yield return new object[] { opaque, new
Rectangle
(100, 200, 300, 400), invalidateChildren, new
Rectangle
(100, 200, 300, 400) };
3375
yield return new object[] { opaque, new
Rectangle
(-100, -200, -300, -400), invalidateChildren, new
Rectangle
(-100, -200, -300, -400) };
3476
yield return new object[] { opaque, new Region(new
Rectangle
(0, 0, 10, 20)) };
3477
yield return new object[] { opaque, new Region(new
Rectangle
(1, 2, 3, 4)) };
3478
yield return new object[] { opaque, new Region(new
Rectangle
(5, 10, 5, 10)) };
3479
yield return new object[] { opaque, new Region(new
Rectangle
(100, 200, 300, 400)) };
3480
yield return new object[] { opaque, new Region(new
Rectangle
(-100, -200, -300, -400)) };
3507
yield return new object[] { opaque, null, new
Rectangle
(0, 0, 10, 20) };
3508
yield return new object[] { opaque, new Region(new
Rectangle
(0, 0, 10, 20)), new
Rectangle
(0, 0, 10, 20) };
3509
yield return new object[] { opaque, new Region(new
Rectangle
(1, 2, 3, 4)), new
Rectangle
(1, 2, 3, 4) };
3510
yield return new object[] { opaque, new Region(new
Rectangle
(5, 10, 5, 10)), new
Rectangle
(5, 10, 5, 10) };
3511
yield return new object[] { opaque, new Region(new
Rectangle
(100, 200, 300, 400)), new
Rectangle
(100, 200, 300, 400) };
3512
yield return new object[] { opaque, new Region(new
Rectangle
(-100, -200, -300, -400)), new
Rectangle
(-100, -200, -300, -400) };
3513
yield return new object[] { opaque, new Region(), new
Rectangle
(-4194304, -4194304, 8388608, 8388608) };
3615
yield return new object[] { opaque, new Region(new
Rectangle
(0, 0, 10, 20)), invalidateChildren };
3616
yield return new object[] { opaque, new Region(new
Rectangle
(1, 2, 3, 4)), invalidateChildren };
3617
yield return new object[] { opaque, new Region(new
Rectangle
(5, 10, 5, 10)), invalidateChildren };
3618
yield return new object[] { opaque, new Region(new
Rectangle
(100, 200, 300, 400)), invalidateChildren };
3619
yield return new object[] { opaque, new Region(new
Rectangle
(-100, -200, -300, -400)), invalidateChildren };
3649
yield return new object[] { opaque, null, invalidateChildren, new
Rectangle
(0, 0, 10, 20) };
3650
yield return new object[] { opaque, new Region(new
Rectangle
(0, 0, 10, 20)), invalidateChildren, new
Rectangle
(0, 0, 10, 20) };
3651
yield return new object[] { opaque, new Region(new
Rectangle
(1, 2, 3, 4)), invalidateChildren, new
Rectangle
(1, 2, 3, 4) };
3652
yield return new object[] { opaque, new Region(new
Rectangle
(5, 10, 5, 10)), invalidateChildren, new
Rectangle
(5, 10, 5, 10) };
3653
yield return new object[] { opaque, new Region(new
Rectangle
(100, 200, 300, 400)), invalidateChildren, new
Rectangle
(100, 200, 300, 400) };
3654
yield return new object[] { opaque, new Region(new
Rectangle
(-100, -200, -300, -400)), invalidateChildren, new
Rectangle
(-100, -200, -300, -400) };
3655
yield return new object[] { opaque, new Region(), invalidateChildren, new
Rectangle
(-4194304, -4194304, 8388608, 8388608) };
4264
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4273
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4320
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4495
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
4528
yield return new object[] { true, Color.Empty, new
Rectangle
(100, 200, 300, 400) };
4529
yield return new object[] { true, Color.Empty, new
Rectangle
(1, 2, 300, 400) };
4532
yield return new object[] { true, Color.Red, new
Rectangle
(100, 200, 300, 400) };
4533
yield return new object[] { true, Color.Red, new
Rectangle
(1, 2, 300, 400) };
4536
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new
Rectangle
(100, 200, 300, 400) };
4537
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new
Rectangle
(1, 2, 300, 400) };
4541
yield return new object[] { false, Color.Empty, new
Rectangle
(100, 200, 300, 400) };
4542
yield return new object[] { false, Color.Empty, new
Rectangle
(1, 2, 300, 400) };
4545
yield return new object[] { false, Color.Red, new
Rectangle
(100, 200, 300, 400) };
4546
yield return new object[] { false, Color.Red, new
Rectangle
(1, 2, 300, 400) };
4632
yield return new object[] { true, Color.Empty, new
Rectangle
(100, 200, 300, 400), 0 };
4633
yield return new object[] { true, Color.Empty, new
Rectangle
(1, 2, 300, 400), 0 };
4635
yield return new object[] { true, Color.Red, new
Rectangle
(100, 200, 300, 400), 0 };
4636
yield return new object[] { true, Color.Red, new
Rectangle
(1, 2, 300, 400), 0 };
4638
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new
Rectangle
(100, 200, 300, 400), 0 };
4639
yield return new object[] { true, Color.FromArgb(200, 50, 100, 150), new
Rectangle
(1, 2, 300, 400), 1 };
4642
yield return new object[] { false, Color.Empty, new
Rectangle
(100, 200, 300, 400), 0 };
4643
yield return new object[] { false, Color.Empty, new
Rectangle
(1, 2, 300, 400), 0 };
4645
yield return new object[] { false, Color.Red, new
Rectangle
(100, 200, 300, 400), 0 };
4646
yield return new object[] { false, Color.Red, new
Rectangle
(1, 2, 300, 400), 0 };
7384
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
7385
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
7393
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7403
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
7404
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
7412
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7495
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
7496
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
7504
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
7514
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
7515
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
7523
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
7593
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
7594
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
7602
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7612
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
7613
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
7621
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7711
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
7712
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
7720
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7731
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
7732
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
7740
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
7834
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
7835
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
7843
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
7856
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
7857
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
7865
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
7982
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
7983
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
7991
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
8009
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8010
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8018
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
8171
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8172
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8180
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8190
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8191
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8199
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8282
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8283
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8291
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8301
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8302
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8310
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8380
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
8381
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
8389
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8399
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
8400
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
8408
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8568
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8569
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8577
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8588
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8589
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8597
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8691
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8692
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8700
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8713
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8714
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8722
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8839
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8840
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8848
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8866
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
8867
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
8875
Assert.Equal(new
Rectangle
(expectedX, expectedY, expectedWidth, expectedHeight), control.Bounds);
8985
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
8986
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
8994
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9006
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
9007
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
9015
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9127
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9128
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9136
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
9148
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9149
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9157
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
9256
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
9257
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
9265
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9277
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
9278
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
9286
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9393
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
9394
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
9402
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9415
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
9416
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
9424
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
9548
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9549
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9557
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
9572
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9573
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9581
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
9706
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9707
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9715
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
9735
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
9736
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
9744
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
10468
Bounds = new
Rectangle
(1, 2, 3, 4)
10555
Bounds = new
Rectangle
(10, 20, 30, 40)
10559
Bounds = new
Rectangle
(1, 2, 3, 4),
10744
Bounds = new
Rectangle
(1, 2, 3, 4)
10764
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.ClientRectangle);
10765
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.DisplayRectangle);
10773
Assert.Equal(new
Rectangle
(1, 2, 3, 4), control.Bounds);
10786
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.ClientRectangle);
10787
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.DisplayRectangle);
10795
Assert.Equal(new
Rectangle
(1, 2, 3, 4), control.Bounds);
10811
Bounds = new
Rectangle
(10, 20, 30, 40)
10815
Bounds = new
Rectangle
(1, 2, 3, 4),
10842
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.ClientRectangle);
10843
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.DisplayRectangle);
10851
Assert.Equal(new
Rectangle
(1, 2, 3, 4), control.Bounds);
10868
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.ClientRectangle);
10869
Assert.Equal(new
Rectangle
(0, 0, 3, 4), control.DisplayRectangle);
10877
Assert.Equal(new
Rectangle
(1, 2, 3, 4), control.Bounds);
10954
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
10955
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
10963
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
10973
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
10974
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
10982
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11065
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11066
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11074
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11084
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11085
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11093
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11163
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
11164
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
11172
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11182
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
11183
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
11191
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11272
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11273
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11281
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11292
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11293
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11301
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11395
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11396
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11404
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11417
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11418
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11426
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11524
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11525
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11533
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11551
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
11552
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
11560
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11649
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11650
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11658
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11668
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11669
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11677
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11758
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11759
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11767
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11778
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11779
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11787
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11893
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11894
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11902
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
11915
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
11916
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
11924
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
12022
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
12023
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
12031
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
12049
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.ClientRectangle);
12050
Assert.Equal(new
Rectangle
(0, 0, clientWidth, clientHeight), control.DisplayRectangle);
12058
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
System\Windows\Forms\ControlTests.Properties.cs (229)
2477
control.Bounds = new
Rectangle
(x, y, width, height);
2479
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
2480
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2488
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2496
control.Bounds = new
Rectangle
(x, y, width, height);
2498
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
2499
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2507
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2566
control.Bounds = new
Rectangle
(x, y, width, height);
2568
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2569
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
2577
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
2585
control.Bounds = new
Rectangle
(x, y, width, height);
2587
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2588
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
2596
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
2651
control.Bounds = new
Rectangle
(x, y, width, height);
2653
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
2654
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
2662
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2670
control.Bounds = new
Rectangle
(x, y, width, height);
2672
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
2673
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
2681
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2756
control.Bounds = new
Rectangle
(x, y, width, height);
2758
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
2759
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2767
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2776
control.Bounds = new
Rectangle
(x, y, width, height);
2778
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
2779
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2787
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
2856
control.Bounds = new
Rectangle
(x, y, width, height);
2858
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2859
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
2867
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
2878
control.Bounds = new
Rectangle
(x, y, width, height);
2880
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2881
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
2889
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
2981
control.Bounds = new
Rectangle
(x, y, width, height);
2983
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2984
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
2992
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
3008
control.Bounds = new
Rectangle
(x, y, width, height);
3010
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
3011
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
3019
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
5729
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.ClientRectangle);
5730
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.DisplayRectangle);
5738
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
5748
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.ClientRectangle);
5749
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.DisplayRectangle);
5757
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
5839
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
5840
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
5848
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
5858
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
5859
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
5867
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
5927
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
5928
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
5936
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
5946
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
5947
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
5955
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
6035
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.ClientRectangle);
6036
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.DisplayRectangle);
6044
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
6055
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.ClientRectangle);
6056
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.DisplayRectangle);
6064
Assert.Equal(new
Rectangle
(0, 0, 0, value), control.Bounds);
6147
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.ClientRectangle);
6148
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.DisplayRectangle);
6156
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.Bounds);
6169
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.ClientRectangle);
6170
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.DisplayRectangle);
6178
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.Bounds);
6284
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.ClientRectangle);
6285
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.DisplayRectangle);
6293
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.Bounds);
6311
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.ClientRectangle);
6312
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.DisplayRectangle);
6320
Assert.Equal(new
Rectangle
(0, 0, 0, expectedHeight), control.Bounds);
6692
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6693
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6702
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6714
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6715
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6724
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6784
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6785
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6793
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6806
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6807
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6815
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6882
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6883
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6892
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6907
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6908
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
6917
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
6993
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
6994
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7002
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
7022
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7023
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7031
Assert.Equal(new
Rectangle
(value, 0, 0, 0), control.Bounds);
7173
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7174
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7183
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7195
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7196
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7205
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7263
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7264
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7273
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7286
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7287
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7296
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7365
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7366
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7375
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7390
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7391
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7400
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7476
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7477
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7486
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
7506
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
7507
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
7516
Assert.Equal(new
Rectangle
(value.X, value.Y, 0, 0), control.Bounds);
9871
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
11113
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
11114
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
11122
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11132
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
11133
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
11141
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11224
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11225
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11233
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
11243
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11244
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11252
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
11319
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
11320
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
11328
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11338
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
11339
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
11347
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11434
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
11435
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
11443
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11454
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
11455
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
11463
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
11551
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11552
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11560
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
11573
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11574
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11582
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
11693
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11694
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11702
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
11720
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
11721
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
11729
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
12128
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12129
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12137
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12149
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12150
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12158
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12218
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12219
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12227
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12240
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12241
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12249
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12316
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12317
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12325
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12340
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12341
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12349
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12425
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12426
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12434
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
12454
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.ClientRectangle);
12455
Assert.Equal(new
Rectangle
(0, 0, 0, 0), control.DisplayRectangle);
12463
Assert.Equal(new
Rectangle
(0, value, 0, 0), control.Bounds);
13148
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.ClientRectangle);
13149
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.DisplayRectangle);
13157
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13167
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.ClientRectangle);
13168
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.DisplayRectangle);
13176
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13258
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
13259
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
13267
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
13277
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
13278
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
13286
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
13346
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
13347
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
13355
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13365
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
13366
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
13374
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13454
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.ClientRectangle);
13455
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.DisplayRectangle);
13463
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13474
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.ClientRectangle);
13475
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.DisplayRectangle);
13483
Assert.Equal(new
Rectangle
(0, 0, value, 0), control.Bounds);
13566
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.ClientRectangle);
13567
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.DisplayRectangle);
13575
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.Bounds);
13588
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.ClientRectangle);
13589
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.DisplayRectangle);
13597
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.Bounds);
13703
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.ClientRectangle);
13704
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.DisplayRectangle);
13712
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.Bounds);
13730
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.ClientRectangle);
13731
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.DisplayRectangle);
13739
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, 0), control.Bounds);
System\Windows\Forms\CursorTests.cs (9)
201
Cursor.Clip = new
Rectangle
(1, 2, 3, 4);
210
Cursor.Clip = new
Rectangle
(0, 0, 0, 0);
365
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
366
yield return new object[] { new
Rectangle
(-1, -2, 3, 4) };
367
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
368
yield return new object[] { new
Rectangle
(0, 0, Cursors.Default.Size.Width, Cursors.Default.Size.Height) };
369
yield return new object[] { new
Rectangle
(1, 0, Cursors.Default.Size.Width, Cursors.Default.Size.Height) };
370
yield return new object[] { new
Rectangle
(0, 2, 3, Cursors.Default.Size.Height) };
371
yield return new object[] { new
Rectangle
(0, 0, Cursors.Default.Size.Width, 4) };
System\Windows\Forms\DataGridViewCellPaintingEventArgsTests.cs (16)
13
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new
Rectangle
(-1, -2, -3, -4), -1, -1, DataGridViewElementStates.Displayed, "value", "formattedValue", "", new DataGridViewCellStyle(), new DataGridViewAdvancedBorderStyle(), DataGridViewPaintParts.All };
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 0, 1, (DataGridViewElementStates)7, "value", "formattedValue", "errorText", new DataGridViewCellStyle(), new DataGridViewAdvancedBorderStyle(), DataGridViewPaintParts.All };
85
e.Paint(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None);
96
Assert.Throws<ArgumentNullException>("advancedBorderStyle", () => e.Paint(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None));
109
Assert.Throws<InvalidOperationException>(() => e.Paint(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None));
122
Assert.Throws<InvalidOperationException>(() => e.Paint(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None));
135
e.PaintBackground(new
Rectangle
(1, 2, 3, 4), true);
146
Assert.Throws<ArgumentNullException>("advancedBorderStyle", () => e.PaintBackground(new
Rectangle
(1, 2, 3, 4), true));
159
Assert.Throws<InvalidOperationException>(() => e.PaintBackground(new
Rectangle
(1, 2, 3, 4), true));
172
Assert.Throws<InvalidOperationException>(() => e.PaintBackground(new
Rectangle
(1, 2, 3, 4), true));
185
e.PaintContent(new
Rectangle
(1, 2, 3, 4));
196
Assert.Throws<ArgumentNullException>("advancedBorderStyle", () => e.PaintContent(new
Rectangle
(1, 2, 3, 4)));
209
Assert.Throws<InvalidOperationException>(() => e.PaintContent(new
Rectangle
(1, 2, 3, 4)));
222
Assert.Throws<InvalidOperationException>(() => e.PaintContent(new
Rectangle
(1, 2, 3, 4)));
System\Windows\Forms\DataGridViewCellTests.cs (30)
3146
yield return new object[] { new DataGridViewAdvancedBorderStyle(), new
Rectangle
(0, 0, 0, 0) };
3150
new
Rectangle
(0, 0, 0, 0)
3158
new
Rectangle
(2, 2, 2, 2)
3166
new
Rectangle
(2, 2, 2, 2)
3174
new
Rectangle
(1, 1, 1, 1)
3182
new
Rectangle
(1, 0, 0, 0)
3190
new
Rectangle
(0, 0, 1, 0)
3198
new
Rectangle
(0, 1, 0, 0)
3206
new
Rectangle
(0, 0, 0, 1)
3228
Assert.Equal(new
Rectangle
(expected.X, expected.Y, expected.Width, expected.Height + 10), cell.BorderWidths(advancedBorderStyle));
3241
Assert.Equal(new
Rectangle
(expected.X, expected.Y, expected.Width + 10, expected.Height), cell.BorderWidths(advancedBorderStyle));
3259
Assert.Equal(new
Rectangle
(expected.X, expected.Y, expected.Width + 10, expected.Height + 11), cell.BorderWidths(advancedBorderStyle));
3280
Assert.Equal(new
Rectangle
(expected.X + 10, expected.Y, expected.Width, expected.Height + 11), cell.BorderWidths(advancedBorderStyle));
3296
Assert.Equal(new
Rectangle
(expected.X, expected.Y, expected.Width + 10, expected.Height), cell.BorderWidths(advancedBorderStyle));
6029
cell.PaintBorder(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), new DataGridViewCellStyle(), new DataGridViewAdvancedBorderStyle());
6036
Assert.Throws<ArgumentNullException>("graphics", () => cell.PaintBorder(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), new DataGridViewCellStyle(), new DataGridViewAdvancedBorderStyle()));
6045
Assert.Throws<ArgumentNullException>("cellStyle", () => cell.PaintBorder(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), null, new DataGridViewAdvancedBorderStyle()));
6055
cell.PaintErrorIcon(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 20, 19), errorText);
6065
cell.PaintErrorIcon(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 20, 19), errorText);
6081
Assert.Throws<ArgumentNullException>("graphics", () => cell.PaintErrorIcon(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, cellValueBoundsWidth, cellValueBoundsHeight), errorText));
6229
Assert.Throws<InvalidOperationException>(() => cell.PositionEditingControl(true, true, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), new DataGridViewCellStyle(), true, true, true, true));
6236
Assert.Throws<InvalidOperationException>(() => cell.PositionEditingPanel(new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), new DataGridViewCellStyle(), true, true, true, true));
System\Windows\Forms\DataGridViewRowPostPaintEventArgsTests.cs (14)
13
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new
Rectangle
(-1, -2, -3, -4), -1, DataGridViewElementStates.Displayed, "", new DataGridViewCellStyle(), true, false };
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 0, (DataGridViewElementStates)7, "errorText", new DataGridViewCellStyle(), true, true };
64
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
65
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
90
e.DrawFocus(new
Rectangle
(1, 2, 3, 4), true);
103
Assert.Throws<InvalidOperationException>(() => e.DrawFocus(new
Rectangle
(1, 2, 3, 4), true));
114
e.PaintCells(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None);
127
Assert.Throws<InvalidOperationException>(() => e.PaintCells(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None));
138
e.PaintCellsBackground(new
Rectangle
(1, 2, 3, 4), true);
151
Assert.Throws<InvalidOperationException>(() => e.PaintCellsBackground(new
Rectangle
(1, 2, 3, 4), true));
162
e.PaintCellsContent(new
Rectangle
(1, 2, 3, 4));
175
Assert.Throws<InvalidOperationException>(() => e.PaintCellsContent(new
Rectangle
(1, 2, 3, 4)));
System\Windows\Forms\DataGridViewRowPrePaintEventArgsTests.cs (14)
16
yield return new object[] { new DataGridView(), graphics, new
Rectangle
(-1, -2, -3, -4), new
Rectangle
(-1, -2, -3, -4), -1, DataGridViewElementStates.Displayed, "", new DataGridViewCellStyle(), true, false };
17
yield return new object[] { new DataGridView(), graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 0, (DataGridViewElementStates)7, "errorText", new DataGridViewCellStyle(), true, true };
65
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
66
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
117
e.DrawFocus(new
Rectangle
(1, 2, 3, 4), true);
130
Assert.Throws<InvalidOperationException>(() => e.DrawFocus(new
Rectangle
(1, 2, 3, 4), true));
141
e.PaintCells(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None);
154
Assert.Throws<InvalidOperationException>(() => e.PaintCells(new
Rectangle
(1, 2, 3, 4), DataGridViewPaintParts.None));
165
e.PaintCellsBackground(new
Rectangle
(1, 2, 3, 4), true);
178
Assert.Throws<InvalidOperationException>(() => e.PaintCellsBackground(new
Rectangle
(1, 2, 3, 4), true));
189
e.PaintCellsContent(new
Rectangle
(1, 2, 3, 4));
202
Assert.Throws<InvalidOperationException>(() => e.PaintCellsContent(new
Rectangle
(1, 2, 3, 4)));
System\Windows\Forms\DataGridViewRowTests.cs (75)
4186
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), 1, DataGridViewElementStates.Selected, new DataGridViewCellStyle { BackColor = Color.Blue, SelectionBackColor = Color.Red }, true };
4187
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), 1, DataGridViewElementStates.Selected, new DataGridViewCellStyle { BackColor = Color.Blue, SelectionBackColor = Color.Red }, true };
4188
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), 1, DataGridViewElementStates.None, new DataGridViewCellStyle { BackColor = Color.Blue, SelectionBackColor = Color.Red }, true };
4189
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), 1, DataGridViewElementStates.None, new DataGridViewCellStyle { BackColor = Color.Blue, SelectionBackColor = Color.Red }, false };
4215
Assert.Throws<InvalidOperationException>(() => row.DrawFocus(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), -1, DataGridViewElementStates.None, new DataGridViewCellStyle(), true));
4229
Assert.Throws<ArgumentNullException>("graphics", () => row.DrawFocus(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), -1, DataGridViewElementStates.None, new DataGridViewCellStyle(), true));
4245
Assert.Throws<ArgumentNullException>("cellStyle", () => row.DrawFocus(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), -1, DataGridViewElementStates.None, null, true));
4569
yield return new object[] { new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), 0, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, true, false };
4570
yield return new object[] { new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), 0, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, false, true };
4571
yield return new object[] { new
Rectangle
(1000, 2000, 100, 100), new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, true, false };
4813
Assert.Equal(new
Rectangle
(1, 2, 3, 4), e.ClipBounds);
4814
Assert.Equal(new
Rectangle
(2, 3, 4, 5), e.RowBounds);
4829
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4833
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4838
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4857
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4861
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4866
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4890
Assert.Equal(new
Rectangle
(1, 2, 3, 4), e.ClipBounds);
4891
Assert.Equal(new
Rectangle
(2, 3, 4, 5), e.RowBounds);
4899
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4903
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4908
row.Paint(graphics, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false);
4927
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4931
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4935
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, Rectangle.Empty, new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4940
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, Rectangle.Empty, new
Rectangle
(2, 3, 4, 5), 1, DataGridViewElementStates.Frozen, true, false));
4969
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, Rectangle.Empty, new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.None, true, true));
4983
Assert.Throws<ArgumentNullException>("graphics", () => row.Paint(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.None, true, true));
5009
Assert.Throws<ArgumentOutOfRangeException>("index", () => row.Paint(graphics, new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), rowIndex, DataGridViewElementStates.None, true, true));
5015
yield return new object[] { new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), 0, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, true, false, DataGridViewPaintParts.All };
5016
yield return new object[] { new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), 0, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, false, true, DataGridViewPaintParts.None };
5017
yield return new object[] { new
Rectangle
(1000, 2000, 100, 100), new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.Displayed | DataGridViewElementStates.Displayed, true, false, DataGridViewPaintParts.All };
5264
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintCells(null, Rectangle.Empty, new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5278
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintCells(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 100, 100), -1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5292
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintCells(null, new
Rectangle
(1, 2, 1000, 10000), new
Rectangle
(1, 2, 1000, 1000), 1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5319
Assert.Throws<ArgumentOutOfRangeException>("rowIndex", () => row.PaintCells(graphics, new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), rowIndex, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5586
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintHeader(null, Rectangle.Empty, new
Rectangle
(1, 2, 100, 100), -1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5601
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintHeader(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 100, 100), 1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5616
Assert.Throws<ArgumentNullException>("graphics", () => row.PaintHeader(null, new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), -1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5641
Assert.Throws<ArgumentOutOfRangeException>("rowIndex", () => row.PaintHeader(graphics, new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), rowIndex, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
5657
Assert.Throws<InvalidOperationException>(() => row.PaintHeader(graphics, new
Rectangle
(1, 2, 100, 100), new
Rectangle
(1, 2, 100, 100), -1, DataGridViewElementStates.None, true, true, DataGridViewPaintParts.All));
System\Windows\Forms\DataGridViewTests.Rendering.cs (1)
35
Assert.Equal(new
Rectangle
(0, 0, 240, 150), dataGrid.Bounds);
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (3)
39
Assert.Equal(new
Rectangle
(0, 0, 100, control.PreferredHeight), control.Bounds);
48
Assert.Equal(new
Rectangle
(0, 0, 96, control.PreferredHeight - 4), control.ClientRectangle);
64
Assert.Equal(new
Rectangle
(0, 0, 96, control.PreferredHeight - 4), control.DisplayRectangle);
System\Windows\Forms\DateTimePickerTests.cs (3)
36
Assert.Equal(new
Rectangle
(0, 0, 200, control.PreferredHeight), control.Bounds);
51
Assert.Equal(new
Rectangle
(0, 0, 196, control.PreferredHeight - 4), control.ClientRectangle);
68
Assert.Equal(new
Rectangle
(0, 0, 196, control.PreferredHeight - 4), control.DisplayRectangle);
System\Windows\Forms\Design\ComponentEditorFormTests.cs (5)
48
Assert.Equal(new
Rectangle
(0, 0, control.Width, control.Height), control.Bounds);
56
Assert.Equal(new
Rectangle
(0, 0, control.ClientSize.Width, control.ClientSize.Height), control.ClientRectangle);
76
Assert.Equal(new
Rectangle
(-SystemInformation.WorkingArea.X, -SystemInformation.WorkingArea.Y, control.Width, control.Height), control.DesktopBounds);
79
Assert.Equal(new
Rectangle
(0, 0, control.ClientSize.Width, control.ClientSize.Height), control.DisplayRectangle);
136
Assert.Equal(new
Rectangle
(-1, -1, control.Width, control.Height), control.RestoreBounds);
System\Windows\Forms\Design\ComponentEditorPageTests.cs (3)
36
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
62
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
System\Windows\Forms\DomainUpDownTests.cs (5)
49
_sub.Bounds.Should().Be(new
Rectangle
(0, 0, 120, _sub.PreferredHeight));
57
_sub.ClientRectangle.Should().Be(new
Rectangle
(0, 0, 120, Control.DefaultFont.Height + 7));
58
_sub.DisplayRectangle.Should().Be(new
Rectangle
(0, 0, 120, Control.DefaultFont.Height + 7));
64
_sub.ClientRectangle.Should().Be(new
Rectangle
(0, 0, 116, Control.DefaultFont.Height + 3));
65
_sub.DisplayRectangle.Should().Be(new
Rectangle
(0, 0, 116, Control.DefaultFont.Height + 3));
System\Windows\Forms\DrawItemEventArgsTests.cs (22)
14
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), -1, DrawItemState.None, SystemColors.WindowText, SystemColors.Window };
15
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(-1, 2, -3, -4), 0, DrawItemState.Selected, SystemColors.HighlightText, SystemColors.Highlight };
16
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Focus, SystemColors.WindowText, SystemColors.Window };
17
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Focus | DrawItemState.NoFocusRect, SystemColors.WindowText, SystemColors.Window };
39
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), -1, DrawItemState.None, Color.Red, Color.Blue };
40
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(-1, 2, -3, -4), 0, DrawItemState.Selected, Color.Red, Color.Blue };
41
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Focus, Color.Red, Color.Blue };
42
yield return new object[] { SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 1, DrawItemState.Focus | DrawItemState.NoFocusRect, Color.Red, Color.Blue };
65
Assert.Throws<ArgumentNullException>("graphics", () => new DrawItemEventArgs(null, SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 0, DrawItemState.None));
66
Assert.Throws<ArgumentNullException>("graphics", () => new DrawItemEventArgs(null, SystemFonts.DefaultFont, new
Rectangle
(1, 2, 3, 4), 0, DrawItemState.None, Color.Red, Color.Blue));
71
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.None };
72
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.Selected };
73
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.Focus };
74
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.Focus | DrawItemState.Selected };
75
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.Focus | DrawItemState.NoFocusRect };
76
yield return new object[] { new
Rectangle
(1, 2, 3, 4), DrawItemState.Focus | DrawItemState.NoFocusRect | DrawItemState.Selected };
77
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.None };
78
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.Selected };
79
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.Focus };
80
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.Focus | DrawItemState.Selected };
81
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.Focus | DrawItemState.NoFocusRect };
82
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), DrawItemState.Focus | DrawItemState.NoFocusRect | DrawItemState.Selected };
System\Windows\Forms\DrawListViewColumnHeaderEventArgsTests.cs (12)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), -1, new ColumnHeader(), ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont };
15
yield return new object[] { new
Rectangle
(-1, 2, -3, -4), 0, new ColumnHeader(), ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont };
16
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1, new ColumnHeader(), ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont };
40
Assert.Throws<ArgumentNullException>("graphics", () => new DrawListViewColumnHeaderEventArgs(null, new
Rectangle
(1, 2, 3, 4), 0, new ColumnHeader(), ListViewItemStates.Default, Color.Red, Color.Blue, SystemFonts.DefaultFont));
49
DrawListViewColumnHeaderEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4), -1, new ColumnHeader(), ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont)
66
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ColumnHeader(), ListViewItemStates.Default, Color.Red, Color.Blue, SystemFonts.DefaultFont };
67
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ColumnHeader(), ListViewItemStates.Default, Color.Red, Color.Blue, SystemFonts.DefaultFont };
68
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ColumnHeader(), ListViewItemStates.Default, Color.Red, Color.Blue, SystemFonts.DefaultFont };
90
DrawListViewColumnHeaderEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4), -1, header, ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont);
99
DrawListViewColumnHeaderEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4), -1, new ColumnHeader(), ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont);
105
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), 0, ListViewItemStates.Default, Color.Empty, Color.Empty, null };
106
yield return new object[] { new
Rectangle
(1, 2, 3, 4), -1, ListViewItemStates.Checked, Color.Red, Color.Blue, SystemFonts.DefaultFont };
System\Windows\Forms\DrawListViewItemEventArgsTests.cs (21)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), -1, ListViewItemStates.Checked };
15
yield return new object[] { new
Rectangle
(-1, 2, -3, -4), 0, ListViewItemStates.Focused };
16
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1, ListViewItemStates.Checked };
38
Assert.Throws<ArgumentNullException>("graphics", () => new DrawListViewItemEventArgs(null, new ListViewItem(), new
Rectangle
(1, 2, 3, 4), 0, ListViewItemStates.Default));
46
Assert.Throws<ArgumentNullException>("item", () => new DrawListViewItemEventArgs(graphics, null, new
Rectangle
(1, 2, 3, 4), 0, ListViewItemStates.Default));
55
DrawListViewItemEventArgs e = new(graphics, new ListViewItem(), new
Rectangle
(1, 2, 3, 4), -1, ListViewItemStates.Checked)
72
yield return new object[] { new ListViewItem(), new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Default };
73
yield return new object[] { new ListViewItem(), new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Focused };
74
yield return new object[] { new ListViewItem(), new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Checked };
78
yield return new object[] { new ListViewItem(), new
Rectangle
(-1, -2, -3, -4), ListViewItemStates.Default };
79
yield return new object[] { new ListViewItem(), new
Rectangle
(-1, -2, -3, -4), ListViewItemStates.Focused };
80
yield return new object[] { new ListViewItem(), new
Rectangle
(-1, -2, -3, -4), ListViewItemStates.Checked };
87
yield return new object[] { listViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Default };
88
yield return new object[] { listViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Focused };
89
yield return new object[] { listViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Checked };
94
yield return new object[] { subItemsItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Default };
95
yield return new object[] { subItemsItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Focused };
96
yield return new object[] { subItemsItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Checked };
102
yield return new object[] { fullRowSelectListViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Default };
103
yield return new object[] { fullRowSelectListViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Focused };
104
yield return new object[] { fullRowSelectListViewItem, new
Rectangle
(1, 2, 3, 4), ListViewItemStates.Checked };
System\Windows\Forms\DrawListViewSubItemEventArgsTests.cs (33)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, -1, new ColumnHeader(), ListViewItemStates.Checked };
15
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), new ListViewItem.ListViewSubItem(), -1, -1, new ColumnHeader(), ListViewItemStates.Checked };
16
yield return new object[] { new
Rectangle
(-1, 2, -3, -4), new ListViewItem(), new ListViewItem.ListViewSubItem(), 0, 0, new ColumnHeader(), ListViewItemStates.Focused };
17
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), new ListViewItem.ListViewSubItem(), 1, 2, new ColumnHeader(), ListViewItemStates.Checked };
41
Assert.Throws<ArgumentNullException>("graphics", () => new DrawListViewSubItemEventArgs(null, new
Rectangle
(1, 2, 3, 4), new ListViewItem(), new ListViewItem.ListViewSubItem(), -1, 0, new ColumnHeader(), ListViewItemStates.Default));
49
Assert.Throws<ArgumentNullException>("item", () => new DrawListViewSubItemEventArgs(graphics, new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), -1, 0, new ColumnHeader(), ListViewItemStates.Default));
59
Assert.Throws<ArgumentNullException>("subItem", () => new DrawListViewSubItemEventArgs(graphics, new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, itemIndex, 0, new ColumnHeader(), ListViewItemStates.Default));
68
DrawListViewSubItemEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, -1, new ColumnHeader(), ListViewItemStates.Checked)
85
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, null, ListViewItemStates.Default };
86
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, null, ListViewItemStates.Checked };
87
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, null, ListViewItemStates.Focused };
88
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Default };
89
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Checked };
90
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Focused };
91
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, null, ListViewItemStates.Default };
92
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, null, ListViewItemStates.Checked };
93
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, null, ListViewItemStates.Focused };
94
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Default };
95
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Checked };
96
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new ListViewItem(), null, -1, new ColumnHeader(), ListViewItemStates.Focused };
98
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Default };
99
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Checked };
100
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Focused };
101
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Default };
102
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Checked };
103
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Focused };
104
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Default };
105
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Checked };
106
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, null, ListViewItemStates.Focused };
107
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Default };
108
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Checked };
109
yield return new object[] { new
Rectangle
(1, 2, 3, 4), null, new ListViewItem.ListViewSubItem(), 0, new ColumnHeader(), ListViewItemStates.Focused };
129
e.DrawFocusRectangle(new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\DrawToolTipEventArgsTests.cs (8)
14
yield return new object[] { new Mock<IWin32Window>(MockBehavior.Strict).Object, new Button(), new
Rectangle
(1, 2, 3, 4), "", Color.Red, Color.Blue, SystemFonts.DefaultFont };
15
yield return new object[] { new Mock<IWin32Window>(MockBehavior.Strict).Object, new Button(), new
Rectangle
(-1, -2, -3, -4), "toolTipText", Color.Red, Color.Blue, SystemFonts.DefaultFont };
35
yield return new object[] { null, null, new
Rectangle
(-1, -2, -3, -4), null, Color.Empty, Color.Empty, null };
36
yield return new object[] { null, null, new
Rectangle
(-1, -2, -3, -4), string.Empty, Color.Empty, Color.Empty, null };
37
yield return new object[] { null, null, new
Rectangle
(-1, -2, -3, -4), "tooltipText", Color.Empty, Color.Empty, null };
38
yield return new object[] { new SubWin32Window(), new Button(), new
Rectangle
(1, 2, 3, 4), null, Color.Red, Color.Blue, SystemFonts.DefaultFont };
39
yield return new object[] { new SubWin32Window(), new Button(), new
Rectangle
(1, 2, 3, 4), string.Empty, Color.Red, Color.Blue, SystemFonts.DefaultFont };
40
yield return new object[] { new SubWin32Window(), new Button(), new
Rectangle
(1, 2, 3, 4), "tooltipText", Color.Red, Color.Blue, SystemFonts.DefaultFont };
System\Windows\Forms\DrawTreeNodeEventArgsTests.cs (3)
14
yield return new object[] { new TreeNode(), new
Rectangle
(1, 2, 3, 4), TreeNodeStates.Checked };
15
yield return new object[] { new TreeNode(), new
Rectangle
(-1, -2, -3, -4), TreeNodeStates.Checked };
38
DrawTreeNodeEventArgs e = new(graphics, new TreeNode(), new
Rectangle
(1, 2, 3, 4), TreeNodeStates.Checked)
System\Windows\Forms\FlowLayoutPanelTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
42
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
59
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
System\Windows\Forms\FormTests.cs (4)
46
Assert.Equal(new
Rectangle
(0, 0, 300, 300), control.Bounds);
54
Assert.Equal(new
Rectangle
(0, 0, control.ClientSize.Width, control.ClientSize.Height), control.ClientRectangle);
75
Assert.Equal(new
Rectangle
(-SystemInformation.WorkingArea.X, -SystemInformation.WorkingArea.Y, 300, 300), control.DesktopBounds);
138
Assert.Equal(new
Rectangle
(0, 0, 300, 300), control.RestoreBounds);
System\Windows\Forms\GroupBoxTests.cs (11)
32
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
40
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
56
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
569
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
578
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
582
Assert.Equal(new
Rectangle
(3, font.Height + 3, 194, 94 - font.Height), control.DisplayRectangle);
595
Assert.Equal(new
Rectangle
(3, font.Height + 3, 194, 94 - font.Height), control.DisplayRectangle);
1515
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
1523
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
1563
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
1574
Assert.Equal(new
Rectangle
(3, Control.DefaultFont.Height + 3, 194, 94 - Control.DefaultFont.Height), control.DisplayRectangle);
System\Windows\Forms\InvalidateEventArgsTests.cs (2)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
15
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
System\Windows\Forms\LabelTests.cs (3)
32
Assert.Equal(new
Rectangle
(0, 0, 100, 23), control.Bounds);
40
Assert.Equal(new
Rectangle
(0, 0, 100, 23), control.ClientRectangle);
56
Assert.Equal(new
Rectangle
(0, 0, 100, 23), control.DisplayRectangle);
System\Windows\Forms\Layout\FlowLayoutTests.cs (28)
84
Assert.Equal(new
Rectangle
(0, 0, 10, 20), child1.Bounds);
85
Assert.Equal(new
Rectangle
(11, 2, 10, 20), child2.Bounds);
86
Assert.Equal(new
Rectangle
(24, 0, 100, 200), largeChild.Bounds);
87
Assert.Equal(new
Rectangle
(127, 3, 0, 0), emptyChild.Bounds);
88
Assert.Equal(new
Rectangle
(131, 2, 0, 0), emptyChildWithMargin.Bounds);
89
Assert.Equal(new
Rectangle
(134, 0, 50, 100), child3.Bounds);
90
Assert.Equal(new
Rectangle
(184, 0, 10, 20), child4.Bounds);
145
Assert.Equal(new
Rectangle
(190, 0, 10, 20), child1.Bounds);
146
Assert.Equal(new
Rectangle
(177, 2, 10, 20), child2.Bounds);
147
Assert.Equal(new
Rectangle
(76, 0, 100, 200), largeChild.Bounds);
148
Assert.Equal(new
Rectangle
(73, 3, 0, 0), emptyChild.Bounds);
149
Assert.Equal(new
Rectangle
(67, 2, 0, 0), emptyChildWithMargin.Bounds);
150
Assert.Equal(new
Rectangle
(16, 0, 50, 100), child3.Bounds);
151
Assert.Equal(new
Rectangle
(6, 0, 10, 20), child4.Bounds);
206
Assert.Equal(new
Rectangle
(0, 0, 10, 20), child1.Bounds);
207
Assert.Equal(new
Rectangle
(1, 22, 10, 20), child2.Bounds);
208
Assert.Equal(new
Rectangle
(14, 0, 100, 200), largeChild.Bounds);
209
Assert.Equal(new
Rectangle
(117, 3, 0, 0), emptyChild.Bounds);
210
Assert.Equal(new
Rectangle
(115, 8, 0, 0), emptyChildWithMargin.Bounds);
211
Assert.Equal(new
Rectangle
(120, 0, 50, 100), child3.Bounds);
212
Assert.Equal(new
Rectangle
(170, 0, 10, 20), child4.Bounds);
267
Assert.Equal(new
Rectangle
(0, 80, 10, 20), child1.Bounds);
268
Assert.Equal(new
Rectangle
(1, 56, 10, 20), child2.Bounds);
269
Assert.Equal(new
Rectangle
(14, -100, 100, 200), largeChild.Bounds);
270
Assert.Equal(new
Rectangle
(117, 97, 0, 0), emptyChild.Bounds);
271
Assert.Equal(new
Rectangle
(115, 90, 0, 0), emptyChildWithMargin.Bounds);
272
Assert.Equal(new
Rectangle
(120, 0, 50, 100), child3.Bounds);
273
Assert.Equal(new
Rectangle
(170, 80, 10, 20), child4.Bounds);
System\Windows\Forms\ListBoxTests.cs (5)
33
Assert.Equal(new
Rectangle
(0, 0, 120, 96), control.Bounds);
41
Assert.Equal(new
Rectangle
(0, 0, 116, 92), control.ClientRectangle);
63
Assert.Equal(new
Rectangle
(0, 0, 116, 92), control.DisplayRectangle);
5385
yield return new object[] { new RECT(1, 2, 3, 4), new
Rectangle
(1, 2, 2, 2) };
5520
yield return new object[] { new DrawItemEventArgs(graphics, null, new
Rectangle
(1, 2, 3, 4), 0, DrawItemState.Checked) };
System\Windows\Forms\ListViewInsertionMarkTests.cs (2)
216
yield return new object[] { new RECT(1, 2, 3, 4), new
Rectangle
(1, 2, 2, 2) };
258
Assert.Equal(new
Rectangle
(1, 2, 2, 2), insertionMark.Bounds);
System\Windows\Forms\ListViewTests.cs (4)
40
Assert.Equal(new
Rectangle
(0, 0, 121, 97), control.Bounds);
53
Assert.Equal(new
Rectangle
(0, 0, 117, 93), control.ClientRectangle);
71
Assert.Equal(new
Rectangle
(0, 0, 117, 93), control.DisplayRectangle);
4144
yield return new object[] { new RECT(1, 2, 3, 4), new
Rectangle
(1, 2, 2, 2) };
System\Windows\Forms\MdiClientTests.cs (18)
538
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
539
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
547
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
557
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
558
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
566
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
640
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
641
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
649
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
662
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
663
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
671
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
1088
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
1089
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
1097
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
1115
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.ClientRectangle);
1116
Assert.Equal(new
Rectangle
(0, 0, expectedClientWidth, expectedClientHeight), control.DisplayRectangle);
1124
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.Bounds);
System\Windows\Forms\MdiControlStripTests.cs (3)
37
Assert.Equal(new
Rectangle
(0, 0, 200, 24), mdiControlStrip.Bounds);
45
Assert.Equal(new
Rectangle
(0, 0, 200, 24), mdiControlStrip.ClientRectangle);
68
Assert.Equal(new
Rectangle
(6, 2, 194, 20), mdiControlStrip.DisplayRectangle);
System\Windows\Forms\MenuStripTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, 200, 24), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, 200, 24), control.ClientRectangle);
66
Assert.Equal(new
Rectangle
(6, 2, 194, 20), control.DisplayRectangle);
System\Windows\Forms\MonthCalendarTests.cs (1)
4329
Rectangle expectedBounds =
new
(13, 42, 16, 16);
System\Windows\Forms\PaintEventArgsTests.cs (5)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
15
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
33
Assert.Throws<ArgumentNullException>("graphics", () => new PaintEventArgs((Graphics)null, new
Rectangle
(1, 2, 3, 4)));
41
PaintEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4));
53
using SubPaintEventArgs e = new(graphics, new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\PanelTests.cs (3)
36
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
60
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
System\Windows\Forms\PictureBoxTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, 100, 50), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, 100, 50), control.ClientRectangle);
59
Assert.Equal(new
Rectangle
(0, 0, 100, 50), control.DisplayRectangle);
System\Windows\Forms\ProgressBarRendererTest.cs (1)
69
Rectangle rectangle1 =
new
(0, 0, 50, 50);
System\Windows\Forms\ProgressBarTests.cs (2)
31
Assert.Equal(new
Rectangle
(0, 0, 100, 23), control.Bounds);
38
Assert.Equal(new
Rectangle
(0, 0, 100, 23), control.ClientRectangle);
System\Windows\Forms\PropertyGridInternal\PropertyGridViewTests.Rendering.cs (7)
42
Validate.TextOut("Misc",
new
(25, 4, 25, 14), stateValidators: State.FontFace(Control.DefaultFont.Name))),
46
Validate.TextOut(" ",
new
(145, 22, 5, 14))), // blank??
48
Validate.TextOut(pt.X.ToString(),
new
(145, 22, 5, 14), stateValidators: State.FontFace(Control.DefaultFont.Name))),
51
Validate.TextOut(nameof(Point.X),
new
(25, 23, 6, 14), stateValidators: State.FontFace(Control.DefaultFont.Name))),
55
Validate.TextOut(" ",
new
(145, 41, 5, 14))), // blank??
57
Validate.TextOut(pt.Y.ToString(),
new
(145, 41, 5, 14), stateValidators: State.FontFace(Control.DefaultFont.Name))),
60
Validate.TextOut(nameof(Point.Y),
new
(25, 42, 6, 14), stateValidators: State.FontFace(Control.DefaultFont.Name))),
System\Windows\Forms\PropertyGridTests.cs (3)
46
Assert.Equal(new
Rectangle
(0, 0, 130, 130), control.Bounds);
59
Assert.Equal(new
Rectangle
(0, 0, 130, 130), control.ClientRectangle);
88
Assert.Equal(new
Rectangle
(0, 0, 130, 130), control.DisplayRectangle);
System\Windows\Forms\PropertyStoreTests.cs (3)
160
Rectangle one =
new
(1, 2, 3, 4);
161
Rectangle two =
new
(5, 6, 7, 8);
176
Rectangle one =
new
(1, 2, 3, 4);
System\Windows\Forms\RadioButtonRendererTests.cs (2)
71
bounds: new
Rectangle
(41, 5, 20, 12),
137
bounds: new
Rectangle
(3, 0, 20, 12),
System\Windows\Forms\RadioButtonTests.cs (3)
35
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.Bounds);
45
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.ClientRectangle);
61
Assert.Equal(new
Rectangle
(0, 0, 104, 24), control.DisplayRectangle);
System\Windows\Forms\RichTextBoxTests.cs (11)
43
Assert.Equal(new
Rectangle
(0, 0, 100, 96), control.Bounds);
54
Assert.Equal(new
Rectangle
(0, 0, 96, 92), control.ClientRectangle);
71
Assert.Equal(new
Rectangle
(0, 0, 96, 92), control.DisplayRectangle);
10322
yield return new object[] { BorderStyle.Fixed3D, Rectangle.Empty, new
Rectangle
(0, 0, 0, 1) };
10326
yield return new object[] { BorderStyle.Fixed3D, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 5) };
10327
yield return new object[] { BorderStyle.FixedSingle, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
10328
yield return new object[] { BorderStyle.None, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
10663
richTextBox1.DrawToBitmap(bitmap1, new
Rectangle
(0, 0, 10, 10));
System\Windows\Forms\ScreenTests.cs (4)
124
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
125
yield return new object[] { new
Rectangle
(0, 0, 0, 0) };
126
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
127
yield return new object[] { new
Rectangle
(int.MaxValue, int.MaxValue, int.MaxValue, int.MaxValue) };
System\Windows\Forms\ScrollableControlTests.cs (44)
199
yield return new object[] { true, width, height, width - 20, height + 50, new
Rectangle
(0, 0, width - SystemInformation.VerticalScrollBarWidth, height) };
200
yield return new object[] { true, width, height, width + 50, height - 20, new
Rectangle
(0, 0, width, height - SystemInformation.HorizontalScrollBarHeight) };
201
yield return new object[] { true, width, height, width + 50, height + 50, new
Rectangle
(0, 0, width - SystemInformation.VerticalScrollBarWidth, height - SystemInformation.HorizontalScrollBarHeight) };
202
yield return new object[] { true, width, height, width - 20, height - 20, new
Rectangle
(0, 0, width, height) };
205
yield return new object[] { false, width, height, width + 50, height - 20, new
Rectangle
(0, 0, width, height) };
206
yield return new object[] { false, width, height, width - 20, height + 50, new
Rectangle
(0, 0, width, height) };
207
yield return new object[] { false, width, height, width + 50, height + 50, new
Rectangle
(0, 0, width, height) };
208
yield return new object[] { false, width, height, width - 20, height - 20, new
Rectangle
(0, 0, width, height) };
717
Assert.Equal(new
Rectangle
(1, 2, 66, 74), control.DisplayRectangle);
720
Assert.Equal(new
Rectangle
(1, 2, 66, 74), control.DisplayRectangle);
1532
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1570
Bounds = new
Rectangle
(1, 2, 30, 40)
1574
Bounds = new
Rectangle
(1, 2, 30, 40)
1665
Bounds = new
Rectangle
(1, 2, 30, 40)
1669
Bounds = new
Rectangle
(1, 2, 30, 40)
1679
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1683
Bounds = new
Rectangle
(1, 2, 10, 20),
1704
Assert.Equal(new
Rectangle
(1, 2, 0, 0), e.ClipRectangle);
1731
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1819
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1823
Bounds = new
Rectangle
(1, 2, 30, 40)
1827
Bounds = new
Rectangle
(1, 2, 10, 20),
1848
Assert.Equal(new
Rectangle
(1, 2, 10, 20), e.ClipRectangle);
2335
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2403
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
2481
yield return new object[] { true, true, true, new Size(70, 80), null, new
Rectangle
(0, 0, 70, 80) };
2482
yield return new object[] { false, true, true, new Size(70, 80), null, new
Rectangle
(0, 0, 70, 80) };
2484
yield return new object[] { true, true, true, new Size(70, 80), new Control(), new
Rectangle
(0, 0, 70, 80) };
2487
yield return new object[] { false, true, true, new Size(70, 80), new LargeControl(), new
Rectangle
(0, 0, 70, 80) };
2490
yield return new object[] { true, false, false, new Size(70, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2493
yield return new object[] { true, false, false, new Size(0, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2494
yield return new object[] { true, false, false, new Size(-1, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2495
yield return new object[] { true, false, false, new Size(70, 0), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2496
yield return new object[] { true, false, false, new Size(70, -1), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2499
yield return new object[] { true, true, false, new Size(70, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2500
yield return new object[] { true, false, true, new Size(70, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2501
yield return new object[] { true, true, true, new Size(70, 80), new LargeControl(), new
Rectangle
(0, 0, 100, 150) };
2503
yield return new object[] { true, true, false, new Size(70, 80), new SmallControl(), new
Rectangle
(0, 0, 70, 80) };
2504
yield return new object[] { true, false, true, new Size(70, 80), new SmallControl(), new
Rectangle
(0, 0, 70, 80) };
2505
yield return new object[] { true, true, true, new Size(70, 80), new SmallControl(), new
Rectangle
(0, 0, 70, 80) };
2512
yield return new object[] { true, true, true, new Size(70, 80), parentControl, new
Rectangle
(0, 0, 100, 150) };
2513
yield return new object[] { true, hScroll, true, new Size(70, 80), childControl, new
Rectangle
(0, 0, 100, 150) };
2521
yield return new object[] { true, true, true, new Size(70, 80), parentControl, new
Rectangle
(0, 0, 100, 150) };
2522
yield return new object[] { true, true, vScroll, new Size(70, 80), childControl, new
Rectangle
(0, 0, 100, 150) };
System\Windows\Forms\ScrollBarTests.cs (80)
1774
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 0, 4) };
1775
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
1776
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
1777
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 0, 4) };
1778
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
1780
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
1781
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
1782
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
1783
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
1784
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
1786
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 6, 4) };
1787
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
1788
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
1789
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 6, 4) };
1790
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
1792
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, -6, 4) };
1793
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
1794
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
1795
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, -6, 4) };
1796
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
1822
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.All, new
Rectangle
(0, 0, 3, 0) };
1823
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.X, new
Rectangle
(0, 2, 3, 4) };
1824
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Y, new
Rectangle
(1, 0, 3, 4) };
1825
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
1826
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(0, 0), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 0) };
1828
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.All, new
Rectangle
(1, 2, 3, 4) };
1829
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.X, new
Rectangle
(1, 2, 3, 4) };
1830
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Y, new
Rectangle
(1, 2, 3, 4) };
1831
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
1832
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(1, 1), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 4) };
1834
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.All, new
Rectangle
(2, 6, 3, 12) };
1835
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.X, new
Rectangle
(2, 2, 3, 4) };
1836
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Y, new
Rectangle
(1, 6, 3, 4) };
1837
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
1838
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(2, 3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, 12) };
1840
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.All, new
Rectangle
(-2, -6, 3, -12) };
1841
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.X, new
Rectangle
(-2, 2, 3, 4) };
1842
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Y, new
Rectangle
(1, -6, 3, 4) };
1843
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Width, new
Rectangle
(1, 2, 3, 4) };
1844
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new Size(-2, -3), BoundsSpecified.Height, new
Rectangle
(1, 2, 3, -12) };
System\Windows\Forms\SplitterPanelTests.cs (27)
42
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
56
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
464
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
465
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
473
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
483
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
484
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
492
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
541
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
542
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
551
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
563
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
564
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
573
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
829
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
830
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
838
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
848
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.ClientRectangle);
849
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.DisplayRectangle);
857
Assert.Equal(new
Rectangle
(0, 0, value.Width, value.Height), control.Bounds);
1186
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
1187
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1195
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
1205
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
1206
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1214
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
System\Windows\Forms\SplitterTests.cs (12)
31
Assert.Equal(new
Rectangle
(0, 0, 3, 3), control.Bounds);
39
Assert.Equal(new
Rectangle
(0, 0, 3, 3), control.ClientRectangle);
55
Assert.Equal(new
Rectangle
(0, 0, 3, 3), control.DisplayRectangle);
1204
Bounds = new
Rectangle
(10, 10, 50, 50)
1248
Bounds = new
Rectangle
(0, 0, 0, 100)
1254
Bounds = new
Rectangle
(50, 0, 3, 3)
1367
Bounds = new
Rectangle
(0, 0, 0, 100)
1373
Bounds = new
Rectangle
(50, 0, 3, 3)
2015
Bounds = new
Rectangle
(0, 0, 0, 100)
2021
Bounds = new
Rectangle
(50, 0, 3, 3)
2116
Bounds = new
Rectangle
(0, 0, 0, 100)
2122
Bounds = new
Rectangle
(50, 0, 3, 3)
System\Windows\Forms\StatusStripTests.cs (14)
35
Assert.Equal(new
Rectangle
(0, 0, 200, 22), control.Bounds);
43
Assert.Equal(new
Rectangle
(0, 0, 200, 22), control.ClientRectangle);
66
Assert.Equal(new
Rectangle
(1, 0, 185, 22), control.DisplayRectangle);
137
Assert.Equal(new
Rectangle
(188, 0, 12, 22), control.SizeGripBounds);
621
yield return new object[] { true, layoutStyle, RightToLeft.Yes, new
Rectangle
(0, 0, 12, 22) };
622
yield return new object[] { true, layoutStyle, RightToLeft.No, new
Rectangle
(188, 0, 12, 22) };
623
yield return new object[] { true, layoutStyle, RightToLeft.Inherit, new
Rectangle
(188, 0, 12, 22) };
647
yield return new object[] { true, layoutStyle, RightToLeft.Yes, new
Rectangle
(0, 10, 12, 22) };
648
yield return new object[] { true, layoutStyle, RightToLeft.No, new
Rectangle
(198, 10, 12, 22) };
649
yield return new object[] { true, layoutStyle, RightToLeft.Inherit, new
Rectangle
(198, 10, 12, 22) };
674
yield return new object[] { true, layoutStyle, RightToLeft.Yes, new
Rectangle
(0, 0, 12, 12) };
675
yield return new object[] { true, layoutStyle, RightToLeft.No, new
Rectangle
(178, 0, 12, 12) };
676
yield return new object[] { true, layoutStyle, RightToLeft.Inherit, new
Rectangle
(178, 0, 12, 12) };
1212
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\StatusStripTests.Rendering.cs (2)
36
Rectangle bitBltBounds =
new
(bounds.X, 0, bounds.Width - 1, bounds.Height - 1);
37
Rectangle polylineBounds =
new
(bounds.X, 0, bounds.Width - 1, 15);
System\Windows\Forms\TabControl.ControlCollectionTests.cs (38)
43
Bounds = new
Rectangle
(0, 0, 400, 300)
72
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
90
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
94
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
119
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
122
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
166
Bounds = new
Rectangle
(0, 0, 400, 300)
326
Bounds = new
Rectangle
(0, 0, 400, 300)
369
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
390
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
394
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
425
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
428
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
467
Bounds = new
Rectangle
(0, 0, 400, 300)
892
Bounds = new
Rectangle
(0, 0, 400, 300)
925
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
929
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
945
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
949
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
965
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
969
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
990
Bounds = new
Rectangle
(0, 0, 400, 300)
1037
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1041
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1060
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1064
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1086
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1090
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1117
Bounds = new
Rectangle
(0, 0, 400, 300)
1201
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value1.Bounds);
1205
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value2.Bounds);
1229
Bounds = new
Rectangle
(0, 0, 400, 300)
1274
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1278
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1297
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1301
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1323
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1327
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
System\Windows\Forms\TabControl.TabPageCollectionTests.cs (75)
28
Bounds = new
Rectangle
(0, 0, 400, 300)
58
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
77
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
81
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
107
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
110
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
154
Bounds = new
Rectangle
(0, 0, 400, 300)
317
Bounds = new
Rectangle
(0, 0, 400, 300)
361
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
383
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
387
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
419
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
422
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
461
Bounds = new
Rectangle
(0, 0, 400, 300)
975
Bounds = new
Rectangle
(0, 0, 400, 300)
1005
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1023
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1027
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1052
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
1055
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
1970
Bounds = new
Rectangle
(0, 0, 400, 300)
2000
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2019
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2023
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
2051
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2054
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
2091
Bounds = new
Rectangle
(0, 0, 400, 300)
2260
Bounds = new
Rectangle
(0, 0, 400, 300)
2304
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2326
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2330
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
2364
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
2367
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
2410
Bounds = new
Rectangle
(0, 0, 400, 300)
3015
Bounds = new
Rectangle
(0, 0, 400, 300)
3046
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
3065
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
3069
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
3097
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
3100
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
3978
Bounds = new
Rectangle
(0, 0, 400, 300)
4012
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4016
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4033
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4037
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4054
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4058
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4079
Bounds = new
Rectangle
(0, 0, 400, 300)
4127
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4131
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4151
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4155
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4178
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4182
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4209
Bounds = new
Rectangle
(0, 0, 400, 300)
4250
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value1.Bounds);
4254
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value2.Bounds);
4274
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value1.Bounds);
4278
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value2.Bounds);
4298
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value1.Bounds);
4302
Assert.Equal(new
Rectangle
(4, 24, 392, 272), value2.Bounds);
4326
Bounds = new
Rectangle
(0, 0, 400, 300)
4374
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4378
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4398
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4402
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4425
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4429
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4699
Bounds = new
Rectangle
(0, 0, 400, 300)
4731
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4735
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4751
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4755
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
4771
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value1.Bounds);
4775
Assert.Equal(new
Rectangle
(0, 0, 200, 100), value2.Bounds);
System\Windows\Forms\TabControlTests.cs (5)
33
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
40
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
3713
yield return new object[] { new RECT(1, 2, 3, 4), new
Rectangle
(1, 2, 2, 2) };
3758
Assert.Equal(new
Rectangle
(1, 2, 2, 2), control.GetTabRect(0));
4222
yield return new object[] { new DrawItemEventArgs(graphics, null, new
Rectangle
(1, 2, 3, 4), 0, DrawItemState.Checked) };
System\Windows\Forms\TableLayoutCellPaintEventArgsTests.cs (8)
14
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), -1, -1 };
15
yield return new object[] { new
Rectangle
(-1, -2, -3, -4), new
Rectangle
(-1, -2, -3, -4), 0, 0 };
16
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(2, 3, 4, 5), 1, 2 };
38
(Graphics)null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4), 1, 2));
System\Windows\Forms\TableLayoutPanelTests.cs (5)
37
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
45
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
65
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1431
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1471
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(15, 2, 5, 20));
System\Windows\Forms\TabPageTests.cs (59)
40
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
65
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
149
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
156
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
174
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1899
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
1900
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1909
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
1921
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
1922
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1931
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
1989
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
1990
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
1999
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
2012
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
2013
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
2022
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
2090
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
2091
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
2100
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
2115
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
2116
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
2125
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
2214
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.ClientRectangle);
2215
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.DisplayRectangle);
2244
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.ClientRectangle);
2245
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.DisplayRectangle);
3978
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4048
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4052
Bounds = new
Rectangle
(1, 2, 30, 40),
4057
Bounds = new
Rectangle
(1, 2, 10, 20),
4077
Assert.Equal(new
Rectangle
(1, 2, 0, 0), e.ClipRectangle);
4104
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4187
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
4191
Bounds = new
Rectangle
(1, 2, 30, 40),
4196
Bounds = new
Rectangle
(1, 2, 10, 20),
4346
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
4347
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
4355
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
4367
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
4368
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
4376
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
4483
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
4484
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
4492
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
4505
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
4506
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
4514
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
4638
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
4639
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
4647
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
4662
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
4663
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
4671
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
4816
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.ClientRectangle);
4817
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.DisplayRectangle);
4846
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.ClientRectangle);
4847
Assert.Equal(new
Rectangle
(0, 0, expected.Width, expected.Height), control.DisplayRectangle);
System\Windows\Forms\TextBoxBase.TextBoxBaseUiaTextProviderTests.cs (8)
470
yield return new object[] { false, new Size(0, 0), new
Rectangle
(1, 0, 78, 16) };
471
yield return new object[] { false, new Size(50, 50), new
Rectangle
(1, 1, 44, 15) };
472
yield return new object[] { false, new Size(250, 100), new
Rectangle
(1, 1, 244, 15) };
473
yield return new object[] { true, new Size(0, 0), new
Rectangle
(4, 0, 72, 16) };
477
yield return new object[] { true, new Size(50, 50), new
Rectangle
(4, 1, 38, 44) };
478
yield return new object[] { true, new Size(250, 100), new
Rectangle
(4, 1, 238, 94) };
482
yield return new object[] { true, new Size(50, 50), new
Rectangle
(4, 1, 38, 30) };
483
yield return new object[] { true, new Size(250, 100), new
Rectangle
(4, 1, 238, 90) };
System\Windows\Forms\TextBoxRendererTests.cs (3)
78
bounds: new
Rectangle
(6, 3, 16, 12),
101
Rectangle textBounds =
new
(10, 20, 30, 40);
114
bounds: new
Rectangle
(13, 20, 16, 12),
System\Windows\Forms\TextRendererTests.cs (73)
163
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, -3, -4), Color.Red };
164
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Red };
165
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 3, 4), Color.Red };
166
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red };
167
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Black };
168
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.White };
169
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Transparent };
170
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Empty };
195
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, -3, -4), Color.Red, Color.Blue };
196
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Red, Color.Blue };
197
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue };
198
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Black, Color.Blue };
199
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.White, Color.Blue };
200
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Transparent, Color.Blue };
201
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Empty, Color.Blue };
202
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Red };
203
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Black };
204
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.White };
205
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Transparent };
206
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Empty };
231
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, -3, -4), Color.Red, TextFormatFlags.Default, };
232
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Red, TextFormatFlags.Default, };
233
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.Default, };
234
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Black, TextFormatFlags.Default, };
235
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.White, TextFormatFlags.Default, };
236
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Transparent, TextFormatFlags.Default, };
237
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Empty, TextFormatFlags.Default, };
239
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.HorizontalCenter };
240
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.VerticalCenter | TextFormatFlags.HorizontalCenter };
241
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.Bottom | TextFormatFlags.Right };
242
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.SingleLine };
243
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Red, TextFormatFlags.SingleLine };
244
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, (TextFormatFlags)1024 };
245
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.RightToLeft };
246
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, (TextFormatFlags)int.MaxValue };
271
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, -3, -4), Color.Red, Color.Blue, TextFormatFlags.Default, };
272
yield return new object[] { hint, text, null, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Blue, Color.Blue, TextFormatFlags.Default, };
273
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.Default, };
274
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Black, Color.Blue, TextFormatFlags.Default, };
275
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.White, Color.Blue, TextFormatFlags.Default, };
276
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Transparent, Color.Blue, TextFormatFlags.Default, };
277
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Empty, Color.Blue, TextFormatFlags.Default, };
278
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Red, TextFormatFlags.Default, };
279
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Black, TextFormatFlags.Default, };
280
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.White, TextFormatFlags.Default, };
281
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Transparent, TextFormatFlags.Default, };
282
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Empty, TextFormatFlags.Default, };
284
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.VerticalCenter | TextFormatFlags.HorizontalCenter };
285
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.Bottom | TextFormatFlags.Right };
286
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.SingleLine };
287
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, int.MaxValue, int.MaxValue), Color.Red, Color.Blue, TextFormatFlags.SingleLine };
288
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, (TextFormatFlags)1024 };
289
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.RightToLeft };
290
yield return new object[] { hint, text, SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, (TextFormatFlags)int.MaxValue };
339
TextRenderer.DrawText(mockDeviceContext.Object, "text", SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red);
343
TextRenderer.DrawText(mockDeviceContext.Object, "text", SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.Default);
347
TextRenderer.DrawText(mockDeviceContext.Object, "text", SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue);
351
TextRenderer.DrawText(mockDeviceContext.Object, "text", SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.Default);
371
TextRenderer.DrawText(mockDeviceContext.Object, "text".AsSpan(), SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red);
375
TextRenderer.DrawText(mockDeviceContext.Object, "text".AsSpan(), SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, TextFormatFlags.Default);
379
TextRenderer.DrawText(mockDeviceContext.Object, "text".AsSpan(), SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue);
383
TextRenderer.DrawText(mockDeviceContext.Object, "text".AsSpan(), SystemFonts.MenuFont, new
Rectangle
(1, 2, 300, 400), Color.Red, Color.Blue, TextFormatFlags.Default);
700
new
Rectangle
(0, 0, int.MaxValue, int.MaxValue),
716
{ TextFormatFlags.GlyphOverhangPadding, new
Rectangle
(3, 0, 70, 12) },
717
{ TextFormatFlags.LeftAndRightPadding, new
Rectangle
(5, 0, 70, 12) },
718
{ TextFormatFlags.NoPadding, new
Rectangle
(0, 0, 70, 12) }
759
using Region region = new(new
Rectangle
(1, 2, 6, 8));
770
new
Rectangle
(0, 0, int.MaxValue, int.MaxValue),
792
{ TextFormatFlags.Default, new
Rectangle
(3, 0, 49, 12) },
793
{ TextFormatFlags.PreserveGraphicsTranslateTransform, new
Rectangle
(8, 10, 49, 12) },
794
{ TextFormatFlags.PreserveGraphicsClipping, new
Rectangle
(6, 12, 5, 0) },
795
{ TextFormatFlags.PreserveGraphicsClipping | TextFormatFlags.PreserveGraphicsTranslateTransform, new
Rectangle
(8, 12, 3, 7) },
807
using Region region = new(new
Rectangle
(1, 2, 6, 8));
System\Windows\Forms\ToolStripArrowRenderEventArgsTests.cs (7)
22
yield return new object[] { graphics, new ToolStripButton(), new
Rectangle
(1, 2, 3, 4), Color.Blue, ArrowDirection.Down };
23
yield return new object[] { graphics, new ToolStripButton(), new
Rectangle
(-1, -2, -3, -4), Color.Blue, ArrowDirection.Down };
41
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
42
yield return new object[] { new
Rectangle
(-1, -2, -3, -4) };
52
ToolStripArrowRenderEventArgs e = new(graphics, button, new
Rectangle
(1, 2, 3, 4), Color.Blue, ArrowDirection.Down)
72
ToolStripArrowRenderEventArgs e = new(graphics, button, new
Rectangle
(1, 2, 3, 4), Color.Blue, ArrowDirection.Down)
87
ToolStripArrowRenderEventArgs e = new(graphics, button, new
Rectangle
(1, 2, 3, 4), Color.Blue, ArrowDirection.Down)
System\Windows\Forms\ToolStripButtonTests.cs (15)
33
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
40
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
114
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
121
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
201
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
208
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
291
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
298
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
379
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
386
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
477
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
484
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
1266
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1357
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1450
yield return new object[] { displayStyle, new PaintEventArgs(graphics, new
Rectangle
(1, 2, 3, 4)) };
System\Windows\Forms\ToolStripComboBox.ToolStripComboBoxControl.ToolStripComboBoxFlatComboAdapterTests.cs (1)
79
Rectangle dropDownRect =
new
(0, 0, 100, 100);
System\Windows\Forms\ToolStripContentPanelTests.cs (10)
38
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.Bounds);
45
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
62
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
940
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
941
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
950
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
962
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.ClientRectangle);
963
Assert.Equal(new
Rectangle
(0, 0, 200, 100), control.DisplayRectangle);
972
Assert.Equal(new
Rectangle
(value.X, value.Y, 200, 100), control.Bounds);
1855
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\ToolStripControlHostTests.cs (21)
30
Bounds = new
Rectangle
(1, 2, 3, 4),
68
Assert.Equal(new
Rectangle
(2, 2, 0, 0), item.ContentRectangle);
700
Bounds = new
Rectangle
(10, 20, 30, 40)
707
Assert.Equal(new
Rectangle
(10, 20, 30, 40), item.Bounds);
708
Assert.Equal(new
Rectangle
(10, 20, 30, 40), c.Bounds);
714
Assert.Equal(new
Rectangle
(10, 20, 30, 40), item.Bounds);
715
Assert.Equal(new
Rectangle
(10, 20, 30, 40), c.Bounds);
2206
Bounds = new
Rectangle
(1, 2, 3, 4)
2214
Assert.Equal(new
Rectangle
(1, 2, value.Width, value.Height), c.Bounds);
2220
Assert.Equal(new
Rectangle
(1, 2, value.Width, value.Height), c.Bounds);
2770
Bounds = new
Rectangle
(10, 20, 30, 40)
2778
Assert.Equal(new
Rectangle
(10, 20, 30, 40), item.Bounds);
2779
Assert.Equal(new
Rectangle
(10, 20, 30, 40), c.Bounds);
2784
Assert.Equal(new
Rectangle
(10, 20, 30, 40), item.Bounds);
2785
Assert.Equal(new
Rectangle
(10, 20, 30, 40), c.Bounds);
2858
Bounds = new
Rectangle
(1, 2, 3, 4)
2863
Assert.Equal(new
Rectangle
(1, 2, 3, 4), item.Bounds);
2867
Assert.Equal(new
Rectangle
(1, 2, 3, 4), item.Bounds);
3847
Bounds = new
Rectangle
(1, 2, 3, 4)
3853
Assert.Equal(new
Rectangle
(1, 2, 3, 4), item.Bounds);
4110
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
System\Windows\Forms\ToolStripDropDownItemTests.cs (8)
32
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
36
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
121
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
125
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
220
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
224
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
320
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
324
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
System\Windows\Forms\ToolStripDropDownTests.cs (11)
39
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.ClientRectangle);
70
Assert.Equal(new
Rectangle
(1, 2, 98, 21), control.DisplayRectangle);
116
Assert.Equal(Screen.GetWorkingArea(new
Rectangle
(0, 0, 100, 25)).Size - new Size(2, 4), control.MaxItemSize);
1966
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.ClientRectangle);
1967
Assert.Equal(new
Rectangle
(1, 2, 98, 21), control.DisplayRectangle);
1976
Assert.Equal(new
Rectangle
(expected.X, expected.Y, 100, 25), control.Bounds);
1988
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.ClientRectangle);
1989
Assert.Equal(new
Rectangle
(1, 2, 98, 21), control.DisplayRectangle);
1998
Assert.Equal(new
Rectangle
(expected.X, expected.Y, 100, 25), control.Bounds);
2232
yield return new object[] { new Region(new
Rectangle
(1, 2, 3, 4)) };
System\Windows\Forms\ToolStripItemImageRenderEventArgsTests.cs (9)
32
yield return new object[] { graphics, new ToolStripButton(), new
Rectangle
(1, 2, 3, 4), null };
33
yield return new object[] { graphics, new ToolStripButton() { Image = image }, new
Rectangle
(1, 2, 3, 4), image };
40
}, new
Rectangle
(1, 2, 3, 4), image
48
}, new
Rectangle
(1, 2, 3, 4), image
56
}, new
Rectangle
(1, 2, 3, 4), null
82
ToolStripItemImageRenderEventArgs e = new(g, item, new
Rectangle
(1, 2, 3, 4));
85
Assert.Equal(new
Rectangle
(1, 2, 3, 4), e.ImageRectangle);
92
yield return new object[] { new ToolStripButton(), new Bitmap(10, 10), new
Rectangle
(1, 2, 3, 4) };
93
yield return new object[] { new ToolStripButton() { Image = new Bitmap(10, 10) }, new Bitmap(10, 10), new
Rectangle
(1, 2, 3, 4) };
System\Windows\Forms\ToolStripItemTests.cs (32)
35
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
39
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
120
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
124
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
215
Assert.Equal(new
Rectangle
(0, 0, 23, 23), item.Bounds);
219
Assert.Equal(new
Rectangle
(2, 2, 19, 19), item.ContentRectangle);
2037
yield return new object[] { new Padding(-23), new
Rectangle
(2, 2, 19, 19) };
2038
yield return new object[] { new Padding(-24), new
Rectangle
(2, 2, 19, 19) };
2039
yield return new object[] { new Padding(2), new
Rectangle
(0, 0, 23, 23) };
2040
yield return new object[] { new Padding(23), new
Rectangle
(-21, -21, 65, 65) };
2041
yield return new object[] { new Padding(24), new
Rectangle
(-22, -22, 67, 67) };
10472
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
14533
yield return new object[] { new
Rectangle
(1, 0, 23, 23), 1 };
14534
yield return new object[] { new
Rectangle
(0, 2, 23, 23), 1 };
14535
yield return new object[] { new
Rectangle
(1, 2, 23, 23), 1 };
14536
yield return new object[] { new
Rectangle
(0, 0, -1, -2), 0 };
14537
yield return new object[] { new
Rectangle
(0, 0, 0, 0), 0 };
14538
yield return new object[] { new
Rectangle
(0, 0, 1, 2), 0 };
14539
yield return new object[] { new
Rectangle
(0, 0, 22, 23), 0 };
14540
yield return new object[] { new
Rectangle
(0, 0, 23, 22), 0 };
14541
yield return new object[] { new
Rectangle
(0, 0, 23, 23), 0 };
14542
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1 };
14683
yield return new object[] { new
Rectangle
(1, 0, 23, 23), 1, 1 };
14684
yield return new object[] { new
Rectangle
(0, 2, 23, 23), 1, 1 };
14685
yield return new object[] { new
Rectangle
(1, 2, 23, 23), 1, 1 };
14686
yield return new object[] { new
Rectangle
(0, 0, -1, -2), 0, 1 };
14687
yield return new object[] { new
Rectangle
(0, 0, 0, 0), 0, 1 };
14688
yield return new object[] { new
Rectangle
(0, 0, 1, 2), 0, 1 };
14689
yield return new object[] { new
Rectangle
(0, 0, 22, 23), 0, 1 };
14690
yield return new object[] { new
Rectangle
(0, 0, 23, 22), 0, 1 };
14691
yield return new object[] { new
Rectangle
(0, 0, 23, 23), 0, 0 };
14692
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1, 1 };
System\Windows\Forms\ToolStripItemTextRenderEventArgsTests.cs (8)
13
yield return new object[] { new ToolStripButton(), "", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, TextFormatFlags.Top };
14
yield return new object[] { new ToolStripButton() { RightToLeft = RightToLeft.Yes }, "text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, TextFormatFlags.Bottom };
38
yield return new object[] { new ToolStripButton(), "", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, ContentAlignment.MiddleCenter, TextFormatFlags.Default | TextFormatFlags.HorizontalCenter | TextFormatFlags.VerticalCenter | TextFormatFlags.HidePrefix };
39
yield return new object[] { new ToolStripButton(), "", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, ContentAlignment.BottomRight, TextFormatFlags.Default | TextFormatFlags.Bottom | TextFormatFlags.Right | TextFormatFlags.HidePrefix };
40
yield return new object[] { new ToolStripButton() { RightToLeft = RightToLeft.Yes }, "text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, (ContentAlignment)(-1), TextFormatFlags.Default | TextFormatFlags.Bottom | TextFormatFlags.Right | TextFormatFlags.RightToLeft | TextFormatFlags.HidePrefix };
66
Assert.Throws<ArgumentNullException>("item", () => new ToolStripItemTextRenderEventArgs(graphics, null, "", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, TextFormatFlags.Top));
67
Assert.Throws<ArgumentNullException>("item", () => new ToolStripItemTextRenderEventArgs(graphics, null, "", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.DefaultFont, ContentAlignment.TopLeft));
82
ToolStripItemTextRenderEventArgs e = new(graphics, new ToolStripButton(), "", new
Rectangle
(1, 2, 3, 4), Color.Blue, SystemFonts.DefaultFont, TextFormatFlags.Top)
System\Windows\Forms\ToolStripMenuItemTests.cs (2)
33
Assert.Equal(new
Rectangle
(0, 0, 32, 19), item.Bounds);
37
Assert.Equal(new
Rectangle
(-2, 2, 36, 15), item.ContentRectangle);
System\Windows\Forms\ToolStripRendererTests.cs (15)
31
yield return new object[] { new SubToolStripItem(), new
Rectangle
(1, 2, 3, 4), Color.Red, arrowDirection };
36
yield return new object[] { new SubToolStripItem(), new
Rectangle
(1, 2, 3, 4), Color.Red, ArrowDirection.Left - 1 };
37
yield return new object[] { new SubToolStripItem(), new
Rectangle
(1, 2, 3, 4), Color.Red, ArrowDirection.Up + 1 };
193
yield return new object[] { graphics, new SubToolStripItem(), new Bitmap(10, 10), new
Rectangle
(1, 2, 3, 4) };
194
yield return new object[] { graphics, new SubToolStripItem { Enabled = false }, new Bitmap(10, 10), new
Rectangle
(1, 2, 3, 4) };
198
yield return new object[] { graphics, new SubToolStripItem { ImageScaling = imageScaling }, new Bitmap(10, 10), new
Rectangle
(1, 2, 3, 4) };
295
yield return new object[] { new SubToolStripItem(), null, new
Rectangle
(1, 2, 0, 4), Color.Empty, null, TextFormatFlags.Left };
296
yield return new object[] { new SubToolStripItem(), null, new
Rectangle
(1, 2, 3, 0), Color.Empty, null, TextFormatFlags.Left };
297
yield return new object[] { new SubToolStripItem(), null, new
Rectangle
(1, 2, 3, 4), Color.Empty, null, TextFormatFlags.Left };
300
yield return new object[] { new SubToolStripItem(), "Text", new
Rectangle
(1, 2, 0, 4), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
301
yield return new object[] { new SubToolStripItem(), "Text", new
Rectangle
(1, 2, 3, 0), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
302
yield return new object[] { new SubToolStripItem(), "Text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
303
yield return new object[] { new SubToolStripItem() { Enabled = false }, "Text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
304
yield return new object[] { new SubToolStripItem() { TextDirection = ToolStripTextDirection.Vertical270 }, "Text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
305
yield return new object[] { new SubToolStripItem() { TextDirection = ToolStripTextDirection.Vertical90 }, "Text", new
Rectangle
(1, 2, 3, 4), Color.Red, SystemFonts.MenuFont, TextFormatFlags.Left };
System\Windows\Forms\ToolStripRenderEventArgsTests.cs (10)
29
yield return new object[] { new ToolStrip(), new
Rectangle
(0, 0, 100, 25), SystemColors.Control };
30
yield return new object[] { new ToolStrip() { BackColor = Color.Red }, new
Rectangle
(0, 0, 100, 25), Color.Red };
31
yield return new object[] { new ToolStripDropDown(), new
Rectangle
(0, 0, 100, 25), SystemColors.Menu };
32
yield return new object[] { new MenuStrip(), new
Rectangle
(0, 0, 200, 24), SystemColors.MenuBar };
52
yield return new object[] { new ToolStrip(), new
Rectangle
(1, 2, 3, 4), Color.Empty, SystemColors.Control };
53
yield return new object[] { new ToolStrip() { BackColor = Color.Red }, new
Rectangle
(1, 2, 3, 4), Color.Empty, Color.Red };
54
yield return new object[] { new ToolStripDropDown(), new
Rectangle
(1, 2, 3, 4), Color.Empty, SystemColors.Menu };
55
yield return new object[] { new MenuStrip(), new
Rectangle
(1, 2, 3, 4), Color.Empty, SystemColors.MenuBar };
56
yield return new object[] { new ToolStrip() { BackColor = Color.Red }, new
Rectangle
(1, 2, 3, 4), Color.Blue, Color.Blue };
94
ToolStripRenderEventArgs e = new(graphics, toolStrip, new
Rectangle
(1, 2, 3, 4), Color.Empty);
System\Windows\Forms\ToolStripSeparatorTests.cs (38)
33
Assert.Equal(new
Rectangle
(0, 0, 6, 6), item.Bounds);
37
Assert.Equal(new
Rectangle
(2, 2, 2, 2), item.ContentRectangle);
1119
yield return new object[] { layoutStyle, new PaintEventArgs(graphics, new
Rectangle
(1, 2, 3, 4)) };
1213
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1284
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
1353
yield return new object[] { new
Rectangle
(1, 0, 23, 23), 1 };
1354
yield return new object[] { new
Rectangle
(0, 2, 23, 23), 1 };
1355
yield return new object[] { new
Rectangle
(1, 2, 23, 23), 1 };
1356
yield return new object[] { new
Rectangle
(0, 0, -1, -2), 0 };
1357
yield return new object[] { new
Rectangle
(0, 0, 0, 0), 0 };
1358
yield return new object[] { new
Rectangle
(0, 0, 1, 2), 0 };
1359
yield return new object[] { new
Rectangle
(0, 0, 5, 6), 0 };
1360
yield return new object[] { new
Rectangle
(0, 0, 6, 5), 0 };
1361
yield return new object[] { new
Rectangle
(0, 0, 6, 6), 0 };
1362
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1 };
1443
yield return new object[] { new
Rectangle
(1, 0, 23, 23), 1 };
1444
yield return new object[] { new
Rectangle
(0, 2, 23, 23), 1 };
1445
yield return new object[] { new
Rectangle
(1, 2, 23, 23), 1 };
1446
yield return new object[] { new
Rectangle
(0, 0, -1, -2), 1 };
1447
yield return new object[] { new
Rectangle
(0, 0, 0, 0), 1 };
1448
yield return new object[] { new
Rectangle
(0, 0, 1, 2), 1 };
1449
yield return new object[] { new
Rectangle
(0, 0, 5, 6), 1 };
1450
yield return new object[] { new
Rectangle
(0, 0, 6, 5), 1 };
1451
yield return new object[] { new
Rectangle
(0, 0, 6, 6), 1 };
1452
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1 };
1453
yield return new object[] { new
Rectangle
(2, 0, 3, 4), 1 };
1479
Assert.Equal(new
Rectangle
(2, bounds.Y, 57, bounds.Height), item.Bounds);
1489
Assert.Equal(new
Rectangle
(2, bounds.Y, 57, bounds.Height), item.Bounds);
1505
yield return new object[] { new
Rectangle
(1, 0, 23, 23), 1, 1 };
1506
yield return new object[] { new
Rectangle
(0, 2, 23, 23), 1, 1 };
1507
yield return new object[] { new
Rectangle
(1, 2, 23, 23), 1, 1 };
1508
yield return new object[] { new
Rectangle
(0, 0, -1, -2), 0, 1 };
1509
yield return new object[] { new
Rectangle
(0, 0, 0, 0), 0, 1 };
1510
yield return new object[] { new
Rectangle
(0, 0, 1, 2), 0, 1 };
1511
yield return new object[] { new
Rectangle
(0, 0, 5, 6), 0, 1 };
1512
yield return new object[] { new
Rectangle
(0, 0, 6, 5), 0, 1 };
1513
yield return new object[] { new
Rectangle
(0, 0, 6, 6), 0, 0 };
1514
yield return new object[] { new
Rectangle
(1, 2, 3, 4), 1, 1 };
System\Windows\Forms\ToolStripTests.cs (50)
39
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.ClientRectangle);
73
Assert.Equal(new
Rectangle
(9, 0, 90, 25), control.DisplayRectangle);
78
Assert.Equal(new
Rectangle
(7, 0, 92, 25), control.DisplayRectangle);
197
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.Bounds);
205
Assert.Equal(new
Rectangle
(0, 0, 100, 25), control.ClientRectangle);
227
Assert.Equal(new
Rectangle
(9, 0, 90, 25), control.DisplayRectangle);
232
Assert.Equal(new
Rectangle
(7, 0, 92, 25), control.DisplayRectangle);
2266
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Visible, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2267
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Visible, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2268
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Visible, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2269
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Hidden, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2270
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Hidden, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2271
yield return new object[] { ToolStripLayoutStyle.Flow, ToolStripGripStyle.Hidden, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2273
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Yes, new
Rectangle
(0, 0, width, 25) };
2274
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.No, new
Rectangle
(x, 0, width, 25) };
2275
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Inherit, new
Rectangle
(x, 0, width, 25) };
2276
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2277
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2278
yield return new object[] { ToolStripLayoutStyle.HorizontalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2280
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Yes, new
Rectangle
(0, 0, width, 25) };
2281
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.No, new
Rectangle
(x, 0, width, 25) };
2282
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Inherit, new
Rectangle
(x, 0, width, 25) };
2283
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2284
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2285
yield return new object[] { ToolStripLayoutStyle.StackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2287
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Visible, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2288
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Visible, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2289
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Visible, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2290
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Hidden, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2291
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Hidden, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2292
yield return new object[] { ToolStripLayoutStyle.Table, ToolStripGripStyle.Hidden, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
2294
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Yes, new
Rectangle
(0, x, 99, height) };
2295
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.No, new
Rectangle
(0, x, 99, height) };
2296
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Visible, RightToLeft.Inherit, new
Rectangle
(0, x, 99, height) };
2297
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Yes, new
Rectangle
(0, 0, 99, 25) };
2298
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.No, new
Rectangle
(0, 0, 99, 25) };
2299
yield return new object[] { ToolStripLayoutStyle.VerticalStackWithOverflow, ToolStripGripStyle.Hidden, RightToLeft.Inherit, new
Rectangle
(0, 0, 99, 25) };
5873
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
5912
Bounds = new
Rectangle
(1, 2, 30, 40)
5916
Bounds = new
Rectangle
(1, 2, 30, 40)
5960
Bounds = new
Rectangle
(1, 2, 30, 40)
5964
Bounds = new
Rectangle
(1, 2, 30, 40)
6020
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
6024
Bounds = new
Rectangle
(0, 0, 30, 25),
6071
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
6158
using PaintEventArgs eventArgs = new(graphics, new
Rectangle
(1, 2, 3, 4));
6162
Bounds = new
Rectangle
(1, 2, 30, 40)
6166
Bounds = new
Rectangle
(0, 0, 30, 25),
6187
Assert.Equal(new
Rectangle
(0, 0, 30, 25), e.ClipRectangle);
System\Windows\Forms\ToolStripTests.Rendering.cs (1)
33
Rectangle bitBltBounds =
new
(bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
System\Windows\Forms\TrackBarRendererTests.cs (11)
44
TestDrawTrack(TrackBarRenderer.DrawHorizontalTrack, new
Rectangle
(0, 0, 100, 10));
45
TestDrawTrack(TrackBarRenderer.DrawVerticalTrack, new
Rectangle
(0, 0, 10, 100));
62
new
Rectangle
(0, 0, 0, 10),
63
new
Rectangle
(0, 0, 100, 0),
64
new
Rectangle
(0, 0, -100, 10),
65
new
Rectangle
(0, 0, 100, -10)
81
Rectangle bounds =
new
(0, 0, 10, 10);
112
Rectangle horizontalBounds =
new
(0, 0, 100, 10);
113
Rectangle verticalBounds =
new
(0, 0, 10, 100);
139
Rectangle Bounds =
new
(0, 0, 100, 10);
154
Rectangle bounds =
new
(0, 0, 10, 10);
System\Windows\Forms\TreeNodeTests.cs (15)
492
yield return new object[] { new RECT(1, 2, 3, 4), new
Rectangle
(1, 2, 2, 2) };
494
yield return new object[] { new RECT(0, 1, 3, 4), new
Rectangle
(0, 1, 3, 3) };
495
yield return new object[] { new RECT(1, 0, 3, 4), new
Rectangle
(1, 0, 2, 4) };
496
yield return new object[] { new RECT(1, 2, 0, 4), new
Rectangle
(1, 2, -1, 2) };
497
yield return new object[] { new RECT(1, 2, 3, 0), new
Rectangle
(1, 2, 2, -2) };
498
yield return new object[] { new RECT(0, 0, 3, 4), new
Rectangle
(0, 0, 3, 4) };
500
yield return new object[] { new RECT(-1, 0, 3, 4), new
Rectangle
(-1, 0, 4, 4) };
501
yield return new object[] { new RECT(1, -2, 3, 4), new
Rectangle
(1, -2, 2, 6) };
502
yield return new object[] { new RECT(1, 2, -3, 4), new
Rectangle
(1, 2, -4, 2) };
503
yield return new object[] { new RECT(1, 2, 3, -4), new
Rectangle
(1, 2, 2, -6) };
504
yield return new object[] { new RECT(-3, -4, -1, -2), new
Rectangle
(-3, -4, 2, 2) };
506
yield return new object[] { new RECT(1, 118, 3, 4), new
Rectangle
(1, 118, 2, -114) };
507
yield return new object[] { new RECT(1, 117, 3, 4), new
Rectangle
(1, 117, 2, -113) };
508
yield return new object[] { new RECT(94, 2, 3, 4), new
Rectangle
(94, 2, -91, 2) };
509
yield return new object[] { new RECT(93, 2, 3, 4), new
Rectangle
(93, 2, -90, 2) };
System\Windows\Forms\TreeViewTests.cs (4)
31
Assert.Equal(new
Rectangle
(0, 0, 121, 97), control.Bounds);
41
Assert.Equal(new
Rectangle
(0, 0, 117, 93), control.ClientRectangle);
57
Assert.Equal(new
Rectangle
(0, 0, 117, 93), control.DisplayRectangle);
5670
yield return new object[] { new DrawTreeNodeEventArgs(graphics, new TreeNode(), new
Rectangle
(1, 2, 3, 4), TreeNodeStates.Checked) };
System\Windows\Forms\UpDownBaseTests.cs (16)
36
Assert.Equal(new
Rectangle
(0, 0, 120, control.PreferredHeight), control.Bounds);
44
Assert.Equal(new
Rectangle
(0, 0, 120, Control.DefaultFont.Height + 7), control.ClientRectangle);
45
Assert.Equal(new
Rectangle
(0, 0, 120, Control.DefaultFont.Height + 7), control.DisplayRectangle);
51
Assert.Equal(new
Rectangle
(0, 0, 116, Control.DefaultFont.Height + 3), control.ClientRectangle);
52
Assert.Equal(new
Rectangle
(0, 0, 116, Control.DefaultFont.Height + 3), control.DisplayRectangle);
1609
Bounds = new
Rectangle
(1, 2, 30, 40)
2756
Assert.Equal(new
Rectangle
(0, 0, width, Control.DefaultFont.Height + 7), control.ClientRectangle);
2757
Assert.Equal(new
Rectangle
(0, 0, width, Control.DefaultFont.Height + 7), control.DisplayRectangle);
2762
Assert.Equal(new
Rectangle
(0, 0, width - 4, Control.DefaultFont.Height + 3), control.ClientRectangle);
2763
Assert.Equal(new
Rectangle
(0, 0, width - 4, Control.DefaultFont.Height + 3), control.DisplayRectangle);
2773
Assert.Equal(new
Rectangle
(x, y, width, preferredHeight), control.Bounds);
2788
Assert.Equal(new
Rectangle
(0, 0, width, Control.DefaultFont.Height + 7), control.ClientRectangle);
2789
Assert.Equal(new
Rectangle
(0, 0, width, Control.DefaultFont.Height + 7), control.DisplayRectangle);
2794
Assert.Equal(new
Rectangle
(0, 0, width - 4, Control.DefaultFont.Height + 3), control.ClientRectangle);
2795
Assert.Equal(new
Rectangle
(0, 0, width - 4, Control.DefaultFont.Height + 3), control.DisplayRectangle);
2805
Assert.Equal(new
Rectangle
(x, y, width, preferredHeight), control.Bounds);
System\Windows\Forms\UserControlTests.cs (3)
41
Assert.Equal(new
Rectangle
(0, 0, 150, 150), control.Bounds);
48
Assert.Equal(new
Rectangle
(0, 0, 150, 150), control.ClientRectangle);
66
Assert.Equal(new
Rectangle
(0, 0, 150, 150), control.DisplayRectangle);
System\Windows\Forms\VisualStyles\VisualStyleRendererTests.cs (128)
119
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
120
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
121
yield return new object[] { new
Rectangle
(0, 0, 0, 4) };
122
yield return new object[] { new
Rectangle
(0, 0, -1, 4) };
123
yield return new object[] { new
Rectangle
(0, 0, 3, 0) };
124
yield return new object[] { new
Rectangle
(0, 0, 3, -1) };
125
yield return new object[] { new
Rectangle
(0, 0, 0, 0) };
126
yield return new object[] { new
Rectangle
(0, 0, -1, -1) };
127
yield return new object[] { new
Rectangle
(-1, -2, 3, 4) };
144
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
145
yield return new object[] { new
Rectangle
(0, 0, 3, 4), new
Rectangle
(1, 2, 3, 4) };
146
yield return new object[] { new
Rectangle
(0, 0, 0, 4), new
Rectangle
(1, 2, 3, 4) };
147
yield return new object[] { new
Rectangle
(0, 0, -1, 4), new
Rectangle
(1, 2, 3, 4) };
148
yield return new object[] { new
Rectangle
(0, 0, 3, 0), new
Rectangle
(1, 2, 3, 4) };
149
yield return new object[] { new
Rectangle
(0, 0, 3, -1), new
Rectangle
(1, 2, 3, 4) };
150
yield return new object[] { new
Rectangle
(0, 0, 0, 0), new
Rectangle
(1, 2, 3, 4) };
151
yield return new object[] { new
Rectangle
(0, 0, -1, -1), new
Rectangle
(1, 2, 3, 4) };
152
yield return new object[] { new
Rectangle
(-1, -2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
153
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4) };
154
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, 3, 4) };
155
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, 0, 4) };
156
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, -1, 4) };
157
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, 3, 0) };
158
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, 3, -1) };
159
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, 0, 0) };
160
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(0, 0, -1, -1) };
161
yield return new object[] { new
Rectangle
(1, 2, 3, 4), new
Rectangle
(-1, -2, 3, 4) };
180
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawBackground(null, new
Rectangle
(1, 2, 3, 4)));
181
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawBackground(null, new
Rectangle
(1, 2, 3, 4), new
Rectangle
(1, 2, 3, 4)));
186
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
187
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Edges.Top, EdgeStyle.Bump, EdgeEffects.Mono };
188
yield return new object[] { new
Rectangle
(1, 2, 3, 4), Edges.Left | Edges.Top | Edges.Right | Edges.Bottom | Edges.Diagonal, EdgeStyle.Sunken, EdgeEffects.FillInterior | EdgeEffects.Flat | EdgeEffects.Soft | EdgeEffects.Mono };
189
yield return new object[] { new
Rectangle
(0, 0, 3, 4), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
190
yield return new object[] { new
Rectangle
(0, 0, 0, 4), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
191
yield return new object[] { new
Rectangle
(0, 0, -1, 4), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
192
yield return new object[] { new
Rectangle
(0, 0, 3, 0), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
193
yield return new object[] { new
Rectangle
(0, 0, 3, -1), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
194
yield return new object[] { new
Rectangle
(0, 0, 0, 0), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
195
yield return new object[] { new
Rectangle
(0, 0, -1, -1), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
196
yield return new object[] { new
Rectangle
(-1, -2, 3, 4), Edges.Left, EdgeStyle.Raised, EdgeEffects.None };
215
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawEdge(null, new
Rectangle
(1, 2, 3, 4), Edges.Top, EdgeStyle.Bump, EdgeEffects.FillInterior));
225
Assert.Throws<InvalidEnumArgumentException>("edges", () => renderer.DrawEdge(graphics, new
Rectangle
(1, 2, 3, 4), edges, EdgeStyle.Bump, EdgeEffects.FillInterior));
235
Assert.Throws<InvalidEnumArgumentException>("style", () => renderer.DrawEdge(graphics, new
Rectangle
(1, 2, 3, 4), Edges.Bottom, style, EdgeEffects.FillInterior));
245
Assert.Throws<InvalidEnumArgumentException>("effects", () => renderer.DrawEdge(graphics, new
Rectangle
(1, 2, 3, 4), Edges.Bottom, EdgeStyle.Bump, effects));
250
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
251
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
252
yield return new object[] { new
Rectangle
(0, 0, 0, 4) };
253
yield return new object[] { new
Rectangle
(0, 0, -1, 4) };
254
yield return new object[] { new
Rectangle
(0, 0, 3, 0) };
255
yield return new object[] { new
Rectangle
(0, 0, 3, -1) };
256
yield return new object[] { new
Rectangle
(0, 0, 0, 0) };
257
yield return new object[] { new
Rectangle
(0, 0, -1, -1) };
258
yield return new object[] { new
Rectangle
(-1, -2, 3, 4) };
295
Assert.Throws<ArgumentNullException>("g", () => renderer.DrawImage(null, new
Rectangle
(1, 2, 3, 4), image));
296
Assert.Throws<ArgumentNullException>("g", () => renderer.DrawImage(null, new
Rectangle
(1, 2, 3, 4), imageList, 0));
306
Assert.Throws<ArgumentNullException>("image", () => renderer.DrawImage(graphics, new
Rectangle
(1, 2, 3, 4), null));
316
Assert.Throws<ArgumentNullException>("imageList", () => renderer.DrawImage(graphics, new
Rectangle
(1, 2, 3, 4), null, 0));
330
Assert.Throws<ArgumentOutOfRangeException>("imageIndex", () => renderer.DrawImage(graphics, new
Rectangle
(1, 2, 3, 4), imageList, imageIndex));
335
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
336
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
337
yield return new object[] { new
Rectangle
(0, 0, 0, 4) };
338
yield return new object[] { new
Rectangle
(0, 0, -1, 4) };
339
yield return new object[] { new
Rectangle
(0, 0, 3, 0) };
340
yield return new object[] { new
Rectangle
(0, 0, 3, -1) };
341
yield return new object[] { new
Rectangle
(0, 0, 0, 0) };
342
yield return new object[] { new
Rectangle
(0, 0, -1, -1) };
343
yield return new object[] { new
Rectangle
(-1, -2, 3, 4) };
362
yield return new object[] { new
Rectangle
(1, 2, 3, 4) };
363
yield return new object[] { new
Rectangle
(0, 0, 3, 4) };
364
yield return new object[] { new
Rectangle
(0, 0, 0, 4) };
365
yield return new object[] { new
Rectangle
(0, 0, -1, 4) };
366
yield return new object[] { new
Rectangle
(0, 0, 3, 0) };
367
yield return new object[] { new
Rectangle
(0, 0, 3, -1) };
368
yield return new object[] { new
Rectangle
(0, 0, 0, 0) };
369
yield return new object[] { new
Rectangle
(0, 0, -1, -1) };
370
yield return new object[] { new
Rectangle
(-1, -2, 3, 4) };
393
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawParentBackground(null, new
Rectangle
(1, 2, 3, 4), childControl));
400
yield return new object[] { new
Rectangle
(1, 2, 3, 4), textToDraw };
401
yield return new object[] { new
Rectangle
(0, 0, 3, 4), textToDraw };
402
yield return new object[] { new
Rectangle
(0, 0, 0, 4), textToDraw };
403
yield return new object[] { new
Rectangle
(0, 0, -1, 4), textToDraw };
404
yield return new object[] { new
Rectangle
(0, 0, 3, 0), textToDraw };
405
yield return new object[] { new
Rectangle
(0, 0, 3, -1), textToDraw };
406
yield return new object[] { new
Rectangle
(0, 0, 0, 0), textToDraw };
407
yield return new object[] { new
Rectangle
(0, 0, -1, -1), textToDraw };
408
yield return new object[] { new
Rectangle
(-1, -2, 3, 4), textToDraw };
430
yield return new object[] { new
Rectangle
(1, 2, 3, 4), textToDraw, drawDisabled };
431
yield return new object[] { new
Rectangle
(0, 0, 3, 4), textToDraw, drawDisabled };
432
yield return new object[] { new
Rectangle
(0, 0, 0, 4), textToDraw, drawDisabled };
433
yield return new object[] { new
Rectangle
(0, 0, -1, 4), textToDraw, drawDisabled };
434
yield return new object[] { new
Rectangle
(0, 0, 3, 0), textToDraw, drawDisabled };
435
yield return new object[] { new
Rectangle
(0, 0, 3, -1), textToDraw, drawDisabled };
436
yield return new object[] { new
Rectangle
(0, 0, 0, 0), textToDraw, drawDisabled };
437
yield return new object[] { new
Rectangle
(0, 0, -1, -1), textToDraw, drawDisabled };
438
yield return new object[] { new
Rectangle
(-1, -2, 3, 4), textToDraw, drawDisabled };
461
yield return new object[] { new
Rectangle
(1, 2, 3, 4), textToDraw, drawDisabled, TextFormatFlags.Default };
462
yield return new object[] { new
Rectangle
(0, 0, 3, 4), textToDraw, drawDisabled, TextFormatFlags.VerticalCenter };
463
yield return new object[] { new
Rectangle
(0, 0, 0, 4), textToDraw, drawDisabled, TextFormatFlags.Default };
464
yield return new object[] { new
Rectangle
(0, 0, -1, 4), textToDraw, drawDisabled, TextFormatFlags.Default };
465
yield return new object[] { new
Rectangle
(0, 0, 3, 0), textToDraw, drawDisabled, TextFormatFlags.Default };
466
yield return new object[] { new
Rectangle
(0, 0, 3, -1), textToDraw, drawDisabled, TextFormatFlags.Default };
467
yield return new object[] { new
Rectangle
(0, 0, 0, 0), textToDraw, drawDisabled, TextFormatFlags.Default };
468
yield return new object[] { new
Rectangle
(0, 0, -1, -1), textToDraw, drawDisabled, TextFormatFlags.Default };
469
yield return new object[] { new
Rectangle
(-1, -2, 3, 4), textToDraw, drawDisabled, TextFormatFlags.Default };
491
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawText(null, new
Rectangle
(1, 2, 3, 4), "text"));
492
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawText(null, new
Rectangle
(1, 2, 3, 4), "text", true));
493
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawText(null, new
Rectangle
(1, 2, 3, 4), "text", false));
494
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawText(null, new
Rectangle
(1, 2, 3, 4), "text", true, TextFormatFlags.Default));
495
Assert.Throws<ArgumentNullException>("dc", () => renderer.DrawText(null, new
Rectangle
(1, 2, 3, 4), "text", false, TextFormatFlags.Default));
System\Windows\Forms\WebBrowserTests.cs (3)
31
Assert.Equal(new
Rectangle
(0, 0, 250, 250), control.Bounds);
39
Assert.Equal(new
Rectangle
(0, 0, 250, 250), control.ClientRectangle);
54
Assert.Equal(new
Rectangle
(0, 0, 250, 250), control.DisplayRectangle);
Text\FontMetrics.cs (20)
156
{ "Arial", 9.0f, new
Rectangle
(1, 1, 1, 1), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 1, 1, 1) },
157
{ "Arial", 12.0f, new
Rectangle
(1, 1, 1, 1), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 1, 1, 1) },
158
{ "Microsoft Sans Serif", 16.0f, new
Rectangle
(1, 1, 1, 1), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 1, 1, 1) },
159
{ "Times New Roman", 11.0f, new
Rectangle
(1, 1, 1, 1), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 1, 1, 1) },
160
{ "MS Gothic", 10.0f, new
Rectangle
(1, 1, 1, 1), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 1, 1, 1) },
161
{ "Arial", 9.0f, new
Rectangle
(1, 1, 100, 100), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 86, 100, 100) },
162
{ "Arial", 12.0f, new
Rectangle
(1, 1, 100, 100), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 83, 100, 100) },
163
{ "Microsoft Sans Serif", 16.0f, new
Rectangle
(1, 1, 100, 100), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 75, 100, 100) },
164
{ "Times New Roman", 11.0f, new
Rectangle
(1, 1, 100, 100), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 84, 100, 100) },
165
{ "MS Gothic", 10.0f, new
Rectangle
(1, 1, 100, 100), (uint)DRAW_TEXT_FORMAT.DT_BOTTOM, new
Rectangle
(1, 87, 100, 100) },
TextBoxBaseTests.cs (18)
6537
Assert.Equal(new
Rectangle
(0, 0, width - 4, s_preferredHeight - 4), control.ClientRectangle);
6538
Assert.Equal(new
Rectangle
(0, 0, width - 4, s_preferredHeight - 4), control.DisplayRectangle);
6546
Assert.Equal(new
Rectangle
(x, y, width, s_preferredHeight), control.Bounds);
6558
Assert.Equal(new
Rectangle
(0, 0, width - 4, s_preferredHeight - 4), control.ClientRectangle);
6559
Assert.Equal(new
Rectangle
(0, 0, width - 4, s_preferredHeight - 4), control.DisplayRectangle);
6567
Assert.Equal(new
Rectangle
(x, y, width, s_preferredHeight), control.Bounds);
6671
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.ClientRectangle);
6672
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.DisplayRectangle);
6680
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
6692
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.ClientRectangle);
6693
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.DisplayRectangle);
6701
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
6787
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.ClientRectangle);
6788
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.DisplayRectangle);
6796
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
6808
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.ClientRectangle);
6809
Assert.Equal(new
Rectangle
(0, 0, width - 4, height - 4), control.DisplayRectangle);
6817
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
TextBoxTests.cs (3)
38
Assert.Equal(new
Rectangle
(0, 0, 100, control.PreferredHeight), control.Bounds);
47
Assert.Equal(new
Rectangle
(0, 0, 96, control.PreferredHeight - 4), control.ClientRectangle);
63
Assert.Equal(new
Rectangle
(0, 0, 96, control.PreferredHeight - 4), control.DisplayRectangle);
TrackBarTests.cs (10)
32
Assert.Equal(new
Rectangle
(0, 0, 104, s_dimension), control.Bounds);
40
Assert.Equal(new
Rectangle
(0, 0, 104, s_dimension), control.ClientRectangle);
56
Assert.Equal(new
Rectangle
(0, 0, 104, s_dimension), control.DisplayRectangle);
2997
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
2998
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
3006
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
3018
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
3019
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
3027
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
3245
Rectangle rectangle =
new
(rectX, rectY, rectWidth, rectHeight);
WebBrowserBaseTests.cs (25)
74
control.Bounds = new
Rectangle
(x, y, width, height);
76
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
77
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
85
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
93
control.Bounds = new
Rectangle
(x, y, width, height);
95
Assert.Equal(new
Rectangle
(0, 0, width, height), control.ClientRectangle);
96
Assert.Equal(new
Rectangle
(0, 0, width, height), control.DisplayRectangle);
104
Assert.Equal(new
Rectangle
(x, y, width, height), control.Bounds);
190
control.Bounds = new
Rectangle
(x, y, width, height);
192
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
193
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
201
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
212
control.Bounds = new
Rectangle
(x, y, width, height);
214
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.ClientRectangle);
215
Assert.Equal(new
Rectangle
(0, 0, expectedWidth, expectedHeight), control.DisplayRectangle);
223
Assert.Equal(new
Rectangle
(x, y, expectedWidth, expectedHeight), control.Bounds);
656
yield return new object[] { new
Rectangle
(0, 0, 1, 1) };
657
yield return new object[] { new
Rectangle
(0, 0, 10, 10) };
658
yield return new object[] { new
Rectangle
(2, 3, 10, 15) };
659
yield return new object[] { new
Rectangle
(2, 3, 15, 10) };
660
yield return new object[] { new
Rectangle
(0, 0, 100, 150) };
706
Assert.Throws<ArgumentNullException>("bitmap", () => control.DrawToBitmap(null, new
Rectangle
(1, 2, 3, 4)));
724
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(x, y, width, height)));
738
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(1, 2, 3, 4)));
752
Assert.Throws<ArgumentException>(() => control.DrawToBitmap(bitmap, new
Rectangle
(1, 2, 3, 4)));
System.Windows.Forms.UI.IntegrationTests (2)
Infra\ScreenRecordService.cs (2)
238
var bounds = new
Rectangle
(0, 0, width, height);
324
var cropArea = new
Rectangle
(firstChangedColumn, firstChangedLine, lastChangedColumn - firstChangedColumn + 1, lastChangedLine - firstChangedLine + 1);
WinFormsControlsTest (5)
CustomComCtl32Button.cs (5)
104
path.AddArc(new
Rectangle
(x, y, radius, radius), 180, 90);
107
path.AddArc(new
Rectangle
(width, y, radius, radius), 270, 90);
110
path.AddArc(new
Rectangle
(width, height, radius, radius), 0, 90);
113
path.AddArc(new
Rectangle
(x, height, radius, radius), 90, 90);
116
path.AddArc(new
Rectangle
(x, y, radius, radius), 180, 90);