JSplitPane: setOrientation(JSplitPane.HORIZONTAL_SPLIT) : JSplitPane « javax.swing « Java by API






JSplitPane: setOrientation(JSplitPane.HORIZONTAL_SPLIT)

  
import java.awt.BorderLayout;

import javax.swing.JFrame;
import javax.swing.JSplitPane;

public class MainClass {
  public static void main(String args[]) {
    JFrame frame = new JFrame("JSplitPane Sample");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    JSplitPane splitPane = new JSplitPane();
    splitPane.setOrientation(JSplitPane.HORIZONTAL_SPLIT);
    frame.add(splitPane, BorderLayout.CENTER);
    frame.setSize(300, 200);
    frame.setVisible(true);
  }
}

           
         
    
  








Related examples in the same category

1.JSplitPane.LAST_DIVIDER_LOCATION_PROPERTY
2.JSplitPane.VERTICAL_SPLIT
3.new JSplitPane(int newOrientation, Component newLeftComponent, Component newRightComponent)
4.JSplitPane: addHierarchyListener(HierarchyListener l)
5.JSplitPane: getBottomComponent()
6.JSplitPane: getDividerLocation()
7.JSplitPane: getLeftComponent()
8.JSplitPane: getRightComponent()
9.JSplitPane: getTopComponent()
10.JSplitPane: resetToPreferredSizes()
11.JSplitPane: setContinuousLayout(boolean newContinuousLayout)
12.JSplitPane: setDividerLocation(double proportionalLocation)
13.JSplitPane: setDividerSize(int newSize)
14.JSplitPane: setLeftComponent(Component comp)
15.JSplitPane: setOneTouchExpandable(boolean newValue)
16.JSplitPane: setResizeWeight(double value)
17.JSplitPane: setRightComponent(Component comp)