Documentation ¶
Index ¶
- Variables
- func AutoNewPicture(width int, dpi float64, padding int, fontSize float64) *autoPicture
- func LoadFont(fontPath string) (*truetype.Font, error)
- func LoadPicture(filepath string) *image.RGBA
- func NewColor(R, G, B, A uint8) *image.Uniform
- func NewColorPicture(width, height int, color color.Color) *image.RGBA
- func NewPictureWithBackGround(png *image.RGBA, dpi float64, padding int, fontSize float64) *picture
- func RGBA(R, G, B, A uint8) *image.Uniform
- func ReadFont(fontfile io.Reader) (*truetype.Font, error)
- func ReadPicture(file io.Reader) *image.RGBA
- func SetDefaultFont(font *truetype.Font)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Transparent = image.Transparent White = image.White Black = image.Black Red = image.NewUniform(color.RGBA{255, 0, 0, 255}) Green = image.NewUniform(color.RGBA{0, 255, 0, 255}) Blue = image.NewUniform(color.RGBA{0, 0, 255, 255}) )
Functions ¶
func AutoNewPicture ¶ added in v1.1.0
func LoadPicture ¶ added in v1.1.0
func NewColorPicture ¶ added in v1.1.0
Color can be generated using text2picture.NewColor()
func NewPictureWithBackGround ¶
png: background padding: text left and right padding fontSize: font size in points
func SetDefaultFont ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.