Use SolidColorBrush to paint Rectangle
<Window x:Class="WpfApplication1.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="WPF" Height="300" Width="300">
<Canvas Margin="5">
<Canvas.Resources>
<!--scRGB semi-transparent color-->
<SolidColorBrush Color="sc# 0.8,0.3,0.9,0.25" x:Key="Brush1" />
</Canvas.Resources>
<Rectangle Canvas.Top="5" Canvas.Left="5"
Fill="{StaticResource Brush1}" Height="180" Width="80" />
</Canvas>
</Window>
Related examples in the same category