# HG changeset patch # User Daniel O'Connor # Date 1462000043 -34200 # Node ID ce367392806cd37a713cf7e0a04e7da2054613a2 # Parent 71b78f06ff038ffba37ba545843d8bd172c35fc0 comment tweaks diff -r 71b78f06ff03 -r ce367392806c musiccutter.py --- a/musiccutter.py Sat Apr 30 16:37:14 2016 +0930 +++ b/musiccutter.py Sat Apr 30 16:37:23 2016 +0930 @@ -102,7 +102,7 @@ # Add title and page number Midi2PDF.textHelper(pdf, 0 * mm, 1 * mm, ENGRAVE_COLOUR, True, self.fontname, self.fontsize, '%s (%d / %d)' % (title, pindx + 1, npages)) - pdf.saveState() # Not really necessary since this is last thing we do + pdf.saveState() # Not really necessary since everything after this is done hairline pdf.setLineWidth(0) # Draw time marks @@ -118,7 +118,7 @@ pdf.line(x * mm, self.heel, x * mm, self.pageheight * mm) Midi2PDF.textHelper(pdf, x * mm, 1 * mm, ENGRAVE_COLOUR, False, self.fontname, self.fontsize, str(s) + 's') - # Draw rectangle around page + # Draw rectangle around page (upper and right hand ends don't seem to render though) if self.drawrect: pdf.rect(0, 0, self.pagewidth * mm, self.pageheight * mm, fill = False, stroke = True) @@ -130,6 +130,8 @@ # Note name if self.notenames: Midi2PDF.textHelper(pdf, (self.pagewidth - 10) * mm, ofs + 1 * mm, ENGRAVE_COLOUR, False, self.fontname, self.fontsize, self.slot2note[slot]) + + # Save PDF pdf.save() # http://newt.phys.unsw.edu.au/jw/notes.html