Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 05-05-2022, 10:57 PM   #76
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,245
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by JSWolf View Post
Does left justified text work with hyphenation (KePub)?
Hyphenation? What's this hyphenation? On a serious note, a hyphen in left justified rendering is an rara avis.
DNSB is offline   Reply With Quote
Old 05-06-2022, 06:21 AM   #77
Lykke
Groupie
Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.Lykke can program the VCR without an owner's manual.
 
Posts: 159
Karma: 182076
Join Date: Aug 2017
Device: Kobo Libra 2
Quote:
Originally Posted by JSWolf View Post
Does left justified text work with hyphenation (KePub)?
Yes, if you enable the patch "Set KePub hyphenation". Seems to me it works as well as hypenation with justified text… only that, naturally, the text will not be justified.
Lykke is offline   Reply With Quote
Advert
Old 05-06-2022, 08:32 AM   #78
CyberPaul
Groupie
CyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheese
 
CyberPaul's Avatar
 
Posts: 159
Karma: 1000
Join Date: Aug 2016
Device: Kindle Voyage - Tolino Vision 4 HD - Kobo Sage
@jackie_w
This is the KEPUB code:
Quote:
<p><span class="koboSpan" id="kobo.91.1">Se non avessi creduto al principio elementare che non si può continuare all’infinito a mandare roba dall’alto in basso senza contraccambiarla con un invio dal basso in alto, mi sarei lasciato vincere dal sentimentalismo. </span><span class="koboSpan" id="kobo.91.2">Ma… </span><em><span class="koboSpan" id="kobo.92.1">Tanstaafl</span></em><span class="koboSpan" id="kobo.93.1">: </span><span class="koboSpan" id="kobo.93.2">i pranzi gratis non esistono, tanto a Bombay quanto sulla Luna.</span></p>
I think it is pretty much as you described, right?
What I do not understand is why the algorithm is insisting on that specific sequence (Ma...)? Why not adding spaces within other words? I think it can be related to periods interpreted as single words, because usually it is a separator of words.

Last edited by CyberPaul; 05-06-2022 at 09:15 AM.
CyberPaul is offline   Reply With Quote
Old 05-06-2022, 09:33 AM   #79
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
Posts: 13,529
Karma: 78910202
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
Have you tried replacing the ... by a Unicode character?

Sent from my Pixel 4a using Tapatalk
PeterT is offline   Reply With Quote
Old 05-06-2022, 11:05 AM   #80
CyberPaul
Groupie
CyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheese
 
CyberPaul's Avatar
 
Posts: 159
Karma: 1000
Join Date: Aug 2016
Device: Kindle Voyage - Tolino Vision 4 HD - Kobo Sage
No, I would like to avoid editing books before reading them
CyberPaul is offline   Reply With Quote
Advert
Old 05-06-2022, 11:16 AM   #81
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,245
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by PeterT View Post
Have you tried replacing the ... by a Unicode character?
As far as I can tell, the original text is using an ellipsis (…) and not 3 periods. I suspect using the numeric entity for a … ( & # x2026; ) would have the same results since it appears that all 3 characters inside <span class="koboSpan" id="kobo.91.2">Ma… </span> are having extra white space added.
DNSB is offline   Reply With Quote
Old 05-06-2022, 11:31 AM   #82
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
Quote:
Originally Posted by CyberPaul View Post
@jackie_w
This is the KEPUB code:

I think it is pretty much as you described, right?
Yes.

Quote:
Originally Posted by CyberPaul View Post
What I do not understand is why the algorithm is insisting on that specific sequence (Ma...)? Why not adding spaces within other words? I think it can be related to periods interpreted as single words, because usually it is a separator of words.
If you're asking how the kepub reading app decides where to "inject unwanted spaces" - the simple answer is I don't know, other than it must feel it's necessary to get the neatly justified right edge. Why it would think it's OK to create spaces within a word, rather than adding more space to the existing gaps between words, is anyone's guess.

If you're asking why the kepub creation algorithm chooses to fragment paragraphs the way it does - it's for koboSpan purposes. It tries to create (at least) one per sentence. However a koboSpan must only contain text, not other tags, so it has to end the old one and start a new one when it encounters inline tags such as <i>, <em>, <span>, ... etc. in the middle of a sentence. On top of that, the algorithm used to determine what will be considered 'end of sentence' is a somewhat simplistic list of punctuation characters (period, colon, ellipsis, ... etc) in a regex search.

With current tools, books using a lot of any of the following will have a lot of unnecessary (IMO) koboSpan fragmentation during kepub creation:
  • 3 consecutive periods (...) instead of a single ellipsis (…)
  • abbreviations, Mr. Mrs. Dr. U.S.A. U.K.
  • time-related, A.M. P.M. 12:30

Last edited by jackie_w; 05-06-2022 at 11:37 AM. Reason: typo
jackie_w is offline   Reply With Quote
Old 05-06-2022, 01:06 PM   #83
CyberPaul
Groupie
CyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheese
 
CyberPaul's Avatar
 
Posts: 159
Karma: 1000
Join Date: Aug 2016
Device: Kindle Voyage - Tolino Vision 4 HD - Kobo Sage
Quote:
Originally Posted by DNSB View Post
As far as I can tell, the original text is using an ellipsis (…) and not 3 periods. I suspect using the numeric entity for a … ( & # x2026; ) would have the same results since it appears that all 3 characters inside <span class="koboSpan" id="kobo.91.2">Ma… </span> are having extra white space added.
You are right, I didn’t even notice it! It is using the single character, not the single dots.

Last edited by CyberPaul; 05-06-2022 at 06:47 PM.
CyberPaul is offline   Reply With Quote
Old 05-06-2022, 03:04 PM   #84
CyberPaul
Groupie
CyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheese
 
CyberPaul's Avatar
 
Posts: 159
Karma: 1000
Join Date: Aug 2016
Device: Kindle Voyage - Tolino Vision 4 HD - Kobo Sage
Quote:
Originally Posted by jackie_w View Post
f you're asking how the kepub reading app decides where to "inject unwanted spaces" - the simple answer is I don't know, other than it must feel it's necessary to get the neatly justified right edge. Why it would think it's OK to create spaces within a word, rather than adding more space to the existing gaps between words, is anyone's guess.
Yes, that was my question. Specifically why preferring to alter THAT specific combination? It must have a peculiar rule for handling that specific character or special characters in general.

Could you please share your customized plugin? I would like to try converting my epub using your version optimized to create less spans.

Last edited by CyberPaul; 05-06-2022 at 03:10 PM.
CyberPaul is offline   Reply With Quote
Old 05-08-2022, 05:09 PM   #85
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
Quote:
Originally Posted by CyberPaul View Post
Could you please share your customized plugin? I would like to try converting my epub using your version optimized to create less spans.
I'm afraid it's not really suitable for sharing. In addition to the koboSpans stuff, I've added several other non-standard features (aimed only at my personal whims) plus I've removed/changed existing KTE features I didn't like. I'll be happy to share what I've done with the official KTE developers/maintainers if they ask.
jackie_w is offline   Reply With Quote
Old 05-08-2022, 07:33 PM   #86
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,760
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
@jackie_w, does your version of KePub work better then KePub from the official driver?
JSWolf is offline   Reply With Quote
Old 05-08-2022, 08:05 PM   #87
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,245
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by JSWolf View Post
@jackie_w, does your version of KePub work better then KePub from the official driver?
For @jackie_w, it does. For others it may not. And probably a rather important consideration is that just perhaps @jackie_w does not want to be responsible for supporting a public fork of the KoboTouchExtended driver.
DNSB is offline   Reply With Quote
Old 05-08-2022, 08:08 PM   #88
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,760
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by DNSB View Post
For @jackie_w, it does. For others it may not. And probably a rather important consideration is that just perhaps @jackie_w does not want to be responsible for supporting a public fork of the KoboTouchExtended driver.
I'm curious and if it does work better, maybe the official plugin can then be improved. It's just a thought.
JSWolf is offline   Reply With Quote
Old 05-08-2022, 08:12 PM   #89
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,245
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by JSWolf View Post
I'm curious and if it does work better, maybe the official plugin can then be improved. It's just a thought.
Hmm... To quote @jackie_w's message:
Quote:
I'll be happy to share what I've done with the official KTE developers/maintainers if they ask.
DNSB is offline   Reply With Quote
Old 05-11-2022, 05:52 PM   #90
CyberPaul
Groupie
CyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheeseCyberPaul can extract oil from cheese
 
CyberPaul's Avatar
 
Posts: 159
Karma: 1000
Join Date: Aug 2016
Device: Kindle Voyage - Tolino Vision 4 HD - Kobo Sage
How do they know of those improvements of nobody tells them?
CyberPaul is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adjusting 'text weight' on Kindle Paperwhite susmoka Amazon Kindle 8 03-07-2016 09:51 PM
EPUB to KEPUB line spacing Buhaj47 Conversion 1 12-07-2015 04:00 PM
Aura epub, kepub, hyphenation and word-spacing pblasi Kobo Reader 5 08-22-2014 05:13 AM
Left-justified text in a right-justified box Skeezix Conversion 4 11-15-2011 08:44 PM
Justified word paragraph not wrapping in mobi wlloydw Conversion 0 03-05-2011 03:03 PM


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


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