Feature addition: text along path - #1136
Open
philocalyst wants to merge 4 commits into
Open
philocalyst wants to merge 4 commits into
philocalyst wants to merge 4 commits into
Conversation
Member
|
Thank you, this is a great addition! I will review the PR soon :). |
Author
|
Thank you! Going to go in and fix the CI in the meantime :) Aside: was hapily surprised how mostly readable the typst code is, this being the first time I tried to write something serious in it, but let me know if any sections are too hard to parse! |
Author
|
Okay hm it seems to fail on master too, so you know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #395
This PR adds rigid text and content placement along named/inline paths.
What changed
My notes on design
I heavily referenced Typst's existing approach of separating measurement form layout, reusing resolved content styles. The arc-length sampler uses adapative subdivision + Newton refinement, which mirrors the spirit of the work done in
Design notes within Typst PR #3847 (typst/typst#3847).
The layout code maintains opaque content rigid, avoiding pretending that independently shaped grapheme clusters can effectively preserve cross-place ligatures.
Now, on the note about FIXED, as of right now Typst doesn't have a general way of doing deeper text pathing manipulation. I looked into doing some WASM black magic, but hey, that's not really what the project is about! So instead I just got a PR up at Typst, which if/when merged will make that part very easy to add.