fixed z-order problems in poly2bitmap
[swftools.git] / swfs / rfxview.sc
1 # rfxview.sc - a document viewer for pdf2swf converted files
2 #
3 # Copyright (c) 2008 Matthias Kramm 
4
5 # Permission is hereby granted, free of charge, to any person obtaining a copy
6 # of this software and associated documentation files (the "Software"), to deal
7 # in the Software without restriction, including without limitation the rights
8 # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 # copies of the Software, and to permit persons to whom the Software is
10 # furnished to do so, subject to the following condition:
11
12 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15 # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
18 # THE SOFTWARE.
19
20
21 .flash filename=rfxview.swf fps=30 bbox=600x800 version=8 compress background=#CCCCCC export=0
22
23 .define width 600
24 .define height 800
25
26 #======================================== buttons ===========================================================
27
28 .gradient grad1 radial x=4 y=4 r=28:
29  0% white
30  50% #666666
31  100% #202020
32 .end
33 .gradient grad2 linear width=8 height=6 rotate=120:
34  0% white
35  70% #666666
36  100% #202020  
37 .end
38 .gradient grad4 linear width=8 height=6 rotate=120:
39  0% white
40  70% #999999
41  100% #404040
42 .end
43
44 .gradient grad2l linear width=8 height=6 rotate=120:
45  0% #e0e0e0
46  100% #000000  
47 .end
48 .gradient grad4l linear width=8 height=6 rotate=120:
49  0% #ffffff
50  100% #404040
51 .end
52
53 .gradient grad3 radial x=4 y=4 r=28:
54  0% white
55  70% #999999
56  100% #404040
57 .end
58
59 .gradient grad7 linear rotate=180:
60  0% #777777
61  100% #666666
62 .end
63
64 .gradient grad72 linear rotate=45:
65  0% #999999
66  100% #666666
67 .end
68
69 .outline arrowoutline:
70     moveTo -8,-8
71     lineTo -8, 8
72     lineTo  8, 0
73     lineTo -8,-8
74 .end
75
76 .outline larrowoutline:
77     moveTo 8,-8
78     lineTo 8, 8
79     lineTo -8, 0
80     lineTo 8,-8
81 .end
82
83 .font arialbold filename="../wx/ArialBold.ttf" glyphs="1:"
84 .font arial filename="../wx/Arial.ttf" glyphs="0123456789 /:"
85
86 .textshape oneoneoutline text="1:1" font=arialbold size=14pt
87
88 .outline plusoutline:
89     moveTo  2,-8
90     lineTo -2,-8
91     lineTo -2,-2
92     lineTo -8,-2
93     lineTo -8,2
94     lineTo -2,2
95     lineTo -2,8
96     lineTo  2,8
97     lineTo  2,2
98     lineTo  8,2
99     lineTo  8,-2
100     lineTo  2,-2
101     lineTo  2,-8
102 .end
103
104 .outline zoomoutline:
105     moveTo 8,0 lineTo 4,3 lineTo 4,-3 lineTo 8,0
106     moveTo -8,0 lineTo -4,3 lineTo -4,-3 lineTo -8,0
107     moveTo 0,8 lineTo 3,4 lineTo -3,4 lineTo 0,8
108     moveTo 0,-8 lineTo 3,-4 lineTo -3,-4 lineTo 0,-8
109 .end
110
111 .outline minusoutline:
112     moveTo -7,2
113     lineTo -7,-2
114     lineTo  7,-2
115     lineTo  7,2
116     lineTo -7,2
117 .end
118
119 .circle shadcircle line=0 fill=#00000033 r=11.5
120
121 .circle outcircle line=2 color=#00000060 fill=grad1 r=11
122 .circle outcircle_over line=2 color=#00000060 fill=grad3 r=11
123
124 .filled incircle outline=arrowoutline fill=grad2 line=1 color=#00000060
125 .filled incircle_over outline=arrowoutline fill=grad4 line=1 color=#00000060
126 .filled lincircle outline=larrowoutline fill=grad2l line=1 color=#00000060
127 .filled lincircle_over outline=larrowoutline fill=grad4l line=1 color=#00000060
128 .filled pincircle outline=plusoutline fill=grad2l line=1 color=#00000060
129 .filled pincircle_over outline=plusoutline fill=grad4l line=1 color=#00000060
130 .filled mincircle outline=minusoutline fill=grad2l line=1 color=#00000060
131 .filled mincircle_over outline=minusoutline fill=grad4l line=1 color=#00000060
132 .filled oincircle outline=oneoneoutline fill=grad2l line=1.2 color=#00000060
133 .filled oincircle_over outline=oneoneoutline fill=grad4l line=1.2 color=#00000060
134 .filled zincircle outline=zoomoutline fill=grad2l line=1 color=#00000060
135 .filled zincircle_over outline=zoomoutline fill=grad4l line=1 color=#00000060
136
137 .sprite plusface
138  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put pincircle 11 11 pin=center scale=90%
139 .end
140 .sprite plusfaceover 
141  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put pincircle_over 11 11 pin=center scale=90%
142 .end
143 .sprite plusfacedown 
144  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put pincircle_over 11 11 pin=center scale=79%
145 .end
146
147 .sprite minusface
148  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put mincircle 11 11 pin=center scale=90% luminance=60%
149 .end
150 .sprite minusfaceover 
151  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put mincircle_over 11 11 pin=center scale=90%
152 .end
153 .sprite minusfacedown 
154  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put mincircle_over 11 11 pin=center scale=79%
155 .end
156
157 .sprite rbface
158  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put incircle 13 11 pin=center scale=90%
159 .end
160 .sprite rbfaceover 
161  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put incircle_over 13 11 pin=center scale=90%
162 .end
163 .sprite rbfacedown 
164  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put incircle_over 13 11 pin=center scale=79%
165 .end
166
167 .sprite lbface
168  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put lincircle 9 11 pin=center scale=90%
169 .end
170 .sprite lbfaceover 
171  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put lincircle_over 9 11 pin=center scale=90%
172 .end
173 .sprite lbfacedown 
174  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put lincircle_over 9 11 pin=center scale=79%
175 .end
176
177 .sprite obface
178  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put oincircle 9 11 pin=center scale=90% luminance=50%
179 .end
180 .sprite obfaceover 
181  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put oincircle_over 9 11 pin=center scale=90%
182 .end
183 .sprite obfacedown 
184  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put oincircle_over 9 11 pin=center scale=79%
185 .end
186
187 .sprite zbface
188  .put shadcircle 11 13 pin=center .put outcircle 11 11 pin=center .put zincircle 10 11 pin=center scale=90% luminance=50%
189 .end
190 .sprite zbfaceover 
191  .put shadcircle 11 13 pin=center .put outcircle_over 11 11 pin=center .put zincircle_over 10 11 pin=center scale=90%
192 .end
193 .sprite zbfacedown 
194  .put shadcircle 11 13 pin=center scale=90% .put outcircle_over 11 11 pin=center scale=90% .put zincircle_over 10 11 pin=center scale=79%
195 .end
196
197 .button rightbutton
198   .show rbface as=idle
199   .show outcircle as=area
200   .show rbfacedown as=pressed
201   .show rbfaceover as=hover
202 .end
203
204 .button leftbutton
205   .show lbface as=idle
206   .show outcircle as=area
207   .show lbfacedown as=pressed
208   .show lbfaceover as=hover
209 .end
210
211 .button plusbutton
212   .show plusface as=idle
213   .show outcircle as=area
214   .show plusfacedown as=pressed
215   .show plusfaceover as=hover
216 .end
217
218 .button minusbutton
219   .show minusface as=idle
220   .show outcircle as=area
221   .show minusfacedown as=pressed
222   .show minusfaceover as=hover
223 .end
224
225 .button oneonebutton
226   .show obface as=idle
227   .show outcircle as=area
228   .show obfacedown as=pressed
229   .show obfaceover as=hover
230 .end
231
232 .button fullsizebutton
233   .show zbface as=idle
234   .show outcircle as=area
235   .show zbfacedown as=pressed
236   .show zbfaceover as=hover
237 .end
238
239 #======================================== frame ===========================================================
240   
241 .frame 1
242
243 .box background_box line=1 color=#00000030 fill=#00000030 width=800 height=600
244 .sprite background
245     .put background_box x=0 y=0
246 .end
247 .put background
248
249 # horizontal scroll outline
250 .box hscroll_box line=1 color=#000000 width=800-20 height=10
251 .sprite hscroll_outline
252     .put hscroll_box x=0 y=0
253 .end
254 .put hscroll_outline
255
256 # vertical scroll outline
257 .box vscroll_box line=1 color=#000000 width=10 height=600-20
258 .sprite vscroll_outline
259     .put vscroll_box x=0 y=0
260 .end
261 .put vscroll_outline
262
263 # content outline
264 .box content_box width=100 height=100 line=1 color=#000000
265 .sprite content_outline
266     .put content_box x=0 y=0
267 .end
268 .put content_outline
269
270 .put p1=plusbutton x=width-25-20 y=20 pin=center
271 .put m1=minusbutton x=width-50-20 y=20 pin=center
272 .put o1=oneonebutton x=width-75-20 y=20 pin=center
273 .put z1=fullsizebutton x=width-100-20 y=20 pin=center
274
275 .put l1=leftbutton x=width/2-100 y=20 pin=center
276 .put r1=rightbutton x=width/2+100 y=20 pin=center
277
278 .sprite vscrollbar
279     .box vscroll2_shadow line=0 fill=#00000033 width=14 height=100
280     .sprite vshadow
281     .put vscroll2_shadow x=0 y=0 luminance=1.8
282     .end
283     .put vshadow
284
285     .box vscroll2 width=14 height=100 line=1 color=#00000060 fill=grad7
286     .sprite vbox
287     .put vscroll2 x=0 y=0 luminance=1.5
288     .end
289     .put vbox
290
291     .box tick line=1 color=black width=8 height=0
292
293     .sprite t1 .put tt1=tick y=0 x=3 .end .put t1
294     .sprite t2 .put tt2=tick y=0 x=3 .end .put t2 y=50
295     .sprite t3 .put tt3=tick y=0 x=3 .end .put t3
296     
297     .button vscrollbutton
298         .show vscroll2 as=area
299         .on_press inside:
300             startDrag(false, _parent.fullwidth-22, 40, 
301                              _parent.fullwidth-22, 40+_parent.scrollbaryrange);
302             _parent.Dragging = "v";
303         .end
304         .on_release:
305             stopDrag();
306             _parent.refreshDrag();
307             _parent.Dragging = "";
308         .end
309     .end
310     .put vscrollbutton
311 .end
312
313 .sprite hscrollbar
314     .box hscroll2_shadow width=100 line=0 fill=#00000033 height=14
315     .sprite hshadow
316         .put hscroll2_shadow x=0 y=0 luminance=1.5
317     .end
318     .put hshadow
319
320     .box hscroll2 width=100 height=14 line=1 color=#00000060 fill=grad72
321     .sprite hbox
322     .put hscroll2 x=0 y=0 luminance=1.5
323     .end 
324     .put hbox
325
326     .box htick line=1 color=black width=0 height=8
327
328     .sprite th1 .put tht1=htick x=0 y=3 .end .put th1
329     .sprite th2 .put tht2=htick x=0 y=3 .end .put th2 x=50
330     .sprite th3 .put tht3=htick x=0 y=3 .end .put th3
331
332     .button hscrollbutton
333         .show hscroll2 as=area
334         .on_press inside:
335             startDrag(false, 10                        , _parent.fullheight-22, 
336                              10+_parent.scrollbarxrange, _parent.fullheight-22);
337             _parent.Dragging = "h";
338         .end
339         .on_release:
340             stopDrag();
341             _parent.refreshDrag();
342             _parent.Dragging = "";
343         .end
344     .end
345     .put hscrollbutton
346 .end
347
348 .put hscrollbar y=height-22 x=10
349 .put vscrollbar x=width-22 y=40
350
351 .edittext et width=50 height=20 font=arial size=18pt color=black variable=current_pagenumber maxlength=3 text="1" align=left
352 .edittext etmiddle text="/" width=10 height=25 font=arial color=black noselect size=18pt align=center
353 .edittext et_total_pages width=50 height=25 font=arial color=black noselect size=18pt align=right
354
355 #.font dbgarial filename="Courier.ttf"
356 #.edittext debugtxt width=width height=20 font=dbgarial size=18pt color=#004000 noselect
357 #.put debugtxt y=20
358
359 .put et x=width/2-55 y=8
360 .put etmiddle x=width/2-5 y=8
361 .put et_total_pages x=width/2+5 y=8
362
363 #.swf viewport filename=paper5.viewport
364 .sprite viewport
365 .end
366
367 .box f width=100 height=100 line=0 fill=black
368
369 .button areabutton
370     .show f as=area
371     .on_press inside:
372         viewport.startDrag(false, left-scrollxrange, top-scrollyrange, left,top);
373         Dragging = "xy";
374     .end
375     .on_release:
376         viewport.stopDrag();
377         Dragging = "";
378     .end
379 .end
380 .put areabutton x=10 y=40
381
382 .sprite cf
383     .put f
384 .end
385 .put cliparea=cf x=10 y=40
386 .put viewport x=10 y=40
387
388
389 .action:
390     et_total_pages.text=viewport._totalframes;
391     swfwidth = viewport._width;
392     swfheight = viewport._height;
393
394     Dragging = "";
395     
396     Stage.scaleMode="noScale";
397     Stage.align ="LT";
398     
399     //Stage.showMenu = false;
400
401     fullwidth = Stage.width;
402     fullheight = Stage.height;
403     contentwidth = fullwidth - 40;
404     contentheight = fullheight - 70;
405
406     background._width = fullwidth-1;
407     background._height = fullheight-1;
408
409     // resize/position hscroll outline
410     hscroll_outline._x = 10;
411     hscroll_outline._y = fullheight-20;
412     hscroll_outline._width = fullwidth-40;
413     hscroll_outline._height = 10;
414
415     // resize/position vscroll outline
416     vscroll_outline._x = fullwidth-20;
417     vscroll_outline._y = 40;
418     vscroll_outline._width = 10;
419     vscroll_outline._height = fullheight-70;
420
421     // resize/position content outline
422     content_outline._x = 9;
423     content_outline._y = 39;
424     content_outline._width = contentwidth+1;
425     content_outline._height = contentheight+1;
426
427     // move all objects to their proper positions
428     vscrollbar._x = fullwidth-22;
429     hscrollbar._y = fullheight-22;
430     p1._x = fullwidth-25-20 - p1._width/2;
431     o1._x = fullwidth-50-20 - o1._width/2;
432     z1._x = fullwidth-75-20 - z1._width/2;
433     m1._x = fullwidth-100-20 - m1._width/2;
434
435     l1._x = fullwidth/2-100 - l1._width/2;
436     r1._x = fullwidth/2+100 - r1._width/2;
437
438     et._x = fullwidth/2 - (et._width+etmiddle._width+et_total_pages._width)/2;
439     etmiddle._x = fullwidth/2 - (et._width+etmiddle._width+et_total_pages._width)/2 + et._width;
440     et_total_pages._x = fullwidth/2 - (et._width+etmiddle._width+et_total_pages._width)/2 + et._width+etmiddle._width;
441     
442     areabutton._xscale = contentwidth;
443     areabutton._yscale = contentheight;
444     cliparea._xscale = contentwidth;
445     cliparea._yscale = contentheight;
446     viewport.setMask(cliparea);
447     
448
449     lastzoom = 1;
450
451     zoom = 1;
452         
453     //debugtxt.text = Stage.width+ " x " + Stage.height;
454     //debugtxt.text = zoomtype;
455
456     setPageNr = function(setscroll) {
457         current_pagenumber = pagenr;
458         viewport.gotoAndStop(pagenr);
459         if(!setscroll) {
460             viewport._y = top;
461             swfpos2scrollbars();
462         }
463         else {
464             viewport._y = setscroll;                
465             swfpos2scrollbars();
466         }
467     };
468    
469     setNoScrollZoomLevel = function() {
470         // determine initial zoom level
471         xscale = contentwidth / swfwidth;
472         yscale = contentheight / swfheight;
473         if(xscale < yscale) {
474             zoom = xscale;
475             setZoomLevel();
476         } else {
477             zoom = yscale;
478             setZoomLevel();
479         }
480     };
481     
482     setOneDirScrollZoomLevel = function() {
483         xscale = contentwidth / swfwidth;
484         yscale = contentheight / swfheight;
485         if(xscale > yscale) {
486             zoom = xscale;
487             setZoomLevel();
488         } else {
489             zoom = yscale;
490             setZoomLevel();
491         }
492     };
493    
494     set11ZoomLevel = function() {
495         zoom = 1.0;
496         setZoomLevel();
497     };
498
499     swfpos2scrollbars = function() {
500         if(scrollxrange) {
501             hscrollbar._x = 10 + (left-viewport._x)*scrollbarxrange/scrollxrange;
502         } else {
503             hscrollbar._x = 10;
504         }
505         if(scrollyrange) {
506             vscrollbar._y = 40 + (top-viewport._y)*scrollbaryrange/scrollyrange;
507         } else {
508             vscrollbar._y = 40;
509         }
510     };
511     setZoomLevel = function() {
512
513         width = contentwidth;
514         height = contentheight;
515         left = 10;
516         top = 40;
517
518         if(swfwidth * zoom < contentwidth) {
519             width = swfwidth*zoom;
520             left = 10+(contentwidth-width)/2;
521         }
522         if(swfheight * zoom < contentheight) {
523             height = swfheight*zoom;
524             top = 40+(contentheight-height)/2;
525         }
526             
527         scrollxrange = swfwidth*zoom-width;
528         scrollyrange = swfheight*zoom-height;
529    
530         hscrollbar._xscale = (contentwidth*width) / (swfwidth*zoom);
531         vscrollbar._yscale = (contentheight*height) / (swfheight*zoom);
532         scrollbarxrange = contentwidth - hscrollbar._xscale;
533         scrollbaryrange = contentheight - vscrollbar._yscale;
534         if(scrollbarxrange<0) {
535             scrollbarxrange = 0;
536         }
537         if(scrollbaryrange<0) {
538             scrollbaryrange = 0;
539         }
540
541         viewport._xscale = zoom*100;
542         viewport._yscale = zoom*100;
543    
544         focusx = contentwidth/2 - (viewport._x-10);
545         focusy = contentheight/2 - (viewport._y-40);
546
547         viewport._x = left - focusx * zoom / lastzoom + width/2;
548         viewport._y = top - focusy * zoom / lastzoom + height/2;
549
550         if(viewport._x > left) {
551             viewport._x = left;
552         } else if(viewport._x < left-scrollxrange) {
553             viewport._x = left-scrollxrange;
554         } 
555         if(viewport._y > top) {
556             viewport._y = top;
557         } else if(viewport._y < top-scrollyrange) {
558             viewport._y = top-scrollyrange;
559         }
560
561         swfpos2scrollbars();
562
563         if(scrollxrange) {
564             hscrollbar._visible = 1;
565         } else {
566             //hscrollbar._visible = 0;
567         }
568         if(scrollyrange) {
569             vscrollbar._visible = 1;
570         } else {
571             //vscrollbar._visible = 0;
572         }
573
574         lastzoom = zoom;
575
576         // update the ruler decorations
577
578         vscrollbar.t1._y = vscrollbar.t2._y - 600.0/vscrollbar._yscale;
579         vscrollbar.t3._y = vscrollbar.t2._y + 600.0/vscrollbar._yscale;
580         hscrollbar.th1._x = hscrollbar.th2._x - 600.0/hscrollbar._xscale;
581         hscrollbar.th3._x = hscrollbar.th2._x + 700.0/hscrollbar._xscale;
582
583         vscrollbar.vshadow._x = vscrollbar.vbox._x + 500/vscrollbar._xscale;
584         vscrollbar.vshadow._y = vscrollbar.vbox._y + 500/vscrollbar._yscale;
585         
586         hscrollbar.hshadow._x = hscrollbar.hbox._x + 500/hscrollbar._xscale;
587         hscrollbar.hshadow._y = hscrollbar.hbox._y + 500/hscrollbar._yscale;
588     };
589
590     pagenr = 1;
591     setPageNr();
592
593     if(zoomtype=="1") {
594         set11ZoomLevel();
595     } else if(zoomtype=="2") {
596         setNoScrollZoomLevel();
597     } else {
598         setOneDirScrollZoomLevel();
599     }
600         
601     et.onChanged = function(){
602         if(current_pagenumber <= viewport._totalframes) {
603             if (current_pagenumber > 0) {
604                 pagenr = int(current_pagenumber);
605                 setPageNr();
606             }
607         }
608     };
609     l1.onRelease = function(){ 
610         if(pagenr > 1) {
611             pagenr = pagenr - 1;
612             setPageNr();
613         }
614     };
615     r1.onRelease = function(){ 
616         if(pagenr < viewport._totalframes) {
617             pagenr = pagenr + 1;
618             setPageNr();
619         }
620     };
621     p1.onRelease = function(){ 
622         if(zoom < 4) {
623             zoom = zoom + 1;
624             setZoomLevel();
625         }
626     };
627     m1.onRelease = function(){ 
628         if(zoom > 1) {
629             zoom = zoom - 1;
630             if(zoom < 1)
631                 zoom = 1;
632             setZoomLevel();
633         }
634     };
635     o1.onRelease = function(){ 
636         setNoScrollZoomLevel();
637     };
638     z1.onRelease = function(){ 
639         setOneDirScrollZoomLevel();
640     };
641     refreshDrag = function(){
642         if(Dragging == "h") {
643             viewport._x = left + (10-hscrollbar._x)*scrollxrange/scrollbarxrange;
644         } else if(Dragging == "v") {
645             viewport._y = top + (40-vscrollbar._y)*scrollyrange/scrollbaryrange;
646         } else if(Dragging == "xy") {
647             swfpos2scrollbars();
648         }
649     };
650     dragrefresh = setInterval(refreshDrag, 20);
651
652     var mouseListener = new Object();
653
654     mouseListener.onMouseWheel = function(delta) {
655         divideDelta = delta/Math.abs(delta);
656         viewport._y = viewport._y + 30*zoom*divideDelta;
657         swfpos2scrollbars();
658         if(viewport._y < top-scrollyrange) {
659             if(pagenr < viewport._totalframes) {
660                 pageNr = pageNr + 1;
661                 setPageNr();
662             }
663             else {
664                 viewport._y = top-scrollyrange;
665                 swfpos2scrollbars();
666             }
667         }
668         else if(viewport._y > top) {
669             if(pagenr > 1) {
670                 pageNr = pageNr - 1;
671                 setPageNr(top-scrollyrange);
672             }
673             else {
674                 viewport._y = top;
675                 swfpos2scrollbars();
676             }
677         }
678     };
679
680     Mouse.addListener(mouseListener);
681 .end
682
683 .end