Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic volume break fails in some cases #15

Closed
egli opened this issue Nov 23, 2022 · 1 comment
Closed

Automatic volume break fails in some cases #15

egli opened this issue Nov 23, 2022 · 1 comment

Comments

@egli
Copy link
Member

egli commented Nov 23, 2022

Volume breaking is probably only based on text in <p> or <line> elements. Maybe though if they are inside<li> elements they might be ignored. In the example given most of the text is inside <li> elements.

The volume break for the given example is as follows:

  1. 168 S.
  2. 150 S.
  3. 183 S.
  4. 149 S.
  5. 314 S.

So the last volume has too many pages

See 10377.zip

@egli egli moved this from Todo to In Progress in Daisyproducer improvements Feb 17, 2023
@egli
Copy link
Member Author

egli commented Feb 21, 2023

The problem is that the given book contains a large amount of <li> elements. Those aren't used to calculate the total number of words in the book and they are also not used as split points.

The given book contains a sort of index at the end where there are no <p>s and hence no points where a split could happen.

If we'd allow <li> as split points we'd get the unfortunate side effect that volume breaks could happen in the middle of a list. This we certainly do not want. Maybe we should just increase the allowed_stretch factor when inside a list.

@egli egli moved this from In Progress to Todo in Daisyproducer improvements Mar 28, 2023
@egli egli moved this from Todo to In Progress in Daisyproducer improvements Mar 30, 2023
egli added a commit to daisy/pipeline1 that referenced this issue Apr 6, 2023
Count the words in <li> and <line> also. Then when moving to blocks
also use a list as a split point.

Should fix sbsdev/dtbook-to-latex#15
@egli egli moved this from In Progress to Deployed in Testing in Daisyproducer improvements Apr 6, 2023
@egli egli moved this from Deployed in Testing to Done in Daisyproducer improvements Apr 6, 2023
@egli egli moved this from Done to Deployed in Testing in Daisyproducer improvements Apr 6, 2023
@egli egli moved this from Deployed in Testing to In Progress in Daisyproducer improvements May 11, 2023
@egli egli moved this from In Progress to Deployed in Testing in Daisyproducer improvements May 16, 2023
@egli egli moved this from Deployed in Testing to Deployed in Production in Daisyproducer improvements Sep 25, 2023
@egli egli closed this as completed Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Deployed in Production
Development

No branches or pull requests

1 participant