Bagikan melalui


AnimatedChevronDownSmallVisualSource.SetColorProperty(String, Color) Metode

Definisi

Mengatur warna visual animasi untuk AnimatedIcon.

Dokumentasi ini berlaku untuk WinUI 2 untuk UWP (untuk WinUI di SDK Aplikasi Windows, lihat namespace SDK Aplikasi Windows).

public:
 virtual void SetColorProperty(Platform::String ^ propertyName, Color value) = SetColorProperty;
void SetColorProperty(winrt::hstring const& propertyName, Color const& value);
public void SetColorProperty(string propertyName, Color value);
Public Sub SetColorProperty (propertyName As String, value As Color)

Parameter

propertyName
String

Platform::String

winrt::hstring

Nama properti warna seperti yang didefinisikan dalam file JSON untuk ikon animasi.

value
Color

Nilai warna ikon animasi sedang diatur ke.

Penerapan

M:Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2.SetColorProperty(System.String,Windows.UI.Color) M:Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2.SetColorProperty(Platform::String,Windows.UI.Color) M:Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2.SetColorProperty(winrt::hstring,Windows.UI.Color)

Keterangan

Nama properti warna didefinisikan dalam file JSON yang dihasilkan oleh LottieGen untuk ikon animasi. Misalnya, jika Anda menentukan properti warna di animasi Lottie bernama Foreground, Anda dapat mengatur warna menggunakan AnimatedIcon.Foreground properti .

Berlaku untuk

Lihat juga