]> git.donarmstrong.com Git - lilypond.git/commitdiff
(do_file): Bugfix: texinfo paper
authorJan Nieuwenhuizen <janneke@gnu.org>
Wed, 10 Mar 2004 08:18:51 +0000 (08:18 +0000)
committerJan Nieuwenhuizen <janneke@gnu.org>
Wed, 10 Mar 2004 08:18:51 +0000 (08:18 +0000)
settings.
(Lilypond_snippet.is_outdated): Also check for PNG file.
Workaround for interrupted (web) builds.

ChangeLog
scripts/lilypond-book.py

index a47a52b1bb81628cb6ad75e4a2877297dd84ec49..e74f323e7e4f0ae1a029d4a47ebc3b82fc24e636 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2004-03-10  Jan Nieuwenhuizen  <janneke@gnu.org>
+
+       * scripts/lilypond-book.py (do_file): Bugfix: texinfo paper
+       settings.
+       (Lilypond_snippet.is_outdated): Also check for PNG file.
+       Workaround for interrupted (web) builds.
+
+       * lily/paper-book.cc (get_pages): Bugfix: set dimensions for titles.
+
+       * ps/lilyponddefs.ps: Use only very small top-marging.
+       (init-paper): Also pop page size string.
+       (start-page, stop-page): New function.
+
+       * scm/output-ps.scm (header-end): Remove stray exec commands.
+
 2004-03-10  Han-Wen Nienhuys   <hanwen@xs4all.nl>
 
        * lily/score.cc (default_rendering): clean protection.
index a0cd79855acfeaa2129e67b91956eb62bcd7951f..e9ed11648ef10c3122351e90192a8edc58bd2758 100644 (file)
@@ -271,11 +271,13 @@ FRAGMENT_LY = r'''\score{
 }'''
 FULL_LY = '%(code)s'
 
-texi_linewidths = { 'afourpaper': '160 \\mm',
-                   'afourwide': '6.5\\in',
-                   'afourlatex': '150 \\mm',
-                   'smallbook': '5 \\in' ,
-                   'letterpaper': '6\\in'}
+texinfo_linewidths = {
+       '@afourpaper': '160 \\mm',
+       '@afourwide': '6.5 \\in',
+       '@afourlatex': '150 \\mm',
+       '@smallbook': '5 \\in' ,
+       '@letterpaper': '6\\in',
+       }
 
 def classic_lilypond_book_compatibility (o):
        if o == 'singleline':
@@ -484,8 +486,12 @@ class Lilypond_snippet (Snippet):
 
        def is_outdated (self):
                base = self.basename ()
+               ## FIXME: adding PNG to is_outdated test fixes
+               ##        interrupted (web) builds.
+               ##        should only do this if PNG is actually target
                if os.path.exists (base + '.ly') \
                   and os.path.exists (base + '.tex') \
+                  and os.path.exists (base + '.png') \
                   and (use_hash_p \
                        or self.ly () == open (base + '.ly').read ()):
                        # TODO: something smart with target formats
@@ -828,9 +834,12 @@ def do_file (input_filename):
                        default_ly_options[LINEWIDTH] = '''%.0f\\pt''' \
                                                        % textwidth
                elif format == TEXINFO:
-                       for (k, v) in texi_linewidths.items ():
-                               s = chunks[0].replacement_text ()
-                               if re.search (k, s):
+                       for (k, v) in texinfo_linewidths.items ():
+                               # FIXME: @paper is usually not in chunk #0:
+                               #        \input texinfo @c -*-texinfo-*-
+                               # bluntly search first K of source
+                               # s = chunks[0].replacement_text ()
+                               if re.search (k, source[:1024]):
                                        default_ly_options[LINEWIDTH] = v
                                        break