---
title: foreground
framework: swiftui
role: symbol
role_heading: Type Property
path: swiftui/graphicscontext/shading/foreground
---

# foreground

A shading instance that fills with the foreground style from the graphics context’s environment.

## Declaration

```swift
static var foreground: GraphicsContext.Shading { get }
```

## See Also

### Other shape styles

- [style(_:)](swiftui/graphicscontext/shading/style(_:).md)
