elements

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 3, 2021 License: BSD-3-Clause Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Anchor

type Anchor [2]float64

type Box

type Box [2]int

type Image

type Image struct {
	Style
	Src    string
	Reader io.Reader
	Img    image.Image
	Width  int
	Height int
	Limit  int
}

func (Image) Draw

func (i Image) Draw(ctx *gg.Context) error

type Style

type Style struct {
	Color           color.Color
	BackgroundColor color.Color
	FontFile        string
	FontFace        font.Face
	Top             float64
	Left            float64
	FontSize        float64
	Anchor          Anchor
	Width           float64
	Align           gg.Align
	LineSpacing     float64
	BorderRadius    float64
	Box             Box
}

type Text

type Text struct {
	Style
	Content string
	Wrapped bool
}

func (Text) Draw

func (t Text) Draw(ctx *gg.Context) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL