# TransformOrigin

Artifact: [androidx.compose.ui:ui](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/graphics/TransformOrigin.kt+class:androidx.compose.ui.graphics.TransformOrigin) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.0.0) Common/AllAndroid/JVM
- Cmn

  ```
  value class TransformOrigin
  ```

*** ** * ** ***

A two-dimensional position represented as a fraction of the Layer's width and height

## Summary

| ### Public companion properties |
|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#Center()` `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin` constant to indicate that the center of the content should be used for rotation and scale transformations | Cmn |

| ### Public functions |
|---|---|---|
| `inline operator https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#component1()()` | Cmn |
| `inline operator https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#component2()()` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#copy(kotlin.Float,kotlin.Float)(pivotFractionX: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, pivotFractionY: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Returns a copy of this TransformOrigin instance optionally overriding the pivotFractionX or pivotFractionY parameter | Cmn |

| ### Public properties |
|---|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#pivotFractionX()` Return the position along the x-axis that should be used as the origin for rotation and scale transformations. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin#pivotFractionY()` Return the position along the y-axis that should be used as the origin for rotation and scale transformations. | Cmn |

## Public companion properties

### Center

Cmn Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.0.0)

```
val Center: TransformOrigin
```

`https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/TransformOrigin` constant to indicate that the center of the content should be used for rotation and scale transformations

## Public functions

### component1

Cmn Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.1.0)

```
inline operator fun component1(): Float
```

### component2

Cmn Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.1.0)

```
inline operator fun component2(): Float
```

### copy

Cmn Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.2.0)

```
fun copy(
    pivotFractionX: Float = this.pivotFractionX,
    pivotFractionY: Float = this.pivotFractionY
): TransformOrigin
```

Returns a copy of this TransformOrigin instance optionally overriding the pivotFractionX or pivotFractionY parameter

## Public properties

### pivotFractionX

Cmn Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.2.0)

```
val pivotFractionX: Float
```

Return the position along the x-axis that should be used as the origin for rotation and scale transformations. This is represented as a fraction of the width of the content. A value of 0.5f represents the midpoint between the left and right bounds of the content

### pivotFractionY

Cmn Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.2.0)

```
val pivotFractionY: Float
```

Return the position along the y-axis that should be used as the origin for rotation and scale transformations. This is represented as a fraction of the height of the content. A value of 0.5f represents the midpoint between the top and bottom bounds of the content