IVsColorableItem.GetDefaultColors 方法
定義自訂的可設定色彩項目預設背景和前景色彩。
命名空間: Microsoft.VisualStudio.TextManager.Interop
組件: Microsoft.VisualStudio.TextManager.Interop (在 Microsoft.VisualStudio.TextManager.Interop.dll 中)
語法
'宣告
Function GetDefaultColors ( _
<OutAttribute> piForeground As COLORINDEX(), _
<OutAttribute> piBackground As COLORINDEX() _
) As Integer
int GetDefaultColors(
COLORINDEX[] piForeground,
COLORINDEX[] piBackground
)
int GetDefaultColors(
[OutAttribute] array<COLORINDEX>^ piForeground,
[OutAttribute] array<COLORINDEX>^ piBackground
)
abstract GetDefaultColors :
piForeground:COLORINDEX[] byref *
piBackground:COLORINDEX[] byref -> int
function GetDefaultColors(
piForeground : COLORINDEX[],
piBackground : COLORINDEX[]
) : int
參數
piForeground
類型:array<Microsoft.VisualStudio.TextManager.Interop.COLORINDEX[][] out傳回整數,包含的前景色彩。 如需詳細資訊,請參閱COLORINDEX。
piBackground
類型:array<Microsoft.VisualStudio.TextManager.Interop.COLORINDEX[][] out傳回包含背景色彩的整數。 如需詳細資訊,請參閱COLORINDEX。
傳回值
類型:Int32
如果此方法將會成功,則會傳回S_OK。如果失敗,它就會傳回錯誤碼。
備註
COM 簽章
從 textmgr.idl:
HRESULT IVsColorableItem::GetDefaultColors(
[out] COLORINDEX *piForeground,
[out] COLORINDEX *piBackground
);
傳回的色彩值取自COLORINDEX列舉,本質上為預先定義的色彩] 清單中的索引。
.NET Framework 安全性
- 完全信任立即呼叫者。這個成員無法供部分信任的程式碼使用。如需詳細資訊,請參閱從部分受信任程式碼使用程式庫。