Documentation ¶
Index ¶
- Constants
- Variables
- func ColorError(name string) string
- func ColorHeading(name string) string
- func ColorName(name string) string
- func ColorPath(name string) string
- func ColorTypeName(name string) string
- func ColorValue(name string) string
- func ColoredOptions(options []string, colorizer Colorizer) string
- func EnableColor(force bool)
- func GetSize() (int, int, error)
- func IndentString(indent int) string
- func Options(options []string) string
- func PrintIndent(indent int)
- func ProcessColorizeFlag(colorize string) error
- type Colorizer
- type Table
- type TableStyle
- type TreePrefix
Constants ¶
View Source
const ( TopSeparatorTableStyle = 1 << iota ColumnSeparatorTableStyle RowSeparatorTableStyle BottomSeparatorTableStyle )
View Source
const IndentSpaces = 2
Variables ¶
View Source
var Colorize = false
View Source
var Indent = strings.Repeat(" ", IndentSpaces)
View Source
var Quiet bool = false
View Source
var Stderr io.Writer = os.Stderr
View Source
var Stdout io.Writer = os.Stdout
Functions ¶
func ColorError ¶
func ColorHeading ¶
func ColorTypeName ¶
func ColorValue ¶
func ColoredOptions ¶
func EnableColor ¶
func EnableColor(force bool)
func IndentString ¶
func PrintIndent ¶
func PrintIndent(indent int)
func ProcessColorizeFlag ¶
Types ¶
type Table ¶
type Table struct { Rows [][][]string Style TableStyle MaxWidth int HeadingSeparator string RowSeparator string TopDividerSeparator string TopDivider string MiddleDividerSeparator string MiddleDivider string BottomDividerSeparator string BottomDivider string }
func (*Table) ColumnWidths ¶
type TableStyle ¶
type TableStyle uint8
type TreePrefix ¶
type TreePrefix []bool
func (TreePrefix) Print ¶
func (self TreePrefix) Print(indent int, last bool)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.