Xceed Docking Windows for WinForms v2.3 Documentation
Auto-hide Tool Windows

Welcome to Xceed Docking Windows for WinForms v2.3 > Basic Concepts > Tool Windows > States > Auto-hide Tool Windows

Each tool window can be "pinned" or "unpinned". If a ToolWindow is unpinned, it will automatically hide when the mouse is no longer over it, and its associated tab will be displayed in the AutoHideFrame (see Figure 1). To reopen the tool window, the mouse must be placed over the tab. Interactively, a tool window can be pinned or unpinned by clicking on the "pin/unpin" glyph () in the caption unless the AllowAutoHide property is set to false. Only a docked tool window can be unpinned (state changed to AutoHide) or pinned (state changed to Docked). 


Figure 1: Auto-hide frame

AutoHideFrameAppearance property

The "thickness" of the auto-hide frame can be specified for the top/bottom sides as well as the left/right sides using the TopBottomHeight and LeftRightWidth properties. The height of the tabs contained in the auto-hide frame will be adjusted according to size of the section they are contained in. Ideally, each tool window should have a 16x16 image in order for its associated tab to have a proper appearance when it is displayed. If an image larger than 16x16 is used, the height and width of the frame sections must be changed accordingly. The thickness of the auto-hide frame will not automatically adjusted to the image size. 

The background color of the auto-hide frame can be specified using the BackColor property. The background and foreground colors as well as the font of the tabs contained in the auto-hide frame can be specified using the TabBackColor, TabForeColor, and TabFont properties. The color of the tabs' border can be changed via the TabBorderColor property. The background and foreground colors as well as the font of the selected tab can be modified using the SelectedTabBackColor, SelectedTabForeColor, and SelectedTabFont properties (see Example 1). 

Show/Hide Animation

The AnimationDuration property of auto-hide frame indicates the time it takes, in milliseconds, to show or hide auto hide tool windows. If the AnimationDuration property is set to 0, the tool window will be shown and hidden using animation. The ShowHideDelay property indicates, in milliseconds, the length of time the mouse must hover over an auto-hide tool window's tab before the animation to show the tool window begins, as well as the length of time before the animation to hide an auto hide tool window begins when the mouse leaves the tool window.

Examples

Example 1: Changing the appearance of the auto-hide frame

The following code demonstrates how to change the background color and height of the auto-hide frame as well as how to change the background and foreground color of the tabs it contains
 
VB.NET Copy Code

m_manager.AutoHideFrameAppearance.BackColor = Color.LightSteelBlue
m_manager.AutoHideFrameAppearance.TabBackColor = Color.SteelBlue
m_manager.AutoHideFrameAppearance.TabForeColor = Color.White

m_manager.AutoHideFrameAppearance.TopBottomHeight = 30

C# Copy Code

m_manager.AutoHideFrameAppearance.BackColor = Color.LightSteelBlue;
m_manager.AutoHideFrameAppearance.TabBackColor = Color.SteelBlue;
m_manager.AutoHideFrameAppearance.TabForeColor = Color.White;

m_manager.AutoHideFrameAppearance.TopBottomHeight = 30;