Custom properties className & style are available only for cells (at the
moment).
If you want to style an entire row you can style all the cells in it.

If you want to style all rows or all cells or other properties across the
table you can use

cssClassNames

Read -
http://code.google.com/apis/visualization/documentation/gallery/table.html#Configuration_Options

<http://code.google.com/apis/visualization/documentation/gallery/table.html#Configuration_Options>
ChartMan


On Fri, Jul 9, 2010 at 11:14 PM, laurenty <[email protected]> wrote:

> Doing this:
>
> function drawVisualization() {
>  // Create and populate the data table.
>  var data = new google.visualization.DataTable();
>  data.addColumn('string', 'Name');
>  data.addColumn('number', 'Height');
>  data.addColumn('boolean', 'Smokes');
>  data.addRows(3);
>  data.setCell(0, 0, 'Tong Ning mu');
>  data.setCell(1, 0, 'Huang Ang fa');
>  data.setCell(2, 0, 'Teng nu');
>  data.setCell(0, 1, 174);
>  data.setCell(1, 1, 523);
>  data.setCell(2, 1, 86);
>  data.setCell(0, 2, true);
>  data.setCell(1, 2, false);
>  data.setCell(2, 2, true);
>
>  // individual cell properties work
>  data.setProperty(0, 0, 'style', 'background-color: red;');
>
>  // trying to set a class on a row - does not work
>  data.setRowProperty(1, 'className', 'myclass');
>
>  // trying to set the style for a row - does not work
>  data.setRowProperties(2, {style: 'background-color: red;'});
>
>  // Create and draw the visualization.
>  visualization = new
> google.visualization.Table(document.getElementById('table'));
>  visualization.draw(data, {allowHtml: true});
> }
>
> Setting the properties on a row does not seem to have any effect on
> the output even with allowHtml set to true;
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To post to this group, send email to
> [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-visualization-api%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-visualization-api?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" 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-visualization-api?hl=en.

Reply via email to