@react-18-pdf/textkit
v3.0.1
Published
An advanced text layout framework
Downloads
1,933
Readme
@react-18-pdf/textkit
Acknowledges
This project is a fork of textkit by @devongovett and continued under the scope of this project since it has react-pdf specific features. Any recongnition should go to him and the original project mantainers.
Layout process
- split into paragraphs
- get bidi runs and paragraph direction
- font substitution - map to resolved font runs
- script itemization
- font shaping - text to glyphs
- line breaking
- bidi reordering
- justification
- get a list of rectangles by intersecting path, line, and exclusion paths
- perform line breaking to get acceptable break points for each fragment
- ellipsize line if necessary
- bidi reordering
- justification