---
id: "P:cAlgo.API.Shape.StrokeThickness"
kind: "property"
type: "T:cAlgo.API.Shape"
url: "https://help.ctrader.com/ctrader-algo/references/Controls/Layout/Shapes/Shape/StrokeThickness/"
---

> Documentation index for agents: https://help.ctrader.com/ctrader-algo/llms.txt · machine index: https://help.ctrader.com/ctrader-algo/api.json

# Shape.StrokeThickness

Member of [Shape](https://help.ctrader.com/ctrader-algo/references/Controls/Layout/Shapes/Shape/index.md).

## StrokeThickness

Gets or sets the stroke thickness.

Environments: Desktop supported · CLI not supported · Cloud not supported.

- CLI: Accepted without error but never displayed, so control events such as Click are never raised.
- Cloud: Accepted without error but never displayed, so control events such as Click are never raised.

C#:

```csharp
public double StrokeThickness {get; set;}
```

Python:

```python
shape.StrokeThickness: float
```

### Returns

`double` — 

### Examples

C#:

```csharp
var line = new Line { X1 = 0, Y1 = 0, X2 = 200, Y2 = 0, StrokeColor = Color.Yellow, StrokeThickness = 4 };
Chart.AddControl(line);
Print("Stroke thickness: {0}", line.StrokeThickness);
```

Python:

```python
line = Line()
line.X2 = 200
line.StrokeColor = Color.Yellow
line.StrokeThickness = 4
api.Chart.AddControl(line)
api.Print(f"Stroke thickness: {line.StrokeThickness}")
```

