I want to make a child window that is clipped by the main app window (its parent) and it should move with the main app window when the user moves it. This is exactly how the child documents behave in an MDI application. I can't use MFC though.
I have reproduced this same functionality by specifying the following window style for the child:
WS_CHILD | WS_VISIBLE | WS_CAPTION
However, the title bar of this child is always greyed out. I cannot find any combination of styles that will allow the title bar to be active. I tried artificially setting the focus when the user clicks on the child using
SetFocus(), EnableWindow(), ShowWindow(), but to no avail, the title bar is still greyed out! This is more a stylistic annoyance than anything else as the functionality is there, please can someone tell me how to correct this!