bugfix: test lexers in context

This commit is contained in:
Johann Dreo 2014-05-02 19:08:57 +02:00
commit 200f1cd1f3

View file

@ -551,7 +551,7 @@ def colorin(text, color="red", style="normal"):
color_code = str(color_nb)
# programming language
elif color.lower() in lexers:
elif color.lower() in context["lexers"]:
# bypass color encoding and return text colored by the lexer
return color_lexer(color,style,text)