Versions in this module Expand all Collapse all v1 v1.6.0 Apr 5, 2025 v1.4.0 Oct 6, 2024 Changes in this version + var DefaultCtx = NewCtx() + type Ctx struct + func NewCtx(modOptions ...ModOption) *Ctx + func NewCtxWith(ctx *Ctx, modOptions ...ModOption) *Ctx + func (ctx *Ctx) WithAnySlice(a interface{}, iterateTransFn func(originItem interface{}) Item, ...) string + func (ctx *Ctx) WithCsv(filename string) (string, error) + func (ctx *Ctx) WithItems(items []Item) string + func (ctx *Ctx) WithMap(m map[string]int) string + func (ctx *Ctx) WithMapFloat(m map[string]float64) string + type Item struct + Name string + Num float64 + type ModOption func(option *Option) + type Option struct + DrawIconBlock string + DrawIconPadding string + HideName bool + HideNum bool + MaxBarLength int + Order Order + PrefixNumLimit int + SuffixNumLimit int + type Order int + const NoNumLimit + const OrderAscCount + const OrderAscName + const OrderDescCount + const OrderDescName + const OrderOrigin