# Sandbox.Stroke.WithCap

```csharp
Stroke WithCap(LineCap cap)
```

Returns a copy with the specified caps at both ends of open paths and dash runs. Dots stay round.

### Parameters

- `cap` (`LineCap`)

### Returns

`Stroke`

Declared in [Sandbox.Stroke](/api/Sandbox.Stroke).
Assembly: `Sandbox.Engine`.
