MFC 控件随窗体大小变化而变化
2009-07-01 12:20
309 查看
1.添加OnInitialUpdate()
2.添加控件成员变量
3.void CFS_DataView::OnInitialUpdate()
{
CFormView::OnInitialUpdate();
// TODO: Add your specialized code here and/or call the base class
CRect rect;
GetWindowRect( &rect );
if (m_wndlist.GetSafeHwnd())
{
m_wndlist.MoveWindow(CRect(0,22,rect.Width(),rect.Height()-20),TRUE);
}
}
2.添加控件成员变量
3.void CFS_DataView::OnInitialUpdate()
{
CFormView::OnInitialUpdate();
// TODO: Add your specialized code here and/or call the base class
CRect rect;
GetWindowRect( &rect );
if (m_wndlist.GetSafeHwnd())
{
m_wndlist.MoveWindow(CRect(0,22,rect.Width(),rect.Height()-20),TRUE);
}
}
相关文章推荐
- MFC中让控件随窗体大小变化而变化中需要注意的问题
- MFC控件随窗体大小变化的实现
- [MFC] 控件大小跟随对话框大小比例变化 [大三TJB_708]
- MFC 无边框窗体实现用鼠标拖动窗体边缘实现窗体大小变化
- 窗体控件大小随窗体大小变化而变化(VB.NET)
- MFC中控件大小随对话框大小动态变化
- CFormView上让控件的大小随着窗体的变化而自动适应
- mfc控件自适应窗口大小,随窗口大小变化而变化
- 窗体控件大小随窗体大小变化而变化
- MFC窗口和控件大小等比例变化
- 让对话框内的控件在窗体大小发生变化时随之变化
- 窗体中控件自动随窗体变化大小
- WinForm中控件位置不随窗体大小的变化而改变
- 在MFC中怎么样让控件的大小随着主窗体大小改变而改变
- MFC无边框的窗体实现用鼠标拖动窗体边缘实现窗体大小变化
- 窗体的控件随窗体变化自动调整大小
- vs2013 窗体应用编程—控件大小随窗体变化(通过代码实现)
- 如何让窗体大小随着控件的大小变化而变化
- winform控件随窗体大小变化而变化
- MFC中控件大小随对话框大小动态变化