![]() |
#1 |
Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44
Karma: 40820
Join Date: Jun 2012
Device: Kindle 3 WIFI
|
Arabic/Persian text on Kindle 3
So, after installing the latest update of Kindle 3, I learned that the Arabic/Persian font that was available on Kindle experimental browser is now available in the Kindle book reader itself.
It is important for those who want to read Arabic/Persian books on Kindle. Let me explain more: For getting Arabic/Persian books work, it is needed that: 1. Kindle should understand UTF-8 encoding (This was ok, even before this update) 2. Kindle should be able to show Arabic/Persian characters (This is fixed with the latest update) 3. Kindle should do shaping (TODO, workaround is shaping manually) 4. Kindle should do right-to-left layout (Remaining problem) So, this is what I've got with shaping characters manully, that is also possible to do with the help of layouout engines in windows/linux. Pango is available on Kindle, but Can we use it effectively to fix this problem? I was searching for the ways to change font, and I came across Calibre plugin that can change font and justification of the text in Kindle. https://www.mobileread.com/forums/sho...d.php?t=118635 How does the plugin does this? Is it possible to use the way it works to mirror the flow of characters on the screen? Last edited by wlaf; 11-04-2012 at 05:42 AM. |
![]() |
![]() |
![]() |
#2 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@wlaf: It's come up a few times (look for posts by Doitsu & me, in particular).
TL;DR: Not much you can do, besides building KF8 files & no diacritics. It's not perfect, but it might be good enough for some scripts. (And, no, diving into pango to 'fix' it is probably not doable without breaking everything). |
![]() |
![]() |
![]() |
#3 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
You'll need to manually transfer the files via the USB cable. Unfortunately RTL Font embedding only works with fixed layout files. |
|
![]() |
![]() |
![]() |
#4 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@Doitsu: You got stuff with complex shaping working in fixed-layout books?
|
![]() |
![]() |
![]() |
#5 | |
Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44
Karma: 40820
Join Date: Jun 2012
Device: Kindle 3 WIFI
|
Doitsu, I could also be able to do it right! :-)
I was testing a "plain text file". Just setting direction to RTL in css worked fine. Shaping can be done manually. This program that can do the shaping: I'll attach it in for easier access. As you can see even diacratics work, with some minor problems that I think comes from the design of the font. Quote:
Last edited by wlaf; 11-03-2012 at 12:57 PM. |
|
![]() |
![]() |
![]() |
#6 | |||
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
Why would you want to shape letters manually when the Kindle rendering engine will do it for you? IIRC, Persian usually doesn't use diacritics so why go through the hassle of preshaping the letters? BTW, did you test my files on your K3, and did they display correctly? If they didn't, you probably transfered them via the Cloud or your FW3.4 update failed. (My test file didn't contain preshaped letters. I.e. preshaping is not required.) Quote:
|
|||
![]() |
![]() |
![]() |
#7 | ||||
Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44
Karma: 40820
Join Date: Jun 2012
Device: Kindle 3 WIFI
|
Quote:
Quote:
Quote:
Quote:
|
||||
![]() |
![]() |
![]() |
#8 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 59
Karma: 48000
Join Date: Oct 2012
Device: kindle paperwhite
|
Dear Doitsu
Is there a way yet to change the font so that we can have more Arabic fonts on PW not only the default one as seen in your above Qur'an example? thanks |
![]() |
![]() |
![]() |
#9 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
I hate the default font as much as you, but without a jailbreak and a font hack it's not possible to install additional fonts. And even with a font hack it might be tricky, because the Arabic glyphs come from the code2000.ttf fallback font. I.e. you could probably only replace the default font with one other Arabic font of your choice.
|
![]() |
![]() |
![]() |
#10 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Can't speak for the Touch/PW, but on the PW, the Fonts hack doesn't even tweak the CJK/I18N fonts for KF8 (only serif/sans & mono are changed).
It's on my TODO list, though. EDIT: Wee, my brain is turning into mush. Scratch that. It *does* handle CJK & I18N in KF8... [Well, I18N at least, there might be some more tweaks needed for some CJK scripts]. Last edited by NiLuJe; 11-07-2012 at 07:46 AM. |
![]() |
![]() |
![]() |
#11 | |
Member
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19
Karma: 29044
Join Date: Jan 2013
Device: Kindle Paperwhite
|
Kindle PW with latest firmware shows arabic text in KF8 files. There is neither need to add unicode conrol character nor dir=RL attributes and nor defining the book as a fixed layout book. I just drag & drop a simple HTML file to Kindle Previewer and copy the generated KF8 mobi file to my PW. However, if I have <idx:key> kind of tags in the HTML, Kindle Previewer generates simple mobi file and this mobi doesn't always show the arabic words in the correct order and font embedding is not supported.
What I wonder is the possibility of changing arabic font in KF8. I embedded a nice arabic font with some css like this one: Quote:
Does anyone succeeded embedding arabic font without a problem? |
|
![]() |
![]() |
![]() |
#12 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
So do all current Kindle models (K3 and higher).
Quote:
Can you post a .zip file with the source code and the compiled .mobi file? |
|
![]() |
![]() |
![]() |
#13 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,705
Karma: 4619474
Join Date: Nov 2012
Device: Kindle Scribe, Kindle Paperwhite
|
What's the use of this? Are there Arabic ebooks available online? I'd be interested to know. Arabic is my main language but I always read English ebooks as I rarely find Arabic ebooks on the web.
|
![]() |
![]() |
![]() |
#14 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
BTW, you could also create your own books from the .html files hosted at the Arabic Wikisouce website. Hopefully, the increased availability of ereaders with Arabic support will eventually convince Arab publishers to offer their books as ebooks, too. Last edited by Doitsu; 03-07-2013 at 11:32 AM. |
|
![]() |
![]() |
![]() |
#15 |
Member
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19
Karma: 29044
Join Date: Jan 2013
Device: Kindle Paperwhite
|
Source code and the screenshots are at the attachment.
Last edited by sevenkul; 03-12-2013 at 10:37 AM. Reason: added attachment |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to make a PRC book file in Persian (Farsi) | golagha | iRex | 7 | 01-29-2013 09:19 PM |
Kobo language support Persian/Arabic/Russian? | Haieflosse | Kobo Reader | 1 | 05-02-2012 02:11 AM |
Calibre is not viewing Arabic text | ahmed_rdi | Calibre | 3 | 10-19-2011 04:42 AM |
Sony PRS 700 - problems with arabic text | firdavs_abc | Sony Reader | 1 | 09-26-2009 07:37 AM |
openinkpot and middle eastern languages Arabic, Persian (Farsi) | ali_sade | OpenInkpot | 16 | 05-06-2009 05:10 AM |