Example
package main
import (
"log"
"github.com/qbee-org/khroma"
)
func main() {
kh, err := khroma.From("#1c0416")
if err != nil {
log.Fatal(err)
}
kh.ToRgb() // "rgb 28 4 22"
kh.ToHex() // "#1c0416"
// Also accessible are kh.R, kh.G and kh.B.
kh.Set("rgb 07 01 22")
kh.ToRgb() // "rgb 07 01 22"
}
License
Khroma is licensed under the terms of Apache License 2.0.