Commit graph

734 commits

Author SHA1 Message Date
Keavon Chambers
33cb6fcb00 Remove usage of 'null' in favor of 'undefined' 2022-08-25 21:32:27 -07:00
Keavon Chambers
1e74ccb4f8 Enable some TS consistency lints 2022-08-25 19:00:23 -07:00
Keavon Chambers
881ad667d7 Prefix all type imports with the 'type' keyword where appropriate 2022-08-25 15:38:21 -07:00
Keavon Chambers
3a84de32ac Clean up MenuList types and fix many Vue and Clippy warnings
Also remove hard-coded-in-Vue Graphite logo in the menu bar in favor of a Rust definition.
2022-08-25 14:41:16 -07:00
Keavon Chambers
1a90a4db86 Clean up camelCase and snake_case in frontend code 2022-08-23 13:36:27 -07:00
Dennis
71f12db1e6 Impl DynNode 2022-08-22 17:18:26 +02:00
Keavon Chambers
f73836b838 Add grayscale sample image for its node graph test 2022-08-20 23:59:37 -07:00
0hypercube
fda275f231 Fix cargo-deny 2022-08-20 20:59:43 +01:00
Dennis
bdad7aca47 Make node trait consume self 2022-08-19 18:58:17 +02:00
Dennis
12b33da083 Implement image loding test 2022-08-13 19:15:48 +02:00
Dennis
8a0eb0e266 Add tests for op nodes 2022-08-13 18:21:46 +02:00
Dennis
b06e00ce61 Implement cons node 2022-08-13 14:54:12 +02:00
Dennis
7f415febed Add test for gray scale node
# Conflicts:
#	node-graph/gcore/src/raster.rs
2022-08-10 13:10:14 +02:00
Dennis
ef08c27e9c Reintroduce input for the node trait
# Conflicts:
#	node-graph/gcore/src/raster.rs
2022-08-10 13:05:57 +02:00
0HyperCube
b46bcc16ba Add point insertion to the Path tool (#754)
* Messaging cleanup

* Add bezier iter

* Add splitting

* Use bezier_rs bounding box

* Cleanup

* Fix comments

* Fix typo

* Code review tweaks

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2022-08-21 22:43:24 +01:00
0HyperCube
1bcf55939d Add path closing and segment extension to the Pen tool (#753)
* Close paths with pen tool

* Issue Z command always at end of path

* Small code review style changes

* Extending paths

* Fix mirror on extend path

* Code review tweaks

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2022-08-21 00:36:17 +01:00
Daniel Childs
09dace0147 Nudge selected artboard with arrow keys (#701) (#756) 2022-08-20 21:13:22 +01:00
Hannah Li
49c236fcc2 Divide the large Bezier-rs implementation file into smaller ones (#751)
* Refactor bezier lib file into a separate folder

* Add better implementation comments

* Update import of Subpath from bezier-rs

* Add comment to describe compare.rs

* Remove printlns and adjust spacing
2022-08-18 18:47:36 -04:00
0HyperCube
8effd6ecca Fix images and text again (#752)
* Images and text now work again

* Fix crash on load images
2022-08-18 13:40:34 +01:00
0HyperCube
4025815515 Fix a new non-infinite document getting a NaN zoom (#750) 2022-08-15 19:11:06 +01:00
Keavon Chambers
4412b983cd Move bezier-rs into libraries folder and deploy its interactive docs 2022-08-14 16:17:27 -07:00
Keavon Chambers
78a3644c45 Fix logic bug in key internationalization for A-Z keys in alternate layouts 2022-08-14 13:57:01 -07:00
Hannah Li
410b3d672c Add further Bezier library unit tests (#729)
* Initial tests

* Write unit tests for Bezier

Co-authored-by: Thomas Cheng <Androxium@users.noreply.github.com>
Co-authored-by: Rob Nadal <RobNadal@users.noreply.github.com>
Co-authored-by: Linda Zheng <linda-zheng@users.noreply.github.com>
Co-authored-by: Jackie Chen <jackiechen73@users.noreply.github.com>

* Write final tests and add PartialEq and Debug traits to Bezier

* Minor changes

* Identify missing tests and rename tests

* Add tests for rotate and translate

* Add tests for bounding box and inflection

* de casteljau point test

* curvature tests

* Add more sections to the rotate and translation tests

Co-authored-by: Thomas Cheng <Androxium@users.noreply.github.com>
Co-authored-by: Rob Nadal <RobNadal@users.noreply.github.com>
Co-authored-by: Linda Zheng <linda-zheng@users.noreply.github.com>
Co-authored-by: Jackie Chen <jackiechen73@users.noreply.github.com>
Co-authored-by: Jackie Chen <jackie.chen73@gmail.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
2022-08-14 16:56:43 -04:00
Keavon Chambers
863c17b86f Simplify platform-specific keyboard layouts with Accel key and global platform variable (#748)
* Simplify platform-specific keyboard layouts with Accel key and global platform variable


Co-authored-by: Dennis <dennis@kobert.dev>
2022-08-13 04:28:02 -07:00
Keavon Chambers
41bead9028 Rename MovementMessage to NavigationMessage 2022-08-11 17:20:10 -07:00
Keavon Chambers
9559ec58e8 Switch Vec<Key> to KeysGroup newtype 2022-08-11 16:35:04 -07:00
Keavon Chambers
47aaaf89d7 Fix shortcut label on welcome screen: "Control" -> "Ctrl" 2022-08-11 10:53:03 -07:00
Keavon Chambers
cf6bbcfd30 Revamp key/code input processing which fixes Option key on Mac and other locales
Closes #742
Closes #746
2022-08-11 02:53:46 -07:00
Keavon Chambers
765b648704 Extend welcome screen button click area to labels
Closes #738
2022-08-08 01:29:23 -07:00
Keavon Chambers
45a1e144a8 Populate menu bar
Closes #531
2022-08-06 03:17:25 -07:00
Thomas Cheng
b84e647f40 Implement arcs for Bezier math library (#731)
* added arcs impl

Co-authored-by: Hannah Li <hannahli2010@gmail.com>
Co-authored-by: Rob Nadal <RobNadal@users.noreply.github.com>

* fixed arc drawing,  todo - fix linear check

Co-authored-by: Hannah Li <hannahli2010@gmail.com>

* fixed linear bug + added comments and tests

Co-authored-by: Hannah Li <hannahli2010@gmail.com>

* added max iteration guard + made params optional  + added impl todo

* Add functionality to get arcs between extrema

* Add ArcsOptions to manage optional parameters of the arcs function

* added slider to toggle between arcs impl

Co-authored-by: Rob Nadal <RobNadal@users.noreply.github.com>

* Remove unused types

* address some comments

* added rustdoc for CircularArc struct

* Extract duplicate code into helper, remove loop labels, use window function

* Make JsValue handling consistent in WasmBezier and add comments for the underlying type

* Add enum for MaximizeArcs Auto/On/Off functionality

* Change Auto to Automatic

* fix errors from resolving merge conflict

* fixed error from resolving merge conflicts

* fixed formatting

* address comments

* Small fix

* Add some missing comments

* address comments

* rename variable

* Use unit to show maximize_arcs values

* Change i32 to usize and other minor adjustments

* Change computation for middle t values

* Remove tsconfig

* Fix more usize number handling

Co-authored-by: Hannah Li <hannahli2010@gmail.com>
Co-authored-by: Rob Nadal <RobNadal@users.noreply.github.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
2022-08-06 01:34:39 -04:00
luzpaz
0f88055573 Fix various typos (#745)
Found via `codespell -q 3 -L complies,crate,doubleclick,ist,ser,vew`
2022-08-05 23:57:52 -04:00
Dennis
1ed7562b90 Add raster module to graphene_core 2022-08-04 12:34:05 +02:00
Keavon Chambers
9e34199ca9 Additional cleanup of prelude imports in editor codebase
Closes #744
2022-08-05 17:09:37 -07:00
Keavon Chambers
e4306c30e2 Restructure the entire editor codebase to consistently match the message hierarchy
Closes #744
2022-08-05 05:38:11 -07:00
Dennis
78f07439db Add license information for node_graph crates 2022-08-04 11:47:38 +02:00
Keavon Chambers
0c2dbd411b Fix formatting of previous commit 2022-08-04 00:18:42 -07:00
Dennis
d09f023618 Bump dyn-any version + format code 2022-08-04 09:08:48 +02:00
Dennis
c44e9d22e3 Integrate dyn-any into the main graphite repo 2022-08-04 08:52:24 +02:00
Keavon Chambers
f39d6bf00c Add full support for Mac-specific keyboard layouts (#736)
* IPP for Mac, flawed initial experiments

* Cleanup and progress, but not compiling yet

* Fix error and rename nonmac -> standard

* Extentd ipp macros to accomodate mac input

* Add Mac versions of shortcuts; refactor and document the input mapper macros

* Change frontend styling for user input labels in floating menus

* Additional macro documentation

* A little more documentation

* Improve entry macro syntax

* Move input mapper macros to a separate file

* Adapt the keyboard shortcuts to the user's OS

* Display keyboard shortcuts in the menu bar based on OS

* Change Input Mapper macro syntax from {} to ()

* Fix esc key bug in Vue

* Tweaks

* Interim solution for Mac-specific hints

* Feed tooltip input hotkeys from their actions

* Fix hotkeys for tools because of missing actions

* Make Vue respect Ctrl/Cmd differences per platform

* Remove commented lines

* Code review pass by me

* Code review suggestions with TrueDoctor

* Turn FutureKeyMapping struct into ActionKeys enum which is a bit cleaner

* Add serde derive attributes for message discriminants

* Re-add serde deserialize

* Fix not mutating ActionKeys conversion; remove custom serializer

* Add serde to dev dependencies

Co-authored-by: Dennis <dennis@kobert.dev>
2022-08-03 14:12:28 -07:00
Dennis
fa461f3157 Temporarily remove pretty printing for token streams 2022-08-02 11:53:35 +02:00
Dennis
20f4271e91 Add dyn-any as a submodule 2022-08-02 11:52:08 +02:00
Dennis
e84b9bd5bd Compile node graph description to GPU code 2022-06-08 09:52:58 +02:00
Dennis
998f37d1b0 Add Unit and Id nodes to node graph 2022-06-05 22:58:12 +02:00
Dennis
a2703c0fb1 Don't force nodes to store references to other nodes 2022-06-05 15:25:07 +02:00
Dennis
fa5345d33f Remove input from the node definition 2022-06-05 01:15:22 +02:00
Dennis
f6e4dbf3e3 Add GPU support for node graph 2022-04-24 11:58:31 +02:00
Dennis
49c171b419 Implement borrow stack for node graph 2022-04-22 19:58:13 +02:00
Dennis
09deee0c4d Make graphene_core no_std 2022-04-22 15:15:39 +02:00
Dennis
90e465b35c Restructure node graph proxy architecture 2022-04-03 19:25:07 +02:00