Hyphenation support #17
Replies: 6 comments 9 replies
-
|
Tried my hand at simple hyphenation engine, feedback is welcome - #47 |
Beta Was this translation helpful? Give feedback.
-
|
Nice. Looking at the screenshot, I am seeing that you end up with fragments of 3 characters. To my taste, I would increase that to 4 or 5 (making hyphenation only on fairly long words). |
Beta Was this translation helpful? Give feedback.
-
|
With my other e-readers, I usually use this Calibre plugin , which adds soft hyphens to books that don't already have them. |
Beta Was this translation helpful? Give feedback.
-
|
Made another attempt on Hyphenation, using rule dictionaries - #305 |
Beta Was this translation helpful? Give feedback.
-
|
#305 has been merged. Please provide feedback on the hyphenation feature. Also, do you think we need to support more languages (besides included English, German, French and Russian)? |
Beta Was this translation helpful? Give feedback.
-
|
Considering this one closed, future issues / feature requests around hyphenation can be made through Issues |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
To avoid big gaps in justified text, hyphenation of words would be beneficial (I would focus on words >7-9 char).
I assume existing hyphenation libraries (e.g. https://github.com/hunspell/hyphen, https://github.com/bramstein/hypher) are too heavy. They could, however, provide hyphenation rules (pattern files), which we could shorten (to the "top 1000"?).
In case we want to implement the algorithm from scratch (because existing implementations are too heavy): https://www.tug.org/docs/liang/
Hypher (https://github.com/typst/hypher) has an interesting approach to implement those patterns as FSM, which seems to be very efficient. We could use that project to generate FSMs, convert them into header or binary files and implement a small runtime to execute them (LLM may be able to do some/most of it).
Beta Was this translation helpful? Give feedback.
All reactions