First pass at packaging for Harmattan
[ejpi] / ejpi / plugins / alphabet.py
1 """
2 Keyboard Origin:
3
4 qwe rtyu iop
5 as dfghj kl
6 zxc vb nm
7
8 e t i
9 a h l
10 c b n
11 """
12
13 from __future__ import division
14
15 import os
16
17 from ejpi import plugin_utils
18
19
20 _NAME = "Alphabet"
21 _ICON = "alphabet.png"
22 _MAP = {
23         "name": _NAME,
24         "keys": {
25                 (0, 0): {
26                         "CENTER": {"action": "e", "type": "text", "text": "E", },
27                         "SOUTH": {"action": "q", "type": "text", "text": "Q", },
28                         "EAST": {"action": "w", "type": "text", "text": "W", },
29                         "showAllSlices": True,
30                 },
31                 (0, 1): {
32                         "CENTER": {"action": "t", "type": "text", "text": "T", },
33                         "WEST": {"action": "r", "type": "text", "text": "R", },
34                         "EAST": {"action": "y", "type": "text", "text": "Y", },
35                         "SOUTH": {"action": "u", "type": "text", "text": "U", },
36                         "showAllSlices": True,
37                 },
38                 (0, 2): {
39                         "CENTER": {"action": "i", "type": "text", "text": "I", },
40                         "WEST": {"action": "o", "type": "text", "text": "O", },
41                         "SOUTH": {"action": "p", "type": "text", "text": "P", },
42                         "showAllSlices": True,
43                 },
44                 (1, 0): {
45                         "CENTER": {"action": "a", "type": "text", "text": "A", },
46                         "EAST": {"action": "s", "type": "text", "text": "S", },
47                         "showAllSlices": True,
48                 },
49                 (1, 1): {
50                         "CENTER": {"action": "h", "type": "text", "text": "H", },
51                         "WEST": {"action": "d", "type": "text", "text": "D", },
52                         "NORTH": {"action": "f", "type": "text", "text": "F", },
53                         "EAST": {"action": "g", "type": "text", "text": "G", },
54                         "SOUTH": {"action": "j", "type": "text", "text": "J", },
55                         "showAllSlices": True,
56                 },
57                 (1, 2): {
58                         "CENTER": {"action": "l", "type": "text", "text": "L", },
59                         "WEST": {"action": "k", "type": "text", "text": "K", },
60                         "showAllSlices": True,
61                 },
62                 (2, 0): {
63                         "CENTER": {"action": "c", "type": "text", "text": "C", },
64                         "NORTH": {"action": "z", "type": "text", "text": "Z", },
65                         "EAST": {"action": "x", "type": "text", "text": "X", },
66                         "showAllSlices": True,
67                 },
68                 (2, 1): {
69                         "CENTER": {"action": "b", "type": "text", "text": "B", },
70                         "NORTH": {"action": "v", "type": "text", "text": "V", },
71                         "showAllSlices": True,
72                 },
73                 (2, 2): {
74                         "CENTER": {"action": "n", "type": "text", "text": "N", },
75                         "NORTH_WEST": {"action": "m", "type": "text", "text": "M", },
76                         "showAllSlices": True,
77                 },
78         },
79 }
80 _ICON_PATH = [os.path.join(os.path.dirname(__file__), "images")]
81 PLUGIN = plugin_utils.PieKeyboardPluginFactory(_NAME, _ICON, _MAP, _ICON_PATH)