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

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.6)
  3.  
  4. import os
  5. import win32api
  6. ver_strings = ('Comments', 'InternalName', 'ProductName', 'CompanyName', 'LegalCopyright', 'ProductVersion', 'FileDescription', 'LegalTrademarks', 'PrivateBuild', 'FileVersion', 'OriginalFilename', 'SpecialBuild')
  7. fname = os.environ['comspec']
  8. d = win32api.GetFileVersionInfo(fname, '\\')
  9. for n, v in d.items():
  10.     print n, v
  11.  
  12. pairs = win32api.GetFileVersionInfo(fname, '\\VarFileInfo\\Translation')
  13. for lang, codepage in pairs:
  14.     print 'lang: ', lang, 'codepage:', codepage
  15.     for ver_string in ver_strings:
  16.         str_info = u'\\StringFileInfo\\%04X%04X\\%s' % (lang, codepage, ver_string)
  17.         print ver_string, win32api.GetFileVersionInfo(fname, str_info)
  18.     
  19.  
  20.