05-22-2014, 02:49 PM | #1 |
Village idiot
Posts: 157
Karma: 519566
Join Date: Mar 2014
Location: Belgium
Device: sony PRS T-1
|
Position text bottom right corner
Hi all
Do any of you guys know how I can position a body of text in the bottom right corner of the page? I tried a <div> like this: Code:
.bottomright { position: absolute; bottom: 12pt; right: 0; } Any suggestions? |
05-22-2014, 03:10 PM | #2 |
Grand Sorcerer
Posts: 27,468
Karma: 192992430
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Bottom-right corner of what page? Unless it's a fixed-layout epub from beginning to end, there are no pages.
|
05-22-2014, 03:34 PM | #3 |
frumious Bandersnatch
Posts: 7,514
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Your best bet is forgetting about any king of vertical positiong (other than vertical margins/paddings)
|
05-22-2014, 03:45 PM | #4 |
Village idiot
Posts: 157
Karma: 519566
Join Date: Mar 2014
Location: Belgium
Device: sony PRS T-1
|
Right, thought as much. I'll leave it in the top right corner then :-)
|
05-22-2014, 05:06 PM | #5 |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
Why are you two misleading him? you can use that perfectly fine for all sorts of designs in a none fixed layout ePub!
use: Code:
position: absolute; bottom: 0; right: 0; |
05-22-2014, 05:54 PM | #6 |
Wizard
Posts: 1,528
Karma: 6613969
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Well, that could work in a web page but with ereader devices... Kindle for sure has big issues with absolute and relative positioning (read the Kindle Publishing Guidelines) and ADE doesn't manage well this kind of code neither.
|
05-22-2014, 06:02 PM | #7 |
Color me gone
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
|
If you are doing things for just your ipad, you can do anything you want. But if you want to do things other people can read, like on the many many many Kindles, then you have to make compromises.
|
05-22-2014, 06:09 PM | #8 | ||
Grand Sorcerer
Posts: 27,468
Karma: 192992430
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Quote:
http://www.idpf.org/epub/20/spec/OPS...htm#Section3.3 Quote:
|
||
05-23-2014, 02:11 AM | #9 |
Village idiot
Posts: 157
Karma: 519566
Join Date: Mar 2014
Location: Belgium
Device: sony PRS T-1
|
|
05-23-2014, 04:45 AM | #10 |
frumious Bandersnatch
Posts: 7,514
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
OK, maybe I didn't convey the message properly. I don't mean "it will never work", but rather something like: it's not possible to have a spec-compliant ePub 2.0.1 that's guaranteed to work in all spec-compliant readers, it may work in some readers, or even most, but i will most probably fail in unexpected ways in some other readers, and the reader will not be to blame.
That said, simply using "position: absolute" may be a good compromise solution, provided it fails gracefully when it fails. |
05-23-2014, 04:48 AM | #11 |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
Yeah, just wanted to get things straight.
JLius, the rules you posted were different to mine, that's why I thought you couldn't align it to where you wanted. |
05-23-2014, 05:22 AM | #12 |
Scripler Project Lead
Posts: 19
Karma: 19304
Join Date: May 2014
Location: Copenhagen, Denmark.
Device: Gameboy Color
|
Well a work-around I often use for vertical positioning is using margin-top. It only works of course when the element you want to positions is the only one on the html-page, like a dedication or similar. You can put css like this on the element.
Code:
margin-top:80%; |
05-23-2014, 05:38 AM | #13 | |
Village idiot
Posts: 157
Karma: 519566
Join Date: Mar 2014
Location: Belgium
Device: sony PRS T-1
|
Quote:
|
|
05-23-2014, 07:16 AM | #14 | |
frumious Bandersnatch
Posts: 7,514
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Quote:
So, for a 800x600 portrait screen, ignoring page margins, "margin: 80%" means 600*80/100 = 480 pixels, and in landscape orientation it means 800*80/100 = 640 pixels, which is more than the screen height, not a good idea if you ask me. |
|
05-23-2014, 07:38 AM | #15 |
Color me gone
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
|
You can make it look passable by using a much small amount. It moves things down the page some, to my eyes just enough to make it look like it is purposeful.
|
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[M92] "New" PDF Reader makes the bottom left corner menu slow | machinogodzilla | Onyx Boox | 0 | 05-08-2013 07:25 AM |
902 How to change text position after zoom? | bunny12 | PocketBook | 2 | 02-13-2012 02:42 PM |
Since 1.9.10, text slightly cut off on very bottom line | danskmacabre | Kobo Reader | 33 | 01-13-2012 05:25 AM |
Problem: positioning text to the bottom-right | JulienDym | ePub | 5 | 07-06-2011 09:03 AM |
Text aligned on the bottom of the page? | NASCARaddicted | ePub | 4 | 11-15-2010 01:14 PM |