# Sandbox.Painter.Outline

## Overload 1

```csharp
void Outline(Rect rect, float cornerRadius = 0, float offset = 0)
```

Draws an outline using [Sandbox.Painter.Stroke](/api/Sandbox.Painter/Stroke). At zero offset, its inner edge follows the rectangle.
Positive offsets push the outline outward; negative offsets pull it inward. All dimensions are in drawing pixels.

### Parameters

- `rect` (`Rect`)
- `cornerRadius` (`float`), default `0`
- `offset` (`float`), default `0`

## Overload 2

```csharp
void Outline(Rect rect, CornerRadii corners, float offset = 0)
```

Draws an outline using Stroke and elliptical corners. At zero offset, its inner edge follows the rectangle.
Positive offsets move it outward; negative offsets move it inward. Radii use the same clamping as Rect.

### Parameters

- `rect` (`Rect`)
- `corners` (`CornerRadii`)
- `offset` (`float`), default `0`

Declared in [Sandbox.Painter](/api/Sandbox.Painter).
Assembly: `Sandbox.Engine`.
