View Single Post
Old 05-15-2017, 01:31 AM   #49
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
Keyboard patches (Glo)

Here are some keyboard patches for the Glo, they should also change the keys on other devices but I'm not sure whether they will be arranged in the right order.

Hopefully others can confirm whether it suits other devices too, or else work off the notes in this example to create new patches for those devices.

`Cyrillic keyboard` (paste into libnickel.so.1.0.0.patch):
Spoiler:
Code:
<Patch>
patch_name = `Cyrillic keyboard`
patch_enable = `no`
# patch_group = `Keyboard alternatives`
#
## Replaces keys on the Extended Latin keypad with Cyrillic alternatives.
##
## Note that after the device boots, the keypad might just show blank squares
## until after the first book has been opened.
##
## Also note that long-pressing keys on the base keypad will no longer show
## the appropriate list of Extended Latin keys.
#
# Enable uppercase for `ß` key
replace_bytes = 708434, 00 26, 01 26
# Enable uppercase for `ƒ` key
#replace_bytes = 708414, 80 F0 01 00, 01 20 01 20
#
# Replace layout sign
find_base_address = `ÉÀÇ`
replace_string = 0000, `ÉÀÇ`, `абв`
#
# Change keyboard keys (1- or 2-byte characters only)
# Row positions based on Glo, might be different for other devices:
find_base_address = `ý\0ÿ\0š\0ž\0`
# Top row, left to right (10 keys):
replace_string = 000C, `æ`, `й`
replace_string = 000F, `œ`, `ф`
replace_string = 0012, `þ`, `þ`
replace_string = 0006, `š`, `š`
replace_string = 0009, `ž`, `ž`
replace_string = 0018, `ŀ`, `ŀ`
replace_string = FFFFFF8C, `ƒ`, `ƒ`
replace_string = 001B, `μ`, `μ`
replace_string = 001E, `ª`, `ª`
replace_string = 0021, `º`, `º`
# Second row, left to right (11 keys):
replace_string = 0024, `à`, `ц`
replace_string = 0036, `è`, `у`
replace_string = 0042, `ì`, `к`
replace_string = 0045, `ò`, `е`
replace_string = 0048, `ù`, `н`
replace_string = 0027, `á`, `г`
replace_string = 0039, `é`, `ш`
replace_string = 004B, `í`, `щ`
replace_string = 004E, `ó`, `з`
replace_string = 0051, `ú`, `х`
replace_string = 0000, `ý`, `ъ`
# Third row, left to right (11 keys):
replace_string = 002A, `â`, `ы`
replace_string = 003C, `ê`, `в`
replace_string = 0060, `î`, `а`
replace_string = 0054, `ô`, `п`
replace_string = 0066, `û`, `р`
replace_string = 002D, `ä`, `о`
replace_string = 003F, `ë`, `л`
replace_string = 0063, `ï`, `д`
replace_string = 0057, `ö`, `ж`
replace_string = 0069, `ü`, `э`
replace_string = 0003, `ÿ`, `ё`
# Bottom row, left to right (10 keys):
replace_string = 0030, `ã`, `я`
replace_string = 006C, `ñ`, `ч`
replace_string = 005A, `õ`, `с`
replace_string = 0033, `å`, `м`
replace_string = FFFFFF89, `ß`, `и`
replace_string = 006F, `ç`, `т`
replace_string = 0072, `đ`, `ь`
replace_string = 005D, `ø`, `б`
replace_string = 0015, `ij`, `ю`
replace_string = 0075, `ł`, `.`
</Patch>

`Arabic keyboard` (paste into libnickel.so.1.0.0.patch):
Spoiler:
Code:
<Patch>
patch_name = `Arabic keyboard`
patch_enable = `no`
# Multi-version patch: 4.4.9298+
# patch_group = `Keyboard alternatives`
#
## Replaces keys on the Extended Latin keypad with Arabic alternatives.
##
## Note that after the device boots, the keypad might just show blank squares
## until after the first book has been opened.
##
## Also note that long-pressing keys on the base keypad will no longer show
## the appropriate list of Extended Latin keys.
#
# Enable uppercase for `ß` key
#replace_bytes = 708434, 00 26, 01 26
# Enable uppercase for `ƒ` key
#replace_bytes = 708414, 80 F0 01 00, 01 20 01 20
# Replace layout sign
find_base_address = `ÉÀÇ`
replace_string = 0000, `ÉÀÇ`, `ع`
# Change keyboard layout
find_base_address = `ý\0ÿ\0š\0ž\0`
# Top row, left to right (10 keys):
replace_string = 000C, `æ`, `ذ`
replace_string = 000F, `œ`, `ض`
replace_string = 0012, `þ`, `þ`
replace_string = 0006, `š`, `š`
replace_string = 0009, `ž`, `ž`
replace_string = 0018, `ŀ`, `ŀ`
replace_string = FFFFFF8C, `ƒ`, `ƒ`
replace_string = 001B, `μ`, `μ`
replace_string = 001E, `ª`, `ª`
replace_string = 0021, `º`, `º`
# Second row, left to right (11 keys):
replace_string = 0024, `à`, `ص`
replace_string = 0036, `è`, `ث`
replace_string = 0042, `ì`, `ق`
replace_string = 0045, `ò`, `ف`
replace_string = 0048, `ù`, `غ`
replace_string = 0027, `á`, `ع`
replace_string = 0039, `é`, `ه`
replace_string = 004B, `í`, `خ`
replace_string = 004E, `ó`, `ح`
replace_string = 0051, `ú`, `ج`
replace_string = 0000, `ý`, `د`
# Third row, left to right (11 keys):
replace_string = 002A, `â`, `ش`
replace_string = 003C, `ê`, `س`
replace_string = 0060, `î`, `ي`
replace_string = 0054, `ô`, `ب`
replace_string = 0066, `û`, `ل`
replace_string = 002D, `ä`, `ا`
replace_string = 003F, `ë`, `ت`
replace_string = 0063, `ï`, `ن`
replace_string = 0057, `ö`, `م`
replace_string = 0069, `ü`, `ك`
replace_string = 0003, `ÿ`, `ط`
# Bottom row, left to right (10 keys):
replace_string = 0030, `ã`, `ئ`
replace_string = 006C, `ñ`, `ء`
replace_string = 005A, `õ`, `ؤ`
replace_string = 0033, `å`, `ر`
replace_string = FFFFFF89, `ß`, `ى`
replace_string = 006F, `ç`, `ة`
replace_string = 0072, `đ`, `و`
replace_string = 005D, `ø`, `ز`
replace_string = 0015, `ij`, `ظ`
replace_string = 0075, `ł`, `.`
</Patch>

Edit: I'll add more keyboard patches to this post when I get time.

Last edited by GeoffR; 05-15-2017 at 03:12 AM. Reason: Removed `Hebrew keyboard`, see oren64's post below.
GeoffR is offline   Reply With Quote