void CDemoDlg::OnBnClickedButtonSm()
{
// TODO: 在此添加控件通知处理程序代码
CListBox* pListBox = (CListBox*)GetDlgItem(IDC_LIST);
pListBox->ResetContent();
CString strText;
strText.Format(_T("屏幕大小: %d x %d"),GetSystemMetrics(SM_CXSCREEN),GetSystemMetrics(SM_CYSCREEN));
pListBox->AddString(strText);
strText.Format(_T("全屏窗口大小: %d x %d"),GetSystemMetrics(SM_CXFULLSCREEN),GetSystemMetrics(SM_CYFULLSCREEN));
pListBox->AddString(strText);
strText.Format(_T("最大化窗口大小: %d x %d"),GetSystemMetrics(SM_CXMAXIMIZED),GetSystemMetrics(SM_CYMAXIMIZED));
pListBox->AddString(strText);
strText.Format(_T("最小化窗口大小: %d x %d"),GetSystemMetrics(SM_CXMINIMIZED),GetSystemMetrics(SM_CYMINIMIZED));
pListBox->AddString(strText);
strText.Format(_T("窗口边框大小: %d x %d"),GetSystemMetrics(SM_CXBORDER),GetSystemMetrics(SM_CYBORDER));
pListBox->AddString(strText);
strText.Format(_T("固定边框厚度: %d x %d"),GetSystemMetrics(SM_CXFIXEDFRAME),GetSystemMetrics(SM_CYFIXEDFRAME));
pListBox->AddString(strText);
strText.Format(_T("可变边框厚度: %d x %d"),GetSystemMetrics(SM_CXSIZEFRAME),GetSystemMetrics(SM_CYSIZEFRAME));
pListBox->AddString(strText);
strText.Format(_T("水平滚动条箭头大小: %d x %d"),GetSystemMetrics(SM_CXHSCROLL),GetSystemMetrics(SM_CYHSCROLL));
pListBox->AddString(strText);
strText.Format(_T("垂直滚动条箭头大小: %d x %d"),GetSystemMetrics(SM_CXVSCROLL),GetSystemMetrics(SM_CYVSCROLL));
pListBox->AddString(strText);
strText.Format(_T("标题栏高度: %d"),GetSystemMetrics(SM_CYCAPTION));
pListBox->AddString(strText);
strText.Format(_T("标题栏按钮大小: %d x %d"),GetSystemMetrics(SM_CXSIZE),GetSystemMetrics(SM_CYSIZE));
pListBox->AddString(strText);
strText.Format(_T("菜单栏高度: %d"),GetSystemMetrics(SM_CYMENU));
pListBox->AddString(strText);
strText.Format(_T("鼠标指针大小: %d x %d"),GetSystemMetrics(SM_CXCURSOR),GetSystemMetrics(SM_CYCURSOR));
pListBox->AddString(strText);
strText.Format(_T("默认图标大小: %d x %d"),GetSystemMetrics(SM_CXICON),GetSystemMetrics(SM_CYICON));
pListBox->AddString(strText);
}