MCPcopy Create free account
hub / github.com/BeneficialCode/WinArk / InitColorSys

Function InitColorSys

WinArk/ThemeSystem.cpp:25–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23HWND g_hWndTop = 0;
24
25void InitColorSys() {
26 HDC hdc = GetDC(g_hWndMainFrame);
27 g_crLightGray = GetNearestColor(hdc, RGB(0xc0, 0xc0, 0xc0));
28 g_crDarkGray = GetNearestColor(hdc, RGB(0x80, 0x80, 0x80));
29 g_crBlack = GetNearestColor(hdc, RGB(0, 0, 0));
30
31 g_myColor[0] = GetNearestColor(hdc, RGB(0, 0, 0));
32 g_myColor[1] = GetNearestColor(hdc, RGB(0x80, 0, 0));
33 g_myColor[2] = GetNearestColor(hdc, RGB(0, 0x80, 0));
34 g_myColor[3] = GetNearestColor(hdc, RGB(0x80, 0x80, 0));
35 g_myColor[4] = GetNearestColor(hdc, RGB(0, 0, 0x80));
36 g_myColor[5] = GetNearestColor(hdc, RGB(0x80, 0, 0x80));
37 g_myColor[6] = GetNearestColor(hdc, RGB(0, 0x80, 0x80));
38 g_myColor[7] = GetNearestColor(hdc, RGB(0xc0, 0xc0, 0xc0));
39 g_myColor[8] = GetNearestColor(hdc, RGB(0x80, 0x80, 0x80));
40 g_myColor[9] = GetNearestColor(hdc, RGB(0xff, 0, 0));
41 g_myColor[10] = GetNearestColor(hdc, RGB(0, 0xff, 0));
42 g_myColor[11] = GetNearestColor(hdc, RGB(0xff, 0xff, 0));
43 g_myColor[12] = GetNearestColor(hdc, RGB(0, 0, 0xff));
44 g_myColor[13] = GetNearestColor(hdc, RGB(0xff, 0, 0xff));
45 g_myColor[14] = GetNearestColor(hdc, RGB(0, 0xff, 0xff));
46 g_myColor[15] = GetNearestColor(hdc, RGB(0xff, 0xff, 0xff));
47 g_myColor[16] = GetNearestColor(hdc, RGB(0xc0, 0xdc, 0xc0));
48 g_myColor[17] = GetNearestColor(hdc, RGB(0x16, 0xc6, 0x12));
49 g_myColor[18] = GetNearestColor(hdc, RGB(0x53, 0x53, 0x53));
50 g_myColor[19] = GetNearestColor(hdc, RGB(0xa4, 0xa0, 0xa0));
51}
52
53void InitFontSys() {
54 LOGFONT lf;

Callers 1

RunFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected