digideskio / google-web-toolkit-incubator

Automatically exported from code.google.com/p/google-web-toolkit-incubator
0 stars 0 forks source link

Set border between headerWrapper and dataWrapper in ScrollTable #368

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I'm using ScrollTable and would like to set a 1px border between the header and 
the data areas.  Unfortunately, ScrollTable#createWrapper explicitly sets the 
border of the wrapper divs to zero.  I can see why a left or right border could 
mess up the columns, but I can't see any reason to prohibit top and bottom 
borders.  My current workaround is to subclass ScrollTable:

 ScrollTable scrollTable = new ScrollTable(dataTable, headerTable) {
      @Override
      protected Element createWrapper(String cssName) {
        Element wrapper = super.createWrapper(cssName);
        wrapper.getStyle().setProperty("borderBottom", "1px solid #ddd");
        return wrapper;
      }
    };

I would much prefer to do this in CSS.  One option I think is to set borderLeft 
and borderRight instead of border in ScrollTable.

Or is there a better way to do this?

Original issue reported on code.google.com by will.h...@gmail.com on 26 Jul 2010 at 8:40