In a comment on our previous post on creating glossy-looking items in WPF Jason asks how to emulate the glossy "now playing" section in apple's iTunes MP3 player. Although we don't want to condone the use of Macs, or any apple software on Windows we were prepared to grant Jason's request. Using these iTunes screen-shots as our starting point this is what we came up with.
iTunes "now playing" | WPF |
<Page xmlns="
http://schemas.microsoft.com/winfx/2006/xaml/presentation
"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:x="
http://schemas.microsoft.com/winfx/2006/xaml
"
Background="#785429" >
<Grid Width="200" Height="50">
<Rectangle Stroke="#56584c" StrokeThickness="1.5"
RadiusX="3" RadiusY="3" Fill="#d6dbbf"/>
<Rectangle VerticalAlignment="Top" Height="22" Margin="2,2,2,0"
Stroke="{x:Null}" RadiusX="2" RadiusY="2"
SnapsToDevicePixels="True">
<Rectangle.Fill>
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
<GradientStop Color="#EEF0E5" Offset="0" />
<GradientStop Color="#E4E7D5" Offset="0.9" />
</LinearGradientBrush>
</Rectangle.Fill>
</Rectangle>
</Grid>
</Page>