the problem: I have some UCControl than design geometric shapes. I can configure at runtime, dimensions (size and stroke thickness), colours (background and stroke) and all work fine until I use solid colors. Problems happened if I use, for stroke, Transparent brush: the shape appears with correct dimensions and colours, but the strokethikness is halve.
<Grid x:Name="_grid" >
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Rectangle Grid.Row="0" Grid.Column="0" Margin="0,0,0,0"
Width="{Binding ActualWidth, ElementName=_grid}"
Height="{Binding ActualHeight, ElementName=_grid}"
Stroke="{Binding Rectangle.BorderColorBrush}"
StrokeThickness="{Binding Rectangle.Thick}"
Fill="{Binding Rectangle.BackgroundBrush}"/>
</Grid>
I need than if stroke is a solid color or Transparent, the stroke thick on the draw is the same. I found at this moment this: the Brown is background color, Black or Transparent the Stroke. StrokeThickness is 20 for both (see dot grid: distanced 10)