GridUnitTypeAttribute Class

 

This class associates a GridUnitType value with a MEF export.

Namespace:   Microsoft.VisualStudio.Text.Editor
Assembly:  Microsoft.VisualStudio.Text.UI.Wpf (in Microsoft.VisualStudio.Text.UI.Wpf.dll)

System.Object
  System.Attribute
    Microsoft.VisualStudio.Utilities.SingletonBaseMetadataAttribute
      Microsoft.VisualStudio.Text.Editor.GridUnitTypeAttribute

[MetadataAttributeAttribute]
[AttributeUsageAttribute(AttributeTargets.Class | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field, 
	AllowMultiple = false)]
public sealed class GridUnitTypeAttribute : SingletonBaseMetadataAttribute

NameDescription
System_CAPS_pubmethodGridUnitTypeAttribute(GridUnitType)

Initializes a new instance of GridUnitTypeAttribute.

NameDescription
System_CAPS_pubpropertyGridUnitType

Gets the grid unit type.

System_CAPS_pubpropertyTypeId

(Inherited from Attribute.)

NameDescription
System_CAPS_pubmethodEquals(Object)

(Inherited from Attribute.)

System_CAPS_pubmethodGetHashCode()

(Inherited from Attribute.)

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_pubmethodIsDefaultAttribute()

(Inherited from Attribute.)

System_CAPS_pubmethodMatch(Object)

(Inherited from Attribute.)

System_CAPS_pubmethodToString()

(Inherited from Object.)

The value of this attribute is used by the consumers to decide rendering behavior for the exported object. The rendering behavior matches the behavior defined in WPF classes (e.g. Grid) that interact with GridUnitType.

[Export(typeof(IWpfTextViewMarginProvider))]
[Name(PredefinedMarginNames.VerticalScrollBar)]
[MarginContainer(PredefinedMarginNames.VerticalScrollBarContainerMargin)]
[ContentType("text")]
[TextViewRole(PredefinedTextViewRoles.Interactive)]
[GridUnitType(GridUnitType.Star)] //this size is determined as a weighted proportion of available space
internal sealed class VerticalScrollBarMarginProvider : IWpfTextViewMarginProvider 
{ */ implementation /* }

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: