Show
Ignore:
Timestamp:
10/06/08 00:22:07 (16 years ago)
Author:
jerome
Message:

Removed spaces at EOL.

Files:
1 modified

Legend:

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

    r3410 r3436  
    88# the Free Software Foundation, either version 3 of the License, or 
    99# (at your option) any later version. 
    10 #  
     10# 
    1111# This program is distributed in the hope that it will be useful, 
    1212# but WITHOUT ANY WARRANTY; without even the implied warranty of 
    1313# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
    1414# GNU General Public License for more details. 
    15 #  
     15# 
    1616# You should have received a copy of the GNU General Public License 
    1717# along with this program.  If not, see <http://www.gnu.org/licenses/>. 
     
    2626class Parser(pdlparser.PDLParser) : 
    2727    """A parser for PNM (ascii) documents.""" 
    28     openmode = "rU"                  
     28    openmode = "rU" 
    2929    format = "PNM (ascii)" 
    30     def isValid(self) :     
     30    def isValid(self) : 
    3131        """Returns True if data is ASCII PNM, else False.""" 
    3232        if self.firstblock.split()[0] in ("P1", "P2", "P3") : 
    3333            self.marker = self.firstblock[:2] 
    3434            return True 
    35         else :     
     35        else : 
    3636            return False 
    37              
     37 
    3838    def getJobSize(self) : 
    3939        """Counts pages in a PNM (ascii) document.""" 
     
    4747                # Special case of cmyk map 
    4848                divby = 4 
    49             # Unfortunately any whitespace is valid,  
     49            # Unfortunately any whitespace is valid, 
    5050            # so we do it the slow way... 
    5151            pagecount += line.split().count(marker) 
    52              
    53         if not (pagecount % divby) :     
     52 
     53        if not (pagecount % divby) : 
    5454            return pagecount // divby 
    55         else :     
     55        else : 
    5656            return pagecount