Make the function signature less prominent, add an early example to docs

Signed-off-by: Nick Cameron <nrc@ncameron.org>
This commit is contained in:
Nick Cameron
2025-06-19 17:08:46 +12:00
parent 6358eed7e4
commit ff1be99351
99 changed files with 2137 additions and 686 deletions

View File

@ -8,16 +8,20 @@ layout: manual
Draw a line relative to the current origin to a specified distance away from the current position along the 'x' axis.
```kcl
xLine(
@sketch: Sketch,
length?: number(Length),
endAbsolute?: number(Length),
tag?: TagDecl,
): Sketch
exampleSketch = startSketchOn(XZ)
|> startProfile(at = [0, 0])
|> xLine(length = 15)
|> angledLine(angle = 80deg, length = 15)
|> line(end = [8, -10])
|> xLine(length = 10)
|> angledLine(angle = 120deg, length = 30)
|> xLine(length = -15)
|> close()
example = extrude(exampleSketch, length = 10)
```
### Arguments
| Name | Type | Description | Required |
@ -32,6 +36,17 @@ xLine(
[`Sketch`](/docs/kcl-std/types/std-types-Sketch) - A sketch is a collection of paths.
### Function signature
```kcl
xLine(
@sketch: Sketch,
length?: number(Length),
endAbsolute?: number(Length),
tag?: TagDecl,
): Sketch
```
### Examples
```kcl