Java JScrollBar Design

I guess you are looking for a transparent scrollbar. This is just presented as an idea(NOT tested code): import java.awt.*; import javax.swing.*; import javax.swing.border.*; import javax.swing.plaf.basic.*; public class TranslucentScrollBarTest { public JComponent makeUI() { JTextArea cmp = new JTextArea(); String str = “1234567890abcdefghijklmnopqrstuvwxyz”; for(int i=0; i<20; i++) { cmp.append(str+str+”\n”); } cmp.setForeground(Color.WHITE); cmp.setBackground(Color.BLACK); cmp.setOpaque(true); JScrollPane scrollPane … Read more

JTable with horizontal scrollbar

First, add your JTable inside a JScrollPane and set the policy for the existence of scrollbars: new JScrollPane(myTable, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED); Then, indicate that your JTable must not auto-resize the columns by setting the AUTO_RESIZE_OFF mode: myJTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);