本文整理汇总了Python中pygments.formatters.HtmlFormatter.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python HtmlFormatter.__init__方法的具体用法?Python HtmlFormatter.__init__怎么用?Python HtmlFormatter.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pygments.formatters.HtmlFormatter
的用法示例。
在下文中一共展示了HtmlFormatter.__init__方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, language, ctags, **kwargs):
HtmlFormatter.__init__(self, linenos='table', lineanchors='L',
linespans='L', anchorlinenos=True, **kwargs)
self.language = language
if ctags:
# Use Pygments' ctags system but provide our own CTags instance
self.tagsfile = True # some trueish object
self._ctags = ctags
示例2: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
"""
"""
HtmlFormatter.__init__(self, **options)
self.project = options['codebro_project']
self.is_xrefed = False
self.file = None
self.functions = []
self.func_idx = 0
示例3: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
self.relativeBaseDir = options.get("relativeBaseDir", "")
示例4: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
示例5: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
self.inputIndent = int(options.get('input-indent', '4'))
self.indent = float(options.get('indent', '3'))
self.indentUnit = options.get('indent-unit', 'ch')
示例6: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, identifier):
HtmlFormatter.__init__(self, linenos="table")
self.identifier = identifier
示例7: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self):
HtmlFormatter.__init__(self, linenos="inline")
示例8: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, lines, **kwargs):
HtmlFormatter.__init__(self, **kwargs)
self.lines = lines
示例9: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
self.pasteid = options.get('pasteid',0)
示例10: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, linenos):
HtmlFormatter.__init__(self, linenos=linenos, lineanchors='L',
anchorlinenos=True)
示例11: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
self.wrap_pre = get_bool_opt(options, 'wrap_pre', False)
self.wrap_code = get_bool_opt(options, 'wrap_code', False)
示例12: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, covdata, **options):
HtmlFormatter.__init__(self, **options)
self.covdata = covdata
示例13: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, **options):
HtmlFormatter.__init__(self, **options)
self.lineanchorlinks = options.get('lineanchorlinks', False)
示例14: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, other):
self._xyzzy_other = other
HtmlFormatter.__init__(self)
示例15: __init__
# 需要导入模块: from pygments.formatters import HtmlFormatter [as 别名]
# 或者: from pygments.formatters.HtmlFormatter import __init__ [as 别名]
def __init__(self, *args, **kwargs):
BaseModuleInfo.__init__(self, kwargs['module'])
del kwargs['module']
HtmlFormatter.__init__(self, *args, **kwargs)
self.curlineno = None