I’m looking for an effect similar to ---- or ----. However, the code below is creating a strike through effect. I thought that setting Grid.ZIndex would solve the issue, however it doesn’t seem to be doing anything.
<Grid>
<TextBlock Text="or" FontSize="22" Height="34" Grid.ZIndex="2" HorizontalAlignment="Center" />
<Line Stretch="Fill" Stroke="Black" X1="1" Margin="0 4 0 -1" SnapsToDevicePixels="True" Grid.ZIndex="1" Height="34" />
</Grid>
If I set a background to my TextBlock control then all works fine. What I want, though, is to use the default gray background (e.g. not set a background at all).
How can I accomplish this?
The solution was actually quite simple.