Results 1 to 3 of 3

Thread: DrawItem Event in TabControl Doesn't Cover the Entire Header

  1. #1

    Thread Starter
    Hyperactive Member neef's Avatar
    Join Date
    Dec 2001
    Location
    Boston
    Posts
    311

    DrawItem Event in TabControl Doesn't Cover the Entire Header

    I'm using a TabControl and have overridden the DrawItem event to produce my own background and foreground colors for the header text. It looks good but there's still grey color around each header. I thought maybe the Padding property could be set to (0,0) but that seemed to have no effect.

    Here is a screenshot.

    Name:  ScreenHunter_02 Aug. 01 10.59.gif
Views: 1437
Size:  40.8 KB

    How can I get rid of the grey edges?

    Thanks.
    Intermediate Level Programmer Extraordinaire

  2. #2
    Hyperactive Member
    Join Date
    Apr 2011
    Location
    England
    Posts
    421

    Re: DrawItem Event in TabControl Doesn't Cover the Entire Header

    Hi Neef,

    Here is a good link to OwnerDraw examples and source code for the TabControl: http://dotnetrix.co.uk/tabcontrol.htm

    Hope this helps

  3. #3

    Thread Starter
    Hyperactive Member neef's Avatar
    Join Date
    Dec 2001
    Location
    Boston
    Posts
    311

    Re: DrawItem Event in TabControl Doesn't Cover the Entire Header

    Excellent link, thank you very much!
    Intermediate Level Programmer Extraordinaire

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width