# Pinned/Unpinned Panes

Each **RadPane** provides built-in pin/unpin functionality that allows you to control the behavior and the visualization of the docked **RadPanes** during run-time.

By default this functionality is enabled and when a **RadPane** is docked, pin/unpin toggle button is created and placed at its upper right corner. To toggle the pinned state of a certain **RadPane** just click the button, highlighted on **Figure 1**.

> caption Pin button on a docked pane

![Pin button on a docked pane](https://www.telerik.com/products/wpf/documentation/assets/4559764921c1e20254457dd544d4ff00/raddocking_features_panes_pinn_unpinn_010.png)

You can also change the pin state of a **RadPane** programmatically using the **RadPane**'s boolean property **IsPinned**.

**Example 1: Set the IsPinned property on a pane**

```XAML
<telerik:RadPane x:Name="radPane" IsPinned="True"/>
```

```C#
radPane.IsPinned = true;
```

```VB.NET
radPane.IsPinned = True
```

You can also pin/unpin all of the panes inside of a [RadPaneGroup](https://www.telerik.com/products/wpf/documentation/controls/raddocking/features/pane-groups) using the **group.PinAllPanes()** and **group.UnpinAllPanes()** methods.

## Pinned Panes

You can recognize that a docked **RadPane** is pinned if it is visible all the time, even if your mouse cursor is not over it. On the snapshot below you can see two pinned **RadPanes** docked to the left and to the right side of the docking container. **Note that the pin icon of the toggle button is pointing downwards.**

![WPF RadDocking Pinned Panes](https://www.telerik.com/products/wpf/documentation/assets/cd86e2847eb08bd7e620e292a17e3bd8/raddocking_features_panes_pinn_unpinn_020.png)

## Unpinned Panes

The unpinned **RadPane** is shown only when the mouse cursor is over it and is hidden when the cursor leaves its area. When it is hidden you can only see its tab header placed in the auto-hide area, while when shown, it is slided on the top of all the other controls without affecting the overall layout.

On the snapshot below you can see two unpinned **RadPanes**; the first is a "Toolbox" docked to the left, the second is a "Solution Explorer" docked respectively to the right. You can see that all their content is hidden, except their tab headers placed in the auto-hide area.

![WPF RadDocking Unpinned and Hidden Panes](https://www.telerik.com/products/wpf/documentation/assets/832dcb8f00a0bc0b98b7c729c69ad294/raddocking_features_panes_pinn_unpinn_030.png)

If you hover your mouse over the tab of the "Toolbox" pane, it will slide automatically overlapping the other content. **Note that the pin icon of the toggle button is pointing sideways.**

![WPF RadDocking Hovered Pane](https://www.telerik.com/products/wpf/documentation/assets/6ca96ee59f984c9e6e4353e9234677a5/raddocking_features_panes_pinn_unpinn_040.png)

> tip If you want to control the auto-hide area's width and hight of your unpinned panes use the respective **RadPane**'s properties **AutoHideHeight** and **AutoHideWidth**. The size of the auto-hide area is also affected by the **FlyoutMinLength** property of RadDocking.

## Let Auto-Hide Area Content Exceed Screen

As the element hosting the content of the pane when you hover over the auto-hide area is a popup, it will try to position itself optimally so that all of it's content is displayed. An example of this behavior when such a popup is opened near the edge of the screen is illustrated in **Figure 2**.

> caption Default unpinned pane near the edge of the screen

![Default unpinned pane near edge of screen](https://www.telerik.com/products/wpf/documentation/assets/112684d1c0a431a8b610bee56a82d324/canautohideareaexceedscreen_false.png)

If, however, you want to force the panes to go outside of the screen, you can set the **CanAutoHideAreaExceedScreen** property of the RadDocking control to **True**. The result in such a scenario can be observed in **Figure 3**.

> caption Unpinned pane near the edge of the screen with CanAutoHideAreaExceedScreen set to true

![Unpinned pane near edge of screen with CanAutoHideAreaExceedScreen set to True](https://www.telerik.com/products/wpf/documentation/assets/f94d00b60ed65532b90d52c029a9177c/canautohideareaexceedscreen_true.png)

## Disabling Pin

If you don't want your **RadPanes** to be pinnable just set the **CanUserPin** property to **False**. Once disabled the user will not be able to change the pin state of a **RadPane** run-time because the toggle button will be hidden. This has been illustrated in **Figure 4**.

> caption Docked pane with no pin button

![Docked pane with no pin button](https://www.telerik.com/products/wpf/documentation/assets/69eb6dea7969c7efdf29faa0277db270/raddocking_features_panes_pinn_unpinn_050.png)

**Example 2: Disable pinning of panes via the CanUserPin property**

```XAML
<telerik:RadPane x:Name="radPane1" CanUserPin="False"/>
```

```C#
radPane.CanUserPin = false;
```

```VB.NET
radPane.CanUserPin = False
```

## See Also

* [RadPane](https://www.telerik.com/products/wpf/documentation/controls/raddocking/features/panes/radpane)

* [RadDocumentPane](https://www.telerik.com/products/wpf/documentation/controls/raddocking/features/panes/raddocumentpane)

* [Docked/Floating Panes](https://www.telerik.com/products/wpf/documentation/controls/raddocking/features/panes/docked-floating-panes)
