I have these visual glitches on every tabControls when I am changing its tabPages BackColor and the BackColor of the form, as illustrated on the following images:
- At the top of the
tabPage, there is an interior one-pixel white border. - At the left of the
tabPage, there is an interior three-pixels white border. - At the bottom of the
tabPage, there is an interior one-pixel white border and an exterior two-pixels white border. - At the right of the
tabPage, there is an interior one-pixel white border and an exterior two-pixels white border.



Is there a way I can get rid of those white borders?
Here’s my attempted hack. I used a
NativeWindowto draw over theTabControlto fill in those “white” spaces. I won’t claim it’s perfect:And to hook it up:
My end result: