Spinning rod animation/Text: Difference between revisions

Content added Content deleted
m (→‎{{header|REXX}}: added a programming note; commented that this REXX program also works with Regina REXX.)
m (→‎{{header|REXX}}: added whitespace.)
Line 1,083: Line 1,083:
::* Regina REXX   (see the programming note below.)
::* Regina REXX   (see the programming note below.)
<lang rexx>/*REXX program displays a "spinning rod" (AKA: trobbers or progress indicators). */
<lang rexx>/*REXX program displays a "spinning rod" (AKA: trobbers or progress indicators). */

if 4=='f4'x then bs= "16"x /*EBCDIC? Then use this backspace chr.*/
if 4=='f4'x then bs= "16"x /*EBCDIC? Then use this backspace chr.*/
else bs= "08"x /* ASCII? " " " " " */
else bs= "08"x /* ASCII? " " " " " */

signal on halt /*jump to HALT when user halts pgm.*/
signal on halt /*jump to HALT when user halts pgm.*/
$= '│/─\' /*the throbbing characters for display.*/
$= '│/─\' /*the throbbing characters for display.*/
Line 1,091: Line 1,093:
call delay .25 /*delays a quarter of a second. */
call delay .25 /*delays a quarter of a second. */
end /*j*/
end /*j*/

halt: say bs ' ' /*stick a fork in it, we're all done. */</lang>
halt: say bs ' ' /*stick a fork in it, we're all done. */</lang>
Programming note: &nbsp; this REXX program makes use of &nbsp; '''DELAY''' &nbsp; BIF which delays (sleeps) for a specified amount of seconds.
Programming note: &nbsp; this REXX program makes use of &nbsp; '''DELAY''' &nbsp; BIF which delays (sleeps) for a specified amount of seconds.