Just did my very  first Google bar chart. Pretty straight forward, except 
that I can't figure out how to inhibit highlighting if a user clicks on one 
of the bars. Currently, a white inner box appears if I click on it. How do 
I inhibit this? At this point, I don't intend to provide for any 
interactive capability except for hover annotations. Thanks, Mike

Here's my current code:

<script type="text/javascript" 
src="https://www.google.com/jsapi?autoload={'modules':[{'name':'visualization','version':'1','packages':['corechart']}]}"></script>
<script type="text/javascript">
google.setOnLoadCallback(drawChart);
function drawChart() {
  var data = google.visualization.arrayToDataTable([
    ['Index', 'FFIUS', 'S&P 500'],
    ['10 Yrs', .77, .74],
    ['5 Yrs', 1.22, 1.12],
    ['3 Yrs', .62, .59],
    ['1 Yr', .48, .46],
    ['YTD', .05, .06],
    ['6 Mos', .12, .11],
    ['3 Mos', .03, .03],
    ['1 Mo', .02, .03]
  ]);
  var options = {
    chart: {bars: 'horizontal'},
    backgroundColor: { fill: '#f0f0f0' },
    colors: ['#1F4E79','#ADB9CA'],
    chartArea: {left: 50,top: 20, right: 40, bottom: 20, 
width:'85%',height:'75%', backgroundColor: '#f0f0f0'},
    legend: {textStyle: {fontName: 'Calibri', fontSize: 12, bold: true}, 
alignment: "center", position: "bottom"},
    bar: {groupWidth: "90%"},
    vAxis: {textStyle: {fontName: 'Calibri', fontSize: 12,bold: true}},
    hAxis: {
     textStyle: {fontName: 'Calibri', fontSize: 12,bold: true},
     format: '#%',
      viewWindowMode: 'explicit',
          viewWindow: {
                max: 1.25
      }
    }
  };
  var chart = new google.visualization.BarChart(
    document.getElementById('ffius-returns'));
  chart.draw(data, options);
}
</script>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to