Comments
Patch
@@ -417,11 +417,11 @@ if pycompat.osname == 'nt':
ansire = re.compile('\033\[([^m]*)m([^\033]*)(.*)',
re.MULTILINE | re.DOTALL)
- def win32print(writefunc, *msgs, **opts):
+ def win32print(ui, writefunc, *msgs, **opts):
for text in msgs:
- _win32print(text, writefunc, **opts)
+ _win32print(ui, text, writefunc, **opts)
- def _win32print(text, writefunc, **opts):
+ def _win32print(ui, text, writefunc, **opts):
label = opts.get('label', '')
attr = origattr
@@ -805,7 +805,7 @@ class ui(object):
elif self._colormode == 'win32':
# windows color printing is its own can of crab, defer to
# the color module and that is it.
- color.win32print(self._write, *args, **opts)
+ color.win32print(self, self._write, *args, **opts)
else:
msgs = args
if self._colormode is not None:
@@ -831,7 +831,7 @@ class ui(object):
elif self._colormode == 'win32':
# windows color printing is its own can of crab, defer to
# the color module and that is it.
- color.win32print(self._write_err, *args, **opts)
+ color.win32print(self, self._write_err, *args, **opts)
else:
msgs = args
if self._colormode is not None: