Fixes #174: different colors for download/upload
This commit is contained in:
parent
e0165a2283
commit
3f903c796c
|
@ -20,7 +20,7 @@ The keys are:
|
|||
BattLines -- array of ints for the colors of lines
|
||||
MemLines -- array of ints for the colors of lines
|
||||
ProcCursor -- int, color of the cursor in the process widget
|
||||
Sparkline -- int, color of the graph bars
|
||||
Sparklines -- array of ints for the colors of network usage
|
||||
DiskBar -- int, color of the disk bars
|
||||
TempLow -- int, color used for low temperatures
|
||||
TempHigh -- int, color used for high temperatures
|
||||
|
|
|
@ -16,7 +16,7 @@ func init() {
|
|||
|
||||
ProcCursor: 4,
|
||||
|
||||
Sparkline: 4,
|
||||
Sparklines: [2]int{4, 5},
|
||||
|
||||
DiskBar: 7,
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
"ProcCursor": 4,
|
||||
|
||||
"Sparkline": 4,
|
||||
"Sparklines": [4, 5],
|
||||
|
||||
"DiskBar": 7,
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ func init() {
|
|||
|
||||
ProcCursor: 33,
|
||||
|
||||
Sparkline: 4,
|
||||
Sparklines: [2]int{4, 5},
|
||||
|
||||
DiskBar: 252,
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ func init() {
|
|||
|
||||
ProcCursor: 197,
|
||||
|
||||
Sparkline: 81,
|
||||
Sparklines: [2]int{81, 186},
|
||||
|
||||
DiskBar: 102,
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ func init() {
|
|||
|
||||
ProcCursor: 31, // blue (nord9)
|
||||
|
||||
Sparkline: 31,
|
||||
Sparklines: [2]int{31, 96},
|
||||
|
||||
DiskBar: 254,
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ func init() {
|
|||
|
||||
ProcCursor: 136,
|
||||
|
||||
Sparkline: 33,
|
||||
Sparklines: [2]int{33, 136},
|
||||
|
||||
DiskBar: 243,
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ func init() {
|
|||
|
||||
ProcCursor: 4,
|
||||
|
||||
Sparkline: 4,
|
||||
Sparklines: [2]int{4, 5},
|
||||
|
||||
DiskBar: 12, // base0
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ func init() {
|
|||
|
||||
ProcCursor: 4,
|
||||
|
||||
Sparkline: 4,
|
||||
Sparklines: [2]int{4, 5},
|
||||
|
||||
DiskBar: 11, // base00
|
||||
|
||||
|
|
|
@ -52,8 +52,8 @@ type Colorscheme struct {
|
|||
// ProcCursor is used as the color for the color bar in the process widget
|
||||
ProcCursor int
|
||||
|
||||
// SparkLine determines the color of the data line in spark graphs
|
||||
Sparkline int
|
||||
// SparkLines define the colors used for the Network usage graphs
|
||||
Sparklines [2]int
|
||||
|
||||
// DiskBar is the color of the disk gauge bars (currently unused,
|
||||
// as there's no disk gauge widget)
|
||||
|
|
|
@ -16,7 +16,7 @@ func init() {
|
|||
|
||||
ProcCursor: 159,
|
||||
|
||||
Sparkline: 183,
|
||||
Sparklines: [2]int{183, 146},
|
||||
|
||||
DiskBar: 158,
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/xxxserxxx/lingo/v2"
|
||||
|
||||
"github.com/xxxserxxx/gotop/v4"
|
||||
"github.com/xxxserxxx/gotop/v4/widgets"
|
||||
|
||||
|
@ -186,9 +187,9 @@ func makeWidget(c gotop.Config, widRule widgetRule) interface{} {
|
|||
w = t
|
||||
case "net":
|
||||
n := widgets.NewNetWidget(c.NetInterface)
|
||||
n.Lines[0].LineColor = ui.Color(c.Colorscheme.Sparkline)
|
||||
n.Lines[0].LineColor = ui.Color(c.Colorscheme.Sparklines[0])
|
||||
n.Lines[0].TitleColor = ui.Color(c.Colorscheme.BorderLabel)
|
||||
n.Lines[1].LineColor = ui.Color(c.Colorscheme.Sparkline)
|
||||
n.Lines[1].LineColor = ui.Color(c.Colorscheme.Sparklines[1])
|
||||
n.Lines[1].TitleColor = ui.Color(c.Colorscheme.BorderLabel)
|
||||
n.Mbps = c.Mbps
|
||||
w = n
|
||||
|
|
Loading…
Reference in New Issue
Block a user