title: Render numbers for tick on a WPF Slider using TextBox
body: <p>There have been several earlier questions related to adding number values to the ticks on a WPF <code>Slider</code> (e.g. <a href="https://stackoverflow.com/questions/4289322/wpf-silverlight-slider-control-display-tick-numbers">here</a> and <a href="https://stackoverflow.com/questions/20329916/wpf-how-to-set-a-dynamic-range-of-numbers-for-vertical-slider">here</a>). All proposed solutions I have found so far are to do with inheriting from the <code>TickBar</code> class and then using <code>DrawText(FormattedText text, Point point)</code> to draw the value. Something like:</p>
  
  <pre><code>protected override void OnRender(DrawingContext dc)
  {
     foreach(double tick in Ticks)
     {
        formattedText = new FormattedText(Convert.ToString(tick),
                                         CultureInfo.GetCultureInfo("en-us"),
                                         FlowDirection.LeftToRight,
                                         new Typeface("Verdana"), // I don't know why all examples use the Verdana font :P
                                         10, Brushes.Black);
        dc.DrawText(formattedText, ComputeTheRightPosition(tick));
     }
  }
  </code></pre>
  
  <p>While this is a valid solution, I am finding that it is not generic enough for me, due to the <code>FormattedText</code>. In my application, the <code>Style</code> can change at runtime, so I would prefer a way of putting all the numbers in a <code>TextBlock</code> or something, which can dynamically update its style and font and all. </p>
  
  <p>Is it possible to add text boxes in this way in an<code>Slider</code> or <code>TickBar</code> subclass?</p>