16,472
社区成员
发帖
与我相关
我的任务
分享
//set full screen display
CRect m_rcMain;
GetWindowRect(&m_rcMain);//restore the src screen's size;
//delete the showing window's caption
long style= GetWindowLong(m_hWnd,GWL_STYLE);
style &=~WS_CAPTION;
//set the window's show sytle
SetWindowLong(m_hWnd,GWL_STYLE,style);
//get the screen's pixel
int screenX = GetSystemMetrics(SM_CXSCREEN);
int screenY = GetSystemMetrics(SM_CYSCREEN);
//show window
SetWindowPos(NULL,0,0,screenX,screenY,SWP_NOZORDER);
//reposition the controllers
CWnd *pWnd;
//“some static string”
pWnd=GetDlgItem(IDC_STATIC_1);
pWnd->SetWindowPos (NULL,screenX/2-130,screenY/5-20,NULL,NULL,SWP_NOZORDER|SWP_NOSIZE);