View Full Version : set td class in TableLayout

27 Aug 2010, 4:54 PM
I am using a Panel with a layout='table' and cannot figure out how to set the class on the td elements in the generated table. I have tried setting cls as a parameter of the Panel and the individual items added to the Panel, but neither one actually set the class of the td, rather they set the class for the interior divs. How do I set it for the tds?

27 Aug 2010, 5:02 PM
Never mind, i found the answer... setting the cellCls for the individual items does the trick. Hard to find in the API docs cause I couldn't find cellCls as a config parameter anywhere.

27 Aug 2010, 11:14 PM
Even in the documentation?


28 Aug 2010, 3:42 AM
Yeah that's where I found it. I'm just so used to clicking the config options link to scan through the config options, whereas the cellCls description is not in that section.

28 Aug 2010, 4:45 AM
It's one of those difficult to document options.

It's not really a regular config option of BoxComponent. Only of a BoxComponent that is a child of a Container which is using table layout.

This is similar to region, split, flex, anchor , fieldLabel etc.

I refer to these as "hints" rather than configurations because they are used by a supervising layout manager to adjust its layout.

There's no real good place to document them.

29 Aug 2010, 6:23 PM
Yeah I suppose that makes sense. Thanks for the reply.