BackEase.Amplitude 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
public:
property double Amplitude { double get(); void set(double value); };
double Amplitude();
void Amplitude(double value);
public double Amplitude { get; set; }
var double = backEase.amplitude;
backEase.amplitude = double;
Public Property Amplitude As Double
<BackEase Amplitude="double" .../>
屬性值
Double
double
與 BackEase 動畫相關聯的撤銷幅度。 這個值必須大於或等於 0。 預設值是 1。
範例
下列範例會將 BackEase easing 函式套用至 DoubleAnimation ,以建立在動畫開頭和結尾稍微回溯的動畫。
<StackPanel x:Name="LayoutRoot" >
<StackPanel.Resources>
<Storyboard x:Name="myStoryboard">
<DoubleAnimation From="1" To="2" Duration="00:00:1"
Storyboard.TargetName="myScaleTransform"
Storyboard.TargetProperty="ScaleX">
<DoubleAnimation.EasingFunction>
<BackEase Amplitude="0.3" EasingMode="EaseInOut" />
</DoubleAnimation.EasingFunction>
</DoubleAnimation>
</Storyboard>
</StackPanel.Resources>
<Rectangle Margin="60" x:Name="myRectangle" PointerPressed="Pointer_Clicked"
Fill="Blue" Width="50" Height="50" >
<Rectangle.RenderTransform>
<ScaleTransform x:Name="myScaleTransform" />
</Rectangle.RenderTransform>
</Rectangle>
</StackPanel>
// When the user clicks the rectangle, the animation
// begins.
private void Pointer_Clicked(object sender, PointerRoutedEventArgs e)
{
myStoryboard.Begin();
}
' When the user clicks the rectangle, the animation
' begins.
Private Sub Pointer_Clicked(ByVal sender As Object, ByVal e As PointerRoutedEventArgs)
myStoryboard.Begin()
End Sub