Hello All,
I am looking at an example from charles petzold's book ("Programming Windows", Fifth Edition, Chapter 11, Figure 11-3. "the ABOUT2 program" in which the initial static text control painting is not done in response to the WM_INITDIALOG message. Instead he handles the WM_PAINT message in the dialog box procedure and paints the static text control there. So, I was wondering if after the DialogBox() function is called (from the main application window's procedure) to create the dialog box, Windows sends the dialog box procedure the WM_PAINT message soon after it sends the WM_INITDIALOG message. How else is the static text control on the dialog box painted initially according to this example program in his book?.
I understand that incase of a regular window (main application window), the WinMain() calls UpdateWindow () which causes WM_PAINT to be sent to the window procedure where initial painting can be done. I am trying to understand how this is done in case of dialog boxes.
Thanks
Best Regards
Chandra
I am looking at an example from charles petzold's book ("Programming Windows", Fifth Edition, Chapter 11, Figure 11-3. "the ABOUT2 program" in which the initial static text control painting is not done in response to the WM_INITDIALOG message. Instead he handles the WM_PAINT message in the dialog box procedure and paints the static text control there. So, I was wondering if after the DialogBox() function is called (from the main application window's procedure) to create the dialog box, Windows sends the dialog box procedure the WM_PAINT message soon after it sends the WM_INITDIALOG message. How else is the static text control on the dialog box painted initially according to this example program in his book?.
I understand that incase of a regular window (main application window), the WinMain() calls UpdateWindow () which causes WM_PAINT to be sent to the window procedure where initial painting can be done. I am trying to understand how this is done in case of dialog boxes.
Thanks
Best Regards
Chandra