---
title: GraphicsContext.GradientOptions
framework: swiftui
role: symbol
role_heading: Structure
path: swiftui/graphicscontext/gradientoptions
---

# GraphicsContext.GradientOptions

Options that affect the rendering of color gradients.

## Declaration

```swift
@frozen struct GradientOptions
```

## Overview

Overview Use these options to affect how SwiftUI manages a gradient that you create for a GraphicsContext.Shading instance for use in a GraphicsContext.

## Topics

### Getting gradient options

- [linearColor](swiftui/graphicscontext/gradientoptions/linearcolor.md)
- [mirror](swiftui/graphicscontext/gradientoptions/mirror.md)
- [repeat](swiftui/graphicscontext/gradientoptions/repeat.md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Copyable](swift/copyable.md)
- [Equatable](swift/equatable.md)
- [ExpressibleByArrayLiteral](swift/expressiblebyarrayliteral.md)
- [OptionSet](swift/optionset.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)
- [SetAlgebra](swift/setalgebra.md)

## See Also

### Drawing a path

- [stroke(_:with:lineWidth:)](swiftui/graphicscontext/stroke(_:with:linewidth:).md)
- [stroke(_:with:style:)](swiftui/graphicscontext/stroke(_:with:style:).md)
- [fill(_:with:style:)](swiftui/graphicscontext/fill(_:with:style:).md)
- [GraphicsContext.Shading](swiftui/graphicscontext/shading.md)
