Hi! I would like to draw a Tab Control myself (instead of the recatangle,
for example, I would like to draw a rounded Rect). Is there any way to do
this or should I create my own Tab Control?
Thanks.
Martin
Tim Wilson - 21 Apr 2006 20:14 GMT
You can use the GraphicsPath class to construct a rounded region and then
set this region into the Region property of the TabControl. There is
information in the newsgroup archives on constructing a rounded rectangle.
http://groups.google.com/groups?as_ugroup=microsoft.public.dotnet.*&as_q=rounded
+rectangle

Signature
Tim Wilson
.NET Compact Framework MVP
> Hi! I would like to draw a Tab Control myself (instead of the recatangle,
> for example, I would like to draw a rounded Rect). Is there any way to do
> this or should I create my own Tab Control?
> Thanks.
> Martin
Mick Doherty - 21 Apr 2006 20:25 GMT
Depends on exactly what you want.
You can Fully OwnerDraw the TabControl, but if you want full control over
the location and size of the tabs, then you'll be better off creating a new
tabcontrol from scratch.
Some links which you may find useful:
a.. http://www.dotnetrix.co.uk/tabcontrols.html
b.. http://www.dotnetrix.co.uk/custom.html ("Create a PanelManager" can
easily be modified to build a custom tabcontrol)
c.. http://www.codeproject.com/cs/miscctrl/flattabcontrol.asp
d.. http://www.codeproject.com/dotnet/CustomTabControl.asp

Signature
Mick Doherty
http://dotnetrix.co.uk/nothing.html
> Hi! I would like to draw a Tab Control myself (instead of the recatangle,
> for example, I would like to draw a rounded Rect). Is there any way to do
> this or should I create my own Tab Control?
> Thanks.
> Martin