Documentation ¶
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Formater ¶
Example ¶
package main import ( "fmt" "github.com/muhqu/go-attributedtext/textstyle" "github.com/muhqu/go-attributedtext/textstyle/htmlformater" ) func main() { err := htmlformater.Formater(textstyle.Red.ForegroundColor()) info := htmlformater.Formater(textstyle.Yellow.ForegroundColor()) fatal := htmlformater.Formater(textstyle.Red.ForegroundColor(), textstyle.Bold, textstyle.Underline, textstyle.White.BackgroundColor()) fmt.Printf("%s\n", err("Hello")) fmt.Printf("%s\n", info("World")) fmt.Printf("%s\n", fatal("<Fatal>")) }
Output: <font color="red">Hello</font> <font color="yellow">World</font> <font bgcolor="white"><u><b><font color="red"><Fatal></font></b></u></font>
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.