* Support calling KCL std KW fns, and move circle to KCL std
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Doc comments on parameters
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Update grammar
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Change use of counterClockWise to ccw
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add more tests for sweep sectional
* A snapshot a day keeps the bugs away! 📷🐛
* Add rust doc test for sectional
* A snapshot a day keeps the bugs away! 📷🐛
* Ran redo-kcl-stdlib-docs
* A snapshot a day keeps the bugs away! 📷🐛
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Automatic fixing of deprecations and use non-quoted default planes by default
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* transform a sketch
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* fix test
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* show we can revolve around paths
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* show we can revolve around paths
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛
* A snapshot a day keeps the bugs away! 📷🐛
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* bare minimum
* start of segment util added
* remove redundant handle
* some probably buggy handling of arc handles, can fix later
* probably bug implementation of update args, but data flow through is mostly there can fix bugs after
* fix update for arc
* fix math for center handle
* fix up length indicator
* tweak math
* stub out xState logic for arc
* more progress on adding point and click, implemented more of sketchLineHelper for arc
* small unrelated tweak
* fix up draft arc bugs
* fix arc last click
* fix draft segment animation and add comment
* add draft point snapping for arcs
* add helper stuff to arc
* clone arc point and click as base for arc-three-point
* rust change for arc three point
* can draw three point arc
* make arcTo editable
* can add new three point arc, so long as it continues existing profile
* get overlays working
* make snap to for continuing profile work for three point arcs
* add draft animation
* tangent issue fix
* action rename
* tmp test fix up
* fix silly bug
* fix couple problems causing tests to fail
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fix up
* add delet segment test for new segments
* update docs
* draft segments should look right
* add test for dragging new segment handles
* arc tools can be chained now
* make three point arc can start a new profile (not only extend existing paths)
* add test for equiping and unequiping the tool plus drawing with it
* fix console noise
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* clean up
* update rust/docs
* put toolbar mode check into fixture
* do thing for lee
* use TEST_COLORSs
* fix colors
* don't await file write
* remove commented code
* remove unneeded template strings
* power to **2
* remove magic numbers
* more string templates
* some odd bits of clean up
* arc should be enable in dev
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* add new simulation test
* fix test code from kwark migration
* issues Frank found
* fix deleting half complete ark
* fix
* small fix on dele index
* tsc post main merge
* fix up snaping to profile start
* add cross hari for three point arc
* block snapping if it's the only segment
* add tests for canceling arcTo halfway through
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Parse [T] instead of T[] for array types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* homogenous arrays, type coercion, remove solid set and sketch set, etc
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Make tag identifiers monotonic
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Use epochs rather than snapshots in memory
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Previously, `xLine`, `xLineTo`, `yLine` and `yLineTo` used positional arguments. Now:
- `xLineTo` and `yLineTo` have been removed
- `xLine` and `yLine` both use keyword arguments:
- `length`, optional (i.e. a relative distance along the X or Y axis)
- `endAbsolute` optional (i.e. an absolute point along the X or Y axis)
- `tag` optional
- Exactly one of `length` or `endAbsolute` must be given. Not both, not neither.
For example:
```
// Old way
|> xLine(6.04, %)
|> yLineTo(20, %, $base)
// New way
|> xLine(length = 6.04)
|> yLine(endAbsolute = 20, tag = $base)
```
This also improves some of the general-purpose keyword arguments code in modeling app's TS codebase.
* Make some things a little less public
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Rename KclValue::Array to MixedArray
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add settings to KclValue::Function
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Remove a bunch of dead code, simplifying mock exec and meaning KclValue no longer needs to deserialize
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Parse an unparse type decls (and refactor impl attributes slightly)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Remove special treatment of geometric types from parser and executor
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Generate docs for std types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Hover tool-tips for types and fixup the frontend
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fixes
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Show more info on hover for variables
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Move hover impls to lsp module
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Make hover work on names inside calls, fix doc line breaking, trim docs in tool tips
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Test the new hovers; fix signature syntax
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Hover tips for kwargs
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Type ascription
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Support negation of planes
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add default planes to std
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Don't double wrap docs files in const_
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Warn when calling deprecated std functions
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor function values
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Remove StandardPlane docs
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add a struct for encapsualting an f64 and a type
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Generalise and simplify offsetPlane
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add units to Paths
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add some NumericType combination functions
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fix docs/json/snippets generation from schemas
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Revert "Revert multi-profile (#4812)"
This reverts commit efe8089b08.
* fix poor 1000ms wait UX
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* trigger CI
* Add Rust side artifacts for startSketchOn face or plane (#4834)
* Add Rust side artifacts for startSketchOn face or plane
* move ast digging
---------
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* lint
* lint
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* trigger CI
* chore: disabled file watcher which prevents faster file write (#4835)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* partial fixes
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Fix up all the tests
* Fix partial execution
* wip
* WIP
* wip
* rust changes to make three point confrom to same as others since we're not ready with name params yet
* most of the fix for 3 point circle
* get overlays working for circle three point
* fmt
* fix types
* cargo fmt
* add face codef ref for walls and caps
* fix sketch on face after updates to rust side artifact graph
* some things needed for multi-profile tests
* bad attempts at fixing rust
* more
* more
* fix rust
* more rust fixes
* overlay fix
* remove duplicate test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* lint and typing
* maybe fix a unit test
* small thing
* fix circ dep
* fix unit test
* fix some tests
* fix sweep point-and-click test
* fix more tests and add a fix me
* fix more tests
* fix electron specific test
* tsc
* more test tweaks
* update docs
* commint snaps?
* is clippy happy now?
* clippy again
* test works now without me changing anything big-fixed-itself
* small bug
* make three point have cross hair to make it consistent with othe rtools
* fix up state diagram
* fmt
* add draft point for first click of three point circ
* 1 test for three point circle
* 2 test for three point circle
* clean up
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* remove bad doc comment
* remove test skip
* remove onboarding test changes
* Update src/lang/modifyAst.ts
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Update output from simulation tests
* Fix to use correct source ranges
This also reduces cloning.
* Change back to skipping face cap none and both
* Update output after changing back to skipping none and both
* Fix clippy warning
* fix profile start snap bug
* add path ids to cap
* fix going into edit sketch
* make other startSketchOn's work
* fix snapshot test
* explain function name
* Update src/lib/rectangleTool.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
* rename error
* remove file tree from diff
* Update src/clientSideScene/segments.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
* nit
* Prevent double write to KCL code on revolve
* Update output after adding cap-to-path graph edge
* Fix edit/select sketch-on-cap via feature tree
* clean up for face codeRef
* fix changing tools part way through circle/rect tools
* fix delete of circle profile
* fix close profiles
* fix closing profile bug (tangentArcTo being ignored)
* remove stale comment
* Delete paths associated with sketch when the sketch plane is deleted
* Add support for deleting sketches on caps (not walls)
* get delet working for walls
* make delet of extrusions work for multi profile
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Delete the sketch statement too on the cap and wall cases
* Don't write to file in `split-sketch-pipe-if-needed` unless necessary
* Don't wait for file write to complete within `updateEditorWithAstAndWriteToFile`
It is already debounced internally. If we await it, we will have to wait for a debounced timeout
* docs
* fix circ dep
* tsc
* fix selection enter sketch weirdness
* test fixes
* comment out and fixme for delete related tests
* add skip wins
* try and get last test to pass
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Kevin Nadro <nadr0@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: Frank Noirot <frankjohnson1993@gmail.com>
* KCL: Update patternTransform and 2d to use kwargs
* Update docs
* Convert segment functions to use keyword args
* Regenerate docs, change branch of kcl-samples
* refactor program memory for encapsulation and remove special treatment of return values
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor ProgramMemory to isolate mutation
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor ProgramMemory
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Generated output
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Cache the result of executing modules for their items
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Compress envs when popped
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Remove the last traces of geometry from the memory module
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* docs
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fixups
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Frontend
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Improve Environment GC
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fixup mock execution frontend and interpreter, misc bug fixes
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>