def __init__(self, **options): self.funcnamehighlighting = get_bool_opt(options, "funcnamehighlighting", True) self.disabledmodules = get_list_opt(options, "disabledmodules", ["unknown"]) self.startinline = get_bool_opt(options, "startinline", False) # private option argument for the lexer itself if "_startinline" in options: self.startinline = options.pop("_startinline") # collect activated functions in a set self._functions = set() if self.funcnamehighlighting: from pygments.lexers._phpbuiltins import MODULES for key, value in MODULES.iteritems(): if key not in self.disabledmodules: self._functions.update(value) RegexLexer.__init__(self, **options)
def __init__(self, **options): self.funcnamehighlighting = get_bool_opt(options, 'funcnamehighlighting', True) self.disabledmodules = get_list_opt(options, 'disabledmodules', ['unknown']) self.startinline = get_bool_opt(options, 'startinline', False) # private option argument for the lexer itself if '_startinline' in options: self.startinline = options.pop('_startinline') # collect activated functions in a set self._functions = set() if self.funcnamehighlighting: from pygments.lexers._phpbuiltins import MODULES for key, value in MODULES.iteritems(): if key not in self.disabledmodules: self._functions.update(value) RegexLexer.__init__(self, **options)