-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add rectangle from corner tool #1500
Comments
I should note that I'm also totally cool if a rectangle function gets added to stdlib and we just generate that. I'm not sure how we're planning on maintaining that "taggability" rule when calling stdlib functions though. |
I like the individual segments approach. However I think that the use of variables is not great, if we can follow the same pattern of other segments that is not constraining completely when its added (unless we're talking snapping logic) I think better code is |> startProfileAt([1, 3], %)
|> angledLine({ angle: 45, length: 13, tag: 'a' }, %)
|> angledLine({
angle: segAng('a', %) - 90,
length: 4,
tag: 'b'
}, %)
|> angledLine({
angle: segAng('a', %),
length: -segLen('a', %),
tag: 'c'
}, %)
|> close(%) Because it its still constrained as a rectangle, but not its editable dimensions, (angle, length height) Screenshare.-.2024-02-27.8_40_38.PM.mp4Though I think we need to get those constraint symbols in hey, because why the the segments are not editable isn't clear
Is fully constrained so that can't be edited. |
Sick I didn't know about the Yeah you're right we need those soon. I'll make an issue: I have a few details I want to discuss before we implement them. |
I've got a little baby branch started @Irev-Dev just with the icon, toolbar, and rough state machine setup. I'm not quite sure how to tweak things such that we can |
@Irev-Dev had a good idea for how to tweak |
Add a sketch tool that generates a rectangle for the user.
User flow
Code generation
I might be thinking about this wrong @Irev-Dev but I think we should still have these be line segments being generated, so that each of their edges are individually taggable. I would also recommend we stay away from using horizontal or vertical line definitions, as it would make the rectangle impossible to rotate or tweak later. I think the code generated should be a rectangle defined relative to itself:
Additional resources
An icon has been made and is available in Figma here.
The text was updated successfully, but these errors were encountered: