131 references to Center
System.Windows.Forms (3)
System\Windows\Forms\Control.cs (1)
881if (value is ImageLayout.Center or ImageLayout.Zoom or ImageLayout.Stretch)
System\Windows\Forms\Rendering\ControlPaint.cs (1)
84case ImageLayout.Center:
System\Windows\Forms\Scrolling\ScrollableControl.cs (1)
668(BackgroundImageLayout == ImageLayout.Zoom || BackgroundImageLayout == ImageLayout.Stretch || BackgroundImageLayout == ImageLayout.Center))
System.Windows.Forms.Tests (126)
System\Windows\Forms\ComboBoxTests.cs (6)
587control.BackgroundImageLayout = ImageLayout.Center; 588Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 592control.BackgroundImageLayout = ImageLayout.Center; 593Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 603control.BackgroundImageLayout = ImageLayout.Center; 604Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ControlTests.Handlers.cs (2)
556BackgroundImageLayout = ImageLayout.Center 560BackgroundImageLayout = ImageLayout.Center
System\Windows\Forms\ControlTests.Properties.cs (11)
2003[InlineData(ImageLayout.Center, 1)] 2041yield return new object[] { new Bitmap(10, 10, PixelFormat.Format32bppArgb), ImageLayout.Center, true }; 2047yield return new object[] { new Bitmap(10, 10, PixelFormat.Format32bppRgb), ImageLayout.Center, false }; 2084control.BackgroundImageLayout = ImageLayout.Center; 2085Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 2089control.BackgroundImageLayout = ImageLayout.Center; 2090Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 2100control.BackgroundImageLayout = ImageLayout.Center; 2101Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 2119control.BackgroundImageLayout = ImageLayout.Center; 2120Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\DataGridViewTests.cs (1)
3495TestEvent(nameof(DataGridView.BackgroundImageLayoutChanged), nameof(DataGridView.BackgroundImageLayout), ImageLayout.Center, ImageLayout.Stretch);
System\Windows\Forms\DateTimePickerTests.cs (1)
747control.BackgroundImageLayout = ImageLayout.Center;
System\Windows\Forms\LabelTests.cs (5)
564label.BackgroundImageLayout = ImageLayout.Center; 565Assert.Equal(ImageLayout.Center, label.BackgroundImageLayout); 568label.BackgroundImageLayout = ImageLayout.Center; 569Assert.Equal(ImageLayout.Center, label.BackgroundImageLayout); 596label.BackgroundImageLayout = ImageLayout.Center;
System\Windows\Forms\ListBoxTests.cs (6)
562control.BackgroundImageLayout = ImageLayout.Center; 563Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 567control.BackgroundImageLayout = ImageLayout.Center; 568Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 578control.BackgroundImageLayout = ImageLayout.Center; 579Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ListViewTests.cs (6)
586control.BackgroundImageLayout = ImageLayout.Center; 587Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 591control.BackgroundImageLayout = ImageLayout.Center; 592Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 602control.BackgroundImageLayout = ImageLayout.Center; 603Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\MdiClientTests.cs (6)
304control.BackgroundImageLayout = ImageLayout.Center; 305Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 309control.BackgroundImageLayout = ImageLayout.Center; 310Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 320control.BackgroundImageLayout = ImageLayout.Center; 321Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\MonthCalendarTests.cs (6)
464control.BackgroundImageLayout = ImageLayout.Center; 465Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 469control.BackgroundImageLayout = ImageLayout.Center; 470Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 480control.BackgroundImageLayout = ImageLayout.Center; 481Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ProgressBarTests.cs (6)
309control.BackgroundImageLayout = ImageLayout.Center; 310Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 314control.BackgroundImageLayout = ImageLayout.Center; 315Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 325control.BackgroundImageLayout = ImageLayout.Center; 326Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\PropertyGridTests.cs (6)
501control.BackgroundImageLayout = ImageLayout.Center; 502Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 506control.BackgroundImageLayout = ImageLayout.Center; 507Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 517control.BackgroundImageLayout = ImageLayout.Center; 518Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\RichTextBoxTests.cs (6)
830control.BackgroundImageLayout = ImageLayout.Center; 831Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 835control.BackgroundImageLayout = ImageLayout.Center; 836Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 846control.BackgroundImageLayout = ImageLayout.Center; 847Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ScrollableControlTests.cs (3)
1586int expected = backgroundImage is not null && (backgroundImageLayout == ImageLayout.Zoom || backgroundImageLayout == ImageLayout.Stretch || backgroundImageLayout == ImageLayout.Center) && (hScroll || vScroll) ? 0 : 1; 1637: backgroundImage is not null && (backgroundImageLayout == ImageLayout.Zoom || backgroundImageLayout == ImageLayout.Stretch || backgroundImageLayout == ImageLayout.Center) 1786int expected = backgroundImage is not null && (backgroundImageLayout == ImageLayout.Zoom || backgroundImageLayout == ImageLayout.Stretch || backgroundImageLayout == ImageLayout.Center) && (!hScroll && vScroll) ? 0 : 1;
System\Windows\Forms\ScrollBarTests.cs (6)
334control.BackgroundImageLayout = ImageLayout.Center; 335Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 339control.BackgroundImageLayout = ImageLayout.Center; 340Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 350control.BackgroundImageLayout = ImageLayout.Center; 351Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\SplitterTests.cs (6)
291control.BackgroundImageLayout = ImageLayout.Center; 292Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 296control.BackgroundImageLayout = ImageLayout.Center; 297Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 307control.BackgroundImageLayout = ImageLayout.Center; 308Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\TabControlTests.cs (6)
709control.BackgroundImageLayout = ImageLayout.Center; 710Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 714control.BackgroundImageLayout = ImageLayout.Center; 715Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 725control.BackgroundImageLayout = ImageLayout.Center; 726Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ToolStripComboBoxTests.cs (1)
152[InlineData(ImageLayout.Center)]
System\Windows\Forms\ToolStripDropDownTests.cs (6)
884control.BackgroundImageLayout = ImageLayout.Center; 885Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 889control.BackgroundImageLayout = ImageLayout.Center; 890Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 900control.BackgroundImageLayout = ImageLayout.Center; 901Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\ToolStripItemTests.cs (1)
1993[InlineData(ImageLayout.Center, 1)]
System\Windows\Forms\ToolStripMenuItemTests.cs (1)
278BackgroundImageLayout = ImageLayout.Center,
System\Windows\Forms\ToolStripTests.cs (2)
5928int expected = backgroundImage is not null && (backgroundImageLayout == ImageLayout.Zoom || backgroundImageLayout == ImageLayout.Stretch || backgroundImageLayout == ImageLayout.Center) && (hScroll || vScroll) ? 0 : 1; 5987: backgroundImage is not null && (backgroundImageLayout == ImageLayout.Zoom || backgroundImageLayout == ImageLayout.Stretch || backgroundImageLayout == ImageLayout.Center)
System\Windows\Forms\ToolStripTextBoxTests.cs (1)
64[InlineData(ImageLayout.Center)]
System\Windows\Forms\TreeViewTests.cs (6)
879control.BackgroundImageLayout = ImageLayout.Center; 880Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 884control.BackgroundImageLayout = ImageLayout.Center; 885Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 895control.BackgroundImageLayout = ImageLayout.Center; 896Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System\Windows\Forms\UpDownBaseTests.cs (6)
694control.BackgroundImageLayout = ImageLayout.Center; 695Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 699control.BackgroundImageLayout = ImageLayout.Center; 700Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 710control.BackgroundImageLayout = ImageLayout.Center; 711Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
TextBoxBaseTests.cs (6)
532control.BackgroundImageLayout = ImageLayout.Center; 533Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 537control.BackgroundImageLayout = ImageLayout.Center; 538Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 548control.BackgroundImageLayout = ImageLayout.Center; 549Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
ToolStripContainerTests.cs (1)
101_toolStripContainer.BackgroundImageLayout = ImageLayout.Center;
TrackBarTests.cs (6)
526control.BackgroundImageLayout = ImageLayout.Center; 527Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 531control.BackgroundImageLayout = ImageLayout.Center; 532Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout); 542control.BackgroundImageLayout = ImageLayout.Center; 543Assert.Equal(ImageLayout.Center, control.BackgroundImageLayout);
System.Windows.Forms.UI.IntegrationTests (2)
PropertyGridTests.cs (2)
172_propertyGrid.BackgroundImageLayout = ImageLayout.Center; 173_propertyGrid.BackgroundImageLayout.Should().Be(ImageLayout.Center);