title: WPF databinding problem
body: <p>I have a grid inside a canvas on a tab.
  The grid contains a large bitmap image,
  I have(tried to) bound the size of the grid to the size of the tab and also have a five pixel margin around the grid.</p>
  
  <p>imageTab.cs</p>
  
  <pre><code>    public ImageTab(SendInfo sendInfo, int numImge, int numAccs)
      {
          imageDisplay = new ImageDisplay(sendInfo, numImge, numAccs);
          imageDisplay.ClipToBounds = true;
          CreateCanvas();
      }
  
      private void CreateCanvas()
      {
          Canvas canvas = new Canvas();
          canvas.Children.Add(imageDisplay);
          this.AddChild(canvas);
      }
  </code></pre>
  
  <p>ImageDisplay.xaml</p>
  
  <pre><code>&lt;UserControl x:Class="MyProj.ImageDisplay"&gt;
  
        &lt;Grid Margin="5,5,5,5" Height="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=TabControl, AncestorLevel=1}, Path=ActualHeight}"&gt;
            &lt;Image/&gt;
        &lt;/Grid&gt;
  
  &lt;/UserControl&gt;
  </code></pre>
  
  <p>The grid comes off the bottom of the tab area slightly causing the bottom of the image to be cut off.
  Is there a problem with my databinding, do I need to apply some sort of offset to it? (size of tab - 10pixels for the margin?)</p>