Bagikan melalui


IAnimatedVisualSource2.SetColorProperty(String, Color) Metode

Definisi

Mengatur warna untuk visual animasi.

public:
 void SetColorProperty(Platform::String ^ propertyName, Color value);
void SetColorProperty(winrt::hstring const& propertyName, Color const& value);
public void SetColorProperty(string propertyName, Color value);
function setColorProperty(propertyName, 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 untuk propertyName.

Keterangan

File JSON untuk ikon animasi dihasilkan oleh LottieGen. Misalnya, jika Anda menentukan properti warna di animasi Lottie bernama Foreground, Anda dapat mengatur warna menggunakan AnimatedIcon.Foreground properti .

Berlaku untuk