I am new to WPF. My requirement is to make a splash screen with rounded rectangle. I did some searching and achieved the round rectangle. But the issue is that it fails some area. Kindly see the screenshot and check the code below.

In that image you can see the black border is breaking at the corners
Here is my xaml
<Window x:Class="TimeLogger.StartWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Width="470" Height="270" ShowInTaskbar="False" WindowStartupLocation="CenterScreen"
ResizeMode="NoResize" WindowStyle="None" AllowsTransparency="True" Background="Transparent" >
<Border BorderBrush="#FF000000" BorderThickness="2,2,2,2" CornerRadius="8,8,8,8">
<Grid Background="#012a7a" >
<Label Margin="-5,-7,5,7">
<TextBlock Foreground="Black" FontFamily="Segoe UI" FontSize="25" FontStretch="UltraExpanded" Height="71" Width="177">
TimeLogger
</TextBlock>
</Label>
</Grid>
</Border>
</Window>
Applying a corner radius to a border does not shrink the size of the border’s content so that it’s circumscribed. You’re seeing the Grid painting on top of the border because it’s still filling the full area that the border says it has available. The fix is fairly easy:
Something like this: