Commit e36c9a61 authored by Mario Hock's avatar Mario Hock

curses gui: optimize for < 100% CPU util

parent 33194e75
......@@ -175,11 +175,11 @@ def display(measurement):
cpu_sorted = helpers.sort_named_tuple(cpu, skip="idle")
t = '{0: >8}'.format( CPU_TYPE_LABELS[cpu_sorted[0][0]] )
stdscr.addstr(y, LABEL_CPU_1, t, curses.color_pair(4))
stdscr.addstr("{:>6.2f}%".format(cpu_sorted[0][1]), curses.color_pair(3))
stdscr.addstr("{:>5.2f}%".format(cpu_sorted[0][1]), curses.color_pair(3))
t = '{0: >8}'.format( CPU_TYPE_LABELS[cpu_sorted[1][0]] )
stdscr.addstr(y, LABEL_CPU_2, t, curses.color_pair(4))
stdscr.addstr("{:>6.2f}%".format(cpu_sorted[0][1]), curses.color_pair(3))
stdscr.addstr("{:>5.2f}%".format(cpu_sorted[0][1]), curses.color_pair(3))
num += 1
y += 1
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment