locale.py 文件源码

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

项目:gprime 作者: GenealogyCollective 项目源码 文件源码
def gettext(self, msgid):
        """
        Obtain translation of gettext, return a unicode object

        :param msgid: The string to translated.
        :type msgid: unicode
        :returns: Translation or the original.
        :rtype: unicode
        """
        # If msgid =="" then gettext will return po file header
        # and that's not what we want.
        if len(msgid.strip()) == 0:
            return msgid
        return gettext.GNUTranslations.gettext(self, msgid)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号