08-16-2014, 07:21 PM | #16 |
Resident Curmudgeon
Posts: 73,976
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
08-17-2014, 12:44 AM | #17 | |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
Quote:
PHP Code:
Code:
.horizontal_center { width: 100%; text-align: center; } .image { width:60%; display:inline-block; } |
|
Advert | |
|
08-17-2014, 04:42 AM | #18 | |
frumious Bandersnatch
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Quote:
Code:
width: 68%; margin-left: 16%; margin-right: 16%; |
|
08-17-2014, 08:52 AM | #19 | |
Well trained by Cats
Posts: 29,801
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
Sorry, No such beast . Unlike the standards maintained by the NIST, the ones for EPUB are Jello. Then the device/program designers make more changes Compromise? (My stuff is for just my own use, so it is tuned for MY 5-6" e-Ink devices) Ignore the edge cases (Full/minimum Zoom, Tiny/Huge screen...)? (Brand) Optimized Versions? (One sizes does not fit all) |
|
08-17-2014, 11:21 AM | #20 | |
Chief Bohemian Misfit
Posts: 571
Karma: 462964
Join Date: May 2013
Device: iPad, ADE
|
I spent the whole morning (so far) re-doing my ornaments (in various sizes) this way (as you offered up here, odedta, as I've quoted below), testing it out on my computer in ADE and Sony Reader Library, and while it seemed to work fine in those, when I finally got around to transferring my epub over to the iPad and looked at it in iBooks, everything is TOTALLY outta wack -- the ornaments are all the wrong sizes. It seems that what's happening is that (to use your example, below) the image size of 60% is ignored, and instead they all go to the 100% defined in the paragraph style -- either that or it's just ignoring both and inserting the image as large as it can or something (but that would be weird).
Bummer, I really thought that I (i.e. you) had licked this problem. Quote:
|
|
Advert | |
|
08-17-2014, 01:42 PM | #21 | |
Wizard
Posts: 1,542
Karma: 6613969
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Quote:
Last edited by RbnJrg; 08-17-2014 at 01:45 PM. |
|
08-17-2014, 03:11 PM | #22 | |
Resident Curmudgeon
Posts: 73,976
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
08-17-2014, 03:44 PM | #23 |
Chief Bohemian Misfit
Posts: 571
Karma: 462964
Join Date: May 2013
Device: iPad, ADE
|
Okay, I seem to have solved some of my problems! But not one last one. :/ The book I'm working on is Thoreau's "Walden", by the way -- lots of weird table 'n' stuff in there, I'll tell ya. I've included the following screenshots here to illustrate the problem(s) I've been having with regard to these stupid ornaments...
"ornament-black.jpg" - the ornament I'm using (I've got a brown version of this for under the chapter headings, but it's the same image, size, etc.); "screenshot - header.jpg" - screenshot of the chapter headings, where the ornament displays just fine; "screenshot - paragraph.jpg" - screenshot of the ornament as a section break, where I finally managed to get it to display correctly (before I couldn't seem to get the top/bottom margins equal, but now I have); and "screenshot - poem.jpg" - screenshot showing the problem that I'm still struggling with. I've tested this all out in iBooks (on the iPad) and in ADE and Sony Reader Library (and Sigil) on my PC, and the chapter headings and the section breaks all look perfect! But I just can't seem to get that smaller/smallest version of the ornament to have equal top/bottom margins. I'm sure that I could if I used the same code to have it centered like I did with the section break, but because the poem(s) is/are smaller in size, I don't want it centered in the page -- that would look weird. I found that by having the image be 111px (or so) and about 6em over seems to look/work just fine for all the poems in the book, so that's what I've been trying to do... ...but I just can't get those stupid top/bottom margins to be equal. Here's the code that I finally figured out to use to get the section breaks to actually work/look okay (the code for the chapter headings is similar). In my HTML I have... Code:
<p class="ornimdpar"><img alt="[section break]" class="ornimd" src="../Images/ornament-black.jpg" /></p> Code:
.ornimdpar { width: 38%; margin-left:31%; text-align: center; } .ornimd { width:100%; margin-top:0.38em; margin-bottom:0.38em; display:inline-block; } Code:
<p class="poembreak"><img alt="[verse break]" src="../Images/ornament-black.jpg" /></p> Code:
p.poembreak { font-size: 76%; margin-left:111px; width:111px; margin-top: 0; margin-bottom: 0; line-height: 138%; text-align: left; } |
08-17-2014, 03:49 PM | #24 | |
Chief Bohemian Misfit
Posts: 571
Karma: 462964
Join Date: May 2013
Device: iPad, ADE
|
Quote:
The problems I've been having with this dumb ornament are really incredible, though -- it's hard to believe that to just insert a simple image as an ornament in-between a couple of paragraphs and have it come out okay would be SO problematic! Makes me long for the days when things were just HTML, before CSS even existed, and all you had to do was put <p align="center"> ...and TA-DA! |
|
08-17-2014, 04:29 PM | #25 | |
Resident Curmudgeon
Posts: 73,976
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
As for iBooks, sometimes you do have to make a version of the eBook just for iBooks and one for everything else. This is the way it is because iBooks is not standard in a lot of instances. Just ask Hitch if you want to see someone rant at iBooks and it's issues. Oh and don't forget, the 1st gen iPad with the older iBooks can work differently then the current version iBooks for all the other iPads. So you might want to get a 1st Gen iPad to also test on. |
|
08-17-2014, 05:30 PM | #26 | |
Bookmaker & Cat Slave
Posts: 11,462
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
I think he meant to tell you to make the image 100% of the p, and then size the p (div) accordingly. That's what we do with divs. We often wrap a p around an image and then wrap that in a div, depending upon circumstances. And, n.b.: what Wolfie told you is right: solutions that work on later iBooks won't work on first-gens (like the "oh, it's solved" problem of floating images at the top of a page having text run through them--cost me a client). Apple never bothered to fix it for first-gen iPads, along with a host of other issues. Also, when it comes to almost any added "flourishes," e.g., everything from dropcaps to incipits to you-name-it, you likely shall have to make a different book for iBooks versus other readers, because there is so much "workaround" crap you have to do. Hitch |
|
08-17-2014, 06:50 PM | #27 | |
Wizard
Posts: 1,542
Karma: 6613969
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Quote:
Regarding the divider in the poetry section, take in count that I assigned to the ".poetry" <div> a width of 40%. Of course, you can assign any width you wish. Also that <div> is not centered since it has a margin-left of 10% (of course, you can set here a margin-left in "ems" if you want). But in order that the dividers here are centered, you must set -for dividers- a margin-left according to their width. In this case, since I assigned a width of 30% to the ".poetry_divider" class, its margin-left must be equal to 35% (35% * 2 + 30% = 100%). Of course, you can change the values I used for margins top and bottom. Regards Rubén |
|
08-18-2014, 08:11 AM | #28 | |
Chief Bohemian Misfit
Posts: 571
Karma: 462964
Join Date: May 2013
Device: iPad, ADE
|
Thanks for the replies, everybody -- lots of food for thought! I have a busy day ahead of me away from home, so forgive me if I just quickly respond to something Rubén said...
Quote:
I do have to wonder, though, how practical that might be, re portrait vs. landscape orientation? Like, in your landscape screenshots, a margin of 40% would probably be okay, but in portrait many (if not most) of the lines would wrap -- and that would look funny, since people wouldn't understand why they were typoset (so to speak) like that. And in any case, if one is in portrait or landscape, then obviously the width of the screen changes, and then how the ornament is "centered" would change, too, and it might look funny where it ends up in one or the other (or both!). But that's certainly a thought! I have to run off today, but I'll play with that idea (tomorrow or whenever) and see if perhaps it does work out okay. Thanks, Rubén (and everyone)! |
|
08-18-2014, 11:08 AM | #29 |
Chief Bohemian Misfit
Posts: 571
Karma: 462964
Join Date: May 2013
Device: iPad, ADE
|
Okay! To heck with the stupid graphical ornament for the breaks in the poems. It's really weird that I was able to get the ornament in the section breaks in the main text to center vertically okay, but not in the poems, but at this point I give up, and decided to go with what one of the print editions of this book uses, which is a row of three asterisks. This looked nice, and served the purpose, but naturally one might think that there would still be the issue of the top/bottom margins of that row of asterisks not looking equal, because asterisks are inherently "superscript"-like characters, of course.
So all I did was make them subscript asterisks (and adjusted my CSS for <sub> accordingly! I know y'all will say that this is pretty wonky, but it WORKS! Looks virtually perfect in ADE, Sony Reader Library and on the iPad in iBooks. Here's the code that I ended up using in my HTML for that row of asterisks... Code:
<p class="poem"> <sub>*</sub> <sub>*</sub> <sub>*</sub></p> Code:
sub { font-size: 100%; line-height: 100%; vertical-align : -38%; } Anybody see any issues with doing it this way (as wonky as it is)? |
08-18-2014, 11:13 AM | #30 | |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
Quote:
I'm not sure about iPad 1 iBooks version though. (iOS 5.1.1) |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Share your favourite Holiday ornament or decoration | 5thWiggle | Lounge | 2 | 12-22-2013 12:40 PM |
PRS-650 What is 'ornament assy' ? | Witty Username | Sony Reader | 7 | 08-27-2011 05:43 PM |
Other Non-Fiction Holmes, William H.: Form and Ornament in Ceramic Art, v.1, 30 Dec 2008 | vivaldirules | IMP Books | 0 | 12-30-2008 08:47 AM |
Other Non-Fiction Holmes, William H.: Form and Ornament in Ceramic Art, v.1, 30 Dec 2008 | vivaldirules | Kindle Books | 0 | 12-30-2008 08:46 AM |
Other Non-Fiction Holmes, William H.: Form and Ornament in Ceramic Art, v.1, 30 Dec 2008 | vivaldirules | BBeB/LRF Books | 0 | 12-30-2008 08:45 AM |