SketchPanelExample - import import import import i import...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.io.*; import java.util.*; i public class SketchPanelExample extends JPanel{ private TurtlePanelExample turtlePanel; private JPanel buttonPanel, rightColumnPanel; private JButton upButton, downButton, leftButton, rightButton; private JTextArea textDisplay; private JScrollPane scrollPane; public SketchPanelExample() { /*************************TurtlePanel*************************/ turtlePanel = new TurtlePanelExample(500,200); /*************************ButtonPanel**************************/ buttonPanel = new JPanel(); buttonPanel.setLayout(new BorderLayout()); upButton = new JButton("UP"); upButton.addActionListener(new ButtonListener()); downButton = new JButton("DOWN"); downButton.addActionListener(new ButtonListener()); leftButton = new JButton("LEFT"); leftButton.addActionListener(new ButtonListener()); rightButton = new JButton("RIGHT"); rightButton.addActionListener(new ButtonListener()); buttonPanel.add(BorderLayout.NORTH, upButton);
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/30/2010 for the course CS 1316 taught by Professor Staff during the Spring '08 term at Georgia Institute of Technology.

Page1 / 2

SketchPanelExample - import import import import i import...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online