589 references to SystemInformation
Microsoft.VisualBasic.Forms (5)
Microsoft\VisualBasic\Devices\Mouse.vb (5)
29
If
SystemInformation
.MousePresent Then
30
Return
SystemInformation
.MouseButtonsSwapped
44
If
SystemInformation
.MousePresent Then
45
Return
SystemInformation
.MouseWheelPresent
60
Return
SystemInformation
.MouseWheelScrollLines
Microsoft.VisualBasic.Tests (13)
Microsoft\VisualBasic\Devices\MouseTests.cs (13)
10
public static bool NoMousePresent => !
SystemInformation
.MousePresent;
12
public static bool NoMouseWheelPresent => NoMousePresent || !
SystemInformation
.MouseWheelPresent;
14
[ConditionalFact(typeof(
SystemInformation
), nameof(
SystemInformation
.MousePresent))]
18
Assert.Equal(
SystemInformation
.MouseButtonsSwapped, mouse.ButtonsSwapped);
32
[ConditionalFact(typeof(
SystemInformation
), nameof(
SystemInformation
.MousePresent))]
36
Assert.Equal(
SystemInformation
.MouseWheelPresent, mouse.WheelExists);
50
[ConditionalFact(typeof(
SystemInformation
), nameof(
SystemInformation
.MousePresent), nameof(
SystemInformation
.MouseWheelPresent))]
53
if (
SystemInformation
.MouseWheelPresent)
56
Assert.Equal(
SystemInformation
.MouseWheelScrollLines, mouse.WheelScrollLines);
System.Windows.Forms (208)
System\Windows\Forms\Application.cs (2)
397
!
SystemInformation
.HighContrast && OsVersion.IsWindows11_OrGreater();
405
!
SystemInformation
.HighContrast
System\Windows\Forms\Application.ThreadContext.cs (2)
615
if (
SystemInformation
.UserInteractive)
699
if (reason == msoloop.ModalForm && !
SystemInformation
.UserInteractive)
System\Windows\Forms\Control.cs (2)
3268
if (
SystemInformation
.MenuAccessKeysUnderlined)
3314
if (
SystemInformation
.MenuAccessKeysUnderlined)
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.ColorOptions.cs (1)
24
HighContrast =
SystemInformation
.HighContrast;
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.cs (7)
69
protected bool IsHighContrastHighlighted() =>
SystemInformation
.HighContrast
105
if (Control.BackColor != SystemColors.Control &&
SystemInformation
.HighContrast)
132
bool disabledHighContrast = (!Control.Enabled) &&
SystemInformation
.HighContrast;
164
?
SystemInformation
.HighContrast ? SystemColors.ControlLight : SystemColors.Control
165
:
SystemInformation
.HighContrast ? colors.Highlight : colors.ButtonFace);
235
bool disabledHighContrast = (!Control.Enabled) &&
SystemInformation
.HighContrast;
273
:
SystemInformation
.HighContrast ? SystemColors.ControlLight : SystemColors.Control);
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonFlatAdapter.cs (9)
28
|| (
SystemInformation
.HighContrast ? state != CheckState.Indeterminate : state == CheckState.Unchecked),
29
check: !hasCustomBorder &&
SystemInformation
.HighContrast && state == CheckState.Checked,
99
else if (state == CheckState.Checked &&
SystemInformation
.HighContrast)
121
|| (
SystemInformation
.HighContrast ? state != CheckState.Indeterminate : state == CheckState.Unchecked),
122
!hasCustomBorder &&
SystemInformation
.HighContrast && state == CheckState.Checked,
187
else if (state == CheckState.Checked &&
SystemInformation
.HighContrast)
204
if (
SystemInformation
.HighContrast)
313
layout.ShadowedText =
SystemInformation
.HighContrast;
325
layout.ShadowedText =
SystemInformation
.HighContrast;
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonPopupAdapter.cs (5)
62
LayoutData layout = PaintPopupLayout(state == CheckState.Unchecked,
SystemInformation
.HighContrast ? 2 : 1).Layout();
86
if (
SystemInformation
.HighContrast)
120
LayoutData layout = PaintPopupLayout(up: false,
SystemInformation
.HighContrast ? 2 : 1).Layout();
165
layout.ShadowedText =
SystemInformation
.HighContrast;
181
layout.ShadowedText =
SystemInformation
.HighContrast;
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckBoxBaseAdapter.cs (2)
100
Color comboColor =
SystemInformation
.HighContrast ? SystemColors.ControlDark : SystemColors.Control;
168
checkColor =
SystemInformation
.HighContrast ? colors.Highlight : colors.ButtonShadow;
System\Windows\Forms\Controls\Buttons\ButtonInternal\RadioButtonBaseAdapter.cs (1)
66
if (!
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\Buttons\CheckBoxRenderer.cs (1)
344
if (
SystemInformation
.HighContrast
System\Windows\Forms\Controls\Buttons\RadioButtonRenderer.cs (1)
322
if (
SystemInformation
.HighContrast
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (5)
775
_prefHeightCache = (short)(textSize.Height +
SystemInformation
.BorderSize.Height * 8 + Padding.Size.Height);
792
_prefHeightCache = (short)(textSize.Height * itemCount +
SystemInformation
.BorderSize.Height * 16 + Padding.Size.Height);
825
int dyEdit = textExtent.Height +
SystemInformation
.Border3DSize.Height;
836
Size fixedFrameBoderSize =
SystemInformation
.FixedFrameBorderSize;
3734
&& !(
SystemInformation
.HighContrast && BackColor == SystemColors.Window))
System\Windows\Forms\Controls\ComboBox\ComboBox.FlatComboAdapter.cs (1)
32
int dropDownButtonWidth =
SystemInformation
.GetHorizontalScrollBarArrowWidthForDpi(comboBox._deviceDpi);
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (4)
229
private static readonly Size s_dragSize =
SystemInformation
.DragSize;
1115
return Application.RenderWithVisualStyles ? 1 :
SystemInformation
.Border3DSize.Width;
1990
defaultCellStyleTmp.ForeColor =
SystemInformation
.HighContrast ? DefaultForeBrush.Color : base.ForeColor;
2054
ForeColor =
SystemInformation
.HighContrast ? DefaultForeBrush.Color : base.ForeColor,
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (11)
940
&&
SystemInformation
.VerticalScrollBarWidth <= _layout.Data.Width)
943
availableWidth -=
SystemInformation
.VerticalScrollBarWidth;
4542
int oldThumbHeight = Math.Max(((_vertScrollBar.Height - 2 *
SystemInformation
.VerticalScrollBarArrowHeight) * _vertScrollBar.LargeChange) / _vertScrollBar.Maximum, 8);
4553
(_vertScrollBar.Height - 2 *
SystemInformation
.VerticalScrollBarArrowHeight) * _vertScrollBar.LargeChange / _vertScrollBar.Maximum,
5779
&& (DateTime.Now.Ticks - _lastMouseClickInfo.TimeStamp) / 10000 <=
SystemInformation
.DoubleClickTime
5785
Size hotDoubleClickZone =
SystemInformation
.DoubleClickSize;
10168
int horizScrollBarHeight = _horizScrollBar.Height =
SystemInformation
.HorizontalScrollBarHeight;
10169
int vertScrollBarWidth = _vertScrollBar.Width =
SystemInformation
.VerticalScrollBarWidth;
16479
int wheelScrollLines =
SystemInformation
.MouseWheelScrollLines;
16713
if (
SystemInformation
.HighContrast)
30050
PInvokeCore.SendMessage(nmhdr->hwndFrom, PInvoke.TTM_SETMAXTIPWIDTH, 0,
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (6)
757
valBounds.Inflate(-
SystemInformation
.Border3DSize.Width, -
SystemInformation
.Border3DSize.Height);
884
valBounds.Width > 2 *
SystemInformation
.Border3DSize.Width + 1 &&
885
valBounds.Height > 2 *
SystemInformation
.Border3DSize.Height + 1)
907
SystemInformation
.HighContrast,
938
SystemInformation
.HighContrast ? 2 : 1,
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (1)
1439
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxCell.cs (3)
701
_ =>
SystemInformation
.Border3DSize.Width * 2 + 9 + 2 * DATAGRIDVIEWCHECKBOXCELL_margin,
1202
checkBoxSize = new Size(
SystemInformation
.Border3DSize.Width * 2 + 9,
SystemInformation
.Border3DSize.Width * 2 + 9);
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (8)
546
int dropWidth = Math.Min(
SystemInformation
.HorizontalScrollBarThumbWidth, adjustedSize.Width - 2 * Margin - 1);
614
s_cachedDropDownWidth = maxPreferredWidth + 2 +
SystemInformation
.VerticalScrollBarWidth;
1197
preferredSize.Width +=
SystemInformation
.HorizontalScrollBarThumbWidth + 1 + (2 * Margin) + borderAndPaddingWidths;
1203
borderAndPaddingWidths +
SystemInformation
.HorizontalScrollBarThumbWidth + 1 + (IconMarginWidth * 2) + s_iconsWidth);
1992
int dropWidth = Math.Min(
SystemInformation
.HorizontalScrollBarThumbWidth, valBounds.Width - 2 * Margin - 1);
2068
if (
SystemInformation
.HighContrast)
2090
Pen pen =
SystemInformation
.HighContrast ? SystemPens.ControlLight : SystemPens.Control;
2326
if (paintPostXPThemes && (drawDropDownButton || drawComboBox) && !
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkCell.cs (6)
51
else if (
SystemInformation
.HighContrast)
94
if (
SystemInformation
.HighContrast)
159
else if (
SystemInformation
.HighContrast)
200
private bool ShouldSerializeLinkColor() =>
SystemInformation
.HighContrast
296
else if (
SystemInformation
.HighContrast)
341
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkColumn.cs (3)
68
if (
SystemInformation
.HighContrast)
179
if (
SystemInformation
.HighContrast)
359
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\DataGridView\DataGridViewRowCollection.cs (2)
2041
GetRowsHeightExceedLimit(DataGridViewElementStates.Visible, 0, rowIndex, DataGridView.LayoutInfo.Data.Height +
SystemInformation
.HorizontalScrollBarHeight);
2053
useRowShortcut = GetRowsHeightExceedLimit(DataGridViewElementStates.Visible, 0, rowIndex, DataGridView.LayoutInfo.Data.Height + DataGridView.VerticalScrollingOffset +
SystemInformation
.HorizontalScrollBarHeight) &&
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (1)
1039
if (
SystemInformation
.HighContrast &&
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (1)
750
height +=
SystemInformation
.BorderSize.Height * 4 + 3;
System\Windows\Forms\Controls\GroupBox\GroupBox.cs (1)
545
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\GroupBox\GroupBoxRenderer.cs (1)
361
if (
SystemInformation
.HighContrast
System\Windows\Forms\Controls\Labels\LinkLabel.cs (2)
238
?
SystemInformation
.HighContrast ? SystemColors.HotTrack : IELinkColor
349
?
SystemInformation
.HighContrast ? LinkUtilities.GetVisitedLinkColor() : IEVisitedLinkColor
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (2)
750
height +=
SystemInformation
.BorderSize.Height * 4 + 3;
769
width +=
SystemInformation
.VerticalScrollBarWidth + 4;
System\Windows\Forms\Controls\ListView\ListView.cs (1)
6822
PInvokeCore.SendMessage(nmhdr->hwndFrom, PInvoke.TTM_SETMAXTIPWIDTH, (WPARAM)0, (LPARAM)
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Controls\Menus\MenuTimer.cs (1)
23
_slowShow = Math.Max(_quickShow,
SystemInformation
.MenuShowDelay);
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (1)
1654
Size max =
SystemInformation
.MaxWindowTrackSize;
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (2)
73
private Color _lineColor =
SystemInformation
.HighContrast ? SystemColors.ControlDarkDark : SystemColors.InactiveBorder;
3811
if (DrawFlatToolbar ||
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CategoryGridEntry.cs (1)
122
if (
SystemInformation
.HighContrast && !OwnerGrid.HasCustomLineColor)
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\DropDownButton.DropDownButtonAdapter.cs (1)
18
if (Control.BackColor != SystemColors.Control &&
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.cs (1)
107
=>
SystemInformation
.HighContrast && !OwnerGrid.HasCustomLineColor;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridToolTip.cs (1)
142
(LPARAM)
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (14)
217
? new(
SystemInformation
.VerticalScrollBarArrowHeightForDpi(_deviceDpi), RowHeight)
218
: new(
SystemInformation
.VerticalScrollBarArrowHeight, RowHeight);
255
? new Size(
SystemInformation
.VerticalScrollBarArrowHeightForDpi(_deviceDpi), RowHeight)
256
: new Size(
SystemInformation
.VerticalScrollBarArrowHeight, RowHeight);
2592
if (delta <
SystemInformation
.DoubleClickTime)
2596
if (Math.Abs(screenPoint.X - _rowSelectPos.X) <
SystemInformation
.DoubleClickSize.Width &&
2597
Math.Abs(screenPoint.Y - _rowSelectPos.Y) <
SystemInformation
.DoubleClickSize.Height)
3123
int wheelScrollLines =
SystemInformation
.MouseWheelScrollLines;
3715
maxWidth += 2 + tm.tmMaxCharWidth +
SystemInformation
.VerticalScrollBarWidth;
3791
int overhang = toolTip.Location.X + toolTip.Size.Width -
SystemInformation
.VirtualScreen.Width;
4322
? new Size(
SystemInformation
.VerticalScrollBarArrowHeightForDpi(_deviceDpi), RowHeight)
4323
: new Size(
SystemInformation
.VerticalScrollBarArrowHeight, RowHeight);
5138
_dropDownButton.Size = new(
SystemInformation
.VerticalScrollBarArrowHeightForDpi(_deviceDpi), RowHeight);
5142
_dropDownButton.Size = new(
SystemInformation
.VerticalScrollBarArrowHeight, RowHeight);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.DropDownHolder.cs (3)
31
private static readonly int s_resizeGripSize =
SystemInformation
.HorizontalScrollBarHeight;
41
new(
SystemInformation
.VerticalScrollBarWidth * 4,
SystemInformation
.HorizontalScrollBarHeight * 4);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridToolStripButton.cs (1)
76
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\RichTextBox\RichTextBox.cs (2)
433
scrollBarPadding.Height +=
SystemInformation
.HorizontalScrollBarHeight;
438
scrollBarPadding.Width +=
SystemInformation
.VerticalScrollBarWidth;
System\Windows\Forms\Controls\TabControl\TabControl.cs (1)
2093
PInvokeCore.SendMessage(nmhdr->hwndFrom, PInvoke.TTM_SETMAXTIPWIDTH, 0,
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Controls\TextBox\TextBox.cs (2)
407
scrollBarPadding.Height +=
SystemInformation
.GetHorizontalScrollBarHeightForDpi(_deviceDpi);
412
scrollBarPadding.Width +=
SystemInformation
.GetVerticalScrollBarWidthForDpi(_deviceDpi);
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (1)
803
height +=
SystemInformation
.GetBorderSizeForDpi(_deviceDpi).Height * 4 + 3;
System\Windows\Forms\Controls\ToolStrips\ToolStripComboBox.ToolStripComboBoxControl.ToolStripComboBoxFlatComboAdapter.cs (1)
131
brush =
SystemInformation
.HighContrast
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.cs (1)
201
if (Selected && !Pressed &&
SystemInformation
.HighContrast)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownMenu.cs (1)
733
int menuHeight =
SystemInformation
.MenuHeight;
System\Windows\Forms\Controls\ToolStrips\ToolStripGrip.cs (1)
137
s_dragSize =
SystemInformation
.DragSize;
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
2117
get =>
SystemInformation
.DoubleClickTime * 10000;
System\Windows\Forms\Controls\ToolStrips\ToolStripManager.cs (1)
69
sysFont =
SystemInformation
.GetMenuFontForDpi(dpi);
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (1)
814
if (
SystemInformation
.InLockedTerminalSession())
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderer.cs (1)
832
if (
SystemInformation
.HighContrast && image is Bitmap bitmap)
System\Windows\Forms\Controls\ToolStrips\ToolStripScrollButton.cs (1)
23
private static readonly int s_autoScrollPause =
SystemInformation
.DoubleClickTime;
System\Windows\Forms\Controls\ToolStrips\ToolStripSystemRenderer.cs (3)
579
if (e.Item is ToolStripSplitButton item && !
SystemInformation
.HighContrast &&
657
if (!
SystemInformation
.HighContrast &&
779
if (!
SystemInformation
.InLockedTerminalSession())
System\Windows\Forms\Controls\ToolStrips\ToolStripTextBox.ToolStripTextBoxControl.cs (1)
245
Color innerBorderColor =
SystemInformation
.HighContrast && !focused ? ColorTable.MenuBorder : BackColor;
System\Windows\Forms\Controls\TrackBar\TrackBar.cs (1)
930
int wheelScrollLines =
SystemInformation
.MouseWheelScrollLines;
System\Windows\Forms\Controls\TreeView\TreeView.cs (2)
1624
PInvokeCore.SendMessage(toolTip, PInvoke.TTM_SETMAXTIPWIDTH, 0,
SystemInformation
.MaxWindowTrackSize.Width);
3220
PInvokeCore.SendMessage(nmhdr->hwndFrom, PInvoke.TTM_SETMAXTIPWIDTH, 0,
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Controls\UpDown\UpDownBase.cs (2)
344
height +=
SystemInformation
.BorderSize.Height * 4 + 3;
739
int wheelScrollLines =
SystemInformation
.MouseWheelScrollLines;
System\Windows\Forms\Design\ComponentEditorForm.cs (2)
251
int xFrame =
SystemInformation
.FixedFrameBorderSize.Width;
255
2 * xFrame +
SystemInformation
.CaptionHeight);
System\Windows\Forms\Dialogs\CommonDialogs\CommonDialog.cs (1)
170
if (!
SystemInformation
.UserInteractive)
System\Windows\Forms\Dialogs\CommonDialogs\FileDialog.Vista.cs (1)
19
&&
SystemInformation
.BootMode == BootMode.Normal;
System\Windows\Forms\Dialogs\CommonDialogs\FolderBrowserDialog.cs (1)
248
get => AutoUpgradeEnabled &&
SystemInformation
.BootMode == BootMode.Normal;
System\Windows\Forms\Dialogs\MessageBox.cs (1)
53
if (!
SystemInformation
.UserInteractive && (options & (MessageBoxOptions.ServiceNotification | MessageBoxOptions.DefaultDesktopOnly)) == 0)
System\Windows\Forms\ErrorProvider\ErrorProvider.ErrorWindow.cs (1)
125
(LPARAM)
SystemInformation
.MaxWindowTrackSize.Width);
System\Windows\Forms\Form.cs (17)
899
Rectangle screen =
SystemInformation
.WorkingArea;
922
Rectangle screen =
SystemInformation
.WorkingArea;
3037
correctClientSize.Height +=
SystemInformation
.HorizontalScrollBarHeight;
3042
correctClientSize.Width +=
SystemInformation
.VerticalScrollBarWidth;
3062
correct.Width +=
SystemInformation
.VerticalScrollBarWidth;
3067
correct.Height +=
SystemInformation
.HorizontalScrollBarHeight;
5227
Size max =
SystemInformation
.MaxWindowTrackSize;
5247
Size min =
SystemInformation
.MinWindowTrackSize;
5297
x +=
SystemInformation
.VerticalScrollBarWidth;
5305
y +=
SystemInformation
.HorizontalScrollBarHeight;
5323
Rectangle workingArea =
SystemInformation
.WorkingArea;
5332
Rectangle workingArea =
SystemInformation
.WorkingArea;
5392
if (!
SystemInformation
.UserInteractive)
5591
if (!
SystemInformation
.UserInteractive)
6356
_smallIcon = new Icon(icon,
SystemInformation
.SmallIconSize);
6795
Size virtualScreen =
SystemInformation
.VirtualScreen.Size;
6811
Size minTrackWindowSize =
SystemInformation
.MinWindowTrackSize;
System\Windows\Forms\Input\Cursor.cs (1)
199
s_cursorSize =
SystemInformation
.CursorSize;
System\Windows\Forms\Input\MouseHoverTimer.cs (1)
13
_mouseHoverTimer.Interval =
SystemInformation
.MouseHoverTime;
System\Windows\Forms\MDI\MDIControlStrip.cs (1)
82
using Icon smallIcon = new(icon,
SystemInformation
.SmallIconSize);
System\Windows\Forms\Printing\PrintControllerWithStatusDialog.cs (1)
40
if (
SystemInformation
.UserInteractive)
System\Windows\Forms\Printing\PrintPreviewControl.cs (4)
37
private readonly int _focusHOffset =
SystemInformation
.HorizontalFocusThickness;
38
private readonly int _focusVOffset =
SystemInformation
.VerticalFocusThickness;
344
bool isHighContrast =
SystemInformation
.HighContrast;
596
if (
SystemInformation
.HighContrast && Parent is Control parent)
System\Windows\Forms\Rendering\ControlPaint.cs (6)
140
=>
SystemInformation
.HighContrast ? SystemColors.WindowFrame : SystemColors.ControlDark;
1034
Size sz =
SystemInformation
.Border3DSize;
1118
:
SystemInformation
.HighContrast
1324
? (
SystemInformation
.HighContrast ? SystemColors.GrayText : SystemColors.ControlDark)
1950
if (
SystemInformation
.HighContrast)
1998
if (
SystemInformation
.HighContrast)
System\Windows\Forms\Rendering\DisplayInformation.cs (3)
75
s_highContrast =
SystemInformation
.HighContrast;
90
s_dropShadowEnabled =
SystemInformation
.IsDropShadowEnabled;
106
s_menuAccessKeysUnderlined =
SystemInformation
.MenuAccessKeysUnderlined;
System\Windows\Forms\Rendering\TextRenderer.cs (3)
550
if (
SystemInformation
.HighContrast)
589
if (!
SystemInformation
.IsFontSmoothingEnabled)
595
return
SystemInformation
.FontSmoothingType == 0x0002
System\Windows\Forms\Screen.cs (9)
58
if (!
SystemInformation
.MultiMonitorSupport || monitor == s_primaryMonitor)
61
_bounds =
SystemInformation
.VirtualScreen;
106
if (
SystemInformation
.MultiMonitorSupport)
158
if (
SystemInformation
.MultiMonitorSupport)
191
if (!
SystemInformation
.MultiMonitorSupport || _hmonitor == s_primaryMonitor)
194
_workingArea =
SystemInformation
.WorkingArea;
250
=>
SystemInformation
.MultiMonitorSupport
258
=>
SystemInformation
.MultiMonitorSupport
276
=>
SystemInformation
.MultiMonitorSupport
System\Windows\Forms\Scrolling\HScrollBar.cs (1)
24
=> new(80,
SystemInformation
.HorizontalScrollBarHeight);
System\Windows\Forms\Scrolling\ScrollableControl.cs (7)
310
fullClient.Height +=
SystemInformation
.HorizontalScrollBarHeight;
314
minClient.Height -=
SystemInformation
.HorizontalScrollBarHeight;
319
fullClient.Width +=
SystemInformation
.VerticalScrollBarWidth;
323
minClient.Width -=
SystemInformation
.VerticalScrollBarWidth;
497
clientToBe.Height -=
SystemInformation
.HorizontalScrollBarHeight;
502
clientToBe.Width -=
SystemInformation
.VerticalScrollBarWidth;
1243
SetScrollState(ScrollStateFullDrag,
SystemInformation
.DragFullWindows);
System\Windows\Forms\Scrolling\VScrollBar.cs (2)
33
return new Size(
SystemInformation
.GetVerticalScrollBarWidthForDpi(_deviceDpi), LogicalToDeviceUnits(DefaultHeight));
36
return new Size(
SystemInformation
.VerticalScrollBarWidth, DefaultHeight);
System\Windows\Forms\ToolTip\ToolTip.cs (3)
717
if (
SystemInformation
.HighContrast)
732
PInvokeCore.SendMessage(this, PInvoke.TTM_SETMAXTIPWIDTH, 0,
SystemInformation
.MaxWindowTrackSize.Width);
1581
Rectangle screenBounds =
SystemInformation
.VirtualScreen;
System.Windows.Forms.Design (47)
System\ComponentModel\Design\ByteViewer.cs (2)
438
_scrollbarHeight =
SystemInformation
.HorizontalScrollBarHeight;
439
_scrollbarWidth =
SystemInformation
.VerticalScrollBarWidth;
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (6)
190
_listBox.ItemHeight = Font.Height +
SystemInformation
.BorderSize.Width * 2;
218
w +=
SystemInformation
.BorderSize.Width * 4;
227
return (int)Math.Ceiling(size.Width) + w + pic +
SystemInformation
.BorderSize.Width * 4;
570
w +=
SystemInformation
.BorderSize.Width * 4;
575
button.Inflate(-
SystemInformation
.BorderSize.Width * 2, -
SystemInformation
.BorderSize.Height * 2);
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.cs (1)
103
maxWidth += 2 + tm.tmMaxCharWidth +
SystemInformation
.VerticalScrollBarWidth;
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.FlyoutDialog.cs (2)
36
int width = Math.Max(_hostedControl.Width,
SystemInformation
.MinimumWindowSize.Width);
37
int height = Math.Max(_hostedControl.Height,
SystemInformation
.MinimizedWindowSize.Height);
System\ComponentModel\Design\MultilineStringEditor.MultilineStringEditorUI.cs (1)
158
requestedSize.Width +=
SystemInformation
.VerticalScrollBarWidth;
System\Windows\Forms\Design\AnchorEditor.AnchorUI.cs (2)
72
int XBORDER =
SystemInformation
.Border3DSize.Width;
73
int YBORDER =
SystemInformation
.Border3DSize.Height;
System\Windows\Forms\Design\ComponentTray.cs (6)
1441
if (
SystemInformation
.HighContrast)
1458
if (
SystemInformation
.HighContrast)
1924
_borderWidth =
SystemInformation
.BorderSize.Width;
2189
Size minDrag =
SystemInformation
.DragSize;
2190
Size minDblClick =
SystemInformation
.DoubleClickSize;
2452
_cyIcon =
SystemInformation
.IconSize.Height;
System\Windows\Forms\Design\ControlDesigner.cs (7)
1378
Size minDrag =
SystemInformation
.DragSize;
1379
Size minDblClick =
SystemInformation
.DoubleClickSize;
2240
Size glyphSize =
SystemInformation
.IconSize;
2260
Math.Max(
SystemInformation
.ToolWindowCaptionHeight -
SystemInformation
.BorderSize.Height - 2, Control.Font.Height),
2333
int wait =
SystemInformation
.DoubleClickTime;
2337
Size dblClick =
SystemInformation
.DoubleClickSize;
System\Windows\Forms\Design\DataGridViewCellStyleBuilder.cs (1)
141
if (!
SystemInformation
.HighContrast)
System\Windows\Forms\Design\DataGridViewColumnTypeEditor.Picker.cs (1)
116
Width = Math.Max(Width, PreferredWidth + (
SystemInformation
.VerticalScrollBarWidth * 2));
System\Windows\Forms\Design\DesignBindingPicker.cs (1)
578
Width = Math.Max(Width, _treeViewCtrl is null ? 0 : _treeViewCtrl.PreferredWidth + (
SystemInformation
.VerticalScrollBarWidth * 2));
System\Windows\Forms\Design\DesignerUtils.cs (2)
144
Size minDrag =
SystemInformation
.DragSize;
145
Size minDblClick =
SystemInformation
.DoubleClickSize;
System\Windows\Forms\Design\FormDocumentDesigner.cs (4)
116
size.Height +=
SystemInformation
.HorizontalScrollBarHeight;
121
size.Width +=
SystemInformation
.VerticalScrollBarWidth;
431
clientHeight +=
SystemInformation
.HorizontalScrollBarHeight;
436
clientWidth +=
SystemInformation
.VerticalScrollBarWidth;
System\Windows\Forms\Design\MaskDesignerDialog.cs (1)
83
_validatingTypeHeader.Width = (_listViewCannedMasks.Width / 3) -
SystemInformation
.VerticalScrollBarWidth - 4; // so no h-scrollbar.
System\Windows\Forms\Design\SelectionUIService.cs (1)
629
Size minDragSize =
SystemInformation
.DragSize;
System\Windows\Forms\Design\ToolStripCollectionEditor.ToolStripItemEditorForm.cs (1)
995
? new(4 +
SystemInformation
.HorizontalScrollBarThumbWidth, 3, s_iconWidth, s_iconHeight)
System\Windows\Forms\Design\ToolStripDesignerUtils.cs (3)
586
s_highContrast =
SystemInformation
.HighContrast;
601
s_dropShadowEnabled =
SystemInformation
.IsDropShadowEnabled;
619
s_isTerminalServerSession =
SystemInformation
.TerminalServerSession;
System\Windows\Forms\Design\ToolStripItemBehavior.cs (1)
371
Interval =
SystemInformation
.DoubleClickTime
System\Windows\Forms\Design\ToolStripKeyboardHandlingService.cs (1)
1249
bool menusCascadeRight =
SystemInformation
.RightAlignedMenus;
System\Windows\Forms\Design\ToolStripTemplateNode.cs (2)
1815
DrawArrow(new ToolStripArrowRenderEventArgs(g, null, bounds,
SystemInformation
.HighContrast ? Color.Black : SystemColors.ControlText, ArrowDirection.Down));
2044
if (item is not null && string.Equals(item.Name, CenterLabelName, StringComparison.InvariantCulture) &&
SystemInformation
.HighContrast)
System\Windows\Forms\Design\TreeNodeCollectionEditor.cs (1)
282
if (!
SystemInformation
.HighContrast)
System.Windows.Forms.Primitives.Tests (1)
Interop\Mocks\MockCursor.cs (1)
37
public Size Size =>
SystemInformation
.CursorSize;
System.Windows.Forms.Tests (308)
System\Windows\Forms\AccessibleObjects\Panel.PanelAccessibleObjectTests.cs (2)
280
int horizontalScrollBarHeight =
SystemInformation
.HorizontalScrollBarHeight;
281
int verticalScrollBarWidth =
SystemInformation
.VerticalScrollBarWidth;
System\Windows\Forms\AccessibleObjects\TabPage.TabPageAccessibleObjectTests.cs (2)
552
int horizontalScrollBarHeight =
SystemInformation
.HorizontalScrollBarHeight;
553
int verticalScrollBarWidth =
SystemInformation
.VerticalScrollBarWidth;
System\Windows\Forms\ApplicationTests.cs (1)
157
if (
SystemInformation
.HighContrast)
System\Windows\Forms\ControlTests.Properties.cs (20)
10502
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, control.ShowFocusCues);
10509
{ (int)PInvoke.UIS_CLEAR | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10510
{ (int)PInvoke.UIS_CLEAR | ((int)PInvoke.UISF_HIDEACCEL << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10513
{ (int)PInvoke.UIS_SET | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10514
{ (int)PInvoke.UIS_SET | ((int)PInvoke.UISF_HIDEACCEL << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10517
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10518
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_HIDEACCEL << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10519
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_HIDEFOCUS << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10520
{ (int)PInvoke.UIS_INITIALIZE | ((int)(PInvoke.UISF_HIDEACCEL | PInvoke.UISF_HIDEFOCUS) << 16),
SystemInformation
.MenuAccessKeysUnderlined }
10553
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, control.ShowFocusCues);
10561
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, control.ShowKeyboardCues);
10568
{ (int)PInvoke.UIS_CLEAR | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10570
{ (int)PInvoke.UIS_CLEAR | ((int)PInvoke.UISF_HIDEFOCUS << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10572
{ (int)PInvoke.UIS_SET | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10574
{ (int)PInvoke.UIS_SET | ((int)PInvoke.UISF_HIDEFOCUS << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10576
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_ACTIVE << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10577
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_HIDEACCEL << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10578
{ (int)PInvoke.UIS_INITIALIZE | ((int)PInvoke.UISF_HIDEFOCUS << 16),
SystemInformation
.MenuAccessKeysUnderlined },
10579
{ (int)PInvoke.UIS_INITIALIZE | ((int)(PInvoke.UISF_HIDEACCEL | PInvoke.UISF_HIDEFOCUS) << 16),
SystemInformation
.MenuAccessKeysUnderlined }
10612
Assert.Equal(designMode |
SystemInformation
.MenuAccessKeysUnderlined, control.ShowKeyboardCues);
System\Windows\Forms\CursorTests.cs (3)
209
Rectangle virtualScreen =
SystemInformation
.VirtualScreen;
266
Rectangle virtualScreen =
SystemInformation
.VirtualScreen;
285
Rectangle virtualScreen =
SystemInformation
.VirtualScreen;
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (1)
16
private static readonly int s_preferredHeight = Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3;
System\Windows\Forms\Design\ComponentEditorFormTests.cs (4)
78
Assert.Equal(new Rectangle(-
SystemInformation
.WorkingArea.X, -
SystemInformation
.WorkingArea.Y, control.Width, control.Height), control.DesktopBounds);
79
Assert.Equal(new Point(-
SystemInformation
.WorkingArea.X, -
SystemInformation
.WorkingArea.Y), control.DesktopLocation);
System\Windows\Forms\FormTests.cs (4)
77
Assert.Equal(new Rectangle(-
SystemInformation
.WorkingArea.X, -
SystemInformation
.WorkingArea.Y, 300, 300), control.DesktopBounds);
78
Assert.Equal(new Point(-
SystemInformation
.WorkingArea.X, -
SystemInformation
.WorkingArea.Y), control.DesktopLocation);
System\Windows\Forms\ListBoxTests.cs (3)
102
Assert.Equal(Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3, control.PreferredHeight);
2052
int extra =
SystemInformation
.BorderSize.Height * 4 + 3;
2081
int extra =
SystemInformation
.BorderSize.Height * 4 + 3;
System\Windows\Forms\PowerStatusTests.cs (5)
14
PowerStatus status =
SystemInformation
.PowerStatus;
46
PowerStatus status =
SystemInformation
.PowerStatus;
53
PowerStatus status =
SystemInformation
.PowerStatus;
61
PowerStatus status =
SystemInformation
.PowerStatus;
68
PowerStatus status =
SystemInformation
.PowerStatus;
System\Windows\Forms\PropertyGridInternal\PropertyGridView.DropDownHolderTests.cs (1)
100
int resizeBarSize =
SystemInformation
.HorizontalScrollBarHeight + 1;
System\Windows\Forms\RichTextBoxTests.cs (1)
24
private static readonly int s_preferredHeight = Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3;
System\Windows\Forms\ScrollableControlTests.cs (4)
201
yield return new object[] { true, width, height, width - 20, height + 50, new Rectangle(0, 0, width -
SystemInformation
.VerticalScrollBarWidth, height) };
202
yield return new object[] { true, width, height, width + 50, height - 20, new Rectangle(0, 0, width, height -
SystemInformation
.HorizontalScrollBarHeight) };
203
yield return new object[] { true, width, height, width + 50, height + 50, new Rectangle(0, 0, width -
SystemInformation
.VerticalScrollBarWidth, height -
SystemInformation
.HorizontalScrollBarHeight) };
System\Windows\Forms\SystemInformationTests.cs (217)
18
int delay =
SystemInformation
.ActiveWindowTrackingDelay;
20
Assert.Equal(delay,
SystemInformation
.ActiveWindowTrackingDelay);
26
ArrangeDirection direction =
SystemInformation
.ArrangeDirection;
28
Assert.Equal(direction,
SystemInformation
.ArrangeDirection);
34
ArrangeStartingPosition position =
SystemInformation
.ArrangeStartingPosition;
36
Assert.Equal(position,
SystemInformation
.ArrangeStartingPosition);
42
BootMode bootMode =
SystemInformation
.BootMode;
44
Assert.Equal(bootMode,
SystemInformation
.BootMode);
50
Size size =
SystemInformation
.Border3DSize;
53
Assert.Equal(size,
SystemInformation
.Border3DSize);
59
int factor =
SystemInformation
.BorderMultiplierFactor;
61
Assert.Equal(factor,
SystemInformation
.BorderMultiplierFactor);
67
Size size =
SystemInformation
.BorderSize;
70
Assert.Equal(size,
SystemInformation
.BorderSize);
76
Size size =
SystemInformation
.CaptionButtonSize;
79
Assert.Equal(size,
SystemInformation
.CaptionButtonSize);
85
int height =
SystemInformation
.CaptionHeight;
87
Assert.Equal(height,
SystemInformation
.CaptionHeight);
93
int blinkTime =
SystemInformation
.CaretBlinkTime;
95
Assert.Equal(blinkTime,
SystemInformation
.CaretBlinkTime);
101
int height =
SystemInformation
.CaretWidth;
103
Assert.Equal(height,
SystemInformation
.CaretWidth);
109
string name =
SystemInformation
.ComputerName;
112
Assert.Equal(name,
SystemInformation
.ComputerName);
118
Size size =
SystemInformation
.CursorSize;
120
Assert.Equal(size,
SystemInformation
.CursorSize);
126
Assert.Equal(
SystemInformation
.DbcsEnabled,
SystemInformation
.DbcsEnabled);
132
Assert.Equal(
SystemInformation
.DbcsEnabled,
SystemInformation
.DebugOS);
138
Size size =
SystemInformation
.DoubleClickSize;
141
Assert.Equal(size,
SystemInformation
.DoubleClickSize);
147
int time =
SystemInformation
.DoubleClickTime;
149
Assert.Equal(time,
SystemInformation
.DoubleClickTime);
155
Assert.Equal(
SystemInformation
.DragFullWindows,
SystemInformation
.DragFullWindows);
161
Size size =
SystemInformation
.DragSize;
164
Assert.Equal(size,
SystemInformation
.DragSize);
170
Size size =
SystemInformation
.FixedFrameBorderSize;
173
Assert.Equal(size,
SystemInformation
.FixedFrameBorderSize);
179
int contrast =
SystemInformation
.FontSmoothingContrast;
181
Assert.Equal(contrast,
SystemInformation
.FontSmoothingContrast);
187
int contrast =
SystemInformation
.FontSmoothingType;
189
Assert.Equal(contrast,
SystemInformation
.FontSmoothingType);
195
Size size =
SystemInformation
.FrameBorderSize;
198
Assert.Equal(size,
SystemInformation
.FrameBorderSize);
204
Assert.Equal(
SystemInformation
.HighContrast,
SystemInformation
.HighContrast);
210
int thickness =
SystemInformation
.HorizontalFocusThickness;
212
Assert.Equal(thickness,
SystemInformation
.HorizontalFocusThickness);
218
int thickness =
SystemInformation
.HorizontalResizeBorderThickness;
220
Assert.Equal(thickness,
SystemInformation
.HorizontalResizeBorderThickness);
226
int width =
SystemInformation
.HorizontalScrollBarArrowWidth;
228
Assert.Equal(width,
SystemInformation
.GetHorizontalScrollBarArrowWidthForDpi(LogicalDpi));
229
Assert.Equal(width,
SystemInformation
.HorizontalScrollBarArrowWidth);
235
int height =
SystemInformation
.HorizontalScrollBarHeight;
237
Assert.Equal(height,
SystemInformation
.HorizontalScrollBarHeight);
243
int width =
SystemInformation
.HorizontalScrollBarThumbWidth;
245
Assert.Equal(width,
SystemInformation
.HorizontalScrollBarThumbWidth);
251
int spacing =
SystemInformation
.IconHorizontalSpacing;
253
Assert.Equal(spacing,
SystemInformation
.IconHorizontalSpacing);
259
Size size =
SystemInformation
.IconSize;
262
Assert.Equal(size,
SystemInformation
.IconSize);
268
Size size =
SystemInformation
.IconSpacingSize;
271
Assert.Equal(size,
SystemInformation
.IconSpacingSize);
277
int spacing =
SystemInformation
.IconVerticalSpacing;
279
Assert.Equal(spacing,
SystemInformation
.IconVerticalSpacing);
285
Assert.Equal(
SystemInformation
.IsActiveWindowTrackingEnabled,
SystemInformation
.IsActiveWindowTrackingEnabled);
291
Assert.Equal(
SystemInformation
.IsComboBoxAnimationEnabled,
SystemInformation
.IsComboBoxAnimationEnabled);
297
Assert.Equal(
SystemInformation
.IsDropShadowEnabled,
SystemInformation
.IsDropShadowEnabled);
303
Assert.Equal(
SystemInformation
.IsFlatMenuEnabled,
SystemInformation
.IsFlatMenuEnabled);
309
Assert.Equal(
SystemInformation
.IsFontSmoothingEnabled,
SystemInformation
.IsFontSmoothingEnabled);
315
Assert.Equal(
SystemInformation
.IsHotTrackingEnabled,
SystemInformation
.IsHotTrackingEnabled);
321
Assert.Equal(
SystemInformation
.IsIconTitleWrappingEnabled,
SystemInformation
.IsIconTitleWrappingEnabled);
327
Assert.Equal(
SystemInformation
.IsKeyboardPreferred,
SystemInformation
.IsKeyboardPreferred);
333
Assert.Equal(
SystemInformation
.IsListBoxSmoothScrollingEnabled,
SystemInformation
.IsListBoxSmoothScrollingEnabled);
339
Assert.Equal(
SystemInformation
.IsMenuAnimationEnabled,
SystemInformation
.IsMenuAnimationEnabled);
345
Assert.Equal(
SystemInformation
.IsMenuFadeEnabled,
SystemInformation
.IsMenuFadeEnabled);
351
Assert.Equal(
SystemInformation
.IsMinimizeRestoreAnimationEnabled,
SystemInformation
.IsMinimizeRestoreAnimationEnabled);
357
Assert.Equal(
SystemInformation
.IsSelectionFadeEnabled,
SystemInformation
.IsSelectionFadeEnabled);
363
Assert.Equal(
SystemInformation
.IsSnapToDefaultEnabled,
SystemInformation
.IsSnapToDefaultEnabled);
369
Assert.Equal(
SystemInformation
.IsTitleBarGradientEnabled,
SystemInformation
.IsTitleBarGradientEnabled);
375
Assert.Equal(
SystemInformation
.IsToolTipAnimationEnabled,
SystemInformation
.IsToolTipAnimationEnabled);
381
int height =
SystemInformation
.KanjiWindowHeight;
383
Assert.Equal(height,
SystemInformation
.KanjiWindowHeight);
389
int delay =
SystemInformation
.KeyboardDelay;
391
Assert.Equal(delay,
SystemInformation
.KeyboardDelay);
397
int speed =
SystemInformation
.KeyboardSpeed;
399
Assert.Equal(speed,
SystemInformation
.KeyboardSpeed);
405
Size size =
SystemInformation
.MaxWindowTrackSize;
408
Assert.Equal(size,
SystemInformation
.MaxWindowTrackSize);
414
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined,
SystemInformation
.MenuAccessKeysUnderlined);
420
Size size =
SystemInformation
.MenuBarButtonSize;
423
Assert.Equal(size,
SystemInformation
.MenuBarButtonSize);
429
Size size =
SystemInformation
.MenuButtonSize;
432
Assert.Equal(size,
SystemInformation
.MenuButtonSize);
438
Size size =
SystemInformation
.MenuCheckSize;
441
Assert.Equal(size,
SystemInformation
.MenuCheckSize);
447
Font font =
SystemInformation
.MenuFont;
449
Assert.Equal(font,
SystemInformation
.MenuFont);
455
int height =
SystemInformation
.MenuHeight;
457
Assert.Equal(height,
SystemInformation
.MenuHeight);
463
int delay =
SystemInformation
.MenuShowDelay;
465
Assert.Equal(delay,
SystemInformation
.MenuShowDelay);
471
Assert.Equal(
SystemInformation
.MidEastEnabled,
SystemInformation
.MidEastEnabled);
477
Size size =
SystemInformation
.MinimizedWindowSize;
480
Assert.Equal(size,
SystemInformation
.MinimizedWindowSize);
486
Size size =
SystemInformation
.MinimizedWindowSize;
489
Assert.Equal(size,
SystemInformation
.MinimizedWindowSpacingSize);
495
Size size =
SystemInformation
.MinimumWindowSize;
498
Assert.Equal(size,
SystemInformation
.MinimumWindowSize);
504
Size size =
SystemInformation
.MinWindowTrackSize;
507
Assert.Equal(size,
SystemInformation
.MinWindowTrackSize);
513
int count =
SystemInformation
.MonitorCount;
516
Assert.Equal(count,
SystemInformation
.MonitorCount);
522
Assert.Equal(
SystemInformation
.MonitorsSameDisplayFormat,
SystemInformation
.MonitorsSameDisplayFormat);
528
int count =
SystemInformation
.MouseButtons;
530
Assert.Equal(count,
SystemInformation
.MouseButtons);
536
Assert.Equal(
SystemInformation
.MouseButtonsSwapped,
SystemInformation
.MouseButtonsSwapped);
542
Size size =
SystemInformation
.MouseHoverSize;
545
Assert.Equal(size,
SystemInformation
.MouseHoverSize);
551
int count =
SystemInformation
.MouseHoverTime;
553
Assert.Equal(count,
SystemInformation
.MouseHoverTime);
559
Assert.Equal(
SystemInformation
.MousePresent,
SystemInformation
.MousePresent);
565
int count =
SystemInformation
.MouseSpeed;
567
Assert.Equal(count,
SystemInformation
.MouseSpeed);
573
Assert.Equal(
SystemInformation
.MouseWheelPresent,
SystemInformation
.MouseWheelPresent);
579
int delta =
SystemInformation
.MouseWheelScrollDelta;
581
Assert.Equal(delta,
SystemInformation
.MouseWheelScrollDelta);
587
int lines =
SystemInformation
.MouseWheelScrollLines;
589
Assert.Equal(lines,
SystemInformation
.MouseWheelScrollLines);
595
Assert.Equal(
SystemInformation
.NativeMouseWheelSupport,
SystemInformation
.NativeMouseWheelSupport);
601
Assert.Equal(
SystemInformation
.Network,
SystemInformation
.Network);
607
Assert.Equal(
SystemInformation
.PenWindows,
SystemInformation
.PenWindows);
613
LeftRightAlignment alignment =
SystemInformation
.PopupMenuAlignment;
615
Assert.Equal(alignment,
SystemInformation
.PopupMenuAlignment);
621
PowerStatus status =
SystemInformation
.PowerStatus;
623
Assert.Same(status,
SystemInformation
.PowerStatus);
629
Size size =
SystemInformation
.PrimaryMonitorMaximizedWindowSize;
632
Assert.Equal(size,
SystemInformation
.PrimaryMonitorMaximizedWindowSize);
638
Size size =
SystemInformation
.PrimaryMonitorSize;
641
Assert.Equal(size,
SystemInformation
.PrimaryMonitorSize);
647
Assert.Equal(
SystemInformation
.RightAlignedMenus,
SystemInformation
.RightAlignedMenus);
653
ScreenOrientation orientation =
SystemInformation
.ScreenOrientation;
655
Assert.Equal(orientation,
SystemInformation
.ScreenOrientation);
661
Assert.Equal(
SystemInformation
.Secure,
SystemInformation
.Secure);
667
Assert.Equal(
SystemInformation
.ShowSounds,
SystemInformation
.ShowSounds);
673
int width =
SystemInformation
.SizingBorderWidth;
675
Assert.Equal(width,
SystemInformation
.SizingBorderWidth);
681
Size size =
SystemInformation
.SmallCaptionButtonSize;
684
Assert.Equal(size,
SystemInformation
.SmallCaptionButtonSize);
690
Size size =
SystemInformation
.SmallIconSize;
693
Assert.Equal(size,
SystemInformation
.SmallIconSize);
699
Assert.Equal(
SystemInformation
.TerminalServerSession,
SystemInformation
.TerminalServerSession);
705
Size size =
SystemInformation
.ToolWindowCaptionButtonSize;
708
Assert.Equal(size,
SystemInformation
.ToolWindowCaptionButtonSize);
714
int height =
SystemInformation
.ToolWindowCaptionHeight;
716
Assert.Equal(height,
SystemInformation
.ToolWindowCaptionHeight);
722
Assert.Equal(
SystemInformation
.UIEffectsEnabled,
SystemInformation
.UIEffectsEnabled);
728
string domainName =
SystemInformation
.UserDomainName;
730
Assert.Equal(domainName,
SystemInformation
.UserDomainName);
736
Assert.Equal(
SystemInformation
.UserInteractive,
SystemInformation
.UserInteractive);
742
string name =
SystemInformation
.UserName;
745
Assert.Equal(name,
SystemInformation
.UserName);
751
int thickness =
SystemInformation
.VerticalFocusThickness;
753
Assert.Equal(thickness,
SystemInformation
.VerticalFocusThickness);
759
int thickness =
SystemInformation
.VerticalResizeBorderThickness;
761
Assert.Equal(thickness,
SystemInformation
.VerticalResizeBorderThickness);
767
int height =
SystemInformation
.VerticalScrollBarArrowHeight;
769
Assert.Equal(height,
SystemInformation
.VerticalScrollBarArrowHeightForDpi(LogicalDpi));
770
Assert.Equal(height,
SystemInformation
.VerticalScrollBarArrowHeight);
776
int height =
SystemInformation
.VerticalScrollBarThumbHeight;
778
Assert.Equal(height,
SystemInformation
.VerticalScrollBarThumbHeight);
784
int width =
SystemInformation
.VerticalScrollBarWidth;
786
Assert.Equal(width,
SystemInformation
.GetVerticalScrollBarWidthForDpi(LogicalDpi));
787
Assert.Equal(width,
SystemInformation
.VerticalScrollBarWidth);
793
Rectangle screen =
SystemInformation
.VirtualScreen;
796
Assert.Equal(screen,
SystemInformation
.VirtualScreen);
802
Rectangle workingArea =
SystemInformation
.WorkingArea;
807
Assert.Equal(workingArea,
SystemInformation
.WorkingArea);
822
Size size =
SystemInformation
.GetBorderSizeForDpi(dpi);
831
int width =
SystemInformation
.GetHorizontalScrollBarArrowWidthForDpi(dpi);
839
int height =
SystemInformation
.GetHorizontalScrollBarHeightForDpi(dpi);
847
Font font =
SystemInformation
.GetMenuFontForDpi(dpi);
855
int width =
SystemInformation
.GetVerticalScrollBarWidthForDpi(dpi);
863
int height =
SystemInformation
.VerticalScrollBarArrowHeightForDpi(dpi);
System\Windows\Forms\ToolStripButtonTests.cs (6)
83
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
164
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
251
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
341
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
429
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
527
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripControlHostTests.cs (1)
112
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripDropDownItemTests.cs (4)
83
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
172
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
271
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
379
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripDropDownTests.cs (12)
81
Assert.Equal(
SystemInformation
.IsDropShadowEnabled, control.DropShadowEnabled);
138
Assert.Equal(
SystemInformation
.WorkingArea.X + 2, control.Right);
171
Assert.Equal(
SystemInformation
.IsDropShadowEnabled ? 0x20808 : 0x808, createParams.ClassStyle);
186
yield return new object[] { true,
SystemInformation
.IsDropShadowEnabled ? 0x20808 : 0x808 };
217
yield return new object[] { true, 1.0,
SystemInformation
.IsDropShadowEnabled ? 0x20808 : 0x808, -0x7E000000, 0x10000 };
218
yield return new object[] { true, 0.5,
SystemInformation
.IsDropShadowEnabled ? 0x20008 : 0x8, -0x7E000000, 0x90000 };
219
yield return new object[] { false, 1.0,
SystemInformation
.IsDropShadowEnabled ? 0x20008 : 0x8, 0x46000000, 0x10000 };
220
yield return new object[] { false, 0.5,
SystemInformation
.IsDropShadowEnabled ? 0x20008 : 0x8, 0x46000000, 0x10000 };
1933
expected.X = Math.Max(expected.X,
SystemInformation
.WorkingArea.X);
1934
expected.Y = Math.Max(expected.Y,
SystemInformation
.WorkingArea.Y);
1936
if (expectedLocationChangedCallCount == 0 &&
SystemInformation
.WorkingArea.Location != Point.Empty)
5007
var nonClientSize =
SystemInformation
.BorderSize;
System\Windows\Forms\ToolStripItemTests.cs (3)
82
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
167
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
262
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripMenuItemTests.cs (1)
86
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripSeparatorTests.cs (1)
80
Assert.Equal(
SystemInformation
.MenuAccessKeysUnderlined, item.ShowKeyboardCues);
System\Windows\Forms\ToolStripTests.cs (1)
7317
await Assert.ThrowsAsync<TaskCanceledException>(() => Task.Delay(
SystemInformation
.MouseHoverTime * 2, cancellationTokenSource.Token));
System\Windows\Forms\UpDownBaseTests.cs (8)
721
yield return new object[] { BorderStyle.Fixed3D, new Size(122, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
722
yield return new object[] { BorderStyle.FixedSingle, new Size(122, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
727
yield return new object[] { BorderStyle.Fixed3D, new Size(123, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
728
yield return new object[] { BorderStyle.FixedSingle, new Size(121, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
758
yield return new object[] { BorderStyle.Fixed3D, 0, 0, new Size(122, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
759
yield return new object[] { BorderStyle.FixedSingle, 0, 1, new Size(122, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
764
yield return new object[] { BorderStyle.Fixed3D, 0, 0, new Size(123, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
765
yield return new object[] { BorderStyle.FixedSingle, 1, 1, new Size(123, Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3) };
TextBoxBaseTests.cs (1)
18
private static readonly int s_preferredHeight = Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3;
TextBoxTests.cs (1)
15
private static readonly int s_preferredHeight = Control.DefaultFont.Height +
SystemInformation
.BorderSize.Height * 4 + 3;
TrackBarTests.cs (1)
16
public static readonly int s_dimension = (
SystemInformation
.HorizontalScrollBarHeight * 8) / 3;
System.Windows.Forms.UI.IntegrationTests (7)
ButtonTests.cs (2)
260
Size primaryMonitor =
SystemInformation
.PrimaryMonitorSize;
296
Size primaryMonitor =
SystemInformation
.PrimaryMonitorSize;
DragDropTests.cs (3)
196
Rectangle vscreen =
SystemInformation
.VirtualScreen;
716
Size dragSize =
SystemInformation
.DragSize;
765
_screenOffset =
SystemInformation
.WorkingArea.Location;
Infra\ControlTestBase.cs (2)
183
Size primaryMonitor =
SystemInformation
.PrimaryMonitorSize;
192
Size primaryMonitor =
SystemInformation
.PrimaryMonitorSize;