Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 05-08-2015, 04:08 PM   #16
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
Quote:
Originally Posted by rubeus View Post
  is not supported by my PRS 650 even if i have fonts in the ebook. Sigil is not trust worthy here, cause it uses QT5 which will render and allow much more as declared in the epub Standard, e.g. Sigil will follow all pseudo-classes, but no epub2 reader will follow this style.
Although this is true for pseudo-classes and other elements, it is not true for  . That is perfectly valid in ePUB2 and should be supported. It is the PRS-650 that is not trustworthy here... That it is not supported, is an issue with the ADE engine on the reader since you already ruled out the font.
Toxaris is offline   Reply With Quote
Old 05-08-2015, 04:29 PM   #17
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by Notjohn View Post
Speaking of em spaces, I am reading The Far Side of Paradise, Mizener's wonderful biography of F. Scott Fitzgerald. It was published in the 1950s, I think. I was astonished to see a double-wide space following every sentence, much as we were taught in typing class at Brewster Free Academy (using Army-surplus Remington manual typewriters). I have never before seen such a thing in a published book. What was Houghton Mifflin thinking?

I apologize for hijacking the thread, but to me this is a momentous discovery (despite the fact that I'd read the book years ago) and I just had to tell someone!
I would recommend reading this article:

http://www.heracliteanriver.com/?p=324

I will quote myself from a thread from last year:

Quote:
Originally Posted by Tex2002ans View Post
Side Note: This reminds me of this fascinating article, "Why two spaces after a period isn’t wrong (or, the lies typographers tell about history)". The author goes through even these older Style Guides themselves (like new/older versions of the Chicago Manual of Style) and demolishes this "double-spacing" myth! I assume something similar could be said about ellipses
It was a thread that was necroed, and then we had a nice long semi-related side chat about spacing and other typographical decisions in ebooks:

https://www.mobileread.com/forums/sho...=206482&page=2

Quote:
Originally Posted by Toxaris View Post
Although this is true for pseudo-classes and other elements, it is not true for  . That is perfectly valid in ePUB2 and should be supported. It is the PRS-650 that is not trustworthy here... That it is not supported, is an issue with the ADE engine on the reader since you already ruled out the font.
If I remember correctly with my Nook, some of these rarer spaces do not work very well at all (appears as a blank box). I haven't tested the spaces in a very long time though.

I would just stick with nbsp; in many of these cases in ebooks for maximum compatibility. (Again, see that topic linked above, we had a huge discussion about it).

For example, in French, the thin space is used all over the place before/after punctuation, but it is perfectly valid to substitute a non-breaking space when writing French in HTML.

Also, is the thin space actually in the Georgia font? Everything I am looking at says that it doesn't contain it:

http://www.fileformat.info/info/unic...al_punctuation
http://www.htmlescape.net/20/charact...pace_2009.html

Times New Roman is also missing a ton of Unicode, but it does look to have support for some of these rarer spaces:

http://www.fileformat.info/info/unic...al_punctuation

Last edited by Tex2002ans; 05-08-2015 at 04:50 PM.
Tex2002ans is offline   Reply With Quote
Old 05-08-2015, 07:51 PM   #18
Notjohn
mostly an observer
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 1,519
Karma: 987654
Join Date: Dec 2012
Device: Kindle
Quote:
Originally Posted by Tex2002ans View Post
I would recommend reading this article:
http://www.heracliteanriver.com/?p=324
The reason The Far Side of Paradise astounded me is that I have read three or four thousand books in my lifetime so far, from scores of publishers in half a dozen countries. and nowhere else I have I seen double-width spacing following a full stop.

Fortunately html makes it very difficult for the uninitiated to make this (to me egregious) error.
Notjohn is offline   Reply With Quote
Old 05-08-2015, 08:52 PM   #19
DaleDe
Grand Sorcerer
DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.
 
DaleDe's Avatar
 
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
It may be that the entity reference name is not supported by the reader. Perhaps coding it by number would work.

A work around is to use regular spaces but change the font size.

Dale
DaleDe is offline   Reply With Quote
Old 05-08-2015, 09:56 PM   #20
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Tex2002ans View Post
Also, is the thin space actually in the Georgia font? Everything I am looking at says that it doesn't contain it:
So what? Like TABs, they can be synthesized in the context.
If I open the HTML in Firefox, it displays the correct spacing with text in Georgia.

If text is being justified, for instance as it usually is, then spaces are already being scaled to arbitrary widths.
AlanHK is offline   Reply With Quote
Old 05-08-2015, 10:14 PM   #21
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Notjohn View Post
The reason The Far Side of Paradise astounded me is that I have read three or four thousand books in my lifetime so far, from scores of publishers in half a dozen countries. and nowhere else I have I seen double-width spacing following a full stop.
Read some books printed before 1920 and most of them have that.
E.g, browse some books at the Hathi Trust, which has lots of old public domain books online.
This one from 1913: Adnam's orchard.
AlanHK is offline   Reply With Quote
Old 05-08-2015, 10:16 PM   #22
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by DaleDe View Post
It may be that the entity reference name is not supported by the reader. Perhaps coding it by number would work.
No, tried that, and also converting to UTF8 characters. Still boxes.

Quote:
Originally Posted by DaleDe View Post
A work around is to use regular spaces but change the font size.
Yes.
AlanHK is offline   Reply With Quote
Old 05-08-2015, 11:10 PM   #23
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by AlanHK View Post
Maybe I could use "letter-spacing".

So these look the same to me when they both work:

Code:
 <p>“&thinsp;‘Honeymoon Bridge’ </p>

 <p><span style="letter-spacing:0.166em">“</span>‘Honeymoon Bridge’ </p>
And the latter seems to be compatible with everything.
(Typographic definition of "thin space" is 1/5 or 1/6em.)

This hack is actually more like the kerning that I do in printing fonts, except the latter I can just do in the font and forget it.

Also found this table of all 20 Unicode spaces:
https://www.cs.tut.fi/~jkorpela/chars/spaces.html


Sorry for the run of replies. I'm obviously out of sync with most here, Timezone GMT + 8

Last edited by AlanHK; 05-08-2015 at 11:26 PM.
AlanHK is offline   Reply With Quote
Old 05-09-2015, 02:48 AM   #24
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,550
Karma: 19500001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Quote:
Originally Posted by AlanHK View Post
So these look the same to me when they both work:

Code:
 <p>“&thinsp;‘Honeymoon Bridge’ </p>

 <p><span style="letter-spacing:0.166em">“</span>‘Honeymoon Bridge’ </p>
And the latter seems to be compatible with everything.
(Typographic definition of "thin space" is 1/5 or 1/6em.)
Shouldn't both quote marks be in the span?:

Code:
<p><span style="letter-spacing:0.166em">“‘</span>Honeymoon Bridge’</p>
If the renderer is adding spacing outside the span, it's doing it wrong according to the CSS3 draft: "It is incorrect to include the letter spacing on the right or trailing edge of the element"
Jellby is offline   Reply With Quote
Old 05-09-2015, 03:42 AM   #25
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Jellby View Post
Shouldn't both quote marks be in the span?:
Tried that, it put the extra space after both quotes.

Looks like:
“ ‘ Honeymoon Bridge’

Same result in Firefox.

Your ref says "Letter-spacing must not be applied at the beginning or at the end of a line.
Line, not "element".

Seems that whatever the standard says, in practice it's "space after each character", not "between affected characters".

Last edited by AlanHK; 05-09-2015 at 04:03 AM.
AlanHK is offline   Reply With Quote
Old 05-09-2015, 06:39 AM   #26
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,550
Karma: 19500001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Quote:
Originally Posted by AlanHK View Post
Your ref says "Letter-spacing must not be applied at the beginning or at the end of a line.
Line, not "element".
I copy-pasted, so my quote is literal. Scroll down, in the "example 15" box there's the fragment in question, showing "a b b c" in red.

Quote:
Seems that whatever the standard says, in practice it's "space after each character", not "between affected characters".
Buggy, non-compliant implementations, changing standard... The truth is you cannot rely on it being done one way or the other, so I'd recommend not to use it. And anyway, "letter-spacing" is not part of the ePub 2 standard.
Jellby is offline   Reply With Quote
Old 05-09-2015, 07:57 AM   #27
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 74,001
Karma: 315160596
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Oasis
Try this:

HTML:

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<link rel="stylesheet" type="text/css" href="../Styles/Style0001.css" />
</head>

<body>
<p><span class="spaceafter">“</span>‘some test text’<span class="spacebefore">”</span></p>
</body>
</html>



CSS:

span.spaceafter {
margin-right: 0.1em;
}

span.spacebefore {
margin-left: 0.1em;
}
pdurrant is offline   Reply With Quote
Old 05-09-2015, 10:14 AM   #28
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,252
Karma: 16544692
Join Date: Sep 2009
Location: UK
Device: ClaraHD, Forma, Libra2, Clara2E, LibraCol, PBTouchHD3
The complex workarounds discussed in this thread have me totally baffled

I created a simple test epub containing the various special space characters - no fancy formatting - and have no problem at all viewing them in the calibre Viewer nor on my Kobo. I tried various fonts (including Georgia and Times New Roman) in both apps and did not see the reported 'black boxes' with any of them.

I did use the calibre Editor, not Sigil, to create the epub so all named entities have been translated to the relevant unicode characters. Perhaps this is why I have no problems.

Here's a screenshot of the calibre Viewer using both Georgia and Times New Roman. I could post the test epub if anyone's interested.
N.B. All paragraphs are left-aligned so there's no space-adjusting involved.
Attached Thumbnails
Click image for larger version

Name:	spaces.jpg
Views:	248
Size:	62.8 KB
ID:	138103  
jackie_w is offline   Reply With Quote
Old 05-09-2015, 01:27 PM   #29
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by jackie_w View Post
I created a simple test epub containing the various special space characters - no fancy formatting - and have no problem at all viewing them in the calibre Viewer
As I mentioned, I'm using an older version of Calibre, based on Qt4, as I run XP, and the newer version of Calibre (with Qt5) won't install. It's this version which fails to show most of the spaces, as I reported.

However, there is a build of the latest Sigil for XP, which I do most of my work on, and they all work on that.

So, support for these characters is not guaranteed.
AlanHK is offline   Reply With Quote
Old 05-09-2015, 01:37 PM   #30
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Jellby View Post
I copy-pasted, so my quote is literal. Scroll down, in the "example 15" box there's the fragment in question, showing "a b b c" in red.
OK. But you must admit even if it's not self-contradictory, it's not clear.


Quote:
Originally Posted by Jellby View Post
IBuggy, non-compliant implementations, changing standard... The truth is you cannot rely on it being done one way or the other, so I'd recommend not to use it. And anyway, "letter-spacing" is not part of the ePub 2 standard.
It seems where letter spacing is recognised at all, it always works to space after.
I haven't found any that space between.

But sadly, FBreader on Android doesn't do letter-spacing at all.

Anyway, next up , I'll try margins and see if that's more compatible.
AlanHK is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ePub CSS @fontface Unicode chars render in <td>, not in <div>, other elements Abelinkin ePub 2 06-05-2012 04:24 AM
Junk chars in splitted file names converting lit to epub ozofmoz Conversion 2 07-15-2011 02:53 AM
PDF->epub: double l chars changed bobkoure Conversion 1 05-02-2011 10:05 PM
0.7.44 Problem with national chars while converting to epub AdamV Conversion 5 02-08-2011 08:01 PM
Replacing Chars in URL DAiki Calibre 5 10-13-2008 09:25 AM


All times are GMT -4. The time now is 03:20 PM.


MobileRead.com is a privately owned, operated and funded community.