--- Comment #10 from Andreas L. Delmelle <> 2011-04-02 
15:32:20 EDT ---
Created an attachment (id=26842)
 --> (
Updated patch, eliminating some code duplication

Attached patch cleans up the previous one. Unrelated fixups in LineLM were
already committed to allow better focusing on the relevant changes. The changes
to test cases are also not included for the same reason. I will attach them as
a separate patch, for those who need it.

The loop duplication has been reduced as described:
- one additional removeLegalBreaks() method in ElementListUtils that just
accepts one parameter, namely the list to remove the breaks from
- remaining logic (i.e. determining the sublist that the breaks should be
removed from) stays in BlockLM

I was also looking at using the same method for the
fox:widow/orphan-content-limit case, and I bumped into the fact that
widows/orphans was implemented in reverse here. 
That is, removeLegalBreaksFromEnd() is called for orphan-content-limit, while
according to the spec, orphans tells you "the minimum number of lines of a
paragraph that must be left at the bottom of a page" or "the minimum number of
line-areas in the first area generated by the formatting object". So, it should
be exactly the other way around. Nobody ever noticed this... 8-)

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

Reply via email to