Text

Write text to the image.

Parameters

Return Values

The instance of *imgo.Image .

Examples

package main

import (
    "github.com/fishtailstudio/imgo"
    "golang.org/x/image/colornames"
    "image/color"
)

func main() {
    fontPath := "/System/Library/Fonts/Supplemental/Arial.ttf"
    imgo.Canvas(500, 500, color.White).
        Text("Hello World", 50, 50, fontPath, colornames.Chocolate, 50, 100).
        Save("out.png")
}

Last updated