JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS : JScrollPane « javax.swing « Java by API






JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS

  



import javax.swing.JScrollPane;
import javax.swing.JTextArea;

public class Main {
  public static void main(String[] argv) throws Exception {
    JTextArea textArea = new JTextArea();
    JScrollPane pane = new JScrollPane(textArea);
    pane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
    pane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);

  }
}

   
    
  








Related examples in the same category

1.JScrollPane.VERTICAL_SCROLLBAR_ALWAYS
2.new JScrollPane(Component view, int vsbPolicy, int hsbPolicy)
3.JScrollPane: getHorizontalScrollBar()
4.JScrollPane: getHorizontalScrollBarPolicy()
5.JScrollPane: getVerticalScrollBar()
6.JScrollPane: getVerticalScrollBarPolicy()
7.JScrollPane: setColumnHeaderView(Component view)
8.JScrollPane: setCorner(String key, Component corner)
9.JScrollPane: setRowHeaderView(Component com)
10.JScrollPane: setViewportView(Component view)