blob: 3af2469ab8c27afb0601dbdb529d1a97f7ac38c0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
package termui
// Color is an integer in the range -1 to 255.
type Color int
// ColorDefault = clear
const ColorDefault = -1
// Copied from termbox. Attributes that can be bitwise OR'ed with a color.
const (
AttrBold Color = 1 << (iota + 9)
AttrUnderline
AttrReverse
)
// Theme is assigned to the current theme.
var Theme = DefaultTheme
// DefaultTheme implements a generic set of colors to use by default.
var DefaultTheme = Colorscheme{
Fg: 7,
Bg: -1,
LabelFg: 7,
LabelBg: -1,
BorderFg: 6,
BorderBg: -1,
Sparkline: 4,
LineGraph: 0,
TableCursor: 4,
GaugeColor: 7,
}
// A Colorscheme represents the current look-and-feel of the dashboard.
type Colorscheme struct {
Fg Color
Bg Color
LabelFg Color
LabelBg Color
BorderFg Color
BorderBg Color
Sparkline Color
LineGraph Color
TableCursor Color
GaugeColor Color
}
|