View Full Version : Pretty Checkbox Columns in editable Grid

28 Apr 2012, 5:01 PM
Is there any way to convert the "True/False" values in Boolean columns to Y/N or have an actual checkbox display in the cell?

Here's my column:
ColumnConfig<RadarChartMeasure, Boolean> cc5 = new ColumnConfig<RadarChartMeasure, Boolean>(properties.visible(), 30, "Show?");
It renders True or False depending on the value of the boolean property. It would be nice to display Y or N or to actually render a checked or unchecked box in that column. Is there a simple way to do this?


9 May 2012, 7:17 AM

30 May 2012, 12:34 PM
Any ideas how to do this?

Colin Alworth
30 May 2012, 2:13 PM
Since this is in a Grid column, I'd make a custom cell for the Y/N option, or use the CheckBoxCell. A custom Cell would probably extend from AbstractCell, and in the render method draw either a Y or an N based on the value parameter. The CheckBoxCell will always draw an actual checkbox that can be manipulated and will update the model in the store.