Your problem is that the window size includes the size of Chrome (window border, etc., such as close / max min buttons).
So your grid is the size you requested, but it doesn't match the size of the window you requested.
, : :
: 202
: 210
Windows 8
SizeToContent="WidthAndHeight"
:
<Window x:Class="WpfApplication4.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:WpfApplication4"
x:Name="window"
Title="MainWindow"
SizeToContent="WidthAndHeight">
<Grid HorizontalAlignment="Left" Height="171" VerticalAlignment="Top" Width="186">
<Rectangle Fill="#FFF4F4F5" HorizontalAlignment="Left" Height="151" Margin="10,10,0,0" Stroke="Black" VerticalAlignment="Top" Width="166"/>
</Grid>
</Window>
, Chrome, Windows.
Snoop. . , Shift + Ctrl, , Grid ,
