# NumberFormatter.DecimalSeparatorDisplay

Added in[API level 30](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)

# DecimalSeparatorDisplay

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/icu/number/NumberFormatter.DecimalSeparatorDisplay "View this page in Java")  

```
class DecimalSeparatorDisplay
```

|---|---|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)                                                                                              |||
| ↳ | [kotlin.Enum](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html)\<[android.icu.number.NumberFormatter.DecimalSeparatorDisplay](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#)\> ||
|   | ↳ | [android.icu.number.NumberFormatter.DecimalSeparatorDisplay](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#) |

|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Known Direct Subclasses [NumberFormatter.DecimalSeparatorDisplay.ALWAYS](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:ALWAYS),[NumberFormatter.DecimalSeparatorDisplay.AUTO](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:AUTO) |-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------| | [NumberFormatter.DecimalSeparatorDisplay.ALWAYS](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:ALWAYS) | Always show the decimal separator, even if there are no digits to display after the separator.                             | | [NumberFormatter.DecimalSeparatorDisplay.AUTO](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:AUTO)     | Show the decimal separator when there are one or more digits to display after the separator, and do not show it otherwise. | |

An enum declaring how to render the decimal separator. Example outputs when formatting 1 and 1.1 in*en-US*:

- AUTO: "1" and "1.1"
- ALWAYS: "1." and "1.1"

<br />

## Summary

|                                                                                                                           Enum values                                                                                                                           ||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|
| [ALWAYS](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:ALWAYS) Always show the decimal separator, even if there are no digits to display after the separator.                         |
| [AUTO](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter.DecimalSeparatorDisplay#ENUM_VALUE:AUTO) Show the decimal separator when there are one or more digits to display after the separator, and do not show it otherwise. |

## Enum values

### ALWAYS

Added in[API level 30](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
enum val ALWAYS : NumberFormatter.DecimalSeparatorDisplay
```

Always show the decimal separator, even if there are no digits to display after the separator.  
**See Also**

- [android.icu.number.NumberFormatter](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter)  

### AUTO

Added in[API level 30](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
enum val AUTO : NumberFormatter.DecimalSeparatorDisplay
```

Show the decimal separator when there are one or more digits to display after the separator, and do not show it otherwise. This is the default behavior.  
**See Also**

- [android.icu.number.NumberFormatter](https://developer.android.com/reference/kotlin/android/icu/number/NumberFormatter)