func ShapeHref(shape string) string {
	return "http://maps.google.com/mapfiles/kml/shapes/" + shape + ".png"
}
ShapeHref returns the href of the icon with the specified shape. See
http://kml4earth.appspot.com/icons.html#shapes.
package icon
import (
	"strconv"
	"github.com/twpayne/go-kml/v2"
)
func CharacterHref(c rune) string {
	switch {
	case '1' <= c && c <= '9':
		return PaletteHref(3, int(c-'1'))
	case 'A' <= c && c <= 'Z':
		return PaletteHref(5, int((c-'A')%8+16*((31-c+'A')/8)))
	default:
		return ""
	}
}
func DefaultHref() string {
	return PushpinHref("ylw")
}
func NoneHref() string {
	return PaletteHref(2, 15)
}
func NumberHref(n int) string {
	if 1 <= n && n <= 10 {
		return PaletteHref(3, (n-1)%8+16*((n-1)/8))
	}
	return ""
}
func PaddleHref(id string) string {
	return "https://maps.google.com/mapfiles/kml/paddle/" + id + ".png"
}
func PaddleIconStyle(id string) kml.Element {
	return kml.IconStyle(
		kml.HotSpot(kml.Vec2{X: 0.5, Y: 0, XUnits: kml.UnitsFraction, YUnits: kml.UnitsFraction}),
		kml.Icon(
			kml.Href(PaddleHref(id)),
		),
	)
}
func PaletteHref(pal, icon int) string {
	return "https://maps.google.com/mapfiles/kml/pal" + strconv.Itoa(pal) + "/icon" + strconv.Itoa(icon) + ".png"
}
func PushpinHref(color string) string {
	return "https://maps.google.com/mapfiles/kml/pushpin/" + color + "-pushpin.png"
}