Changed all text to black and added alternating white/gray rows.
Signed-off-by: Akram <akram@wit.com>
This commit is contained in:
parent
3e5577bc6f
commit
a38e2b75a9
|
@ -17,7 +17,7 @@ var windowsBgGrey = color.RGBA{100, 100, 100, 142}
|
||||||
var windowsBgBlack = color.RGBA{55, 55, 55, 255}
|
var windowsBgBlack = color.RGBA{55, 55, 55, 255}
|
||||||
|
|
||||||
var linuxTextBlue = color.RGBA{0, 100, 200, 100}
|
var linuxTextBlue = color.RGBA{0, 100, 200, 100}
|
||||||
var linuxTextBlack = color.RGBA{0, 0, 0, 0}
|
var linuxTextBlack = color.RGBA{0, 0, 0, 255}
|
||||||
var linuxTextYellow = color.RGBA{200, 200, 0, 200}
|
var linuxTextYellow = color.RGBA{200, 200, 0, 200}
|
||||||
var linuxBgMauve = color.RGBA{72, 0, 0, 142}
|
var linuxBgMauve = color.RGBA{72, 0, 0, 142}
|
||||||
var linuxBgBlack = color.RGBA{55, 55, 55, 255}
|
var linuxBgBlack = color.RGBA{55, 55, 55, 255}
|
||||||
|
@ -25,16 +25,20 @@ var linuxBgWhite = color.RGBA{0, 0, 0, 0}
|
||||||
var linuxBgYellow = color.RGBA{255, 255, 0, 255}
|
var linuxBgYellow = color.RGBA{255, 255, 0, 255}
|
||||||
|
|
||||||
func setRowValues(mh *gui.TableData, row int, vm *pb.Event_VM) {
|
func setRowValues(mh *gui.TableData, row int, vm *pb.Event_VM) {
|
||||||
defaultTextColor := linuxTextBlue
|
defaultTextColor := linuxTextBlack
|
||||||
defaultTextYellow := linuxTextYellow
|
defaultTextYellow := linuxTextBlack
|
||||||
defaultTextBlack := linuxTextBlack
|
defaultTextBlack := linuxTextBlack
|
||||||
|
|
||||||
if runtime.GOOS == "windows" {
|
if runtime.GOOS == "windows" {
|
||||||
defaultTextColor = windowsTextRed
|
defaultTextColor = windowsTextRed
|
||||||
defaultTextBlack = windowsTextBlack
|
defaultTextBlack = windowsTextBlack
|
||||||
}
|
}
|
||||||
// if (row % 2) == 1 {
|
if (row % 2) == 1 {
|
||||||
if (row == 1) {
|
mh.Rows[row].HumanData[0].Color = color.RGBA{200, 200, 200, 100} // odd columns are light grey
|
||||||
|
} else {
|
||||||
|
mh.Rows[row].HumanData[0].Color = color.RGBA{255, 255, 255, 255} // white
|
||||||
|
}
|
||||||
|
/*if (row == 1) {
|
||||||
mh.Rows[row].HumanData[0].Color = color.RGBA{100, 100, 100, 142} // makes the background of each other row grey
|
mh.Rows[row].HumanData[0].Color = color.RGBA{100, 100, 100, 142} // makes the background of each other row grey
|
||||||
} else if (row == 2) {
|
} else if (row == 2) {
|
||||||
mh.Rows[row].HumanData[0].Color = color.RGBA{0, 0, 0, 0} // makes the background of each other row grey
|
mh.Rows[row].HumanData[0].Color = color.RGBA{0, 0, 0, 0} // makes the background of each other row grey
|
||||||
|
@ -50,7 +54,7 @@ func setRowValues(mh *gui.TableData, row int, vm *pb.Event_VM) {
|
||||||
mh.Rows[row].HumanData[0].Color = linuxBgMauve
|
mh.Rows[row].HumanData[0].Color = linuxBgMauve
|
||||||
} else {
|
} else {
|
||||||
mh.Rows[row].HumanData[0].Color = color.RGBA{250, 250, 250, 250}
|
mh.Rows[row].HumanData[0].Color = color.RGBA{250, 250, 250, 250}
|
||||||
}
|
}*/
|
||||||
mh.Rows[row].HumanData[1].Text = vm.Name
|
mh.Rows[row].HumanData[1].Text = vm.Name
|
||||||
mh.Rows[row].HumanData[1].Color = defaultTextColor
|
mh.Rows[row].HumanData[1].Color = defaultTextColor
|
||||||
mh.Rows[row].HumanData[2].Text = vm.Hostname
|
mh.Rows[row].HumanData[2].Text = vm.Hostname
|
||||||
|
|
Loading…
Reference in New Issue