Here you can find the source of borderlessScrollPane(final Component component)
Parameter | Description |
---|---|
component | the component to add to the scroll pane. |
public static JScrollPane borderlessScrollPane(final Component component)
//package com.java2s; //License from project: Apache License import javax.swing.*; import java.awt.*; public class Main { /**/*w w w . ja va 2 s.c om*/ * Returns a new JScrollPane with the specified component and with an empty border. * * @param component the component to add to the scroll pane. * @return a new scroll pane. */ public static JScrollPane borderlessScrollPane(final Component component) { JScrollPane pane = new JScrollPane(component); pane.setBorder(BorderFactory.createEmptyBorder()); return pane; } }