# setAppearance()

> Live restyle (e.g.

Source: https://docs.tryyoursize.com/reference/flutter/set-appearance/

*Method* · `tryyoursize (Dart)`

Live restyle (e.g. when your app switches to dark theme).

```dart
Future<void> setAppearance(Appearance appearance)
```

## Parameters

- **`appearance`** (`Appearance`, required): The new appearance.

## Example

**Flutter**

```dart
await tys.setAppearance(const Appearance(colorPrimary: Color(0xFF3B2F26)));
```

**Swift**

```swift
tys.appearance.colorPrimary = TYSColor(hex: "#3b2f26") // an open window restyles at once
```

**Kotlin**

```kotlin
tys.appearance = tys.appearance.copy(colorPrimary = 0xFF3B2F26.toInt())
```

**React Native**

```tsx
setAppearance({ variables: { colorPrimary: "#3b2f26" } });
```
