home *** CD-ROM | disk | FTP | other *** search
/ Maximum CD 2010 November / maximum-cd-2010-11.iso / DiscContents / calibre-0.7.13.msi / file_409 (.txt) < prev    next >
Encoding:
Python Compiled Bytecode  |  2010-08-06  |  1.3 KB  |  41 lines

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.6)
  3.  
  4. __revision__ = '$Id: __init__.py 61064 2008-02-25 16:29:58Z andrew.kuchling $'
  5. from _curses import *
  6. from curses.wrapper import wrapper
  7. import os as _os
  8. import sys as _sys
  9.  
  10. def initscr():
  11.     import _curses
  12.     import curses
  13.     setupterm(term = _os.environ.get('TERM', 'unknown'), fd = _sys.__stdout__.fileno())
  14.     stdscr = _curses.initscr()
  15.     for key, value in _curses.__dict__.items():
  16.         if key[0:4] == 'ACS_' or key in ('LINES', 'COLS'):
  17.             setattr(curses, key, value)
  18.             continue
  19.     
  20.     return stdscr
  21.  
  22.  
  23. def start_color():
  24.     import _curses
  25.     import curses
  26.     retval = _curses.start_color()
  27.     if hasattr(_curses, 'COLORS'):
  28.         curses.COLORS = _curses.COLORS
  29.     
  30.     if hasattr(_curses, 'COLOR_PAIRS'):
  31.         curses.COLOR_PAIRS = _curses.COLOR_PAIRS
  32.     
  33.     return retval
  34.  
  35.  
  36. try:
  37.     has_key
  38. except NameError:
  39.     from has_key import has_key
  40.  
  41.