Changeset 1926

Show
Ignore:
Timestamp:
11/15/04 23:29:01 (20 years ago)
Author:
jalet
Message:

Moved title and filename to the left to free some space.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/bin/pkbanner

    r1925 r1926  
    2424# 
    2525# $Log$ 
     26# Revision 1.7  2004/11/15 22:29:01  jalet 
     27# Moved title and filename to the left to free some space. 
     28# 
    2629# Revision 1.6  2004/11/15 22:20:27  jalet 
    2730# Now outputs strings as-is, and not title-ized 
     
    125128class PyKotaBanner(Tool) :         
    126129    """A class for pkbanner.""" 
    127     primaryfields = [  
    128                 ("PRINTERNAME", N_("Printer")), 
    129                 ("JOBID", N_("JobId")), 
    130                 ("JOBORIGINATINGHOSTNAME", N_("Client host")), 
    131                 ("TITLE", N_("Title")), 
    132                 ("FILENAME", N_("Filename")), 
    133                 ("COPIES", N_("Copies")), 
    134                 ("JOBSIZEBYTES", N_("Job size in bytes")), 
    135                 ("PRECOMPUTEDJOBSIZE", N_("Estimated job size")), 
    136                 ("PRECOMPUTEDJOBPRICE", N_("Estimated job price")), 
    137              ]    
    138               
    139     secondaryfields = [ 
    140                 ("LIMITBY", N_("Account limited by")), 
    141                 ("BALANCE", N_("Account balance")), 
    142                 ("PAGECOUNTER", N_("Number of pages on this printer")), 
    143                 ("SOFTLIMIT", N_("Soft limit")), 
    144                 ("HARDLIMIT", N_("Hard limit")), 
    145                 ("DATELIMIT", N_("Date limit")), 
    146              ]                            
    147      
    148     tertiaryfields = [ 
    149                 ("ACTION", N_("Action taken for current job")), 
    150              ]                            
    151      
    152130    def getPageSize(self, pgsize) : 
    153131        """Returns the correct page size or None if not found.""" 
     
    244222         
    245223        # Outputs title and filename 
     224        # We put them at x=0.25*pagewidth so that the line is long enough to hold them 
    246225        title = self.getVar("PYKOTATITLE") 
    247         ypos -= self.printVar(c, xcenter, ypos, _("Title"), title, 10, darkness)  
     226        ypos -= self.printVar(c, xcenter / 2.0, ypos, _("Title"), title, 10, darkness)  
    248227         
    249228        filename = self.getVar("PYKOTAFILENAME") 
    250         ypos -= self.printVar(c, xcenter, ypos, _("Filename"), filename, 10, darkness)  
     229        ypos -= self.printVar(c, xcenter / 2.0, ypos, _("Filename"), filename, 10, darkness)  
    251230         
    252231        # skip some space