mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-12-16 21:07:55 +08:00
pkg/ui: Export Fg and Bg.
This commit is contained in:
parent
31f0eaa7b0
commit
c0146f1c42
|
@ -101,6 +101,12 @@ var (
|
|||
ToggleInverse Styling = boolToggle(accessInverse)
|
||||
)
|
||||
|
||||
// Fg returns a Styling that sets the foreground color.
|
||||
func Fg(c Color) Styling { return setForeground{c} }
|
||||
|
||||
// Bg returns a Styling that sets the background color.
|
||||
func Bg(c Color) Styling { return setBackground{c} }
|
||||
|
||||
type setForeground struct{ c Color }
|
||||
type setBackground struct{ c Color }
|
||||
type boolOn func(*Style) *bool
|
||||
|
|
Loading…
Reference in New Issue
Block a user