View Single Post
Old 06-18-2017, 02:40 AM   #1
Nabodita
Connoisseur
Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.Nabodita has never been to obedience school.
 
Nabodita's Avatar
 
Posts: 97
Karma: 44418
Join Date: Jul 2013
Location: Mostly in my own head!
Device: Kindle Fire, iPad
Positioning text vertically on a page

So, I was going through different threads in the forum and found a post about using divs to position text vertically on a page. It seemed like a simple solution and so excited was I that I didn't bother to read any further... off I went to try it out and wow, it really worked so well in ADE!

Unfortunately, iBooks appears to be disregarding those empty divs completely and I can't find that thread anymore.

All I was trying to do was create a title page... it doesn't get simpler than that.

Here's my title page:

Code:
<div id="topGap"></div>
<p id="bookTitle">Scaramouche</p>
<p id="bookAuthor">Rafael Sabatini</p>
...and here's my CSS:

Code:
div#topGap {
    margin: 0;
    padding: 0;
    height: 20%;
}

p#bookTitle {
    font-size: 2em;
    font-weight: bold;
    height: 10%;
}

p#bookAuthor {
    font-size: 1.6em;
    font-weight: bold;
}
I already know the answer to my question but I'm asking anyway. This code won't work on apple devices, am I right?

I know I can use margins or padding to do this but changing the font size throws off the positioning.
Nabodita is offline   Reply With Quote