#!/bin/sh # MetaCard 2.4 stack # The following is not ASCII text, # so now would be a good time to q out of more exec mc $0 "$@" 'javacupwBlackffffffNNHHHHj U Helvetica P@on openCard send nextImage to button "java cup" end openCard zz $  # % java4.gif@Bd0GIF89aBd@@@@ooo@@@U@zhhEE꪿@njkNHH@@x߀@@nn@f˳ϹҴ!,Bd@pH,Ȥrl:ШtJZجvzxL.zn|N~K%$)$~)~% +}}$| ~ )$}%~*&*x B( S Y B " O''SE)$* (N%MM`!Yt!@td9 $$4S6 0D}5'BH( #P%BxO@fa~-0^L @ (1&Tw <đd4MQ$9V,7C95 QPِx=Xy"_9$z[ӐC͔ӰBiwF18yWRu PBaF38 ޳dm09}cZDbw!\SSMtB`"dB,pv^kiX}[C녕I,NAFܵd.bcy*W7Uپ*88bFiueTHi=JJ\=" wS@^:@j,\1qln|VO\O?0EL0 ۢj[;H7жѺnCЮtiTu34Ӊq Jws[M';_\[N2]ּ$@*)KZ?!TϯKUF`^Ԙ)aQ$x.*w47U9 >cvUe%rq%Шi,= 5_jW)O;my];UA9D; java5.gif@BdGIF89aBd@@@@@ݿ@@@U@zhhEEک꪿@@njk@"@x߀@@/~nn®@f˿@ϹҴ!,BdpH,Ȥrl:ШtJZجvzxL.zn|N~Y("-~ -|0$(-} '}~}$/~'x($w(B  0z() $'(y($/"{ (%z-,/)|)'t*'q+ @(‚ ,<`$+*Do bp@Lb@ `G $O&`Ɗ1;1(NဂFlyBFbXB^"RR EN9/0 HC0!@ċ*00&ğ/JLBI'!6F"N'?ar= H+C-U $?Qu["଀oIP 0ܒL 0 %w@H΋pa`#(!!> 4;ԘA~C@S@V@ x`q-@PD`a©k iݔ 0HSv @L pMg 1ҖvYU`|0`ӏIaIx7CtDŒYgJy&a=4%E0yvҙ<`Ղv iBwEG Ė&(lpԧHiP=0mAp I$=t[YTP4+ba, UFT8ʹ%˞AjNUV'jځI%0ҥUӬVMjFf&R\6 CƪvE6<QaAL26ӡDu喣AˆtYEPMEh[ @FsA]<>@ qQ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n^!F=l"YaQˆIr1tIn yLVQ  ~;Q,bHYMV@Cֆ@sakIN]}_첺`ZLlcZ(kմܵ`;1&eĨ+`6/C<3A u=+4@2H& W6dCpHPUhXi y̴@%ٌ>4c!e$ 3xK^"O "S(" E#(h+i 'Lw !^X-a(‡4V e'9hXd2!UyR?RF'w BD4FagCX֔6+ib ˰`Ҫ, X !nNP( lU W% VN$y)נx,V>ւhM$^pKQnP2dD8(bq9d.`2(TOo; java cupC # This handler changes the image displayed by this button # based on the sequence used on the Java Home page. # The "|" character is used as the itemDelimiter for the first # part of the script since this is the way the data was # stored on http://www.java.com and I was too lazy to # change it to use commas which are the more natural # item delimiter on nextImage set the itemDelimiter to "|" put "1|2|3|1|2|3|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15" into sequence put the number of items in sequence into nitems # get the next element in the sequence, wrapping a the end put the imageNumber of me mod nitems + 1 into newImage # save the position in the sequence as a custom property set the imageNumber of me to newImage put item newImage of sequence into frame set the itemDelimiter to "," # set the icon (image) this button displays. The numbers # are the ID's MetaCard assigned to the images when # they were imported. They're not sequential because I # had to import some of them several times before I'd got # all the cruft off of the edges of them. set the icon of me to item frame of "1030,1033,1021,1008,1009,1011,1010,1012,1013,1015,1014,1016,1017,1018,1019" # Arrange to change the icon after a certain time (stored # as a custom property). Note that this update rate # doesn't include the time taken by the above statements. # if the frame rate must be accurate, you should calculate # the flip times and use the milliseconds function to # calculate exactly how long to wait send nextImage to me in the updateInterval of me millisecs # save the timer id generated by the send command so # we can cancel it to stop the animation later if needed set the timerID of me to the result end nextImage on mouseUp # if the animation is already running then stop it. if the timerId of me is not empty then cancel the timerID of me set the timerID of me to empty #Otherwise start it. else nextImage end mouseUp S9]updateInterval100 imageNumber30timerID  q# this message is sent when the scrollbar thumb position # is changed on scrollbarDrag newValue # set a custom property of the button displaying the images # telling it how often to change the image set the updateInterval of button "java cup" to newValue end scrollbarDrag ^$23K1500  `ک 0<  ?This stack demonstrates how easy it is use MetaCard to do the kinds of animation Java has become famous for. The images are changed by setting the "icon" property of a button in a handler. The handler is called using a delayed "send" command, the delay interval (in milliseconds) is set using the scale control below.  Clicking on the "Move It!" button demonstrates another powerful feature of MetaCard. Moving a transparent object over and under other controls on a page is something Java just can't do, and given the design of Java and Netscape, is very unlikely to be able to do anytime soon. r r v {  Besides requiring far less coding than Java to do the animation, MetaCard is vastly more efficient: the Java interpreter in Netscape 2.0 requires over 10 times the CPU resources to animate the cup at a 100 milliseconds update rate as MetaCard (you can verify this most easily with a utility like "top", but also with "ps -l" if you open both applications, run "ps -l", leave the animation running for a few minutes, and then run ps -l again and subtract the times).  [The images were grabbed off of the Java Home page (http:.//www.java.com) using MetaCard's "import snapshot" feature on a Netscape 2.0 window, edited using MetaCard's painting tools, then exported to separate files. The files were converted to transparent GIFs using the freeware NetPBM image conversion package and then reimported into MetaCard. `% : Move It!EpKon mouseUp disable me # don't restart move if already moving set the moveSpeed to 100 put the points of graphic "path" into pathpoints repeat with i = 1 to the number of lines in pathpoints - 1 move button "java cup" from line i of pathpoints to line \ i + 1 of pathpoints end repeat enable me end mouseUp ^L$ #path4,T8}|[/cW`)5EwkI--[Cvfw}$View Source...EpPon mouseUp show field "source" with visual effect barn door open end mouseUp >^l( %sourcepEon mouseUp hide me with visual effect barn door close end mouseUp   BThis field shows the scripts of all of the objects in this stack. 7The scripts themselves are stored as properties on the # set a custom property of the button displaying the images - # telling it how often to change the image : set the updateInterval of button "java cup" to newValue end scrollbarDrag  Script of button "Move It!": @Blue on mouseUp 4 disable me # don't restart move if already moving  set the moveSpeed to 100 3 put the points of graphic "path" into pathpoints = repeat with i = 1 to the number of lines in pathpoints - 1 ? move button "java cup" from line i of pathpoints to line \  i + 1 of pathpoints end repeat enable me end mouseUp  Script of button "java cup": @Blue :# This handler changes the image displayed by this button 4# based on the sequence used on the Java Home page. @# The "|" character is used as the itemDelimiter for the first 9# part of the script since this is the way the data was 6# stored on http://www.java.com and I was too lazy to 5# change it to use commas which are the more natural # item delimiter on nextImage  set the itemDelimiter to "|" put "1|2|3|1|2|3|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15|10|11|12|13|14|15" into sequence 2 put the number of items in sequence into nitems = # get the next element in the sequence, wrapping a the end 9 put the imageNumber of me mod nitems + 1 into newImage ; # save the position in the sequence as a custom property ( set the imageNumber of me to newImage + put item newImage of sequence into frame  set the itemDelimiter to "," = # set the icon (image) this button displays. The numbers 7 # are the ID's MetaCard assigned to the images when : # they were imported. They're not sequential because I < # had to import some of them several times before I'd got , # all the cruft off of the edges of them. s set the icon of me to item frame of "1030,1033,1021,1008,1009,1011,1010,1012,1013,1015,1014,1016,1017,1018,1019" = # arrange to change the icon after a certain time (stored 7 # as a custom property). Note that this update rate < # doesn't include the time taken by the above statements. = # if the frame rate must be accurate, you should calculate 8 # the flip times and use the milliseconds function to ' # calculate exactly how long to wait = send nextImage to me in the updateInterval of me millisecs 8 # save the timer id generated by the send command so ; # we can cancel it to stop the animation later if needed & set the timerID of me to the result end nextImage  on mouseUp 6 # if the animation is already running then stop it. ) if the timerId of me is not empty then  cancel the timerID of me # set the timerID of me to empty  #Otherwise start it.  else nextImage end mouseUp  @Blue Script of button "View Source": @Blue on mouseUp 8 show field "source" with visual effect barn door open end mouseUp  @Blue Script of this field: @Blue on mouseUp - hide me with visual effect barn door close end mouseUp & `{' a