CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 1999
    Posts
    6

    SUBJECT: NCPAINT doesn't work proberly

    Hi,

    I'm writing a new dialog class which changes the
    visible appearence. Therefore I overwrote the
    DefWindowProc to handle the WM_NCPAINT message
    by myself. The problem now is that Windows
    sometimes do it's own drawing stuff and don't
    call my new draw function. This happens when I
    move the window or when the window gets inactive.

    The program code looks like that:

    LRESULT CNCTestDlg:efWindowProc(UINT message, WPARAM wParam, LPARAM lParam)
    {
    switch (message)
    {
    case WM_NCPAINT :
    {
    NcPaint();
    return 0;
    }
    }

    return CDialog:efWindowProc(message, wParam, lParam);
    }

    The NcPaint() function does the drawing stuff.


    Hope someone can help me.

    Thanks in advance

    Martin Horst


  2. #2
    Guest

    Re: SUBJECT: NCPAINT doesn't work proberly

    hi,
    you have to overide other messages which will be generated when you move
    dialog box.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured