68 references to Properties
System.Windows.Forms (67)
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (60)
182
internal bool IsAccessibilityObjectCreated =>
Properties
.ContainsKey(s_accessibilityProperty);
195
if (!
Properties
.TryGetValue(s_accessibilityProperty, out AccessibleObject? accessibleObject))
197
accessibleObject =
Properties
.AddValue(s_accessibilityProperty, CreateAccessibilityInstance());
214
get =>
Properties
.GetValueOrDefault<string>(s_accessibleDefaultActionDescriptionProperty);
217
Properties
.AddOrRemoveValue(s_accessibleDefaultActionDescriptionProperty, value);
231
get =>
Properties
.GetValueOrDefault<string>(s_accessibleDescriptionProperty);
234
Properties
.AddOrRemoveValue(s_accessibleDescriptionProperty, value);
248
get =>
Properties
.GetValueOrDefault<string>(s_accessibleNameProperty);
251
Properties
.AddOrRemoveValue(s_accessibleNameProperty, value);
264
get =>
Properties
.GetValueOrDefault(s_accessibleRoleProperty, AccessibleRole.Default);
268
Properties
.AddOrRemoveValue(s_accessibleRoleProperty, value, defaultValue: AccessibleRole.Default);
390
get =>
Properties
.GetValueOrDefault<Image>(s_backgroundImageProperty);
393
if (
Properties
.AddOrRemoveValue(s_backgroundImageProperty, value) != value)
494
get =>
Properties
.GetValueOrDefault(s_backgroundImageLayoutProperty, ImageLayout.Tile);
498
if (
Properties
.AddOrRemoveValue(s_backgroundImageLayoutProperty, value, defaultValue: ImageLayout.Tile) != value)
531
Properties
.AddOrRemoveValue(s_backColorProperty, value, defaultValue: Color.Empty);
868
Color foreColor =
Properties
.GetValueOrDefault<Color>(s_foreColorProperty);
885
Properties
.AddOrRemoveValue(s_foreColorProperty, value);
928
if (
Properties
.AddOrRemoveValue(s_fontProperty, value) != value)
985
PropertyStore IArrangedElement.Properties =>
Properties
;
1030
Image? image =
Properties
.GetValueOrDefault<Image>(s_imageProperty);
1039
Properties
.AddValue(s_imageProperty, image);
1072
Properties
.AddOrRemoveValue(s_imageProperty, value);
1138
Properties
.RemoveValue(s_imageProperty);
1167
Properties
.RemoveValue(s_imageProperty);
1201
Color color =
Properties
.GetValueOrDefault<Color>(s_foreColorProperty);
1289
get =>
Properties
.GetValueOrDefault(s_mergeActionProperty, MergeAction.Append);
1293
Properties
.AddOrRemoveValue(s_mergeActionProperty, value, defaultValue: MergeAction.Append);
1305
get =>
Properties
.GetValueOrDefault(s_mergeIndexProperty, -1);
1306
set =>
Properties
.AddOrRemoveValue(s_mergeIndexProperty, value, -1);
1391
get => WindowsFormsUtils.GetComponentName(this,
Properties
.GetValueOrDefault<string>(s_nameProperty));
1399
Properties
.AddOrRemoveValue(s_nameProperty, value);
1561
Image? image =
Properties
.GetValueOrDefault<Image>(s_imageProperty);
1614
internal Color RawBackColor =>
Properties
.GetValueOrDefault(s_backColorProperty, Color.Empty);
1644
if (!
Properties
.TryGetValue(s_rightToLeftProperty, out RightToLeft rightToLeft))
1675
if (
Properties
.ContainsKey(s_rightToLeftProperty) || value != RightToLeft.Inherit)
1677
Properties
.AddValue(s_rightToLeftProperty, value);
1725
Properties
.AddValue(s_mirroredImageProperty, mirroredImage);
1730
return
Properties
.GetValueOrDefault<Image>(s_mirroredImageProperty);
1850
get =>
Properties
.GetValueOrDefault<object>(s_tagProperty);
1851
set =>
Properties
.AddOrRemoveValue(s_tagProperty, value);
1863
get =>
Properties
.TryGetValueOrNull(s_textProperty, out string? value) ? value : string.Empty;
1866
if (
Properties
.AddOrRemoveValue(s_textProperty, value, defaultValue: string.Empty) != value)
1909
ToolStripTextDirection textDirection =
Properties
.GetValueOrDefault(s_textDirectionProperty, ToolStripTextDirection.Inherit);
1929
Properties
.AddOrRemoveValue(s_textDirectionProperty, value, defaultValue: ToolStripTextDirection.Inherit);
2112
Properties
.RemoveValue(s_mirroredImageProperty);
2113
Properties
.RemoveValue(s_imageProperty);
2401
Properties
.RemoveValue(s_imageProperty);
2888
Color backColor =
Properties
.GetValueOrDefault<Color>(s_backColorProperty);
2936
Color foreColor =
Properties
.GetValueOrDefault<Color>(s_foreColorProperty);
2946
if (!
Properties
.TryGetValue(s_rightToLeftProperty, out RightToLeft rightToLeft) || rightToLeft == RightToLeft.Inherit)
2962
if (!
Properties
.TryGetValue(s_rightToLeftProperty, out RightToLeft rightToLeft))
2977
ToolStripTextDirection textDirection =
Properties
.GetValueOrDefault(s_textDirectionProperty, ToolStripTextDirection.Inherit);
3095
if (
Properties
.TryGetValue(s_accessibilityProperty, out AccessibleObject? accessibleObject))
3098
Properties
.RemoveValue(s_accessibilityProperty);
3295
Color backColor =
Properties
.GetValueOrDefault<Color>(s_backColorProperty);
3309
Color foreColor =
Properties
.GetValueOrDefault<Color>(s_foreColorProperty);
3363
if (!
Properties
.TryGetValue(s_rightToLeftProperty, out RightToLeft rightToLeft))
3371
private bool ShouldSerializeTextDirection() =>
Properties
.ContainsKey(s_textDirectionProperty);
3640
internal bool TryGetExplicitlySetFont([NotNullWhen(true)] out Font? local) =>
Properties
.TryGetValue(s_fontProperty, out local);
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (7)
111
Properties
.AddOrRemoveValue(s_propMdiForm, mdiForm);
302
get =>
Properties
.GetValueOrDefault(s_propCheckState, CheckState.Unchecked);
310
Properties
.AddOrRemoveValue(s_propCheckState, value, defaultValue: CheckState.Unchecked);
359
get =>
Properties
.GetValueOrDefault(s_propShortcutKeys, Keys.None);
395
Properties
.AddOrRemoveValue(s_propShortcutKeys, value, defaultValue: Keys.None);
480
internal Form? MdiForm =>
Properties
.GetValueOrDefault<Form>(s_propMdiForm);
576
Properties
.RemoveValue(s_propMdiForm);
System.Windows.Forms.Tests (1)
System\Windows\Forms\ToolStripItemTests.cs (1)
15633
return !
Properties
.ContainsKey(key);