mirror of
https://github.com/navidys/tvxwidgets.git
synced 2025-05-11 19:29:26 +08:00
Added function for changing empty guage color
This function will set empty guage color with given color Signed-off-by: Sumon Sutrodhar <24304603+stdr-sumon@users.noreply.github.com>
This commit is contained in:
parent
060941944a
commit
e93d029785
10
gauge_um.go
10
gauge_um.go
@ -89,6 +89,11 @@ func (g *UtilModeGauge) SetValue(value float64) {
|
||||
}
|
||||
}
|
||||
|
||||
// SetEmptyColor sets empty gauge color.
|
||||
func (g *UtilModeGauge) SetEmptyColor (color tcell.Color) {
|
||||
g.emptyColor = color
|
||||
}
|
||||
|
||||
// GetValue returns current gauge value.
|
||||
func (g *UtilModeGauge) GetValue() float64 {
|
||||
return g.pc
|
||||
@ -152,8 +157,3 @@ func (g *UtilModeGauge) getBarColor(percentage float64) tcell.Color {
|
||||
|
||||
return g.critColor
|
||||
}
|
||||
|
||||
// SetEmptyColor sets empty gauge color.
|
||||
func (g *UtilModeGauge) SetEmptyColor (color tcell.Color) {
|
||||
g.emptyColor = color
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user