2017-04-04 16 views
0

googleのコンボチャートの注釈に異なるcolorauraColorを付けたいと思います。誰でもそれがポーズで、どのように言えるでしょうか?注釈に異なる色を設定するにはどうすればいいですか?

これは現在のオプションです。

annotations: { 
      stemColor: 'none', 
      textStyle: { 
       fontName: 'Arial', 
       color: 'white', 
       auraColor: 'grey', 
       fontSize: 11, 
       alwaysOutside: true, 
      } 
     }, 

また、私はこれを試しましたが、動作しません。

annotations: { 
      0:{stemColor: 'none', 
       textStyle: { 
        fontName: 'Arial', 
        color: 'white', 
        auraColor: 'grey', 
        fontSize: 11, 
        alwaysOutside: true 
       }}, 
      1:{stemColor: 'none', 
       textStyle: { 
        fontName: 'Arial', 
        color: 'black', 
        auraColor: 'red', 
        fontSize: 11, 
        alwaysOutside: true, 
       }}, 
      2:{stemColor: 'none', 
       textStyle: { 
        fontName: 'Arial', 
        color: 'blue', 
        auraColor: 'white', 
        fontSize: 11, 
        alwaysOutside: true, 
       }}     
     }, 

事前

答えて

0

でのおかげで、これは私が探しているものですはい... seriesオプションを使用して

series: { 
    0:{ 
    annotations: { 
     stemColor: 'none', 
     textStyle: { 
     fontName: 'Arial', 
     color: 'white', 
     auraColor: 'grey', 
     fontSize: 11, 
     alwaysOutside: true 
     } 
    } 
    }, 
    1:{ 
    annotations: { 
     stemColor: 'none', 
     textStyle: { 
     fontName: 'Arial', 
     color: 'black', 
     auraColor: 'red', 
     fontSize: 11, 
     alwaysOutside: true, 
     } 
    } 
    }, 
    ... 
+0

を試してみてください。ありがとうございました :) –

関連する問題