After giving this more thought, I think the best option is to get rid of
ColumnWidths and roll it into CellTable directly, so you would have:
CellTable.setColumnWidth(Column col, double width, Unit unit)
CellTable.setColumnWidth(Column col, String)

I suggest this for two reasons:

   1. We don't need a CellTable#refreshColumnWidths() method because
   CellTable always knows when the width changes.  Both the ColumnWidths
   proposal and Column#setWidth() have the problem that the table isn't
   notified of the change.  We could add event handlers to ColumnWidths/Column,
   but thats a bit of overkill.
   2. I'm not 100% sold on Column#setWidth() because its possible to use the
   same column in two tables but have different widths.  For example, a source
   table and a destination table that both contain a summary column.

Thanks,
John LaBanca
[email protected]


On Wed, Jan 5, 2011 at 9:31 PM, Miroslav Pokorny <[email protected]
> wrote:

> Minor suggestion but would not ColumnWidthSource be a better name than
> ColumnWidths, after all it is a source of column widths given a column. When
> i see classes w/ plural names, i think of classes w/ static helpers
> java.util.Collections. Guice is another example of this naming style.
>
>  --
> http://groups.google.com/group/Google-Web-Toolkit-Contributors
>

-- 
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to