Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 02-06-2015, 07:44 PM   #16
boriar
Evangelist
boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.boriar ought to be getting tired of karma fortunes by now.
 
boriar's Avatar
 
Posts: 407
Karma: 314204
Join Date: Jan 2015
Device: bq Avant XL, Kobo Aura H2O, Onyx Boox M96C Plus
Quote:
Originally Posted by GeoffR View Post
I don't know. The tile order is based on the last time the object associated with the tile was used. What other order would be useful?

If you mean to change the order by dragging the tiles around or pinning them in place then that would be a nice feature, but I doubt it is possible just with a patch.
That's exactly what i want (in bold). Like the "Last open book"'s windows is always the first.
boriar is offline   Reply With Quote
Old 02-09-2015, 04:56 AM   #17
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
Patch for Arabic book titles

This patch changes the font style used for book titles from italic to normal, which fixes a problem with displaying book titles in Arabic on the Glo/Aura/AuraHD/H2O. (Edit: I don't think the problem occurs on the Touch/Mini.)
Spoiler:
Code:
<Patch>
patch_name = `Book titles font style normal`
patch_enable = `yes`
#
# This patch changes the font style used for book titles displayed in the
# library, search results, etc. from italic to normal. This works around the
# problem of the system fonts missing italic glyphs for Arabic.
#
# Book title in details view
replace_string = D12511, `font-style: italic;`, `font-style: normal;`
#
# Search term in search results view
replace_string = D7D573, `font-style: italic;`, `font-style: normal;`
#
# Book title in library view
replace_string = D842F0, `font-style: italic;`, `font-style: normal;`
</Patch>


Edit: Note that the Arabic glyphs will not be displayed immediately after restarting the device, it is necessary to open a book and maybe to access the Aa font settings menu before they will be available to the rest of the UI.

Last edited by GeoffR; 02-10-2015 at 09:50 PM. Reason: Updated patch to also change titles in book details view
GeoffR is offline   Reply With Quote
Old 02-09-2015, 02:34 PM   #18
Rnway
Junior Member
Rnway began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jan 2015
Device: Kobo Aura H2O
Could you include the patch that prevents dictionaries from getting overwritten by a sync, as mentioned in this post?

https://www.mobileread.com/forums/sho...&postcount=131
Rnway is offline   Reply With Quote
Old 02-09-2015, 09:07 PM   #19
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
Quote:
Originally Posted by Rnway View Post
Could you include the patch that prevents dictionaries from getting overwritten by a sync, as mentioned in this post?

https://www.mobileread.com/forums/sho...&postcount=131
It looks like the firmware has changed quite a bit since that post; this a a patch to change the strings containing "dicthtml" to "micthtml" in the current firmware, I've left the strings uncommented that seem to correspond to the ones in that earlier patch, but this is just a guess. I don't use custom dictionaries, and I haven't tested it at all.
Spoiler:
Code:
<Patch>
patch_name = `Change dicthtml strings to micthtml`
patch_enable = `yes`
# `%1/dicthtml%2.zip` --> `%1/micthtml%2.zip`
#replace_string = C94734, `%1/dicthtml%2.zip`, `%1/micthtml%2.zip`
# `%1/dicthtml%2` --> `%1/micthtml%2`
replace_string = C9B834, `%\01\0/\0d\0i\0c\0t\0h\0t\0m\0l\0%\02\0`, `%\01\0/\0m\0i\0c\0t\0h\0t\0m\0l\0%\02\0`
# `dicthtml` --> `micthtml`
replace_string = C9B87C, `d\0i\0c\0t\0h\0t\0m\0l\0`, `m\0i\0c\0t\0h\0t\0m\0l\0`
# `dicthtml*` --> `micthtml*`
#replace_string = C9B9B8, `d\0i\0c\0t\0h\0t\0m\0l\0*\0`, `m\0i\0c\0t\0h\0t\0m\0l\0*\0`
# `%1/dicthtml%2` --> `%1/micthtml%2`
replace_string = C9BD54, `%\01\0/\0d\0i\0c\0t\0h\0t\0m\0l\0%\02\0`, `%\01\0/\0m\0i\0c\0t\0h\0t\0m\0l\0%\02\0`
# `%1/dicthtml%2` --> `%1/micthtml%2`
replace_string = C9BDB8, `%\01\0/\0d\0i\0c\0t\0h\0t\0m\0l\0%\02\0`, `%\01\0/\0m\0i\0c\0t\0h\0t\0m\0l\0%\02\0`
# `%1/dicthtml%2` --> `%1/micthtml%2`
replace_string = C9BE1C, `%\01\0/\0d\0i\0c\0t\0h\0t\0m\0l\0%\02\0`, `%\01\0/\0m\0i\0c\0t\0h\0t\0m\0l\0%\02\0`
# `%1/%2/dict/dicthtml%3` --> `%1/%2/dict/micthtml%3`
replace_string = C9BE80, `%\01\0/\0%\02\0/\0d\0i\0c\0t\0/\0d\0i\0c\0t\0h\0t\0m\0l\0%\03\0`, `%\01\0/\0%\02\0/\0d\0i\0c\0t\0/\0m\0i\0c\0t\0h\0t\0m\0l\0%\03\0`
# `dicthtml*` --> `micthtml*`
#replace_string = CA98AC, `d\0i\0c\0t\0h\0t\0m\0l\0*\0`, `m\0i\0c\0t\0h\0t\0m\0l\0*\0`
# `dicthtml%1` --> `micthtml%1`
#replace_string = CC26D0, `d\0i\0c\0t\0h\0t\0m\0l\0%\01\0`, `m\0i\0c\0t\0h\0t\0m\0l\0%\01\0`
</Patch>
GeoffR is offline   Reply With Quote
Old 02-10-2015, 04:03 AM   #20
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
Arabic keyboard patch

This patch replaces the keyboard's extended Latin characters with Arabic ones:

Spoiler:
Code:
<Patch>
patch_name = `Arabic keyboard`
patch_enable = `yes`
# Replace layout sign
replace_bytes = D6C4F8, C3 89 C3 80 C3 87, D8 B9 00 00 00 00
# Change keyboard layout
base_address = D6C418
# Top row
replace_bytes = 0000, C3 A6, D8 B0
replace_bytes = 0030, C5 93, D8 B6
# Second row
replace_bytes = 0004, C3 A0, D8 B5
replace_bytes = 0008, C3 A8, D8 AB
replace_bytes = 000C, C3 AC, D9 82
replace_bytes = 0010, C3 B2, D9 81
replace_bytes = 0014, C3 B9, D8 BA
replace_bytes = 0018, C3 A1, D8 B9
replace_bytes = 001C, C3 A9, D9 87
replace_bytes = 0020, C3 AD, D8 AE
replace_bytes = 0024, C3 B3, D8 AD
replace_bytes = 0028, C3 BA, D8 AC
replace_bytes = 002C, C3 BD, D8 AF
# Third row
replace_bytes = 0034, C3 A2, D8 B4
replace_bytes = 0038, C3 AA, D8 B3
replace_bytes = 003C, C3 AE, D9 8A
replace_bytes = 0040, C3 B4, D8 A8
replace_bytes = 0044, C3 BB, D9 84
replace_bytes = 0048, C3 A4, D8 A7
replace_bytes = 004C, C3 AB, D8 AA
replace_bytes = 0050, C3 AF, D9 86
replace_bytes = 0054, C3 B6, D9 85
replace_bytes = 0058, C3 BC, D9 83
replace_bytes = 005C, C3 BF, D8 B7
# Bottom row
replace_bytes = 0060, C3 A3, D8 A6
replace_bytes = 0064, C3 B1, D8 A1
replace_bytes = 0068, C3 B5, D8 A4
replace_bytes = 006C, C3 A5, D8 B1
replace_bytes = 0070, C3 9F, D9 89
replace_bytes = 0074, C3 A7, D8 A9
replace_bytes = 0078, C4 91, D9 88
replace_bytes = 007C, C3 B8, D8 B2
replace_bytes = 0080, C4 B3, D8 B8
replace_bytes = 0084, C5 82, 2E 00
</Patch>


After a device restart the Arabic glyphs won't display properly until a book has been opened and the font menu (Aa) accessed.

The shift key doesn't do anything to the Arabic keys, is that a fault or doesn't Arabic have upper and lower cases?

Not all of the extended keypad is used, maybe possible to replace some more of the keys on the upper row with Arabic keys?

Last edited by GeoffR; 02-11-2015 at 11:14 PM. Reason: Updated comments in patch
GeoffR is offline   Reply With Quote
Old 02-10-2015, 06:26 AM   #21
mamado
Member
mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.mamado ought to be getting tired of karma fortunes by now.
 
Posts: 15
Karma: 215014
Join Date: Feb 2015
Device: Kobo Aura
This is GREAT GeoffR, Thanks a lot, this works very well, with two issues:

The on-the-fly search results while searching, and the search string in the results page are unreadable, may be they need the same change you did before with changing italic to normal.





Quote:
Originally Posted by GeoffR View Post
The shift key doesn't do anything to the Arabic keys, is that a fault or doesn't Arabic have upper and lower cases?
Correct, there is no upper and lower case. usually on keyboards shift allows adding "Tashkil" which are small "modifiers" like accents that affect how the character is pronounced, things like "َّ ً ٌ َ ٍ " but I don't think those are needed in this context.

Quote:
Originally Posted by GeoffR View Post
Not all of the extended keypad is used, maybe possible to replace some more of the keys on the upper row with Arabic keys?
Other characters that could be used `أإآ،`

and again THANKS
mamado is offline   Reply With Quote
Old 02-10-2015, 09:57 PM   #22
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
Quote:
Originally Posted by mamado View Post
The on-the-fly search results while searching, and the search string in the results page are unreadable, may be they need the same change you did before with changing italic to normal.
I've updated the patch in post #17 to remove italics from the search string and the title displayed in the book details view (reached by long-pressing on the book in the library view and selecting Details from the popup menu.)

Unfortunately I can't find how to remove italics from the items in the pick list that pops up while entering the search string.
GeoffR is offline   Reply With Quote
Old 02-10-2015, 11:17 PM   #23
Rnway
Junior Member
Rnway began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jan 2015
Device: Kobo Aura H2O
I can confirm that the custom dictionary patch is working excellently!

Thanks for incorporating it!
Rnway is offline   Reply With Quote
Old 02-11-2015, 11:18 PM   #24
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
Hebrew keyboard patch

This patch replaces most of the extended Latin keys on with Hebrew ones:

Spoiler:
Code:
<Patch>
patch_name = `Hebrew keyboard`
patch_enable = `no`
# Replace layout sign
replace_bytes = D6C4F8, C3 89 C3 80 C3 87, D7 90 D7 91 00 00
# Change keyboard layout
base_address = D6C418
# Top row
replace_bytes = 0000, C3 A6, 40 00
replace_bytes = 0030, C5 93, 2C 00
# Second row
replace_bytes = 0004, C3 A0, 27 00
replace_bytes = 0008, C3 A8, 2F 00
replace_bytes = 000C, C3 AC, D7 A7
replace_bytes = 0010, C3 B2, D7 A8
replace_bytes = 0014, C3 B9, D7 90
replace_bytes = 0018, C3 A1, D7 98
replace_bytes = 001C, C3 A9, D7 95
replace_bytes = 0020, C3 AD, D7 9F
replace_bytes = 0024, C3 B3, D7 9D
replace_bytes = 0028, C3 BA, D7 A4
replace_bytes = 002C, C3 BD, 2D 00
# Third row
replace_bytes = 0034, C3 A2, D7 A9
replace_bytes = 0038, C3 AA, D7 93
replace_bytes = 003C, C3 AE, D7 92
replace_bytes = 0040, C3 B4, D7 9B
replace_bytes = 0044, C3 BB, D7 A2
replace_bytes = 0048, C3 A4, D7 99
replace_bytes = 004C, C3 AB, D7 97
replace_bytes = 0050, C3 AF, D7 9C
replace_bytes = 0054, C3 B6, D7 9A
replace_bytes = 0058, C3 BC, D7 A3
replace_bytes = 005C, C3 BF, 5F 00
# Bottom row
replace_bytes = 0060, C3 A3, D7 96
replace_bytes = 0064, C3 B1, D7 A1
replace_bytes = 0068, C3 B5, D7 91
replace_bytes = 006C, C3 A5, D7 94
replace_bytes = 0070, C3 9F, D7 A0
replace_bytes = 0074, C3 A7, D7 9E
replace_bytes = 0078, C4 91, D7 A6
replace_bytes = 007C, C3 B8, D7 AA
replace_bytes = 0080, C4 B3, D7 A5
replace_bytes = 0084, C5 82, 2E 00
</Patch>


The Hebrew keys won't show immediately after the device restarts, it is necessary to open a book and access the font (Aa) menu to make the Hebrew glyphs available to the rest of the UI.
GeoffR is offline   Reply With Quote
Old 02-14-2015, 03:13 PM   #25
rogerinnyc
Addict
rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.rogerinnyc ought to be getting tired of karma fortunes by now.
 
Posts: 227
Karma: 944808
Join Date: Apr 2009
Device: Kobo Libra 2, Forma and Aura One; Kindle Voyage; Galaxy Note 10
Thanks, as always, for the timely patches, GeoffR.
I'm struggling with adjusting the top margin patch.
First, will it work with Kepubs converted through Calibre's Extended Touch Driver, or am I wasting my time playing with the patch settings?
Second, if I want a smaller header, I'm not sure what to do with this:

# Normal reading mode: 5px (Touch/Mini), 6px (Glo/Aura), 8px (AuraHD/H2O)
# Full-screen reading mode: 6px (Touch/Mini), 7px (Glo/Aura), 10px (AuraHD/H2O)
replace_int = 51EB9E, 1, 6

Do I change the 1 or the 6 in the last line? When I tried that, the compilation failed on that precise line. Or something else?

EDIT: OK, it looks like this was answered near the end of the 3.12.0 patch thread -- you can't change the top margins in kepubs. Sigh.

Last edited by rogerinnyc; 02-14-2015 at 05:16 PM. Reason: Answer Found
rogerinnyc is offline   Reply With Quote
Old 02-17-2015, 01:16 PM   #26
xPrzybyLx
Junior Member
xPrzybyLx began at the beginning.
 
Posts: 9
Karma: 10
Join Date: Feb 2015
Device: Kobo Aura HD
Great set of patches - Thank You !

I already installed few of them.
xPrzybyLx is offline   Reply With Quote
Old 02-19-2015, 02:39 AM   #27
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
`KePub zero body margin/padding` patch

This patch is a work-around for the problem where the text of some KePubs gets shifted to the right and cut off at the right margin in full-screen reading mode. It adds the following clause to the device's built-in KePub stylesheet:
Code:
body{margin:0!important;padding:0!important}
Spoiler:
Code:
<Patch>
patch_name = `KePub zero body margin/padding`
patch_enable = `yes`
# Multi-version patch: 3.12.0 - 3.13.1+
#
# This patch adds the following to the built-in KePub stylesheet:
#
#   body{margin:0!important;padding:0!important}
#
# which solves the problem with the text of some KePubs being shifted to the
# right and cut off at the right margin in full-screen reading mode.
#
find_base_address = `\t\0.\0K\0B\0S\0t\0a\0c\0k\0K\0e\0y\0w\0o\0r\0d\0[\0w\0r\0i\0t\0i\0n\0g\0M\0o\0d\0e\0=\0"\0v\0e\0r\0t\0i\0c\0a\0l\0-\0r\0l\0"\0]\0`
#
replace_string = 0000, `\t\0.\0K\0B\0S\0t\0a\0c\0k\0K\0e\0y\0w\0o\0r\0d\0[\0w\0r\0i\0t\0i\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\0e\0d\0[\0w\0r\0i\0t\0i\0n\0g\0M\0o\0d\0e\0=\0"\0v\0e\0r\0t\0i\0c\0a\0l\0-\0l\0r\0"\0]\0 \0{\0 \0b\0o\0r\0d\0e\0r\0-\0l\0e\0f\0t\0:\0 \02\0p\0x\0 \0d\0o\0t\0t\0e\0d\0 \0b\0l\0a\0c\0k\0 \0!\0i\0m\0p\0o\0r\0t\0a\0n\0t\0;\0 \0}\0 \0\t\0`, `r\0t\0i\0c\0a\0l\0-\0l\0r\0"\0]\0,\0.\0K\0B\0A\0u\0t\0h\0o\0r\0A\0n\0n\0o\0t\0a\0t\0i\0o\0n\0C\0o\0n\0t\0i\0n\0u\0e\0d\0[\0w\0r\0i\0t\0i\0n\0g\0M\0o\0d\0e\0=\0"\0v\0e\0r\0t\0i\0c\0a\0l\0-\0l\0r\0"\0]\0{\0b\0o\0r\0d\0e\0r\0-\0l\0e\0f\0t\0:\02\0p\0x\0 \0d\0o\0t\0t\0e\0d\0 \0b\0l\0a\0c\0k\0!\0i\0m\0p\0o\0r\0t\0a\0n\0t\0}\0b\0o\0d\0y\0{\0m\0a\0r\0g\0i\0n\0:\00\0!\0i\0m\0p\0o\0r\0t\0a\0n\0t\0;\0p\0a\0d\0d\0i\0n\0g\0:\00\0!\0i\0m\0p\0o\0r\0t\0a\0n\0t\0}\0`
#
# The body rule inserted above takes effect in normal reading mode too, which
# interferes with another rule used to set the user margins in normal reading
# mode. To prevent that happening, the following change is made to increase the
# priority of the user margin setting rule:
#
#     body { margin: 0px %1% 0px %2% ! important;}\n
# --> html body{margin:0px %1% 0px %2%!important;}\n
#
find_base_address = `b\0o\0d\0y\0 \0{\0 \0m\0a\0r\0g\0i\0n\0:\0 \00\0p\0x\0 \0%\01\0%\0`
#
replace_string = 0000, `b\0o\0d\0y\0 \0{\0 \0m\0a\0r\0g\0i\0n\0:\0 \00\0p\0x\0 \0%\01\0%\0 \00\0p\0x\0 \0%\02\0%\0 \0!\0 \0i\0`, `h\0t\0m\0l\0 \0b\0o\0d\0y\0{\0m\0a\0r\0g\0i\0n\0:\00\0p\0x\0 \0%\01\0%\0 \00\0p\0x\0 \0%\02\0%\0!\0i\0`
</Patch>


You may not need this patch if you only read sideloaded kepubs, as you can add the above line to the book's CSS instead, by using the kobo_extra.css feature of the KoboTouch driver in Calibre for example.

BEWARE that this patch prevents the margin adjustment slider working for KePubs in normal reading mode! So it is probably only useful to those who read Kobo-synced KePubs and always read them in full-screen mode. (It doesn't have any effect on ePubs in either reading mode.)

Edit: I have updated this patch, the new one no longer prevents kepub margin changes in normal reading mode.

If you use this patch, make sure to add it to libnickel.so.1.0.0.patch so that it comes after the `Fix kepub side bearing font cut-off bug` patch.

Attached are screenshots from my Glo showing a Kobo synced KePub affected by this problem (this one) in full-screen mode with and without this patch.
Attached Thumbnails
Click image for larger version

Name:	unpatched.png
Views:	709
Size:	59.0 KB
ID:	135014   Click image for larger version

Name:	patched.png
Views:	692
Size:	60.6 KB
ID:	135015  

Last edited by GeoffR; 02-23-2015 at 06:26 AM. Reason: Improved patch, no longer prevents kepub margin changes in normal reading mode.
GeoffR is offline   Reply With Quote
Old 02-19-2015, 10:04 AM   #28
GERGE
Guru
GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.GERGE ought to be getting tired of karma fortunes by now.
 
Posts: 733
Karma: 5797160
Join Date: Jun 2010
Location: Istanbul
Device: Kobo Libra
How can I make a Turkish keyboard? Kobo is the most popular reader here, it would help people.
GERGE is offline   Reply With Quote
Old 02-19-2015, 04:13 PM   #29
barobach_so
Connoisseur
barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.barobach_so knows what's going on.
 
Posts: 76
Karma: 25460
Join Date: Feb 2015
Device: kobo h2o
Quote:
Originally Posted by GeoffR View Post
This patch replaces the keyboard's extended Latin characters with Arabic ones:

Spoiler:
Code:
<Patch>
patch_name = `Arabic keyboard`
patch_enable = `yes`
# Replace layout sign
replace_bytes = D6C4F8, C3 89 C3 80 C3 87, D8 B9 00 00 00 00
# Change keyboard layout
base_address = D6C418
# Top row
replace_bytes = 0000, C3 A6, D8 B0
replace_bytes = 0030, C5 93, D8 B6
# Second row
replace_bytes = 0004, C3 A0, D8 B5
replace_bytes = 0008, C3 A8, D8 AB
replace_bytes = 000C, C3 AC, D9 82
replace_bytes = 0010, C3 B2, D9 81
replace_bytes = 0014, C3 B9, D8 BA
replace_bytes = 0018, C3 A1, D8 B9
replace_bytes = 001C, C3 A9, D9 87
replace_bytes = 0020, C3 AD, D8 AE
replace_bytes = 0024, C3 B3, D8 AD
replace_bytes = 0028, C3 BA, D8 AC
replace_bytes = 002C, C3 BD, D8 AF
# Third row
replace_bytes = 0034, C3 A2, D8 B4
replace_bytes = 0038, C3 AA, D8 B3
replace_bytes = 003C, C3 AE, D9 8A
replace_bytes = 0040, C3 B4, D8 A8
replace_bytes = 0044, C3 BB, D9 84
replace_bytes = 0048, C3 A4, D8 A7
replace_bytes = 004C, C3 AB, D8 AA
replace_bytes = 0050, C3 AF, D9 86
replace_bytes = 0054, C3 B6, D9 85
replace_bytes = 0058, C3 BC, D9 83
replace_bytes = 005C, C3 BF, D8 B7
# Bottom row
replace_bytes = 0060, C3 A3, D8 A6
replace_bytes = 0064, C3 B1, D8 A1
replace_bytes = 0068, C3 B5, D8 A4
replace_bytes = 006C, C3 A5, D8 B1
replace_bytes = 0070, C3 9F, D9 89
replace_bytes = 0074, C3 A7, D8 A9
replace_bytes = 0078, C4 91, D9 88
replace_bytes = 007C, C3 B8, D8 B2
replace_bytes = 0080, C4 B3, D8 B8
replace_bytes = 0084, C5 82, 2E 00
</Patch>


After a device restart the Arabic glyphs won't display properly until a book has been opened and the font menu (Aa) accessed.

The shift key doesn't do anything to the Arabic keys, is that a fault or doesn't Arabic have upper and lower cases?

Not all of the extended keypad is used, maybe possible to replace some more of the keys on the upper row with Arabic keys?
hi

is there a way to have both keyboards ?
and have a swift key ?
barobach_so is offline   Reply With Quote
Old 02-19-2015, 04:45 PM   #30
flip1314
Member
flip1314 began at the beginning.
 
Posts: 15
Karma: 14
Join Date: Feb 2015
Location: Halifax, NS
Device: Kobo Aura HD & Kobo Aura
I am getting this error when I try to run the .sh in ubuntu. Could you suggest a reason?

gzip: stdin: unexpected end of file
tar: Child returned status 1
tar: Error is not recoverable: exiting now
Cleaning up /tmp/patch32lsb_om33A6Kv
flip@flip-MacBookAir:~/Downloads/patch_kobo_3121$

I have confirmed the zip of the update and it is valid. Not sure what else could be the problem.
flip1314 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Instructions for patching firmware 3.11.0 GeoffR Kobo Developer's Corner 226 06-01-2015 06:32 AM
Instructions for patching firmware 3.2.0 DNSB Kobo Developer's Corner 66 12-05-2014 08:28 AM
Instructions for patching firmware 3.8.0 GeoffR Kobo Developer's Corner 92 10-22-2014 08:22 AM
Instructions for patching firmware 3.3.x, 3.4.x, 3.5.x GeoffR Kobo Developer's Corner 285 08-27-2014 11:06 AM
Instructions for patching firmware 3.1.1 GeoffR Kobo Developer's Corner 64 04-18-2014 02:23 PM


All times are GMT -4. The time now is 09:16 AM.


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