google-chart icon indicating copy to clipboard operation
google-chart copied to clipboard

fontName ineffective

Open bennypowers opened this issue 8 years ago • 1 comments

      ready: function () {
        this.$.chart.set('options.fontName', "Roboto"); // BUG: this has no effect
        this.$.chart.set('options.fontSize', 25);
        this.$.chart.set('options.timeline', {showRowLabels: false});
        this.$.chart.redraw();
      },
screen shot 2017-04-13 at 11 12 10 am

With fontName and fontSize set, chart still reverts to Arial.

Same behavior when I initialize options as a polymer property on host.

bennypowers avatar Apr 13 '17 08:04 bennypowers

I think this issue sounds more like a problem with the underlying library? https://github.com/google/google-visualization-issues/issues If an option does not work when specified statically in the HTML, then it definitely would be. e.g. The following should definitely work if there is no bug in the google-visualization library:

<google-chart options='{"fontName": "Roboto"}' ...>

If that works, then your issue might be that no slices are watched on the options object.

wesalvaro avatar Jan 12 '18 03:01 wesalvaro