i,
Java
POLITECHNIKA RZESZOWSKA - Wydział DefctrotechnUd i InfometyM
import java.awt.*; import javax.swing.*; public class JSplitPaneDemo extends JFrame { JSplitPaneDemo() { | |
JTree tree = new JTree(); StringU data = { " JSplitPane", " JTree", JList list = new JList(data); |
" JList" ); |
JSplitPane splitPane = new JSplitPane(); | |
splitPane.setDividerLoaation(150); splitPane.setContinuousLayout(true); splitPane.setLeftCcraponent (tree); splitPane.setRightComponent(list); |
►a ►a— |
getContentPane().add(splitPane); setDefaultCloseOperation(JFrame.EXIT_ON CLOSE); setTitle("JSplitPaneDemo"); | |
setvisible(true); | |
public static void main(String() args) ( new JSplitPaneDemo(); L > | |
f |