Quote:
Originally Posted by jackie_w
Would I be correct in thinking that you are using the 'Modify CSS' option in the KoboTouch/KoboTouchExtended drivers to add the following to the kobo_extra.css file?
|
Yes.
Quote:
If so, your main problem probably isn't that you've used 0 rather than 1 (although 1 is more correct, I think), it's that you've included those !important. I haven't figured out why the combo of !important and enabling 'Modify CSS' is so destructive, but it is. I first noticed it a few years ago. Since then I haven't allowed !important to remain in any of my epub css files and I don't use it in kobo_extra.css either. I haven't had a problem with standard epubs since.
|
!important and kobo_extra.css have nothing to do with one another with regard to being destructive or not. "!important" *is* destructive.
!important means: "Use these values, whatever comes after." A cascading stylesheet overwrites values of properties, so if you set "X" to 15 on an element, and then you set it to 20 on the same element (further down in the same stylesheet, or in one linked after the one that has "X" at 15), then the value will be 20. If you set "X" to "15 !important" however, the value will not be overwritten. The "!important" value will be the one used, independently of where it appears in the stylesheet. (Maybe it can be overwritten by a later defined, new "!important" on the same element; I don't know that.)
Quote:
For your extra info, you may not be aware that widows, orphans and @page statements are treated as special cases by the calibre drivers if you include new statements for them in kobo_extra.css. All existing widows/orphans/@page CSS code in your epubs will be completely removed before appending your new values. So !important wouldn't achieve anything anyway.
|
Oh, OK. If the driver removes all @pages and all existing widows/orphans properties everywhere, then indeed "!important" for that property wouldn't achieve anything.