##// END OF EJS Templates
Updating some comments to reflect the actual code.
chebee7i -
Show More
@@ -226,10 +226,6 b' class IPythonConsoleLexer(Lexer):'
226 # c.PromptManager.in2_template = ' .\D.: '
226 # c.PromptManager.in2_template = ' .\D.: '
227 # c.PromptManager.out_template = 'Out[\#]: '
227 # c.PromptManager.out_template = 'Out[\#]: '
228 #
228 #
229 # Note, we do not include the trailing whitespace in the regex since
230 # we want to allow blank prompts (and editors often remove trailing
231 # whitespace).
232 #
233 in1_regex = r'In \[[0-9]+\]: '
229 in1_regex = r'In \[[0-9]+\]: '
234 in2_regex = r' \.\.+\.: '
230 in2_regex = r' \.\.+\.: '
235 out_regex = r'Out\[[0-9]+\]: '
231 out_regex = r'Out\[[0-9]+\]: '
@@ -272,7 +268,8 b' class IPythonConsoleLexer(Lexer):'
272 # The reason can't just use the rstrip'd variants instead is because
268 # The reason can't just use the rstrip'd variants instead is because
273 # we want any whitespace associated with the prompt to be inserted
269 # we want any whitespace associated with the prompt to be inserted
274 # with the token. This allows formatted code to be modified so as hide
270 # with the token. This allows formatted code to be modified so as hide
275 # the appearance of prompts. For example, see copybutton.js.
271 # the appearance of prompts, with the whitespace included. One example
272 # use of this is in copybutton.js from the standard lib Python docs.
276 in1_regex_rstrip = in1_regex.rstrip() + '\n'
273 in1_regex_rstrip = in1_regex.rstrip() + '\n'
277 in2_regex_rstrip = in2_regex.rstrip() + '\n'
274 in2_regex_rstrip = in2_regex.rstrip() + '\n'
278 out_regex_rstrip = out_regex.rstrip() + '\n'
275 out_regex_rstrip = out_regex.rstrip() + '\n'
General Comments 0
You need to be logged in to leave comments. Login now