conversion to mobi ignores vertical-align:top and superscript font size
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
calibre |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Doing some testing for Alexbell from this thread:
http://
I think I've discovered a bug in conversion of various types of superscript. vertical-align:top when combined with a font size/line height reduction is not included in the list of candidates to be considered a superscript. A lot of epub authors do this to eliminate problems with line height being made variable.
On top of that I was under the impression that if you used <sup>/<sub> tags that Calibre would just trust that the author/publisher actually intended for the tag to contain superscript. Instead it seems that the name of the tag is ignored and only css values are checked, as the resultant mobi file loses its <sup> tags.
Beyond that it seems that font size is ignored for superscript tags, they always seem to get <font size="2"> no matter what the user has actually specified for the font size.
I've got a candidate fix for the line height/
File is attached showing examples. All superscripts are lost except the ones which DO NOT have vertical align css.
> I've got a candidate fix for the line height/ vertical- align problem, but my branch is a mess so it will take me a bit to post.
You can always create another branch for this change and leave your normal branch alone. Check out trunk to another directory on your computer. Make the changes. Push them up to another branch.