Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 11-04-2015, 01:08 AM   #1
AlexBell
Wizard
AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.
 
AlexBell's Avatar
 
Posts: 3,413
Karma: 13369310
Join Date: May 2008
Location: Launceston, Tasmania
Device: Sony PRS T3, Kobo Glo, Kindle Touch, iPad, Samsung SB 2 tablet
How to prevent breaks within a 'word'

I'm working on an ebook in which the first part of the story takes place in --shire, and a city called X--.

I'm using —shire for the name of the county, and X— for the city. But every now and then both constructions break - with the — at the end of the line, and shire at the beginning of the next line - similarly for X—

Is there anyway to stop this happening? It happens rarely, but when it does it's ugly.

I've tried using —‍shire, but that doesn't work.

Last edited by AlexBell; 11-06-2015 at 01:14 AM.
AlexBell is offline   Reply With Quote
Old 11-04-2015, 01:53 AM   #2
apprenticeharper
Apprentices Against DRM
apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.apprenticeharper ought to be getting tired of karma fortunes by now.
 
apprenticeharper's Avatar
 
Posts: 46
Karma: 9787852
Join Date: Feb 2015
Location: UK
Device: Asus Laptop
If an ePub renderer ignores the zero width joiner, I don't think there's much you can do.

Hmmm.... I seem to remember that one renderer would no break a work if it started with a soft hyphen. Worth a try, but I'm not optimistic.

For Apple's iBooks you could use the {-webkit-hyphens:none;} CSS attribute. But I don't know how many other renderers take notice of that non-standard CSS.
apprenticeharper is offline   Reply With Quote
Advert
Old 11-04-2015, 02:56 AM   #3
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
You could use a quotation dash (U+2015) instead of an em dash (U+2014).

A quotation dash looks the same as an em dash, but doesn't break between the dash and the word.

The only problem is that some fonts don't contain a quotation dash, so you would want to embed a font that has one to be sure.
GeoffR is offline   Reply With Quote
Old 11-04-2015, 06:21 AM   #4
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,743
Karma: 8700123
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by GeoffR View Post
You could use a quotation dash (U+2015) instead of an em dash (U+2014).
RbnJrg is offline   Reply With Quote
Old 11-05-2015, 10:04 AM   #5
GrannyGrump
Obsessively Dedicated...
GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.
 
GrannyGrump's Avatar
 
Posts: 3,213
Karma: 34984928
Join Date: May 2011
Location: JAPAN (US expatriate)
Device: Sony PRS-T2, ADE on PC
If you don't mind messy markup, you might try a span with whitespace: nowrap
but then it might drop down to the next line, leaving a ragged right margin.

You can experiment with other whitespace settings, and see if any give a workable result.
http://www.w3schools.com/cssref/pr_text_white-space.asp

I keep seeing breaks with nbsp and with trailing emdash all the time. I often even see a break between a full stop and the closing quote mark --- kerning and hyphenation algorithms leave so much to be desired!
GrannyGrump is offline   Reply With Quote
Advert
Old 11-06-2015, 01:17 AM   #6
AlexBell
Wizard
AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.
 
AlexBell's Avatar
 
Posts: 3,413
Karma: 13369310
Join Date: May 2008
Location: Launceston, Tasmania
Device: Sony PRS T3, Kobo Glo, Kindle Touch, iPad, Samsung SB 2 tablet
Thanks to you all. I'll try quotation dash and see what happens. I presume the if the font family doesn't include quotation dash I won't see any dash at all?
AlexBell is offline   Reply With Quote
Old 11-06-2015, 03:02 AM   #7
HarryT
eBook Enthusiast
HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.
 
HarryT's Avatar
 
Posts: 85,544
Karma: 93383099
Join Date: Nov 2006
Location: UK
Device: Kindle Oasis 2, iPad Pro 10.5", iPhone 6
On most devices, if a font doesn't contain a glyph, an empty square box will be displayed instead.

I'd recommend against using a glyph which is not commonly present in fonts.
HarryT is offline   Reply With Quote
Old 11-06-2015, 05:54 AM   #8
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 GrannyGrump View Post
If you don't mind messy markup, you might try a span with whitespace: nowrap
but then it might drop down to the next line, leaving a ragged right margin.
Short lines are fairly common in Kindle editions, so that wouldn't bother me. Some time ago, Amazon evidently changed the software so that if the gaps got too wide between words in a justified line, then the line would fall short of the right margin. I see this often in e-books.
Notjohn is offline   Reply With Quote
Old 11-06-2015, 06:00 AM   #9
HarryT
eBook Enthusiast
HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.
 
HarryT's Avatar
 
Posts: 85,544
Karma: 93383099
Join Date: Nov 2006
Location: UK
Device: Kindle Oasis 2, iPad Pro 10.5", iPhone 6
Quote:
Originally Posted by Notjohn View Post
Some time ago, Amazon evidently changed the software so that if the gaps got too wide between words in a justified line, then the line would fall short of the right margin. I see this often in e-books.
Kindles have always done this, certainly as far back as my first Kindle, which was the Kindle Keyboard.
HarryT is offline   Reply With Quote
Old 11-06-2015, 03:43 PM   #10
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,546
Karma: 19001583
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
This is the main problem with Spanish books, where em-dashes (or quotation dashes) are used everywhere in dialogue... This "let's allow line break at either side of a dash, regardless of anything else" makes them look awful. Using quotation dashes is not a solution without embedding a font (and embedding a font is not a solution).
Jellby is offline   Reply With Quote
Old 11-07-2015, 05:04 AM   #11
doubleshuffle
Unicycle Daredevil
doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.
 
doubleshuffle's Avatar
 
Posts: 13,944
Karma: 185432100
Join Date: Jan 2011
Location: Planet of the Pudding Brains
Device: Aura HD (R.I.P. After six years the USB socket died.) tolino shine 3
Alex, have you tried the word joiner?

It looks awful in Sigil's book view, but seems to work just fine in RMSDK.

(Thanks to pynch for mentioning this in the German forum a while back!)


EDIT: The html code, missing from the Wiki entry is ⁠

Last edited by doubleshuffle; 11-07-2015 at 05:07 AM.
doubleshuffle is offline   Reply With Quote
Old 11-07-2015, 06:07 AM   #12
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 HarryT View Post
Kindles have always done this, certainly as far back as my first Kindle, which was the Kindle Keyboard.
It was in June 2010 that my Kindle (I think a K3 Keyboard) updated and the display changed for me.
Notjohn is offline   Reply With Quote
Old 11-08-2015, 01:17 AM   #13
AlexBell
Wizard
AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.
 
AlexBell's Avatar
 
Posts: 3,413
Karma: 13369310
Join Date: May 2008
Location: Launceston, Tasmania
Device: Sony PRS T3, Kobo Glo, Kindle Touch, iPad, Samsung SB 2 tablet
Quote:
Originally Posted by doubleshuffle View Post
Alex, have you tried the word joiner?

It looks awful in Sigil's book view, but seems to work just fine in RMSDK.

(Thanks to pynch for mentioning this in the German forum a while back!)


EDIT: The html code, missing from the Wiki entry is ⁠
Thanks, doubleshuffle. Not only have I not tried it I've never even heard of it. I'll do some research and try it out. I don't use Sigil, so that should not be a problem for me.
AlexBell is offline   Reply With Quote
Old 11-10-2015, 02:33 AM   #14
AlexBell
Wizard
AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.AlexBell ought to be getting tired of karma fortunes by now.
 
AlexBell's Avatar
 
Posts: 3,413
Karma: 13369310
Join Date: May 2008
Location: Launceston, Tasmania
Device: Sony PRS T3, Kobo Glo, Kindle Touch, iPad, Samsung SB 2 tablet
Quote:
Originally Posted by AlexBell View Post
Thanks, doubleshuffle. Not only have I not tried it I've never even heard of it. I'll do some research and try it out. I don't use Sigil, so that should not be a problem for me.
Thanks for your trouble, but it doesn't work - at least, not on my Sony T3. I get the dreaded little square with a question mark inside.
AlexBell is offline   Reply With Quote
Old 11-10-2015, 06:39 AM   #15
doubleshuffle
Unicycle Daredevil
doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.doubleshuffle ought to be getting tired of karma fortunes by now.
 
doubleshuffle's Avatar
 
Posts: 13,944
Karma: 185432100
Join Date: Jan 2011
Location: Planet of the Pudding Brains
Device: Aura HD (R.I.P. After six years the USB socket died.) tolino shine 3
What a pity. I thought I had successfully tested it in ADE, Bluefire and on my Kobo, but it's been a while. I was looking forward to using it in the collection I'm working on right now - keeping it for last due to the horrible look in Sigil - well, seems I can forget about that now.

Although I think I'll do some more testing and if it really works like I remember, I might offer one version with and one without...
doubleshuffle is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Word breaks FlexUser Calibre 10 03-24-2014 02:42 AM
How to prevent page breaks? bgoldnyxnet ePub 9 01-28-2014 09:45 AM
Getting word breaks to work correctly Techno4 ePub 1 08-27-2012 01:27 PM
Epub to Mobi conversion strange word breaks inkwords Conversion 0 03-04-2012 05:29 PM
Word Wrap and Creating Line breaks for paragraphs? mjt57 Calibre 3 01-03-2011 10:14 PM


All times are GMT -4. The time now is 02:47 PM.


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