实现效果如下:
思路:
自定义控件中利用Path来设置动作。
步骤:
1、自定义控件MyImageControl
前端xaml:
<UserControl x:Class="MouseOverEffect.MyImageControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"