Quote:
Originally Posted by AlanHK
I was restyling an epub3 file and wanted to change the text alignment.
So just did
p{ text-align:justify;}
|
FWIW, you're not actually supposed to set this to justified for MOBI, either. Just a comment....
Quote:
Viewing the epub, it's justified.
Converted to AZW3 using Kindlegen, the text is left justified on my PW3.
Cannot be changed.
Hair-pulling ensues.
|
Not to be pedantic, but "left justified" doesn't actually exist. That's left-aligned or ragged-right. Justified has a single meaning--which is straight edges on both sides. I know, it's quibbling, but for the purposes of clarity, I thought I'd mention that.
A comment about software/typography/MS:
Quote:
I used the Calibre viewer on the AZW3 and its inspector shows me that
text-align: initial;
is having an effect.
I find that at the end of the css, in media queries:
Code:
@media amzn-kf8 {
body {
margin-left: 0.00em;
margin-right: 0.00em;
text-indent: 0.00em;
}
p { /*new requirements for device adjustable line spacing*/
text-align: initial;
}
So I can just delete this.
But why is it here?
The comment states it's necessary for linespacing, but I can adjust linespacing in Kindle regardless on any azw I have.
|
On which devices are you saying that you can adjust line-spacing? Do you mean
manually? Do you mean via coding? As far as I know, trying to
manually adjust line-height is pretty much only doable in K4PC/Mac and the newest K10 Fire. I certainly can't do that on any other device in our collection, which is fairly extensive, from PPWs to Voyages to Fires to iPads with K4iPad on them, and the aforementioned K10 (and of course, my much-loved ancient K2).
Quote:
What does "initial" mean anyway?
Where is the "initial justification" defined? Is it different for each device, reader?
Is this code actually useful in some situation? Seems to cause more trouble than it could solve.
|
As jhowell said, it's supposed to be what it sounds like--the initial, or default, coding for an element, prior to any changes via coding. It's for pretty much anything, not just alignment, AFAIK.
What's bizarre, though,
@jhowell, is, isn't initial
supposed to be overridable? Designed to be?
Not act as the override itself? Or am I wrong about that?
Hitch