diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-03-02 09:30:00 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-03-02 09:30:00 +0100 |
commit | 6c8cb02af0573bce2caab988c1fea58921519e18 (patch) | |
tree | 6db08e95d586ab34dbb855e6aeb4d1bae69fac83 /examples | |
parent | update todo (diff) | |
download | xpybar-6c8cb02af0573bce2caab988c1fea58921519e18.tar.gz xpybar-6c8cb02af0573bce2caab988c1fea58921519e18.tar.bz2 xpybar-6c8cb02af0573bce2caab988c1fea58921519e18.tar.xz |
add xdisplay
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'examples')
-rw-r--r-- | examples/plugin-test | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/examples/plugin-test b/examples/plugin-test index 3fce9bc..06891cf 100644 --- a/examples/plugin-test +++ b/examples/plugin-test @@ -12,6 +12,7 @@ from plugins.uname import Uname from plugins.df import Discs from plugins.mem import Memory from plugins.discstats import DiscStats +from plugins.xdisplay import XDisplay OUTPUT, HEIGHT, YPOS, TOP = 0, 24, 24, True @@ -145,7 +146,9 @@ def redraw(): discstats = ['%s:%s' % (d[2:], colourise(i)) for d, i in discstats] discstats = 'Disc stats: %s' % (' '.join(discstats)) - text = '%s │ %s │ %s │ %s │ %s │ %s │ %s │ %s │ %s\n%s │ %s' - text %= (time, uptime, idle, loadavg, users, uname, mem, swp, shm, discs, discstats) + xdisplay = ':%i' % XDisplay().display + + text = '%s │ %s │ %s │ %s │ %s │ %s %s │ %s │ %s │ %s\n%s │ %s' + text %= (time, uptime, idle, loadavg, users, uname, xdisplay, mem, swp, shm, discs, discstats) bar.draw_coloured_text(0, 10, 0, 2, text) |