lettericon

package
v3.21.0 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2024 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultBackgroundColor *color.RGBA

Functions

func ColorFromHex

func ColorFromHex(hex string) (*color.RGBA, error)

func ColorToHex

func ColorToHex(c color.Color) string

ColorToHex returns the #rrggbb hex string for a color

func IconPath

func IconPath(letter string, size string, colr *color.RGBA, format string) string

func MainLetterFromURL

func MainLetterFromURL(URL string) string

func ParseIconPath

func ParseIconPath(fullpath string) (string, *color.RGBA, int, string)

path is like: lettericons/M-144-EFC25D.png

func RenderPNG

func RenderPNG(letter string, bgColor color.Color, width int, out io.Writer) error

func RenderSVG

func RenderSVG(letter string, bgColor color.Color, out io.Writer) error

RenderSVG writes an SVG lettericon for this letter and color

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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