From 3395fa96cacac99271019452711155074306a3ea Mon Sep 17 00:00:00 2001 From: Bert Frees Date: Wed, 9 Dec 2020 20:50:50 +0100 Subject: [PATCH] Remove EvenSizeVolumeSplitter code The reason is explained in issue https://github.com/mtmse/dotify.formatter.impl/issues/5. While an algorithm that favours solutions with more even volumes would be useful to have, EvenSizeVolumeSplitter (despite its name) does not actually accomplish this. Moreover, it has many problems, deteriorating the volume breaking more than improving it. Until we find a way to implement it properly, the whole feature is dropped. --- .../marker-ref/marker-ref-page-vol-input.obfl | 6 +- .../marker-ref-sequence-vol-input.obfl | 6 +- .../page/page-number8-input.obfl | 10 +- .../volume-breaks-advanced-expected.pef | 14 +- .../volume-breaks-advanced-input.obfl | 7 +- .../volume-breaks-advanced2-input.obfl | 4 +- .../volume-breaks-advanced3-input.obfl | 4 +- .../volume-breaks-advanced4-input.obfl | 4 +- .../volume-breaks-keep-next-input.obfl | 14 +- .../volume-breaks-priority-input.obfl | 7 +- .../volume-breaks-priority2-expected.pef | 28 +- .../volume-breaks-priority2-input.obfl | 20 +- .../dotify/formatter/impl/FormatterImpl.java | 2 +- .../dotify/formatter/impl/VolumeProvider.java | 47 ++-- .../impl/sheet/EvenSizeVolumeSplitter.java | 150 ---------- .../EvenSizeVolumeSplitterCalculator.java | 263 ------------------ .../formatter/impl/sheet/SheetGroup.java | 19 -- .../impl/sheet/SheetGroupManager.java | 99 +------ .../formatter/impl/sheet/VolumeSplitter.java | 36 --- .../EvenSizeVolumeSplitterCalculatorTest.java | 207 -------------- 20 files changed, 106 insertions(+), 841 deletions(-) delete mode 100644 src/org/daisy/dotify/formatter/impl/sheet/EvenSizeVolumeSplitter.java delete mode 100644 src/org/daisy/dotify/formatter/impl/sheet/EvenSizeVolumeSplitterCalculator.java delete mode 100644 src/org/daisy/dotify/formatter/impl/sheet/VolumeSplitter.java delete mode 100644 test/org/daisy/dotify/formatter/impl/sheet/EvenSizeVolumeSplitterCalculatorTest.java diff --git a/integrationtest/org/daisy/dotify/formatter/test/resource-files/marker-ref/marker-ref-page-vol-input.obfl b/integrationtest/org/daisy/dotify/formatter/test/resource-files/marker-ref/marker-ref-page-vol-input.obfl index 088bcec3..7dcba916 100644 --- a/integrationtest/org/daisy/dotify/formatter/test/resource-files/marker-ref/marker-ref-page-vol-input.obfl +++ b/integrationtest/org/daisy/dotify/formatter/test/resource-files/marker-ref/marker-ref-page-vol-input.obfl @@ -17,7 +17,7 @@