6 instantiations of ImageElement
Microsoft.CodeAnalysis.LanguageServer.Protocol (6)
Extensions\Extensions.cs (1)
300=> new(element.Glyph.ToLSPImageId());
Handler\Completion\CompletionResultFactory.cs (1)
372Icon = new ImageElement(item.Tags.GetFirstGlyph().ToLSPImageId()),
Handler\References\FindUsagesLSPContext.cs (1)
218DefinitionIcon = new ImageElement(definitionGlyph.ToLSPImageId()),
Protocol\Internal\Converters\ImageElementConverter.cs (2)
28return automationName is null ? new ImageElement(imageId.Value) : new ImageElement(imageId.Value, automationName);
Protocol\Internal\Text\ImageElement.cs (1)
14public static readonly ImageElement Empty = new(default, string.Empty);
25 references to ImageElement
Microsoft.CodeAnalysis.LanguageServer.Protocol (25)
Extensions\Extensions.cs (1)
299public static ImageElement ToLSPElement(this QuickInfoGlyphElement element)
Protocol\Internal\Converters\ImageElementConverter.cs (10)
12internal class ImageElementConverter : JsonConverter<ImageElement> 16public override ImageElement Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) 37case nameof(ImageElement.ImageId): 40case nameof(ImageElement.AutomationName): 44if (reader.GetString() != nameof(ImageElement)) 45throw new JsonException($"Expected {ObjectContentConverter.TypeProperty} property value {nameof(ImageElement)}"); 58public override void Write(Utf8JsonWriter writer, ImageElement value, JsonSerializerOptions options) 61writer.WritePropertyName(nameof(ImageElement.ImageId)); 63writer.WriteString(nameof(ImageElement.AutomationName), value.AutomationName); 64writer.WriteString(ObjectContentConverter.TypeProperty, nameof(ImageElement));
Protocol\Internal\Converters\ObjectContentConverter.cs (5)
19/// <item><description><see cref="ImageElement"/></description></item>, 56case nameof(ImageElement): 57return ImageElementConverter.Instance.Read(ref clonedReader, typeof(ImageElement), options); 96case ImageElement: 97ImageElementConverter.Instance.Write(writer, (ImageElement)value, options);
Protocol\Internal\Text\ImageElement.cs (1)
14public static readonly ImageElement Empty = new(default, string.Empty);
Protocol\Internal\VSInternalCompletionItem.cs (1)
26public ImageElement? Icon { get; set; }
Protocol\Internal\VSInternalLocation.cs (2)
19/// Gets or sets the text value for a location reference. Must be of type <see cref="ImageElement"/> or <see cref="ContainerElement"/> or <see cref="ClassifiedTextElement"/> or <see cref="string"/>. 33if (value is ImageElement || value is ContainerElement || value is ClassifiedTextElement || value is string)
Protocol\Internal\VSInternalReferenceItem.cs (5)
53/// Must be of type <see cref="string"/>, <see cref="ClassifiedTextElement"/>, <see cref="ContainerElement"/> and <see cref="ImageElement"/>. 72(value is ImageElement || value is ContainerElement || value is ClassifiedTextElement || value is string)) 133/// Must be of type <see cref="ImageElement"/> or <see cref="ContainerElement"/> or <see cref="ClassifiedTextElement"/> or <see cref="string"/>. 160if (value is ImageElement || value is ContainerElement || value is ClassifiedTextElement || value is string) 192public ImageElement? DefinitionIcon { get; set; }