You are here

Quick Interactive Web Pages with Java Sketchpad - A Simple Example: .gsp to .html

Author(s): 
Michael E. Mays

Suppose you want to provide your students an animated illustration of an acute angle.  In Sketchpad you might use a horizontal line segment as one side of the angle, the arc command to create an arc in the first quadrant, a point on the arc to determine the terminal side, and an animate button to allow the point to move on the arc.  This approach is illustrated in the following Sketchpad sketch -- to download the gsp file, click on the sketch.

   

This works in Sketchpad, but you can not save it from Sketchpad as a working HTML file.  The problem reported is

"Some objects in this sketch are not supported by this version of JavaSketchpad, and will not appear in your applet. (These objects have been selected.)"

The applet saved is not functional, but the HTML page displayed in Sketchpad looks like this:

.

The problem is that the current version of JavaSketchpad does not support the arc construction, which means the point cannot be selected on the arc, and so the Animate Objects button is broken as well. As you will see when you click the applet link, only the unbroken objects survive.

A work-around could be to draw a line segment in the first quadrant and animate the angle using a point on the line segment to locate the terminal side.  This version of the Sketchpad file can be downloaded and run (if Sketchpad is on your computer) -- here is the working applet saved from it:   

In contrast to our example on the first page, the applet here is embedded in this page, rather than opened in a new page.  You may choose how to make the most effective use of the animated illustration that JavaSketchpad provides.

Michael E. Mays, "Quick Interactive Web Pages with Java Sketchpad - A Simple Example: .gsp to .html," Convergence (December 2004)