Show
Ignore:
Timestamp:
11/28/06 18:03:07 (18 years ago)
Author:
jerome
Message:

Fixed a problem in the PostScript? parser with some versions (or settings)
or a2ps and endscript.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pkpgcounter/trunk/pkpgpdls/postscript.py

    r428 r437  
    101101                proceed = 1 
    102102                try : 
    103                     newpagenum = int(line.split(']')[0].split()[1]) 
     103                    # treats both "%%Page: x x" and "%%Page: (x-y) z" (probably N-up mode) 
     104                    newpagenum = int(line.split(']')[0].split()[-1]) 
    104105                except :     
    105106                    notinteger = 1 # It seems that sometimes it's not an integer but an EPS file name