Ticket #5483: tkmythremote

File tkmythremote, 12.7 KB (added by Tony Lill <ajlill@…>, 16 years ago)
Line 
1Index: contrib/tkmythremote/pixmaps/left.xbm
2===================================================================
3--- contrib/tkmythremote/pixmaps/left.xbm       (revision 0)
4+++ contrib/tkmythremote/pixmaps/left.xbm       (revision 0)
5@@ -0,0 +1,8 @@
6+#define noname_width 21
7+#define noname_height 21
8+static char noname_bits[] = {
9+ 0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0xe0,0x00,0x00,0xf0,0x00,0x00,0xf8,0x00,
10+ 0x00,0xfc,0x00,0x00,0xfe,0x00,0x00,0xff,0x00,0x80,0xff,0x00,0xc0,0xff,0x00,
11+ 0xe0,0xff,0x00,0xc0,0xff,0x00,0x80,0xff,0x00,0x00,0xff,0x00,0x00,0xfe,0x00,
12+ 0x00,0xfc,0x00,0x00,0xf8,0x00,0x00,0xf0,0x00,0x00,0xe0,0x00,0x00,0xc0,0x00,
13+ 0x00,0x00,0x00};
14Index: contrib/tkmythremote/pixmaps/m.xbm
15===================================================================
16--- contrib/tkmythremote/pixmaps/m.xbm  (revision 0)
17+++ contrib/tkmythremote/pixmaps/m.xbm  (revision 0)
18@@ -0,0 +1,9 @@
19+#define m_width 21
20+#define m_height 21
21+static unsigned char m_bits[] = {
22+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x06, 0x1c, 0x00, 0x07,
23+ 0x3c, 0x80, 0x07, 0x6c, 0xc0, 0x06, 0xcc, 0x60, 0x06, 0x8c, 0x31, 0x06,
24+ 0x0c, 0x1b, 0x06, 0x0c, 0x0e, 0x06, 0x0c, 0x04, 0x06, 0x0c, 0x00, 0x06,
25+ 0x0c, 0x00, 0x06, 0x0c, 0x00, 0x06, 0x0c, 0x00, 0x06, 0x0c, 0x00, 0x06,
26+ 0x0c, 0x00, 0x06, 0x0c, 0x00, 0x06, 0x0c, 0x00, 0x06, 0x00, 0x00, 0x00,
27+ 0x00, 0x00, 0x00 } ;
28Index: contrib/tkmythremote/pixmaps/dleft.xbm
29===================================================================
30--- contrib/tkmythremote/pixmaps/dleft.xbm      (revision 0)
31+++ contrib/tkmythremote/pixmaps/dleft.xbm      (revision 0)
32@@ -0,0 +1,8 @@
33+#define noname_width 21
34+#define noname_height 21
35+static char noname_bits[] = {
36+ 0x00,0x00,0x00,0x00,0x04,0x08,0x00,0x06,0x0c,0x00,0x07,0x0e,0x80,0x07,0x0f,
37+ 0xc0,0x87,0x0f,0xe0,0xc7,0x0f,0xf0,0xe7,0x0f,0xf8,0xf7,0x0f,0xfc,0xff,0x0f,
38+ 0xfe,0xff,0x0f,0xfc,0xff,0x0f,0xf8,0xf7,0x0f,0xf0,0xe7,0x0f,0xe0,0xc7,0x0f,
39+ 0xc0,0x87,0x0f,0x80,0x07,0x0f,0x00,0x07,0x0e,0x00,0x06,0x0c,0x00,0x04,0x08,
40+ 0x00,0x00,0x00};
41Index: contrib/tkmythremote/pixmaps/p.xbm
42===================================================================
43--- contrib/tkmythremote/pixmaps/p.xbm  (revision 0)
44+++ contrib/tkmythremote/pixmaps/p.xbm  (revision 0)
45@@ -0,0 +1,9 @@
46+#define p_width 21
47+#define p_height 21
48+static unsigned char p_bits[] = {
49+ 0x00, 0x00, 0x00, 0xee, 0x04, 0x00, 0xee, 0x0c, 0x00, 0xee, 0x1c, 0x00,
50+ 0xee, 0x3c, 0x00, 0xee, 0x7c, 0x00, 0xee, 0xfc, 0x00, 0xee, 0xfc, 0x01,
51+ 0xee, 0xfc, 0x03, 0xee, 0xfc, 0x07, 0xee, 0xfc, 0x0f, 0xee, 0xfc, 0x07,
52+ 0xee, 0xfc, 0x03, 0xee, 0xfc, 0x01, 0xee, 0xfc, 0x00, 0xee, 0x7c, 0x00,
53+ 0xee, 0x3c, 0x00, 0xee, 0x1c, 0x00, 0xee, 0x0c, 0x00, 0xee, 0x04, 0x00,
54+ 0x00, 0x00, 0x00 } ;
55Index: contrib/tkmythremote/pixmaps/q.xbm
56===================================================================
57--- contrib/tkmythremote/pixmaps/q.xbm  (revision 0)
58+++ contrib/tkmythremote/pixmaps/q.xbm  (revision 0)
59@@ -0,0 +1,9 @@
60+#define q_width 21
61+#define q_height 21
62+static unsigned char q_bits[] = {
63+ 0x00, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x80, 0x3f, 0x00, 0xc0, 0x60, 0x00,
64+ 0x60, 0xc0, 0x00, 0x30, 0x80, 0x01, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03,
65+ 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03,
66+ 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x30, 0x78, 0x01, 0x60, 0xc0, 0x01,
67+ 0xc0, 0xc0, 0x01, 0x80, 0x7f, 0x03, 0x00, 0x3f, 0x0e, 0x00, 0x00, 0x00,
68+ 0x00, 0x00, 0x00 } ;
69Index: contrib/tkmythremote/pixmaps/down.xbm
70===================================================================
71--- contrib/tkmythremote/pixmaps/down.xbm       (revision 0)
72+++ contrib/tkmythremote/pixmaps/down.xbm       (revision 0)
73@@ -0,0 +1,8 @@
74+#define noname_width 21
75+#define noname_height 21
76+static char noname_bits[] = {
77+ 0x01,0x00,0x00,0x01,0x00,0x00,0x01,0x00,0x00,0x01,0x00,0x00,0x01,0x00,0x00,
78+ 0xfd,0xff,0x1f,0xfd,0xff,0x1f,0xf9,0xff,0x0f,0xf1,0xff,0x07,0xe1,0xff,0x03,
79+ 0xc1,0xff,0x01,0x81,0xff,0x00,0x01,0x7f,0x00,0x01,0x3e,0x00,0x01,0x1c,0x00,
80+ 0x01,0x08,0x00,0x01,0x00,0x00,0x01,0x00,0x00,0x01,0x00,0x00,0x01,0x00,0x00,
81+ 0x01,0x00,0x00};
82Index: contrib/tkmythremote/pixmaps/esc.xbm
83===================================================================
84--- contrib/tkmythremote/pixmaps/esc.xbm        (revision 0)
85+++ contrib/tkmythremote/pixmaps/esc.xbm        (revision 0)
86@@ -0,0 +1,9 @@
87+#define esc_width 21
88+#define esc_height 21
89+static unsigned char esc_bits[] = {
90+ 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x1f, 0x00,
91+ 0x80, 0x3f, 0x00, 0xc0, 0x7f, 0x00, 0xe0, 0xff, 0x00, 0xf0, 0xff, 0x01,
92+ 0xf8, 0xff, 0x03, 0xfc, 0xff, 0x07, 0xfe, 0xff, 0x0f, 0x00, 0x00, 0x00,
93+ 0x00, 0x00, 0x00, 0xfe, 0xff, 0x0f, 0xfe, 0xff, 0x0f, 0xfe, 0xff, 0x0f,
94+ 0xfe, 0xff, 0x0f, 0xfe, 0xff, 0x0f, 0xfe, 0xff, 0x0f, 0x00, 0x00, 0x00,
95+ 0x00, 0x00, 0x00 } ;
96Index: contrib/tkmythremote/pixmaps/ddown.xbm
97===================================================================
98--- contrib/tkmythremote/pixmaps/ddown.xbm      (revision 0)
99+++ contrib/tkmythremote/pixmaps/ddown.xbm      (revision 0)
100@@ -0,0 +1,8 @@
101+#define noname_width 21
102+#define noname_height 21
103+static char noname_bits[] = {
104+ 0x01,0x00,0x00,0xfd,0xff,0x1f,0xf9,0xff,0x0f,0xf1,0xff,0x07,0xe1,0xff,0x03,
105+ 0xc1,0xff,0x01,0x81,0xff,0x00,0x01,0x7f,0x00,0x01,0x3e,0x00,0x01,0x1c,0x00,
106+ 0xfd,0xff,0x1f,0xf9,0xff,0x0f,0xf1,0xff,0x07,0xe1,0xff,0x03,0xc1,0xff,0x01,
107+ 0x81,0xff,0x00,0x01,0x7f,0x00,0x01,0x3e,0x00,0x01,0x1c,0x00,0x01,0x08,0x00,
108+ 0x01,0x00,0x00};
109Index: contrib/tkmythremote/pixmaps/right.xbm
110===================================================================
111--- contrib/tkmythremote/pixmaps/right.xbm      (revision 0)
112+++ contrib/tkmythremote/pixmaps/right.xbm      (revision 0)
113@@ -0,0 +1,9 @@
114+#define right_width 21
115+#define right_height 21
116+static unsigned char right_bits[] = {
117+ 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xe0, 0x00, 0x00, 0xe0, 0x01, 0x00,
118+ 0xe0, 0x03, 0x00, 0xe0, 0x07, 0x00, 0xe0, 0x0f, 0x00, 0xe0, 0x1f, 0x00,
119+ 0xe0, 0x3f, 0x00, 0xe0, 0x7f, 0x00, 0xe0, 0xff, 0x00, 0xe0, 0x7f, 0x00,
120+ 0xe0, 0x3f, 0x00, 0xe0, 0x1f, 0x00, 0xe0, 0x0f, 0x00, 0xe0, 0x07, 0x00,
121+ 0xe0, 0x03, 0x00, 0xe0, 0x01, 0x00, 0xe0, 0x00, 0x00, 0x60, 0x00, 0x00,
122+ 0x00, 0x00, 0x00 } ;
123Index: contrib/tkmythremote/pixmaps/dright.xbm
124===================================================================
125--- contrib/tkmythremote/pixmaps/dright.xbm     (revision 0)
126+++ contrib/tkmythremote/pixmaps/dright.xbm     (revision 0)
127@@ -0,0 +1,9 @@
128+#define dright_width 21
129+#define dright_height 21
130+static unsigned char dright_bits[] = {
131+ 0x00, 0x00, 0x00, 0x02, 0x04, 0x00, 0x06, 0x0c, 0x00, 0x0e, 0x1c, 0x00,
132+ 0x1e, 0x3c, 0x00, 0x3e, 0x7c, 0x00, 0x7e, 0xfc, 0x00, 0xfe, 0xfc, 0x01,
133+ 0xfe, 0xfd, 0x03, 0xfe, 0xff, 0x07, 0xfe, 0xff, 0x0f, 0xfe, 0xff, 0x07,
134+ 0xfe, 0xfd, 0x03, 0xfe, 0xfc, 0x01, 0x7e, 0xfc, 0x00, 0x3e, 0x7c, 0x00,
135+ 0x1e, 0x3c, 0x00, 0x0e, 0x1c, 0x00, 0x06, 0x0c, 0x00, 0x02, 0x04, 0x00,
136+ 0x00, 0x00, 0x00 } ;
137Index: contrib/tkmythremote/pixmaps/d.xbm
138===================================================================
139--- contrib/tkmythremote/pixmaps/d.xbm  (revision 0)
140+++ contrib/tkmythremote/pixmaps/d.xbm  (revision 0)
141@@ -0,0 +1,9 @@
142+#define d_width 21
143+#define d_height 21
144+static unsigned char d_bits[] = {
145+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x3f, 0x00, 0xf8, 0x7f, 0x00,
146+ 0x18, 0xc0, 0x00, 0x18, 0x80, 0x01, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03,
147+ 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x18, 0x00, 0x03,
148+ 0x18, 0x00, 0x03, 0x18, 0x00, 0x03, 0x18, 0x00, 0x01, 0x18, 0x80, 0x01,
149+ 0x18, 0xc0, 0x00, 0xf8, 0x7f, 0x00, 0xf8, 0x3f, 0x00, 0x00, 0x00, 0x00,
150+ 0x00, 0x00, 0x00 } ;
151Index: contrib/tkmythremote/pixmaps/up.xbm
152===================================================================
153--- contrib/tkmythremote/pixmaps/up.xbm (revision 0)
154+++ contrib/tkmythremote/pixmaps/up.xbm (revision 0)
155@@ -0,0 +1,8 @@
156+#define noname_width 21
157+#define noname_height 21
158+static char noname_bits[] = {
159+ 0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
160+ 0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x0e,0x00,0x00,0x1f,0x00,0x80,0x3f,0x00,
161+ 0xc0,0x7f,0x00,0xe0,0xff,0x00,0xf0,0xff,0x01,0xf8,0xff,0x03,0xfc,0xff,0x07,
162+ 0xfe,0xff,0x0f,0xfe,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
163+ 0x00,0x00,0x00};
164Index: contrib/tkmythremote/pixmaps/ent.xbm
165===================================================================
166--- contrib/tkmythremote/pixmaps/ent.xbm        (revision 0)
167+++ contrib/tkmythremote/pixmaps/ent.xbm        (revision 0)
168@@ -0,0 +1,9 @@
169+#define ent_width 21
170+#define ent_height 21
171+static unsigned char ent_bits[] = {
172+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x80, 0x03,
173+ 0x00, 0x80, 0x03, 0x00, 0x80, 0x03, 0x00, 0x80, 0x03, 0x00, 0x80, 0x03,
174+ 0x00, 0x80, 0x03, 0x00, 0x80, 0x03, 0x00, 0x80, 0x03, 0x20, 0x80, 0x03,
175+ 0x30, 0x80, 0x03, 0x38, 0x80, 0x03, 0xfc, 0xff, 0x03, 0xfe, 0xff, 0x03,
176+ 0xfc, 0xff, 0x03, 0x38, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00,
177+ 0x00, 0x00, 0x00 } ;
178Index: contrib/tkmythremote/pixmaps/dup.xbm
179===================================================================
180--- contrib/tkmythremote/pixmaps/dup.xbm        (revision 0)
181+++ contrib/tkmythremote/pixmaps/dup.xbm        (revision 0)
182@@ -0,0 +1,8 @@
183+#define noname_width 21
184+#define noname_height 21
185+static char noname_bits[] = {
186+ 0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x0e,0x00,0x00,0x1f,0x00,
187+ 0x80,0x3f,0x00,0xc0,0x7f,0x00,0xe0,0xff,0x00,0xf0,0xff,0x01,0xf8,0xff,0x03,
188+ 0xfc,0xff,0x07,0xfe,0xff,0x0f,0x00,0x0e,0x00,0x00,0x1f,0x00,0x80,0x3f,0x00,
189+ 0xc0,0x7f,0x00,0xe0,0xff,0x00,0xf0,0xff,0x01,0xf8,0xff,0x03,0xfc,0xff,0x07,
190+ 0xfe,0xff,0x0f};
191Index: contrib/tkmythremote/pixmaps/i.xbm
192===================================================================
193--- contrib/tkmythremote/pixmaps/i.xbm  (revision 0)
194+++ contrib/tkmythremote/pixmaps/i.xbm  (revision 0)
195@@ -0,0 +1,9 @@
196+#define i_width 21
197+#define i_height 21
198+static unsigned char i_bits[] = {
199+ 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x06, 0x00,
200+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00,
201+ 0x00, 0x07, 0x00, 0x80, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00,
202+ 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00,
203+ 0x00, 0x06, 0x00, 0x00, 0x0f, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0x00,
204+ 0x00, 0x00, 0x00 } ;
205Index: contrib/tkmythremote/tkmythremote
206===================================================================
207--- contrib/tkmythremote/tkmythremote   (revision 0)
208+++ contrib/tkmythremote/tkmythremote   (revision 0)
209@@ -0,0 +1,52 @@
210+#! /usr/bin/wish
211+#
212+# I dare you to make a simpler GUI!
213+#
214+# Usage: tkmythremote frontendhost
215+
216+set host [lindex $argv 0]
217+set f [socket $host 6546]
218+fconfigure $f -blocking 0 -buffering none
219+
220+proc push {key} {
221+    global f
222+    puts $f "key $key\n"
223+    read $f
224+}
225+
226+# Create all the buttons
227+button .esc -image [image create bitmap -file "./pixmaps/esc.xbm"] -command "push escape"
228+button .play -image [image create bitmap -file "./pixmaps/p.xbm"] -command "push p"
229+button .ent -image [image create bitmap -file "./pixmaps/ent.xbm"] -command "push enter"
230+button .up -image [image create bitmap -file "./pixmaps/up.xbm"] -command "push up"
231+button .down -image [image create bitmap -file "./pixmaps/down.xbm"] -command "push down"
232+button .left -image [image create bitmap -file "./pixmaps/left.xbm"] -command "push left"
233+button .right -image [image create bitmap -file "./pixmaps/right.xbm"] -command "push right"
234+button .backcom -image [image create bitmap -file "./pixmaps/dleft.xbm"] -command "push q"
235+button .forwcom -image [image create bitmap -file "./pixmaps/dright.xbm"] -command "push z"
236+button .pgup -image [image create bitmap -file "./pixmaps/dup.xbm"] -command "push pageup"
237+button .pgdown -image [image create bitmap -file "./pixmaps/ddown.xbm"] -command "push pagedown"
238+button .quit -image [image create bitmap -file "./pixmaps/q.xbm"] -command "exit"
239+button .delete -image [image create bitmap -file "./pixmaps/d.xbm"] -command "push d"
240+button .menu -image [image create bitmap -file "./pixmaps/m.xbm"] -command "push m"
241+button .info -image [image create bitmap -file "./pixmaps/i.xbm"] -command "push i"
242+                                       
243+# Arrange the buttons in  grid
244+# esc   ent  up   i   quit
245+# pgup  left p right  menu
246+# pgd   bc  down fc    del
247+grid .esc -in . -row 1 -column 1
248+grid .ent -in . -row 1 -column 2
249+grid .up -in . -row 1 -column 3
250+grid .info -in . -row 1 -column 4
251+grid .quit -in . -row 1 -column 5
252+grid .pgup -in . -row 2 -column 1
253+grid .left -in . -row 2 -column 2
254+grid .play -in . -row 2 -column 3
255+grid .right -in . -row 2 -column 4
256+grid .pgdown -in . -row 3 -column 1
257+grid .backcom -in . -row 3 -column 2
258+grid .down -in . -row 3 -column 3
259+grid .forwcom -in . -row 3 -column 4
260+grid .delete -in . -row 2 -column 5
261+grid .menu -in . -row 3 -column 5
262
263Property changes on: contrib/tkmythremote/tkmythremote
264___________________________________________________________________
265Name: svn:executable
266   + *
267