Quote:
Originally Posted by frabjous
Then the PDF used Georgia, not Droid, so the !important flag is not "cascading down" so-to-speak.
|
Yes, that's a consequence of how CSS works. To fully control the format of a (let's call it) "badly structured" book, one would need some knowledge of CSS rules and of the classes used in the document, etc. I don't see a way out of it, other than including a full-feature CSS parser/editor/creator, which, well, I'm absolutely not going to write
This does not mean it's not possible to override anything (and everything) in the book, just that it may be not so straightforward and "drag-and-drop" as wished. In this particular case I guess you could include in your default.css:
Code:
.mypararagraph { font-family: inherit !important; }
and rather than including it in the ~/epub2pdf/default.css, I'd copy it to the current directory, and delete it once the conversion is done.
Before adopting it, however, it would be desirable to discuss the name a bit. Maybe "pdf-style" is too broad, and something like "prince-style" would be better, since there might be other XHTML-to-PDF converters one could use.