svg

package
v2.4.5 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Colorize

func Colorize(src []byte, clr color.Color) []byte

Colorize creates a new SVG from a given one by replacing all fill colors by the given color.

func IsFileSVG added in v2.4.0

func IsFileSVG(path string) bool

func IsResourceSVG added in v2.4.0

func IsResourceSVG(res fyne.Resource) bool

IsResourceSVG checks if the resource is an SVG or not.

Types

type Config added in v2.4.0

type Config struct {
	Width  int
	Height int
	Aspect float32
}

type Decoder added in v2.4.0

type Decoder struct {
	// contains filtered or unexported fields
}

func NewDecoder added in v2.4.0

func NewDecoder(stream io.Reader) (*Decoder, error)

func (*Decoder) Config added in v2.4.0

func (d *Decoder) Config() Config

func (*Decoder) Draw added in v2.4.0

func (d *Decoder) Draw(width, height int) (*image.NRGBA, error)

Jump to

Keyboard shortcuts

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