blob: 7bd1f0a1942bf1ea60dc04b18d430b61213036c2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/* Listing3804.java */
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class Listing3804
extends JFrame
implements TableData
{
public Listing3804()
{
super("JTable 1");
addWindowListener(new WindowClosingAdapter(true));
JTable table = new JTable(DATA, COLHEADS);
Container cp = getContentPane();
cp.add(new JLabel("Alte c\'t-Ausgaben:"), BorderLayout.NORTH);
cp.add(new JScrollPane(table), BorderLayout.CENTER);
}
public static void main(String[] args)
{
Listing3804 frame = new Listing3804();
frame.setLocation(100, 100);
frame.setSize(300, 200);
frame.setVisible(true);
}
}
|