List of usage examples for javax.swing JViewport add
public Component add(Component comp)
From source file:org.openmicroscopy.shoola.agents.metadata.editor.GeneralPaneUI.java
/** Builds and lays out the components. */ private void buildGUI() { setLayout(new BorderLayout(0, 0)); container.add(propertiesTaskPane);/*w w w .j av a2s . c o m*/ container.add(annotationTaskPane); pane = new JScrollPane(); JViewport viewport = pane.getViewport(); viewport.add(container); viewport.setBackground(UIUtilities.BACKGROUND_COLOR); add(toolbar, BorderLayout.NORTH); add(pane, BorderLayout.CENTER); }