mercurial/crecord.py
changeset 41993 cde5827d09a7
parent 41992 fa3b0ca9d74f
child 42025 66fc05ff0ea3
equal deleted inserted replaced
41992:fa3b0ca9d74f 41993:cde5827d09a7
  1762         try:
  1762         try:
  1763             curses.use_default_colors()
  1763             curses.use_default_colors()
  1764         except curses.error:
  1764         except curses.error:
  1765             self.usecolor = False
  1765             self.usecolor = False
  1766 
  1766 
       
  1767         # In some situations we may have some cruft left on the "alternate
       
  1768         # screen" from another program (or previous iterations of ourself), and
       
  1769         # we won't clear it if the scroll region is small enough to comfortably
       
  1770         # fit on the terminal.
       
  1771         self.stdscr.clear()
       
  1772 
  1767         # available colors: black, blue, cyan, green, magenta, white, yellow
  1773         # available colors: black, blue, cyan, green, magenta, white, yellow
  1768         # init_pair(color_id, foreground_color, background_color)
  1774         # init_pair(color_id, foreground_color, background_color)
  1769         self.initcolorpair(None, None, name="normal")
  1775         self.initcolorpair(None, None, name="normal")
  1770         self.initcolorpair(curses.COLOR_WHITE, curses.COLOR_MAGENTA,
  1776         self.initcolorpair(curses.COLOR_WHITE, curses.COLOR_MAGENTA,
  1771                            name="selected")
  1777                            name="selected")