private void UpdateStyles()
{
// To show style changes, the non-client area must be repainted. Using the
// control's Invalidate method does not affect the non-client area.
// Instead use a Win32 call to signal the style has changed.
User32.SetWindowPos(MdiClient.Handle, IntPtr.Zero, 0, 0, 0, 0,
Win32.FlagsSetWindowPos.SWP_NOACTIVATE |
Win32.FlagsSetWindowPos.SWP_NOMOVE |
Win32.FlagsSetWindowPos.SWP_NOSIZE |
Win32.FlagsSetWindowPos.SWP_NOZORDER |
Win32.FlagsSetWindowPos.SWP_NOOWNERZORDER |
Win32.FlagsSetWindowPos.SWP_FRAMECHANGED);
}