diff options
| author | Max <me@mkor.je> | 2024-10-01 08:01:28 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-01 08:01:28 +0000 |
| commit | 8eee3ec8d1b4d960017cb558887bd6180cc99cea (patch) | |
| tree | 316835fb26b0302551a291699cc51c0a0025eecd /crates | |
| parent | 4ef1096ad99059fd86526ed819bf8a7abd3aef2b (diff) | |
Fix breakable block equation overflow (#5078)
Diffstat (limited to 'crates')
| -rw-r--r-- | crates/typst/src/math/equation.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/crates/typst/src/math/equation.rs b/crates/typst/src/math/equation.rs index bf5ef9dd..dfcb0f7b 100644 --- a/crates/typst/src/math/equation.rs +++ b/crates/typst/src/math/equation.rs @@ -322,10 +322,8 @@ fn layout_equation_block( .layout_into_run(&elem.body, styles)? .multiline_frame_builder(&ctx, styles); let width = full_equation_builder.size.x; - let can_break = - BlockElem::breakable_in(styles) && full_equation_builder.frames.len() > 1; - let equation_builders = if can_break { + let equation_builders = if BlockElem::breakable_in(styles) { let mut rows = full_equation_builder.frames.into_iter().peekable(); let mut equation_builders = vec![]; let mut last_first_pos = Point::zero(); |
