Documentation ¶
Index ¶
- Variables
- type Hyperlink
- func (h *Hyperlink) Print(url, text string)
- func (h *Hyperlink) Printf(url, text string, a ...interface{})
- func (h *Hyperlink) Println(url, text string)
- func (h *Hyperlink) SetColors(colors ...color.Attribute) Hyperlinker
- func (h *Hyperlink) Sprint(url, text string) string
- func (h *Hyperlink) Sprintf(url, text string, a ...interface{}) string
- func (h *Hyperlink) Sprintln(url, text string) string
- type Hyperlinker
Constants ¶
This section is empty.
Variables ¶
Default option
Functions ¶
This section is empty.
Types ¶
type Hyperlink ¶
Per default the stream uses stdout, less syntax, of course. Avoid using it, use New(... *os.File) function
func New ¶
Create a new instance of Hyperlink without create a new variable, just receives an *os.File
func (*Hyperlink) SetColors ¶
func (h *Hyperlink) SetColors(colors ...color.Attribute) Hyperlinker
Set any number of color attributes, it returns a Hyperlinker that allows you to have a family of fmt methods
func (*Hyperlink) Sprint ¶
Returns a clickable string, works like HTML <a> tags. All of this, without alt attribute, obviusly
type Hyperlinker ¶
type Hyperlinker interface { Sprint(url, text string) string Sprintln(url, text string) string Sprintf(url, text string, a ...interface{}) string Print(url, text string) Println(url, text string) Printf(url, text string, a ...interface{}) }
Like fmt family but evaluates and transforms the required inputs to a hyperlink
Click to show internal directories.
Click to hide internal directories.