私はハイチャートを使って数学的計算と電子用語を表示していますので、ハイチャート上に敬語を表示する必要がありますXaxis titleとYaxis title to superscript私は方法を試してみましたが、まだ私はsoln html subを取得していないし、supタグはそこで働いていない私に適切な解決策を教えてください。ハイチャート上の内容を表示XaxisとYaxisのタイトルを下付き文字と上付き文字の形で
5
A
答えて
10
useHTML
propertyの使用を検討してください:
...
//some options
title: {
useHTML: true,
text: "<sub>sub</sub>normal<sup>sup</sup>"
}
//other options
...
0
これは、グラフのタイトル、軸ラベル、凡例ラベルとデータラベルでuseHTMLプロパティを使用する方法である -
$(function() {
$('#container').highcharts({
\t \t chart: {
type: 'column'
},
credits : {
enabled : false
},
title: {
text: 'Chart Title<sup>1</sup>',
useHTML : true,
},
xAxis: {
\t \t \t categories: [ 'label1','label2','label3<sup>4</sup>','label4'],
title:{
enabled: false
}, \t \t \t \t \t \t
labels: {
useHTML : true,
title: {
enabled: false
}
},
},
yAxis: {
title: {
enabled: false
},
labels: {
useHTML : true,
formatter:function(){
if(this.value != 10){
return this.value;
}else{
return this.value + '<sup> 2</sup>';
} \t \t \t \t \t
} \t \t \t \t \t \t \t \t
} \t \t \t \t \t \t
},
legend: {
useHTML : true,
borderWidth: 0,
labelFormatter:function(){
if(this.name != 'legend1'){
return this.name;
}else{
return this.name + '<sup> 5</sup>';
} \t \t \t \t \t
} \t
},
plotOptions: {
column: {
dataLabels: {
enabled: true,
useHTML : true,
y:-1,
formatter:function(){
if(this.y != 0){
if(this.y > 8 && this.y < 10){
return this.y + '<sup> 3</sup>';
}else{
return this.y;
}
}else{
return null;
} \t \t \t \t \t
} \t \t \t \t
} \t \t \t \t \t \t
} \t \t \t
}, \t \t
series: [{
data: [{
y: 14.913
}, {
y: 8.281
}, {
y: 3.592
}, {
y: 3.017
}],
showInLegend: false,
},{
name: 'legend1',
color: 'rgb(14,178,89)'
},{
name: 'legend2',
color: 'rgb(100,100,9)'
}]
});
});
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="min-width: 310px; height: 400px; max-width: 800px; margin: 0 auto"></div>
関連する問題
- 1. WP7の上付き文字と下付き文字
- 2. MathML - 左下付き文字と上付き文字
- 3. Gnuplot:x軸とy軸のラベルの下付き文字と上付き文字
- 4. グラフィカルユーザーインターフェイス(GUI)で表示されるMatlabの下付き文字と上付き文字の書き方は?
- 5. Android .setmesage(下付き文字または上付き文字)
- 6. Java文字列の上付き文字
- 7. 文字列IOSの上付き文字
- 8. MigraDocの上付き文字
- 9. 上付き文字は、TextField
- 10. XML内の上付き文字/下付き文字をHTMLに変換する方法
- 11. Windowsの下付き文字2のユニコード文字を表示できません
- 12. NSAttributedStringを使用して下付き文字と上付き文字を作成する方法は?
- 13. 上付き文字のテキストを保存して表示する
- 14. aspラベルの上付き文字
- 15. jfreeチャートの上付き文字
- 16. プロットマス式の上付き文字(w/ggplot2)
- 17. データファイルから読み込んだgnuplotのラベルの上付き文字/下付き文字
- 18. Visual Studioで上付き文字/上付きインデックスを書き込む方法は?
- 19. 下付き文字、コアテキスト付きiPhone
- 20. ggplot2 - 上付き文字でテキストに注釈を付ける
- 21. 円ラベルに値と上付き文字を追加する
- 22. 文字列に上付き文字を書き、MessageBox.Show()を使用して表示する方法は?
- 23. プロットの下付き文字R
- 24. 下付き文字のUTF8記号
- 25. Reg Ex付きの文字列形式
- 26. 名前付きタプルの文字列形式を上書きできますか?たとえば
- 27. UILabelで3番目の電源/立方体の文字の上付き文字を文字列として表示する方法は?
- 28. %をプロットマスの下付き文字として使用する
- 29. PHPのインクルードファイル内のアクセント付き文字
- 30. SQL Oracleソート文字列(数字)と(数字付き文字)
あなたを持っていますここで説明したようなものを試しました:http://api.highcharts.com/highcharts#xAxis.title.text –
あなたはsometを行うことができるようです''は上付き文字の位置に3進数/変数を、同じものにはを添字として使用します。 –