]> git.donarmstrong.com Git - lilypond.git/blobdiff - scripts/lilypond-book.py
Merge with master
[lilypond.git] / scripts / lilypond-book.py
index 340c1f0e442910a7ffbf932c50675c0314da2c7f..dd495fc7509e213d10fbe49c3153aefc5e4e9489 100644 (file)
@@ -144,7 +144,7 @@ def get_option_parser ():
                   dest="padding_mm",
                   help="Pad left side of music to align music inspite of uneven bar numbers. (in mm)",
                   type="float",
-                  default=-3.0)
+                  default=3.0)
     
     p.add_option ("-o", '--output', help=_ ("write output to DIR"),
                   metavar=_ ("DIR"),
@@ -1109,8 +1109,7 @@ class Lilypond_snippet (Snippet):
             and (self.relevant_contents (self.full_ly ())
                  == self.relevant_contents (open (ly_file).read ()))):
             return None
-        if global_options.verbose:
-            print 'OUT OF DATE: ', ly_file
+
         return self
 
     def png_is_outdated (self):
@@ -1448,10 +1447,12 @@ def process_snippets (cmd, ly_snippets, texstr_snippets, png_snippets):
                             be_verbose=global_options.verbose, 
                             progress_p=1)
 
-    if global_options.format in (HTML, TEXINFO):
+    if global_options.format in (HTML, TEXINFO) and '--formats' not in cmd:
         cmd += ' --formats=png '
-    if global_options.format in (DOCBOOK):
+    elif global_options.format in (DOCBOOK) and '--formats' not in cmd:
         cmd += ' --formats=png,pdf '
+
+        
     # UGH
     # the --process=CMD switch is a bad idea
     # it is too generic for lilypond-book.
@@ -1563,6 +1564,7 @@ def write_file_map (lys, name):
     snippet_map = open ('snippet-map.ly', 'w')
     snippet_map.write ("""
 #(define version-seen #t)
+#(define output-empty-score-list #f)
 #(ly:add-file-name-alist '(
 """)
     for ly in lys:
@@ -1575,7 +1577,7 @@ def write_file_map (lys, name):
 def do_process_cmd (chunks, input_name):
     all_lys = filter (lambda x: is_derived_class (x.__class__,
                            Lilypond_snippet),
-             chunks)
+                      chunks)
 
     write_file_map (all_lys, input_name)
     ly_outdated = filter (lambda x: is_derived_class (x.__class__,