---
title: "CornerSize"
description: "Defines size of a corner in pixels. For example for rounded shape it can be a corner radius."
type: "interface"
---

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


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

<div class='sourceset sourceset-common'>Common</div>



```kotlin
interface CornerSize
```


Defines size of a corner in pixels. For example for rounded shape it can be a corner radius.


## Functions

```kotlin
fun toPx(shapeSize: Size, density: Density): Float
```


Converts the `CornerSize` to pixels.

#### Parameters

| | |
| --- | --- |
| shapeSize | the size of the shape |
| density | the current density of the screen. |


#### Returns

| | |
| --- | --- |
|  | resolved size of the corner in pixels |




