phpdomain.py 文件源码

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

项目:sphinxcontrib-phpdomain 作者: markstory 项目源码 文件源码
def process_link(self, env, refnode, has_explicit_title, title, target):
        if not has_explicit_title:
            if title.startswith("::"):
                title = title[2:]
            target = target.lstrip('~')  # only has a meaning for the title
            # if the first character is a tilde, don't display the module/class
            # parts of the contents
            if title[0:1] == '~':
                m = re.search(r"(?:\\|[:]{2})(.*)\Z", title)
                if m:
                    title = m.group(1)

        if not title.startswith("$"):
            refnode['php:namespace'] = env.temp_data.get('php:namespace')
            refnode['php:class'] = env.temp_data.get('php:class')

        return title, target
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号