JuggleAnim is free software, released under the GNU General Public License. We encourage others to include this applet in their own web pages; as you will see this is quite simple.
To use JuggleAnim in your page, you only need a single file from the JuggleAnim
distribution, called JuggleAnim.jar
. This Java ARchive
includes a single applet class usable within a web page:
JuggleAnim.class
, which is configurable to contain any or
all of the following elements: An animation view, a pattern input text field,
a pattern browser list, and a siteswap generator.
JuggleAnim.class
, which is an application version of the applet. Use command line
option "help" for a help message.
siteswapGenerator.class
, which gives command line access to the siteswap generator.
Use no command line options for a help message.
When used as an applet, JuggleAnim looks for five parameters within the
<APPLET>
tag. These are named config
,
pattern
, patternfile
,
type
, and title
. All of these parameters are optional,
and are set as follows:
config
animator
none
(no animator), panel
(animate in a panel attached to
the applet), window
(animate in a single detached window), and
multiplewindows
(multiple detached windows, for more than one animation at a time). The default is
panel
.
generator
siteswap
.
(Actually the generators are dynamically loaded, so if you wrote your own you could
use it instead. When you specify generator=filename
, the applet looks
for a class file filenameGenerator.class
and loads it.) The default is
no generator.
editor
true/false
)? If there is a generator
loaded all input is sent to it for interpretation before going to the animator. Otherwise,
you can either type in siteswap (or sync siteswap) notation, or input directly to the
animator in the same format used by the JuggleAnimApplet
"input" parameter.
The default value is false
.
lister
true/false
)? If you are using a generator
or viewing a pattern file then this will automatically be set to true
, otherwise the
default is false
.
pattern
patternfile
<APPLET>
tag.
The format of the pattern files is very simple: Each line is a separate pattern, and consists of an arbitrary-length label followed by one or more TAB characters, followed by instructions to be sent to the animator when the item is clicked. If there is no second field (after the tab), then the label still shows up in the listing but it is inactive.
type
type=window
the applet opens in a separate window, so that the menus can
be used. Otherwise it defaults to an embedded panel.
title
type=window
, then this parameter specifies the title of the
window.
Look at the HTML files in the JuggleAnim distribution for examples of how you can use the applet within a web page.