mercurial/ui.py
changeset 35961 0ff41ced4c12
parent 35957 b62c4154bb28
child 36126 8f5c7f906f9b
equal deleted inserted replaced
35960:580f7b1b88c7 35961:0ff41ced4c12
   868         else:
   868         else:
   869             self._bufferapplylabels = None
   869             self._bufferapplylabels = None
   870 
   870 
   871         return "".join(self._buffers.pop())
   871         return "".join(self._buffers.pop())
   872 
   872 
       
   873     def canwritewithoutlabels(self):
       
   874         '''check if write skips the label'''
       
   875         if self._buffers and not self._bufferapplylabels:
       
   876             return True
       
   877         return self._colormode is None
       
   878 
       
   879     def canbatchlabeledwrites(self):
       
   880         '''check if write calls with labels are batchable'''
       
   881         # Windows color printing is special, see ``write``.
       
   882         return self._colormode != 'win32'
       
   883 
   873     def write(self, *args, **opts):
   884     def write(self, *args, **opts):
   874         '''write args to output
   885         '''write args to output
   875 
   886 
   876         By default, this method simply writes to the buffer or stdout.
   887         By default, this method simply writes to the buffer or stdout.
   877         Color mode can be set on the UI class to have the output decorated
   888         Color mode can be set on the UI class to have the output decorated