GetSysColor The GetSysColor function retrieves the current color of the specified display element. Display elements are the parts of a window and the display that appear on the system display screen. DWORD GetSysColor( int nIndex // display element ); Parameters nIndex [in] Specifies the display element whose color is to be retrieved. This parameter can be one of the following values. Value Meaning COLOR_3DDKSHADOW Dark shadow for three-dimensional display elements.COLOR_3DFACE, COLOR_BTNFACE Face color for three-dimensional display elements and for dialog box backgrounds. RGB(218,208,200)
The GetSysColor function retrieves the current color of the specified display element. Display elements are the parts of a window and the display that appear on the system display screen. DWORD GetSysColor(
int nIndex // display element
);
Parameters
nIndex
[in] Specifies the display element whose color is to be retrieved. This parameter can be one of the following values. Value Meaning
COLOR_3DDKSHADOW Dark shadow for three-dimensional display elements.COLOR_3DFACE, COLOR_BTNFACE Face color for three-dimensional display elements and for dialog box backgrounds. RGB(218,208,200)
#define COLOR_BTNFACE 15
只是一个索引。
COLORREF color;
color =(COLORREF)GetSysColor(COLOR_BTNFACE);