如何 让 单文档 程序 窗口像 一个 对话框的外观,就是 视图窗口不要 陷下去, 要平的.?? 如题.多谢. 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 你说的是对话框? 要是对话框可在其属性中将Border属性去掉就能达到效果…… 不是 对话框 我 框架窗口 : class CMainFrame : public CFrameWnd怎么把他的外观 搞成 象对话框一样, 平的。 在OnInitialUpadata()里{ ModifyStyle(WS_EX_CLIENTEDGE,WS_EX_STATICEDGE); ModifyStyle(-1,WS_CHILD|WS_VISIBLE); CYourView::OnInitialUpdate(); GetParentFrame()->RecalcLayout(); ResizeParentToFit();}然后,在onNcpaint里写上如下几句话 CWindowDC dc(this); CRect rectClient; GetClientRect(rectClient); CRect rectWindow; GetWindowRect(rectWindow); ScreenToClient(rectWindow); rectClient.OffsetRect(-rectWindow.left, -rectWindow.top); dc.ExcludeClipRect(rectClient); rectWindow.OffsetRect(-rectWindow.left, -rectWindow.top); // Paint to a memory device context to help // eliminate screen flicker... // and draw a sunken border for the client area. SendMessage(WM_ERASEBKGND, (WPARAM)dc.m_hDC); dc.DrawEdge(rectWindow, BDR_RAISEDINNER, BF_RECT); 多谢 dc.DrawEdge(......)这个函数真的不错。那个边框原来是 非客户区 多谢 如何用钩子来hook一个窗口标题有改动的消息? list ctrl改变节点顺序 奇怪的Heap corrupt问题,_CrtIsValidHeapPointer失败 关于如何在VC下实现数据格式转换的问题 microsoft什么link可以上传其vc++中存在的bug的呢? 关于视口和窗口! 关于串口通讯问题,高分求助!!! MFC预编译问题 急!!请问在vc sdk环境下,怎么可以实现扁平的工具条?类似于ie里面的 求助,给出两张图片,第一张图片是一个瓶子a,怎么在第二张中所有的瓶子a用矩形框出来 初学遇到画图问题。。。请各位帮忙。。 请教关于CImageList 的一个问题
要是对话框可在其属性中将Border属性去掉就能达到效果……
我 框架窗口 : class CMainFrame : public CFrameWnd怎么把他的外观 搞成 象对话框一样, 平的。
{
ModifyStyle(WS_EX_CLIENTEDGE,WS_EX_STATICEDGE);
ModifyStyle(-1,WS_CHILD|WS_VISIBLE); CYourView::OnInitialUpdate();
GetParentFrame()->RecalcLayout();
ResizeParentToFit();}
然后,在onNcpaint里写上如下几句话
CWindowDC dc(this);
CRect rectClient;
GetClientRect(rectClient);
CRect rectWindow;
GetWindowRect(rectWindow);
ScreenToClient(rectWindow);
rectClient.OffsetRect(-rectWindow.left, -rectWindow.top);
dc.ExcludeClipRect(rectClient);
rectWindow.OffsetRect(-rectWindow.left, -rectWindow.top); // Paint to a memory device context to help
// eliminate screen flicker...
// and draw a sunken border for the client area.
SendMessage(WM_ERASEBKGND, (WPARAM)dc.m_hDC);
dc.DrawEdge(rectWindow, BDR_RAISEDINNER, BF_RECT);