/* TextFrame.java */
import java.awt.*;
import java.net.*;
/**
* This TextFrame
class brings up a frame containing the text
* panel. The class constructor is normally called during the initialization of
* of a AlgAnimFrame
instance.
*
* @see TextPanel
*/
public class TextFrame extends Frame {
private Scrollbar vScrollbar;
private TransformPanel tp[];
static final int n_tf = 6;
/**
* Construct a text frame and initialize the text panel to be added to
* the text frame. By default, this frame is going to be displayed
* with its top-left corner at position (600,0). This can be changed
* in the constructor according to preference.
* @param sourceURL The URL of the algorithm source code to be display
* on the text panel.
*/
public TextFrame( URL sourceURL ) {
int j, k, m;
GridBagLayout lay = new GridBagLayout ();
this.setLayout( lay );
GridBagConstraints constraints = new GridBagConstraints();
System.out.println( "TextFrame( URL ) constructor" );
constraints.weightx = constraints.weighty = 100;
constraints.gridx = constraints.gridy = 0;
constraints.gridwidth = constraints.gridheight = 1;
constraints.fill = GridBagConstraints.BOTH;
move(600, 0);
setTitle("Transformations");
m = 0;
tp = new TransformPanel[n_tf*2];
for(k=0;k