175 references to WindowsFormsUtils
System.Windows.Forms (175)
winforms\Managed\System\WinForms\ButtonBase.cs (8)
211
if ((int)(align &
WindowsFormsUtils
.AnyLeftAlign) != 0) {
214
else if ((int)(align &
WindowsFormsUtils
.AnyRightAlign) != 0) {
221
if ((int)(align &
WindowsFormsUtils
.AnyTopAlign) != 0) {
224
else if ((int)(align &
WindowsFormsUtils
.AnyBottomAlign) != 0) {
382
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
663
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
689
if (!
WindowsFormsUtils
.EnumValidator.IsValidTextImageRelation(value)) {
828
textToolTip.Show(
WindowsFormsUtils
.TextWithoutMnemonics(Text), this);
winforms\Managed\System\WinForms\ButtonInternal\ButtonBaseAdapter.cs (2)
56
using (Graphics measurementGraphics =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
1445
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
winforms\Managed\System\WinForms\ButtonInternal\CheckableControlBaseAdapter.cs (1)
39
using (Graphics measurementGraphics =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
winforms\Managed\System\WinForms\ButtonInternal\CheckBoxStandardAdapter.cs (2)
84
using (Graphics measurementGraphics =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
113
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
winforms\Managed\System\WinForms\ButtonInternal\RadioButtonStandardAdapter.cs (1)
74
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
winforms\Managed\System\WinForms\CheckBox.cs (1)
192
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
winforms\Managed\System\WinForms\ColumnHeader.cs (1)
270
return
WindowsFormsUtils
.GetComponentName(this,name);
winforms\Managed\System\WinForms\ContextMenuStrip.cs (1)
110
bounds =
WindowsFormsUtils
.ConstrainToBounds(screenBounds, bounds);
winforms\Managed\System\WinForms\Control.cs (13)
10373
using (
WindowsFormsUtils
.DCMapping mapping = new
WindowsFormsUtils
.DCMapping(hDC, bounds)) {
10385
using (
WindowsFormsUtils
.DCMapping clientMapping = new
WindowsFormsUtils
.DCMapping(hDC, clientBounds)) {
12384
if ((align &
WindowsFormsUtils
.AnyTopAlign) != 0) {
12392
if ((align &
WindowsFormsUtils
.AnyMiddleAlign) != 0 ) {
12401
if ((align &
WindowsFormsUtils
.AnyBottomAlign) != 0 ) {
14932
if (
WindowsFormsUtils
.SafeCompareStrings(controlsToLookIn[i].Name, key, /* ignoreCase = */ true)) {
14984
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
14991
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
16976
char mnemonic =
WindowsFormsUtils
.GetMnemonic(control.Text, true);
19692
char mnemonic =
WindowsFormsUtils
.GetMnemonic(this.TextLabel, false);
19712
return
WindowsFormsUtils
.TextWithoutMnemonics(TextLabel);
winforms\Managed\System\WinForms\DataGridViewAdvancedBorderStyle.cs (1)
329
return
WindowsFormsUtils
.GetCombinedHashCodes((int) this.top,
winforms\Managed\System\WinForms\DataGridViewCell.cs (6)
1783
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
1831
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
2574
using( Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
2587
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
2631
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
3147
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
winforms\Managed\System\WinForms\DataGridViewCellStyle.cs (1)
717
return
WindowsFormsUtils
.GetCombinedHashCodes((int) this.Alignment,
winforms\Managed\System\WinForms\DataGridViewComboBoxCell.cs (2)
759
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
2013
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
winforms\Managed\System\WinForms\DataGridViewHitTestInfo.cs (1)
128
return
WindowsFormsUtils
.GetCombinedHashCodes((int) this.type,
winforms\Managed\System\WinForms\DataGridViewTextBoxCell.cs (1)
276
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics())
winforms\Managed\System\WinForms\DataObject.cs (2)
879
if (
WindowsFormsUtils
.TargetsAtLeast_v4_5) {
1459
if (
WindowsFormsUtils
.TargetsAtLeast_v4_5) {
winforms\Managed\System\WinForms\DateTimePicker.cs (2)
1764
char previousLabelMnemonic =
WindowsFormsUtils
.GetMnemonic(previousLabel.Text, false /*convertToUpperCase*/);
1773
char ownerTextMnemonic =
WindowsFormsUtils
.GetMnemonic(this.Owner.Text, false /*convertToUpperCase*/);
winforms\Managed\System\WinForms\Form.cs (2)
1750
value =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(bounds).Size;
5989
adjustedBounds =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(adjustedBounds);
winforms\Managed\System\WinForms\ImageList.cs (2)
1493
(
WindowsFormsUtils
.SafeCompareStrings(((ImageInfo)imageInfoCollection[lastAccessedIndex]).Name, key, /* ignoreCase = */ true))) {
1501
(
WindowsFormsUtils
.SafeCompareStrings(((ImageInfo)imageInfoCollection[i]).Name, key, /* ignoreCase = */ true))) {
winforms\Managed\System\WinForms\Label.cs (10)
660
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
886
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
1092
if ((align &
WindowsFormsUtils
.AnyRightAlign) !=0) {
1095
else if ((align &
WindowsFormsUtils
.AnyCenterAlign) != 0) {
1100
if ((align &
WindowsFormsUtils
.AnyBottomAlign) != 0) {
1103
else if ((align &
WindowsFormsUtils
.AnyTopAlign) != 0) {
1310
using (Graphics measurementGraphics =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
1404
textToolTip.Show(
WindowsFormsUtils
.TextWithoutMnemonics(Text), this);
1622
using (
WindowsFormsUtils
.DCMapping mapping = new
WindowsFormsUtils
.DCMapping(hDC, bounds)) {
winforms\Managed\System\WinForms\LinkLabel.cs (8)
507
if ((align &
WindowsFormsUtils
.AnyRightAlign) != 0) {
509
} else if ((align &
WindowsFormsUtils
.AnyCenterAlign) != 0) {
515
if ((align &
WindowsFormsUtils
.AnyBottomAlign) != 0) {
517
} else if ((align &
WindowsFormsUtils
.AnyMiddleAlign) != 0) {
2259
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
2266
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
2772
name =
WindowsFormsUtils
.TextWithoutMnemonics(name);
2780
name =
WindowsFormsUtils
.TextWithoutMnemonics(name);
winforms\Managed\System\WinForms\ListView.cs (10)
6861
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
6868
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
7653
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
7660
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
7816
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
7823
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
8613
if (
WindowsFormsUtils
.SafeCompareStrings(listViewItems[i].Name, key, /* ignoreCase = */ true)) {
8620
if (
WindowsFormsUtils
.SafeCompareStrings(listViewItems[i].SubItems[j].Name, key, /* ignoreCase = */ true)) {
8680
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
8687
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
winforms\Managed\System\WinForms\ListViewItem.cs (4)
917
if (
WindowsFormsUtils
.SafeCompareStrings(toolTipText, value, false /*ignoreCase*/)) {
2048
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
2055
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
2172
return new
WindowsFormsUtils
.ArraySubsetEnumerator(owner.subItems, owner.SubItemCount);
winforms\Managed\System\WinForms\MdiWindowListStrip.cs (1)
102
string text =
WindowsFormsUtils
.EscapeTextWithAmpersands(mdiParent.MdiChildren[i].Text);
winforms\Managed\System\WinForms\Menu.cs (5)
148
return
WindowsFormsUtils
.GetComponentName(this, name);
981
if (
WindowsFormsUtils
.SafeCompareStrings(menuItemsToLookIn[i].Name, key, /* ignoreCase = */ true)) {
1039
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
1046
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
1116
return new
WindowsFormsUtils
.ArraySubsetEnumerator(owner.items, owner.ItemCount);
winforms\Managed\System\WinForms\MenuItem.cs (1)
1638
mnemonic = (short)
WindowsFormsUtils
.GetMnemonic(caption, true);
winforms\Managed\System\WinForms\MenuStrip.cs (2)
252
UnsafeNativeMethods.PostMessage(
WindowsFormsUtils
.GetRootHWnd(this), NativeMethods.WM_SYSCOMMAND, NativeMethods.SC_KEYMENU, (int)Keys.Space);
271
Point pt = PointToClient(
WindowsFormsUtils
.LastCursorPoint);
winforms\Managed\System\WinForms\MessageBox.cs (2)
424
if (!
WindowsFormsUtils
.EnumValidator.IsEnumWithinShiftedRange(icon, /*numBitsToShift*/4, /*min*/0x0,/*max*/0x4)) {
428
if (!
WindowsFormsUtils
.EnumValidator.IsEnumWithinShiftedRange(defaultButton, /*numBitsToShift*/8, /*min*/0x0,/*max*/0x2)) {
winforms\Managed\System\WinForms\Padding.cs (3)
221
^
WindowsFormsUtils
.RotateLeft(Top, 8)
222
^
WindowsFormsUtils
.RotateLeft(Right, 16)
223
^
WindowsFormsUtils
.RotateLeft(Bottom, 24);
winforms\Managed\System\WinForms\Panel.cs (2)
294
using (
WindowsFormsUtils
.DCMapping mapping = new
WindowsFormsUtils
.DCMapping(hDC, bounds)) {
winforms\Managed\System\WinForms\ProfessionalColorTable.cs (1)
481
using (Graphics g =
WindowsFormsUtils
.CreateMeasurementGraphics()) {
winforms\Managed\System\WinForms\RadioButton.cs (1)
187
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
winforms\Managed\System\WinForms\SplitContainer.cs (3)
160
((
WindowsFormsUtils
.TypedControlCollection)this.Controls).AddInternal(panel1);
161
((
WindowsFormsUtils
.TypedControlCollection)this.Controls).AddInternal(panel2);
2569
internal class SplitContainerTypedControlCollection :
WindowsFormsUtils
.TypedControlCollection {
winforms\Managed\System\WinForms\StatusBar.cs (2)
1460
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
1467
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
winforms\Managed\System\WinForms\StatusBarPanel.cs (1)
288
return
WindowsFormsUtils
.GetComponentName(this, name);
winforms\Managed\System\WinForms\StatusStrip.cs (6)
194
HandleRef rootHwnd =
WindowsFormsUtils
.GetRootHWnd(this);
283
WindowsFormsUtils
.ReadOnlyControlCollection controlCollection = this.Controls as
WindowsFormsUtils
.ReadOnlyControlCollection;
292
WindowsFormsUtils
.ReadOnlyControlCollection controlCollection = this.Controls as
WindowsFormsUtils
.ReadOnlyControlCollection;
563
HandleRef rootHwnd =
WindowsFormsUtils
.GetRootHWnd(this);
winforms\Managed\System\WinForms\TabControl.cs (2)
2519
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
2526
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
winforms\Managed\System\WinForms\TableLayoutPanelCellPosition.cs (1)
73
return
WindowsFormsUtils
.GetCombinedHashCodes(
winforms\Managed\System\WinForms\TableLayoutSettings.cs (1)
540
if (
WindowsFormsUtils
.SafeCompareStrings(name, controlName as string, /* ignoreCase = */ false)) {
winforms\Managed\System\WinForms\ToolBar.cs (3)
2065
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
2072
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
2169
return new
WindowsFormsUtils
.ArraySubsetEnumerator(owner.buttons, owner.buttonCount);
winforms\Managed\System\WinForms\ToolBarButton.cs (2)
241
return
WindowsFormsUtils
.GetComponentName(this, name);
407
UpdateButton(
WindowsFormsUtils
.ContainsMnemonic(text), true, true);
winforms\Managed\System\WinForms\ToolStrip.cs (14)
2230
if (!
WindowsFormsUtils
.EnumValidator.IsValidArrowDirection(direction)) {
2596
return
WindowsFormsUtils
.CreateMeasurementGraphics();
2758
if (!
WindowsFormsUtils
.ContainsMnemonic(text)) {
4116
Debug.WriteLineIf(SnapFocusDebug.TraceVerbose, "[ToolStrip RestoreFocus]: Will Restore Focus to: " +
WindowsFormsUtils
.GetControlInformation(hwndThatLostFocus));
4224
Point mousePosition =
WindowsFormsUtils
.LastCursorPoint;
4485
mouseEnterWhenShown =
WindowsFormsUtils
.LastCursorPoint;
4539
HandleRef thisHwndRoot =
WindowsFormsUtils
.GetRootHWnd(this);
4540
HandleRef otherHwndRoot =
WindowsFormsUtils
.GetRootHWnd(otherHandle);
4543
Debug.WriteLineIf(SnapFocusDebug.TraceVerbose, "[ToolStrip SnapFocus]: Caching for return focus:" +
WindowsFormsUtils
.GetControlInformation(otherHandle.Handle));
4621
cursorLocation =
WindowsFormsUtils
.ConstrainToScreenBounds(new Rectangle(cursorLocation, onePixel)).Location;
4719
Point pt = PointToClient(
WindowsFormsUtils
.LastCursorPoint);
4731
HandleRef rootHwnd =
WindowsFormsUtils
.GetRootHWnd(this);
4799
return new
WindowsFormsUtils
.ReadOnlyControlCollection(this, /* isReadOnly = */ !DesignMode);
5166
HandleRef rootHwnd =
WindowsFormsUtils
.GetRootHWnd(ownerToolStrip);
winforms\Managed\System\WinForms\ToolStripContainer.cs (1)
445
internal class ToolStripContainerTypedControlCollection :
WindowsFormsUtils
.ReadOnlyControlCollection {
winforms\Managed\System\WinForms\ToolStripControlHost.cs (6)
144
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
850
WindowsFormsUtils
.ReadOnlyControlCollection oldControlCollection
972
private static
WindowsFormsUtils
.ReadOnlyControlCollection GetControlCollection(ToolStrip toolStrip) {
973
WindowsFormsUtils
.ReadOnlyControlCollection newControls =
974
toolStrip != null ? (
WindowsFormsUtils
.ReadOnlyControlCollection) toolStrip.Controls : null;
980
WindowsFormsUtils
.ReadOnlyControlCollection newControls = GetControlCollection(ParentInternal);
winforms\Managed\System\WinForms\ToolStripDropDown.cs (7)
1193
adjustedBounds =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(adjustedBounds);
1216
dropDownBounds =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(suggestedScreenBounds);
1219
dropDownBounds =
WindowsFormsUtils
.ConstrainToScreenBounds(suggestedScreenBounds);
1267
dropDownBounds =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(dropDownBounds);
1454
if (OwnerItem.Bounds.Contains(
WindowsFormsUtils
.TranslatePoint(mea.Location, this, OwnerToolStrip))) {
2149
Debug.Fail("Why are we being activated when we're not visible? Deactivating thingee is " +
WindowsFormsUtils
.GetControlInformation(m.LParam));
2153
Debug.WriteLineIf(ToolStrip.SnapFocusDebug.TraceVerbose, "[ToolStripDropDown.WndProc] activating thingee is " +
WindowsFormsUtils
.GetControlInformation(m.LParam));
winforms\Managed\System\WinForms\ToolStripDropDownItem.cs (1)
343
dropDownBounds =
WindowsFormsUtils
.ConstrainToScreenWorkingAreaBounds(dropDownBounds);
winforms\Managed\System\WinForms\ToolStripItem.cs (7)
1218
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
1711
return
WindowsFormsUtils
.GetComponentName(this, (string)Properties.GetObject(ToolStripItem.PropName));
2298
if (!
WindowsFormsUtils
.EnumValidator.IsValidContentAlignment(value)) {
2366
if (!
WindowsFormsUtils
.EnumValidator.IsValidTextImageRelation(value)) {
2390
if (
WindowsFormsUtils
.ContainsMnemonic(toolText)) {
4125
char mnemonic =
WindowsFormsUtils
.GetMnemonic(ownerItem.Text, false);
4209
return
WindowsFormsUtils
.TextWithoutMnemonics(ownerItem.Text);
winforms\Managed\System\WinForms\ToolStripItemCollection.cs (3)
298
if (
WindowsFormsUtils
.SafeCompareStrings(itemsToLookIn[i].Name, key, /* ignoreCase = */ true))
396
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
403
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
winforms\Managed\System\WinForms\ToolStripManager.cs (9)
256
return (
WindowsFormsUtils
.GetRootHWnd(control1).Handle ==
WindowsFormsUtils
.GetRootHWnd(control2).Handle);
1167
Debug.WriteLineIf(ToolStrip.SnapFocusDebug.TraceVerbose, "[ModalMenuFilter.SetActiveToolStripCore] Setting " +
WindowsFormsUtils
.GetControlInformation(toolStrip.Handle) + " active.");
1254
Debug.WriteLineIf(ToolStrip.SnapFocusDebug.TraceVerbose, "[ModalMenuFilter.PreFilterMessage] Dismissing because: " +
WindowsFormsUtils
.GetControlInformation(hwndCurrentActiveWindow.Handle) + " has gotten activation. ");
1260
Debug.WriteLineIf(ToolStrip.SnapFocusDebug.TraceVerbose, "[ModalMenuFilter.PreFilterMessage] Calling ProcessActivationChange because: " +
WindowsFormsUtils
.GetControlInformation(hwndCurrentActiveWindow.Handle) + " has gotten activation. ");
1641
HandleRef rootWindowOfToolStrip =
WindowsFormsUtils
.GetRootHWnd(topMostToolStrip);
1642
HandleRef rootWindowOfControl =
WindowsFormsUtils
.GetRootHWnd(activeControl);
1745
HandleRef topmostParentOfMenu =
WindowsFormsUtils
.GetRootHWnd(menuStripToActivate);
1836
if (
WindowsFormsUtils
.SafeCompareStrings(source.Text, candidateItem.Text, true)) {
winforms\Managed\System\WinForms\ToolStripPanel.cs (2)
1003
Point currentCursorLoc = PointToClient(
WindowsFormsUtils
.LastCursorPoint);
1536
internal class ToolStripPanelControlCollection :
WindowsFormsUtils
.TypedControlCollection {
winforms\Managed\System\WinForms\TreeNodeCollection.cs (4)
288
if (
WindowsFormsUtils
.SafeCompareStrings(treeNodeCollectionToLookIn[i].Name, key, /* ignoreCase = */ true)) {
436
if (
WindowsFormsUtils
.SafeCompareStrings(this[lastAccessedIndex].Name, key, /* ignoreCase = */ true)) {
443
if (
WindowsFormsUtils
.SafeCompareStrings(this[i].Name, key, /* ignoreCase = */ true)) {
627
return new
WindowsFormsUtils
.ArraySubsetEnumerator(owner.children, owner.childCount);