原文转自 http://blog.csdn.net/cracent/article/details/48274469

 

BOOL CLoginDlg::OnInitDialog()
{
    CDialog::OnInitDialog();

    SetWindowLong(m_hWnd, GWL_HWNDPARENT, NULL);

    CRgnm_rgn;
    RECT rc;
    GetWindowRect(&rc); //有边框对话框

    //GetClientRect(&rc);//无边框对话框
    m_rgn.CreateRoundRectRgn(rc.left, rc.top, rc.right, rc.bottom, 100, 100); //矩形圆角

    //m_rgn.CreateEllipticRgn(rc.left,rc.top,rc.right,rc.bottom);//椭圆
    SetWindowRgn(m_rgn, TRUE);

    return TRUE; // return TRUE unless you set the focus to a control 
}

相关文章:

  • 2022-12-23
  • 2021-12-21
  • 2021-12-25
  • 2022-01-29
  • 2021-11-27
  • 2022-12-23
  • 2021-06-05
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-04-24
  • 2021-07-04
  • 2021-08-27
  • 2022-12-23
  • 2021-06-20
  • 2021-10-18
相关资源
相似解决方案