Skip to content

Commit

Permalink
Merge pull request #3440 from MahApps/feature/GH-2784_DataTemplate_fo…
Browse files Browse the repository at this point in the history
…r_RangeSlider_AutoToolTip_Values

Add DataTemplates for range slider auto tool tip values
  • Loading branch information
punker76 authored Jan 27, 2019
2 parents ad1a977 + aaca6f2 commit 343dbfd
Show file tree
Hide file tree
Showing 2 changed files with 642 additions and 534 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,18 @@
Orientation="Horizontal"
SmallChange="1"
Style="{DynamicResource MahApps.Metro.Styles.RangeSlider.Win10}"
UpperValue="40" />
UpperValue="60">
<Controls:RangeSlider.AutoToolTipRangeValuesTemplate>
<DataTemplate DataType="Controls:RangeSliderAutoTooltipValues">
<UniformGrid Columns="2" Rows="2">
<TextBlock Text="From:" HorizontalAlignment="Right" />
<TextBlock Text="{Binding LowerValue, StringFormat='{}{0:N2}'}" HorizontalAlignment="Right" />
<TextBlock Text="To:" HorizontalAlignment="Right" />
<TextBlock Text="{Binding UpperValue, StringFormat='{}{0:N2}'}" HorizontalAlignment="Right" />
</UniformGrid>
</DataTemplate>
</Controls:RangeSlider.AutoToolTipRangeValuesTemplate>
</Controls:RangeSlider>
<Controls:RangeSlider Width="200"
Margin="4"
Controls:SliderHelper.EnableMouseWheel="MouseHover"
Expand Down
Loading

0 comments on commit 343dbfd

Please sign in to comment.