---
title: "SwitchColors"
description: "Represents the content colors used in [Switch] in different states."
type: "interface"
---

<div class='type'>Interface</div>


<a id='references'></a>

<div class='sourceset sourceset-android'>Android</div>



```kotlin
public interface SwitchColors
```


Represents the content colors used in `Switch` in different states.


## Functions

```kotlin
@Composable public fun thumbColor(enabled: Boolean, checked: Boolean): State<Color>
```


Represents the thumb color for this `Switch`, depending on the `enabled` and `checked`
properties.

#### Parameters

| | |
| --- | --- |
| enabled | Whether the `Switch` is enabled |
| checked | Whether the `Switch` is currently checked or unchecked |



```kotlin
@Composable public fun trackColor(enabled: Boolean, checked: Boolean): State<Color>
```


Represents the track color for this `Switch`, depending on the `enabled` and `checked`
properties.

#### Parameters

| | |
| --- | --- |
| enabled | Whether the `Switch` is enabled |
| checked | Whether the `Switch` is currently checked or unchecked |




