medium support for all axis names.
This commit is contained in:
parent
f7c53080bd
commit
a846d2f4e8
3 changed files with 35 additions and 5 deletions
|
|
@ -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() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue