Morning!
Still working on a new ODT Test file with some more cases than my 'real text'. While doing I found some more problems:
1) A Picture that is anchored to a page will end up in the front of the document before any text, with a page number as positioning. If you have a lot of pictures in your document anchored to pages, all of them will be the first thing in the conversion. And there is no good way to find the real place in the document. This should also produce a warning so the user knows, or perhaps I should also remove those pictures?
2) ODT sets margins double... so I will find a style like this in the input:
.P-Text_20_body {
font-size: 12pt;
margin-left: 0;
margin-bottom: 0;
margin-top: 0;
margin-right: 0;
text-indent: 1.251cm;
font-family: FreeSerif, serif;
margin: 100%;
text-align: justify
}
which becomes in 'preprocessed' (debug mode):
.P-P3 {
display: block;
font-family: FreeSerif, serif;
font-size: 1em;
margin-bottom: 100%;
margin-top: 100%;
padding-bottom: 0;
padding-left: 0;
padding-right: 0;
padding-top: 0;
text-align: justify;
text-indent: 1.251cm
}
Naturally the convert should just drop this whole 'margin: 100%' line, because it is in addition the the right margins! I suspect this is some sort of proportional setting (like margins-left-right-top-bot are X, and use 100% of this).
I will introduce a fix for this on input level, because I suspect that inside the oeb.transform fixups it's already to late. Fix will be: if there are separate margins, drop the extra margin 100% (that makes no sense at all).
I'll post a note as soon as I committed something to my branch.
|