* make everything in engine a rwlock and cleanup repetitive code Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * docs Signed-off-by: Jess Frazelle <github@jessfraz.com> --------- Signed-off-by: Jess Frazelle <github@jessfraz.com>
45 lines
76 KiB
Markdown
45 lines
76 KiB
Markdown
---
|
|
title: "angledLineToY"
|
|
excerpt: "Create a line segment from the current 2-dimensional sketch origin"
|
|
layout: manual
|
|
---
|
|
|
|
Create a line segment from the current 2-dimensional sketch origin
|
|
|
|
along some angle (in degrees) for some length, ending at the provided value in the 'y' dimension.
|
|
|
|
```js
|
|
angledLineToY(data: AngledLineToData, sketch: Sketch, tag?: TagDeclarator) -> Sketch
|
|
```
|
|
|
|
|
|
### Arguments
|
|
|
|
| Name | Type | Description | Required |
|
|
|----------|------|-------------|----------|
|
|
| `data` | [`AngledLineToData`](/docs/kcl/types/AngledLineToData) | Data to draw an angled line to a point. | Yes |
|
|
| `sketch` | [`Sketch`](/docs/kcl/types/Sketch) | A sketch is a collection of paths. | Yes |
|
|
| `tag` | [`TagDeclarator`](/docs/kcl/types#tag-declaration) | | No |
|
|
|
|
### Returns
|
|
|
|
[`Sketch`](/docs/kcl/types/Sketch) - A sketch is a collection of paths.
|
|
|
|
|
|
### Examples
|
|
|
|
```js
|
|
exampleSketch = startSketchOn('XZ')
|
|
|> startProfileAt([0, 0], %)
|
|
|> angledLineToY({ angle = 60, to = 20 }, %)
|
|
|> line(end = [-20, 0])
|
|
|> angledLineToY({ angle = 70, to = 10 }, %)
|
|
|> close()
|
|
|
|
example = extrude(exampleSketch, length = 10)
|
|
```
|
|
|
|

|
|
|
|
|