IVsContainedLanguageColorizer.ColorizeLineFragment Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Colorizes the specified line fragment or text.
public:
int ColorizeLineFragment(int iLine, int iIndex, int iLength, System::String ^ pszText, int iState, [Runtime::InteropServices::Out] System::UInt32 % pAttributes, [Runtime::InteropServices::Out] int % piNewState);
int ColorizeLineFragment(int iLine, int iIndex, int iLength, std::wstring const & pszText, int iState, [Runtime::InteropServices::Out] unsigned int & pAttributes, [Runtime::InteropServices::Out] int & piNewState);
public int ColorizeLineFragment (int iLine, int iIndex, int iLength, string pszText, int iState, out uint pAttributes, out int piNewState);
abstract member ColorizeLineFragment : int * int * int * string * int * uint32 * int -> int
Public Function ColorizeLineFragment (iLine As Integer, iIndex As Integer, iLength As Integer, pszText As String, iState As Integer, ByRef pAttributes As UInteger, ByRef piNewState As Integer) As Integer
Parameters
- iLine
- Int32
[in] Number of the line to be colorized.
- iIndex
- Int32
[in] Starting character index for the line fragment.
- iLength
- Int32
[in] Number of characters to colorize.
- pszText
- String
[in] The actual text to colorize. The iLength
parameter specifies the number of characters from this string to colorize.
- iState
- Int32
[in] A state value used by the colorizer representing the state of parsing at the beginning of the line. The parsing state is custom to each colorizer.
- pAttributes
- UInt32
[out] Color attributes of the text.
- piNewState
- Int32
[out] The parsing state at the end of the specified text.
Returns
If successful, returns S_OK; otherwise, returns an error code.
Remarks
COM Signature
From singlefileeditor.idl:
long IVsContainedLanguageColorizer::ColorizeLineFragment(
[in] long iLine,
[in] long iIndex,
[in] long iLength,
[in] const WCHAR *pszText,
[in] long iState,
[out] ULONG * pAttributes
);