From c2cc09e71ab97f752cd07acad7c38443c58cf64f Mon Sep 17 00:00:00 2001 From: PgBiel <9021226+PgBiel@users.noreply.github.com> Date: Mon, 9 Dec 2024 06:55:58 -0300 Subject: Forbid footnote migration in pending floats (#5497) Co-authored-by: Laurenz --- .../ref/issue-5435-footnote-migration-in-floats.png | Bin 0 -> 448 bytes tests/suite/layout/flow/footnote.typ | 20 ++++++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 tests/ref/issue-5435-footnote-migration-in-floats.png (limited to 'tests') diff --git a/tests/ref/issue-5435-footnote-migration-in-floats.png b/tests/ref/issue-5435-footnote-migration-in-floats.png new file mode 100644 index 00000000..672a5af8 Binary files /dev/null and b/tests/ref/issue-5435-footnote-migration-in-floats.png differ diff --git a/tests/suite/layout/flow/footnote.typ b/tests/suite/layout/flow/footnote.typ index b549fbca..885ef627 100644 --- a/tests/suite/layout/flow/footnote.typ +++ b/tests/suite/layout/flow/footnote.typ @@ -295,3 +295,23 @@ A #footnote(numbering: "*")[B], C @fn, D @fn, E @fn. --- issue-5256-multiple-footnotes-in-footnote --- // Test whether all footnotes inside another footnote are listed. #footnote[#footnote[A]#footnote[B]#footnote[C]] + +--- issue-5435-footnote-migration-in-floats --- +// Test that a footnote should not prompt migration when in a float that was +// queued to the next page (due to the float being too large), even if the +// footnote does not fit, breaking the footnote invariant. +#set page(height: 50pt) + +#place( + top, + float: true, + { + v(100pt) + footnote[a] + } +) +#place( + top, + float: true, + footnote[b] +) -- cgit v1.2.3