List of usage examples for javax.swing JScrollPane setOpaque
@BeanProperty(expert = true, description = "The component's opacity") public void setOpaque(boolean isOpaque)
From source file:picocash.components.AccountPanel.java
protected JScrollPane createTransactionScrollPane(ListModel listModel) { final JXList transactionList = new JXList(listModel); transactionList.setBackground(TRANSPARENT_LIST_BACKGROUND); transactionList.setCellRenderer(new DefaultListRenderer(new TransactionProvider())); transactionList.setRolloverEnabled(true); transactionList.addHighlighter(/* www . j a v a2s . c o m*/ new TransactionPainterHighlighter(HighlightPredicate.ALWAYS, new MattePainter(Color.WHITE))); transactionList.addHighlighter( new TransactionPainterHighlighter(HighlightPredicate.ROLLOVER_ROW, new PinstripePainter())); final JScrollPane scrollPane = new JScrollPane(transactionList); scrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER); scrollPane.setViewportBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); scrollPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0)); transactionList.setOpaque(true); scrollPane.setOpaque(true); return scrollPane; }