> For the complete documentation index, see [llms.txt](https://docs.overdare.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.overdare.com/development/api-reference/enums/aspecttype.md).

# AspectType

## Overview

AspectType is an Enum that defines how to maintain the aspect ratio of UI elements.

This is used in the AspectType property of UIAspectRatioConstraint and determines how UI elements scale to fit their parent or maximum size.

## Items

| Name                | Value | Description                                                                  |
| ------------------- | ----- | ---------------------------------------------------------------------------- |
| FitWithinMaxSize    | 0     | Fits content to the maximum allowed size while maintaining its aspect ratio. |
| ScaleWithParentSize | 1     | Scales content in proportion to its parent’s size changes.                   |

## See also

{% content-ref url="/pages/EScSNhQiHvJgf8GmuvoX" %}
[UIAspectRatioConstraint](/development/api-reference/classes/uiaspectratioconstraint.md)
{% endcontent-ref %}
