突然想做一个透明的windows窗口置顶,可以放一些信息上去,这样查阅资料方便。就像音乐播放器的歌词一样。慢慢学吧,第一步先学会做窗口。
参考:
https://brothergrup.iteye.com/blog/1602789
透明窗口:
https://blog.youkuaiyun.com/bjbz_cxy/article/details/81119772
#include <Windows.h> //windows窗口标准库函数
#include <stdio.h> //c语言需要的库函数
LRESULT CALLBACK WindowProc(//窗口过程函数原型
HWND hwnd, // handle to window
UINT uMsg, // message identifier
WPARAM wParam, // first message parameter
LPARAM lParam // second message parameter
);
int WINAPI WinMain(//窗口主函数,相当于 DOS下的main函数
HINSTANCE hInstance, // handle to current instance
HINSTANCE hPrevInstance, // handle to previous instance
LPSTR lpCmdLine, // pointer to command line
int nCmdShow // show state of window
)
{
WNDCLASS wcs;
wcs.cbClsExtra=0; //窗口类附加参数