win32—— hIcon hCursor hbrBackground
2021-05-08 00:29
标签:adf toc span gets blog rgb image 图片 bit win32—— hIcon hCursor hbrBackground 标签:adf toc span gets blog rgb image 图片 bit 原文地址:http://www.cnblogs.com/ming-michelle/p/7636118.html //当在资源中时,exe可以出效果
//但从文件中添加时,是不可以的
wnd.hIcon = (HICON)LoadIcon(hInstance, MAKEINTRESOURCE(IDI_ICON1));
wnd.hIcon = (HICON)::LoadImage(NULL, _T("a.ico"), IMAGE_ICON, 0, 0, LR_DEFAULTSIZE | LR_LOADFROMFILE);
wnd.hCursor = LoadCursor(hInstance, MAKEINTRESOURCE(IDI_CURSOR1));
wnd.hCursor = LoadCursorFromFile(_T("b.cur"));
wnd.hCursor = (HCURSOR)LoadImage(hInstance, _T("a.cur"), IMAGE_CURSOR, 32, 32, LR_LOADFROMFILE);
wnd.hbrBackground = (HBRUSH)GetStockBrush(DKGRAY_BRUSH);
wnd.hbrBackground = CreateSolidBrush(RGB(183, 157, 226));
wnd.hbrBackground = (HBRUSH)(COLOR_WINDOW + 10);
HBITMAP hbit = (HBITMAP)LoadImage(hinstance, _T("bk.bmp"), IMAGE_BITMAP, 500, 375, LR_LOADFROMFILE); //500*375图片大小
HBITMAP hbrush = CreatePatternBrush(hbit);
wnd.hbrBackground = hbrush;
文章标题:win32—— hIcon hCursor hbrBackground
文章链接:http://soscw.com/index.php/essay/83901.html