title: WPF C# how to create THIS binding in code?
body: <p>I wonder, how to create this binding, since Line.X2 IS NOT dependency property! :(</p>
  
  <pre><code>&lt;Line Y1="0" X1="0" Y2="0" Stroke="Blue" StrokeThickness="3" Margin="0 -2 0 -2" X2="{Binding Path=RenderSize.Width, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type StackPanel}}}"/&gt;
  </code></pre>