modify manual RO preference…

in `return_boxes_of_images_by_order_of_reading_new`,
when the next multicol separator ends in the same column,
do not recurse into subspan if the next starts earlier
(but continue with top span to the right first)
This commit is contained in:
Robert Sachunsky 2026-02-05 17:58:32 +01:00
parent d047327a1f
commit 6944d31617

View file

@ -1881,7 +1881,10 @@ def return_boxes_of_images_by_order_of_reading_new(
y_mid[nxt]])
# dbg_plt(boxes[-1], "recursive column %d:%d box [%d]" % (column, last, len(boxes)))
column = last
if last == x_ending[nxt] and x_ending[nxt] <= x_ending[cur] and nxt in args:
if (last == x_ending[nxt] and
x_ending[nxt] <= x_ending[cur] and
x_starting[nxt] >= x_starting[cur] and
nxt in args):
# child recur
# print("recur", nxt, y_mid[nxt], "%d:%d" % (x_starting[nxt], x_ending[nxt]))
args.remove(nxt)