# CurvedTextStyle.WarpOffset

Artifact: [androidx.wear.compose:compose-foundation](https://developer.android.com/jetpack/androidx/releases/wear-compose) [View Source](https://cs.android.com/search?q=file:androidx/wear/compose/foundation/CurvedTextStyle.kt+class:androidx.wear.compose.foundation.CurvedTextStyle.WarpOffset) Added in [1.6.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.6.0)


```
value class CurvedTextStyle.WarpOffset
```

<br />

*** ** * ** ***

Used to specify if we want to warp the text, and if so, the offset for warping. Warping the text will cause each character to be modified in shape so that it is thinner when it is closer to the center of the screen and wider when it's further away. This also makes adjacent characters share a line, so this is particularly useful for cursive fonts. When warping is active, this parameter specifies which horizontal line of the text will keep its width.

## Summary

| ### Public companion properties |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Ascent()` Warp using the ascent of the text. |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Baseline()` Warp using the baseline of the text. |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Descent()` Warp using the descent of the text. |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#HalfAscent()` Warp using half the ascent of the text. |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#HalfOpticalHeight()` Warp using the middle point between ascent and descent of the text. |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#None()` Do not warp, use the standard Android rendering |
| `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Unspecified()` Unspecified, used for merging styles |

| ### Public functions |
|---|---|
| `inline https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#takeOrElse(kotlin.Function0)(block: () -> https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset)` If this `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#takeOrElse(kotlin.Function0)` is executed and its result is returned. |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#toString()()` |

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#isSpecified()` `false` when this is `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Unspecified()`. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#isUnspecified()` `true` when this is `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Unspecified()`. |

## Public companion properties

### Ascent

```
val Ascent: CurvedTextStyle.WarpOffset
```

Warp using the ascent of the text.

### Baseline

```
val Baseline: CurvedTextStyle.WarpOffset
```

Warp using the baseline of the text.

### Descent

```
val Descent: CurvedTextStyle.WarpOffset
```

Warp using the descent of the text.

### HalfAscent

```
val HalfAscent: CurvedTextStyle.WarpOffset
```

Warp using half the ascent of the text.

### HalfOpticalHeight

```
val HalfOpticalHeight: CurvedTextStyle.WarpOffset
```

Warp using the middle point between ascent and descent of the text. This is the default

### None

```
val None: CurvedTextStyle.WarpOffset
```

Do not warp, use the standard Android rendering

### Unspecified

```
val Unspecified: CurvedTextStyle.WarpOffset
```

Unspecified, used for merging styles

## Public functions

### takeOrElse

Added in [1.6.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.6.0)

```
inline fun takeOrElse(block: () -> CurvedTextStyle.WarpOffset): CurvedTextStyle.WarpOffset
```

If this `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#takeOrElse(kotlin.Function0)` is executed and its result is returned.

### toString

```
open fun toString(): String
```

## Public properties

### isSpecified

```
val isSpecified: Boolean
```

`false` when this is `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Unspecified()`.

### isUnspecified

```
val isUnspecified: Boolean
```

`true` when this is `https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/CurvedTextStyle.WarpOffset#Unspecified()`.