diff options
| author | PgBiel <9021226+PgBiel@users.noreply.github.com> | 2025-05-21 00:52:44 -0300 |
|---|---|---|
| committer | PgBiel <9021226+PgBiel@users.noreply.github.com> | 2025-06-28 22:39:35 -0300 |
| commit | 3de1237f54d1d61f1d7a70f22c69aafae1d178b1 (patch) | |
| tree | 05530222feebf62ba10380f696a04b2295f9224d | |
| parent | b63f6c99df0f5d0b243e85f4b2982ac6b07b4de7 (diff) | |
temporary workaround for footer lines
| -rw-r--r-- | crates/typst-layout/src/grid/lines.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/crates/typst-layout/src/grid/lines.rs b/crates/typst-layout/src/grid/lines.rs index d5da7e26..973f0d21 100644 --- a/crates/typst-layout/src/grid/lines.rs +++ b/crates/typst-layout/src/grid/lines.rs @@ -512,15 +512,18 @@ pub fn hline_stroke_at_column( ); // Prioritize the footer's top stroke as well where applicable. + // TODO(subfooters): do this properly (store footer rows) let bottom_stroke_comes_from_footer = grid - .footer - .as_ref() + .footers + .last() .and_then(Repeatable::as_repeated) .is_some_and(|footer| { // Ensure the row below us is a repeated footer. // FIXME: Make this check more robust when footers at arbitrary // positions are added. - local_top_y.unwrap_or(0) + 1 < footer.start && y >= footer.start + footer.end == grid.rows.len() + && local_top_y.unwrap_or(0) + 1 < footer.start + && y >= footer.start }); let (prioritized_cell_stroke, deprioritized_cell_stroke) = |
