You need to tweak the selector a bit and change "font:family" to
"font-family":
#chart_div table {
font-family: "Lucida Console Unicode", "Lucida Grande", sans-serif;
}
On Tuesday, June 5, 2012 6:16:54 PM UTC-4, Kushan wrote:
>
> I want to change the font-family of the table. I am updating
> stylesheet using the id of the div tag containing the table:
>
> #chart_div {
> font:family: "Lucida Console Unicode", "Lucida Grande", sans-serif;
> }
>
> However, it doesn't seem to be working.
>
> If I add any other attributes, such as color:red, they however do
> work.
>
> What am I doing wrong?
>
> I am using the following code to display a table:
>
>
> <script type="text/javascript">
> google.load('visualization', '1.0', {'packages':
> ['corechart','table']});
> google.setOnLoadCallback(initialize);
>
> function initialize() {
> var query = new google.visualization.Query('https://docs.google.com/
> spreadsheet/pub?key=123'<https://docs.google.com/spreadsheet/pub?key=123'>);
>
> query.send(handleQueryResponse);
> }
>
> function handleQueryResponse(response) {
> if (response.isError()) {
> alert('Error in query: ' + response.getMessage() + ' ' +
> response.getDetailedMessage());
> return;
> }
>
> var data = response.getDataTable();
> var table = new
> google.visualization.Table(document.getElementById('chart_div'));
> table.draw(data,{allowHtml:true});
> }
>
> </script>
>
> <div id="chart_div"></div>
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/google-visualization-api/-/xK1YPA7iJ9QJ.
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.