IVsFontAndColorUtilities::GetTrackedItemIndex Method (UInt32, Int32, Int32)
Visual Studio 2015
Obtain the index of a tracked color as represented by a COLORREF and a member of the __VSCOLORASPECT indicated if the color was used in the foreground or background.
Assembly: Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)
int GetTrackedItemIndex( unsigned int crSource, [OutAttribute] int% pAspect, [OutAttribute] int% piItem )
Parameters
- crSource
-
Type:
System::UInt32
[in] A COLORREF representation of color value.
- pAspect
-
Type:
System::Int32
[out] A valid member of the __VSCOLORASPECT indicating if the value of crSource is a foreground or background color.
- piItem
-
Type:
System::Int32
The index of the item being tracked.
Return Value
Type: System::Int32If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Managed code can obtain functionality equivalent to GetSysColor with SystemColors and convert between COLORREF and the System.Drawing.Color structure using M:System.Drawing.ColorTranslator.FromWin32 and M:System.Drawing.ColorTranslator.ToWin32.
Show: