title: WPF: How to install thumb behavior in a Canvas?
body: <p>I would like to have a Canvas that supports the DragDelta event. My first idea of how to do this was to make a ControlTemplate that includes a thumb. But I do not know how to do this correctly. How can I change the XAML below to make it compile, and what's the right way to install the DragDelta event handler?</p>
  
  <pre><code>&lt;UserControl.Resources&gt;
      &lt;ControlTemplate x:Key="Transparent"&gt;
          &lt;Rectangle Fill="Transparent"/&gt;
      &lt;/ControlTemplate&gt;
      &lt;ControlTemplate x:Key="ThumbCanvas" TargetType="{x:Type Canvas}"&gt;
          &lt;Grid&gt;
              &lt;Thumb x:Name="CanvasThumb" Template="{StaticResource Transparent}" DragDelta="CanvasThumb_DragDelta"/&gt;
              &lt;ContentPresenter Content="{TemplateBinding Content}"/&gt;
              &lt;!--error MC3011: Cannot find the static member 'ContentProperty' on the type 'Canvas'.--&gt;
          &lt;/Grid&gt;
      &lt;/ControlTemplate&gt;
  &lt;/UserControl.Resources&gt;
  </code></pre>