forked from asciibox/asciirocks
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
535 lines (474 loc) · 30.3 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
<!--
/* The MIT License (MIT)
*
* Copyright (c) 2014 Oliver Bachmann, Karlsruhe, Germany
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
-->
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>ascii.rocks</title>
<script src="scripts/codepagedisplay.js" type="text/javascript"></script>
<script src="scripts/scrollbar.js" type="text/javascript"></script>
<script src="scripts/shape.js" type="text/javascript"></script>
<script src="scripts/jquery-1.9.1.min.js" type="text/javascript"></script>
<script src="scripts/jquery.simple-color.js" type="text/javascript"></script>
<script src="scripts/jquery-ui-1.10.4.custom.min.js"></script>
<script src="scripts/jquery.bpopup.js"></script>
<script src="scripts/app.js"></script>
<script src="scripts/buffer.js"></script>
<script src="scripts/scrollbar.js"></script>
<script src="asciiss/scripts/parse.js"></script>
<script src="fileuploader/fileuploader.js"></script>
<script src="scripts/interpreter.js"></script>
<script src="scripts/requestanimframe.js"></script>
<link rel="stylesheet" href="css/panel.css" type="text/css" media="screen" />
<link rel="stylesheet" href="css/style.css" type="text/css" media="screen" />
<link rel="stylesheet" href="fileuploader/fileuploader.css" type="text/css" media="screen" />
<script src="music/mediaelement/mediaelement-and-player.min.js"></script>
<link rel="stylesheet" href="music/mediaelement/mediaelementplayer.css" />
<style type="text/css" media="screen">
@media only screen and (max-width: 480px) {
.left, .right {
float: none;
width: 100%;
}
}
body {
overflow:hidden;
}
</style>
<script>
var currentSong=0;
var JAVASCRIPT_TEXT_DROP_HERE_TO_UPLOAD="Drop files here to upload";
var JAVASCRIPT_TEXT_UPLOAD_A_FILE="Upload a file";
var JAVASCRIPT_TEXT_CANCEL="Cancel";
var JAVASCRIPT_TEXT_UPLOAD_FAILED="Upload failed";
var JAVASCRIPT_TEXT_UPLOAD_SIZE1="Unfortunately the file(s) you selected were not the type we were expecting. Only";
var JAVASCRIPT_TEXT_UPLOAD_SIZE2="are allowed";
var JAVASCRIPT_TEXT_MAX_SIZE_ERROR="The file is too large";
var JAVASCRIPT_TEXT_MIN_SIZE_ERROR="The file is too small";
var JAVASCRIPT_TEXT_EMPTY_ERROR="Empty";
var JAVASCRIPT_TEXT_ON_LEAVE="The files are being uploaded, if you leave now the upload will be cancelled.";
function goodbye(e) {
if(!e) e = window.event;
//e.cancelBubble is supported by IE - this will kill the bubbling process.
e.cancelBubble = true;
e.returnValue = 'Are you sure you want to leave?'; //This is displayed on the dialog
//e.stopPropagation works in Firefox.
if (e.stopPropagation) {
e.stopPropagation();
e.preventDefault();
}
}
window.onbeforeunload=goodbye;
$(document).ready(function(){
codepage = new Codepage("images/CO_437_8x16.png", function() {
setCanvasSize(document.getElementById("ansi"));
setANSICanvasSize();
globalContext = document.getElementById("ansi").getContext("2d");
display = new Display();
doClearScreen(false);
updateScrollbarX(0);
updateScrollbarY(0);
if (localStorage["ansicanvas"])
{
if (confirm('Do you want to continue to work on your current drawing?')) {
var currentPosY=1;
var screenCharacterArray=JSON.parse(localStorage["ansicanvas"]);
while (currentPosY<getDisplayHeight()-1)
{
var currentPosX=1;
var maxWidth = getDisplayWidth()-1;
if (scrollbarY) maxWidth--;
while (currentPosX<maxWidth)
{
if (typeof(screenCharacterArray[currentPosY][currentPosX-1])=="undefined")
{
console.log("Error Y: "+currentPosY+" X: "+(currentPosX-1)+" is undefined");
break;
} else {
var asciiCode = screenCharacterArray[currentPosY][currentPosX-1][0];
var fgColor = screenCharacterArray[currentPosY][currentPosX-1][1];
var bgColor = screenCharacterArray[currentPosY][currentPosX-1][2];
codepage.drawChar(ctx, asciiCode, fgColor, bgColor, currentPosX, currentPosY);
}
currentPosX++;
}
currentPosY++;
}
} else {
interpreter = new Interpreter("test.ans", display);
}
} else {
interpreter = new Interpreter("test.ans", display);
}
});
//resizeToScreen=true;
$.ajax({
url: 'music/get_urls.php',
type: 'GET',
success: function(result) {
$('#panel').append(result);
player = new MediaElementPlayer('#mp3', {audioWidth:280, success: function(mediaElement) {
mediaElement.addEventListener('ended', function() {
var src = $('#allsongs ').find("li").eq(currentSong).attr('src');
$('#mp3').attr('src', src);
player.play();
currentSong++;
if (currentSong>=$('#allsongs').find("li").length) currentSong=1;
});
} });
currentSong++;
player.play();
$('.mejs-time-total').unbind('mouseenter');
}
});
$('#foreground_color').simpleColor({
boxHeight: 40,
cellWidth: 40,
cellHeight: 20,
chooserCSS: { 'border': '1px solid #660033' },
displayCSS: { 'border': '1px solid red' },
displayColorCode: true,
colors : ansicolors,
livePreview: true,
// element is a html element
onSelect: function(hex, element) {
for (var i = 0; i < ansicolors.length; i++) {
if (ansicolors[i]==hex) {
currentForeground=i;
break;
}
}
},
onOpen : function(element) {
$('.columns').hide();
},
onCellEnter: function(hex, element) {
},
onClose: function(element) {
$('.columns').show();
}
});
$('#background_color').simpleColor({
boxHeight: 40,
cellWidth: 40,
cellHeight: 20,
chooserCSS: { 'border': '1px solid #660033' },
displayCSS: { 'border': '1px solid red' },
displayColorCode: true,
colors : ansicolors,
livePreview: true,
// element is a html element
onSelect: function(hex, element) {
for (var i = 0; i < ansicolors.length; i++) {
if (ansicolors[i]==hex) {
currentBackground=i;
break;
}
}
},
onOpen : function(element) {
$('.columns').hide();
},
onCellEnter: function(hex, element) {
},
onClose: function(element) {
$('.columns').show();
}
});
registerKeyEventListener();initansicanvas();
var uploader = new qq.FileUploader({
// pass the dom node (ex. $(selector)[0] for jQuery users)
element: document.getElementById('file-uploader'),
// path to server-side upload script
action: 'upload.php',
allowedExtensions: ["ans"],
acceptFiles: null, // comma separated string of mime-types for browser to display in browse dialog
abortOnFailure: true, // Fail all files if one doesn't meet the criteria
// events
// return false to cancel submit
onSubmit: function(id, fileName){},
onProgress: function(id, fileName, loaded, total){},
onComplete: function(id, fileName, responseJSON){ // The json looks like this: {"success":true,"filename":282806397}
$('.qq-upload-list').html('');
var filename=responseJSON.filename;
globalContext = document.getElementById("ansi").getContext("2d");
display = new Display();
charactersatonce = 999999; //Math.floor((baud || 115200) / 8 / 100);
doClearScreen(true);
interpreter = new Interpreter("uploads/"+filename+".ans", display);
},
onCancel: function(id, fileName){
$('.qq-upload-list').html('');
},
onUpload: function(id, fileName, xhr){},
onError: function(id, fileName, xhr) {
$('.qq-upload-list').html('');
},
// messages
messages: {
typeError: JAVASCRIPT_TEXT_UPLOAD_SIZE1+" {extensions} "+JAVASCRIPT_TEXT_UPLOAD_SIZE2,
sizeError: "{file} "+JAVASCRIPT_TEXT_MAX_SIZE_ERROR+" {sizeLimit}.",
minSizeError: "{file} "+JAVASCRIPT_TEXT_MIN_SIZE_ERROR+" {minSizeLimit}.",
emptyError: "{file} "+JAVASCRIPT_TEXT_EMPTY_ERROR,
onLeave: JAVASCRIPT_TEXT_ON_LEAVE
},
showMessage: function(message){
alert(message);
},
sizeLimit: 200000,
minSizeLimit: 0
});
});
</script>
</head>
<body>
<div class="panel" id="panel">
<h3>Ansi editor</h3>
<p>This is an ansi editor made of HTML5 and canvas</p>
<p>The sourcecode is available on <a href="http://www.github.com/fanside/ansieditor" target="_blank">GitHub</a>. You can choose different charsets and show them by pressing 1-9, or you can paint a certain character with the mouse. You can also export the file to xterm ANSI.</p>
<p>Hold the SHIFT button to mark ANSI code, and press CTRL-C to copy, and CTRL-V to overwrite ansi code with code from clipboard</p>
<div style="clear:both;"></div>
<h3>Foreground color</h3>
<input id='foreground_color' value='#993300'/>
<h3>Background color</h3>
<input id='background_color' value='#993300'/>
<div class="columns">
<div class="colleft">
<h3>Editing</h3>
<ul>
<li><a href="#" onclick="insert=!insert; return false;" title="toggle cursor">toggle cursor</a></li>
<li><a href="#" onclick="drawingMode=!drawingMode; return false;" title="toggle drawing mode">toggle drawing mode</a></li>
<li><a href="#" onclick="clearWholeScreen(); return false;" title="clear screen">clear screen</a></li>
</ul>
</div>
<div class="colright">
<h3>Other</h3>
<ul>
<li><a href="#" onclick="myexport(); return false;" title="export to xterm ANSI">export to xterm ANSI</a></li>
<!--<li><a href="#" onclick="$('#popup').bPopup();" title="change width and height">change width and heght</a></li>-->
</ul>
<div id="file-uploader">
<noscript>
<p>Please enable JavaScript to use file uploader.</p>
<!-- or put a simple form for upload here -->
</noscript>
</div>
</div>
</div>
<div style="clear:both;"></div>
<img src="images/map.png" border="0" usemap="#ansimap">
<map id="ansimap" name="ansimap">
<area shape="rect" alt="a1" title="" coords="0,0,22,12" onclick="setD(49,1);"/>
<area shape="rect" alt="a2" title="" coords="22,0,48,12" onclick="setD(50,1);" />
<area shape="rect" alt="a3" title="" coords="48,0,72,12" onclick="setD(51,1);"/>
<area shape="rect" alt="a4" title="" coords="72,0,96,12" onclick="setD(52,1);"/>
<area shape="rect" alt="a5" title="" coords="96,0,120,12" onclick="setD(53,1);"/>
<area shape="rect" alt="a6" title="" coords="120,0,144,12" onclick="setD(54,1);"/>
<area shape="rect" alt="a7" title="" coords="144,0,168,12" onclick="setD(55,1);" />
<area shape="rect" alt="a8" title="" coords="168,0,190,10" onclick="setD(56,1);" />
<area shape="rect" alt="a9" title="" coords="192,0,216,10" onclick="setD(57,1);" />
<area shape="rect" alt="a0" title="" coords="214,0,238,10" onclick="setD(48,1);" />
<area shape="rect" alt="b1" title="" coords="0,14,22,24" onclick="setD(218,2);" />
<area shape="rect" alt="b2" title="" coords="24,12,48,22" onclick="setD(191,2);" />
<area shape="rect" alt="b3" title="" coords="48,12,72,22" onclick="setD(192,2);" />
<area shape="rect" alt="b4" title="" coords="72,12,96,22" onclick="setD(217,2);" />
<area shape="rect" alt="b5" title="" coords="96,12,120,22" onclick="setD(196,2);" />
<area shape="rect" alt="b6" title="" coords="122,12,144,22" onclick="setD(179,2);" />
<area shape="rect" alt="b7" title="" coords="142,12,166,24" onclick="setD(195,2);" />
<area shape="rect" alt="b8" title="" coords="166,12,190,24" onclick="setD(180,2);" />
<area shape="rect" alt="b9" title="" coords="192,12,216,22" onclick="setD(193,2);" />
<area shape="rect" alt="b0" title="" coords="216,10,240,22" onclick="setD(194,2);" />
<area shape="rect" alt="c1" title="" coords="0,24,22,32" onclick="setD(201,3);"/>
<area shape="rect" alt="c2" title="" coords="24,24,48,34" onclick="setD(187,3);" />
<area shape="rect" alt="c3" title="" coords="50,24,72,34" onclick="setD(200,3);" />
<area shape="rect" alt="c4" title="" coords="74,24,96,32" onclick="setD(188,3);" />
<area shape="rect" alt="c5" title="" coords="96,24,122,34" onclick="setD(205,3);" />
<area shape="rect" alt="c6" title="" coords="120,24,142,32" onclick="setD(186,3);" />
<area shape="rect" alt="c7" title="" coords="142,24,168,34" onclick="setD(204,3);" />
<area shape="rect" alt="c8" title="" coords="168,24,192,34" onclick="setD(185,3);" />
<area shape="rect" alt="c9" title="" coords="190,24,214,34" onclick="setD(202,3);" />
<area shape="rect" alt="c0" title="" coords="216,24,238,34" onclick="setD(203,3);" />
<area shape="rect" alt="d1" title="" coords="0,34,22,46" onclick="setD(251,4);" />
<area shape="rect" alt="d2" title="" coords="24,36,48,48" onclick="setD(184,4);" />
<area shape="rect" alt="d3" title="" coords="46,36,72,48" onclick="setD(212,4);" />
<area shape="rect" alt="d4" title="" coords="70,34,96,48" onclick="setD(190,4);" />
<area shape="rect" alt="d5" title="" coords="94,36,120,48" onclick="setD(205,4);" />
<area shape="rect" alt="d6" title="" coords="118,36,144,48" onclick="setD(179,4);" />
<area shape="rect" alt="d7" title="" coords="144,36,168,46" onclick="setD(198,4);" />
<area shape="rect" alt="d8" title="" coords="166,36,192,46" onclick="setD(181,4);" />
<area shape="rect" alt="d9" title="" coords="190,36,214,46" onclick="setD(207,4);" />
<area shape="rect" alt="d0" title="" coords="214,34,238,44" onclick="setD(209,4);" />
<area shape="rect" alt="e1" title="" coords="0,48,24,60" onclick="setD(161,5);" />
<area shape="rect" alt="e2" title="" coords="24,48,48,60" onclick="setD(183,5);" />
<area shape="rect" alt="e3" title="" coords="48,50,74,60" onclick="setD(211,5);" />
<area shape="rect" alt="e4" title="" coords="72,50,98,58" onclick="setD(135,5);" />
<area shape="rect" alt="e5" title="" coords="96,48,118,56" onclick="setD(179,5);" />
<area shape="rect" alt="e6" title="" coords="118,48,144,58" onclick="setD(186,5);" />
<area shape="rect" alt="e7" title="" coords="142,48,166,56" onclick="setD(199,5);" />
<area shape="rect" alt="e8" title="" coords="166,48,192,56" onclick="setD(182,5);" />
<area shape="rect" alt="e9" title="" coords="188,48,214,58" onclick="setD(208,5);" />
<area shape="rect" alt="e0" title="" coords="218,48,236,58" onclick="setD(144,5);" />
<area shape="rect" alt="f1" title="" coords="0,60,22,72" onclick="setD(197,6);" />
<area shape="rect" alt="f2" title="" coords="24,60,48,70" onclick="setD(206,6);" />
<area shape="rect" alt="f3" title="" coords="48,60,72,70" onclick="setD(139,6);" />
<area shape="rect" alt="f4" title="" coords="72,60,96,70" onclick="setD(140,6);" />
<area shape="rect" alt="f5" title="" coords="96,60,118,70" onclick="setD(232,6);" />
<area shape="rect" alt="f6" title="" coords="118,60,144,70" onclick="setD(163,6);" />
<area shape="rect" alt="f7" title="" coords="140,60,168,70" onclick="setD(155,6);" />
<area shape="rect" alt="f8" title="" coords="166,60,192,68" onclick="setD(156,6);" />
<area shape="rect" alt="f9" title="" coords="194,60,216,68" onclick="setD(153,6);" />
<area shape="rect" alt="f0" title="" coords="218,60,240,70" onclick="setD(239,6);" />
<area shape="rect" alt="g1" title="" coords="0,74,24,84" onclick="setD(176,7);" />
<area shape="rect" alt="g2" title="" coords="24,74,46,84" onclick="setD(177,7);" />
<area shape="rect" alt="g3" title="" coords="48,72,74,82" onclick="setD(178,7);" />
<area shape="rect" alt="g4" title="" coords="72,72,96,82" onclick="setD(219,7);" />
<area shape="rect" alt="g5" title="" coords="96,72,120,80" onclick="setD(223,7);" />
<area shape="rect" alt="g6" title="" coords="120,72,142,80" onclick="setD(219,7);" />
<area shape="rect" alt="g7" title="" coords="142,72,168,82" onclick="setD(124,7);" />
<area shape="rect" alt="g8" title="" coords="168,72,192,80" onclick="setD(141,7);" />
<area shape="rect" alt="g9" title="" coords="192,72,216,82" onclick="setD(254,7);" />
<area shape="rect" alt="g0" title="" coords="218,72,238,82" onclick="setD(250,7);" />
<area shape="rect" alt="h1" title="" coords="0,84,22,94" onclick="setD(001,8;" />
<area shape="rect" alt="h2" title="" coords="24,84,48,94" onclick="setD(002,8);" />
<area shape="rect" alt="h3" title="" coords="50,84,74,92" onclick="setD(003,8);" />
<area shape="rect" alt="h4" title="" coords="70,84,96,94" onclick="setD(004,8);" />
<area shape="rect" alt="h5" title="" coords="94,84,118,94" onclick="setD(005,8);" />
<area shape="rect" alt="h6" title="" coords="118,84,142,94" onclick="setD(006,8);" />
<area shape="rect" alt="h7" title="" coords="142,84,168,94" onclick="setD(196,8);" />
<area shape="rect" alt="h8" title="" coords="168,84,194,94" onclick="setD(127,8);" />
<area shape="rect" alt="h9" title="" coords="192,84,216,94" onclick="setD(14,8);" />
<area shape="rect" alt="h0" title="" coords="216,84,240,94" onclick="setD(207,8);" />
<area shape="rect" alt="i1" title="" coords="0,96,22,106" onclick="setD(24,9);" />
<area shape="rect" alt="i2" title="" coords="22,96,48,108" onclick="setD(25,9);" />
<area shape="rect" alt="i3" title="" coords="48,96,72,106" onclick="setD(24,9);" />
<area shape="rect" alt="i4" title="" coords="74,96,96,106" onclick="setD(25,9);" />
<area shape="rect" alt="i5" title="" coords="96,96,120,104" onclick="setD(16,9);" />
<area shape="rect" alt="i6" title="" coords="120,96,142,106" onclick="setD(17,9);" />
<area shape="rect" alt="i7" title="" coords="142,94,164,104" onclick="setD(23,9);" />
<area shape="rect" alt="i8" title="" coords="166,96,190,106" onclick="setD(23,9);" />
<area shape="rect" alt="i9" title="" coords="192,96,214,104" onclick="setD(20,9);" />
<area shape="rect" alt="i0" title="" coords="216,96,238,106" onclick="setD(21,9);" />
<area shape="rect" alt="j1" title="" coords="0,108,24,118" onclick="setD(174,10);" />
<area shape="rect" alt="j2" title="" coords="24,108,48,120" onclick="setD(175,10);" />
<area shape="rect" alt="j3" title="" coords="50,108,72,118" onclick="setD(61,10);" />
<area shape="rect" alt="j4" title="" coords="72,108,96,118" onclick="setD(243,10);" />
<area shape="rect" alt="j5" title="" coords="96,108,118,118" onclick="setD(169,10);" />
<area shape="rect" alt="j6" title="" coords="118,106,144,116" onclick="setD(170,10);" />
<area shape="rect" alt="j7" title="" coords="144,106,168,116" onclick="setD(253,10);" />
<area shape="rect" alt="j8" title="" coords="168,106,190,116" onclick="setD(246,10);" />
<area shape="rect" alt="j9" title="" coords="190,106,216,116" onclick="setD(171,10);" />
<area shape="rect" alt="j0" title="" coords="218,108,238,118" onclick="setD(172,10);" />
<area shape="rect" alt="k1" title="" coords="0,120,22,130" onclick="setD(149,11);" />
<area shape="rect" alt="k2" title="" coords="24,118,48,130" onclick="setD(241,11);" />
<area shape="rect" alt="k3" title="" coords="48,118,70,128" onclick="setD(20,11);" />
<area shape="rect" alt="k4" title="" coords="70,120,96,130" onclick="setD(21,11);" />
<area shape="rect" alt="k5" title="" coords="94,120,122,130" onclick="setD(234,11);" />
<area shape="rect" alt="k6" title="" coords="120,118,144,128" onclick="setD(157,11);" />
<area shape="rect" alt="k7" title="" coords="144,118,166,128" onclick="setD(228,11);" />
<area shape="rect" alt="k8" title="" coords="166,118,190,128" onclick="setD(167,11);" />
<area shape="rect" alt="k9" title="" coords="190,118,214,130" onclick="setD(251,11);" />
<area shape="rect" alt="k0" title="" coords="218,120,238,128" onclick="setD(252,11);" />
<area shape="rect" alt="l1" title="" coords="2,132,26,142" onclick="setD(162,12);" />
<area shape="rect" alt="l2" title="" coords="26,132,48,142" onclick="setD(225,12);" />
<area shape="rect" alt="l3" title="" coords="50,130,70,140" onclick="setD(147,12);" />
<area shape="rect" alt="l4" title="" coords="72,130,96,140" onclick="setD(228,12);" />
<area shape="rect" alt="l5" title="" coords="96,130,120,140" onclick="setD(230,12);" />
<area shape="rect" alt="l6" title="" coords="120,132,144,140" onclick="setD(232,12);" />
<area shape="rect" alt="l7" title="" coords="144,130,168,140" onclick="setD(235,12);" />
<area shape="rect" alt="l8" title="" coords="166,132,192,140" onclick="setD(236,12);" />
<area shape="rect" alt="l9" title="" coords="190,130,214,140" onclick="setD(237,12);" />
<area shape="rect" alt="l0" title="" coords="216,130,238,140" onclick="setD(237,12);" />
<area shape="rect" alt="m1" title="" coords="2,140,26,150" onclick="setD(128,13);" />
<area shape="rect" alt="m2" title="" coords="26,140,48,150" onclick="setD(135,13);" />
<area shape="rect" alt="m3" title="" coords="46,140,70,150" onclick="setD(165,13);" />
<area shape="rect" alt="m4" title="" coords="72,140,94,150" onclick="setD(164,13);" />
<area shape="rect" alt="m5" title="" coords="94,140,118,150" onclick="setD(152,13);" />
<area shape="rect" alt="m6" title="" coords="120,140,142,150" onclick="setD(159,13);" />
<area shape="rect" alt="m7" title="" coords="144,140,166,150" onclick="setD(44,13);" />
<area shape="rect" alt="m8" title="" coords="166,140,188,150" onclick="setD(249,13);" />
<area shape="rect" alt="m9" title="" coords="190,140,214,150" onclick="setD(173,13);" />
<area shape="rect" alt="m0" title="" coords="216,140,238,150" onclick="setD(168,13);" />
<area shape="rect" alt="n1" title="" coords="2,150,26,163" onclick="setD(131,14);" />
<area shape="rect" alt="n2" title="" coords="26,150,48,163" onclick="setD(132,14);" />
<area shape="rect" alt="n3" title="" coords="46,150,70,163" onclick="setD(133,14);" />
<area shape="rect" alt="n4" title="" coords="72,150,94,163" onclick="setD(160,14);" />
<area shape="rect" alt="n5" title="" coords="94,150,118,163" onclick="setD(248,14);" />
<area shape="rect" alt="n6" title="" coords="120,150,142,163" onclick="setD(134,14);" />
<area shape="rect" alt="n7" title="" coords="144,150,166,163" onclick="setD(142,14);" />
<area shape="rect" alt="n8" title="" coords="166,150,188,163" onclick="setD(143,14);" />
<area shape="rect" alt="n9" title="" coords="190,150,214,163" onclick="setD(145,14);" />
<area shape="rect" alt="n0" title="" coords="216,150,238,163" onclick="setD(146,14);" />
<area shape="rect" alt="o1" title="" coords="2,163,26,174" onclick="setD(147,15);" />
<area shape="rect" alt="o2" title="" coords="26,163,48,174" onclick="setD(148,15);" />
<area shape="rect" alt="o3" title="" coords="46,163,70,174" onclick="setD(149,15);" />
<area shape="rect" alt="o4" title="" coords="72,163,94,174" onclick="setD(224,15);" />
<area shape="rect" alt="o5" title="" coords="94,163,118,174" onclick="setD(167,15);" />
<area shape="rect" alt="o6" title="" coords="120,163,142,174" onclick="setD(150,15);" />
<area shape="rect" alt="o7" title="" coords="144,163,166,174" onclick="setD(129,15);" />
<area shape="rect" alt="o8" title="" coords="166,163,188,174" onclick="setD(151,15);" />
<area shape="rect" alt="o9" title="" coords="190,163,214,174" onclick="setD(163,15);" />
<area shape="rect" alt="o0" title="" coords="216,163,238,174" onclick="setD(154,15);" />
<area shape="rect" alt="o1" title="" coords="2,175,26,196" onclick="setD(226,16);" />
<area shape="rect" alt="o2" title="" coords="26,175,48,196" onclick="setD(153,16);" />
<area shape="rect" alt="o3" title="" coords="46,175,70,196" onclick="setD(227,16);" />
<area shape="rect" alt="o4" title="" coords="72,175,94,196" onclick="setD(224,16);" />
<area shape="rect" alt="o5" title="" coords="94,175,118,196" onclick="setD(167,16);" />
<area shape="rect" alt="o6" title="" coords="120,175,142,196" onclick="setD(129,16);" />
<area shape="rect" alt="o7" title="" coords="144,175,166,196" onclick="setD(234,16);" />
<area shape="rect" alt="o8" title="" coords="166,175,188,196" onclick="setD(151,16);" />
<area shape="rect" alt="o9" title="" coords="190,175,214,196" onclick="setD(163,16);" />
<area shape="rect" alt="o0" title="" coords="216,175,238,196" onclick="setD(154,16);" />
</map>
</div>
<!--
Image width: <input autocomplete="off" type="text" id="imagewidth" value="800">
Image height: <input autocomplete="off" type="text" id="imageheight" value="500">
Display width: <input autocomplete="off" type="text" id="displaywidth" value="80">
Display height: <input autocomplete="off" type="text" id="displayheight" value="50">
<br />
<canvas id="boxcanvas" width="800" height="500" style="border: 1px solid black;">
Your browser does not support canvas
</canvas>
--><div style="width: 640px" class="centered">
<canvas id="ansi" width=640 height=480></canvas>
</div>
<div id="popup" class="popup">
<span id="part1">
<span class="button b-close"><span>X</span></span>
<a href="" target="_blank" id="file"></a> (right click - save as)
</span>
<span id="part2">
<span class="button b-close"><span>X</span></span>
<ul>
<li class="left">Width:</li>
<li class="right"><input type="text" value="80" /></li>
<li class="left">Height:</li>
<li class="right"><input type="text" value="45" /></li>
<li><input type="button" value="OK"></li>
</ul>
</span>
</div>
</body>
</html>