medium support for all axis names.

This commit is contained in:
Will Charczuk 2016-08-06 22:27:26 -07:00
parent f7c53080bd
commit a846d2f4e8
3 changed files with 35 additions and 5 deletions

View file

@ -44,7 +44,9 @@ func drawChart(res http.ResponseWriter, req *http.Request) {
},
},
XAxis: chart.XAxis{
Style: chart.StyleShow(),
Name: "Random Other Values",
NameStyle: chart.StyleShow(),
Style: chart.StyleShow(),
},
Series: []chart.Series{
mainSeries,
@ -57,8 +59,8 @@ func drawChart(res http.ResponseWriter, req *http.Request) {
graph.Elements = []chart.Renderable{chart.Legend(&graph)}
res.Header().Set("Content-Type", "image/svg+xml")
graph.Render(chart.SVG, res)
res.Header().Set("Content-Type", "image/png")
graph.Render(chart.PNG, res)
}
func main() {