yandextank/plugins/Console/screen.py
def __render_left_panel(self):
        ''' Render left blocks '''
        self.log.debug("Rendering left blocks")
        left_block = self.left_panel
        left_block.render()
        blank_space = self.left_panel_width - left_block.width

        lines = []
        pre_space = ' ' * int(blank_space / 2)
        if not left_block.lines:
            lines = [(''), (self.markup.RED + 'BROKEN LEFT PANEL' + self.markup.RESET)]
        else:
            while self.left_panel.lines:
                src_line = self.left_panel.lines.pop(0)
                line = pre_space + self.__truncate(src_line, self.left_panel_width)
                post_space = ' ' * (self.left_panel_width - len(self.markup.clean_markup(line)))
                line += post_space + self.markup.RESET
                lines.append(line)
        return lines
def __render_left_panel(self):
        ''' Render left blocks '''
        self.log.debug("Rendering left blocks")
        left_block = self.left_panel
        left_block.render()
        blank_space = self.left_panel_width - left_block.width

        lines = []
        pre_space = ' ' * int(blank_space / 2)
        if not left_block.lines:
            lines = [(''), (self.markup.RED + 'BROKEN LEFT PANEL' + self.markup.RESET)]
        else:
            while self.left_panel.lines:
                src_line = self.left_panel.lines.pop(0)
                line = pre_space + self.__truncate(src_line, self.left_panel_width)
                post_space = ' ' * (self.left_panel_width - len(self.markup.clean_markup(line)))
                line += post_space + self.markup.RESET
                lines.append(line)
        return lines
Render left blocks