2018-02-21 15:56:37 +08:00
|
|
|
package colorschemes
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
//revive:disable
|
2018-02-21 15:56:37 +08:00
|
|
|
const (
|
|
|
|
Bold int = 1 << (iota + 9)
|
|
|
|
Underline
|
|
|
|
Reverse
|
|
|
|
)
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
//revive:enable
|
|
|
|
|
|
|
|
/*
|
|
|
|
Colorscheme defines colors and fonts used by TUI elements. The standard
|
|
|
|
256 terminal colors are supported.
|
|
|
|
|
|
|
|
For int values, -1 = clear
|
|
|
|
|
|
|
|
Colors may be combined with 'Bold', 'Underline', or 'Reverse' by using
|
|
|
|
bitwise OR ('|') and the name of the Color. For example, to get bold red
|
|
|
|
labels, you would use 'Labels: 2 | Bold'
|
|
|
|
*/
|
2018-02-21 15:56:37 +08:00
|
|
|
type Colorscheme struct {
|
2020-06-08 05:40:03 +08:00
|
|
|
// Name is the key used to look up the colorscheme, e.g. as provided by the user
|
|
|
|
Name string
|
|
|
|
// Who created the color scheme
|
2018-02-21 15:56:37 +08:00
|
|
|
Author string
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// Foreground color
|
2018-02-22 03:15:53 +08:00
|
|
|
Fg int
|
2020-06-08 05:40:03 +08:00
|
|
|
// Background color
|
2018-02-21 15:56:37 +08:00
|
|
|
Bg int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// BorderLabel is the color of the widget title label
|
2018-02-21 18:24:36 +08:00
|
|
|
BorderLabel int
|
2020-06-08 05:40:03 +08:00
|
|
|
// BorderLine is the color of the widget border
|
|
|
|
BorderLine int
|
2018-02-21 18:24:36 +08:00
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// CPULines define the colors used for the CPU activity graph, in
|
|
|
|
// order, for each core. Should add at least 8 here; they're
|
|
|
|
// selected in order, with wrapping.
|
2018-02-21 18:24:36 +08:00
|
|
|
CPULines []int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// BattLines define the colors used for the battery history graph.
|
|
|
|
// Should add at least 2; they're selected in order, with wrapping.
|
2018-12-27 12:06:55 +08:00
|
|
|
BattLines []int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// MemLines define the colors used for the memory histograph.
|
|
|
|
// Should add at least 2 (physical & swap); they're selected in order,
|
|
|
|
// with wrapping.
|
2020-02-29 00:03:41 +08:00
|
|
|
MemLines []int
|
2018-02-21 18:24:36 +08:00
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// ProcCursor is used as the color for the color bar in the process widget
|
2018-02-21 18:24:36 +08:00
|
|
|
ProcCursor int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// SparkLine determines the color of the data line in spark graphs
|
2018-02-21 18:24:36 +08:00
|
|
|
Sparkline int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// DiskBar is the color of the disk gauge bars (currently unused,
|
|
|
|
// as there's no disk gauge widget)
|
2018-02-21 18:24:36 +08:00
|
|
|
DiskBar int
|
|
|
|
|
2020-06-08 05:40:03 +08:00
|
|
|
// TempLow determines the color of the temperature number when it's under
|
|
|
|
// a certain threshold
|
|
|
|
TempLow int
|
|
|
|
// TempHigh determines the color of the temperature number when it's over
|
|
|
|
// a certain threshold
|
2018-02-21 18:24:36 +08:00
|
|
|
TempHigh int
|
2018-02-21 15:56:37 +08:00
|
|
|
}
|