FileDocCategorySizeDatePackage
SimpleBrowser.javaAPI DocExample1514Sat Nov 25 11:54:28 GMT 2000None

SimpleBrowser

public class SimpleBrowser extends JFrame

Fields Summary
static JTextField
textField
static JEditorPane
editor
Constructors Summary
public SimpleBrowser(String s)

        super(s);

        JPanel panel = new JPanel();
        panel.setLayout(new BorderLayout());
        panel.setBorder(BorderFactory.createRaisedBevelBorder());

        editor = new JEditorPane();
        textField  = new JTextField();
        JScrollPane scrollPane = new JScrollPane(editor);

        editor.setEditable(false);

        panel.add(new JLabel("Location:  "), BorderLayout.WEST);
        panel.add(textField, BorderLayout.CENTER);

        getContentPane().add(panel, BorderLayout.NORTH);
        getContentPane().add(scrollPane, BorderLayout.CENTER);

        textField.addActionListener(new TextFieldListener());
    
Methods Summary
public static voidmain(java.lang.String[] args)

        SimpleBrowser frame = new SimpleBrowser("Simple Browser");
        frame.setSize(400,400);
        frame.setVisible(true);