List of usage examples for javax.swing JPanel JPanel
public JPanel(boolean isDoubleBuffered)
JPanel
with FlowLayout
and the specified buffering strategy. From source file:Main.java
public static JComponent scrollV(String title, JComponent content) { JPanel p = new JPanel(new BorderLayout()); p.setBorder(BorderFactory.createTitledBorder(title)); JScrollPane scroll = new JScrollPane(content); scroll.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER); scroll.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS); p.add(scroll);/*from w w w . j av a2 s .c o m*/ return p; }
From source file:Main.java
public Main() { setLayout(new BorderLayout()); JPanel east = new JPanel(new BorderLayout()); add(east, BorderLayout.EAST); BasicArrowButton north = new BasicArrowButton(BasicArrowButton.NORTH); east.add(north, BorderLayout.NORTH); BasicArrowButton south = new BasicArrowButton(BasicArrowButton.SOUTH); east.add(south, BorderLayout.SOUTH); }