MCPcopy
hub / github.com/lxn/walk / prepareDCForBackground

Method prepareDCForBackground

window.go:2249–2261  ·  view source on GitHub ↗
(hdc win.HDC, hwnd win.HWND, brushWnd Window)

Source from the content-addressed store, hash-verified

2247}
2248
2249func (wb *WindowBase) prepareDCForBackground(hdc win.HDC, hwnd win.HWND, brushWnd Window) {
2250 if _, ok := brushWnd.(Container); ok {
2251 win.SetBkMode(hdc, win.TRANSPARENT)
2252 }
2253
2254 var bgRC win.RECT
2255 win.GetWindowRect(brushWnd.Handle(), &bgRC)
2256
2257 var rc win.RECT
2258 win.GetWindowRect(hwnd, &rc)
2259
2260 win.SetBrushOrgEx(hdc, bgRC.Left-rc.Left, bgRC.Top-rc.Top, nil)
2261}
2262
2263func (wb *WindowBase) handleWMCTLCOLOR(wParam, lParam uintptr) uintptr {
2264 hwnd := win.HWND(lParam)

Callers 3

handleWMCTLCOLORMethod · 0.95
WndProcMethod · 0.95
tabWidgetTabWndProcFunction · 0.80

Calls 1

HandleMethod · 0.65

Tested by

no test coverage detected