package documentation

Module containing filter lookup functions and default filters.

Unknown Field: copyright
Copyright 2006-2021 by the Pygments team, see AUTHORS.
Unknown Field: license
BSD, see LICENSE for details.

From __init__.py:

Constant FILTERS Undocumented
Class ​Code​Tag​Filter Highlight special code tags in comments and docstrings.
Class ​Error​Token Undocumented
Class ​Gobble​Filter Gobbles source code lines (eats initial characters).
Class ​Keyword​Case​Filter Convert keywords to lowercase or uppercase or capitalize them, which means first letter uppercase, rest lowercase.
Class ​Name​Highlight​Filter Highlight a normal Name (and Name.*) token with a different token type.
Class ​Raise​On​Error​Token​Filter Raise an exception when the lexer generates an error token.
Class ​Symbol​Filter Convert mathematical symbols such as <longrightarrow> in Isabelle or longrightarrow in LaTeX into Unicode characters.
Class ​Token​Merge​Filter Merges consecutive tokens with the same token type in the output stream of a lexer.
Class ​Visible​Whitespace​Filter Convert tabs, newlines and/or spaces to visible characters.
Function ​_replace​_special Undocumented
Function find​_filter​_class Lookup a filter by name. Return None if not found.
Function get​_all​_filters Return a generator of all filter names.
Function get​_filter​_by​_name Return an instantiated filter.
def find_filter_class(filtername):
Lookup a filter by name. Return None if not found.
def get_filter_by_name(filtername, **options):

Return an instantiated filter.

Options are passed to the filter initializer if wanted. Raise a ClassNotFound if not found.

def get_all_filters():
Return a generator of all filter names.
def _replace_special(ttype, value, regex, specialttype, replacefunc=(lambda x: x)):

Undocumented

FILTERS =

Undocumented

Value
{'codetagify': CodeTagFilter,
 'keywordcase': KeywordCaseFilter,
 'highlight': NameHighlightFilter,
 'raiseonerror': RaiseOnErrorTokenFilter,
 'whitespace': VisibleWhitespaceFilter,
 'gobble': GobbleFilter,
 'tokenmerge': TokenMergeFilter,
...