# Paint.Align

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

# Align

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/graphics/Paint.Align "View this page in Java")  

```
class Align
```

|---|---|--------------------------------------------------------------------------------------------------------------|
| [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.graphics.Paint.Align](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#)\> ||
|   | ↳ | [android.graphics.Paint.Align](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#) |

|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Known Direct Subclasses [Paint.Align.CENTER](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:CENTER),[Paint.Align.LEFT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:LEFT),[Paint.Align.RIGHT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:RIGHT) |---------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------| | [Paint.Align.CENTER](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:CENTER) | The text is drawn centered horizontally on the x,y origin | | [Paint.Align.LEFT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:LEFT)     | The text is drawn to the right of the x,y origin          | | [Paint.Align.RIGHT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:RIGHT)   | The text is drawn to the left of the x,y origin           | |

Align specifies how drawText aligns its text relative to the \[x,y\] coordinates. The default is LEFT.

## Summary

|                                                                             Enum values                                                                              ||
|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|
| [CENTER](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:CENTER) The text is drawn centered horizontally on the x,y origin |
| [LEFT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:LEFT) The text is drawn to the right of the x,y origin              |
| [RIGHT](https://developer.android.com/reference/kotlin/android/graphics/Paint.Align#ENUM_VALUE:RIGHT) The text is drawn to the left of the x,y origin             |

## Enum values

### CENTER

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

```
enum val CENTER : Paint.Align
```

The text is drawn centered horizontally on the x,y origin  

### LEFT

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

```
enum val LEFT : Paint.Align
```

The text is drawn to the right of the x,y origin  

### RIGHT

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

```
enum val RIGHT : Paint.Align
```

The text is drawn to the left of the x,y origin