Skip to content

added feature to snap at midpoint while using path tool - #3766

Open
krVatsal wants to merge 11 commits into
GraphiteEditor:masterfrom
krVatsal:shift-key-snaps-lines-from-middle-for-shpes
Open

added feature to snap at midpoint while using path tool#3766
krVatsal wants to merge 11 commits into
GraphiteEditor:masterfrom
krVatsal:shift-key-snaps-lines-from-middle-for-shpes

Conversation

@krVatsal

Copy link
Copy Markdown
Contributor

fixes #3760

Now when we use path tool to snap any shape(while holding shift) then it snaps from midpoint irrespective of wherever we drag from.

@krVatsal

krVatsal commented Feb 15, 2026

Copy link
Copy Markdown
Contributor Author

One small question, does the axes are meant to be at drag point or at the midpoint?

@Annonnymmousss

Copy link
Copy Markdown
Contributor

Midpoint of the segment.

@Keavon

Keavon commented Feb 16, 2026

Copy link
Copy Markdown
Member

!build

@github-actions

Copy link
Copy Markdown
📦 Build Complete for b3c30f4
https://63007abd.graphite.pages.dev

@Keavon

Keavon commented Feb 17, 2026

Copy link
Copy Markdown
Member

This is behaving correctly except for the fact that we want the X and Y snapping lines to be centered through the initial position of the midpoint of the Bezier segment being molded, rather than the point at which the pointer began dragging the molded segment.

@krVatsal

Copy link
Copy Markdown
Contributor Author

Yepp, was working on that part only. Almost done with the work I will push the new commit with that change.

@krVatsal
krVatsal marked this pull request as ready for review February 17, 2026 06:15
@Keavon
Keavon force-pushed the shift-key-snaps-lines-from-middle-for-shpes branch from d2413a4 to 183ab31 Compare February 23, 2026 05:59
@Keavon

Keavon commented Feb 23, 2026

Copy link
Copy Markdown
Member

!build (Run ID 22294708633)

@github-actions

Copy link
Copy Markdown
📦 Build Complete for 183ab31
https://f56d9453.graphite.pages.dev

@Keavon

Keavon commented Feb 24, 2026

Copy link
Copy Markdown
Member

The expected midpoint (t=0.5, where the X and Y axes should cross through) should be here, roughly where I marked it with the red dot:

image

@Keavon
Keavon marked this pull request as draft February 24, 2026 03:26
@krVatsal
krVatsal marked this pull request as ready for review February 24, 2026 22:02
@Keavon

Keavon commented Mar 3, 2026

Copy link
Copy Markdown
Member

!build (Run ID 22639891656)

@github-actions

github-actions Bot commented Mar 3, 2026

Copy link
Copy Markdown
📦 Build Complete for db0547b
https://6bacc445.graphite.pages.dev

Comment thread editor/src/messages/tool/tool_messages/path_tool.rs Outdated
Comment thread editor/src/messages/tool/tool_messages/path_tool.rs
@Keavon
Keavon force-pushed the master branch 2 times, most recently from 5bb6104 to 52d2b38 Compare March 9, 2026 23:35
@Keavon
Keavon force-pushed the master branch 5 times, most recently from e58c1de to df8001f Compare March 17, 2026 00:10
@Keavon
Keavon force-pushed the master branch 4 times, most recently from 9b97ab7 to 2e842cb Compare March 19, 2026 11:00
@Keavon
Keavon force-pushed the master branch 2 times, most recently from f07c79b to 76938eb Compare April 29, 2026 12:16
@Keavon
Keavon force-pushed the master branch 2 times, most recently from 4b7a823 to 847b8e9 Compare May 17, 2026 14:37
@timon-schelling
timon-schelling force-pushed the master branch 2 times, most recently from 15fcaac to d5f0140 Compare May 17, 2026 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Segment molding Shift key X/Y constraint

4 participants