java - padding of JTable via JScrollPane -


i have jtable in jscrollpane.

jtable table = new jtable(data, columnnames); jscrollpane scroll = new jscrollpane(); scroll.setviewportview(table); 

everything well, if need more space between scrollpanel , table? how can that? example: in html/css if use <div> tag, have "padding" method. need that.

you do

scroll.setborder(borderfactory.createemptyborder(10, 10, 10, 10)); 

Comments

Popular posts from this blog

matlab - Deleting rows with specific rules -

jquery - How would i go about shortening this code? And to cancel the previous click on click of new section? -