bumblebee-status/i3bumblebee
Tobias Witek c4683f3700 [output] Create preliminary framework for output handling
Prepare a framework for having modular outputs. Essentially, the main
application uses a output-type object to format strings for the
preamble, the actual data items, and a "postamble" (finalizer). The
printing of that representation, again, is up to the main application,
not the output framework.

Probably, at some point in the future, an interface class will be in
order, but right now, I want to keep it lean - seeing as for the
forseeable future, i3bar is going to be the one and only consumer of
this.
2016-10-30 15:58:35 +01:00

20 lines
368 B
Python
Executable file

#!/usr/bin/env python
import bumblebee.outputs.i3
def main():
output = bumblebee.outputs.i3.i3bar()
print output.preamble()
while True:
# TODO: retrieve data from modules
data = []
print output.data(data)
print output.finalize()
if __name__ == "__main__":
main()
# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4