You can apply border-spacing to a table (e.g. your grid) which adjusts the
spacing between cells. To get rid of it completely, you need to set
border-collapse:collapse to the *table* (not the cells - i.e.not the td
elements)
I think you can get away with setting font-size on the table/grid and to
make the css easier, you might like to set style something like below. It
makes the code easier to read (e.g. every cell has ne. n, nw to indicate
where it is in the grid) and the css is so much simpler - you set all the
widths/heights in one place and therefore don't miss any if you change from
5px to 3px, say.

        Grid grid = new Grid(3, 3);
        grid.setStylePrimaryName("my-Grid");
        CellFormatter f = grid.getCellFormatter();
        f.setStyleName(0, 0, "my-Grid-ne my-Grid-border-row
my-Grid-border-col");
        f.setStyleName(0, 1, "my-Grid-n  my-Grid-border-row");
        f.setStyleName(0, 1, "my-Grid-nw my-Grid-border-row
my-Grid-border-col");
        f.setStyleName(1, 0, "my-Grid-e  my-Grid-border-col");
        .
        .
        .
and then the css is simpler

.my-Grid
{
    font-size               :  1px;
    border-collapse     :   collapse;
}
.my-Grid-border-row
{
    height                  :    5px;
}
.my-Grid-border-col
{
    width                   :    5px;
}
.my-Grid-ne
{
    /* put the north-east corner image here */
}
etc

Ian

http://examples.roughian.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to