diff --git a/bumblebee/outputs/i3.py b/bumblebee/outputs/i3.py index a2cc3fb..c8a7351 100644 --- a/bumblebee/outputs/i3.py +++ b/bumblebee/outputs/i3.py @@ -10,11 +10,15 @@ class i3bar(bumblebee.output.Output): def add(self, obj): theme = obj.theme() - self._data.append({ - "full_text": "%s%s%s" % (theme.prefix(obj), obj.data(), theme.suffix(obj)), - "separator": False, - "separator_block_width": 0, - }) + + data = { + "full_text": "%s%s%s" % (theme.prefix(obj), obj.data(), theme.suffix(obj)) + } + if theme.default_separators(obj) == False: + data["separator"] = False + data["separator_block_width"] = 0 + + self._data.append(data) def get(self): data = json.dumps(self._data) diff --git a/bumblebee/theme.py b/bumblebee/theme.py index 91100ba..5227fe2 100644 --- a/bumblebee/theme.py +++ b/bumblebee/theme.py @@ -25,6 +25,9 @@ class Theme: return value + def default_separators(self, obj): + return self._gettheme(obj, "default_separators") + def prefix(self, obj): return self._gettheme(obj, "prefix") diff --git a/bumblebee/themes/default.json b/bumblebee/themes/default.json index 68040de..c239d28 100644 --- a/bumblebee/themes/default.json +++ b/bumblebee/themes/default.json @@ -7,10 +7,10 @@ "prefix": "bat ", "states": { "charging": { - "suffix": "+" + "suffix": "+ " }, "discharging": { - "suffix": "-" + "suffix": "- " } } },