Advertisement
Guest User

Untitled

a guest
Apr 25th, 2019
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.64 KB | None | 0 0
  1. <ContentPresenter HorizontalAlignment="Stretch"
  2. VerticalAlignment="Stretch"
  3. UseLayoutRounding="True"
  4. Content="{Binding Icon}"
  5. Margin="0,0,3,0"
  6. Visibility="{Binding Icon,
  7. Converter={StaticResource NullToVisibilityConverter}}">
  8. <ContentPresenter.Resources>
  9. <DataTemplate DataType="{x:Type tui:IconViewModel}">
  10. <tuicc:IconContentControl Width="{Binding Width}"
  11. Height="{Binding Height}"
  12. Margin="{Binding Margin}"
  13. HorizontalAlignment="Center"
  14. VerticalAlignment="Center"
  15. IconContainer="{Binding IconContainer, Mode=OneTime}"
  16. IconKey="{Binding Key}"
  17. Stretch="{Binding Stretch}"
  18. StrokeThickness="{Binding Thickness}">
  19. <tuicc:IconContentControl.Foreground>
  20. <MultiBinding Converter="{StaticResource ColorToSolidColorBrushWithInversionOnMouseOverConverter}">
  21. <Binding Path="Foreground"/>
  22. <Binding Path="Hover" />
  23. <Binding Path="IsMouseOver" RelativeSource="{RelativeSource AncestorType={x:Type Button}}"/>
  24. </MultiBinding>
  25. </tuicc:IconContentControl.Foreground>
  26. </tuicc:IconContentControl>
  27. </DataTemplate>
  28. </ContentPresenter.Resources>
  29. </ContentPresenter>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement