Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 01-27-2025, 08:00 AM   #1
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
Question Kobo Device Unable to Render Unicode Italics in EPUBs – Seeking a Conversion Solution

Hi everyone,

I’ve encountered an issue with my Kobo device failing to properly render italicized text in an EPUB file. Specifically, the text uses Unicode (e.g., 𝘸𝘦𝘭𝘤𝘰𝘮&#120358. My Kobo device cannot display these characters and either skips them, shows placeholder glyphs or shows an empty line where the text should be.

Does Calibre offer any built-in tools or plugins to convert it to a readable version?

Thanks in advance for your help!

p.s. i'm rather new to all of this
GuyNoodle is offline   Reply With Quote
Old 01-27-2025, 08:03 AM   #2
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: 78,947
Karma: 144284074
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 GuyNoodle View Post
Hi everyone,

I’ve encountered an issue with my Kobo device failing to properly render italicized text in an EPUB file. Specifically, the text uses Unicode (e.g., 𝘸𝘦𝘭𝘤𝘰𝘮&#120358. My Kobo device cannot display these characters and either skips them, shows placeholder glyphs or shows an empty line where the text should be.

Does Calibre offer any built-in tools or plugins to convert it to a readable version?

Thanks in advance for your help!

p.s. i'm rather new to all of this
Can you please post a code sample of the HTML and CSS?

Are you using KePub or ePub?

Thanks.
JSWolf is offline   Reply With Quote
Advert
Old 01-27-2025, 08:14 AM   #3
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
Quote:
Originally Posted by JSWolf View Post
Can you please post a code sample of the HTML and CSS?

Are you using KePub or ePub?

Thanks.
CSS:
Code:
div.svg_outer {
   display: block;
   margin-bottom: 0;
   margin-left: 0;
   margin-right: 0;
   margin-top: 0;
   padding-bottom: 0;
   padding-left: 0;
   padding-right: 0;
   padding-top: 0;
   text-align: left;
}
div.svg_inner {
   display: block;
   text-align: center;
}
h1, h2 {
   text-align: center;
   margin-bottom: 10%;
   margin-top: 10%;
}
h3, h4, h5, h6 {
   text-align: center;
   margin-bottom: 15%;
   margin-top: 10%;
}
ol, ul {
   padding-left: 8%;
}
body {
  margin: 2%;
}
p {
  overflow-wrap: break-word;
}
dd, dt, dl {
  padding: 0;
  margin: 0;
}
img {
   display: block;
   min-height: 1em;
   max-height: 100%;
   max-width: 100%;
   padding-bottom: 0;
   padding-left: 0;
   padding-right: 0;
   padding-top: 0;
   margin-left: auto;
   margin-right: auto;
   margin-bottom: 2%;
   margin-top: 2%;
}
img.inline {
   display: inline;
   min-height: 1em;
   margin-bottom: 0;
   margin-top: 0;
}
.thumbcaption {
  display: block;
  font-size: 0.9em;
  padding-right: 5%;
  padding-left: 5%;
}
hr {
   color: black;
   background-color: black;
   height: 2px;
}
a:link {
   text-decoration: none;
   color: #0B0080;
}
a:visited {
   text-decoration: none;
}
a:hover {
   text-decoration: underline;
}
a:active {
   text-decoration: underline;
}table {
   width: 90%;
   border-collapse: collapse;
}
table, th, td {
   border: 1px solid black;
}
.webToEpub-author-note {
    border: 1px solid black; padding: 0.5em
}
HTML code sample
Code:
<div class="dib pr">     <p>He was transported to a temple like room with a fairy</p>   </div> </div>     <div class="db cha-paragraph pr hover-light j_paragraph j_para_644d08e41ee2cec772e6c122453de06d  "> <div class="dib pr">     <p>she said " 𝘸𝘦𝘭𝘤𝘰𝘮𝘦 𝘵𝘰 𝘰𝘮𝘦𝘨𝘢... 𝘮𝘺 𝘯𝘢𝘮𝘦 𝘪𝘴 𝘨𝘢𝘪𝘢 𝘪 𝘢𝘮 𝘵𝘩𝘦 𝘢𝘳𝘵𝘪𝘧𝘪𝘤𝘪𝘢𝘭 𝘪𝘯𝘵𝘦𝘭𝘭𝘪𝘨𝘦𝘯𝘤𝘦 𝘪𝘯𝘤𝘩𝘢𝘳𝘨𝘦 𝘰𝘧 𝘵𝘩𝘪𝘴 𝘸𝘰𝘳𝘭𝘥."</p>   </div> </div>
I have a feeling that the header section, along with a bit of the content immediately following it, might also be relevant:
Code:
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Chapter 2: 'Omega'</title><link href="../Styles/stylesheet.css" type="text/css" rel="stylesheet" /></head><body><div class="cha-tit skiptranslate">  <div class="pr hover-light j_paragraph j_para_54688165499297042_title mb14" data-ejs="{&quot;paragraphId&quot;:&quot;54688165499297042_title&quot;,&quot;chapterId&quot;:&quot;54688165499297042&quot;}"> <h1 class="dib mb0 fw700 fs24 lh1.5">Chapter 2: 'Omega'</h1>  </div>      </div> <div class="cha-content " data-report-l1="3">        <div class="cha-words _font_54688165499297042">       <div class="db cha-paragraph pr hover-light j_paragraph j_para_630c1f8f089b272c2f26148c5233d4ef  ">
The specific part that doesn’t render on my Kobo is shown below, and all subsequent text formatted in the same way simply doesn’t appear:
Quote:
𝘸𝘦𝘭𝘤𝘰𝘮𝘦 𝘵𝘰 𝘰𝘮𝘦𝘨𝘢... 𝘮𝘺 𝘯𝘢𝘮𝘦 𝘪𝘴 𝘨𝘢𝘪𝘢 𝘪 𝘢𝘮 𝘵𝘩𝘦 𝘢𝘳𝘵𝘪𝘧𝘪𝘤𝘪𝘢𝘭 𝘪𝘯𝘵𝘦𝘭𝘭𝘪𝘨𝘦𝘯𝘤𝘦 𝘪𝘯𝘤𝘩𝘢𝘳𝘨𝘦 𝘰𝘧 𝘵𝘩𝘪𝘴 𝘸𝘰𝘳𝘭𝘥
Thank you in advance for any help or guidance
GuyNoodle is offline   Reply With Quote
Old 01-27-2025, 12:00 PM   #4
Karellen
Wizard
Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.
 
Karellen's Avatar
 
Posts: 1,592
Karma: 9499994
Join Date: Sep 2021
Location: Australia
Device: Kobo Libra 2
It is a bit hard to figure out. Your html code snippet shows numerous classes but they are not shown in your css snippet. I do wonder why this is needed...
<div class="db cha-paragraph pr hover-light j_paragraph j_para_644d08e41ee2cec772e6c122453de06d ">
<div class="dib pr">


Your missing sentence is captured by the above, so who knows which one of those classes is responsible.
Maybe post the ebook here? If in copyright, scramble it first.
Karellen is offline   Reply With Quote
Old 01-27-2025, 07:35 PM   #5
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: 44,518
Karma: 167912829
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
I am just curious as to why you are using "mathematical sans-serif italic small e" instead of a standard e? That character would need to in a font on your Kobo that is accessible to the ePub while a standard e is available in pretty much every font.
DNSB is offline   Reply With Quote
Advert
Old 01-27-2025, 08:19 PM   #6
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,270
Karma: 78869092
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
It looks as if this is from "MMORPG : Rebirth Of The Strongest Guild Master" https://m.webnovel.com/book/mmorpg-r...66446406794005

I haven't yet managed to figure out how to download the content in ePub format to look at the underlying markup.
PeterT is offline   Reply With Quote
Old 01-27-2025, 09:26 PM   #7
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: 44,518
Karma: 167912829
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Opening the 2nd chapter of MMORPG : Rebirth Of The Strongest Guild Master on WebNovel and looking at the stylesheet and code associated with that page, there is no styling for italic. The author appears to have used italic characters from the Mathematical section of the font file to generate italics.

Other than the 1.6+ setting for line height, this appears to have been typed and not created in any decent editor. The following quote expresses my opinion of this:

"Well, here's another nice mess you've gotten me into."—Oliver Hardy of Laurel & Hardy

I've attached an image of what the code looks like in either calibre's ebook-editor or in Sigil. The code block below is a copy/paste from calibre's ebook-editor.

Code:
<p>He was transported to a temple like room with a fairy</p>

  <p>she said ” �������������� ���� ����������… ���� �������� ���� �������� �� ���� ������ �������������������� ������������������������ ���������������� ���� �������� ����������.”</p>

  <p>������������ ������������ �������� ��������������</p>
Attached Thumbnails
Click image for larger version

Name:	Screenshot 2025-01-27 182942.png
Views:	73
Size:	10.5 KB
ID:	213297  

Last edited by DNSB; 01-27-2025 at 09:33 PM.
DNSB is offline   Reply With Quote
Old 01-28-2025, 12:48 AM   #8
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: 44,518
Karma: 167912829
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
I did some more digging at the file to kill time between periods while watching hockey and found that the Code2001 font from the Code2001 site would display the mathematical sans-serif italic grouping.

Still ugly as homemade sin since the author/translator was likely not very comfortable in English but at least you can read the text.
DNSB is offline   Reply With Quote
Old 01-28-2025, 05:23 AM   #9
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
Quote:
Originally Posted by Karellen View Post
It is a bit hard to figure out. Your html code snippet shows numerous classes but they are not shown in your css snippet. I do wonder why this is needed...
<div class="db cha-paragraph pr hover-light j_paragraph j_para_644d08e41ee2cec772e6c122453de06d ">
<div class="dib pr">


Your missing sentence is captured by the above, so who knows which one of those classes is responsible.
Maybe post the ebook here? If in copyright, scramble it first.
This is because I extracted it from a novel site to read on my eReader when I don’t have access to my computer. Although I’m not a programmer by any means, I believe this code pertains to comments made on the site, which are visible when you hover over them. When extracting the novel, this code is included.

Quote:
Originally Posted by PeterT View Post
It looks as if this is from "MMORPG : Rebirth Of The Strongest Guild Master" https://m.webnovel.com/book/mmorpg-r...66446406794005

I haven't yet managed to figure out how to download the content in ePub format to look at the underlying markup.
This is correct; I have included the extracted EPUB for reference.
Quote:
Originally Posted by DNSB View Post
I did some more digging at the file to kill time between periods while watching hockey and found that the Code2001 font from the Code2001 site would display the mathematical sans-serif italic grouping.

Still ugly as homemade sin since the author/translator was likely not very comfortable in English but at least you can read the text.
I truly appreciate the effort, and I agree with the observation that the author wasn’t very comfortable with English. However, I love the general idea and progression of the story, which has me hooked. I’m currently at chapter 80 and have been reading it despite the missing text—it’s doable, but I would love to have the text included. On that note, I’ll gladly take your fixed version, but I’d also like to explore options to fix the EPUB so I can read it using my favorite font, Amazon Ember.
GuyNoodle is offline   Reply With Quote
Old 01-28-2025, 08:49 AM   #10
Quoth
Still reading
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 13,651
Karma: 103503445
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper
Formatted by a nearly clueless web page "hacker". It's not about lack of English but lack of understanding of formatting.

Quote:
<p>He was transported to a temple like room with a fairy</p>

<p>she said ” �������������� ���� ����������… ���� �������� ���� �������� �� ���� ������ �������������������� ������������������������ ���������������� ���� �������� ����������.”</p>

<p>������������ ������������ �������� ��������������</p>
The problem is the original source! Or maybe extraction. That's not a viewer or renderer, but editing source! That's unfixable by any regex

Last edited by Quoth; 01-28-2025 at 01:50 PM.
Quoth is offline   Reply With Quote
Old 01-28-2025, 09:27 AM   #11
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
Excuse me?
GuyNoodle is offline   Reply With Quote
Old 01-28-2025, 09:39 AM   #12
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
Quote:
Originally Posted by GuyNoodle View Post
Excuse me?
Since I can no longer edit my post after 5 minutes, here’s what I originally intended to say:

The process involves removing unnecessary tags, normalizing Unicode characters, converting them to Kobo-compatible HTML/CSS, and cleaning up nested tags. My question was whether Calibre offers any automated tools that can perform all these tasks at once. I discovered that the Edit Book tool provides some functionality, but I’m seeking guidance on the best regex patterns to efficiently accomplish these tasks. I have basic knowledge of CSS/HTML and some other programming languages, but as I mentioned in my earlier comment, while I am not a programmer by any means, that does not mean I lack understanding of the topic.

Your snarky comments, however, are not contributing meaningfully to this discussion. I would kindly request that you refrain from replying if you do not have useful information to add to the topic.
GuyNoodle is offline   Reply With Quote
Old 01-28-2025, 11:02 AM   #13
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,270
Karma: 78869092
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
One thing to keep in mind is that your favourite font does NOT include the characters that the html uses.

Sent from my Pixel 7a using Tapatalk
PeterT is offline   Reply With Quote
Old 01-28-2025, 11:26 AM   #14
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,270
Karma: 78869092
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
Quote:
Originally Posted by DNSB View Post
I did some more digging at the file to kill time between periods while watching hockey and found that the Code2001 font from the Code2001 site would display the mathematical sans-serif italic grouping.

Still ugly as homemade sin since the author/translator was likely not very comfortable in English but at least you can read the text.
I'm not totally sure but what would happen if you converted to kepub? Would nickel fall back to another font for missing glyphs? (OP has expressed interest in sticking with his favourite font, Amazon Ember)??

Sent from my Pixel 7a using Tapatalk
PeterT is offline   Reply With Quote
Old 01-28-2025, 02:12 PM   #15
GuyNoodle
Junior Member
GuyNoodle began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Jan 2025
Device: Kobo Libra 2
I decided to reach out to the creator of the novel extraction software I used. In hindsight, I probably should’ve done that in the first place, but hey, 🤷 He provided the solution!

So, for any future readers:
You can remove all Unicode characters with Calibre by following these steps:
  • Select your book.
  • Go to Convert books.
  • Navigate to Look & Feel -> Text.
  • Check the box labeled "Transliterate Unicode characters to ASCII".
  • Click OK.

This solution will obviously remove bold and/or italic text formatted with Unicode, but I can perfectly live with that.
GuyNoodle is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Plugboard: Removing Unicode characters that Kobo can't render ownedbycats Devices 6 09-11-2021 01:03 AM
Unable to download some Epubs from Kobo rashkae Kobo Reader 64 10-07-2019 05:48 PM
Italics don't render in NOOK app Ballory Devices 10 03-27-2019 11:03 PM
ePub CSS @fontface Unicode chars render in <td>, not in <div>, other elements Abelinkin ePub 2 06-05-2012 04:24 AM


All times are GMT -4. The time now is 10:54 AM.


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