PgBiel / typst-tablex

More powerful and customizable tables in Typst
MIT License
370 stars 12 forks source link

doc(known-issues): Add caveat about layout/hyphenation of rotated text #60

Closed ja-he closed 1 year ago

ja-he commented 1 year ago

Per discussion in https://github.com/PgBiel/typst-tablex/issues/59.

I figured I could make myself useful by writing down what I tried to find before filing the issue.

Feel free to edit this or suggest edits as you prefer them or reject the PR, just my quick idea for a bit of doc.

ja-he commented 1 year ago

Sorry, realized that your box-suggestion was the way to go after all, so I wanted to add that as well. Feel free to squash the commits (or tell me to squash them) as you see fit.

PgBiel commented 1 year ago

Don't worry about the commits. :)

PgBiel commented 1 year ago

I think another possible workaround might be to use #place over the rotate so the text doesn't occupy any space at all, thus allowing for more flexibility. We could perhaps mention both approaches. (This should be tested first, though.)

PgBiel commented 1 year ago

Other than that, your text is pretty good. Thanks!

ja-he commented 1 year ago

I think another possible workaround might be to use #place over the rotate so the text doesn't occupy any space at all, thus allowing for more flexibility. We could perhaps mention both approaches. (This should be tested first, though.)

I got the result I wanted and also got with box and hyphenate:false via rowspanx(7, box(rotate(-90deg, [...]))) rowspanx(7, place(center + horizon, rotate(-90deg, [...]))) so I added that to the text. (edit: just realized I wrote cellx for some reason, don't think it matters for readability of the workaround)

Again, feel free to edit as you want.

PgBiel commented 1 year ago

Thank you! :D