ecs_explorer.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:ecs_explorer 作者: firemanphil 项目源码 文件源码
def convert_details_to_columns(details):
    labels = []
    data = []
    for detail in details:
        if type(detail[0]) is list:
            labels.extend(detail[0])
        else:
            labels.append(detail[0])
        labels.append('\n')
        data.append(str(detail[1]))
    text2 = '\n'.join(data)
    if len(labels) == 0:
        labels = ''
        text2 = ''
    filler1 = urwid.Filler(urwid.Text(labels, 'left'), valign='top')
    filler2 = urwid.Filler(urwid.Text(text2, 'left'), valign='top')
    return [filler1, filler2]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号