Changeset 3456 for pkpgcounter

Show
Ignore:
Timestamp:
11/25/08 00:10:40 (16 years ago)
Author:
jerome
Message:

Replaced all print statements.

Location:
pkpgcounter/trunk
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • pkpgcounter/trunk/bin/pkpgcounter

    r3436 r3456  
    105105if __name__ == "__main__" : 
    106106    if (len(sys.argv) >= 2) and (sys.argv[1] in ("-h", "--help")) : 
    107         print __doc__ % globals() 
     107        sys.stdout.write("%s\n" % (__doc__ % globals())) 
    108108    else : 
    109109        analyzer.main() 
  • pkpgcounter/trunk/pkpgpdls/analyzer.py

    r3436 r3456  
    222222    (options, arguments) = parser.parse_args() 
    223223    if options.version : 
    224         print "%s" % version.__version__ 
     224        sys.stdout.write("%s\n" % version.__version__) 
    225225    elif not (72 <= options.resolution <= 1200) : 
    226226        sys.stderr.write("ERROR: the argument to the --resolution command line option must be between 72 and 1200.\n") 
     
    254254            sys.stderr.flush() 
    255255        if not options.colorspace : 
    256             print "%i" % totalsize 
     256            sys.stdout.write("%i\n" % totalsize) 
    257257        else : 
    258             print "\n".join(lines) 
     258            sys.stdout.write("%s\n" % ("\n".join(lines))) 
    259259 
    260260if __name__ == "__main__" : 
  • pkpgcounter/trunk/pkpgpdls/inkcoverage.py

    r3447 r3456  
    131131if __name__ == "__main__" : 
    132132    # NB : length of result gives number of pages ! 
    133     print getInkCoverage(sys.argv[1], "CMYK") 
     133    sys.stdout.write("%s\n" % getInkCoverage(sys.argv[1], "CMYK")) 
  • pkpgcounter/trunk/pkpgpdls/pjl.py

    r3436 r3456  
    147147        if mustclose : 
    148148            infile.close() 
    149         print str(parser) 
     149        sys.stdout.write("%s\n" % str(parser)) 
    150150 
    151151if __name__ == "__main__" :