From 586de7623c6311a2aada4faeda6c1e148390df9d Mon Sep 17 00:00:00 2001 From: ineanto Date: Mon, 10 Jul 2023 11:20:37 +0200 Subject: [PATCH] fix: battery status display --- dot_config/i3/scripts/executable_battery2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dot_config/i3/scripts/executable_battery2 b/dot_config/i3/scripts/executable_battery2 index a117f5b..40c01d5 100644 --- a/dot_config/i3/scripts/executable_battery2 +++ b/dot_config/i3/scripts/executable_battery2 @@ -42,7 +42,7 @@ else: def color(percent): if percent < 35: return colors.get("low") - if percent < 75 and percent > 35: + if percent < 50 and percent > 35: return colors.get("mid") if percent > 50: return colors.get("high") @@ -64,7 +64,7 @@ else: 'high': '#b8bb26' } - display = "{}{}%" + display = "{} {}%" battery = "" color = color(percentleft) @@ -75,7 +75,7 @@ else: elif state == "Unknown": battery = B_UNKNOWN + " " + B_FULL + " " else: - battery = B_CHARGING + " " + B_MID + " " + battery = B_UNKNOWN + " " + B_MID + " " display = display.format(color, battery, percentleft)