This post contains source code for a simple slide in/out control built in Silverlight.
First of all let's look at the sample below:
Move mouse over blue rectangle and control content will slide out.
Such control can preserve some visual space needed for application and it's really easy to use. Just drop it inside xaml and set GripWidth property.
Control style can be also easily changed inside generic.xaml file.
Here is the code illustrating how slide control can be used on a page:
<local:SimpleSlideControl
GripWidth="20" />
Below is the code for the the slide control template:
<Style
TargetType="local:SimpleSlideControl" >
<Setter
Property="Template" >
<Setter.Value >
<ControlTemplate
TargetType="local:SimpleSlideControl" >
<Canvas
x:Name="host" >
<StackPanel
x:Name="panel"
Orientation="Horizontal" >
<ContentControl
Content="{TemplateBinding Content}" />
<Rectangle
x:Name="grip"
Fill="Blue"
Width="{TemplateBinding GripWidth}" />
</StackPanel>
</Canvas>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
If you want to change grip style - just remove "grip" rectangle and replace it with something more appropriate.
Source
I hope it will be helpful ;)