Udostępnij za pośrednictwem


ColorableItem Constructor

Definition

Initializes the ColorableItem class and accepts all the information needed to describe a colorable item.

public:
 ColorableItem(System::String ^ name, System::String ^ displayName, Microsoft::VisualStudio::TextManager::Interop::COLORINDEX foreColor, Microsoft::VisualStudio::TextManager::Interop::COLORINDEX backColor, System::Drawing::Color hiForeColor, System::Drawing::Color hiBackColor, Microsoft::VisualStudio::TextManager::Interop::FONTFLAGS fontFlags);
public ColorableItem (string name, string displayName, Microsoft.VisualStudio.TextManager.Interop.COLORINDEX foreColor, Microsoft.VisualStudio.TextManager.Interop.COLORINDEX backColor, System.Drawing.Color hiForeColor, System.Drawing.Color hiBackColor, Microsoft.VisualStudio.TextManager.Interop.FONTFLAGS fontFlags);
new Microsoft.VisualStudio.Package.ColorableItem : string * string * Microsoft.VisualStudio.TextManager.Interop.COLORINDEX * Microsoft.VisualStudio.TextManager.Interop.COLORINDEX * System.Drawing.Color * System.Drawing.Color * Microsoft.VisualStudio.TextManager.Interop.FONTFLAGS -> Microsoft.VisualStudio.Package.ColorableItem
Public Sub New (name As String, displayName As String, foreColor As COLORINDEX, backColor As COLORINDEX, hiForeColor As Color, hiBackColor As Color, fontFlags As FONTFLAGS)

Parameters

name
String

[in] The name of the colorable item. This can be used in the properties listing if you support customizing your own custom colors.

displayName
String

[in] The name of the colorable item that is displayed in the Fonts and Colors list of colors. This is the localized name.

foreColor
COLORINDEX

[in] The text's foreground color as specified by a value from the COLORINDEX enumeration.

backColor
COLORINDEX

[in] The text's background color as specified by a value from the COLORINDEX enumeration.

hiForeColor
Color

[in] A Color structure describing the foreground color in terms of red, green, blue components. This value can be Empty if high colors are not used.

hiBackColor
Color

[in] A Color structure describing the background color in terms of red, green, blue components. This value can be Empty if high colors are not used.

fontFlags
FONTFLAGS

[in] A set of flags from the FONTFLAGS enumeration describing how the text is to be rendered.

Remarks

All of this information must be specified for each colorable item.

Applies to