The easiest way to have a button in a Header is to create a Header
with a ButtonCell
ButtonCell buttonCell = new ButtonCell();
Header myHeader = new Header(buttonCell);
myTable.addColumn(column, myHeader);
You can also extend the ClientBundle defined in CellTable.Resource/
Style as tbroyer suggests. The CSS dev guide has more info:
http://code.google.com/webtoolkit/doc/latest/DevGuideClientBundle.html
On Oct 22, 9:11 am, Thomas Broyer <
t.bro...@gmail.com> wrote:
> On 22 oct, 14:33, Rodrigue Lagoue <
rlag...@googlemail.com> wrote:
>
> > Hi all,
>
> > does somebody know, if it is possible to customize the headers' style of a
> > CellTable. I would like to have for exemple header that looks like a
> > button...
>
> If you can do it entirely with CSS, then extend the CellTable.Resource
> and CellTable.Style to provide your own .cellTableHeader (and
> possibly .cellTableFirstColumnHeader and/
> or .celltableLastColumnHeader), and pass it to the constructor.
> This is used in the DynatableRf sample:
http://code.google.com/p/google-web-toolkit/source/browse/trunk/sampl...
>
> Otherwise, you can provide your own Header implementation when adding
> a column, instead of giving the header as just the text (as a String).
> That way, you can generate the HTML snippet you want for your headers.
> This is used in the Expenses sample to make the table "sortable":
http://code.google.com/p/google-web-toolkit/source/browse/trunk/sampl...http://code.google.com/p/google-web-toolkit/source/browse/trunk/sampl...
>
> You can of course use both at the same time, as is done in the
> Expenses sample:
http://code.google.com/p/google-web-toolkit/source/browse/trunk/sampl...