]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/paper-outputter.cc
* Documentation/user/refman.itely: Compile fix for \mark #'(music ...).
[lilypond.git] / lily / paper-outputter.cc
index 24ed811878b28200c5cc8576c4ee5f8d860187bc..65c4e384d73c6842c401def99bf9aac270262325 100644 (file)
@@ -3,26 +3,23 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c)  1997--2001 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c)  1997--2002 Han-Wen Nienhuys <hanwen@cs.uu.nl>
   Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
 #include <time.h>
-
 #include <math.h>
 
-
 #include "dimensions.hh"
 #include "virtual-methods.hh"
 #include "paper-outputter.hh"
 #include "molecule.hh"
 #include "array.hh"
 #include "string-convert.hh"
-#include "debug.hh"
+#include "warn.hh"
 #include "font-metric.hh"
 #include "main.hh"
-#include "scope.hh"
-
+#include "scm-hash.hh"
 #include "lily-version.hh"
 #include "paper-def.hh"
 #include "file-results.hh"
@@ -95,7 +92,7 @@ Paper_outputter::output_scheme (SCM scm)
 }
 
 void
-Paper_outputter::output_scope (Scope *scope, String prefix)
+Paper_outputter::output_scope (Scheme_hash_table *scope, String prefix)
 {
   SCM al = scope->to_alist ();
   for (SCM s = al ; gh_pair_p (s); s = ly_cdr (s))
@@ -114,7 +111,7 @@ Paper_outputter::output_scope (Scope *scope, String prefix)
        }
       else if (gh_number_p (v))
        {
-         output_Real_def (prefix + s, gh_scm2double (v));        
+         output_Real_def (prefix + s, gh_scm2double (v));
        }
     }
 }
@@ -127,19 +124,18 @@ Paper_outputter::output_version ()
 
   output_String_def ("lilypondtagline", id_str);
   output_String_def ("LilyPondVersion", version_str ());
+  output_String_def ("lilypondpaperunit", String (INTERNAL_UNIT));  
 }
 
 
-
-
 void
 Paper_outputter::output_Real_def (String k, Real v)
 {
   
   SCM scm = scm_list_n (ly_symbol2scm ("lily-def"),
-                    ly_str02scm (k.ch_l ()),
-                    ly_str02scm (to_str (v).ch_l ()),
-                    SCM_UNDEFINED);
+                       ly_str02scm (k.ch_l ()),
+                       ly_str02scm (to_str (v).ch_l ()),
+                       SCM_UNDEFINED);
   output_scheme (scm);
 }
 
@@ -174,7 +170,7 @@ Paper_outputter::write_header_field_to_file (String filename, SCM key, SCM value
 }
 
 void
-Paper_outputter::write_header_fields_to_file (Scope * header)
+Paper_outputter::write_header_fields_to_file (Scheme_hash_table * header)
 {
   if (dump_header_fieldnames_global.size ())
     {