83 instantiations of InstanceDescriptor
PresentationCore (22)
System\Windows\CultureInfoConverter.cs (1)
139return new InstanceDescriptor(method, new object[] { culture.Name });
System\Windows\DurationConverter.cs (3)
109return new InstanceDescriptor(mi, new object[] { duration.TimeSpan }); 114return new InstanceDescriptor(mi, null); 121return new InstanceDescriptor(mi, null);
System\Windows\FontStretchConverter.cs (1)
96return new InstanceDescriptor(mi, new object[]{c.ToOpenTypeStretch()});
System\Windows\FontStyleConverter.cs (1)
96return new InstanceDescriptor(ci, new object[]{c});
System\Windows\FontWeightConverter.cs (1)
96return new InstanceDescriptor(mi, new object[]{c.ToOpenTypeWeight()});
System\Windows\Ink\StrokeCollectionConverter.cs (1)
138return new InstanceDescriptor(ci, new object[] { stream });
System\Windows\Markup\XmlLanguageConverter.cs (1)
132return new InstanceDescriptor(method, new object[] { xmlLanguage.IetfLanguageTag });
System\Windows\Media\Animation\KeySplineConverter.cs (1)
107return new InstanceDescriptor(ci, new object[]
System\Windows\Media\Animation\KeyTimeConverter.cs (4)
148return new InstanceDescriptor(mi, new object[] { keyTime.Percent }); 154return new InstanceDescriptor(mi, new object[] { keyTime.TimeSpan }); 160return new InstanceDescriptor(mi, null); 166return new InstanceDescriptor(mi, null);
System\Windows\Media\Animation\RepeatBehaviorConverter.cs (3)
127return new InstanceDescriptor(mi, null); 133return new InstanceDescriptor(mi, new object[] { repeatBehavior.Count }); 139return new InstanceDescriptor(mi, new object[] { repeatBehavior.Duration });
System\Windows\Media\ColorConverter.cs (1)
106return new InstanceDescriptor(mi, new object[]{c.A, c.R, c.G, c.B});
System\Windows\Media\PixelFormatConverter.cs (1)
102return new InstanceDescriptor(ci, new object[]{p.ToString()});
System\Windows\Media\RequestCachePolicyConverter.cs (2)
116return new InstanceDescriptor(ci, new object[] { httpPolicy.Level }); 131return new InstanceDescriptor(ci, new object[] { policy.Level });
System\Windows\TextDecorationCollectionConverter.cs (1)
175return new InstanceDescriptor(ci, new object[]{value});
PresentationFramework (10)
System\Windows\Controls\DataGridLengthConverter.cs (1)
143return new InstanceDescriptor(ci, new object[] { length.Value, length.UnitType });
System\Windows\Controls\VirtualizationCacheLengthConverter.cs (1)
146return (new InstanceDescriptor(ci, new object[] { gl.CacheBeforeViewport, gl.CacheAfterViewport }));
System\Windows\CornerRadiusConverter.cs (1)
132return new InstanceDescriptor(ci, new object[] { cr.TopLeft, cr.TopRight, cr.BottomRight, cr.BottomLeft });
System\Windows\DynamicResourceExtensionConverter.cs (1)
50return new InstanceDescriptor(typeof(DynamicResourceExtension).GetConstructor(new Type[] { typeof(object) }),
System\Windows\FigureLengthConverter.cs (1)
159return (new InstanceDescriptor(ci, new object[] { fl.Value, fl.FigureUnitType }));
System\Windows\GridLengthConverter.cs (1)
179return (new InstanceDescriptor(ci, new object[] { gl.Value, gl.GridUnitType }));
System\Windows\LengthConverter.cs (1)
154return new InstanceDescriptor(ci, new object[] { l });
System\Windows\TemplateBindingExtensionConverter.cs (1)
54return new InstanceDescriptor(typeof(TemplateBindingExtension).GetConstructor(new Type[] { typeof(DependencyProperty) }),
System\Windows\ThemeModeConverter.cs (1)
107return new InstanceDescriptor(ci, new object[] { value });
System\Windows\ThicknessConverter.cs (1)
132return new InstanceDescriptor(ci, new object[] { thickness.Left, thickness.Top, thickness.Right, thickness.Bottom });
System.ComponentModel.TypeConverter (22)
System\ComponentModel\CultureInfoConverter.cs (1)
160return new InstanceDescriptor(
System\ComponentModel\DateOnlyConverter.cs (1)
98return new InstanceDescriptor(typeof(DateOnly).GetConstructor(new Type[] { typeof(int), typeof(int), typeof(int) }), new object[] { date.Year, date.Month, date.Day });
System\ComponentModel\DateTimeConverter.cs (2)
125return new InstanceDescriptor( 131return new InstanceDescriptor(
System\ComponentModel\DateTimeOffsetConverter.cs (2)
137return new InstanceDescriptor( 143return new InstanceDescriptor(
System\ComponentModel\DecimalConverter.cs (1)
50return new InstanceDescriptor(ctor, new object[] { decimal.GetBits(decimalValue) });
System\ComponentModel\EnumConverter.cs (2)
158return new InstanceDescriptor(method, new object[] { EnumType, convertedValue }); 170return new InstanceDescriptor(info, null);
System\ComponentModel\GuidConverter.cs (1)
62return new InstanceDescriptor(ctor, new object?[] { value.ToString() });
System\ComponentModel\NullableConverter.cs (1)
112return new InstanceDescriptor(ci, new object?[] { value }, true);
System\ComponentModel\TimeOnlyConverter.cs (2)
95return new InstanceDescriptor(typeof(TimeOnly).GetConstructor(new Type[] { typeof(long) }), new object[] { time.Ticks }); 98return new InstanceDescriptor(typeof(TimeOnly).GetConstructor(new Type[] { typeof(int), typeof(int), typeof(int), typeof(int), typeof(int) }),
System\ComponentModel\TimeSpanConverter.cs (1)
69return new InstanceDescriptor(
System\ComponentModel\UriTypeConverter.cs (1)
75return new InstanceDescriptor(ctor, new object[] { uri.OriginalString, GetUriKind(uri) });
System\ComponentModel\VersionConverter.cs (1)
76return new InstanceDescriptor(ctor, new object[] { version.Major, version.Minor, version.Build, version.Revision });
System\Drawing\ColorConverter.cs (1)
128return new InstanceDescriptor(member, args);
System\Drawing\PointConverter.cs (1)
87return new InstanceDescriptor(ctor, new object[] { pt.X, pt.Y });
System\Drawing\RectangleConverter.cs (1)
89return new InstanceDescriptor(ctor, new object[] {
System\Drawing\SizeConverter.cs (1)
85return new InstanceDescriptor(ctor, new object[] { size.Width, size.Height });
System\Drawing\SizeFConverter.cs (1)
82return new InstanceDescriptor(ctor, new object[] { size.Width, size.Height });
System\Security\Authentication\ExtendedProtection\ExtendedProtectionPolicyTypeConverter.cs (1)
53return new InstanceDescriptor(constructor, parameterValues);
System.Data.Common (6)
System\Data\ColumnTypeConverter.cs (1)
99return new InstanceDescriptor(method, new object[] { ((Type)newValue).AssemblyQualifiedName! });
System\Data\Common\DataColumnMapping.cs (1)
174return new InstanceDescriptor(ctor, values);
System\Data\Common\DataTableMapping.cs (1)
198return new InstanceDescriptor(ctor, values);
System\Data\ConstraintConverter.cs (2)
43return new InstanceDescriptor(ctor, new object[] { constr.ConstraintName, constr.ColumnNames, constr.IsPrimaryKey }); 54return new InstanceDescriptor(ctor, new object[] { constr.ConstraintName, constr.ParentKey.Table.TableName, constr.ParentColumnNames,
System\Data\RelationshipConverter.cs (1)
68return new InstanceDescriptor(ctor, values);
System.Windows.Controls.Ribbon (1)
Microsoft\Windows\Controls\Ribbon\RibbonControlLengthConverter.cs (1)
132return new InstanceDescriptor(ci, new object[] { length.Value, length.RibbonControlLengthUnitType });
System.Windows.Forms (16)
System\Windows\Forms\Controls\DataGridView\DataGridViewCellConverter.cs (1)
33return new InstanceDescriptor(ctor, Array.Empty<object>(), false);
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyleConverter.cs (1)
41return new InstanceDescriptor(ctor, Array.Empty<object>(), false);
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnConverter.cs (2)
45return new InstanceDescriptor(ctor, new object[] { dataGridViewColumn.CellType }, false); 54return new InstanceDescriptor(ctor, Array.Empty<object>(), false);
System\Windows\Forms\Controls\DataGridView\DataGridViewRowConverter.cs (1)
32return new InstanceDescriptor(ctor, Array.Empty<object>(), isComplete: false);
System\Windows\Forms\Controls\ListView\ColumnHeaderConverter.cs (3)
50id = new InstanceDescriptor(ctor, new object[] { col.ImageIndex }, false); 59id = new InstanceDescriptor(ctor, new object[] { col.ImageKey }, false); 68return new InstanceDescriptor(ctor, Array.Empty<object>(), false);
System\Windows\Forms\Controls\ListView\ListViewGroupConverter.cs (1)
97return new InstanceDescriptor(ctor, new object[] { group.Header, group.HeaderAlignment }, false);
System\Windows\Forms\Controls\ListView\ListViewItemConverter.cs (1)
59return new InstanceDescriptor(ctor, new object[] { subItemArray, item.ImageKey }, false);
System\Windows\Forms\Controls\ListView\ListViewSubItemConverter.cs (2)
44return new InstanceDescriptor(ctor, new object?[] 57return new InstanceDescriptor(ctor, new object?[] { null, item.Text }, true);
System\Windows\Forms\Controls\MonthCalendar\SelectionRangeConverter.cs (1)
128return new InstanceDescriptor(ctor, new object[] { range.Start, range.End });
System\Windows\Forms\Controls\TreeView\TreeNodeConverter.cs (1)
107return new InstanceDescriptor(info, args, false);
System\Windows\Forms\DataBinding\ListBindingConverter.cs (1)
196return new InstanceDescriptor(ctor, values, isComplete);
System\Windows\Forms\Input\CursorConverter.cs (1)
127return new InstanceDescriptor(prop, null);
System.Xaml (4)
src\Microsoft.DotNet.Wpf\src\Shared\System\Windows\Markup\Replacements\TypeUriConverter.cs (1)
47return new InstanceDescriptor(constructor, new object[] { uri.OriginalString, uriKind });
System\Windows\Markup\StaticExtensionsToInstanceDescriptorsConverter.cs (1)
36return new InstanceDescriptor(
System\Windows\Markup\TypeExtensionConverter.cs (1)
36return new InstanceDescriptor(
System\Xaml\Replacements\DateTimeOffsetConverter2.cs (1)
58return new InstanceDescriptor(
WindowsBase.Tests (2)
System\Windows\Markup\Primitives\MarkupObjectTests.cs (1)
478return new InstanceDescriptor(ctor, new object[] { 1, 2 });
System\Windows\Markup\Primitives\MarkupPropertyTests.cs (1)
566return new InstanceDescriptor(ctor, new object[] { 1, 2 });
363 references to InstanceDescriptor
netstandard (1)
netstandard.cs (1)
288[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.ComponentModel.Design.Serialization.InstanceDescriptor))]
PresentationBuildTasks (4)
MS\Internal\MarkupCompiler\MarkupCompiler.cs (4)
1787InstanceDescriptor desc = null; 1827if (converter.CanConvertTo(ctx, typeof(InstanceDescriptor))) 1829desc = (InstanceDescriptor)converter.ConvertTo(ctx, TypeConverterHelper.InvariantEnglishUS, value, typeof(InstanceDescriptor));
PresentationCore (29)
System\Windows\CultureInfoConverter.cs (2)
65return destinationType == typeof(InstanceDescriptor) || 129else if (destinationType == typeof(InstanceDescriptor))
System\Windows\DurationConverter.cs (2)
35return destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string); 97if (value is not Duration duration || (destinationType != typeof(InstanceDescriptor) && destinationType != typeof(string)))
System\Windows\FontStretchConverter.cs (2)
40if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string)) 92if (destinationType == typeof(InstanceDescriptor))
System\Windows\FontStyleConverter.cs (2)
40if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string)) 92if (destinationType == typeof(InstanceDescriptor))
System\Windows\FontWeightConverter.cs (2)
40if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string)) 92if (destinationType == typeof(InstanceDescriptor))
System\Windows\Ink\StrokeCollectionConverter.cs (2)
55if (destinationType == typeof(InstanceDescriptor)) 127else if (destinationType == typeof(InstanceDescriptor))
System\Windows\Markup\XmlLanguageConverter.cs (2)
58return destinationType == typeof(InstanceDescriptor) || 122else if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\Animation\KeySplineConverter.cs (2)
45if ( destinationType == typeof(InstanceDescriptor) 99if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\Animation\KeyTimeConverter.cs (2)
48if ( type == typeof(InstanceDescriptor) 138if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\Animation\RepeatBehaviorConverter.cs (2)
50if ( destinationType == typeof(InstanceDescriptor) 119if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\ColorConverter.cs (2)
41if (destinationType == typeof(InstanceDescriptor)) 102if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\PixelFormatConverter.cs (2)
44if (destinationType == typeof(InstanceDescriptor) || 98if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\RequestCachePolicyConverter.cs (3)
44if (destinationType == typeof(InstanceDescriptor) || 113else if (destinationType == typeof(InstanceDescriptor)) 128else if (destinationType == typeof(InstanceDescriptor))
System\Windows\TextDecorationCollectionConverter.cs (2)
25if (destinationType == typeof(InstanceDescriptor)) 169if (destinationType == typeof(InstanceDescriptor) && value is IEnumerable<TextDecoration>)
PresentationCore.Tests (13)
System\Windows\DurationConverter.Tests.cs (2)
17[InlineData(false, typeof(InstanceDescriptor))] 28[InlineData(true, typeof(InstanceDescriptor))]
System\Windows\Input\Command\KeyGestureConverter.Tests.cs (1)
20[InlineData(false, typeof(InstanceDescriptor))]
System\Windows\Input\Command\MouseGestureConverter.Tests.cs (1)
20[InlineData(false, typeof(InstanceDescriptor))]
System\Windows\Input\MouseActionConverter.Tests.cs (1)
16[InlineData(false, typeof(InstanceDescriptor))]
System\Windows\TextDecorationCollectionConverter.Tests.cs (8)
17[InlineData(false, typeof(InstanceDescriptor))] 27[InlineData(true, typeof(InstanceDescriptor))] 193InstanceDescriptor? result = (InstanceDescriptor?)converter.ConvertTo(null, null, value, destinationType); 218typeof(InstanceDescriptor) }; 223typeof(InstanceDescriptor) }; 229new TextDecoration[3] { TextDecorations.Underline[0], TextDecorations.OverLine[0], TextDecorations.Baseline[0] }, typeof(InstanceDescriptor) }; 233new List<TextDecoration> { TextDecorations.Underline[0], TextDecorations.OverLine[0], TextDecorations.Baseline[0] }, typeof(InstanceDescriptor) };
PresentationFramework (25)
System\Windows\Controls\DataGridLengthConverter.cs (2)
51return (destinationType == typeof(string)) || (destinationType == typeof(InstanceDescriptor)); 140if (destinationType == typeof(InstanceDescriptor))
System\Windows\Controls\VirtualizationCacheLengthConverter.cs (2)
67if ( destinationType == typeof(InstanceDescriptor) 143if (destinationType == typeof(InstanceDescriptor))
System\Windows\CornerRadiusConverter.cs (2)
62if ( destinationType == typeof(InstanceDescriptor) 129if (destinationType == typeof(InstanceDescriptor))
System\Windows\DynamicResourceExtensionConverter.cs (2)
29if (destinationType == typeof(InstanceDescriptor)) 41if (destinationType == typeof(InstanceDescriptor))
System\Windows\FigureLengthConverter.cs (2)
82return ( destinationType == typeof(InstanceDescriptor) 156if (destinationType == typeof(InstanceDescriptor))
System\Windows\FontSizeConverter.cs (1)
46if (destinationType == typeof(InstanceDescriptor))
System\Windows\GridLengthConverter.cs (2)
85return ( destinationType == typeof(InstanceDescriptor) 176if (destinationType == typeof(InstanceDescriptor))
System\Windows\LengthConverter.cs (2)
76if (destinationType == typeof(InstanceDescriptor) || 151else if (destinationType == typeof(InstanceDescriptor))
System\Windows\Markup\Primitives\ElementMarkupObject.cs (4)
357if (converter != null && converter.CanConvertTo(Context, typeof(InstanceDescriptor))) 359InstanceDescriptor instanceDescriptor; 363instance, typeof(InstanceDescriptor)) as InstanceDescriptor;
System\Windows\TemplateBindingExtensionConverter.cs (2)
33if (destinationType == typeof(InstanceDescriptor)) 45if (destinationType == typeof(InstanceDescriptor))
System\Windows\ThemeModeConverter.cs (2)
48return destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string); 104else if (destinationType == typeof(InstanceDescriptor))
System\Windows\ThicknessConverter.cs (2)
70return destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string); 129else if (destinationType == typeof(InstanceDescriptor))
System (1)
src\libraries\shims\System\ref\System.cs (1)
274[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.ComponentModel.Design.Serialization.InstanceDescriptor))]
System.ComponentModel.TypeConverter (40)
System\ComponentModel\CultureInfoConverter.cs (2)
54return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 158if (destinationType == typeof(InstanceDescriptor) && value is CultureInfo cultureValue)
System\ComponentModel\DateOnlyConverter.cs (2)
28return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 96if (destinationType == typeof(InstanceDescriptor) && value is DateOnly date)
System\ComponentModel\DateTimeConverter.cs (2)
33return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 120if (destinationType == typeof(InstanceDescriptor) && value is DateTime)
System\ComponentModel\DateTimeOffsetConverter.cs (2)
32return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 131if (destinationType == typeof(InstanceDescriptor) && value is DateTimeOffset)
System\ComponentModel\DecimalConverter.cs (2)
34return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 46if (destinationType == typeof(InstanceDescriptor) && value is decimal decimalValue)
System\ComponentModel\Design\Serialization\InstanceDescriptor.cs (1)
122if (translatedArguments[i] is InstanceDescriptor instanceDescriptor)
System\ComponentModel\EnumConverter.cs (2)
57if (destinationType == typeof(Enum[]) || destinationType == typeof(InstanceDescriptor)) 139if (destinationType == typeof(InstanceDescriptor) && value != null)
System\ComponentModel\GuidConverter.cs (2)
33return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 58if (destinationType == typeof(InstanceDescriptor) && value is Guid)
System\ComponentModel\NullableConverter.cs (2)
85else if (destinationType == typeof(InstanceDescriptor)) 108else if (destinationType == typeof(InstanceDescriptor))
System\ComponentModel\TimeOnlyConverter.cs (2)
28return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 91if (destinationType == typeof(InstanceDescriptor) && value is TimeOnly time)
System\ComponentModel\TimeSpanConverter.cs (2)
33return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 67if (destinationType == typeof(InstanceDescriptor) && value is TimeSpan)
System\ComponentModel\TypeConverter.cs (2)
29=> sourceType == typeof(InstanceDescriptor); 56if (value is InstanceDescriptor instanceDescriptor)
System\ComponentModel\TypeListConverter.cs (1)
43return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType);
System\ComponentModel\UriTypeConverter.cs (2)
34return destinationType == typeof(Uri) || destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 71if (destinationType == typeof(InstanceDescriptor))
System\ComponentModel\VersionConverter.cs (2)
33return destinationType == typeof(Version) || destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 72if (destinationType == typeof(InstanceDescriptor))
System\Drawing\ColorConverter.cs (2)
35return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 96else if (destinationType == typeof(InstanceDescriptor))
System\Drawing\PointConverter.cs (2)
22return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 82else if (destinationType == typeof(InstanceDescriptor))
System\Drawing\RectangleConverter.cs (2)
22return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 82else if (destinationType == typeof(InstanceDescriptor))
System\Drawing\SizeConverter.cs (2)
22return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 80else if (destinationType == typeof(InstanceDescriptor))
System\Drawing\SizeFConverter.cs (2)
22return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 77else if (destinationType == typeof(InstanceDescriptor))
System\Security\Authentication\ExtendedProtection\ExtendedProtectionPolicyTypeConverter.cs (2)
18return destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 26if (destinationType == typeof(InstanceDescriptor))
System.Data.Common (10)
System\Data\ColumnTypeConverter.cs (2)
63destinationType == typeof(InstanceDescriptor) || 80if (value != null && destinationType == typeof(InstanceDescriptor))
System\Data\Common\DataColumnMapping.cs (2)
152if (typeof(InstanceDescriptor) == destinationType) 166if ((typeof(InstanceDescriptor) == destinationType) && (value is DataColumnMapping))
System\Data\Common\DataTableMapping.cs (2)
174if (typeof(InstanceDescriptor) == destinationType) 188if ((typeof(InstanceDescriptor) == destinationType) && (value is DataTableMapping))
System\Data\ConstraintConverter.cs (2)
21destinationType == typeof(InstanceDescriptor) || 35if (destinationType == typeof(InstanceDescriptor) && value is Constraint)
System\Data\RelationshipConverter.cs (2)
24if (destinationType == typeof(InstanceDescriptor)) 45if (destinationType == typeof(InstanceDescriptor) && value is DataRelation)
System.Drawing.Common.Tests (6)
System\Drawing\FontConverterTests.cs (3)
121InstanceDescriptor descriptor = (InstanceDescriptor)converter.ConvertTo(font, typeof(InstanceDescriptor));
System\Drawing\Printing\MarginsConverterTests.cs (3)
135converted = mc.ConvertTo(context, culture, margins, typeof(InstanceDescriptor)); 136Assert.IsType<InstanceDescriptor>(converted); 137Assert.Equal(new object[] { 1, 2, 3, 4 }, ((InstanceDescriptor)converted).Arguments);
System.Private.Windows.Core.TestUtilities (1)
CommonTestHelper.cs (1)
120{ typeof(InstanceDescriptor), true },
System.Windows.Controls.Ribbon (2)
Microsoft\Windows\Controls\Ribbon\RibbonControlLengthConverter.cs (2)
72return (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string)); 129if (destinationType == typeof(InstanceDescriptor))
System.Windows.Forms (39)
System\Windows\Forms\Controls\DataGridView\DataGridViewCellConverter.cs (2)
16if (destinationType == typeof(InstanceDescriptor)) 28if (destinationType == typeof(InstanceDescriptor) && value is DataGridViewCell cell)
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyleConverter.cs (2)
19if (destinationType == typeof(InstanceDescriptor)) 38if (destinationType == typeof(InstanceDescriptor) && value is DataGridViewCellStyle)
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnConverter.cs (2)
15if (destinationType == typeof(InstanceDescriptor)) 34if (destinationType == typeof(InstanceDescriptor) && value is DataGridViewColumn dataGridViewColumn)
System\Windows\Forms\Controls\DataGridView\DataGridViewRowConverter.cs (2)
15if (destinationType == typeof(InstanceDescriptor)) 27if (value is DataGridViewRow row && destinationType == typeof(InstanceDescriptor))
System\Windows\Forms\Controls\Labels\LinkArea.LinkAreaConverter.cs (2)
39if (destinationType == typeof(InstanceDescriptor)) 103else if (destinationType == typeof(InstanceDescriptor))
System\Windows\Forms\Controls\Labels\LinkConverter.cs (2)
35if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string)) 100if (destinationType == typeof(InstanceDescriptor))
System\Windows\Forms\Controls\ListView\ColumnHeaderConverter.cs (3)
19if (destinationType == typeof(InstanceDescriptor)) 38if (destinationType == typeof(InstanceDescriptor) && value is ColumnHeader col) 43InstanceDescriptor? id = null;
System\Windows\Forms\Controls\ListView\ListViewGroupConverter.cs (2)
37if (destinationType == typeof(InstanceDescriptor)) 92if (destinationType == typeof(InstanceDescriptor) && value is ListViewGroup group)
System\Windows\Forms\Controls\ListView\ListViewItemConverter.cs (2)
26if (destinationType == typeof(InstanceDescriptor)) 45if (destinationType == typeof(InstanceDescriptor) && value is ListViewItem item)
System\Windows\Forms\Controls\ListView\ListViewSubItemConverter.cs (2)
16if (destinationType == typeof(InstanceDescriptor)) 28if (destinationType == typeof(InstanceDescriptor) && value is ListViewItem.ListViewSubItem item)
System\Windows\Forms\Controls\MonthCalendar\SelectionRangeConverter.cs (2)
39if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(DateTime)) 120if (destinationType == typeof(InstanceDescriptor))
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\MergePropertyDescriptor.cs (4)
139if (converter.CanConvertTo(typeof(InstanceDescriptor))) 142var instanceDescriptor = (InstanceDescriptor?)converter.ConvertTo( 146typeof(InstanceDescriptor));
System\Windows\Forms\Controls\TreeView\TreeNodeConverter.cs (2)
24if (destinationType == typeof(InstanceDescriptor)) 43if (destinationType == typeof(InstanceDescriptor) && value is TreeNode node)
System\Windows\Forms\DataBinding\ListBindingConverter.cs (3)
49if (destinationType == typeof(InstanceDescriptor)) 68if (destinationType == typeof(InstanceDescriptor) && value is Binding) 114private static InstanceDescriptor GetInstanceDescriptorFromValues(Binding b)
System\Windows\Forms\Input\CursorConverter.cs (2)
40if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(byte[])) 120else if (destinationType == typeof(InstanceDescriptor))
System\Windows\Forms\Panels\TableLayoutPanel\TableLayoutPanelCellPositionTypeConverter.cs (2)
15if (destinationType == typeof(InstanceDescriptor)) 66if (destinationType == typeof(InstanceDescriptor) && value is TableLayoutPanelCellPosition cellPosition)
System\Windows\Forms\Panels\TableLayoutPanel\TableLayoutSettings.StyleConverter.cs (2)
16if (destinationType == typeof(InstanceDescriptor)) 26if (destinationType == typeof(InstanceDescriptor) && value is TableLayoutStyle style)
System\Windows\Forms\Panels\TableLayoutPanel\TableLayoutSettingsTypeConverter.cs (1)
34if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(string))
System.Windows.Forms.Design (7)
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (7)
1889if (converter.CanConvertTo(typeof(InstanceDescriptor))) 1891if (converter.ConvertTo(value, typeof(InstanceDescriptor)) is InstanceDescriptor descriptor && descriptor.MemberInfo is not null) 1901if (converter.CanConvertTo(typeof(InstanceDescriptor))) 1903if (converter.ConvertTo(value, typeof(InstanceDescriptor)) is InstanceDescriptor descriptor && descriptor.MemberInfo is not null) 1935private CodeExpression? SerializeInstanceDescriptor(IDesignerSerializationManager manager, object value, InstanceDescriptor descriptor)
System.Windows.Forms.Design.Tests (1)
System\Windows\Forms\Design\DataMemberFieldConverterTests.cs (1)
19Assert.True(s_converter.CanConvertFrom(s_context, typeof(InstanceDescriptor)));
System.Windows.Forms.Primitives (2)
System\Windows\Forms\PaddingConverter.cs (2)
18destinationType == typeof(InstanceDescriptor) || base.CanConvertTo(context, destinationType); 54else if (destinationType == typeof(InstanceDescriptor))
System.Windows.Forms.Tests (93)
System\Windows\Forms\ColumnHeaderConverterTests.cs (6)
36[InlineData(typeof(InstanceDescriptor), true)] 97InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 107Assert.Throws<ArgumentException>(() => converter.ConvertTo(value, typeof(InstanceDescriptor))); 130Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\CursorConverterTests.cs (8)
65[InlineData(typeof(InstanceDescriptor), true)] 101InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(Cursors.AppStarting, typeof(InstanceDescriptor))); 106Assert.Throws<NotSupportedException>(() => converter.ConvertTo(new Cursor(Cursors.AppStarting.Handle), typeof(InstanceDescriptor))); 113Assert.Throws<NotSupportedException>(() => converter.ConvertTo(new Cursor(2), typeof(InstanceDescriptor))); 120Assert.Throws<NotSupportedException>(() => converter.ConvertTo(null, typeof(InstanceDescriptor))); 173[InlineData(typeof(InstanceDescriptor))]
System\Windows\Forms\DataGridViewCellConverterTests.cs (4)
16[InlineData(typeof(InstanceDescriptor), true)] 25Type destinationType = typeof(InstanceDescriptor); 28_converter.ConvertTo(context: null, CultureInfo.InvariantCulture, cell, destinationType).Should().BeOfType<InstanceDescriptor>(); 35Type destinationType = typeof(InstanceDescriptor);
System\Windows\Forms\DataGridViewCellStyleConverterTests.cs (3)
25_converter.CanConvertTo(null, typeof(InstanceDescriptor)).Should().BeTrue(); 37object? convertTo = _converter.ConvertTo(null, CultureInfo.InvariantCulture, _style, typeof(InstanceDescriptor)); 39convertTo.Should().BeOfType<InstanceDescriptor>();
System\Windows\Forms\DataGridViewColumnConverterTests.cs (7)
19[InlineData(typeof(InstanceDescriptor))] 73var descriptor = _converter.ConvertTo(context: null, culture: CultureInfo.InvariantCulture, value: column, destinationType: typeof(InstanceDescriptor)) as InstanceDescriptor; 80var descriptor = _converter.ConvertTo(context: null, culture: CultureInfo.InvariantCulture, value: column, destinationType: typeof(InstanceDescriptor)) as InstanceDescriptor;
System\Windows\Forms\DataGridViewRowConverterTests.cs (3)
18Assert.True(converter.CanConvertTo(typeof(InstanceDescriptor))); 27object descriptor = converter.ConvertTo(row, typeof(InstanceDescriptor)); 30Assert.IsType<InstanceDescriptor>(descriptor);
System\Windows\Forms\Layout\TableLayoutSettingsTypeConverterTests.cs (2)
149[InlineData(typeof(InstanceDescriptor), true)] 292[InlineData(typeof(InstanceDescriptor))]
System\Windows\Forms\LinkAreaConverterTests.cs (5)
62[InlineData(typeof(InstanceDescriptor), true)] 85InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new LinkArea(1, 2), typeof(InstanceDescriptor))); 101Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\LinkConverterTests.cs (8)
60[InlineData(typeof(InstanceDescriptor), true)] 83InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new LinkLabel.Link(1, 2), typeof(InstanceDescriptor))); 93InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new LinkLabel.Link(1, 2, "linkData"), typeof(InstanceDescriptor))); 110Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\ListViewGroupConverterTests.cs (5)
129[InlineData(typeof(InstanceDescriptor), true)] 203InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 228Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\ListViewItemConverterTests.cs (5)
38[InlineData(typeof(InstanceDescriptor), true)] 258InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 283Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\ListViewSubItemConverterTests.cs (5)
38[InlineData(typeof(InstanceDescriptor), true)] 71InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 96Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\MonthCalendar.SelectionRangeConverterTests.cs (4)
38[InlineData(typeof(InstanceDescriptor), true)] 105InstanceDescriptor descriptor = (InstanceDescriptor)_converter.ConvertTo(null, CultureInfo.InvariantCulture, _range, typeof(InstanceDescriptor));
System\Windows\Forms\OpacityConverterTests.cs (3)
72[InlineData(typeof(InstanceDescriptor), false)] 103Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor))); 108[InlineData(typeof(InstanceDescriptor))]
System\Windows\Forms\PaddingConverterTests.cs (8)
64[InlineData(typeof(InstanceDescriptor), true)] 88InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new Padding(1, 2, 3, 4), typeof(InstanceDescriptor))); 97InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new Padding(1, 1, 1, 1), typeof(InstanceDescriptor))); 113Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\TableLayoutPanelCellPositionTests.cs (5)
161[InlineData(typeof(InstanceDescriptor), true)] 175InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(new TableLayoutPanelCellPosition(1, 2), typeof(InstanceDescriptor))); 192Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\TableLayoutStyleTests.cs (6)
114[InlineData(typeof(InstanceDescriptor), true)] 139InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 149Assert.Throws<NotSupportedException>(() => converter.ConvertTo(new SubTableLayoutStyle { SizeType = sizeType }, typeof(InstanceDescriptor))); 163Assert.Throws<NotSupportedException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Forms\TreeNodeConverterTests.cs (6)
12[InlineData(typeof(InstanceDescriptor), true)] 22[InlineData(typeof(InstanceDescriptor), true)] 33if (destinationType == typeof(InstanceDescriptor)) 35result.Should().BeOfType<InstanceDescriptor>(); 36var descriptor = (InstanceDescriptor)result;
System.Xaml (13)
src\Microsoft.DotNet.Wpf\src\Shared\System\Windows\Markup\Replacements\TypeUriConverter.cs (2)
29destinationType == typeof(InstanceDescriptor) || 44if (destinationType == typeof(InstanceDescriptor))
System\Windows\Markup\StaticExtensionsToInstanceDescriptorsConverter.cs (2)
19if (destinationType == typeof(InstanceDescriptor)) 29if (destinationType == typeof(InstanceDescriptor))
System\Windows\Markup\TypeExtensionConverter.cs (2)
19if (destinationType == typeof(InstanceDescriptor)) 29if (destinationType == typeof(InstanceDescriptor))
System\Xaml\Replacements\DateTimeOffsetConverter2.cs (2)
18if (destinationType == typeof(string) || destinationType == typeof(InstanceDescriptor)) 44else if (destinationType == typeof(InstanceDescriptor))
System\Xaml\Schema\BuiltInValueConverter.cs (1)
200!stdConverter.CanConvertTo(typeof(string)) || !stdConverter.CanConvertTo(typeof(Uri)) || !stdConverter.CanConvertTo(typeof(InstanceDescriptor)))
System\Xaml\XamlObjectReader.cs (4)
1403if (converter is not null && context.CanConvertTo(converter, typeof(InstanceDescriptor))) 1415var descriptor = context.ConvertTo<InstanceDescriptor>(converter, instance); 1437if (converter is null || !context.CanConvertTo(converter, typeof(InstanceDescriptor)))
System.Xaml.Tests (38)
System\Windows\Markup\NameReferenceConverterTests.cs (1)
19[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\Markup\StaticExtensionTests.cs (7)
200[InlineData(typeof(InstanceDescriptor), true)] 216InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(extension, typeof(InstanceDescriptor))); 226Assert.IsType<InstanceDescriptor>(converter.ConvertTo(extension, typeof(InstanceDescriptor))); 235Assert.Throws<ArgumentException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Windows\Markup\TypeExtensionTests.cs (7)
161[InlineData(typeof(InstanceDescriptor), true)] 177InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(extension, typeof(InstanceDescriptor))); 187Assert.IsType<InstanceDescriptor>(converter.ConvertTo(extension, typeof(InstanceDescriptor))); 196Assert.Throws<ArgumentException>(() => converter.ConvertTo(1, typeof(InstanceDescriptor)));
System\Xaml\Replacements\DateTimeConverter2Tests.cs (3)
19[InlineData(typeof(InstanceDescriptor), true)] 60[InlineData(typeof(InstanceDescriptor), false)] 99[InlineData(typeof(InstanceDescriptor))]
System\Xaml\Replacements\DateTimeOffsetConverter2Tests.cs (5)
21[InlineData(typeof(InstanceDescriptor), true)] 60[InlineData(typeof(InstanceDescriptor), true)] 89InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(dateTimeOffset, typeof(InstanceDescriptor)));
System\Xaml\Replacements\EventConverterTests.cs (2)
18[InlineData(typeof(InstanceDescriptor), true)] 150[InlineData(typeof(InstanceDescriptor), false)]
System\Xaml\Replacements\TypeListConverterTests.cs (2)
17[InlineData(typeof(InstanceDescriptor), false)] 49[InlineData(typeof(InstanceDescriptor), false)]
System\Xaml\Replacements\TypeTypeConverterTests.cs (2)
19[InlineData(typeof(InstanceDescriptor), false)] 91[InlineData(typeof(InstanceDescriptor), false)]
System\Xaml\Replacements\TypeUriConverterTests.cs (7)
49[InlineData(typeof(InstanceDescriptor), false)] 102[InlineData(typeof(InstanceDescriptor), true)] 150InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.ConvertTo(value, typeof(InstanceDescriptor))); 214return destinationType == typeof(Uri) || destinationType == typeof(InstanceDescriptor); 227return destinationType == typeof(string) || destinationType == typeof(InstanceDescriptor);
System\Xaml\Schema\XamlTypeTypeConverterTests.cs (2)
18[InlineData(typeof(InstanceDescriptor), false)] 194[InlineData(typeof(InstanceDescriptor), false)]
WindowsBase.Tests (38)
System\Windows\ExpressionConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor))] 82[InlineData(typeof(InstanceDescriptor))]
System\Windows\Input\KeyConverterTests.cs (11)
17yield return new object?[] { null, typeof(InstanceDescriptor), false }; 22yield return new object?[] { new CustomTypeDescriptorContext(), typeof(InstanceDescriptor), false }; 28yield return new object?[] { new CustomTypeDescriptorContext { Instance = new object() }, typeof(InstanceDescriptor), false }; 33yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.None }, typeof(InstanceDescriptor), false }; 38yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.Cancel }, typeof(InstanceDescriptor), false }; 43yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.A }, typeof(InstanceDescriptor), false }; 48yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.OemClear }, typeof(InstanceDescriptor), false }; 53yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.DeadCharProcessed }, typeof(InstanceDescriptor), false }; 58yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.None - 1 }, typeof(InstanceDescriptor), false }; 63yield return new object?[] { new CustomTypeDescriptorContext { Instance = Key.DeadCharProcessed + 1 }, typeof(InstanceDescriptor), false }; 232[InlineData(typeof(InstanceDescriptor), false)]
System\Windows\Input\ModifierKeysConverterTests.cs (9)
17yield return new object?[] { null, typeof(InstanceDescriptor), false }; 23yield return new object?[] { new CustomTypeDescriptorContext(), typeof(InstanceDescriptor), false }; 29yield return new object?[] { new CustomTypeDescriptorContext { Instance = new object() }, typeof(InstanceDescriptor), false }; 35yield return new object?[] { new CustomTypeDescriptorContext { Instance = ModifierKeys.None }, typeof(InstanceDescriptor), false }; 41yield return new object?[] { new CustomTypeDescriptorContext { Instance = ModifierKeys.Control }, typeof(InstanceDescriptor), false }; 47yield return new object?[] { new CustomTypeDescriptorContext { Instance = ModifierKeys.Control | ModifierKeys.Alt | ModifierKeys.Windows | ModifierKeys.Shift }, typeof(InstanceDescriptor), false }; 53yield return new object?[] { new CustomTypeDescriptorContext { Instance = (ModifierKeys)(-1) }, typeof(InstanceDescriptor), false }; 59yield return new object?[] { new CustomTypeDescriptorContext { Instance = (ModifierKeys)0x10 }, typeof(InstanceDescriptor), false }; 198[InlineData(typeof(InstanceDescriptor), false)]
System\Windows\Int32RectConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\Markup\Primitives\MarkupObjectTests.cs (2)
464if (destinationType == typeof(InstanceDescriptor)) 474if (destinationType == typeof(InstanceDescriptor))
System\Windows\Markup\Primitives\MarkupPropertyTests.cs (2)
552if (destinationType == typeof(InstanceDescriptor)) 562if (destinationType == typeof(InstanceDescriptor))
System\Windows\Media\MatrixConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\PointConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\RectConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\SizeConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]
System\Windows\VectorConverterTests.cs (2)
16[InlineData(typeof(InstanceDescriptor), false)] 108[InlineData(typeof(InstanceDescriptor), true)]