-
-
Notifications
You must be signed in to change notification settings - Fork 977
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Paragraph justification sometimes doesn't use the full page width #5472
Comments
I suspect that this may be a duplicate of #5449 ? The issues seem very similar |
It's not a regression, so I doubt that. |
Probably the list (which is laid out as a grid) has shrink-to-fit semantics from the grid. |
But I don't know any field that does that, which means there is no workaround? Without completely rewriting the list show rule in Typst. |
In principle they are just auto columns, separate lists are separate grids so they aren't in the same column. The underlying problem has the same cause as the centering equations in lists issue (#529). However, what isn't clear is why justification isn't requesting the full width. Usually, the text would cause the list to resize to full width due to being too long. In either case, the fix would be similar as the other issue. You can try to add |
Nice! Adding |
I'm pretty sure the space there doesn't make much of a difference since what comes after it is also a space, but, if it's really necessary, you can write |
The width is determined as the maximum natural line width after line breaking. So it doesn't necessarily request the full width. |
That's unfortunate, since it'll lead to situations like this, where the margin is uneven Edit: As far as I can recall, this is not how justification works elsewhere |
It's only in blocks with shrink-to-fit behaviour. |
How do I know if a given block has that kind of behavior? See also #5479 |
All non-fixed-size blocks have that. |
Description
As soon as I insert
+ #lorem(24)
in the first list, they both become full-width:I cannot explain why would this ever happen. I never noticed this before, but apparently this behavior is the same for previous versions too. I guess I rarely have 2 lists on the same page.
By definition, the justification stretches the content to the full-width of the page. My only hunch is something to do with non-Latin/Unicode stuff.
Reproduction URL
No response
Operating system
Linux
Typst version
The text was updated successfully, but these errors were encountered: