mirror of
https://github.com/koreader/koreader
synced 2024-11-16 06:12:56 +00:00
c1be488a11
dofile() wasn't enough to copy en_keyboard, as the references to key popups would still be shared, and hacks to them (as done by the FR keyboard) would be active on the EN keyboard. Also, for the FR Keyboard: - bring M key popup too when moving it to 2nd row. - keep original ',' and '.' as on EN keyboard. - add ';' instead of ',' as the added key, and let it have some key popup too, with keys helpful when CSS editing.
16 lines
521 B
Lua
16 lines
521 B
Lua
-- Start with the english keyboard layout (deep copy, to not alter it)
|
|
local es_keyboard = require("util").tableDeepCopy(require("ui/data/keyboardlayouts/en_keyboard"))
|
|
|
|
local keys = es_keyboard.keys
|
|
|
|
-- Insert an additional key at the end of 2nd row for easy Ñ and ñ
|
|
table.insert(keys[2],
|
|
-- 1 2 3 4 5 6 7 8
|
|
{ "Ñ", "ñ", "Ñ", "ñ", "Ñ", "ñ", "Ñ", "ñ", }
|
|
)
|
|
|
|
-- Rename "space"
|
|
keys[4][4].label = "espacio"
|
|
|
|
return es_keyboard
|