IVsStatusbar.SetColorText(String, UInt32, UInt32) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
用前景色和背景色设置状态栏文本。
public:
int SetColorText(System::String ^ pszText, System::UInt32 crForeColor, System::UInt32 crBackColor);
public:
int SetColorText(Platform::String ^ pszText, unsigned int crForeColor, unsigned int crBackColor);
int SetColorText(std::wstring const & pszText, unsigned int crForeColor, unsigned int crBackColor);
public int SetColorText (string pszText, uint crForeColor, uint crBackColor);
abstract member SetColorText : string * uint32 * uint32 -> int
Public Function SetColorText (pszText As String, crForeColor As UInteger, crBackColor As UInteger) As Integer
参数
- pszText
- String
中要在状态文本区域中显示的文本。
- crForeColor
- UInt32
中的前景色 pszText 。
- crBackColor
- UInt32
中的背景色 pszText 。
返回
如果该方法成功,则它会返回 S_OK。 如果该方法失败,则会返回错误代码。
注解
COM 签名
从 vsshell:
HRESULT IVsStatusbar::SetColorText(
[in]LPCOLESTR pszText,
[in] COLORREF crForeColor,
[in] COLORREF crBackColor
);
方法忽略和的值 crForeColor crBackColor ,并且始终将前景色设置为白色,将背景色设置为深蓝色。