_simpletable.py 文件源码

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

项目:gprime 作者: GenealogyCollective 项目源码 文件源码
def get_cell_markup(self, x, y=None, data=None):
        """
        See if a column has formatting (if x and y are supplied) or
        see if a cell has formatting. If it does, return the formatted
        string, otherwise return data that is escaped (if that column
        has formatting), or just the plain data.
        """
        if x in self._cell_markup:
            if y is None:
                return True # markup for this column
            elif y in self._cell_markup[x]:
                return self._cell_markup[x][y]
            else:
                return escape(data)
        else:
            if y is None:
                return False # no markup for this column
            else:
                return data
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号