##// END OF EJS Templates
py3: slice over bytes to prevent getting ascii values...
Pulkit Goyal -
r36198:34e85044 default
parent child Browse files
Show More
@@ -454,7 +454,7 b' def ascii(ui, state, type, char, text, c'
454 if any(len(char) > 1 for char in edgemap.values()):
454 if any(len(char) > 1 for char in edgemap.values()):
455 # limit drawing an edge to the first or last N lines of the current
455 # limit drawing an edge to the first or last N lines of the current
456 # section the rest of the edge is drawn like a parent line.
456 # section the rest of the edge is drawn like a parent line.
457 parent = state['styles'][PARENT][-1]
457 parent = state['styles'][PARENT][-1:]
458 def _drawgp(char, i):
458 def _drawgp(char, i):
459 # should a grandparent character be drawn for this line?
459 # should a grandparent character be drawn for this line?
460 if len(char) < 2:
460 if len(char) < 2:
@@ -463,7 +463,7 b' def ascii(ui, state, type, char, text, c'
463 # either skip first num lines or take last num lines, based on sign
463 # either skip first num lines or take last num lines, based on sign
464 return -num <= i if num < 0 else (len(lines) - i) <= num
464 return -num <= i if num < 0 else (len(lines) - i) <= num
465 for i, line in enumerate(lines):
465 for i, line in enumerate(lines):
466 line[:] = [c[-1] if _drawgp(c, i) else parent for c in line]
466 line[:] = [c[-1:] if _drawgp(c, i) else parent for c in line]
467 edgemap.update(
467 edgemap.update(
468 (e, (c if len(c) < 2 else parent)) for e, c in edgemap.items())
468 (e, (c if len(c) < 2 else parent)) for e, c in edgemap.items())
469
469
@@ -619,7 +619,7 b' def getwebsubs(repo):'
619 websubdefs += repo.ui.configitems('interhg')
619 websubdefs += repo.ui.configitems('interhg')
620 for key, pattern in websubdefs:
620 for key, pattern in websubdefs:
621 # grab the delimiter from the character after the "s"
621 # grab the delimiter from the character after the "s"
622 unesc = pattern[1]
622 unesc = pattern[1:2]
623 delim = re.escape(unesc)
623 delim = re.escape(unesc)
624
624
625 # identify portions of the pattern, taking care to avoid escaped
625 # identify portions of the pattern, taking care to avoid escaped
General Comments 0
You need to be logged in to leave comments. Login now