createpdf.py 文件源码

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

项目:deviation-manual 作者: DeviationTX 项目源码 文件源码
def setPageCounter(counter=None, style=None):

    global _counter, _counterStyle

    if counter is not None:
        _counter = counter
    if style is not None:
        _counterStyle = style

    if _counterStyle=='lowerroman':
        ptext=toRoman(_counter).lower()
    elif _counterStyle=='roman':
        ptext=toRoman(_counter).upper()
    elif _counterStyle=='alpha':
        ptext=string.uppercase[_counter%26]
    elif _counterStyle=='loweralpha':
        ptext=string.lowercase[_counter%26]
    else:
        ptext=unicode(_counter)
    return ptext
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号