)
We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to change the fore color and back color of tabbed dock windows in DockingManager

Platform: WinForms |
Control: DockingManager |
Published Date: January 31, 2018 |
Last Revised Date: May 23, 2019

BackColor and ForeColor of the items of the DockTab can be changed using following properties,

ActiveTabForeColor - Using this property ForeColor of the ActiveTab in DockTab can be changed.

InActiveTabForeColor - Using this property ForeColor of the InActiveTab in DockTab can be changed.

ActiveTabColor – Using this property BackColor of the ActiveTab in DockTab can be changed.

InactiveTabColor – Using this property BackColor of the InActiveTab in DockTab can be changed.

The following code example illustrate the same,

 

C#

            dockingManager1.DockTabFont = new Font("Calibri", 10);
            DockTabControl docktab;
            DockHost dhost = this.panel3.Parent as DockHost;
            if (dhost != null)
            {
                DockHostController dhc = dhost.InternalController as 
                                         DockHostController;
                if (dhc != null && dhc.ParentController is DockTabController)
                {
                    docktab = (dhc.ParentController as DockTabController).TabControl;
                    docktab.InActiveTabForeColor = Color.WhiteSmoke;
                    docktab.ActiveTabForeColor = Color.Brown;
                    docktab.TabPanelBackColor = Color.WhiteSmoke;
                    docktab.ActiveTabColor = Color.Yellow;
                    docktab.InactiveTabColor = Color.Black;                     
                }
            }

 

Screenshot:

Showing applied back color and fore color of tabbed dock windows

Sample Link:

http://www.syncfusion.com/downloads/support/directtrac/general/ze/TabForeBackColor_Sample1533342199.zip

 

2X faster development

The ultimate WinForms UI toolkit to boost your development speed.
ADD COMMENT
You must log in to leave a comment

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon