Tuesday, May 15, 2018

SVGo: Go Language Library for SVG generation

ajstarks/svgo: Go Language Library for SVG generation @ GitHub
by ajstarks (Anthony Starks)

package main

import (
 "github.com/ajstarks/svgo"
 "os"
)

func main() {
 width := 500
 height := 500
 canvas := svg.New(os.Stdout)
 canvas.Start(width, height)
 canvas.Circle(width/2, height/2, 100)
 canvas.Text(width/2, height/2, "Hello, SVG", "text-anchor:middle;font-size:30px;fill:white")
 canvas.End()
}


link from:
Go Time #79: New Go branding strategy | News and podcasts for developers | Changelog

more from the same author:
ajstarks/go-proverbs: Deck documenting the "Go Proverbs"

No comments: