def _add_throughput(self, y, x, width, op, title, available, used):
percent = float(used) / available<EOL>self.win.addstr(y, x, "<STR_LIT:[>")<EOL>try:<EOL><INDENT>self.win.addstr(y, x + width - <NUM_LIT:1>, "<STR_LIT:]>")<EOL><DEDENT>except curses.error:<EOL><INDENT>pass<EOL><DEDENT>x += <NUM_LIT:1><EOL>right = "<STR_LIT>" % (used, available, op)<EOL>pieces = self._progress_bar(width - <NUM_LIT:2>, percent, title, right)<EOL>for color, text in pieces:<EOL><INDENT>self.win.addstr(y, x, text, curses.color_pair(color))<EOL>x += len(text)<EOL><DEDENT>
Write a single throughput measure to a row