Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

ColorableItems Interface

Represents the portions of an item that can be colored, such as the foreground and background.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)
type ColorableItems =  interface end

The ColorableItems type exposes the following members.

Public propertyBackgroundSets or gets the background color of the item.
Public propertyBoldSets or gets whether or not the item should appear in bold.
Public propertyForegroundSets or gets the foreground color of the item.
Public propertyNameSets or gets the name of the ColorableItems object.

ColorableItems objects are contained in the FontsAndColorsItems collection.

Sub ColorableItemsExample()
   Dim props As EnvDTE.Properties
   props = DTE.Properties("FontsAndColors", "TextEditor")
   Dim prop As EnvDTE.Property = props.Item("FontsAndColorsItems")
   Dim clritems As EnvDTE.FontsAndColorsItems = prop.Object
   Dim clritem As EnvDTE.ColorableItems
   Dim ClrList As String
   For Each clritem In clritems
      ClrList += clritem.Name + " (" + clritem.Foreground.ToString() + ")"
      ClrList += Chr(13) & Chr(10)
End Sub
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
© 2014 Microsoft. All rights reserved.