title: WinForms tabpage not repainting on form resize
body: <p>Is there a reason why a .NET WinForms <code>TabPage</code> doesn't fully repaint its background when I resize the Form? It should be completely white (in Windows 7), but a portion remains gray (<code>SystemColors.Control</code>, most likely). Whenever I hit the maximize button, currently visible <code>TabPage</code> background doesn't get redrawn. Also, if I resize it, I need to move the form past the screen boundaries in order for it to get painted.</p>
  
  <p>The same thing happens if I minimize and then restore the form. In that case the <code>TabPage</code> background remains grey. Child controls are rendered properly (labels, for example, keep their white backgrounds).</p>
  
  <p>I am using Windows 7 32-bit, .NET 3.5. Tab control was added using the Visual Studio designer, and contains a couple of labels and two text boxes. I haven't changed any native style flags related to paint messages.</p>
  
  <p><strong>[Edit]</strong></p>
  
  <p>I have created a test project, source is <a href="http://pastebin.com/LJNE3c20" rel="noreferrer">uploaded here</a>.</p>
  
  <p>This is how the window looks initially:</p>
  
  <p><img src="https://i.stack.imgur.com/PWUHR.png" alt="Form initial state"></p>
  
  <p>This is how the window looks after I minimize it and then restore it:</p>
  
  <p><img src="https://i.stack.imgur.com/2IJt2.png" alt="Minimized, then restored"></p>
  
  <p>Note the change in <code>TabPage</code> background color.</p>