Quote:
Originally Posted by Hitch
You two are SO cute. ;-) 
Hitch
|
Should add a new smilie,
Hackers At Work, or something.
Quote:
Originally Posted by dgatwood
Very possible. Have you tried looking at the stylesheets inside the app?
Control-click on the app bundle and choose "Show Package Contents". Then go to Contents, PlugIns, then control-click on BKAssetEpub.bundle, choose "Show Package Contents", then Contents, Resources, and open the various .css.tmpl files.
|
Wow, thanks! I didn't even think of that.
...Interesting, looks like they use Handlebars to auto-generate portions of their CSS, based on what fonts are available, if the language is Japanese (vertical), etc.
Heh. Some of the stuff in here is gold:
Code:
.calibre > div, .calibre1 > div {
position: static !important;
}
...
/* fix documents that abuse inline-block */
...
/* centering hack to support Calibre-generated vertical centered documents */
...
/* Hide soundtrack <audio> tags from ever showing up */
/* display: none; doesn't seem to actually work for some reason, so hide it another way */
...
Interesting, the impact Calibre has had, even on the supposedly aloof citadels of Apple. Reminds me of a story I once read about graphics card driver programmers and game programmers, always writing code to try to compensate for one anothers' software. So you have the eBook conversion software and the eBook display software, and the developers writing code to compensate for each others' bugs and quirks.
Here's the CSS that hides the <aside> of your footnotes:
Code:
aside[epub|type~="footnote"] {
display: none !important;
}
Aha! I found the footnote itself:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ibooks="http://apple.com/ibooks/html-extensions">
<head>
<title>Footnote</title>
<style type="text/css">
@namespace ibooks "http://apple.com/ibooks/html-extensions";
body > div:first-child {
font-size: 200%%;
}
body > div:first-child[ibooks|footnoteTitleEnhance="on"] {
font-size: 300%%;
line-height: 0;
}
body > div:first-child[ibooks|footnoteTitleEnhance="on"] > span {
vertical-align: text-bottom;
}
</style>
</head>
<body>
<div><span><BKASIDETITLEGOESHERE/></span></div>
<div>
<BKASIDEHTMLGOESHERE/>
</div>
</body>
</html>
So, it looks like when the popover is generated, it is populated with this
footnote.xhtml file, which obviously doesn't pull in any of your CSS. I mean, unless they read your files for
<style> tags in your
<head> and pull those in--but per evidence to hand, they don't.
So yeah, looks like inlining stuff is the way to go here.
Note: This is OSX iBooks, so maybe iOS iBooks works differently, but I kinda doubt it.