Thread Tools Display Modes
Prev Previous Post   Next Post Next
10-25-15, 05:02 PM   #1
MunkDev
A Scalebane Royal Guard
 
MunkDev's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2015
Posts: 431
Translating keyboard layout

Hello. I need help translating keyboard layouts for my new keyboard module in ConsolePort.
The only languages I have so far are Swedish and English.
This is what it looks like:

  • A language table contains 8 sets of 4 buttons, each having 4 strings inside.
  • To swap the character sets, the user holds down L1 or L2 or L1 and L2 together.
  • The keyboard module defaults to the second string.
  • The sets are rendered clockwise.
  • Inside a set, the rendering order is counterclockwise.
This is what the table for English looks like:

Lua Code:
  1. -- Lua format
  2. Language.English = {
  3.     [1] = {
  4.         {"A", "a", "1", "/s"},
  5.         {"B", "b", "2", "/p"},
  6.         {"C", "c", "3", "/i"},
  7.         {"D", "d", "4", "/g"},
  8.     },
  9.     [2] = {
  10.         {"E", "e", "5", "/y"},
  11.         {"F", "f", "6", "/w"},
  12.         {"G", "g", "7", "/e"},
  13.         {"H", "h", "8", "/r"},
  14.     },
  15.     [3] = {
  16.         {"I", "i", "9", "´"},
  17.         {"J", "j", "<", "^"},
  18.         {"K", "k", "0", "`"},
  19.         {"L", "l", ">", "¨"},
  20.     },
  21.     [4] = {
  22.         {"M", "m", "@", "¤"},
  23.         {"N", "n", "&", "#"},
  24.         {"O", "o", "$", "€"},
  25.         {"P", "p", "%", "£"},
  26.     },
  27.     [5] = {
  28.         {"Q", "q", "/", "½"},
  29.         {"R", "r", "(", "["},
  30.         {"S", "s", "\\", "\|"},
  31.         {"T", "t", ")", "]"},
  32.     },
  33.     [6] = {
  34.         {"U", "u", "+", "§"},
  35.         {"V", "v", "*", "{"},
  36.         {"W", "w", "=", "¿"},
  37.         {"X", "x", "/", "}"},
  38.     },
  39.     [7] = {
  40.         {"Y", "y", "{rt1}", "{rt1}"},
  41.         {"Z", "z", "{rt2}", "{rt2}"},
  42.         {"\"", "'", "{rt3}", "{rt3}"},
  43.         {"_", "-", "{rt4}", "{rt4}"},
  44.     },
  45.     [8] = {
  46.         {"!", "!", "{rt5}", "{rt5}"},
  47.         {":", ".", "{rt6}", "{rt6}"},
  48.         {":", ",", "{rt7}", "{rt7}"},
  49.         {"?", "?", "{rt8}", "{rt8}"},
  50.     },
  51. }
  52.  
  53. --[[ Readable format
  54. A    a   1   /s
  55. B    b   2   /p
  56. C    c   3   /i
  57. D    d   4   /g
  58.  
  59. E    e   5   /y
  60. F    f   6   /w
  61. G    g   7   /e
  62. H    h   8   /r
  63.  
  64. I    i   9   ´
  65. J    j   <   ^
  66. K    k   0   `
  67. L    l   >   ¨
  68.  
  69. M    m   @   ¤
  70. N    n   &   #
  71. O    o   $   €
  72. P    p   %   £
  73.  
  74. Q    q   /   ½
  75. R    r   (   [
  76. S    s   \   |
  77. T    t   )   ]
  78.  
  79. U    u   +   §
  80. V    v   *   {
  81. W    w   =   ¿
  82. X    x   /   }
  83.  
  84. Y    y   {rt1}   {rt1}
  85. Z    z   {rt2}   {rt2}
  86. "    '   {rt3}   {rt3}
  87. _    -   {rt4}   {rt4}
  88.  
  89. !    !   {rt5}   {rt5}
  90. :    .   {rt6}   {rt6}
  91. :    ,   {rt7}   {rt7}
  92. ?    ?   {rt8}   {rt8}
  93. ]]--
Note: {rtX} are raid markers.
__________________

Last edited by MunkDev : 10-26-15 at 09:36 PM.
  Reply With Quote
 

WoWInterface » AddOns, Compilations, Macros » UI Screenshots, Feedback and Design Discussion » Translating keyboard layout

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off